SHARE
TWEET

Dmesg with full date

gaspar_fm Mar 11th, 2013 466 Never
  1. # dmesg with full date
  2.  
  3. base=$(cat /proc/uptime | cut -d ‘.’ -f1); seconds=`date +%s`; dmesg | sed 's/^\[\(.*\)\..*\]\(.*\)$/\1\n\2/' | while read first; do read second; first=`date +"%d/%m/%Y %H:%M:%S" --date="@$(($seconds - $base + $first))"`; echo "[$first] $second"; done
RAW Paste Data
Top