24時間PCを作動させていたり、何かしら一つのPCで作業していたり、遠隔地からPCをリモートで接続して作業させていたりすると気になるPCの「稼働時間」。
私の場合は遠隔地にある非力なPCにて、これまた非力なソフトウェアを随時稼働させていなくてはならず、時折勝手に再起動したりフリーズしたりしてしまう。
だからこそ、たまに稼働時間をチェックし、手動で再起動させたりしてる。
作業によっては自動で再起動させてもいいが、PC再起動後、ソフトウェアを自動させる設定にしていても、提供されているソフトウェアが非力すぎて作動時のパラメータが設定できない等があったり、パラメータが公開されていなかったりでマニュアル操作でないと使えないタイプがあるからだ。
言い換えれば本来「そのようなソフトウェアは使用するべきでは無い」ともいえるが、クライアントの意向は無視はできないだろう。
Windows XP Professional, Windows Vista, Windows 7, Windows 8.x, Windows 10の場合
英語版
<code>Systeminfo | Find "Up Time"</code>
日本語版
<code>Systeminfo | Find "起動時間"</code>
systeminfo.exeのコマンドレファレンスはページの一番したにあります。
Windows XP Homeの場合
Windows XP Home Editionの場合、そもそもXP Proの様にsysteminfo.exeというファイルはありません。
Microsoftからしてみれば、普通の一般ユーザーがこのようなコマンドライン型のソフトを使う機会が少ないと思ったからかもしれません。
ですが、代替として
- uptime.exe – Microsoft製 – http://support.microsoft.com/kb/232243/ – CUI (*1)
- uptime.exe – オープンソース – http://uptimeexe.codeplex.com/ – CUI (*1)
- WinAudit – Parmavex Services製 – http://pxserver.com/WinAudit.htm – GUI (*2)
*1 - CUI = Character User Interface; *2 = Graphical User Interface
と三種類の方法があります。
基本的にどれも英語です。
コマンドレファレンス
英語バージョン
<code>Microsoft Windows XP [Version 5.1.2600]
(C) Copyright 1985-2001 Microsoft Corp.
C:\WINDOWS>SYSTEMINFO /?
SYSTEMINFO [/S system [/U username [/P [password]]]] [/FO format] [/NH]
Description:
This command line tool enables an administrator to query for basic
system configuration information.
Parameter List:
/S system Specifies the remote system to connect to.
/U [domain\]user Specifies the user context under which
the command should execute.
/P [password] Specifies the password for the given
user context. Prompts for input if omitted.
/FO format Specifies the format in which the output
is to be displayed.
Valid values: "TABLE", "LIST", "CSV".
/NH Specifies that the "Column Header" should
not be displayed in the output.
Valid only for "TABLE" and "CSV" formats.
/? Displays this help/usage.
Examples:
SYSTEMINFO
SYSTEMINFO /?
SYSTEMINFO /S system
SYSTEMINFO /S system /U user
SYSTEMINFO /S system /U domain\user /P password /FO TABLE
SYSTEMINFO /S system /FO LIST
SYSTEMINFO /S system /FO CSV /NH</code>
コマンドレファレンス
日本語バージョン
<code>C:\Windows>systeminfo /?
SYSTEMINFO [/S システム [/U ユーザー名 [/P パスワード]]] [/FO 形式] [/NH]
説明:
コンピュータのオペレーティング システム構成情報を
Service Pack レベルを含むローカル コンピュータまたはリモート コンピュータ
パラメータ一覧:
/S システム 接続先のリモート システムを指定します。
/U [ドメイン\]ユーザー 実行するコマンドのユーザー コンテキストを指定
します。
/P [パスワード] 提供されたユーザー コンテキストのパスワードを指定
します。省略された場合は、入力を要求します。
/FO 形式 表示される形式を指定します。
有効な値: "TABLE", "LIST", "CSV"。
/NH 出力しない "カラム ヘッダー" を指定します。
"TABLE"と "CSV" の形式のみ有効です。
/? ヘルプを表示します。
例:
SYSTEMINFO
SYSTEMINFO /?
SYSTEMINFO /S システム
SYSTEMINFO /S システム /U ユーザー
SYSTEMINFO /S システム /U ドメイン\ユーザー /P パスワード /FO TABLE
SYSTEMINFO /S システム /FO LIST
SYSTEMINFO /S システム /FO CSV /NH</code>

コメント