Searching the Help
To search for information in the Help, type a word or phrase in the Search box. When you enter a group of words, OR is inferred. You can use Boolean operators to refine your search.
Results returned are case insensitive. However, results ranking takes case into account and assigns higher scores to case matches. Therefore, a search for "cats" followed by a search for "Cats" would return the same number of Help topics, but the order in which the topics are listed would be different.
Search for | Example | Results |
---|---|---|
A single word | cat
|
Topics that contain the word "cat". You will also find its grammatical variations, such as "cats". |
A phrase. You can specify that the search results contain a specific phrase. |
"cat food" (quotation marks) |
Topics that contain the literal phrase "cat food" and all its grammatical variations. Without the quotation marks, the query is equivalent to specifying an OR operator, which finds topics with one of the individual words instead of the phrase. |
Search for | Operator | Example |
---|---|---|
Two or more words in the same topic |
|
|
Either word in a topic |
|
|
Topics that do not contain a specific word or phrase |
|
|
Topics that contain one string and do not contain another | ^ (caret) |
cat ^ mouse
|
A combination of search types | ( ) parentheses |
|
rosh utility
The Remote SA Shell (rosh
) command makes a client connection that enables you to remotely run programs on managed servers. You invoke the rosh
command from within a Global Shell session.
rosh syntax
For servers, the rosh
command has the following syntax:
rosh (-n server-name | -i server-id)[-d dir] [-l login-name]
[-s] [-t | -T] [command [arg ...]]
For network devices, the rosh
command has the following syntax:
rosh (-n device-name | -i device-id) [-N] [-C comment]
[-L] [-P parameters] [-s] -[-V variables] [command [arg ...]]
The following table describes the rosh
options of the preceding syntax statements.
Option |
Description |
---|---|
-3
|
|
|
A comment for the log of a network script invocation. |
|
Sets the working directory (path) on the remote server. The default is the remote user’s home directory. |
|
|
|
|
|
Specifies the server by its ID, which must already exist in the |
|
Specifies the login name of the remote user who performs operations on a remote server, which must already exist in the |
|
The network script should be run line-by-line. |
|
Network device mode. |
|
Specifies the server by its name, which must already exist in the |
|
The -i or -n option refers to a network device instead of a server. |
|
Parameters for a network advanced script. |
|
Relays RDP data to a managed server (on Windows). |
|
Treats a command as the name of a saved script that will be sent to and run on the remote server. |
|
Forces the remote session to run in a pseudo terminal (for UNIX servers only). |
-T
|
Forces the remote session to run without a pseudo terminal (for UNIX servers only). |
-v
|
|
-V variables
|
Variables for a network command or advanced script. |
|
Inactivity time out. |
|
Overall time out. |
|
Runs a program or saved script. |
rosh usage rules
The following usage rules apply to the rosh
program:
- Specify either the
-n
or-i
option to log into or run programs on a managed server. These options are mutually exclusive, but if both are specified the-i
option has precedence. - If neither the
-n
,-i,
andid
options are specified, the managed server can be inferred if your working directory is at or below:/opsw/Server/.../server-name/
Or/opsw/.Server.ID/server-id/
- If
-r
is specified, no other option (excluding-n
or-i
) can be specified. - If
-l
is not specified, the login-name can be inferred if your working directory is at or below:/opsw/Server/.../server-name/files/login-name/
Or/opsw/.Server.ID/server-id/files/login-name/
- If
-s
is specified and command is a saved shared script with asetuid
policy, thelogin-name
specified by the-l
option will be overridden. In this case, the-l
option may be omitted. These scripts are stored in/opsw/Script/Shared
. - If your working directory is not below server
/files/
login-name and-d
is not specified, thecwdpath
defaults to the home directory for login-name
. To default to the home directory, you must specify-l
. - For network scripts, if your current working directory is below a network device directory in the OFGS, you do not need to specify the device with -
N
, -n
or -i
. The network device is implied by the current working directory. - For network scripts, if the full path of the script is not specified,
rosh
uses the search path indicated by theNETWORK_SCRIPT_PATH
environment variable. If this variable is not set,rosh
searches for the script in these directories:/opsw/Script/Network/Command/
/opsw/Script/Network/Diagnostic/
/opsw/Script/Network/Advanced/
rosh operations
The rosh
command establishes a client connection that enables you to remotely run programs on managed servers. The SA Global Shell feature provides the following modes of operation for rosh
:
- jump: This operation starts a shell session in a pseudo-terminal on a managed server. This mode operates when you do not use the
-s
option and when you do not specify a command or a script. You must have theloginToServer
permission on the managed server to jump. - reach: This is a remote execution of commands that are native to the platform (operating system) of the managed server. This mode operates when you specify a command. You must have the
runCommandOnServer
permission on the managed server to reach. - push: This is a remote execution of a script on a managed server. The script is stored in the OGFS and is sent to the managed server by
rosh
. You must have therunCommandOnServer
permission on the managed server.
rosh examples
The following examples illustrate what these operations look like for an SA user named psi
at this path:
/opsw/Server/@/salish.snv1.corp.opsware.com/files/root/etc
[psi@m168 etc](538) $ uname -n; id; pwd
m168.dev.opsware.com
uid=59796(psi) gid=59796(psi) groups=59796(psi)
/opsw/Server/@/salish.snv1.corp.opsware.com/files/root/etc
The rosh
jump command would display the following information about the managed server:
[psi@m168 etc](539) $ rosh
[root@salish etc]# uname -n; id; pwd
salish.snv1.corp.opsware.com
uid=0(root) gid=0(root)
groups=0(root),1(bin),2(daemon),3(sys),4(adm),6(disk),10(wheel),12(mail),7(lp),4(adm),9(kmem),6(disk),5(tty),3(sys),2(daemon),8(mem)
/etc
[root@salish etc]# logout
The rosh
reach command displays the following information about the managed server:
[psi@m168 etc](541) $ rosh "uname -n; id; pwd"
salish.snv1.corp.opsware.com
uid=0(root) gid=0(root)
groups=0(root),1(bin),2(daemon),3(sys),4(adm),6(disk),10(wheel),12(mail),7(lp),4(adm),9(kmem),6(disk),5(tty),3(sys),2(daemon),8(mem)
/etc
The rosh
push command displays the following information about the managed server:
[psi@m168 etc](544) $ cat /tmp/who.sh
#!/bin/sh
uname -n
id
pwd
[psi@m168 etc](543) $ rosh -s /tmp/who.sh
salish.snv1.corp.opsware.com
uid=0(root) gid=0(root)
groups=0(root),1(bin),2(daemon),3(sys),4(adm),6(disk),10(wheel),12(mail),7(lp),4(adm),9(kmem),6(disk),5(tty),3(sys),2(daemon),8(mem)
/etc
The following example runs a script on a network device:
$ cd /opsw/Network/@/sw-ee-1-2b
$ rosh -s -C 'Updating device location' \
-V 'Location=Opsware - Sunnyvale' 'Set Location'
run script task 8725081 completed successfully.
Results:
Script 'Set Location for Cisco IOS configuration (for drivers: Cisco switches, Catalyst 2950, 3550, 3750 & 8500 series, IOS version 12.x)' completed.
We welcome your comments!
To open the configured email client on this computer, open an email window.
Otherwise, copy the information below to a web mail client, and send this email to hpe_sa_docs@hpe.com.
Help Topic ID:
Product:
Topic Title:
Feedback: