Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Path: utzoo!utgpu!water!watmath!clyde!rutgers!ames!ucbcad!ucbvax!CITHEX.CALTECH.EDU!carl From: carl@CITHEX.CALTECH.EDU.UUCP Newsgroups: comp.os.vms Subject: Re: Physical terminal from DCL Message-ID: <870613145308.05q@CitHex.Caltech.Edu> Date: Sat, 13-Jun-87 17:59:42 EDT Article-I.D.: CitHex.870613145308.05q Posted: Sat Jun 13 17:59:42 1987 Date-Received: Mon, 15-Jun-87 03:40:37 EDT Sender: daemon@ucbvax.BERKELEY.EDU Distribution: world Organization: The ARPA Internet Lines: 16 > Does anyone know of a way to obtain the physical terminal name of an > interactive process from DCL? F$getjpi(pid,"TERMINAL") returns the virtual > terminal (if there is one) which is not nearly as useful a piece of > information. I have also noticed that the accounting records also contain > only the virtual terminals for jobs on ports where disconnect is available. > Anyone know of a way to obtain this from accountng.dat?? For the former, use F$GETDVI(F$GETJPI(PID,"TERMINAL"),"TTPHYDEVNAM"). As to the latter, since the information isn't in accounting.dat, there's no way to extract it. You could do something like have your SYS$SYLOGIN: write a record to a file, said record listing PID and physical terminal. This information is of dubious value, since the user may later disconnect, then log in on another physical terminal and connect to the old process. One instance in which it WOULD be very useful is the case of login failures, but in this case, you never get to the SYS$SYLOGIN:, so the information isn't available.