Partially answer some part of my question
Question: Is it necessary to write/define stop and restart in God configuration
Answer Well not really you can define your own command but if in case you dont define there is default lambda
for stop
and restart
Straight from GOD documentation
Question: If the process is explicity move to background will GOD still monitor it for command like stop|restart etc
Answer: Answer is YES and NO , No because if you dont give GOD the pid
file to monitor it will not monitor the process running in background
Again from GOD documentation
Question: If :process_running is a set of conditions what other conditions does start_if
contains also what c.running = false (internally do)
Answer: Well I will answer this question in 2 parts
What other conditions does
start_if
contains ?Ans:
Well the best place to look that is under conditions directory of god check over here there isprocess_running
condition also existsWhat c.running = false (internally do)?
Ans:
Well c.running is internally used to check (the check is perform with respect to process id and running variable) whether a process was running prior whengod
start so if the process i.e(c.running = true) is running and thepid
file pointed has the corrected all work well but if thec.running = true
andpid
monitored is different or does not exist it keep looping hence it advisable to usec.running = true
only if the process was already running and correctpid_file
(with correctpid
in it is) is define in god file . One can check that over here
Note: Accepting my answer since only one question is left and I believe it was mostly not working because of my wrong doing (i.e the pid wasn't getting stored in desired directory) :) Rest all question are answered by me.