[Bug 491685] [NEW] memcached doesn't correctly daemonize

Robby robbyd at u20.org
Thu Dec 3 01:30:36 UTC 2009


Public bug reported:

Binary package hint: memcached

Ubuntu 9.10
memcached 1.2.8-1

it appears that launching memcached through the init.d scripts will
cause it to daemonize in a way where it's still attached to the tty of
the launching terminal/process. For instance, 'ps aux' shows:

nobody   16026  0.0  0.1  55976  2364 pts/0    Sl+  00:47   0:00
/usr/bin/memcached -m 128 -p 11211 -u nobody

where if I launch the command like so:

root at chllab-dev1:/home/rbd# su nobody --
$ /usr/bin/memcached -d -m 128 -p 11211 -u nobody

I see:

nobody    4970  0.0  0.0 113816   884 ?        Ssl  20:24   0:00
/usr/bin/memcached -d -m 128 -p 11211 -u nobody

Notice the command is not associated with a particular tty (good). This
problem will not affect most people, but affects me because I have an
application that will start up memcached when it starts up, and shut it
down right before it's done shutting down. When my application receives
a SIGINT, memcached gets the SIGINT as well and dies suddenly, where my
app still needs it for the shutdown routine to complete.

The fix would be to have memcached's perl wrapper pass the -d flag along
to the daemon...right now it appears that it ignores this, even if I
uncomment it in the /etc/memcached.conf file

** Affects: memcached (Ubuntu)
     Importance: Undecided
         Status: New

-- 
memcached doesn't correctly daemonize
https://bugs.launchpad.net/bugs/491685
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.

-- 
ubuntu-bugs mailing list
ubuntu-bugs at lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs




More information about the universe-bugs mailing list