How long system has been awake / running / since restart
Use uptime
command. Yes, it includes sleep time, if you don't want to include it see:
- How to find the uptime since last wake from standby?.
There is no way to distinguish between restart and shutdown, without parsing logs.