Path: utzoo!utgpu!news-server.csri.toronto.edu!bonnie.concordia.ca!thunder.mcrcim.mcgill.edu!snorkelwacker.mit.edu!usc!zaphod.mps.ohio-state.edu!think.com!barmar From: barmar@think.com (Barry Margolin) Newsgroups: comp.unix.admin Subject: Re: Error in SunOS4.1.1 /etc/rc Keywords: su, uucp, /etc/rc, Sun Message-ID: <1991Feb25.215959.23218@Think.COM> Date: 25 Feb 91 21:59:59 GMT References: <4132@gmdzi.gmd.de> Sender: news@Think.COM Organization: Thinking Machines Corporation, Cambridge MA, USA Lines: 35 In article <4132@gmdzi.gmd.de> czech@gmdzi.gmd.de writes: >We're here running some Sun SPARCstations, SunOS 4.1.1. Every time a >machine boots I get an error message: > > su: illegal option -- c > usage: uucico [-xNUM] [-r[0|1]] -sSYSTEM -uUSERID -dSPOOL -iINTERFACE > >The problem is in the startup script /etc/rc. Here are the lines in question: > > if [ -d /usr/lib/uucp ]; then > su uucp -c /usr/lib/uucp/uusched & \ > echo -n ' uucp' > >The line with the 'su uucp' is obviously syntactically wrong. The >argument '-c' is between the user name 'uucp' and the command >'/usr/lib/uucp/uusched'. >The manual page of uusched(8c) gives exactly the same (wrong) syntax. > >Now my question: For what purpose is the '-c' in that line. How should >the line look if it was correct. Did it run under SunOS 4.0.3 or earlier >versions? All the arguments to su after the user name are passed to the subprocess, which is running the user's default shell. That command line assumes that uucp is running a normal shell, which allows the option '-c' to specify a command line to execute. You apparently have uucp's login shell set to uucico, which doesn't support this usage. The passwd file that got installed here when we upgraded to 4.1.1 doesn't specify uucico as its login shell, it lets the shell default. -- Barry Margolin, Thinking Machines Corp. barmar@think.com {uunet,harvard}!think!barmar