You are not logged in.

#26 2011-06-29 10:29:52

thisoldman
Member
From: Pittsburgh
Registered: 2009-04-25
Posts: 1,172

Re: Logging boot messages

I've been able to capture the last screen of console boot messages, after starting X, with this command:

sudo cat /dev/vcs1 > console_1.txt

Unfortunately, it records the screen text without line breaks.  Everything is on a single line.

Offline

#27 2011-06-29 10:31:44

rwd
Member
Registered: 2009-02-08
Posts: 646

Re: Logging boot messages

toad wrote:

(...)
Some queries:
1. What's it with all the ^[[?

They are color codes, like the ones you can set for bash output. No idea where they come from though.

Offline

#28 2011-06-29 12:17:06

karol
Archivist
Registered: 2009-05-06
Posts: 25,432

Re: Logging boot messages

rwd wrote:
toad wrote:

(...)
Some queries:
1. What's it with all the ^[[?

They are color codes, like the ones you can set for bash output. No idea where they come from though.

They come from initscripts.

Offline

#29 2011-06-29 12:29:29

toad
Member
From: if only I knew
Registered: 2008-12-22
Posts: 1,775
Website

Re: Logging boot messages

Pardon me for being dumb but what do I do with karol's script?

#!/bin/bash
sed 's#\^\[#\\033#g' /var/log/boot > 00blog
printf "$(cat 00blog) \n"

Please note you are talking to someone who has no IT background or scripting experience whatsoever, i.e. the ideal answer would be: you put it <there> like <this> smile

Many thanks in advance to the kind soul who takes pity on me...


never trust a toad...
::Grateful ArchDonor::
::Grateful Wikipedia Donor::

Offline

#30 2011-06-29 13:13:12

karol
Archivist
Registered: 2009-05-06
Posts: 25,432

Re: Logging boot messages

toad wrote:

Pardon me for being dumb but what do I do with karol's script?

#!/bin/bash
sed 's#\^\[#\\033#g' /var/log/boot > 00blog
printf "$(cat 00blog) \n"

Please note you are talking to someone who has no IT background or scripting experience whatsoever, i.e. the ideal answer would be: you put it <there> like <this> smile

Many thanks in advance to the kind soul who takes pity on me...

Just save is to a file (say, ~/toadboot), make it executable (chmod +x ~/toadboot) and run (assuming you're in your ~, './toadboot' will do).

Offline

#31 2011-06-29 20:10:57

toad
Member
From: if only I knew
Registered: 2008-12-22
Posts: 1,775
Website

Re: Logging boot messages

Cheers, karol.

And I suppose I could put it in /etc/rc.local so as to forego this arduous task? Or is there a niftier way of integrating it?


never trust a toad...
::Grateful ArchDonor::
::Grateful Wikipedia Donor::

Offline

#32 2011-06-29 20:21:43

karol
Archivist
Registered: 2009-05-06
Posts: 25,432

Re: Logging boot messages

toad wrote:

Cheers, karol.

And I suppose I could put it in /etc/rc.local so as to forego this arduous task? Or is there a niftier way of integrating it?

But it doesn't even work right! It (/var/log/boot) doesn't log all the things it should, so I'm not sure you will see much benefit using it.

But sure, it's basically a two-liner so it definitely doesn't have to be a separate script.

Offline

#33 2011-06-30 01:27:41

x33a
Forum Moderator
Registered: 2009-08-15
Posts: 3,424
Website

Re: Logging boot messages

toad wrote:

Cheers, karol.

And I suppose I could put it in /etc/rc.local so as to forego this arduous task? Or is there a niftier way of integrating it?

Since it can be run after the boot, you can put it in ~/.xinitrc instead of rc.local, as that would be easier to maintain.

Offline

#34 2011-06-30 07:10:06

rwd
Member
Registered: 2009-02-08
Posts: 646

Re: Logging boot messages

B.t.w. most of the color codes are gone when you change USECOLOR="yes" to USECOLOR="no" in /etc/rc.conf .

Offline

#35 2011-07-02 19:34:45

jocom
Member
Registered: 2009-04-29
Posts: 74

Re: Logging boot messages

Somehow the contents of /var/log/boot can't be directly parsed by 'less -{Rr}'
Anyone has explanations for that?

Offline

#36 2011-07-05 13:12:05

alem0lars
Member
Registered: 2011-07-04
Posts: 1

Re: Logging boot messages

The ^[ characters in the /var/log/boot file aren't the escape character \e (or ^[).

Last edited by alem0lars (2011-07-05 13:12:34)

Offline

#37 2011-08-21 19:05:09

karol
Archivist
Registered: 2009-05-06
Posts: 25,432

Re: Logging boot messages

Can you test if this commit http://projects.archlinux.org/initscrip … 9d8a516abc clears the boot log properly?

Offline

#38 2012-11-17 17:40:59

r0b0t
Member
From: /tmp
Registered: 2009-05-24
Posts: 376

Re: Logging boot messages

For not opening a new thread I have bootlogd package installed which worked just fine before I switched to systemd, now the daemon doesn't run and systemctl doesn't include it:

# systemctl enable bootlogd
Failed to issue method call: No such file or directory

furthermore lack of a rc.d script makes me ask  "How can I make it run just when the system starts?"

Offline

#39 2012-11-25 21:20:46

knedlyk
Member
From: L'viv, Ukraine
Registered: 2009-04-14
Posts: 153
Website

Re: Logging boot messages

r0b0t wrote:

furthermore lack of a rc.d script makes me ask  "How can I make it run just when the system starts?"

Just read about journalctl

journalctl --help

In your case run

journalctl -b

and find all needed info about boot process.

Offline

Board footer

Powered by FluxBB