Yes, not a simple problem. I'm using a line like : su --command=${zopePath}/start zope &> ${zopePath}/var/start-init.log & in the start/stop file : /etc/rc.d/init.d/zope I join my Zope sysinit script to this mail. Perhaps continuing the thread to fine a great solution ;o) cyrille Mike Renfro a écrit:
On Fri, Jan 03, 2003 at 05:40:55PM +0100, cyrille wrote:
Mike Renfro a écrit:
On Fri, Jan 03, 2003 at 04:24:43AM -0400, beno wrote:
I seem to have run into this problem before but I don't remember how to fix it. I start my Zope with: ./start -u www & but it doesn't go into a background process. When I close the shell (or lose my Internet connection) Zope crashes (2.6.x, RH7.2). What to do?
man nohup
I think nohup is not the answer :
Actually, it probably is the answer. Not the only answer, but a valid one nonetheless. See below for what he'll end up using to make it work:
`nohup' does not automatically put the command it runs in the background; you must do that explicitly, by ending the command line with an `&'.
The problem he's getting is that Zope is trying to write some sort of debugging message, warning, or something similar to its controlling TTY. He may also see IOError exceptions before Zope crashes, or as it's crashing. At least core Zope 2.5.1 spits out a warning about a deprecated regex interface every time you start or restart it.
When the controlling TTY is gone (he logs out or loses his connection), Zope will eventually die as a result of not being able to write these messages. This is apparently fixed in 2.6, but I've not installed that anywhere to verify it.
As for me, I have Zope run as part of the system startup, so it'll spew these messages to /dev/tty1 as long as I don't restart the init script from a shell prompt. If I do need to restart Zope without using the Restart button in the control panel, I make sure that I'm either on the machine's physical console, or else that I'm restarting it from inside a 'screen' session I keep running 24/7 on the system.
Prior references at http://zope.nipltd.com/public/lists/zope-archive.nsf/Main?SearchView=&Query=... -- and if Dieter agrees with me, it must be correct, right?