home *** CD-ROM | disk | FTP | other *** search
- Comments: Gated by NETNEWS@AUVM.AMERICAN.EDU
- Path: sparky!uunet!paladin.american.edu!auvm!NETCOM.COM!ANTIGONE!MROSS
- Message-ID: <9212251039.AA00321@antigone.com>
- Newsgroups: bit.listserv.next-l
- Date: Fri, 25 Dec 1992 02:39:25 -0800
- Reply-To: mross@antigone.com
- Sender: NeXT Computer List <NEXT-L@BROWNVM.BITNET>
- From: Michael Ross <antigone!mross@NETCOM.COM>
- Subject: Modifying rc.local
- Lines: 50
-
- I'm really confused.
-
- I'm trying to get a program to execute when I turn the NeXT on. This
- program, 'start', spawns a daemon 'serverd' and must be run by the
- user 'server'. I have added a line to /etc/rc.local so that it looks
- like this:
-
- #####################################
- # Read in configuration information
- . /etc/hostconfig
-
- (echo -n 'local daemons:')
- >/dev/console
- #
- # Run your own commands here
- #
- su server -c '/usr/server/start -cr >/dev/console' && (echo -n '
- listserv') >/dev/console
- #
- #
- (echo '.')
- >/dev/console
- ####################################
-
- During the boot process, the console echoes 'local daemons:', the
- output of the start program, and the final '.' properly. However '
- listserv' never appears, meaning the previous su... was unsuccessful.
- And, indeed, the daemon spawned by 'start' is no longer is the list
- of processes running (seen with 'ps -ax') when I first login.
-
- The frustrating thing is that the su.... line works fine when
- executed from a Terminal shell as root!
-
-
- Can anyone tell me why this process is dying at startup and what can
- I do to the rc.local file to make it stay? It looks like either when
- the 'su' subshell exits, it kills all processes it has spawned, or su
- is returning an exit error code, but not 'saying' anything to the
- console....
-
- Thanks for any suggestions and.... MERRY CHRISTMAS!!!!
-
- Michael
-
- ---
- Michael Ross
- Antigone Press, San Francisco, California
- e-mail: mross@antigone.com
- FAX: 1-415-431-3650
- ---
-