Do you have a question? Post it now! No Registration Necessary. Now with pictures!
- Posted on
- Multiple servers on a single host question
July 13, 2005, 11:52 pm
rate this thread
servers. The second server is run with this command:
shell> mysqld_safe --defaults-extra-file=/root/my2.cnf &
some /root/my2.cnf file entries:
port = 3307
socket = /tmp/mysql2.sock
Both servers co-exist peacefully except:
shell> mysql --socket=/tmp/mysql2.sock [accesses second server
shell> mysql --port=3307 [accesses the first server and not the
Does that mean that the first server's port 3306 is hard-coded into
Is this a bug ?
Or am I missing something ?
What is the work-around ?
Re: Multiple servers on a single host question
The default port is coded into MySQL. I don't see this as a problem.
The port used is irrelevant if it's using the unix-domain socket.
It uses the unix-domain socket instead of the port if the host
is specified as or defaults to 'localhost'.
If you want to use the second server, specify BOTH the socket and
the port for the second server, which works regardless of
whether "--host localhost" or "--host my.server.com" is being
Gordon L. Burditt
- » Americanas.com SALDO de TVs Com at 80% de Desconto (29798)
- — Newest thread in » MySQL Database Forum