mysql clients ignore port specification when connecting to "localhost"
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
mysql-admin (Ubuntu) |
Invalid
|
Undecided
|
Unassigned | ||
mysql-dfsg-5.0 (Ubuntu) |
Fix Released
|
Medium
|
Unassigned |
Bug Description
Binary package hint: mysql-admin
I can duplicate this with all of mysql, mysqldump, and the mysql-admin GUI on 8.04LTS. This is not the behavior I am used to from the same applications on 6.06LTS or the Windows ports of the same applications.
I normally create an SSH tunnel to a remote (6.06LTS) server where I run a MySQL server (via `ssh -L localhost:
When I specify a host of "localhost" and a port of "33060" to any of mysql, mysqldump, or mysql-admin, the client will attach to the local instance of MySQL server instead of the tunnel to the remote instance, yet when I connect directly to 127.0.0.1, the connection works (I can also work around this by defining some other alias for 127.0.0.1 in /etc/hosts and using it). In the following transcript, note the local MySQL instance is hardy's version 5.051a-3ubuntu5.1 and the remote instance is dapper's version 5.0.22-
derek@jor-el:~$ mysql -h localhost --port=33060 -uroot -p
Enter password:
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 32
Server version: 5.0.51a-3ubuntu5.1 (Ubuntu)
Type 'help;' or '\h' for help. Type '\c' to clear the buffer.
mysql> quit
Bye
derek@jor-el:~$ mysql -h 127.0.0.1 --port=33060 -uroot -p
Enter password:
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 493390
Server version: 5.0.22-
Type 'help;' or '\h' for help. Type '\c' to clear the buffer.
mysql> quit
Bye
derek@jor-el:~$ telnet localhost 33060
Trying 127.0.0.1...
Connected to localhost.
Escape character is '^]'.
M
5.0.22-
derek@jor-el:~$
Changed in mysql-dfsg-5.0: | |
importance: | Undecided → Medium |
status: | New → Triaged |
http:// bugs.mysql. com/bug. php?id= 31577