On 9/06/2010 22:02, Mark Edwards wrote: > I saw that, but afterwards Aristoteles suggested using sudo, so I thought > perhaps there was a way to achieve it. > > So am I correct that the choice is between: > > 1) Running ASSP as root, not running as a service, and being able to restart > itself > > 2) Running ASSP as non-root user, running as a service, and not being able to > restart itsel
I've just tested the following on version 1.7.5.1(1.0.08): AsAService:= AsADaemon:= runAsUser:=nobody runAsGroup:=nogroup AutoRestart:=1 AutoRestartCmd:=sudo /etc/init.d/assp restart AutoRestartAfterCodeChange:= Then sudoers has: nobody ALL=(ALL) NOPASSWD: /etc/init.d/assp After enabling the following on the ASSP configuration: RestartEvery:=10 I can see the entries on auth.log: Jun 10 11:11:12 assp sudo: nobody : TTY=unknown ; PWD=/usr/local/assp ; USER=root ; COMMAND=/etc/init.d/assp restart Jun 10 11:11:25 assp sudo: nobody : TTY=unknown ; PWD=/usr/local/assp ; USER=root ; COMMAND=/etc/init.d/assp restart Jun 10 11:11:42 assp sudo: nobody : TTY=unknown ; PWD=/usr/local/assp ; USER=root ; COMMAND=/etc/init.d/assp restart Jun 10 11:11:55 assp sudo: nobody : TTY=unknown ; PWD=/usr/local/assp ; USER=root ; COMMAND=/etc/init.d/assp restart Jun 10 11:12:08 assp sudo: nobody : TTY=unknown ; PWD=/usr/local/assp ; USER=root ; COMMAND=/etc/init.d/assp restart Jun 10 11:12:21 assp sudo: nobody : TTY=unknown ; PWD=/usr/local/assp ; USER=root ; COMMAND=/etc/init.d/assp restart Jun 10 11:12:34 assp sudo: nobody : TTY=unknown ; PWD=/usr/local/assp ; USER=root ; COMMAND=/etc/init.d/assp restart Which shows that it is working. Since I do not use Service or Daemon (I also don't use autorestart) Fritz's comment is probably correct that if it runs as a service or daemon, this wont work. I can also see a problem with busier installations which will depend on the init script you use. The one in the wiki will send a kill command and start it back up straight away, which may mean that the ports may have not yet been released by the process you just killed and thus the new process wont be able to bind to them. -- Best Regards, Neto Web Drive Limited ============================ web: www.webdrive.co.nz eml: n...@webdrive.co.nz nzl: 0800 932 374 int: +64 9 477 0055 ============================ ------------------------------------------------------------------------------ ThinkGeek and WIRED's GeekDad team up for the Ultimate GeekDad Father's Day Giveaway. ONE MASSIVE PRIZE to the lucky parental unit. See the prize list and enter to win: http://p.sf.net/sfu/thinkgeek-promo _______________________________________________ Assp-user mailing list Assp-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/assp-user