From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from lists.gentoo.org ([140.105.134.102] helo=robin.gentoo.org) by nuthatch.gentoo.org with esmtp (Exim 4.43) id 1EAaab-0000RH-0p for garchives@archives.gentoo.org; Wed, 31 Aug 2005 21:57:49 +0000 Received: from robin.gentoo.org (localhost [127.0.0.1]) by robin.gentoo.org (8.13.4/8.13.4) with SMTP id j7VLsaPt015945; Wed, 31 Aug 2005 21:54:36 GMT Received: from bullet.espersunited.com (24-117-226-93.cpe.cableone.net [24.117.226.93]) by robin.gentoo.org (8.13.4/8.13.4) with ESMTP id j7VLoWPB028287 for ; Wed, 31 Aug 2005 21:50:33 GMT Received: from baby.espersunited.com (baby.espersunited.com [192.168.1.3]) by bullet.espersunited.com (8.13.4/8.13.3) with ESMTP id j7VGtFtZ008869 for ; Wed, 31 Aug 2005 11:55:15 -0500 Subject: Re: [gentoo-user] Trouble with mysql From: Michael Sullivan To: gentoo-user@lists.gentoo.org In-Reply-To: <43162307.7030701@igoe.me.uk> References: <1125521529.11373.9.camel@baby.espersunited.com> <43162307.7030701@igoe.me.uk> Content-Type: text/plain Date: Wed, 31 Aug 2005 16:52:49 -0500 Message-Id: <1125525169.11368.17.camel@baby.espersunited.com> Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-user@gentoo.org Reply-to: gentoo-user@lists.gentoo.org Mime-Version: 1.0 X-Mailer: Evolution 2.2.3 Content-Transfer-Encoding: 7bit X-Archives-Salt: be223f38-693c-464c-8daa-a45bfabeff21 X-Archives-Hash: 2ca0fe23bdec8d96e4d52f330e0d1b3c On Wed, 2005-08-31 at 22:37 +0100, Tim Igoe wrote: > > Michael Sullivan wrote: > > I am having trouble with /etc/init.d/mysql. I rebooted my system, and > > when it finished rebooting I tried to connect to the mysql daemon and > > failed. I looked in /var/log/mysql: There was a file there called > > mysql.err. The contents were: > > > > 050831 15:47:29 mysqld started > > 050831 15:47:30 Can't start server: Bind on TCP/IP port: Address already > > in use > > 050831 15:47:30 Do you already have another mysqld server running on > > port: 3306 ? > > 050831 15:47:30 Aborting > > > > 050831 15:47:30 /usr/sbin/mysqld: Shutdown Complete > > > > 050831 15:47:30 mysqld ended > > > > > > check the output of ps aux > look for mysqld processes in the list - if it is running then try > killing the mysqld processes or restarting the machine > > > > > I tried netstat | grep '3306': > > > > bullet mysql # netstat | grep '3306' > > bullet mysql # > > netstat -n | grep 3306 > > or > > netstat | grep mysql > > might be better > > > > > The output was blank, so I assume that port 3306 is NOT in use. Any > > ideas? > > > > Do you have something else that could be using the port - a rootkit or > someone else running a service on the box? I did ps aux | grep 'mysqld' and got a listing of several mysqld processes. I killed each one using kill -9 and then rebooted the machine. Once it was fully rebooted I issued another ps aux | grep 'mysqld'. Here is the output: bullet ~ # ps aux | grep 'mysqld' root 8115 0.0 1.5 2216 948 ? Ss 11:50 0:00 /bin/sh /usr/bin/mysqld_safe --defaults-file=/etc/mysql/my.cnf mysql 8151 0.2 3.9 38728 2416 ? S 11:50 0:00 /usr/sbin/mysqld --defaults-file=/etc/mysql/my.cnf --basedir=/usr --datadir=/var/lib/mysql --user=mysql --pid-file=/var/run/mysqld/mysqld.pid --skip-locking --port=3306 --socket=/var/run/mysqld/mysqld.sock mysql 8153 0.0 3.9 38728 2420 ? S 11:50 0:00 /usr/sbin/mysqld --defaults-file=/etc/mysql/my.cnf --basedir=/usr --datadir=/var/lib/mysql --user=mysql --pid-file=/var/run/mysqld/mysqld.pid --skip-locking --port=3306 --socket=/var/run/mysqld/mysqld.sock mysql 8154 0.0 3.9 38728 2420 ? S 11:50 0:00 /usr/sbin/mysqld --defaults-file=/etc/mysql/my.cnf --basedir=/usr --datadir=/var/lib/mysql --user=mysql --pid-file=/var/run/mysqld/mysqld.pid --skip-locking --port=3306 --socket=/var/run/mysqld/mysqld.sock mysql 8155 0.0 3.9 38728 2420 ? S 11:50 0:00 /usr/sbin/mysqld --defaults-file=/etc/mysql/my.cnf --basedir=/usr --datadir=/var/lib/mysql --user=mysql --pid-file=/var/run/mysqld/mysqld.pid --skip-locking --port=3306 --socket=/var/run/mysqld/mysqld.sock root 8848 0.0 0.8 1448 492 pts/0 S+ 11:51 0:00 grep mysqld bullet ~ # I have no idea why so many of them are being started. How do I stop my system from starting more than one mysql daemon? -- gentoo-user@gentoo.org mailing list