Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
sysklogd and xconsole
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Other Things Gentoo
View previous topic :: View next topic  
Author Message
Bill Cosby
Guru
Guru


Joined: 22 Jan 2005
Posts: 430
Location: Aachen, Germany

PostPosted: Thu Oct 09, 2008 7:40 pm    Post subject: sysklogd and xconsole Reply with quote

Hi there,

I am running a full ~x86 Gentoo machine, and everything works fine, except that somehow udev doesn't create the fifo /dev/xconsole.

Now my question is, do I actually need xconsole or can I use /dev/console instead and just read it with xterm/urxvt -C?
I mean can I pipe sysklogd to console instead of xconsole?

Or how can I tell udev to create xconsole?

Thanks in advance
_________________
The Creature from Jekyll Island.
Back to top
View user's profile Send private message
notHerbert
Advocate
Advocate


Joined: 11 Mar 2008
Posts: 2228
Location: 45N 73W

PostPosted: Thu Oct 09, 2008 9:41 pm    Post subject: Reply with quote

Bill Cosby,

If you just want some log tailing on your desktop, you can use xrootconsole <logfile>
Example
Code:
xrootconsole /var/log/messages


see xrootconsole --help for details.
8)
Back to top
View user's profile Send private message
Bill Cosby
Guru
Guru


Joined: 22 Jan 2005
Posts: 430
Location: Aachen, Germany

PostPosted: Fri Oct 10, 2008 11:27 am    Post subject: Reply with quote

notHerbert wrote:
Bill Cosby,

If you just want some log tailing on your desktop, you can use xrootconsole <logfile>
Example
Code:
xrootconsole /var/log/messages


see xrootconsole --help for details.
8)

Well thanks, however I don't want log tailling on my desktop, I want a file where I can extract certain log information from, /dev/console would be nice, I am not even sure what the difference to /dev/xconsole is, however when I start my Gentoo box then there is no /dev/xconsole file. How can I tell udev to create it?
_________________
The Creature from Jekyll Island.
Back to top
View user's profile Send private message
notHerbert
Advocate
Advocate


Joined: 11 Mar 2008
Posts: 2228
Location: 45N 73W

PostPosted: Fri Oct 10, 2008 11:59 am    Post subject: Reply with quote

xconsole is a xbase-clients application - looks like a small xterm. You can pipe all syslog into it by amending your syslog.conf file.
Here is a section from syslog-ng.conf
/etc/syslog-ng/syslog-ng.conf:
# By default messages are logged to tty12...
destination console_all { file("/dev/tty12"); };
# ...if you intend to use /dev/console for programs like xconsole
# you can comment out the destination line above that references /dev/tty12
# and uncomment the line below.
#destination console_all { file("/dev/console"); };

I suppose that you can pipe it into any file such as $HOME/somefile. :)
Back to top
View user's profile Send private message
Bill Cosby
Guru
Guru


Joined: 22 Jan 2005
Posts: 430
Location: Aachen, Germany

PostPosted: Tue Oct 21, 2008 9:17 am    Post subject: Reply with quote

notHerbert wrote:
xconsole is a xbase-clients application - looks like a small xterm. You can pipe all syslog into it by amending your syslog.conf file.

Yeah, I appreaciate your explenation, but I know what it is. What /dev/console is was mytserious to me, but now I know that it is a device file for my actual console, so that anything I write to it will be displayed by the console. Still ...
I want to know how I can create the xconsole on boot, so far I am sure it is done via udev.
Or how do I cahnge permissions for the /dev/console file, and is this even safe?

notHerbert wrote:
I suppose that you can pipe it into any file such as $HOME/somefile. :)

I suppose so, but my question still stands.
_________________
The Creature from Jekyll Island.
Back to top
View user's profile Send private message
notHerbert
Advocate
Advocate


Joined: 11 Mar 2008
Posts: 2228
Location: 45N 73W

PostPosted: Wed Oct 22, 2008 9:19 am    Post subject: Reply with quote

Well, you don't really need xconsole until you start an X session.

So one way to use xconsole is to put into $HOME/.xinitrc a command such as this
Code:
sudo xconsole -file /var/log/messages &
You could even make it sticky through the window manager.

If you use KDM there is an Xsetup file /usr/kde/3.5/share/config/kdm/Xsetup, such a command might work well (untested)
Code:
xconsole -file /var/log/messages &


There is also $HOME/.kde/Autostart, and I think there is a GUI in Gnome to run autostart programs.

You could even create a destination in /etc/syslog[d-ng] to pipe to /var/log/console only selected logs, etc...

:P
Back to top
View user's profile Send private message
Bill Cosby
Guru
Guru


Joined: 22 Jan 2005
Posts: 430
Location: Aachen, Germany

PostPosted: Wed Aug 12, 2009 6:36 pm    Post subject: Reply with quote

Hejhej, I am back, I simply let this problem rest, but I am still interested in it.

@notHerbert, I am talking about the device file xconsole, not the program.
It is called /dev/xconsole, and as I read earlier today, on systems which use udev it isn't present (anymore?). I am not sure why.
However, it is a special file, I can create it with:
Code:
mknod -m=644 /dev/xconsole

then redirect the output from my syslog daemon to it, and then read it with the application program Xconsole.

My question are, why has xconsole disappeared ,is there a recent replacement, and if not how do I tell udev to create this file for me, or what is the general usage here?
_________________
The Creature from Jekyll Island.
Back to top
View user's profile Send private message
STrRedWolf
n00b
n00b


Joined: 02 Sep 2002
Posts: 72

PostPosted: Sat Aug 23, 2014 2:26 pm    Post subject: Reply with quote

I have the same setup. Sysklogd was complaining about a /dev/xconsole. So after a google search, the Gentoo logging documentation pointed me back to /etc/syslog.conf:

Code:
# The named pipe /dev/xconsole is for the `xconsole' utility.  To use it,
# you must invoke `xconsole' with the `-file' option:
#
#    $ xconsole -file /dev/xconsole [...]
#
# NOTE: adjust the list below, or you'll go crazy if you have a reasonably
#      busy site..
#
daemon.*;mail.*;\
        news.err;\
        *.=debug;*.=info;\
        *.=notice;*.=warn       |/dev/xconsole


Huh, so it needs to be a named pipe. Well, that's the "mkfifo" command:

Code:
mkfifo -m 644 /dev/xconsole


But then, you may just want to disable it by prefixing the lines with hashes.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Other Things Gentoo All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum