System Notifies Admin of mysqld Not Running

Discussion in 'General' started by giganet, Sep 21, 2007.

  1. giganet

    giganet New Member

    In the last few days I have seen the following notifies sent by the server:
    Code:
    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
    All mysql related functions appear to be functioning during these notifies.

    Thank you for the help...

    Regards
     
  2. till

    till Super Moderator

    Please post the output of:

    netstat -tap | grep mysql
     
  3. giganet

    giganet New Member

    Thank you Till

    The output of 'netstat -tap | grep mysql'
    Regards
     
  4. falko

    falko Super Moderator

    Can you log in to MySQL like this?

    Code:
    mysql -u root -p
     
  5. giganet

    giganet New Member

    Thank you Falko

    Yes I am able to log into mysql.
    No errors or anything at login...


    Regards
     
  6. falko

    falko Super Moderator

    And do
    Code:
    mysql -h 127.0.0.1 -u root -p
    and
    Code:
    mysql -h localhost -u root -p
    work as well? What's in /etc/mysql/my.cnf and /etc/hosts?
     
  7. andresb

    andresb New Member

    Seems like socket connection

    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.
     
  8. till

    till Super Moderator

    Tha's correct. Networking should be enabled for ISPConfig. If you want to prevent exernal access, you should use:

    Code:
    bind-address           = 127.0.0.1
    instead.
     
  9. giganet

    giganet New Member

    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'
    Code:
    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
     
  10. till

    till Super Moderator

    If you can login like this, then everything should be fine now.
     
  11. giganet

    giganet New Member

    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??

    Code:
    # 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:
    Code:
    auto lo
    iface lo inet loopback
    Actually look like:
    Code:
    auto lo
    iface lo inet loopback
            address 127.0.0.1
    Thank you

    Regards
     
  12. falko

    falko Super Moderator

    No,
    Code:
    auto lo
    iface lo inet loopback
    is fine.
     
  13. giganet

    giganet New Member

    Ahh, OK I got it now, just had to disable '#skip-networking'

    Thank you all for your help very much

    Regards
     

Share This Page