Wednesday, February 10, 2016

PowerShell Tips : Finding last boot time by using PowerShell.


Want to find out when the last your server/laptop boot up? We have a simple solution for it ;) use the below class ...


Get-CimInstance -ClassName win32_operatingsystem 



Get-CimInstance -ClassName win32_operatingsystem | select  lastbootuptime




With Regards.
Aman Dhally
If you like, you can follow me on Twitter and Facebook. You can also check my “You Tube channel for PowerShell video tutorials. You can download all of my scripts from “Microsoft TechNet Gallery”.

1 comment:

  1. New-TimeSpan -Seconds (Get-WmiObject Win32_PerfFormattedData_PerfOS_System).SystemUptime | Format-Table Days,Hours,Minutes