Re: [WebDNA] RESTART WebDNA
This WebDNA talk-list message is from 2016
It keeps the original formatting.
numero = 113194
interpreted = N
texte = 782I would suggest to create a new file called /etc/sudoers.d/webdna , and =put this inside:Defaults        !authenticate%www-data ALL=3D/etc/init.d/WebCatalogCtlThen chmod 0440 /etc/sudoers.d/webdna . Use the follow WebDNA code with =it:[SHELL]sudo /etc/init.d/WebCatalogCtl restart &[/SHELL]> WebdnaMonitor utilizes a file that contains the process ID of the =running engineWhen WebCatalog is started with the -m argument, it does not create the =WebCatalog.pid file. Instead the WebDNAMonitor creates it, and puts its =own PID in it:# cat /usr/lib/cgi-bin/WebCatalogEngine/WebCatalog.pid15568# ps aux|grep 15568root     15568  0.0  0.0   4288   608 pts/17   S    12:28   0:00 =/usr/lib/cgi-bin//WebCatalogEngine/WebDNAMonitorThe bug is that the WebCatalog.pid file is deleted by WebCatalog on a =clean exit regardless of whether or not it created it. It should not do =this if -m was passed.> if the running engine is killed (i.e. Not usually the best way to stop =any application)This is how WebCatalogCtl and WebDNAMonitor stop WebCatalog. It sends it =a INT signal, which goes through the same handler as TERM so there is no =difference.What you want to avoid is sending SIGKILL (aka signal 9), that is =closest to force-quitting an application from the OSX GUI. The =application isn't able to run any signal handlers and do a graceful =shutdown, as signal 9 cannot be caught."killall" will send a TERM signal by default, which WebCatalog will =catch and use to gracefully shutdown by running CleanExit(0).> there will likely end up being a mismatch between the monitor and the =engine. Then what will happen is rogue instances of the engine.Yeah you are right. Since WebCatalog deletes the WebCatalog.pid file =when it exits, the WebCatalogCtl script stops working.- chris> On Nov 18, 2016, at 21:03, Donovan Brooke 
 wrote:>=20> WebdnaMonitor utilizes a file that contains the process ID of the =running engine.. if the running engine is killed (i.e. Not usually the =best way to stop any application), there will likely end up being a =mismatch between the monitor and the engine. Then what will happen is =rogue instances of the engine.=20>=20> A better idea to give people the power to control WebDNA and restarts =of the server would be to build a separate and optional WebDNA server =control app perhaps, that utilizes root capabilities... but there is =already an app for that... called shell, or terminal.>=20> D. Brooke Mobile---------------------------------------------------------This message is sent to you because you are subscribed tothe mailing list .To unsubscribe, E-mail to: archives: http://mail.webdna.us/list/talk@webdna.usBug Reporting: support@webdna.us.
Associated Messages, from the most recent to the oldest:
782I would suggest to create a new file called /etc/sudoers.d/webdna , and =put this inside:Defaults        !authenticate%www-data ALL=3D/etc/init.d/WebCatalogCtlThen chmod 0440 /etc/sudoers.d/webdna . Use the follow WebDNA code with =it:[shell]sudo /etc/init.d/WebCatalogCtl restart &[/SHELL]> WebdnaMonitor utilizes a file that contains the process ID of the =running engineWhen WebCatalog is started with the -m argument, it does not create the =WebCatalog.pid file. Instead the WebDNAMonitor creates it, and puts its =own PID in it:# cat /usr/lib/cgi-bin/WebCatalogEngine/WebCatalog.pid15568# ps aux|grep 15568root     15568  0.0  0.0   4288   608 pts/17   S    12:28   0:00 =/usr/lib/cgi-bin//WebCatalogEngine/WebDNAMonitorThe bug is that the WebCatalog.pid file is deleted by WebCatalog on a =clean exit regardless of whether or not it created it. It should not do =this if -m was passed.> if the running engine is killed (i.e. Not usually the best way to stop =any application)This is how WebCatalogCtl and WebDNAMonitor stop WebCatalog. It sends it =a INT signal, which goes through the same handler as TERM so there is no =difference.What you want to avoid is sending SIGKILL (aka signal 9), that is =closest to force-quitting an application from the OSX GUI. The =application isn't able to run any signal handlers and do a graceful =shutdown, as signal 9 cannot be caught."killall" will send a TERM signal by default, which WebCatalog will =catch and use to gracefully shutdown by running CleanExit(0).> there will likely end up being a mismatch between the monitor and the =engine. Then what will happen is rogue instances of the engine.Yeah you are right. Since WebCatalog deletes the WebCatalog.pid file =when it exits, the WebCatalogCtl script stops working.- chris> On Nov 18, 2016, at 21:03, Donovan Brooke  wrote:>=20> WebdnaMonitor utilizes a file that contains the process ID of the =running engine.. if the running engine is killed (i.e. Not usually the =best way to stop any application), there will likely end up being a =mismatch between the monitor and the engine. Then what will happen is =rogue instances of the engine.=20>=20> A better idea to give people the power to control WebDNA and restarts =of the server would be to build a separate and optional WebDNA server =control app perhaps, that utilizes root capabilities... but there is =already an app for that... called shell, or terminal.>=20> D. Brooke Mobile---------------------------------------------------------This message is sent to you because you are subscribed tothe mailing list .To unsubscribe, E-mail to: archives: http://mail.webdna.us/list/talk@webdna.usBug Reporting: support@webdna.us.
christophe.billiottet@webdna.us
DOWNLOAD WEBDNA NOW!
Top Articles:
Talk List
The WebDNA community talk-list is the best place to get some help: several hundred extremely proficient programmers with an excellent knowledge of WebDNA and an excellent spirit will deliver all the tips and tricks you can imagine...
Related Readings:
 
WebCat2b14MacPlugIn - [include] doesn't hide the search string (1997)
 
Thanks for tips, more quest (1997)
 
Insufficient memory, etc-looking more and more like a bug... (2000)
 
Time Tracking (2003)
 
WebCat2b13MacPlugIn - [include] (1997)
 
Appending Record Prob (2001)
 
Setting up shop (1997)
 
CASTEGORIES IN DIFFERENT FRAMES (1997)
 
AutoReload?  RequireComment?  InterpretAll? (1999)
 
Re:HELP - NONE STOP DIGESTS. Digest for 4/24/97) (1997)
 
Initiating NewCart (1997)
 
creator code (1997)
 
help needed w/ search params (1998)
 
 Follow-up to listfiles bug report ... (2003)
 
[ModDate] & [ModTime] ? (1997)
 
WebCat2 - storing unformatted date data? (1997)
 
 TPL Asks For Authentication (2004)
 
WC TableGrinder (1997)
 
why .HTML pages no processing? (2000)
 
Running 2 two WebCatalog.acgi's (1996)