|
From: rajiv s. <wo...@ya...> - 2003-01-16 03:40:32
|
Hi guys, Awesome work.. I do have a few questions/suggestions regarding the way wrapper runs as a daemon on un*x. It could be that I have totally misunderstood the situation, please help me out if that is the case. The documentation says ' There are not any differences between running as a service vs as a console application in a Unix environment.', and looking at the example sh and bash scripts supplied, the process is started by putting it in the background (using an &). Doing that will work if (and only if) the controlling terminal does not send the process a SIGHUP. For example, if you telnet to a solaris host, and the default login shell of the person you are logging in as is sh (not bash), and you then su and /etc/init.d/script start: the process will be put in the background, but when you log out, the process WILL be killed. However, the way unix startup scripts typically work is to just execute the process with a flag to tell it to become a daemon (not backgrounded). The process is then responsible for forking and putting itself in the background. I made some changes to wrapper_unix.c and started wrapper with the additional parameter wrapper.isunixdaemon=true, and it seems to solve the issue. (I have enclosed my changes within 'Begin Rajiv's changes' and 'End Rajiv's changes') I hope I didn't totally miss something.. Again, folks, great work! best regards, Rajiv __________________________________________________ Do you Yahoo!? Yahoo! Mail Plus - Powerful. Affordable. Sign up now. http://mailplus.yahoo.com |