View Full Version : System Notifies Admin of mysqld Not Running
giganet
21st September 2007, 01:14
In the last few days I have seen the following notifies sent by the server:
Warning: service mysqld not running (server: giganetwireless.com)!
Message generated at September 20, 2007, 14:30.
This message is received every half hour by the admin email account.
After receiving the notifiy on a few ocassions I have run '/etc/init.d/mysql status' which returns
mailman@giganetwireless:~$ /etc/init.d/mysql status
Password:
/usr/bin/mysqladmin Ver 8.41 Distrib 5.0.22, for pc-linux-gnu on i486
Copyright (C) 2000 MySQL AB & MySQL Finland AB & TCX DataKonsult AB
This software comes with ABSOLUTELY NO WARRANTY. This is free software,
and you are welcome to modify and redistribute it under the GPL license
Server version 5.0.22-Debian_0ubuntu6.06.3-log
Protocol version 10
Connection Localhost via UNIX socket
UNIX socket /var/run/mysqld/mysqld.sock
Uptime: 1 day 6 min 48 sec
Threads: 1 Questions: 7430 Slow queries: 0 Opens: 0 Flush tables: 1 Open tables: 64 Queries per second avg: 0.086
All mysql related functions appear to be functioning during these notifies.
Thank you for the help...
Regards
till
21st September 2007, 09:09
Please post the output of:
netstat -tap | grep mysql
giganet
21st September 2007, 20:31
Thank you Till
The output of 'netstat -tap | grep mysql'
After roughly a 20 second pause after initiating the command the system returns nothing at all then returns to the ready prompt
Regards
falko
22nd September 2007, 13:27
Can you log in to MySQL like this?
mysql -u root -p
giganet
22nd September 2007, 23:09
Thank you Falko
Yes I am able to log into mysql.
No errors or anything at login...
Regards
falko
23rd September 2007, 20:21
And do mysql -h 127.0.0.1 -u root -p and mysql -h localhost -u root -p work as well? What's in /etc/mysql/my.cnf and /etc/hosts?
andresb
24th September 2007, 06:26
This is my guess, I've been receiving these messages since I retouched my.cnf.
If you set skip-networking in my.cnf the service checker assumes the mysql server is down, even if it's working.
till
24th September 2007, 10:43
This is my guess, I've been receiving these messages since I retouched my.cnf.
If you set skip-networking in my.cnf the service checker assumes the mysql server is down, even if it's working.
Tha's correct. Networking should be enabled for ISPConfig. If you want to prevent exernal access, you should use:
bind-address = 127.0.0.1
instead.
giganet
25th September 2007, 07:29
Thank you Falko, Andre & Till...
I am able to log when running 'mysql -h localhost -u root -p'
I just edited '/etc/mysql/my.cnf' skip-networking enabled and the bind address uncommented.
After restarting mysql I am still unable to log onto mysql using 'mysql -h 127.0.0.1 -u root -p'.
Will wait to see if the system emails warns cease.
'my.cnf contents'
Copyright (C) 2000 MySQL AB & MySQL Finland AB & TCX DataKonsult AB
This software comes with ABSOLUTELY NO WARRANTY. This is free software,
and you are welcome to modify and redistribute it under the GPL license
Server version 5.0.22-Debian_0ubuntu6.06.3-log
Protocol version 10
Connection Localhost via UNIX socket
UNIX socket /var/run/mysqld/mysqld.sock
Uptime: 3 min 45 sec
Threads: 1 Questions: 217 Slow queries: 0 Opens: 0 Flush tables: 1 Open tables: 64 Queries per second avg: 0.964
mailman@giganetwireless:~$ sudo vi /etc/mysql/my.cnf
log_bin = /var/log/mysql/mysql-bin.log
# WARNING: Using expire_logs_days without bin_log crashes the server! See README.Debian!
expire_logs_days = 10
max_binlog_size = 100M
#binlog_do_db = include_database_name
#binlog_ignore_db = include_database_name
#
# * BerkeleyDB
#
# Using BerkeleyDB is now discouraged as its support will cease in 5.1.12.
skip-bdb
#
# * InnoDB
#
# InnoDB is enabled by default with a 10MB datafile in /var/lib/mysql/.
# Read the manual for more InnoDB related options. There are many!
# You might want to disable InnoDB to shrink the mysqld process by circa 100MB.
#skip-innodb
#
# * Security Features
#
# Read the manual, too, if you want chroot!
# chroot = /var/lib/mysql/
#
# For generating SSL certificates I recommend the OpenSSL GUI "tinyca".
#
# ssl-ca=/etc/mysql/cacert.pem
# ssl-cert=/etc/mysql/server-cert.pem
# ssl-key=/etc/mysql/server-key.pem
[mysqldump]
quick
quote-names
max_allowed_packet = 16M
[mysql]
#no-auto-rehash # faster start of mysql but no tab completition
[isamchk]
key_buffer = 16M
#
# * NDB Cluster
#
# See /usr/share/doc/mysql-server-*/README.Debian for more information.
#
# The following configuration is read by the NDB Data Nodes (ndbd processes)
# not from the NDB Management Nodes (ndb_mgmd processes).
#
# [MYSQL_CLUSTER]
# ndb-connectstring=127.0.0.1
#
# * IMPORTANT: Additional settings that can override those from this file!
#
!includedir /etc/mysql/conf.d/
Thank you all very much for your time and help.
Regards
till
25th September 2007, 10:17
I am able to log when running 'mysql -h localhost -u root -p'
If you can login like this, then everything should be fine now.
giganet
25th September 2007, 21:52
Hmm, I just received more of the mysql service not running notifies.
Looking into '/etc/network/interfaces' I see the following and think I see the problem??
# The loopback network interface
auto lo
iface lo inet loopback
# The primary network interface (WAN)
auto eth0
iface eth0 inet static
address 72.169.xxx.xxx
netmask 255.0.0.0
network 72.169.xxx.xxx
broadcast 72.169.xxx.xxx
gateway 72.169.xxx.xxx
Shouldn't the line:
auto lo
iface lo inet loopback
Actually look like:
auto lo
iface lo inet loopback
address 127.0.0.1
Thank you
Regards
falko
26th September 2007, 16:07
No,
auto lo
iface lo inet loopback
is fine.
giganet
28th September 2007, 03:41
Ahh, OK I got it now, just had to disable '#skip-networking'
Thank you all for your help very much
Regards
vBulletin® v3.8.4, Copyright ©2000-2010, Jelsoft Enterprises Ltd.