| United States-English |
|
|
|
![]() |
HP-UX Remote Access Services Administrator's Guide: HP-UX 11i v2, HP-UX 11i v3 > Chapter 1 Remote Access Services OverviewR-Commands |
|
Remote command execution is a process on a host that causes a program to be executed on another host. Table 1-1 describes the different r-commands supported in the HP-UX 11i v2 operating system. Table 1-1 R-Commands
A description of all the r-commands is provided in the subsequent sections. The rlogin command connects the terminal on the local host to the remote host (rhost) and acts as a virtual terminal to the remote system. The host name rhost can either be the official name or an alias as listed in the /etc/hosts file. The syntax for the rlogin command is as follows:
In a Kerberos V5 network authentication environment, the syntax for the rlogin command is as follows:
If rlogin is unable to read from or write to the socket connection on the remote host, the following message is displayed on the standard error and rlogin exits:
In a non-secure, or traditional, environment, rlogin allows a user to log in to an equivalent remote host, rhost, using the normal login and password sequence, similar to the remsh command. For more information on equivalent hosts and how to specify them in the /etc/hosts.equiv and .rhosts files, type man 4 hosts.equiv at the HP-UX prompt. When you log in to a remote system, and if you have a user account equivalent to the remote account, you are prompted for the password of the remote account. If the login fails, a login name and password is prompted, similar to a login command. In a Kerberos V5 network authentication environment, rlogin uses the Kerberos V5 protocol to authenticate the connection to a remote host. If the authentication is successful, user authorization is performed according to the rlogind command-line options (that is, -K, -R, -k, or -r). You do not require a password to log in to a remote host in a Kerberos authentication environment. The Kerberos protocol is responsible for authenticating the remote connection. In a Kerberos environment, a password, which is confidential information, is not sent over the network for authentication. This is one of the advantages of a secure environment. Fore more information on Kerberos authentication and authorization, type man 5 sis (the Secure Internet Services manpage) or man 1M rlogind at the HP-UX prompt. You can set the default Kerberos options in the configuration file /etc/krb5.conf. You can set the -f and -F options with the tag names forward and forwardable, respectively, and set the fallback option within the appdefaults section in the krb5.conf file. If you set the fallback option to true and the Kerberos authentication fails, rlogin uses the non-secure mode for authentication. The -f and -F options are mutually exclusive. For more information, type man 4 krb5.conf at the HP-UX prompt. For more information on rlogin, type man 1 rlogin at the HP-UX prompt. rlogind is the server for the rlogin program. It provides remote login facility with the following authentication methods:
The inetd daemon invokes rlogind when a service request is received at ports indicated by the login or klogin services. These services are specified in the /etc/services file. For more information, type man 1M inetd or man 4 services at the HP-UX prompt. Service requests arriving at the klogin port are in a secure environment and Kerberos V5 handles the authentication of services. To start rlogind from the inetd deamon in the IPv4 mode, perform the following action: To start rlogind in IPv6 mode, add the following entry to the configuration file/etc/inetd.conf: After you add the necessary entry to the /etc/inetd.conf file, recompile inetd using the following command:
Now, inetd invokes rlogind with the service as specified in the /etc/inetd.conf file. For detailed information on rlogind, type man 1M rlogind at the HP-UX prompt. The remsh command enables you to connect to a remote host and execute commands. The host name can be either the official name or an alias that the function gethostbyname() is able to interpret. For more information, type man 3N gethostent or man 4 host at the HP-UX prompt. remsh exits when the sockets associated with the standard output (stdout) and standard error (stderr) are closed, that is, remsh and the remote command terminate at the same time. For more information, type man 1M remshd at the HP-UX prompt. remsh performs the following functions:
The syntax for remsh is as follows:
In a Kerberos V5 network authentication environment, the syntax for remsh is as follows:
By default, remsh uses the following path while executing a command:
You cannot use remsh to run commands that require a terminal interface (such as vi), or commands that read standard error (such as more). In such cases, you can use rlogin or telnet to connect to the remote host. See “The telnet Program” and “The rlogin Command” for more information. You can specify the remote account name in the remsh command by using the -l option. If you do not specify any option, the local account name is considered as the remote account name. The remote account name must be equivalent to the originating account. Additionally, the remote host account name must conform to other rules, depending upon whether the environment is secure (Kerberos V5 network authentication environment) or non-secure. In a non-secure, or traditional environment, the remote account name must be equivalent to the originating account. remsh enables a user to log in to an equivalent remote host, rhost, using the normal login and password sequence. For more information on equivalent hosts and how to specify them in the /etc/hosts.equiv and .rhosts files, type man 4 hosts.equiv at the HP-UX prompt. In a Kerberos V5 network authentication environment, the local host must be authenticated successfully before the remote account name is checked for proper authentication. The authorization mechanism depends on the command-line options used to invoke remshd on the remote host (-K, -R, -k, or -r). Fore more information on Kerberos authentication and authorization, type man 5 sis or man 1M rlogind at the HP-UX prompt. Kerberos authentication is used only to authorize the local host. All the information transferred between the local and the remote host is sent in text format over the network. You can set the default Kerberos options in the configuration file /etc/krb5.conf. You can set the -f and -F options with the tag names forward and forwardable, respectively, and set the fallback option within the appdefaults section in the /etc/krb5.conf file. If you set the fallback option to true and the Kerberos authentication fails, remsh uses the non-secure mode of authentication. The -f and -F options are mutually exclusive. For more information, type man 4 krb5.conf at the HP-UX prompt. The rexec command differs from the remsh command in the following ways:
You must use the rexec command in instances where you are aware of the password to a remote account but you do not have sufficient permission for remsh. For detailed information on remsh and rexec, type man 1 remsh at the HP-UX prompt. The rcp command copies files, directory subtrees, or a combination of files and directory subtrees from one or more systems to another. In many respects, it is similar to the cp command. The syntax for the rcp command is as follows:
To use rcp, you must have read access to the files being copied, and read and execute permission on all directories in the directory path. Third-party transfers have special requirements. In a Kerberos V5 network authentication environment, rcp uses the Kerberos V5 protocol to initiate the connection to a remote host. The authorization mechanism depends on the command-line options that invoke remshd on the remote host (-K, -R, -k, or -r). For a detailed description of the Kerberos authentication and authorization rules, type man 5 sis on the HP-UX prompt. Although the rcp command uses Kerberos authentication and authorization, it does not apply the Kerberos mechanism while copying files. The files are transferred in text format over the network. You can set the default Kerberos options in the configuration file /etc/krb5.conf. You can set the -f and -F options with the tag names forward and forwardable, respectively, and set the fallback option within the appdefaults section in the /etc/krb5.conf file. If you set the fallback option to true and the Kerberos authentication fails, rcp uses the non-secure mode of authentication. The -f and -F options are mutually exclusive. For more information, type man 4 krb5.conf at the HP-UX prompt. Table 1-2 describes the rcp options and arguments. Table 1-2 rcp Options and Arguments
For detailed information on rcp, type man 1 rcp at the HP-UX prompt. rdist allows you to maintain identical copies of files over multiple hosts. It preserves the owner, group, mode, and modification time of files and updates executing programs.The syntax for rdist is as follows:
The distfile in the rdist command contains a sequence of entries that specify the files to be copied, the destination hosts, and operations to perform while updating. Each entry has one of the following formats:
Table 1-3 The distfile Entries
describes the distfile entries. Table 1-4 describes the rdist options. Table 1-4 rdist Options
For detailed information on rdist, type man 1 rdist at the HP-UX prompt. ruptime produces a status line for each machine on the local network that is running the rwho daemon. ruptime’s status lines are formed from packets broadcasted every 3 minutes between the rwho daemons on each host on the network. Each status line has a field for the machine name, the status of the machine, the time duration for which the machine was up or down, the number of users logged in to the machine, and the 1-, 5-, and 15-minute load averages for the machine when the packet was sent. The syntax for ruptime is as follows:
The status of the machine is reported as up unless no report is received from the machine for 11 minutes. The time duration for which the machine is up is shown as follows:
Load averages are the average number of jobs in the run queue over the last 1-, 5-, and 15-minute intervals when the packet was sent. An example status line output by ruptime is as follows:
The output line indicates that machine1:
If a user has not used the system for an hour or more, the user is considered idle. Idle users are not shown unless you specify the -a option. Table 1-5 describes the options that change the sorting order. If you do not specify any option, the listing is sorted by host name. Table 1-5 Sorting Order Options
For detailed information on ruptime, type man 1 ruptime at the HP-UX prompt. The rwho command displays who is logged in to the local system. rwho displays output similar to the HP-UX who command for all the machines on the local network running the rwho daemon. If rwhod does not receive a report from a machine for 11 minutes, rwho assumes that the machine is down and does not report the information about last known users. rwho’s output contains fields for the user name, the machine name, the user’s terminal line, the time the user logged in, and the time period for which the user is idle. The idle time is shown as hours:minutes. If a user is inactive for 1 minute, rwho reports this as idle time. If a user is inactive for 1 hour or more, the user is omitted from rwho’s output unless the -a flag is specified. An example rwho output is as follows:
The output line indicates that joe_user has:
For detailed information on rwho, type man 1 rwho at the HP-UX prompt. rwhod is the server that maintains the database used by the rwho and ruptime commands. rwhod sends and receives status information from other nodes running the rwhod daemon on the local network. rwhod performs the following functions as an information sender:
rwhod performs the following functions as an information receiver:
By default, rwhod sends and receives information. You can configure rwhod to either send or receive information by using the -s and -r options, respectively. rwhod starts during system startup if the variable RWHO is set to 1 in the /etc/rc.config.d/netdaemons file. For more information, type man 1M rwhod at the HP-UX prompt. |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
|||||||||||||||