Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

INN 1.4 and HP-UX 9.05 on reboot

0 views
Skip to first unread message

Mario Piazzese

unread,
May 1, 1996, 3:00:00 AM5/1/96
to

Does anyone know have to get INN running on reboot on HP-UX 9.05?

I have the following entry in /etc/rc in the function localrc():
# Start the News Server
if [ -x /usr/local/etc/rc.news ]; then
echo "Starting Internet News Server..."
su news -c /usr/local/etc/rc.news >/dev/console
fi

On reboot the line "Starting Internet News Server..." is printed out
yet the server does not start. If I enter the line as root is does
start.
--
Mario Piazzese - Senior Systems Engineer, ULTRADATA Australia Pty. Ltd.
1919 Malvern Road, East Malvern, Victoria, Australia 3145.
P.O. Box 42, Carnegie, Victoria, Australia, 3163.
Voice: +61-3-9885-2211, Fax: +61-3-9885-2222

Chris Lewis

unread,
May 1, 1996, 3:00:00 AM5/1/96
to

In article <3186A9...@ultradata.com.au>,

Mario Piazzese <m...@ultradata.com.au> wrote:
>Does anyone know have to get INN running on reboot on HP-UX 9.05?
>
>I have the following entry in /etc/rc in the function localrc():
> # Start the News Server
> if [ -x /usr/local/etc/rc.news ]; then
> echo "Starting Internet News Server..."
> su news -c /usr/local/etc/rc.news >/dev/console
> fi
>
>On reboot the line "Starting Internet News Server..." is printed out
>yet the server does not start. If I enter the line as root is does
>start.

Nohup the su:

nohup su news -c /usr/local/etc/rc.news >/dev/console

Parts of the server take a while to start, and when /etc/rc terminates,
it essentially kills all child process groups.
--
Chris Lewis: _Una confibula non sat est_

Dan Smisko

unread,
May 9, 1996, 3:00:00 AM5/9/96
to

Mario Piazzese (m...@ultradata.com.au) wrote:
: Does anyone know have to get INN running on reboot on HP-UX 9.05?

: I have the following entry in /etc/rc in the function localrc():
: # Start the News Server
: if [ -x /usr/local/etc/rc.news ]; then
: echo "Starting Internet News Server..."
: su news -c /usr/local/etc/rc.news >/dev/console
: fi

: On reboot the line "Starting Internet News Server..." is printed out
: yet the server does not start. If I enter the line as root is does
: start.

I had the same problem on various versions of HP-UX.

First thing, you need to be root to open the nntp port. Inndstart
does this, so I made it setuid root. This is mentioned in Install.ms.

Another glitch is that the rc.news script does "su news". If you are
already news, it asks for a password. This does not work well
unattended. So I set the variable NEWSEXEC to "su news" or "/bin/sh"
if I'm root or news, respectively.

The method that rc.news uses to start innwatch doesn't (or didn't)
work on hpux for some reason. I've seen it mentioned elsewhere. This
has also been changed.

I also put in a hack to allow rc.news to be called from innwatch,
without starting another innwatch or clobbering its lock file.

This is probably more than you want, but here's the diffs from the
original in inn1.4-sec.


Dan Smisko

11c11
< DOINNWATCH=false
---
> DOINNWATCH=${1:-true}
16c16
< FLAGS="-i0"
---
> FLAGS="-i0 -x"
17a18,27
> : ${SHELL:=`sed -n '/^news/s/.*://p' /etc/passwd`}
> if [ `whoami` = root ] ; then
> NEWSEXEC="su ${NEWSUSER}"
> elif [ `whoami` = ${NEWSUSER} ] ; then
> NEWSEXEC=$SHELL
> else
> echo Can\'t execute as `whoami`
> exit 1
> fi
>
53c63
< # && mv history.n.pag history.pag" | su ${NEWSUSER}
---
> # && mv history.n.pag history.pag" | ${NEWSEXEC}
58c68,71
< ( cd ${LOCKS} && rm -f LOCK* )
---
> ( cd ${LOCKS} &&
> for i in LOCK* ; do
> ${DOINNWATCH} || [ -z "$1" ] || [ "$i" != LOCK.innwatch ] && rm -f "$i"
> done )
66,69c79,80
< # Gee, looks like lisp, doesn't it?
< ${DOINNWATCH} && {
< echo "( ( sleep 60 ; ${INNWATCH} ) & )" | su ${NEWSUSER}
< }
---
> ${DOINNWATCH} &&
> $SHELL -c "nohup $NEWSEXEC -c \"sleep 60 ; ${INNWATCH}\" <&- >&- 2>&- &"
78c89
< echo "${NEWSBIN}/expirerm ${RMFILE}" | su ${NEWSUSER} &
---
> $SHELL -c "nohup $NEWSEXEC -c \"${NEWSBIN}/expirerm ${RMFILE}\" <&- >&- 2>&- &"

Steve Howie

unread,
May 10, 1996, 3:00:00 AM5/10/96
to

Dan Smisko (smi...@lf.hp.com) wrote:

: Mario Piazzese (m...@ultradata.com.au) wrote:
: : Does anyone know have to get INN running on reboot on HP-UX 9.05?
:
: : I have the following entry in /etc/rc in the function localrc():
: : # Start the News Server
: : if [ -x /usr/local/etc/rc.news ]; then
: : echo "Starting Internet News Server..."
: : su news -c /usr/local/etc/rc.news >/dev/console
: : fi
:
: : On reboot the line "Starting Internet News Server..." is printed out
: : yet the server does not start. If I enter the line as root is does
: : start.
:
: I had the same problem on various versions of HP-UX.

We had the same problem too. Solution is to make absolutely sure you have
HAVE_SETSID set to "DO" in your config.data file. That fixes the problem.

Scotty
=================================================================
Steve Howie Email: sho...@uoguelph.ca
NetNews and Listserv Admin. Phone: (519) 824-4120 x2556
Computing and Communications Svcs. Fax: (519) 763-6143
University of Guelph

If it's not Scottish its CRRRRRAAAAAAAAAAAAAAPPPPP
=================================================================


Neal Becker

unread,
May 14, 1996, 3:00:00 AM5/14/96
to

Just to make things interesting, I also run inn1.4 (actually,
inn1.4unoff4) on hpux9.05. I *don't* have any of the cited problems.

0 new messages