Path: utzoo!attcan!utgpu!jarvis.csri.toronto.edu!mailrus!cwjcc!tut.cis.ohio-state.edu!cs.utexas.edu!uunet!auspex!guy From: guy@auspex.auspex.com (Guy Harris) Newsgroups: comp.windows.x Subject: Re: Why does every xterm create an entry in /usr/utmp? Message-ID: <2422@auspex.auspex.com> Date: 7 Sep 89 18:31:51 GMT References: <3472@blake.acs.washington.edu> <8909051759.AA11810@gaak.LCS.MIT.EDU> <16851@pasteur.Berkeley.EDU> Reply-To: guy@auspex.auspex.com (Guy Harris) Organization: Auspex Systems, Santa Clara Lines: 52 >Hang on just a minute here. This is NOT a bug, or a "hack to fix finger" >as most people seem to be implying. There are a number of unix utilities >that expect every tty (or pty) to have a utmp entry associated with it. >Write and talk, for example, require this. Without a utmp entry, users >cannot write me on a given xterm (usually scribbling on my login terminal >instead, which is nasty since it's the "glass tty" underlying my X session). That's a botch; output to the "glass tty" underlying your session should be directed to some other window - under SunOS, you can do so with the "-C" flag to "xterm" (or "shelltool" or "cmdtool" under SunView), and I think Ultrix may also have OS hooks to do the same thing. If your system doesn't have a way to do that, complain to your vendor. With that fixed, users *can* "write" you on your login terminal; the output will show up in the window in question. The annoyance is that you can't "write" back in an "xterm" of your choice and get their output in that window; however, with "talk", you can do that (since the "talk" on their side doesn't write directly to the terminal). "talk" is nicer in a network environment, anyway (and if you like "write"s user interface better, for some reason, the ideal fix is to have "write" work the way "talk" does, rather than blatting stuff directly to the user's terminal). >It amuses me that everyone sees fit to criticise this in xterm, but >never seemed to mind it in rlogind. If you think about it, they >both provide the much same functionality, it's just a matter of >perception. I think the difference people perceive may be that they view "rlogin" as really logging you in to a particular machine, while "xterm" is just popping another window up on top of an existing login session. The problem is that many UNIX utilities assume that a user will be logged onto a machine only once, or at least will only be sitting in front of one login at a time, so you can really think of multiple logins as separate. However, you may have N windows in front of you on a particular machine, but since they're all in front of you you may think of them as subsessions of a single session and not want each one to have its own "utmp" entry. With a network window session you may have M more windows in front of you, on a machine other than the one on your desk; you might also want one of those to be associated with a login session, but not the others, since they might all look like subsessions of a single session on the other machine. On top of that, you might have windows on another machine, none of which are terminal emulators and therefore cannot have "utmp" entries. The problems discussed here seem to stem from the model of the world held by said UNIX utilities breaking down in a network window system world....