Windows:稼働時間コマンド-CMDとPowerShell

Windows

組み込みのWindowsはまだありませんが uptime コマンド、サーバー/ワークステーションの実際の稼働時間、またはシステムの起動時間は、コマンドラインから確認できます。

このメモでは、コマンドラインプロンプトとPowerShellからWindowsの稼働時間を確認する方法をいくつか紹介します。

Windows稼働時間コマンド

PowerShellとCMD: 以下の各コマンドは、コマンドラインプロンプト(CMD)とPowerShellの両方から機能します。

Windowsの稼働時間は、 wmic コマンド:

C:\> wmic os get lastbootuptime

コマンドラインプロンプトからWindowsの稼働時間を確認する別の方法は、の出力からシステムの起動時間を取得することです。 systeminfo コマンド:

C:\> systeminfo
- or -
C:\> systeminfo | find "System Boot Time:"

また、Windowsサーバー/ワークステーションの稼働時間は、 net statistics 統計が実行されてからの日付と時刻を返すコマンド。これは、Windowsの起動時間にほぼ対応します。

Windowsサーバーの稼働時間:

C:\> net statistics server 
- or -
C:\> net statistics server | find "Statistics since"

Windowsワークステーションの稼働時間:

C:\> net statistics workstation
- or -
C:\> net statistics workstation | find "Statistics since"

Hope this helps!

Source link

コメントを残す

メールアドレスが公開されることはありません。 が付いている欄は必須項目です