How to get the Windows/Linux PC uptime

Jephe Wu - http://linuxtechres.blogspot.com

Objective: get to know when a computer was rebooted last time and uptime since then.
Environment: Windows XP SP3, Windows 7, RHEL 5 and its varieties


1. windows (check when last time a computer was rebooted, so you can also know the uptime)
net statistics[stats] server[srv] 
or 
net statistics[stats] workstation[work]

note: looking for the beginning of the output, 'Statistics since' time, it shows when the computer was rebooted last time.

1.1. Windows uptime
and type in systeminfo after cmd, look for 'system up time'
systeminfo | find "up time" /i

for Windows 7, press Shift+Ctrl+Esc, performance tab, system, uptime

2.  Linux 
just run 'uptime'

3. References
http://www.optimizewindows7.net/windows7/determine-windows-7-uptime/
http://www.windowsreference.com/general/how-to-find-the-system-uptime-in-windows-vistaserver-2008xp2003/
http://support.microsoft.com/kb/555737
http://support.microsoft.com/kb/232243
http://www.ehow.com/how_5915486_tell-last-time-computer-rebooted.html