Uptime (LastBootTime): Unterschied zwischen den Versionen

Aus Wiki-WebPerfect
Wechseln zu: Navigation, Suche
K
K
Zeile 4: Zeile 4:
  
 
=== Startzeit eines Remote System anzeigen ===
 
=== Startzeit eines Remote System anzeigen ===
<source lang="powershell"> Get-CimInstance -ClassName win32_operatingsystem -CimSession FPPW0180 | select csname, lastbootuptime</source>
+
<source lang="powershell"> Get-CimInstance -ClassName win32_operatingsystem -CimSession <Hostname> | select csname, lastbootuptime</source>
 
oder
 
oder
 
<source lang="powershell"> Invoke-Command -ComputerName <Hostname> -Credential (Get-Credential) -ScriptBlock {Get-CimInstance -ClassName win32_operatingsystem | select csname, lastbootuptime}</source>
 
<source lang="powershell"> Invoke-Command -ComputerName <Hostname> -Credential (Get-Credential) -ScriptBlock {Get-CimInstance -ClassName win32_operatingsystem | select csname, lastbootuptime}</source>

Version vom 12. Juni 2017, 16:14 Uhr

Startzeit eines Systems anzeigen

Get-CimInstance -ClassName win32_operatingsystem | select csname, lastbootuptime


Startzeit eines Remote System anzeigen

 Get-CimInstance -ClassName win32_operatingsystem -CimSession <Hostname> | select csname, lastbootuptime

oder

 Invoke-Command -ComputerName <Hostname> -Credential (Get-Credential) -ScriptBlock {Get-CimInstance -ClassName win32_operatingsystem | select csname, lastbootuptime}