On Sun, Mar 11, 2001 at 09:42:40AM -0700, Scott Jacobsen <[EMAIL PROTECTED]> wrote:
| What's the difference between a console and an xterm?

When you're running in text mode (no X11) the console is the tty you're in front
of. An xterm is just another tty, not the console. Just as you won't see
console messages on a telnet connection or if you're logged in on a serial line
or such like.

| I ask because I'm trying to view kernel messages, and I must use
| xconsole to see them . . . or look at /var/log/messages.

Or man xterm:

       [...]
       -C      This  option  indicates  that  this  window should
               receive console output.  This is not supported  on
               all  systems.   To obtain console output, you must
               be the owner of the console device, and  you  must
               have read and write permission for it.  If you are
               running X under xdm on the console screen you  may
               need  to  have  the session startup and reset pro­
               grams explicitly change the ownership of the  con­
               sole device in order to get this option to work.

It does depend on the OS. Haven't tried this with Linux myself.

| Is there some way for an xterm to look at /dev/console and display
| kernel messages?

If -C doesn't work on linux you can always go:

        xterm -e tail -f /var/log/messages

which would do passably.

| Can I replace the first line in my /etc/syslog.conf file to something
| like this:
| kern.*                /dev/tty*

Perhaps not readily. And I suspect you don't want the messages in _every_
tty (which the above appears to want, though it wouldn't do it). You
could go:

        xterm -e a-script

and write the "a-script" script to edit that line of the syslogd.conf file
to say
        kern.*  /dev/ptyXX
where /dev/ptyXX is the output of the "tty" command. Then prod syslogd to
reread things.

The problem with that is that if your tty goes away for some reason the
messages now go nowhere. Undesirable. It is better (if it works) to use
"xterm -C" and leave the messages directed to /dev/console, which is a
nice reliable place.

Cheers,
-- 
Cameron Simpson, DoD#743        [EMAIL PROTECTED]    http://www.zip.com.au/~cs/

Loud pipes make noise. Skill and experience save lives.
        - EdBob Morandi



_______________________________________________
Redhat-list mailing list
[EMAIL PROTECTED]
https://listman.redhat.com/mailman/listinfo/redhat-list

Reply via email to