The who -b command desn't show me the last reboot times on my Raspberry 3

    :~ $ uname -a
Linux xxxxx 4.9.35-v7+ #1014 SMP Fri Jun 30 14:47:43 BST 2017 armv7l GNU/Linux
:~ $ who -b 
    system boot  1970-01-01 01:00

I configured the ntp daemon as the date is uptodate.

How to configure the system for getting this king of information.



Short answer. Use: uptime -s

You can use the uptime command to find out how long it has been since the Pi (or any Unix/Linux OS) has booted. The -s flag tells uptime to calculate the boot time.

The Pi doesn't have a real-time clock (though there are RTC chips that you can add). This means it does not know the date/time as it boots. If it has access to a network, it'll reach out to a time server to set these. But if it doesn't have a network, it will rely on a fake hardware clock (basically a file where it periodically writes the time. It isn't accurate but at least it fixes problems where log files have "newer" entries with older date/time stamps than "older" entries.

See: How is time kept on the Raspberry Pi?

| improve this answer | |

who -b is THE SAME for everyone.
The Pi DOES NOT know the time at boot.

| improve this answer | |
  • This is not a issue – dubis Feb 5 '18 at 15:39

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.