[comp.os.vms] SET HOST Problem

mberkley@watnext.waterloo.edu (Mike Berkley) (07/15/88)

(I'm posting this for a friend.  He can read comp.os.vms, but cannot
post, so you can either post followups or send email to me.)

I'm having a problem with the SET HOST command.  Our uVAX II
(VMS 4.7) is connected to a dozen non-VMS computers, and I want
to connect my VT220 terminal to any of those systems.  The command

	$ SET HOST/DTE $TERMINAL1

works fine at the VMS level (i.e. my VT220 becomes a terminal
for the remote machine).  The problem is that it doesn't work
from within a command (DCL) file.  It exits with the message:

	%REM-F-NOTERM, command device is not a terminal

I want to do it from DCL because I would like to put up a menu of the
systems the user can connect to.

Note the /DTE (Data Terminal Equipment) option - I think that this is
causing the problem.  (A friend of mine tried "SET HOST" (no /DTE)
on his machine to another VMS machine over DECnet, and it works okay).

Any suggestions would be most appreciated!!

gil@limbic.UUCP (Gil Kloepfer Jr.) (07/18/88)

In article <5202@watcgl.waterloo.edu> mberkley@watnext.waterloo.edu (Mike Berkley) writes:
|>	$ SET HOST/DTE $TERMINAL1
|>
|>works fine at the VMS level (i.e. my VT220 becomes a terminal
|>for the remote machine).  The problem is that it doesn't work
|>from within a command (DCL) file.  It exits with the message:
|>
|>	%REM-F-NOTERM, command device is not a terminal

Yeah, I had the same problem.

First off, if you are running this from a command file, recall that SYS$INPUT
is *NOT* your terminal, but rather the command file itself.  Therefore what
you want to do is:

	$ DEFINE/USER SYS$INPUT SYS$COMMAND

right before you execute the SET HOST/DTE command.  The error message you are
getting is not refering to the $TERMINAL1 necessarily, but the terminal
connected to SYS$INPUT (which is a file not a terminal)...

Hope this helps!

+------------------------------------+----------------------------------------+
| Gil Kloepfer, Jr.                  | Net-Address:                           |
| ICUS Software Systems              | {boulder,talcott}!icus!limbic!gil      |
| P.O. Box 1                         | Voice-net: (516) 968-6860              |
| Islip Terrace, New York  11752     | Othernet: gil@limbic.UUCP              |
+------------------------------------+----------------------------------------+

"James_A._Gray.OsbuSouth"@XEROX.COM (07/23/88)

Sorry for the wide distribution but I'm unable to reply directly to:
tt!chinet!mcdchg!clyde!watmath!watcgl!watnext!mberkley@ucbvax.Berkeley.EDU

Simply said, you need to be able to use SET HOST/DTE from within a command
procedure.  I use the following one with great success.  Actually I have more
than one, one for each terinal line since I don't type well.  Once you're done
with the line, just DEALLOCATE DET_TERMINAL to not only free the line but also
to hang it up.

Good luck.

	Jim Gray


$ VERIFY='F$VERIFY(0)
$ ALLOCATE/NOLOG TXA0: DTE_TERMINAL
$ DEFINE/NOLOG KER$COMM DTE_TERMINAL
$ SET TERMINAL DTE_TERMINAL/SPEED=1200/HANGUP
$ DEFINE/USER_MODE SYS$INPUT SYS$COMMAND
$ DEFINE/USER_MODE SYS$OUTPUT SYS$COMMAND
$ DEFINE/USER_MODE SYS$ERROR SYS$COMMAND
$ SET HOST/DTE DTE_TERMINAL
$ VERIFY=F$VERIFY(VERIFY)

carl@CITHEX.CALTECH.EDU (Carl J Lydick) (08/05/88)

 > I'm having a problem with the SET HOST command.  Our uVAX II
 > (VMS 4.7) is connected to a dozen non-VMS computers, and I want
 > to connect my VT220 terminal to any of those systems.  The command
 > 
 > 	$ SET HOST/DTE $TERMINAL1
 > 
 > works fine at the VMS level (i.e. my VT220 becomes a terminal
 > for the remote machine).  The problem is that it doesn't work
 > from within a command (DCL) file.  It exits with the message:
 > 
 > 	%REM-F-NOTERM, command device is not a terminal
 >
 > I want to do it from DCL because I would like to put up a menu of the
 > systems the user can connect to.
 > 
 > Note the /DTE (Data Terminal Equipment) option - I think that this is
 > causing the problem.  (A friend of mine tried "SET HOST" (no /DTE)
 > on his machine to another VMS machine over DECnet, and it works okay).

SET HOST used to do the same thing before they invented SET HOST/DTE.  The
problem is that SET HOST/DTE wants to talk to you via the file SYS$INPUT.
When you execute a DCL procedure from an interactive job, that procedure
becomes SYS$INPUT.  Your terminal remains SYS$COMMAND.  The workaround is
to redirect SYS$INPUT before activating the image.  The following works:

	$ DEFINE/USER_MODE SYS$INPUT SYS$COMMAND
 	$ SET HOST/DTE $TERMINAL1