[comp.os.vms] "Autologin" issues with DEC VT-1300 X terminals

gjc@mitech.com (03/01/91)

I've been trying to set up some VT-1300 X Terminals in a kind of
always-logged-in mode. (Or rather, set up so that when they boot
they automatically start an application on the remote VAX instead
of going through the DECWINDOWS LOGIN sequence).

Thing are working fairly well, although not 100%, so I'd like to share
my results so far and get some feedback from people who might be
trying to do the same kind of thing.

It is easy to start off along this path. First, modify the file
EWS$LIBRARY:EWS$SERVER.COM, which is executed via a decnet object
running in the context of the username EWS$SERVER after the VT-1300
boots or otherwise starts from "state 0".

After the line              $ CALL CREATE_DISPLAY 'rem_node'
there is usually just this: $ MCR DECW$STARTLOGIN

Instead I've replaced it with:

 $!
 $ F = F$SEARCH("EWS$LIBRARY:" + rem_node + ".COM")
 $ IF F .EQS. "" THEN GOTO START_LOGIN_REGULAR
 $ WRITE SYS$OUTPUT "Executing special command file ''F'"
 $ @'F'
 $ GOTO START_LOGIN_EOJ
 $START_LOGIN_REGULAR:
 $ WRITE SYS$OUTPUT "DECW$STARTLOGIN for ''REM_NODE'"
 $ ASSIGN/USER OPA0: SYS$COMMAND
 $ MCR DECW$STARTLOGIN
 $START_LOGIN_EOJ:
 $! PURGE NETSERVER.LOG/KEEP=5
 $ WRITE/ERROR=WERR1 time_data "$EOJ"
 $ CLOSE time_data
 $ EXIT

Then, say the node-name of your VT-1300 is XTERM1, you could
have the following in the file EWS$LIBRARY:XTERM1.COM:

 $ SET PROC/PRIV=(CMK,SYSPRV)
 $ WS = F$TRN("DECW$DISPLAY")
 $ SUBMIT/USER=ENGINEER/NOPRINT/PARAM=('WS') EWS$LIBRARY:ENGINEER_SM

And the following was my first try at ENGINEER_SM.COM

 $ DEFINE/PROCESS/NOLOG DECW$DISPLAY 'P1'
 $ DEFINE/JOB/NOLOG DECW$DISPLAY 'P1'
 $!
 $ spawn/nowait run sys$system:decw$winmgr
 $ WAIT 00:00:03.00
 $ @SYS$MANAGER:DECW$STARTSM

Just because from accounting records it appeared that the window
manager was started before the session manager. This had some problems
in that the window manager did not seem to be picking up the resources
defined for things like title bar heightlight color. Starting the
window manager *after* the session manager made things happier.

Another problem with this way of starting the session manager
is that it appeared that the server was trying to load the additional
fonts in the font directories specified in XTERM1.DAT over and over
again. 

Next case:

Instead of starting the session manager automatically we can start
an application.

  $ DEFINE/PROCESS/NOLOG DECW$DISPLAY 'P1'
  $ DEFINE/JOB/NOLOG DECW$DISPLAY 'P1'
  $!
  $ spawn/nowait run sys$system:decw$winmgr
  $ WAIT 00:00:03.00
  $ RUN LOCAL_EXE:SOME_APPLICATION

This works fine, except for two things:

(1) The window manager is not getting any resource info, seems to be
    defaulting to some kind of BLACK-AND-WHITE default configuration.
(2) When the application exits the XTERM is left in a lonely state.
    So evidently it is the session manager that tells the VT-1300
    server code some special thing that causes it to invoke the
    network object EWS$SERVER on the remote VAX again.

#2 is not so much of a big problem, because you can always write this:

  $LOOP:
  $RUN LOCAL_EXE:SOME_APPLICATION
  $GOTO LOOP

But #1, *is* a problem.

Am I being an idiot here, just fooling around with these command
procedures via experiment? Is this stuff documented anyplace?

Of course an alternative approach here would be to get a VAXELN
development environment, and make my own modifications to the
boot code for the VT-1300. A special menu that allowed choices of
various applications to invoke on various machines on the net
would be possible goal.


-gjc

p.s. Finally. This brings up the question of WHAT IS AN INTERACTIVE USER
under VMS? Running an application in a BATCH QUEUE does not count
against the "interactive user license" limitation. However, an application
could clearly be a DECTERM, which is obviously somewhat "interactive".

Chris_F_Chiesa@cup.portal.com (03/04/91)

For what it's worth, I use a VT1000 X Terminal via Ethernet to a couple of
MicroVAXes and, security issues permitting, can log into one of these VAXes
from any source, do the appropriate SET DISPLAY/CREATE and CREATE/TERMINAL
commands to create a DECterm window on my VT1000, then --


   -- do an OPEN, READ, and CLOSE on the second of the three new mailbox
devices which appear on the VAX host, and log out of the process from which
I originally created the DECterm window.

  This causes the DECterm window to remain behind, in such a state that
I can use it as a permanent terminal.  That is, I can LOG OUT of it, and
it does NOT disappear (close), and can in fact be logged into and out of
as though it were a permanent terminal connected to that particular VAX.
(Once you've done THAT, it's a simple matter to RUN the appropriate image
to bring up the DECwindows application(s) of your choice.)

Chris Chiesa
  Chris_F_Chiesa@cup.portal.com