[comp.sys.apollo] Problems with login scripts!

pfuetz@zgdvda.UUCP (Matthias Pfuetzner) (07/02/90)

Hallo!

I have  a problem with  SR 10.2  and  the startup scripts.   It is the
following:

I'm trying to setup standard login and logout files for users who wish
to work only with the  X environment on our DN10000.   Due to the fact
that most of the   users  prefer using standard Apollo  loginsequences
(and DM-pads) these need to be solved on a per-user basis.  So what is
to be done:

1.) set screen to mono in order  to make it  behave  like a real xterm
    (otherwise xterm sometimes get colored backgrounds).
2.) delete all processes and associated windows (DM-pads).
3.) hand background over to X.
4.) create an xterm upon termination of which the  user will be logged
    out.
5.) remove the DM input and output pads.
6.) terminate DM.

At logout the reverse actions have to be performed:

7.) hand background back to DM.
8.) turn DM  on again.
9.) redisplay DM input and output pads.
10.) reload colormap.
11.) reassign the standard keys.
12.) send a HUP (hangup) signal to the always running Xapollo (Xapollo
     is started at boot time from /etc/rc and keeps running permantly)

What I've done up to now results in the following:

~/user_data/startup_dm.1280color: (the per-user login-file)
=====
mono -on
wc -a;dq -s;tn
wc -a;dq -s;tn
wc -a;dq -s
cpo /usr/bin/X11/xownroot -on
cpo /bin/csh -c '/usr/bin/X11/xterm;/usr/apollo/bin/xdmc lo'
dmio -off
wmgr -off
=====
/sys/dm/startup_logout.1280color: (the standard logout-file executed
on every logout)
=====
/usr/bin/X11/xownroot -off
wmgr -on
dmio -on
/usr/apollo/bin/lcm
/usr/apollo/bin/kbm -r
/bsd4.2/bin/csh -c 'kill -1 `ps ax | grep Xapollo | grep -v grep | awk '{print $1}'`'
=====

These things do what I want them to do, only the line reading

cpo /bin/csh -c '/usr/bin/X11/xterm;/usr/apollo/bin/xdmc lo'

doesn't do what I want.  When executed it skips the  command to logout
the user when the xterm is finished and  leaves me  with a screen only
containing the  X-background. I have no  access  to the  DM  input and
output   pads because they    were   disabled  by   the   login-script
(user.server.none!) and not $USER!. But when I convert this line to

cp /bin/csh -c '/usr/bin/X11/xterm;/usr/apollo/bin/xdmc lo'

e.g. converting cpo to cp, it executes the logout upon termination of
the xterm. So my question now is:

Why does the cpo command do things different from the cp command?
How can I get these login scripts to work?

Any help will be highly appreciated.
Thanks in advance,
Sincerly,
	Matthias Pfuetzner
-----
            @work:            | Matthias Pfuetzner  |         @home:
  ZGDV, Wilhelminenstrasse 7  | 6100 Darmstadt, FRG |  Lichtenbergstrasse 73
    +49 6151 155-164 or -101  \    <- Tel.nr. ->    /     +49 6151 75717
   pfuetzner@agd.fhg.de    pfuetzner@zgdvda.UUCP    XBR1YD3U@DDATHD21.BITNET

-- 
            @work:            | Matthias Pfuetzner  |         @home:
  ZGDV, Wilhelminenstrasse 7  | 6100 Darmstadt, FRG |  Lichtenbergstrasse 73
   +49 6151 1000-164 or -101  \    <- Tel.nr. ->    /     +49 6151 75717
   pfuetzner@agd.fhg.de    pfuetzner@zgdvda.UUCP    XBR1YD3U@DDATHD21.BITNET