Copyright 1991-2016 by Kevin G. Barkes All rights reserved. This article may be duplicated or redistributed provided no alterations of any kind are made to this file. This edition of DCL Dialogue is sponsored by Networking Dynamics, developers and marketers of productivity software for OpenVMS systems. Contact our website www.networkingdynamics.com to download free demos of our software and see how you will save time, money and raise productivity! Be sure to mention DCL Dialogue! DCL DIALOGUE Originally published May 1991 Wired By Kevin G. Barkes With the explosion of on-line information services, more and more VMS users want to be able to escape the confines of their machines and dial into other systems. Unfortunately, you just can't plug a modem into one of your VAX's serial ports and start demon dialing. You have to configure both the modem and the port in order to make the connection successful. SAY WHAT? Working with the SET TERMINAL command is often a frustrating experience, because its command qualifiers don't precisely do what their names imply. Take SET TERMINAL/DIALUP. One might be led to believe this command will automatically configure your modem port for dialout. In actuality, the DIALUP/NODIALUP qualifiers are security-related and have nothing to do with communication parameters. Say you're the system manager and you're paranoid about users trying to access your system at night through your dialup lines. You want to make certain you're the only one who can get in, using the SYSTEM account. Your first step is to run AUTHORIZE and change everyone's ACCESS to NODIALUP, then change SYSTEM back to DIALUP. UAF> MODIFY [*,*] /ACCESS/NODIALUP UAF> MODIFY [SYSTEM] /ACCESS/DIALUP Next, modify your site-specific startup file so that the port connected to your modem is set as a dialup port: $ SET TERMINAL/PERM/DIALUP TXA4: By identifying TXA4 as a dialup port, VMS will look in the SYSUAF.DAT file everytime someone logs in and will check the status of the user's DIALUP access flag. Unless it's SYSTEM on the phone, the user will see the message: You are not authorized to login from this source HANGING ON Another common misconception is that SET TERMINAL's /DISCONNECT and /NODISCONNECT qualifiers control whether or not VMS kills off a process when the phone connection to the port is dropped. They do, but only for virtual terminals. Briefly, virtual terminals are enabled by running SYSGEN and issuing the command: SYSGEN> CONNECT VTA0/NOADAPTER/DRIVER=TTDRIVER Any port which has been set with SET TERM/DISCONNECT will be treated by the system as a virtual terminal. If a user is disconnected from the virtual terminal, VMS keeps the process active instead of killing it off. You can dial back, log in, and receive the message: You have the following disconnected process: Terminal Process name Image name _VTA190 KGB (None) Connect to above listed process [YES]: You can only connect to a virtual terminal process that has your UIC, so the setup affords some additional security, but only on systems where the VAX is able to detect that your end of the connection dropped. Which brings us to: /MODEM/NOMODEM These SET TERM qualifiers also are a bit misleading. When you set a port to /NOMODEM, for example, you're not telling the VAX that no modem is connected. Rather, you're telling it not to assert and/or recognize the Request To Send (RTS) and Data Terminal Ready (DTR) RS-232 signals on the port. Normally, you'd want to set dialup ports to /MODEM. Doing so allows the VAX to "see" what the modem is doing and respond accordingly. For example, a port set to /MODEM which has the Clear To Send (CTS), Data Set Ready (DSR) and Data Carrier Detect (DCD) signals applied to it will be granted the REMOTE characteristic. You can't issue a SET TERM/REMOTE command; the VAX decides if the port has the proper configuration to qualify for the characteristic. (This is a quick way to determine whether your modem is asserting the proper signals to the serial port, using the SHOW TERMINAL command.) /MODEM is also necessary for SET TERM's /HANGUP qualifier to work. /HANGUP causes the VAX to momentarily drop DTR to the modem which, if configured properly, will then hang up the phone when the user logs out or the connection is severed. /HANGUP is generally used to make certain the modems are disconnected when a user logs out; otherwise, the call isn't interrupted and the phone link remains intact. Take it from someone who's had to deal with three-figure telephone bills. You want /HANGUP enabled. There's only one problem with this MODEM/NOMODEM business. Not all VAX serial ports support modem control signals, like the ones on my VAXstation 3100. Set the ports on this baby to /MODEM, and when you try to log in you'll see VAX/VMS host wired incorrectly - contact your system manager. This message appeared in Version 5 of VMS, when many system managers learned for the first time that DZs didn't support modem signals, and only the first two ports of a DMF did. This problem doesn't prevent you from using these ports for dialup operations... you just have to set them to /NOMODEM. There's a potentially serious security problem here, though. If your modem hangs up, the port will not be logged out, even if the modem on the VAX end hangs up as well. That's because the VAX isn't looking for the modem signals that would tell it a disconnect took place. The next person who dials in will be connected to your process; a nasty situation, in some instances. THE DANGERS OF /AUTOBAUD When you set a modem port to /AUTOBAUD, it automatically adjusts its speed to that of the device to which it is connected. Usually. An improperly configured modem can cause a lot of grief with /AUTOBAUD. Let's say you forgot to turn off the modem's response codes, and you dial in. The modem detects your call, and says "RING" to the VAX at, say, 2400 baud. Problem is, you dialing in at 1200. No go. Even worse is the "Aunt Olive/Uncle Roy" syndrome. Someone calls your modem number by mistake. It says "RING" to the VAX. The VAX says "Username:" to the modem. The modem says "ERROR". The VAX says "Password:". The modem says "ERROR". The VAX says "User authorization error". The modem says "ERROR". The VAX says "Username:". You get the idea. Like my elderly, hearing-impaired Aunt Olive and Uncle Roy, the VAX and modem spend the rest of the afternoon engaging in energetic but totally useless conversation. There are several ways around this problem. Disabling modem response codes is probably easiest. The best way out of the situation is to use a modem with buffered i/o which allows the end connected to the VAX to be "locked in" at a specific speed, usually 9600 baud. This permits you to use /NOAUTOBAUD/SPEED=9600. Well, we're out of space, and we've barely scratched the surface of VAX modem connections. More next month. If you're impatient and you'd like more information ASAP, you can search through the VMS Database on DSIN/DSNlink; it contains a number of comprehensive articles on modem configuration and SET TERMINAL qualifiers. *********** When I wrote the RoboVAX system monitor (December, 1990), I purposely left out checks for cpu and memory errors because they're not normally accessible with DCL lexical functions. Cynthia Driscoll of the Webb Institute of Naval Architecture pinned me on this one, though, and specifically asked how to give RoboVAX the ability to check for these error types. Search through SYS$SYSTEM:SYS.MAP and find the references to EXE$GL_MEMERRS and EXE$GL_MCHKERRS. These symbols have the addresses where the longwords containing the number of memory and machine check errors are stored. They vary from version to version of VMS. Under VMS 5.3-1, EXE$GL_MEMERRS is at %x800044F4, while EXE$GL_MCHKERRS is at %x800044F0. Using these addresses, the DCL code for obtaining the counts is: $ MEM_ERR = F$CVUI(0,16,F$FAO("!AD",4,%X800044F4)) $ MCH_ERR = F$CVUI(0,16,F$FAO("!AD",4,%X800044F0)) For an explanation of how the above works, refer to "Raiders of the Global Symbols", which appeared in the September, 1989 issue of the DEC Professional. ******* A frequent complaint of VMS users who must also work on MS-DOS PC systems is the lack of command line recall. The primitive "F3" function just doesn't hack it. There are a number of products on the market which feature this capability, but not many perfectly emulate DCL's RECALL function. One is Boston Business Computing's VCL, which is actually a complete DCL "shell" for MS-DOS and Unix systems. Its only drawback, at least under MS-DOS, is that it takes about 176K of memory and doesn't get along very well with MS-DOS TSR programs. John A. Frederickson of California Street Software has come to the rescue of RECALL junkies with a product called Vkeys. Using only about 22K, Vkeys perfectly emulates DCL RECALL and provides a number of other useful features, including online help and screen color control. And that's all it does. Sometimes less is more. ************************************************* Kevin G. Barkes is publisher of KGB Report. He operates the www.kgbreport.com website, lurks on comp.os.vms, and can be reached at kgbarkes@gmail.com.