Tag: busybox

Openwrt dmesg human timestamp

To viel on busybox dmesg with human readable time for debug do: $vi /root/dmesg.sh insert: base=$(cut -d '.' -f1 /proc/uptime); seconds=$(date +%s); dmesg | sed 's/\]//;s/\[//;s/\([^.]\)\.\([^ ]*\)\(.*\)/\1\n\3/' | while read first; do read second; first=`date +"%d/%m/%Y %H:%M:%S" –date="@$(($seconds – $base + $first))"`; printf "[%s] %s\n" "$first" "$second"; done exit 0 run it sh dmesg.sh.. System Echo: … [16/03/2018 14:55:18] br-lan: port 3(wlan1) entered blocking state [16/03/2018 14:55:18] br-lan: port 3(wlan1) entered disabled state [16/03/2018 14:55:18] device wlan1 entered promiscuous mode [16/03/2018 14:55:18] br-lan: port 3(wlan1) entered blocking state [16/03/2018 14:55:18] br-lan: port 3(wlan1) entered forwarding state [16/03/2018 14:55:19] br-lan: port […]

Impressum Datenschutz-DSGVO-GDPR

www.linuxonlinehelp.eu - Nonprofit Linux PC & Server Support since 2004 Tags: Linux Online Help, Linuxonlinehelp, Linux Support, Linux Hilfe