-
Notifications
You must be signed in to change notification settings - Fork 5.5k
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
pidfile support for minion and master daemons #563
Comments
Hi chutz, that is an easy request, I will get it into the next release |
Thanks, let me know once it's in git so I can pull the patch and apply it in the ebuild. That way I can finish up the init scripts and add it to Gentoo right away. |
Will do, we want to be in portage! |
Just curious, how do you do this on gentoo for multiple pids? The master generally starts multiple worker processes and they each have different pids. Do you just put the parent's pid in the pidfile or all of them? |
Generally you just put the master's PID in the file, then have the master make sure that all the children are terminated before it terminates. |
I am having an issue cleanly killing all the children, the pidfile now has all master process pids |
Tom: Perhaps you should just get the process group id, and then intercept the I know in non-python shell scripts, this is how I would do it. Use ps magic to get the process group id and then send a signal to the entire process group instead of individual pids. |
Good call, I had not tried this approach yet, I had been trying to manage the multiprocesses when catching the signal, I will give this a shot, thanks! Yes, we do want the master to clean the children! |
Yeah this should work. It is the "proper" way to do this sort of thing on Linux at least. |
We have updated this all to have a single pid in pidfiles and for the main pid on the master to cleanly kill all the other processes. IS this still an issue? |
Should be fixed in git and will be in 0.9.8 |
…the actual providers. Fixes saltstack#563.
Hi, I am working on a Gentoo package, and as such I am making init scripts for the minion and master daemons. Without an option for a pid file, it's a little tricky to write a proper working init script.
Probably the most straightforward approach is to add a --pidfile option to give the location to write the file.
The text was updated successfully, but these errors were encountered: