MySQL doesn't work properly.

K

kimipatel

Guest
Hi,

I have found errors from /var/log/syslog using following command grep -i 'mysql' /var/log/syslog


SEP 17 19:52:54 dbametrix.com mysqld[9211]: 100409 19:52:54 InnoDB: Started; log sequence number 0 43655
SEP 17 19:52:54 dbametrix.com mysqld[9211]: 100409 19:52:54 [ERROR] Can't start server: Bind on TCP/IP port: Cannot assign requested address
SEP 17 19:52:54 dbametrix.com mysqld[9211]: 100409 19:52:54 [ERROR] Do you already have another mysqld server running on port: 3306 ?
SEP 17 19:52:54 dbametrix.com mysqld[9211]: 100409 19:52:54 [ERROR] Aborting
SEP 17 19:52:54 dbametrix.com mysqld[9211]:

How to resolve issue and start database? Could any one help me out?

Thanks.
 


You need to figure out what's running on port 3306 already.. could use:

Code:
netstat -tanp|grep 3306
 
Rest of error files are found empty like mysql.err file, mysql.log.


SEP 18 17:50:55 dbametrix.com mysqld_safe[9207]: started
Apdbametrix.com mysqld[9211]: 100409 17:50:55 InnoDB: Starting shutdown...
SEP 18 17:50:55 dbametrix.com mysqld[9211]: 100409 17:50:55 InnoDB: Shutdown completed; log sequence number 0 43655
SEP 18 17:50:55 dbametrix.com mysqld[9211]: 100409 17:50:55 [Note] /usr/sbin/mysqld: Shutdown complete
SEP 18 17:50:55 dbametrix.com mysqld[9211]:
SEP 18 17:50:55 dbametrix.com mysqld_safe[9242]: ended
SEP 18 17:50:55 dbametrix.com /etc/init.d/mysql[9380]: 0 processes alive and '/usr/bin/mysqladmin --defaults-file=/etc/mysql/debian.cnf ping' resulted in
SEP 18 17:50:55 dbametrix.com /etc/init.d/mysql[9380]: ^G/usr/bin/mysqladmin: connect to server at 'localhost' failed
SEP 18 17:50:55 dbametrix.com /etc/init.d/mysql[9380]: error: 'Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (2)'
SEP 18 17:50:55 dbametrix.com /etc/init.d/mysql[9380]: Check that mysqld is running and that the socket: '/var/run/mysqld/mysqld.sock' exists!
SEP 18 17:50:55 dbametrix.com /etc/init.d/mysql[9380]:
 
Unfortunately this is our main production site http://www.dbametrix.com and we are providing Oracle database support to various global clients. One of our ticketing system failed with above errors. Which i already mention. What should i do? To start normal way?
 
pls post cmd results

Kimipatel, if you do what rob says, ie find out what is running on port 3306 this will help diagnose the issue. Post the results if you are not sure what to do next. You may need to kill whatever service is running on the port (process number will be listed with the above netstat command) and then restart mysqld. Also, you are using InnoDB, is it configured to split tables into separate files? Check the db table sizes and available disk space ( df -h [filepath] ).

Let us know how you get on.

Daniel
 
[root@Uranus ~]# netstat -tanp|grep 3306
tcp 0 0 192.168.0.115:3306 0.0.0.0:* LISTEN 2193/mysqld
[root@Uranus ~]# uname -a
Linux Uranus 2.6.32-71.el6.x86_64 #1 SMP Fri May 20 03:51:51 BST 2011 x86_64 x86_64 x86_64 GNU/Linux

We are not using InnDB? Check following output of df -h. data1 mountpoint became full. I need to check does it consumed mySQL files or not.
[root@Uranus ~]# df -h
Filesystem Size Used Avail Use% Mounted on
/dev/mapper/vg_uranus-lv_root
50G 24G 23G 52% /
tmpfs 3.8G 1.8G 2.1G 47% /dev/shm
/dev/sda3 485M 35M 425M 8% /boot
/dev/mapper/vg_uranus-lv_home1
666G 30G 603G 5% /home
/sda2 485G 485G 0 100% /data1
 
Hi friends,

After cleaning up /data1 mountpoint. We didn't get any error in mySQL. Now it is working properly. We tried to check connectivity from outside of server too. It is also working fine. We are scheduling to restart server this weekend. Thanks a lot for your proper help. I appreciate help from everybody especially @rob and #ddlench.
 
what distro do you use, does the init.d V system already not in support of service scripts?
do this and slap it

Code:
service mysql start

it that doesn't do it, see the TCP ports,

Code:
netstat -antp | grep mysql
 

Staff online

Members online


Top