[lug] Initial Value of term and tcsh
John E. Koontz
koontz at boulder.nist.gov
Wed Oct 30 12:47:23 MST 2002
I am dealing with two Red Hat Linux systems, one 7.2, one 7.3. Both are
using gdm and GNOME. There are various configuration differences between
the two systems apart from the difference in versions. The 7.2 was set up
by Dell and modified some locally. The 7.3 was installed from the Red Hat
Bible CDs and modified some locally. In particular, both systems had
NIS/NFS/automounter set up, and the 7.3 had an in house hardening script
(not mine) run.
The user accounts are from NIS and the user shell is tcsh. Both systems
are running tcsh 6.10.0 with the same date and compilation
options. Incidentally, there is no /etc/ttytype file on either system.
If I connect to a system gdm invokes .login which sources another file in
which there is the code sequence:
echo "Term is initially $term"
if ( ! $?term ) set term="unknown"
echo "Term is now $term"
while ( $term == "dumb" || $term == "network" || $term == "" )
echo What is your terminal type\?
set term=`tset - -I -Q \?$DEFAULT_TERM`
end
At this point term is undefined, though, for example, in running this code
in Solaris it might come in as dtterm.
On the 7.2 system .xsession-errors contains
===
XIM DEBUG: Term is initially dumb
Term is now dumb
What is your terminal type?
tset: standard error: Inappropriate ioctl for device
===
(Repeat previous two lines indefinitely - user never gets a session.)
On the 7.3 system .xsession-errors contains
===
term: Undefined variable.
SESSION_MANAGER=local/hostb.nist.gov:/tmp/.ICE-unix/2953
Gtk-WARNING **: gtk_signal_disconnect_by_data(): could not find handler
containing data (0x81B0B68)
===
This last alternative is more what I would expect.
If I remove the initial echo, then I get, as expected, on either system:
===
XIM DEBUG: Term is now unknown
Terminal type set to unknown.
The DISPLAY variable has been set to :0
Gdk-WARNING **: locale not supported by C library
SESSION_MANAGER=local/hosta:/tmp/.ICE-unix/25181
...
===
Actually, the 7.3 system doesn't include the XIM DEBUG: at the start of the
first line this time either. I'm assuming that this is a Xim[ian] debug
option to capture output directed in a suspicious or aimless direction, and
not involved in the actual pattern of behavior with term.
====
To summarize, on the 7.2 system, using echo to look at term, apparently
undefined, apparently causes it to have the value dumb. I'm tempted to
say, causes it to have a dumb value. Not looking at it lets it remain
undefined, so it gets reset to unknown. On the 7.3 system, looking at term
with echo doesn't affect it.
====
The question is, can anyone tell me what is setting term in this way,
apparently within only one of two identical tcsh-es?
====
I'm pretty sure the difference does have something to do with the
differences in setup of the two systems, because I have another 7.3 which,
so far as tested, has the same superficial behavior as the first. However,
I have no idea what difference in the 7.2 system might be relevant here. I
suspect it's not directly correlated with the version of Red Hat, however,
but something about the Dell setup or subsequent mods.
John E. Koontz
303-497-5180
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.lug.boulder.co.us/pipermail/lug/attachments/20021030/4d82458a/attachment.html>
More information about the LUG
mailing list