Bug #35085 mysql.sock is missing
Submitted: 5 Mar 2008 16:38 Modified: 5 Mar 2008 17:20
Reporter: Francis Lacroix Email Updates:
Status: Not a Bug Impact on me:
None 
Category:MySQL Server Severity:S2 (Serious)
Version:5.1.23a OS:Microsoft Windows
Assigned to: CPU Architecture:Any
Tags: console, missing, mysql.sock, windows

[5 Mar 2008 16:38] Francis Lacroix
Description:
I am using the MySQL 5.1.23a Community build. I also tried MySQL4 stable. I am not running it as a service, but rather in console mode, in Windows XP. The server runs fine when using networking. However, when I attempt to skip networking and use the socket instead, the socket file (c:\tmp\mysql.sock) just won't create itself. I am, of course, running it as Administrator.

So the permissions:
C:\>cacls tmp
C:\tmp Everyone:(OI)(CI)F

Running the server:
mysqld --console --skip-networking --socket=c:/tmp/mysql.sock --enable-named-pipe

080305 11:07:26  InnoDB: Started; log sequence number 0 46409
080305 11:07:26 [Note] Event Scheduler: Loaded 0 events
080305 11:07:26 [Note] mysqld: ready for connections.
Version: '5.1.23a-maria-alpha-community-maria'  socket: ''  port: 0  MySQL Community Server [Maria] (GPL)

As you can see, the output is: "socket: '' port: 0". I don't know why it doesn't create it. I use the same version on Fedora Core 6 with the same parameters (except the path is /tmp/mysql.sock) and it works perfectly, it just won't work in Windows.

Thanks for looking into it.

How to repeat:
In Windows: mysqld --console --skip-networking --socket=c:/tmp/mysql.sock --enable-named-pipe
[5 Mar 2008 17:20] MySQL Verification Team
Thank you for the bug report. Please read:
http://dev.mysql.com/doc/refman/5.1-maria/en/windows-testing.html

"...host name. Use the --socket option to specify the name of the pipe if you do not want to use the default pipe name."

c:\dbs>5.1\bin\mysqld --standalone --console --skip-networking --socket="MySQLSocket" --enable-named-pipe
080305 14:15:57  InnoDB: Started; log sequence number 0 46409
080305 14:15:57 [Note] Event Scheduler: Loaded 0 events
080305 14:15:57 [Note] 5.1\bin\mysqld: ready for connections.
Version: '5.1.24-rc-nt-log'  socket: ''  port: 0  Source distribution

c:\dbs>5.0\bin\mysql -uroot -W --socket="MySQL"
ERROR 2017 (HY000): Can't open named pipe to host: .  pipe: MySQL (2)

c:\dbs>5.0\bin\mysql -uroot -W --socket="MySQLSocket"
Welcome to the MySQL monitor.  Commands end with ; or \g.
Your MySQL connection id is 1
Server version: 5.1.24-rc-nt-log Source distribution

Type 'help;' or '\h' for help. Type '\c' to clear the buffer.

mysql>