Help - a question on log file

  • Follow


Hi,

I'm using RH Linux 9.0 and found an issue with /var/log/messages.  It seems
the content of /var/log/messages stays the same and won't be updated any
more even after a reboot.  dmesg still shows log update.  How can I "reset"
/var/log/messages and let it update?

Thanks,


T.



0
Reply l_x2828 (152) 7/19/2004 8:56:21 PM

On Mon, 19 Jul 2004 15:56:21 -0500, L wrote:

> Hi,
> 
> I'm using RH Linux 9.0 and found an issue with /var/log/messages.  It
> seems the content of /var/log/messages stays the same and won't be
> updated any more even after a reboot.  dmesg still shows log update. How
> can I "reset" /var/log/messages and let it update?

The 'messages' in /var/log/messages are normally appended at the end of
the file and /var/log/messages does not get erased and re-created like
/var/log/dmesg at boot.

As root type;
rm /var/log/messages
service syslog restart

cat /var/log/messages  (expected output, modified for word wrap)

Jul 19 16:22:29 Laptop1700 syslogd 1.4.1: restart.

Jul 19 16:22:29 Laptop1700 syslog: syslogd startup succeeded

Jul 19 16:22:29 Laptop1700 kernel: klogd 1.4.1, log source = /proc/kmsg
started.

Jul 19 16:22:29 Laptop1700 syslog: klogd startup succeeded
 

-- 
Hi!  I'm a .sig virus!  Please copy me to your .sig! so I can spread
This E-mail is safe, no Microsoft products where used in creating me!

0
Reply Lenard 7/19/2004 9:22:20 PM


"Lenard" <lenard@127.0.0.1> wrote in message
news:pan.2004.07.19.21.25.26.962496@127.0.0.1...
> On Mon, 19 Jul 2004 15:56:21 -0500, L wrote:
>
> > Hi,
> >
> > I'm using RH Linux 9.0 and found an issue with /var/log/messages.  It
> > seems the content of /var/log/messages stays the same and won't be
> > updated any more even after a reboot.  dmesg still shows log update. How
> > can I "reset" /var/log/messages and let it update?
>
> The 'messages' in /var/log/messages are normally appended at the end of
> the file and /var/log/messages does not get erased and re-created like
> /var/log/dmesg at boot.
>
> As root type;
> rm /var/log/messages
> service syslog restart

After do the above two steps:
rm /var/log/messages
service syslog restart

 I can only find "/var/log/messages." but not "/var/log/messages"  and the
file "/var/log/messages." is empty.  After a reboot, I still can not find
"/var/log/messages" and "/var/log/messages." is still empty.  What I missed?

Thanks,

T.
--

> cat /var/log/messages  (expected output, modified for word wrap)
>
> Jul 19 16:22:29 Laptop1700 syslogd 1.4.1: restart.
>
> Jul 19 16:22:29 Laptop1700 syslog: syslogd startup succeeded
>
> Jul 19 16:22:29 Laptop1700 kernel: klogd 1.4.1, log source = /proc/kmsg
> started.
>
> Jul 19 16:22:29 Laptop1700 syslog: klogd startup succeeded
>
>
> -- 
> Hi!  I'm a .sig virus!  Please copy me to your .sig! so I can spread
> This E-mail is safe, no Microsoft products where used in creating me!
>


0
Reply l_x2828 (152) 7/19/2004 10:25:32 PM

"Lenard" <lenard@127.0.0.1> wrote in message
news:pan.2004.07.19.21.25.26.962496@127.0.0.1...
> On Mon, 19 Jul 2004 15:56:21 -0500, L wrote:
>
> > Hi,
> >
> > I'm using RH Linux 9.0 and found an issue with /var/log/messages.  It
> > seems the content of /var/log/messages stays the same and won't be
> > updated any more even after a reboot.  dmesg still shows log update. How
> > can I "reset" /var/log/messages and let it update?
>
> The 'messages' in /var/log/messages are normally appended at the end of
> the file and /var/log/messages does not get erased and re-created like
> /var/log/dmesg at boot.
>
> As root type;
> rm /var/log/messages
> service syslog restart

After complete the above two steps:
rm /var/log/messages
service syslog restart

 (correction for the previous post, sorry) I can NOT find
"/var/log/messages".  After a reboot, I still can not find
"/var/log/messages".  What I missed?

Thanks,

T.
--

> cat /var/log/messages  (expected output, modified for word wrap)
>
> Jul 19 16:22:29 Laptop1700 syslogd 1.4.1: restart.
>
> Jul 19 16:22:29 Laptop1700 syslog: syslogd startup succeeded
>
> Jul 19 16:22:29 Laptop1700 kernel: klogd 1.4.1, log source = /proc/kmsg
> started.
>
> Jul 19 16:22:29 Laptop1700 syslog: klogd startup succeeded
>
>
> -- 
> Hi!  I'm a .sig virus!  Please copy me to your .sig! so I can spread
> This E-mail is safe, no Microsoft products where used in creating me!
>



0
Reply l_x2828 (152) 7/19/2004 10:51:52 PM

On 2004-07-19, L wrote:
>
> "Lenard" <lenard@127.0.0.1> wrote in message
> news:pan.2004.07.19.21.25.26.962496@127.0.0.1...
>> On Mon, 19 Jul 2004 15:56:21 -0500, L wrote:
>>
>> > Hi,
>> >
>> > I'm using RH Linux 9.0 and found an issue with /var/log/messages.  It
>> > seems the content of /var/log/messages stays the same and won't be
>> > updated any more even after a reboot.  dmesg still shows log update. How
>> > can I "reset" /var/log/messages and let it update?
>>
>> The 'messages' in /var/log/messages are normally appended at the end of
>> the file and /var/log/messages does not get erased and re-created like
>> /var/log/dmesg at boot.
>>
>> As root type;
>> rm /var/log/messages
>> service syslog restart
>
> After do the above two steps:
> rm /var/log/messages
> service syslog restart
>
>  I can only find "/var/log/messages." but not "/var/log/messages"  and the
> file "/var/log/messages." is empty.  After a reboot, I still can not find
> "/var/log/messages" and "/var/log/messages." is still empty.  What I missed?

    Create the file, then syslog will use it:

touch /var/log/messages

-- 
    Chris F.A. Johnson                  http://cfaj.freeshell.org/shell
    ===================================================================
    My code (if any) in this post is copyright 2004, Chris F.A. Johnson
    and may be copied under the terms of the GNU General Public License
0
Reply cfajohnson (1783) 7/19/2004 10:59:59 PM

"Chris F.A. Johnson" <cfajohnson@gmail.com> wrote in message
news:2m323fFi6i0iU1@uni-berlin.de...
> On 2004-07-19, L wrote:
> >
> > "Lenard" <lenard@127.0.0.1> wrote in message
> > news:pan.2004.07.19.21.25.26.962496@127.0.0.1...
> >> On Mon, 19 Jul 2004 15:56:21 -0500, L wrote:
> >>
> >> > Hi,
> >> >
> >> > I'm using RH Linux 9.0 and found an issue with /var/log/messages.  It
> >> > seems the content of /var/log/messages stays the same and won't be
> >> > updated any more even after a reboot.  dmesg still shows log update.
How
> >> > can I "reset" /var/log/messages and let it update?
> >>
> >> The 'messages' in /var/log/messages are normally appended at the end of
> >> the file and /var/log/messages does not get erased and re-created like
> >> /var/log/dmesg at boot.
> >>
> >> As root type;
> >> rm /var/log/messages
> >> service syslog restart
> >
> > After do the above two steps:
> > rm /var/log/messages
> > service syslog restart
> >
> >  I can only find "/var/log/messages." but not "/var/log/messages"  and
the
> > file "/var/log/messages." is empty.  After a reboot, I still can not
find
> > "/var/log/messages" and "/var/log/messages." is still empty.  What I
missed?
>
>     Create the file, then syslog will use it:
>
> touch /var/log/messages

I run:

- rm /var/log/messages
- service syslog restart (Console messages show the system logger and kernel
logger Shutting down and Starting)
- touch /var/log/messages (I can see the file messages was created after
this)
- reboot

After system starts up, /var/log/messages is still empty.  Very strange!

T.
--

>
> -- 
>     Chris F.A. Johnson                  http://cfaj.freeshell.org/shell
>     ===================================================================
>     My code (if any) in this post is copyright 2004, Chris F.A. Johnson
>     and may be copied under the terms of the GNU General Public License


0
Reply l_x2828 (152) 7/19/2004 11:17:25 PM

On Mon, 19 Jul 2004 18:17:25 -0500, L wrote:
> "Chris F.A. Johnson" <cfajohnson@gmail.com> wrote in message
> news:2m323fFi6i0iU1@uni-berlin.de...
>> On 2004-07-19, L wrote:
>> >
>> > "Lenard" <lenard@127.0.0.1> wrote in message
>> > news:pan.2004.07.19.21.25.26.962496@127.0.0.1...
>> >> On Mon, 19 Jul 2004 15:56:21 -0500, L wrote:
>> >>
>> >> > Hi,
>> >> >
>> >> > I'm using RH Linux 9.0 and found an issue with /var/log/messages.  It
>> >> > seems the content of /var/log/messages stays the same and won't be
>> >> > updated any more even after a reboot.  dmesg still shows log update.
> How
>> >> > can I "reset" /var/log/messages and let it update?
>> >>
>> >> The 'messages' in /var/log/messages are normally appended at the end of
>> >> the file and /var/log/messages does not get erased and re-created like
>> >> /var/log/dmesg at boot.
>> >>
>> >> As root type;
>> >> rm /var/log/messages
>> >> service syslog restart
>> >
>> > After do the above two steps:
>> > rm /var/log/messages
>> > service syslog restart
>> >
>> >  I can only find "/var/log/messages." but not "/var/log/messages"  and
> the
>> > file "/var/log/messages." is empty.  After a reboot, I still can not
> find
>> > "/var/log/messages" and "/var/log/messages." is still empty.  What I
> missed?
>>
>>     Create the file, then syslog will use it:
>>
>> touch /var/log/messages
> 
> I run:
> 
> - rm /var/log/messages
> - service syslog restart (Console messages show the system logger and kernel
> logger Shutting down and Starting)
> - touch /var/log/messages (I can see the file messages was created after
> this)
> - reboot
> 
> After system starts up, /var/log/messages is still empty.  Very strange!

I thought I had already answered this? Do you have multiple posts?

Check your /etc/syslog.conf file, "man syslog.conf" for details.
This is the file that tells the system where to log what.

-- 
Juhan Leemet
Logicognosis, Inc.

0
Reply juhan (466) 7/20/2004 12:58:17 PM

"Juhan Leemet" <juhan@logicognosis.com> wrote in message
news:pan.2004.07.20.12.58.15.723122@logicognosis.com...
> On Mon, 19 Jul 2004 18:17:25 -0500, L wrote:
> > "Chris F.A. Johnson" <cfajohnson@gmail.com> wrote in message
> > news:2m323fFi6i0iU1@uni-berlin.de...
> >> On 2004-07-19, L wrote:
> >> >
> >> > "Lenard" <lenard@127.0.0.1> wrote in message
> >> > news:pan.2004.07.19.21.25.26.962496@127.0.0.1...
> >> >> On Mon, 19 Jul 2004 15:56:21 -0500, L wrote:
> >> >>
> >> >> > Hi,
> >> >> >
> >> >> > I'm using RH Linux 9.0 and found an issue with /var/log/messages.
It
> >> >> > seems the content of /var/log/messages stays the same and won't be
> >> >> > updated any more even after a reboot.  dmesg still shows log
update.
> > How
> >> >> > can I "reset" /var/log/messages and let it update?
> >> >>
> >> >> The 'messages' in /var/log/messages are normally appended at the end
of
> >> >> the file and /var/log/messages does not get erased and re-created
like
> >> >> /var/log/dmesg at boot.
> >> >>
> >> >> As root type;
> >> >> rm /var/log/messages
> >> >> service syslog restart
> >> >
> >> > After do the above two steps:
> >> > rm /var/log/messages
> >> > service syslog restart
> >> >
> >> >  I can only find "/var/log/messages." but not "/var/log/messages"
and
> > the
> >> > file "/var/log/messages." is empty.  After a reboot, I still can not
> > find
> >> > "/var/log/messages" and "/var/log/messages." is still empty.  What I
> > missed?
> >>
> >>     Create the file, then syslog will use it:
> >>
> >> touch /var/log/messages
> >
> > I run:
> >
> > - rm /var/log/messages
> > - service syslog restart (Console messages show the system logger and
kernel
> > logger Shutting down and Starting)
> > - touch /var/log/messages (I can see the file messages was created after
> > this)
> > - reboot
> >
> > After system starts up, /var/log/messages is still empty.  Very strange!
>
> I thought I had already answered this? Do you have multiple posts?
>
> Check your /etc/syslog.conf file, "man syslog.conf" for details.
> This is the file that tells the system where to log what.

This is it!  Somehow, syslog.conf got modified.  After restoring it,
/var/log/messages logs all messages.

Thanks,

T.
--


> -- 
> Juhan Leemet
> Logicognosis, Inc.
>


0
Reply l_x2828 (152) 7/20/2004 3:01:35 PM

7 Replies
38 Views

(page loaded in 0.176 seconds)


Reply: