Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.
  • Percona-XtraDB-Cluster-server-5.5.24-23.6.340.rhel5

This is a slave server. mysqladmin shutdown hangs at:

[Note] Event Scheduler: Purging the queue. 24 events 
[Note] Slave I/O thread killed while reading event 
[Note] Slave I/O thread exiting, read up to log 'mysql-bin.000878', position 848536790 

so, I pressed Ctrl+C, and the terminal show the below warning:

Warning;  Aborted waiting on pid file: '/var/lib/mysql/x.pid' after 302 seconds

The processes still exist:

root 9623 1 0 10:18 pts/8 00:00:00 /bin/sh /usr/bin/mysqld_safe --datadir=/var/lib/mysql --pid-file=/var/lib/mysql/x.pid

mysql 10357 9623 0 10:18 pts/8 00:00:06 /usr/sbin/mysqld --basedir=/usr --datadir=/var/lib/mysql --plugin-dir=/usr/lib64/mysql/plugin --user=mysql --log-error=/var/log/mysqld.log --open-files-limit=100000 --pid-file=/var/lib/mysql/x.pid --socket=/var/lib/mysql/mysql.sock

but the socket file is missing:

ls: /var/lib/mysql/mysql.sock: No such file or directory

and there is nothing listening on port 3306.

# netstat --inet -nlp | grep :3306
# lsof -i :3306
#

Sending a SIGTERM signal (kill -15) to the child process doesn't work. What can I do but kill -9?

share|improve this question
add comment

1 Answer

up vote 0 down vote accepted

Nothing. Get out the SIGKILL bat and prepare for a log recovery.

share|improve this answer
    
There is only a few processes when stopping. How many minutes should I wait before pressing Ctrl-C? –  quanta Jul 28 '12 at 15:25
1  
You should never press Ctrl-C. Who runs MySQL servers in the foreground? –  womble Jul 28 '12 at 21:26
    
MySQL server was started by init script. It happened to me that InnoDB couldn't recover after doing a kill -9. –  quanta Jul 29 '12 at 4:48
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.