If you want to find the duration of time a linux server is up or active, you can use uptime command
uptime - tell how long the system has been running
Format
uptime [OPTION]... [ FILE ]
DESCRIPTION
Print the current time, the length of time the system has been up, the number
...
Read more »