有类似问题,贴上来看看对你有否帮助:
[function.mysql-connect]: Can't create TCP/IP socket (10106)
Trying to connect to mysql with PHP under windows XP pro. 
The solution to this problem was for me to connect 
.via named pipe (FIFO)
in the my.ini, I added this:
enable-named-pipe
and renamed localhost:
HOST=.
(just a dot) and not 
HOST=localhost 
which, if I anderstand well try to find its way via TCP/IP and for some reason doesn't. 
I overlooked the installation manual.
Everything works just fine now.