Link to home
Start Free TrialLog in
Avatar of mlsbraves
mlsbravesFlag for United States of America

asked on

Can't get mysql to start after reboot. Starting fails and mysqld says it may already be running.

I'm running Ubuntu 9.10. I cant get mysql to start after I rebooted my system. Usually I just use the following code to start the service.

sudo /etc/init.d/mysql start

But this returns [fail]
So I looked at the status sudo /etc/init.d/mysql status:
* MySQL is stopped.

So then I tried the following:
>sudo mysqld
100415 11:11:40 [Note] Plugin 'FEDERATED' is disabled.
100415 11:11:40  InnoDB: Started; log sequence number 0 44233
100415 11:11:40 [ERROR] Can't start server: Bind on TCP/IP port: Cannot assign requested address
100415 11:11:40 [ERROR] Do you already have another mysqld server running on port: 3306 ?
100415 11:11:40 [ERROR] Aborting
100415 11:11:40  InnoDB: Starting shutdown...
100415 11:11:41  InnoDB: Shutdown completed; log sequence number 0 44233
100415 11:11:41 [Warning] Forcing shutdown of 1 plugins
100415 11:11:41 [Note] mysqld: Shutdown complete

I checked to make sure the service wasnt running:
>sockstat | grep "mysqld"

Nothing.

I then tried connecting to mysql
>mysql
ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (2)

I did change the IP address and install an tftp server on it recently but I don't see where this could have hurt anything. Does someone know what could be happening in my case?

Avatar of TobiasHolm
TobiasHolm
Flag of Sweden image

Maybe you can try to uninstall the TFTP server to see if MySQL starts?

Regards, Tobias
Avatar of mlsbraves

ASKER

I uninstalled the following programs that was installed with the TFPT server:
xinetd tftpd tftp

Rebooted the system and still have the same problems
is your loopback interface up?
ASKER CERTIFIED SOLUTION
Avatar of thedwill
thedwill
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Yes,
ifconfig:
eth0      Link encap:Ethernet  HWaddr 00:0b:1b:db:ab:ab
          inet addr:10.1.0.15  Bcast:10.1.0.127  Mask:255.255.255.128
          inet6 addr: fe80::20f:1fff:fede:a4a2/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:158 errors:0 dropped:0 overruns:0 frame:0
          TX packets:174 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:16738 (16.7 KB)  TX bytes:27354 (27.3 KB)
          Interrupt:16

lo        Link encap:Local Loopback
          inet addr:127.0.0.1  Mask:255.0.0.0
          inet6 addr: ::1/128 Scope:Host
          UP LOOPBACK RUNNING  MTU:16436  Metric:1
          RX packets:4 errors:0 dropped:0 overruns:0 frame:0
          TX packets:4 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0
          RX bytes:240 (240.0 B)  TX bytes:240 (240.0 B)
ps ax |grep mysql

kill -9 nnnn

where nnnn is the process id of the mysql prcess, then try to start it again and see if that works

[quote]
thedwill:
check the bind address here:
/etc/mysql/my.conf
[/quote]
The Bind address was set to the old IP address. Changed it and everything is back up. Thanks for all the quick responses.