PuTTY を使用した CLI への接続
PuTTY および plink ユーティリティーの実行方法について熟知していることが必要です。
セキュア・シェル (SSH) プロトコルでは、新しいホスト・サーバーへの最初のアクセス時に、SSH サーバー公開鍵またはユーザー・パスワードを受け入れるための確認の問い合わせを SSH ユーザーに送信することを指定しています。 今回は SSH サーバーへの初めての接続であるため、サーバーは、既知のホストの SSH クライアント・リストに含まれていません。 したがって、フィンガープリント確認の問い合わせが行われ、その際に、ホストとの接続を行う役割を受け入れるかどうかが尋ねられます。 y を入力すると、ホストのフィンガープリントと IP アドレスが SSH クライアントによって保管されます。
PuTTY を使用する場合は、さらに y を入力して、このホストのフィンガープリントを受け入れる必要があります。 しかし、ホストの指紋と IP アドレスは、Windows にログオンしているユーザー名のレジストリーに保管されます。
また、SSH プロトコルでは、SSH サーバー公開鍵が受け入れられた後、SSH サーバーのフィンガープリントが以前に受け入れられたものと異なる場合、確認の問い合わせを再度送信することを指定しています。この場合、変更されたこのホストのフィンガープリントを受け入れるかどうかを決める必要があります。
- 対話式プロンプト・モード
- 単一行コマンド・モード。このモードに入ると、一度ですべてのパラメーターを含めることができます。
対話モード
対話モードの場合、PuTTY 実行可能プログラムを使用して、SSH 限定シェルをオープンできます。
C:\support utils\putty <username>@svcconsoleip
ここで、support utils¥putty は putty.exe ファイルの場所、<username> は 管理 GUI の IP アドレス、<username> は使用するユーザー名です。
IBM_2145:cluster0:superuser>lsuser
id name password ssh_key remote usergrp_id usergrp_name
0 superuser yes yes no 0 SecurityAdmin
1 smith no yes no 4 Monitor
2 jones no yes no 2 CopyOperator
exit と入力し Enter を押すと、対話モード・コマンドをエスケープできます。
以下に、対話モードで plink を使用する場合の、ホストの指紋確認の問い合わせの例を示します。
C:\Program Files\IBM\svcconsole\cimom>plink superuser@9.43.225.208
The server's host key is not cached in the registry. ユーザー
have no guarantee that the server is the computer you
think it is.
The server's key fingerprint is:
ssh-rsa 1024 e4:c9:51:50:61:63:e9:cd:73:2a:60:6b:f0:be:25:bf
If you trust this host, enter "y" to add the key to
PuTTY's cache and carry on connecting.
If you want to carry on connecting just once, without
adding the key to the cache, enter "n".
If you do not trust this host, press Return to abandon the
connection.
Store key in cache? (y/n) y
Using user name "superuser".
Authenticating with public key "imported-openssh-key"
IBM_2145:your_cluster_name:superuser>
単一行コマンド
単一行コマンド・モードでは、1 つのコマンド・ラインに以下のすべてを入力できます。
C:¥Program Files¥IBM¥svcconsole¥cimom>
plink superuser@9.43.225.208 lsuser
Authenticating with public key "imported-openssh-key"
id name password ssh_key remote usergrp_id usergrp_name
0 superuser yes yes no 0 SecurityAdmin
1 smith no yes no 4 Monitor
2 jones no yes no 2 CopyOperator
以下に、単一行コマンド・モードで plink を使用する場合の、ホストの指紋確認の問い合わせの例を示します。
C:¥Program Files¥IBM¥svcconsole¥cimom>
plink superuser@9.43.225.208 lsuser
The server's host key is not cached in the registry. ユーザー
have no guarantee that the server is the computer you
think it is.
The server's key fingerprint is:
ssh-rsa 1024 e4:c9:51:50:61:63:e9:cd:73:2a:60:6b:f0:be:25:bf
If you trust this host, enter "y" to add the key to
PuTTY's cache and carry on connecting.
If you want to carry on connecting just once, without
adding the key to the cache, enter "n".
If you do not trust this host, press Return to abandon the
connection.
Store key in cache? (y/n) y
Authenticating with public key "imported-openssh-key"
id name password ssh_key remote usergrp_id usergrp_name
0 superuser yes yes no 0 SecurityAdmin
1 smith no yes no 4 Monitor
2 jones no yes no 2 CopyOperator