3PAR InForm® OS 2.3.1 CLI Administrator's Manual (320-200180 Rev B, February 2010)

3.25
SSH
InForm OS Version 2.3.1 3PAR InForm CLI Administrator’s Manual
Ensure that only the owner has access and read/write permission on the private key file,
otherwise the SSH client refuses the key file.
3 Log onto an InServ system from any system with the SSH client installed.
4 Issue the
setsshkey command.
5 Write your script. See the following example:
$ssh user3@system1
user3@system1’s password: testpw3
system1 cli% setsshkey
setsshkey
Please enter the SSH public key below. When finished, press enter twice.
The key is usually long. It's better to copy it from inside an editor and
paste it here. (Please make sure there is no extra blanks.)
ssh–rsa AF5afPdciUTJ0PYzB6msRxFrCuDSqDwPshqWS5tGCFSoSZdE= user3’s pubic key
SSH public key successfully set!
#!/bin/sh
# Assume that the user name “user3” exists on system1
# The private key file “id_rsa” is accessible.
SSH="ssh –i id_rsa –l user3 system1 "
#
# Execute the command passed in as command line argument $1
${SSH} $1