LinuxQuestions.org
LinuxAnswers - the LQ Linux tutorial section.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices

Reply
 
Search this Thread
Old 06-19-2005, 01:06 PM   #1
candyman123
Member
 
Registered: Jul 2003
Posts: 46

Rep: Reputation: 15
Logging Console Boot Messages


Hi, I am getting some output during boot up that does not appear in any of the log files in /var/log. How can I get access to these messages? I would like them logged in the future...that is, I would like to have a log file that is an exact duplicate of the output I see during bootup (no extra details, no missing details...just an exact duplicate).
 
Old 06-19-2005, 02:02 PM   #2
jonaskoelker
Senior Member
 
Registered: Jul 2004
Location: Denmark
Distribution: Ubuntu, Debian
Posts: 1,524

Rep: Reputation: 46
The naive brute-force solution would be to use tee (man tee) to, well, tee stdout to /where/ever/stdout.log; similarly for stderr.

I do believe (hope, at least), however, that better solutions exist. I wouldn't know any

hth --Jonas
 
Old 06-19-2005, 02:12 PM   #3
jxi
Member
 
Registered: Feb 2003
Location: Richmond VA
Distribution: Slackware 11 -- CentOS 4.4
Posts: 115

Rep: Reputation: 15
Did you look in /etc/syslog.conf ?

look for a line that has /dev/console on the right side like

kern.warning /dev/console

("kern.warning" is just an example)

change /dev/console to /var/log/<mybootmessages>

and you need to run from the command line:

touch /var/log/<mybootmessages>

(of course naming this latter file whatever )

HTH
 
Old 06-19-2005, 02:24 PM   #4
candyman123
Member
 
Registered: Jul 2003
Posts: 46

Original Poster
Rep: Reputation: 15
If I change the output from /dev/console to a log file, then I won't see it at the console anymore. I could try tee, but there should be a nice way to keep the output going to console...additionally, it should log these to a file. Note, to see the display before I log in, I could hold down shift and press page-up. This will allow me to see the messages...so this is stored in some buffer. Can't I output the buffer to a file?
 
Old 06-19-2005, 02:35 PM   #5
jonaskoelker
Senior Member
 
Registered: Jul 2004
Location: Denmark
Distribution: Ubuntu, Debian
Posts: 1,524

Rep: Reputation: 46
Quote:
Can't I output the buffer to a file?
*gentle nudge*
http://homepages.tesco.net/~J.deBoyn...o-answers.html
 
Old 06-19-2005, 02:38 PM   #6
jxi
Member
 
Registered: Feb 2003
Location: Richmond VA
Distribution: Slackware 11 -- CentOS 4.4
Posts: 115

Rep: Reputation: 15
after boot is completed,

as root;

dmesg |more

of course this isn't everything that scrolled by on boot ...
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
logging bootup messages to textfile? cast55 Debian 2 02-19-2005 05:56 PM
console logging messages srns Red Hat 2 09-13-2004 04:18 PM
Redirecting console boot messages to different tty. cenkozkan Linux - Software 2 01-17-2004 04:11 AM
Logging kernel messages ugenn Linux - Software 8 01-04-2003 06:11 AM
logging external messages with syslogd slawomir Linux - Networking 3 09-04-2002 04:26 AM


All times are GMT -5. The time now is 05:48 PM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration