Sunday, April 28, 2024
 Popular · Latest · Hot · Upcoming
0
rated 0 times [  0] [ 0]  / answers: 1 / hits: 4485  / 2 Years ago, thu, september 8, 2022, 5:52:57

The connection worked fine the other day and for some reason is doesn't. MySQL is running in Ubuntu Server 12.04 and I am trying to connect to a database using ODBC Connector 5.1 from Windows 7.



I have tried commenting out and keeping the bind-address in the cnf file. I have tried to grant all access. I have been reading endless amounts of tutorials and posting to attempt to figure it out. I cannot figure out what is going on, also I am a newbie to all this and I have noticed that most posting leave out some minor things that others may be attuned to.



Help! Thanks in advance.



The service is running and I get the following from netstat -tlpen | grep mysql:



tcp  0  0.0.0.0.0:3306  0.0.0.0:*  LISTEN  106  15172  3565/mysqld


I get the following from netstat -tlpen:



    Active Internet connections (only servers)
Proto Recv-Q Send-Q Local Address Foreign Address State User Inode PID/Program name
tcp 0 0 0.0.0.0:3306 0.0.0.0:* LISTEN 106 15172 3565/mysqld
tcp 0 0 0.0.0.0:139 0.0.0.0:* LISTEN 0 7092 776/smbd
tcp 0 0 0.0.0.0:111 0.0.0.0:* LISTEN 0 8325 784/rpcbind
tcp 0 0 0.0.0.0:10000 0.0.0.0:* LISTEN 0 9759 1325/perl
tcp 0 0 0.0.0.0:44819 0.0.0.0:* LISTEN 0 9584 -
tcp 0 0 0.0.0.0:22 0.0.0.0:* LISTEN 0 8809 947/sshd
tcp 0 0 0.0.0.0:445 0.0.0.0:* LISTEN 0 7090 776/smbd
tcp 0 0 0.0.0.0:2049 0.0.0.0:* LISTEN 0 9000 -
tcp6 0 0 :::139 :::* LISTEN 0 7088 776/smbd
tcp6 0 0 :::111 :::* LISTEN 0 8328 784/rpcbind
tcp6 0 0 :::22 :::* LISTEN 0 8811 947/sshd
tcp6 0 0 :::445 :::* LISTEN 0 7085 776/smbd
tcp6 0 0 :::2049 :::* LISTEN 0 9003 -
tcp6 0 0 :::47906 :::* LISTEN 0 9586 -


iptable -L



Chain INPUT (policy ACCEPT)
target prot opt source destination

Chain FORWARD (policy ACCEPT)
target prot opt source destination

Chain OUTPUT (policy ACCEPT)
target prot opt source destination


enter image description here


More From » server

 Answers
5

I finally figured out what was going on. It turns out that the static ip that I set for my server was not completely establishedand upon reboot another computer on my LAN grabbed the ip address that I dictated for the server.



sudo nano /etc/network/interfaces


and changed the information similar to this tutorial, using the information realted to my LAN.



Instead of changing the resolv.conf file as the tutorial states I added:



dns-nameserver XX.XX.XX.XX
dns-nameserver XX.XX.XX.XX


as two additional lines at the bottom of the interfaces file. XX.XX.XX.XX are replaced with the dns-nameservers that I identified from my router. Other information that I read indicates that you could use others, i.e. Google or OpenDNS. Once that was done and the network was restarted, I had to remove dhcp-client from the server. Without doing this the static ip address does not maintain upon restarting the server.


[#32385] Friday, September 9, 2022, 2 Years  [reply] [flag answer]
Only authorized users can answer the question. Please sign in first, or register a free account.
issfullus

Total Points: 264
Total Questions: 126
Total Answers: 107

Location: Comoros
Member since Mon, Dec 19, 2022
1 Year ago
;