Re: [systemd-devel] Backup the current boot logs in raw format
On Wed, Jul 24, 2019 at 4:08 PM Zbigniew Jędrzejewski-Szmek wrote: > journalctl -o export ... | /usr/lib/systemd/systemd-journal-remote -o > /tmp/foo.journal - > This has the advantage that you can apply any journalctl filter where > the dots are, e.g. '-b'. Thanks ! It's documented in man page but I wasn't sure that I didn't miss somthing else because it is a bit strange to use an additional tool (systemd-journal-remote) to do that. Something like: journalctl -o raw -b >/tmp/foo.journal -- Francis ___ systemd-devel mailing list systemd-devel@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/systemd-devel
Re: [systemd-devel] Backup the current boot logs in raw format
On Wed, Jul 24, 2019 at 03:48:40PM +0200, Francis Moreau wrote: > Hi, > > I would like to backup the journal logs for the current boot in a > "raw" format so I can reuse it later with "journalctl > --file=my-backup". > > But looking at the different values for "-o" option I can't find the answer. > > Could anybody give me some clues ? One option is to simply copy some of the files in /var/log/journal to a different location. You can then read them with 'journalctl -D'. If you want to be more granular and only select specific log entries, you can export and write to a journal file with: journalctl -o export ... | /usr/lib/systemd/systemd-journal-remote -o /tmp/foo.journal - This has the advantage that you can apply any journalctl filter where the dots are, e.g. '-b'. Zbyszek ___ systemd-devel mailing list systemd-devel@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/systemd-devel
[systemd-devel] Backup the current boot logs in raw format
Hi, I would like to backup the journal logs for the current boot in a "raw" format so I can reuse it later with "journalctl --file=my-backup". But looking at the different values for "-o" option I can't find the answer. Could anybody give me some clues ? Thanks. -- Francis ___ systemd-devel mailing list systemd-devel@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/systemd-devel
Re: [systemd-devel] Antw: Re: Antw: sd_journal_send non-blocking call
On Mi, 24.07.19 07:56, Ulrich Windl (ulrich.wi...@rz.uni-regensburg.de) wrote: > >> No, program APIs use Unix sockets (/dev/log, /run/systemd/journal/socket). > >> You only get UDP when your local syslog daemon is configured to forward > >> elsewhere. > >> > >> That said, both are datagram sockets, I'm not sure whether sending to Unix > >> dgram sockets can block or not? > > > > Local AF_UNIX/SOCK_DGRAM sockets may block and are reliable. > > Out of curiosity, what would be the condition for the datagram socket to block > when it's being written to? Is it due to being "reliable" that all received > packets have to be buffered? ("man 7 unix" does not contain the phrase "block" > here) Yes, when an AF_UNIX socket buffer is full any further send()/write() on it will block until the other side reads some data off them. Lennart -- Lennart Poettering, Berlin ___ systemd-devel mailing list systemd-devel@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/systemd-devel