stage-1: add datestamps to logs

When the stage-1 logs get imported in to the journal, they all get
loaded with the same timestamp. This makes it difficult to identify
what might be taking a long time in early boot.
This commit is contained in:
Graham Christensen 2020-10-30 11:05:48 -04:00
parent 4512dac960
commit a179781696
No known key found for this signature in database
GPG key ID: FE918C3A98C1030F

View file

@ -120,7 +120,7 @@ eval "exec $logOutFd>&1 $logErrFd>&2"
if test -w /dev/kmsg; then
tee -i < /tmp/stage-1-init.log.fifo /proc/self/fd/"$logOutFd" | while read -r line; do
if test -n "$line"; then
echo "<7>stage-1-init: $line" > /dev/kmsg
echo "<7>stage-1-init: [$(date)] $line" > /dev/kmsg
fi
done &
else