[arch-general] journalctl - configure date output persistent to short-iso
Hi archers, I want journalctl to display date output persistently in short-iso format everytime everywhere. Searched around in manpages (journalctl journald.conf) and the web but no avail. I know about the -o switch, but didn't find the place to make this persistent. Anyone around who knows or did this already? -- Friedrich
On Sun, 23 Jun 2019, at 00:22, Friedrich Strohmaier wrote:
Anyone around who knows or did this already?
From casually scimming the journalctl source code, unless I've overlooked something, it seems like only journalctl handles the presentation of the data in the specified OutputMode which is why there is no journald configuration option, because it's irrelevant to journald.
Inside journalctl, OutputMode is only set from external input via the -o CLI option. Going by these facts, it seems like there is no way to archieve what you want just with journalctl. If that's correct, there are 2 simple alternatives: * alias journalctl='journalctl -o foo' * Put a journalctl wrapper into a directory that is at the head of $PATH: #!/bin/sh exec /usr/sbin/journalctl -o foo "$@"
Hi Jens, *, Am 23.06.19 um 13:05 schrieb Jens John:
On Sun, 23 Jun 2019, at 00:22, Friedrich Strohmaier wrote:
Anyone around who knows or did this already?
[..]
Going by these facts, it seems like there is no way to archieve what you want just with journalctl.
Thats definitly not what I wanted to read, but well..
If that's correct, there are 2 simple alternatives:
* alias journalctl='journalctl -o foo' * Put a journalctl wrapper into a directory that is at the head of $PATH:
#!/bin/sh exec /usr/sbin/journalctl -o foo "$@"
Thanks for Your investigation and suggestion. That smells like a feature request at systemd guys, as I can't see any advantage having the recent date output as default. -- Friedrich
participants (2)
-
Friedrich Strohmaier
-
Jens John