(Summary) Openwin Cmdtool can't find terminal

Another Casualty of Applied Metaphysics JPEREGRINO at hbsstg.harvard.edu
Wed Apr 17 11:00:00 AEST 1991


In a previous query I wrote :

>All of a sudden today, when I start up Openwindows, neither the console
>cmdtool nor any other cmdtools show up.  A look with ps shows that they
>are running (and sucking 23% of the cpu a piece), but have a '?' under the
>tty column.  So it seems that they cannot access the console.  Other
>windows (meters, filemgr, etc) come up fine.  No problem with sunview
>alone, or vanilla X11/R4.
>
>Someone had this problem back in v9n126, but I can't find a response in
>the archives.

Thanks to jesse at cs.ualberta.ca, the original submitter re:v9n126, I was
put on the correct track.  Poffen at sj.ate.slb.com also gave a similar
suggestion.

Here's What Happened :

1) in a ~/.openwin-init I had two invocations to cmdtool.
2) Cmdtool normally looks for the first available ttyp* terminal.
3) The first two available terminals were two left over from a crashed
   vanilla X11R4 session.  The protection and ownership of the two terminals
   were still the previous owner's.
4) Cmdtool continuous retried to connect to these two terminals, shooting
   the cpu usage through the roof.
5) Starting up additional cmdtools was no problem because the bad
   terminals were now unavailable.
6) After killing the stalled cmdtools, I reset the bad terminals ownership
   to root and protection to 666.
7) Things were fine.

One thing that seemed odd was that the 'w' command showed those two
terminals as still being active and owned by the old user.  A peek at
/etc/utmp showed that they were still referenced in that file.  I felt
uneasy with that, so I rebooted the machine.

The 'moral' is exactly how does cmdtool determine that a terminal is
available? Obviously, not by the ownership of the terminal.  Does it look
in /etc/utmp?  If so, how do you clear spurious information from that
file?

| James Peregrino, Programmer/Analyst    |     JPEREGRINO at HBSSTG.HARVARD.EDU |
| Science & Technology Interest Group    |       PEREGRIN at HULAW1.BITNET      |
| Harvard Business School                +-----------------------------------+
| Boston, MA 02163                       | Standard Disclaimers Provided Upon|
| Voice:(617)495-6307, FAX:(617)495-0351 | Request.                          |



More information about the Comp.sys.sun mailing list