Error 2003 Hy000 111 Mysql
Contents |
here for a quick overview of the site Help Center Detailed answers to any questions you might have Meta Discuss the workings and policies of this site error 2003 hy000 can t connect to mysql server on 111 About Us Learn more about Stack Overflow the company Business Learn more about error 2003 hy000 mysql windows hiring developers or posting ads with us Stack Overflow Questions Jobs Documentation Tags Users Badges Ask Question x Dismiss Join error 2003 hy000 can't connect to mysql server on 110 the Stack Overflow Community Stack Overflow is a community of 4.7 million programmers, just like you, helping each other. Join them; it only takes a minute: Sign up ERROR 2003 (HY000): Can't error 2003 hy000 can't connect to mysql server on localhost 10061 connect to MySQL server (111) up vote 19 down vote favorite 3 This question is related to the following questions: Can't connect to MySQL server error 111 Trying to connect to remote MySQL host (error 2003) I am configuring a new MySQL (5.1) server on my local machine. I need to provide remote access to the database. I did the following steps: Comment bind-address in my.cnf:
Error 2003 Hy000 Can't Connect To Mysql Server On 113
# bind-address = 192.168.1.3 Grant privileges: GRANT ALL PRIVILEGES ON *.* TO 'nickruiz'@'%' IDENTIFIED BY PASSWORD 'xxxx'; Set port forwarding on router (TCP and UDP, port 3306, 192.168.1.3) Configure iptables for firewall sudo iptables -I INPUT -p udp --dport 3306 -j ACCEPT sudo iptables -I INPUT -p tcp --dport 3306 --syn -j ACCEPT sudo iptables-save Restart mysql server sudo /etc/init.d/mysql restart When testing, I get the following: LAN: mysql -h 192.168.1.3 -u nickruiz -p Welcome to the MySQL monitor. Commands end with ; or \g. Your MySQL connection id is 95 Server version: 5.1.63-0ubuntu0.11.04.1 (Ubuntu) Remote: mysql -h 1xx.xx.4.136 -u nickruiz -p ERROR 2003 (HY000): Can't connect to MySQL server on '1xx.xx.4.136' (111) Clearly there's something wrong that's preventing me from being able to use my global IP address. Notes: I've tried testing the remote connection on the same machine and also via SSH from a remote machine. I'm not sure if my ISP has given me a static IP. Any ideas? Update: telnet doesn't seem to be working. telnet 192.168.1.3 3306 Trying 192.168.1.3... Connected to 192.168.1.3. Escape character is '^]'. E 5.1.63-0ubuntu0.11.04.1,0g8!:@pX;]DyY0#\)SIConnection closed by foreign host. mysql linux remote-access mysql-error-2003 share|improve this quest
here for a quick overview of the site Help Center Detailed answers to any questions you might have Meta Discuss the workings and policies of this site About
Error 2005 Hy000
Us Learn more about Stack Overflow the company Business Learn more about hiring error 2002 hy000 developers or posting ads with us Stack Overflow Questions Jobs Documentation Tags Users Badges Ask Question x Dismiss Join the error 2006 hy000 Stack Overflow Community Stack Overflow is a community of 4.7 million programmers, just like you, helping each other. Join them; it only takes a minute: Sign up ERROR 2003 (HY000): Can't connect to http://stackoverflow.com/questions/11758339/error-2003-hy000-cant-connect-to-mysql-server-111 MySQL server on 'hostname' (111) up vote 7 down vote favorite Thanks in advance for your help. I am facing an issue with mysql server which is the title of this topic, by using the command: mysql -u myuser -pmypass -h `hostname` db_name I get the error ERROR 2003 (HY000): Can't connect to MySQL server on 'hostname' (111) So I checked the my.cnf file and I http://stackoverflow.com/questions/18083045/error-2003-hy000-cant-connect-to-mysql-server-on-hostname-111 have no lines with "bind address" and "skip-networking" although I tried adding them and restarting which did not change anything. Besides that there is no error in the sql logs, and we can (with HeidiSQL) connect to the server remotely knowing that the user is myuser"@"%. Mysql listens on the port 3306, so it's ok there Also, users created with with @'localhost', works fine with the command line (without the -h option). What is more intriguing is that other servers that look exactly the same work both locally and remotely with the first command... The server runs with CentOS 6.2 So if anyone has an idea on this matter I would be glad to hear it P.S : It's my first time posting here, so if there are formatting issues, please forgive me mysql networking centos share|improve this question edited Aug 13 '13 at 11:55 asked Aug 6 '13 at 14:29 ASettouf 36113 hostname is passed literally? If yes, replace it with the address of your server (or localhost) –Alma Do Aug 6 '13 at 14:33 1 No it is passed between "grave accent" (thus it is the unix command that is executed)
Get Kubuntu Get Xubuntu Get Lubuntu Get UbuntuStudio Get Mythbuntu Get Edubuntu Get Ubuntu-GNOME Get UbuntuKylin Ubuntu Code of Conduct Ubuntu Wiki https://ubuntuforums.org/showthread.php?t=2242435 Community Wiki Other Support Launchpad Answers Ubuntu IRC Support AskUbuntu Official http://forums.mysql.com/read.php?11,6916,184947 Documentation User Documentation Social Media Facebook Twitter Useful Links Distrowatch Bugs: Ubuntu PPAs: Ubuntu Web Upd8: Ubuntu OMG! Ubuntu Ubuntu Insights Planet Ubuntu Activity Page Please read before SSO login Advanced Search Forum The Ubuntu Forum Community Ubuntu Specialised Support Ubuntu Servers, Cloud and Juju Server Platforms error 2003 [SOLVED] Can't connect to MySQL server on 'DOMAIN' (111) Having an Issue With Posting ? Do you want to help us debug the posting issues ? < is the place to report it, thanks ! Page 1 of 2 12 Last Jump to page: Results 1 to 10 of 18 Thread: Can't connect to MySQL server on 'DOMAIN' (111) error 2003 hy000 Thread Tools Show Printable Version Subscribe to this Thread… Display Linear Mode Switch to Hybrid Mode Switch to Threaded Mode September 1st, 2014 #1 Maheriano View Profile View Forum Posts Private Message Iced Almond Soy Ubuntu, No Foam Join Date Jul 2006 Location Calgary, Alberta Beans 1,113 DistroUbuntu 13.04 Raring Ringtail Can't connect to MySQL server on 'DOMAIN' (111) I have a default installation of MySQL on my default Ubuntu server, I haven't really changed any settings after install. The default configuration is to disallow external connections to MySQL and I'm trying to allow external connections so I can connect to it from anywhere, mainly so I can use MySQL Workbench instead of PHPMyAdmin. I've made the necessary changes but it still doesn't seem to work. Here is part of my my.cnf file: Code: [mysqld] # # * Basic Settings # user = mysql pid-file = /var/run/mysqld/mysqld.pid socket = /var/run/mysqld/mysqld.sock port = 3306 basedir = /usr datadir = /var/lib/mysql tmpdir = /tmp lc-messages-dir = /usr/share/mysql # skip-external-locking # # Instead of skip-networking the d
Community Podcasts MySQL.com Downloads Documentation Section Menu: MySQL Forums :: Install & Repo :: Error 2003 (HY000): Can't connect to MySQL server on... New Topic Advanced Search Re: Error 2003 (HY000): Can't connect to MySQL server on... Posted by: Stephen Adkins () Date: November 26, 2007 03:26PM This error happened for me also. ERROR 2003 (HY000): Can't connect to MySQL server on 'po51' (111) Clearly this is a networking-level error and not a MySQL authentication error. The simple answer was to comment out the "bind-address" line in the global "my.cnf". I am running a fresh install of Gentoo. # cat /proc/version # Linux version 2.6.22-gentoo-r9 (root@po51) (gcc version 4.1.1 (Gentoo 4.1.1-r3)) #2 SMP Sun Nov 18 20:24:03 EST 2007 I checked my global "my.cnf" (which on Gentoo is "/etc/mysql/my.cnf") and saw these lines. # security: # using "localhost" in connects uses sockets by default # skip-networking bind-address = 127.0.0.1 The "skip-networking" is commented out meaning that we are not skipping networking. That's good for me because I want to connect to the MySQL server from another machine. The "bind-address" line says that when the server binds to a socket and listens on it, it will only access networking connections from clients that connect to it on that IP address. This is not what I wanted because "127.0.0.1" is the IP address for "localhost". This configuration will inherently not allow anyone to connect to the MySQL server from any other server! Others have suggested changing "127.0.0.1" to the network address that the server takes on the network ("172.17.4.51" in my case). This should work. However I do not wish to be this specific. So I commented out the "bind-address" line completely, and it started working just fine. There is no loss in security from commenting out this line. If someone is on your network trying to connect to the MySQL server, you will be no safer if the line exists than if it is commented out. Stephen Adkins Navigate:Previous Message•Next Message Options:Reply•Quote Subject Written By Posted Error 2003 (HY000): Can't connect to MySQL server on... mikeaconway 11/26/2004 03:38PM Re: Error 2003 (HY000): Can't connect to MySQL server on... mikeaconway 11/29/2004 04:00PM Re: Error 2003 (HY000): Ca