Is there any reason to NOT lock down paged memory, when running memcached as 
daemon ?

With current code, -d will effectively ignore -k.

I re-arranged the current code as following:
From:
   mlockall
 setuid
 daemon
  ...child process...
 init

To :
daemon
 ...child process ...
mlockall
setuid
init

This made -d to work with -k.

The reason is that forked child process does not inherit mlock.  The modified 
code worked as expected on Solaris 10 and Linux 2.6.x .

Let me know any downside of the change.

-  Gary

Reply via email to