Subject: mysqladmin shutdown hangs
To: NetBSD-Help <netbsd-help@NetBSD.org>
From: Serban Udrea <S.Udrea@gsi.de>
List: netbsd-help
Date: 02/22/2005 09:08:57
Hello,

I am doing my first steps with mysql on NetBSD and have the problem that mysqladmin is not 
able to take the server down. It just hangs up to a ^C (or kill) and then issues a message like:

Aborted waiting on pid file: '/var/mysql/sklap05.ikp.physik.tu-darmstadt.de.pid' after 217 
seconds

The file is there and contains the correct PID:

 > cat /var/mysql/sklap05.ikp.physik.tu-darmstadt.de.pid
17526
 > ps ax | grep mysql
17526 p0 Ia   0:01.09 /usr/pkg/libexec/mysqld --basedir=/usr/pkg --datadir=/var/mysql 
--user=mysql --pid-f
20203 p0 I    0:00.01 /bin/sh /usr/pkg/bin/mysqld_safe --datadir=/var/mysql

If I just

 > kill 17256

mysql goes down.

According to the reference manual "mysqladmin shutdown" should take down the server, if one 
did not set the root password (which is the case in my test).

Nevertheless, I set the root password running the two commands mentioned in the post install 
MESSAGE and tried both:

 > /usr/pkg/bin/mysqladmin -u root -p shutdown

and

 > /usr/pkg/bin/mysqladmin -h `hostname` -u root -p shutdown


In the first case there was the same behaviour as before, in the second case the command 
returned without any messages immediately after I entered the password but the mysql server 
was still there, up and running.

Any clues are wellcome!

Best regards,

Serban Udrea