]> git.ipfire.org Git - thirdparty/util-linux.git/commit
dmesg: support for additional human readable timestamp
authorRishabh Thukral <rthukral@arista.com>
Tue, 5 Dec 2023 19:53:33 +0000 (11:53 -0800)
committerKarel Zak <kzak@redhat.com>
Tue, 12 Dec 2023 09:46:46 +0000 (10:46 +0100)
commit3de2e556da09d7b08ffaca3513a7be606b290a86
tree7b86ad915c4b3c0c451ea3fc48a47c5198b0415d
parent294aa16fab0ff3db6e15727a110c2689848c16d2
dmesg: support for additional human readable timestamp

The dmesg logs have timestamps in seconds since boot format which can
be converted to other formats. However, there is no option to include
both the original timestamp as present in the buffer along with the
converted timestamp in the specified format.

This change updates the --time-format option in dmesg to enable the
user to specify it multiple times with different formats with each
input providing a timestamp format among the currently supported
choices. This enables seeing the dmesg logs in both seconds since boot
and human readable format simultaneously in each row of the log output.
The sequence of timestamp format follows the order
in which the user provides the desired formats.

Signed-off-by: Rishabh Thukral <rthukral@arista.com>
sys-utils/dmesg.1.adoc
sys-utils/dmesg.c