FAQ Search Today's Posts Mark Forums Read
» Video Reviews

» Linux Archive

Linux-archive is a website aiming to archive linux email lists and to make them easily accessible for linux users/developers.


» Sponsor

» Partners

» Sponsor

Go Back   Linux Archive > Redhat > Fedora Development

 
 
LinkBack Thread Tools
 
Old 10-10-2012, 06:36 PM
Lennart Poettering
 
Default replacing rsyslogd in minimal with journald

On Wed, 10.10.12 09:54, Richard W.M. Jones (rjones@redhat.com) wrote:

> On Wed, Oct 10, 2012 at 09:50:43AM +0200, Bjrn Persson wrote:
> > Lennart Poettering wrote:
> > > On Tue, 09.10.12 09:09, Chris Adams (cmadams@hiwaay.net) wrote:
> > > > How do you read this log when the system is not running (e.g.
> > > > mounting filesystems of a drive on another system, running from a
> > > > rescue image, etc.)?
> > >
> > > journalctl -D <pathtothejournalfiles>
> >
> > So the rescue system (which might not always be Fedora) must have
> > journalctl installed. Is the file format stable, or can it break if the
> > rescue system has a different version of journalctl? Is the format
> > perchance even documented so that other tools for reading logs could be
> > written?
>
> This would be essential for libguestfs tools to parse logs out of
> guests (we do it now by reading /var/log/messages etc which has all of
> the properties you state).

I'd recommend simply using our C API for this. For details see:

http://www.freedesktop.org/software/systemd/man/

Look for the various APIs with the sd_journal_ prefix. With those you
get full access to the journal. Here you find an example how to do this:

http://www.freedesktop.org/software/systemd/man/sd_journal_next.html

Lennart

--
Lennart Poettering - Red Hat, Inc.
--
devel mailing list
devel@lists.fedoraproject.org
https://admin.fedoraproject.org/mailman/listinfo/devel
 
Old 10-10-2012, 06:36 PM
Lennart Poettering
 
Default replacing rsyslogd in minimal with journald

On Wed, 10.10.12 10:12, Richard W.M. Jones (rjones@redhat.com) wrote:

> On Wed, Oct 10, 2012 at 09:54:28AM +0100, Richard W.M. Jones wrote:
> > On Wed, Oct 10, 2012 at 09:50:43AM +0200, Bjrn Persson wrote:
> > > Lennart Poettering wrote:
> > > > On Tue, 09.10.12 09:09, Chris Adams (cmadams@hiwaay.net) wrote:
> > > > > How do you read this log when the system is not running (e.g.
> > > > > mounting filesystems of a drive on another system, running from a
> > > > > rescue image, etc.)?
> > > >
> > > > journalctl -D <pathtothejournalfiles>
> > >
> > > So the rescue system (which might not always be Fedora) must have
> > > journalctl installed. Is the file format stable, or can it break if the
> > > rescue system has a different version of journalctl? Is the format
> > > perchance even documented so that other tools for reading logs could be
> > > written?
> >
> > This would be essential for libguestfs tools to parse logs out of
> > guests (we do it now by reading /var/log/messages etc which has all of
> > the properties you state).
>
> I checked out the code, and it does seem as if the format is intended
> to be backwards compatible. It uses a set of filesystem-like
> "compatible" and "incompatible" flags, so presumably a sufficiently
> recent journalctl would be able to read any previous version of the
> binary file format.
>
> It would be nice to have this confirmed, and indeed enshrined in the
> policy of the journal, because it is IMHO essential that the binary
> log files will always be readable.

Yes, the compatible and incompatible flag bit fields are precisely to
provide good compatibility as the format evolves.

Lennart

--
Lennart Poettering - Red Hat, Inc.
--
devel mailing list
devel@lists.fedoraproject.org
https://admin.fedoraproject.org/mailman/listinfo/devel
 
Old 10-10-2012, 06:37 PM
Konstantin Ryabitsev
 
Default replacing rsyslogd in minimal with journald

On Wed, Oct 10, 2012 at 2:32 PM, Lennart Poettering
<mzerqung@0pointer.de> wrote:
>> Can journalctl send the logs via logwatch?
>
> Not sure I can parse this, but IIUC you are wondering whether logwatch
> is compatible with the journal. Not to my knowledge, no. But adding this
> should be fairly easy as the output of "journalctl" is a pixel-perfect
> copy of the original format, so where it works on /var/log/messages it
> should simply work on the output of journalctl and all should be good.
>
> Note however that with the capabilities of the journal it might be
> interesting to add journal support to logwatch that goes beyond mere
> compatibility. For example, tests such as "look for messages which are
> claimed to come from PID xyz but actually came from uvw" and suchlike
> would be really interesting to have. That information is not available
> in the /var/log/messages format however...

So, in other words, all our existing log analysis tools have to be
modified if they are to be of any use in Fedora 18?

Best,
--
Konstantin Ryabitsev
LinuxFoundation.org
Montral, Qubec
--
devel mailing list
devel@lists.fedoraproject.org
https://admin.fedoraproject.org/mailman/listinfo/devel
 
Old 10-10-2012, 06:39 PM
Kay Sievers
 
Default replacing rsyslogd in minimal with journald

On Wed, Oct 10, 2012 at 8:37 PM, Konstantin Ryabitsev
<icon@fedoraproject.org> wrote:
> On Wed, Oct 10, 2012 at 2:32 PM, Lennart Poettering
> <mzerqung@0pointer.de> wrote:
>>> Can journalctl send the logs via logwatch?
>>
>> Not sure I can parse this, but IIUC you are wondering whether logwatch
>> is compatible with the journal. Not to my knowledge, no. But adding this
>> should be fairly easy as the output of "journalctl" is a pixel-perfect
>> copy of the original format, so where it works on /var/log/messages it
>> should simply work on the output of journalctl and all should be good.
>>
>> Note however that with the capabilities of the journal it might be
>> interesting to add journal support to logwatch that goes beyond mere
>> compatibility. For example, tests such as "look for messages which are
>> claimed to come from PID xyz but actually came from uvw" and suchlike
>> would be really interesting to have. That information is not available
>> in the /var/log/messages format however...
>
> So, in other words, all our existing log analysis tools have to be
> modified if they are to be of any use in Fedora 18?

What part of "Run the syslog daemon like you always did, if you need
syslog files." did you not understand?

Kay
--
devel mailing list
devel@lists.fedoraproject.org
https://admin.fedoraproject.org/mailman/listinfo/devel
 
Old 10-10-2012, 06:40 PM
Matthew Miller
 
Default replacing rsyslogd in minimal with journald

On Wed, Oct 10, 2012 at 02:37:05PM -0400, Konstantin Ryabitsev wrote:
> So, in other words, all our existing log analysis tools have to be
> modified if they are to be of any use in Fedora 18?

No, not in the even slightest. I don't think that's even up for discussion.


--
Matthew Miller ☁☁☁ Fedora Cloud Architect ☁☁☁ <mattdm@fedoraproject.org>
--
devel mailing list
devel@lists.fedoraproject.org
https://admin.fedoraproject.org/mailman/listinfo/devel
 
Old 10-10-2012, 06:42 PM
Seth Vidal
 
Default replacing rsyslogd in minimal with journald

On Wed, 10 Oct 2012, Kay Sievers wrote:



So, in other words, all our existing log analysis tools have to be
modified if they are to be of any use in Fedora 18?


What part of "Run the syslog daemon like you always did, if you need
syslog files." did you not understand?



Kay,
This is not an acceptable tone. There is no need for this sort of sarcasm
or snark. Please amend this in the future.


-sv

--
devel mailing list
devel@lists.fedoraproject.org
https://admin.fedoraproject.org/mailman/listinfo/devel
 
Old 10-10-2012, 06:44 PM
Konstantin Ryabitsev
 
Default replacing rsyslogd in minimal with journald

On Wed, Oct 10, 2012 at 2:39 PM, Kay Sievers <kay@vrfy.org> wrote:
>> So, in other words, all our existing log analysis tools have to be
>> modified if they are to be of any use in Fedora 18?
>
> What part of "Run the syslog daemon like you always did, if you need
> syslog files." did you not understand?

Well, hang on, Kay. My understanding was that we're trying to make
syslog an optional install in Fedora 18 (or is it 19?). If that is the
case, then even if I require rsyslog for a package, that won't work
unless rsyslog is started and running. So, sysadmin's experience
changes:

Was: Install logwatch.
Becomes: Install logwatch. Make sure you install and enable rsyslog.

I just want to make sure people are aware of the change.

Best,
--
Konstantin Ryabitsev
LinuxFoundation.org
Montral, Qubec
--
devel mailing list
devel@lists.fedoraproject.org
https://admin.fedoraproject.org/mailman/listinfo/devel
 
Old 10-10-2012, 06:58 PM
Kay Sievers
 
Default replacing rsyslogd in minimal with journald

On Wed, Oct 10, 2012 at 8:44 PM, Konstantin Ryabitsev
<icon@fedoraproject.org> wrote:
> On Wed, Oct 10, 2012 at 2:39 PM, Kay Sievers <kay@vrfy.org> wrote:
>>> So, in other words, all our existing log analysis tools have to be
>>> modified if they are to be of any use in Fedora 18?
>>
>> What part of "Run the syslog daemon like you always did, if you need
>> syslog files." did you not understand?
>
> Well, hang on, Kay. My understanding was that we're trying to make
> syslog an optional install in Fedora 18 (or is it 19?).

Surely not f18, and there is not even a feature for f19 as of now.

> If that is the
> case, then even if I require rsyslog for a package, that won't work
> unless rsyslog is started and running.

Services can pull-in service dependencies to start stuff they depend
on, it's unreleated RPM dependencies.

> So, sysadmin's experience
> changes:
>
> Was: Install logwatch.
> Becomes: Install logwatch. Make sure you install and enable rsyslog.
>
> I just want to make sure people are aware of the change.

Ah, sorry that I was just unable to translate: "all our existing log
analysis tools have to be modified if they are to be of any use in
Fedora" to "just want to make sure ... you install and enable
rsyslog".

Kay
--
devel mailing list
devel@lists.fedoraproject.org
https://admin.fedoraproject.org/mailman/listinfo/devel
 
Old 10-10-2012, 07:01 PM
Matthew Miller
 
Default replacing rsyslogd in minimal with journald

On Wed, Oct 10, 2012 at 02:44:53PM -0400, Konstantin Ryabitsev wrote:
> Well, hang on, Kay. My understanding was that we're trying to make
> syslog an optional install in Fedora 18 (or is it 19?). If that is the

The suggestion was to propose this as a feature for F19. I think there's
some additional basic functionality we really need in place before that
would be ready.

> case, then even if I require rsyslog for a package, that won't work
> unless rsyslog is started and running. So, sysadmin's experience
> changes:
> Was: Install logwatch.
> Becomes: Install logwatch. Make sure you install and enable rsyslog.
> I just want to make sure people are aware of the change.

Well, we've got: http://fedoraproject.org/wiki/Features/PackagePresets and
it seems like we could probably come up with a preset selection for
non-desktop system use. I'd say "server-presets", except it goes beyond
server, of course. But yeah, we'd need to make that easy -- a list of "now
you get to jump through these hoops because we've made things better!" won't
make anyone happy with us.

Additionally, it _would_ be cool for log monitoring and analysis tools to
gain journald support, so that users of those tools can take advantage of
all the features Lennart lists. If we could have some of those in place
along with the proposed feature, that would be a win.


--
Matthew Miller ☁☁☁ Fedora Cloud Architect ☁☁☁ <mattdm@fedoraproject.org>
--
devel mailing list
devel@lists.fedoraproject.org
https://admin.fedoraproject.org/mailman/listinfo/devel
 
Old 10-10-2012, 07:08 PM
Konstantin Ryabitsev
 
Default replacing rsyslogd in minimal with journald

On Wed, Oct 10, 2012 at 3:01 PM, Matthew Miller
<mattdm@fedoraproject.org> wrote:
> Additionally, it _would_ be cool for log monitoring and analysis tools to
> gain journald support, so that users of those tools can take advantage of
> all the features Lennart lists. If we could have some of those in place
> along with the proposed feature, that would be a win.

Hint-hint, nudge-nudge?

I'm not sure I can swing that, unfortunately. But I certainly am
interested in seeing where journal is headed, as it improves a lot of
aspects of log management that log analysis tools have to work around.

Regards,
--
Konstantin Ryabitsev
LinuxFoundation.org
Montral, Qubec
--
devel mailing list
devel@lists.fedoraproject.org
https://admin.fedoraproject.org/mailman/listinfo/devel
 

Thread Tools




All times are GMT. The time now is 01:37 PM.

VBulletin, Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.
Copyright 2007 - 2008, www.linux-archive.org