Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

smart-attach-daemon errors when the pidfile is not available #65

Closed
xrmx opened this issue Nov 28, 2012 · 1 comment
Closed

smart-attach-daemon errors when the pidfile is not available #65

xrmx opened this issue Nov 28, 2012 · 1 comment

Comments

@xrmx
Copy link
Collaborator

xrmx commented Nov 28, 2012

With uwsgi-1.4 branch as 092767c with this configuration:

smart-attach-daemon = /proc/unbit/tmp/memcached.pid memcached -s %d/memcached.socket -d -P /proc/unbit/tmp/memcached.pid

if the pid file does not exists it loops here:

[uwsgi-daemons] found changed pidfile for "memcached -s %d/memcached.socket -d -P /proc/unbit/tmp/memcached.pid -u toret" (old_pid: 0 new_pid: -1)
open("/proc/unbit/tmp/memcached.pid"): No such file or directory [core/daemons.c line 96]
open("/proc/unbit/tmp/memcached.pid"): No such file or directory [core/daemons.c line 96]
@xrmx
Copy link
Collaborator Author

xrmx commented Nov 28, 2012

Once i created the pidfile i'm not able to have just one instance of memcached,

[uwsgi-daemons] spawning "memcached -s /www/memcached.socket -d -P /proc/unbit/tmp/memcached.pid -m 50"
[uwsgi-daemons] found changed pidfile for "memcached -s /www/memcached.socket -d -P /proc/unbit/tmp/memcached.pid -m 50" (old_pid: 30985 new_pid: -1)
[uwsgi-daemons] throttling "memcached -s /www/memcached.socket -d -P /proc/unbit/tmp/memcached.pid -m 50" for 1 seconds
[uwsgi-daemons] found changed pidfile for "memcached -s /www/memcached.socket -d -P /proc/unbit/tmp/memcached.pid -m 50" (old_pid: 30986 new_pid: -1)
subprocess 30985 exited with code 0
[uwsgi-daemons] throttling "memcached -s /www/memcached.socket -d -P /proc/unbit/tmp/memcached.pid -m 50" for 2 seconds
[uwsgi-daemons] found changed pidfile for "memcached -s /www/memcached.socket -d -P /proc/unbit/tmp/memcached.pid -m 50" (old_pid: 30989 new_pid: -1)
[uwsgi-daemons] found changed pidfile for "memcached -s /www/memcached.socket -d -P /proc/unbit/tmp/memcached.pid -m 50" (old_pid: 30995 new_pid: 30988)
[uwsgi-daemons] throttling "memcached -s /www/memcached.socket -d -P /proc/unbit/tmp/memcached.pid -m 50" for 3 seconds
[uwsgi-daemons] respawning "memcached -s /www/memcached.socket -d -P /proc/unbit/tmp/memcached.pid -m 50"

@unbit unbit closed this as completed in 5370e53 Nov 28, 2012
unbit added a commit that referenced this issue Nov 28, 2012
Avoid call storming of pidfile check that leads to multiple daemons
running instead of one. Fix #65.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants