tags:

views:

329

answers:

1

I have run Memcached on my Server for 2 month. Yesterday it stopped working. No idea why. So I tried:

root@xyz:~# killall memcached
root@xyz:~# /etc/init.d/memcached stop
Stopping memcached: memcached.
root@xyz:~# memcached -d -m 128 -l 127.0.0.1 -p 11211 -vv -u www-data
bind(): Address already in use
failed to listen
root@xyz:~# memcached -u www-data -vv
bind(): Address already in use
failed to listen

Any idea?

+2  A: 

Make sure that memcached is not running.

ps auxw | grep memcached

If you find any process, kill it with kill -9 (to make sure it REALLY is killed):

kill -9 insert-your-PID-of-running-memcached-here

If you still can't start memcached, look if there's anything else listening on port 11211:

netstat -A -n | grep 11211

Also, this questions belongs to Serverfault, because it's not a programming question.

Emil Vikström
Thank you. It works with `kill -9 [PID]`. If someone has problems with interpreting the result of `ps auxw` you can also use `pidof memcached`.
Bernd