In 1:1 direct mode, the NISH client connects directly to a single SR OS node and operates
the MD-CLI from a local Linux workstation.
The following figure shows the communication for 1:1 direct mode.
Figure 1. Communication between the NISH client and the SR OS node
Prerequisites
Review the following requirements before using the NISH client in 1:1 direct
mode.
-
Ensure that you have permission to access the gRPC interface and the MD-CLI
gRPC service of the target node.
-
The nish command can be issued from the command line,
providing a username, hostname (or IP address), and port number of the
target SR OS node. Alternatively, the hostname and the port number can be
defined using environment variables or in a NISH rc
file. In this case, the nish command can be entered
without these arguments. See NISH rc files for more information about
configuring rc files.
Note: The arguments defined in environment variables or in the NISH
rc file must be supported in the current mode of
operation. If arguments for another mode of operation are defined, the NISH
client fails and returns an error.
To use the NISH client in 1:1 direct mode, perform the following steps:
Procedure
-
Execute the nish command from the command line, providing a
username, hostname (or IP address), and port number of the target SR OS node.
nish [OPTIONS] [-l
user] [-p
port-number]
[user]@hostname
You can specify the user with the -l flag or
--login-name option, together with the hostname in
the format user@hostname, or in the $NISH_USER environment variable. If you
do not specify a user with any of these options, the default $USER
environment variable is used.
The port number defines the target node TCP port. If it is not set, the
default port 57400 is used. To specify a
non-default port number use the -p flag or
--port option.
The hostname defines the target SR OS node. FQDN, hostname, IPv4 address, or
IPv6 address formats are accepted. See Command options, for
information about other command options.
Example:
[root@server ~]# nish admin@test1
In this example:
- The name of the SR OS node user who has the required permissions is
admin.
- The hostname of the node is test1.
- 57400 is the default port and does not need to be specified
explicitly.
Note: If the user, target host, and target port are defined in environment
variables or in a NISH rc file, and no other options
are needed, the nish command can be used without these
arguments.
-
Enter the password for the SR OS node when prompted.