A From:	SMTP%"RELAY-INFO-VAX@CRVAX.SRI.COM" 27-MAY-1993 11:10:55.25  To:	EVERHART CC:	% Subj:	Re: Exec, Spawn, Objects in VMS    From: jeh@cmkrnl.com2 X-Newsgroups: comp.sys.dec,comp.os.vms,vmsnet.misc( Subject: Re: Exec, Spawn, Objects in VMS. Message-Id: <1993May26.131430.2072@cmkrnl.com> Date: 26 May 93 13:14:30 PDT0 Organization: Kernel Mode Systems, San Diego, CA	 Lines: 60  To: Info-VAX@kl.sri.com  X-Gateway-Source-Info: USENET   6 In article <1993May25.152103.6262@dbased.nuo.dec.com>,8  winalski@adserv.enet.dec.com (Paul S. Winalski) writes:H > 1) One and only one I/O channel can be opened on SYS$NET:.  All DECnetK >    communications have to take place over that channel.  In particular, a 7 >    subprocess cannot access its parent's DECnet link.   L As some might see a conflict between my and Paul's responses in this thread,# I thought I'd post a clarification:   K Paul is correct here.  The reason is that the $ASSIGN channel to SYS$NET is N "special".  The reason it's special is that the equivalence name of SYS$NET isL not just a device name; it's the network connect block that will tell DECnetK which inbound connect request you're confirming.  The channel ends up being O assigned to a pseudo-device called NETnnnn, but that device isn't ready for use O until after the $ASSIGN to SYS$NET has been done, confirming the link.  (It may > not even exist until that $ASSIGN is done, I haven't checked.)  N You can also confirm the link by $ASSIGNing to NET0:, which gets you a channelL to a NETnnnn, picking the NCB out of SYS$NET's equivalence name, and passingJ the NCB to NETnnnn with a $QIO IO$_ACCESS; this is part of non-transparent programming.    M You can't assign a second channel to SYS$NET because once you've assigned the H first one, the connect request which SYS$NET describes has already been C confirmed!  (You might think of SYS$NET has having been "used up".)   O Someone is no doubt wondering what happens if you $ASSIGN to SYS$NET, then do a N $GETDVI on the channel to recover the NETnnnn device name, then try to $ASSIGNH a second channel to that device name.  I was, so I tried it.  The secondN $ASSIGN will complete without error but the resulting channel can't be used toM talk to the DECNet link, because the WCB pointer in the channel control block H isn't filled in.  I suppose this could be patched up via a little bit of kernel-mode code.     O All of this is a little afield of the original question.  The questioner wanted N (I think) to have a process (we'll call it the "switcher") declare its name toK DECnet via IO$_ACPCONTROL, receive multiple inbound connect requests (via a M mailbox associated with the channel used to do the ACPCONTROL), and pass them N off to other processes. Such a process CAN pass the NCBs read from the mailboxC to other processes, and let the other processes confirm the links.    M But this doesn't contradict Paul's assertion, as it does not involve multiple O $ASSIGNs to SYS$NET; SYS$NET won't be involved at all in this technique, except J perhaps for the first incoming connect to the "switcher" process (and that2 connect cannot be handed off to another process).   O If you want the "switcher" process to confirm the links and read something from I the link to determine what image to run in another process to service the L link.... you can't do that, because it would require assigning two differentK channels to the link (one in the "switcher" process and one in the "server" J that it creates).  But you CAN use non-transparent programming to send theO "server selection" information in the Network Connect Block; the "switcher" can O then examine the NCB received in the mailbox message to determine what image to 8 run in the server, and the server can confirm the link.   6 	--- Jamie Hanrahan, Kernel Mode Systems, San Diego CAO drivers, internals, networks, applications, and training for VMS and Windows NT N uucp 'g' protocol guru and release coordinator, VMSnet (DECUS uucp) W.G., and K Chair, Programming and Internals Working Group, U.S. DECUS VMS Systems SIG  B Internet:  jeh@cmkrnl.com  Uucp: uunet!cmkrnl!jeh  CIS: 74140,2055  