MySQL Forums
Forum List  »  Newbie

Can't connect from remote host
Posted by: Jeffrey Hunter
Date: August 01, 2005 01:29PM

Newbie alert...

I have installed and configured MySQL 4.1.13 on RH3 (2.4.21-27.0.2). I can connect as -uroot -pmypassword, but when I try to connect using the -h flag, I get:

bash-2.05b$ mysql -uroot -pmypw
Welcome to the MySQL monitor. Commands end with; or \g.
Your MySQL connection id is 2 to server version: 4.1.13-max

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

mysql>

bash-2.05b$ mysql -uroot -pmypw -h myhost -port 3036
ERROR 2003 (HY000): Can't connect to MySQL server on 'myhost' (111)


I can definitely ping my hostname, so I know nameservice is not a problem.
bash-2.05b$ ping myhost
PING myhost (192.1.1.1) 56(84) bytes of data.
64 bytes from myhost (192.1.1.1): icmp_seq=0 ttl=64 time=0.025 ms
64 bytes from myhost (192.1.1.1): icmp_seq=1 ttl=64 time=0.022 ms
64 bytes from myhost (192.1.1.1): icmp_seq=2 ttl=64 time=0.014 ms


I see mysqld using the correct port:
bash-2.05b$ ps -ef | grep mysqld
mysql 22684 22580 0 14:44 pts/1 00:00:00 /bin/sh ./bin/mysqld_safe
mysql 22743 22684 0 14:44 pts/1 00:00:00 /mysql/bin/mysqld --defaults-extra-file=/mysql/data/my.cnf --basedir=/mysql --datadir=/mysql/data --pid-file=/mysql/myhost.pid --skip-locking --port=3036 --socket=/mysql/data/myhost.sock
mysql 22837 22833 0 14:53 pts/2 00:00:00 grep mysqld


Any hints as to why I can't connect when I specify the hostname? (I'm testing connections via a client).

Options: ReplyQuote


Subject
Written By
Posted
Can't connect from remote host
August 01, 2005 01:29PM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.