clogin Command

Purpose

Initiates a user session or runs a command within a workload partition.

Syntax

clogin WparName [-l User] [ command [ args ] ]

Description

The clogin command provides a mechanism for the root user to log in or run a command within a workload partition.

When you specify the -l flag, a session is initiated as if the session was started by the user specified using the User parameter in the workload partition. If a subsequent command is specified, the command runs as if it was launched as a parameter to the login shell associated with the User. The clogin command performs similar operations as the su command, so all of the functions that are associated with the su command apply to the clogin command.

Note: The pseudo-terminal on which the session is initiated belongs to the global environment, but the login shell running in the terminal belongs to the workload partition.

Flags

Item Description
WparName The name of the workload partition in which to log in.
-l User Specifies the user name to log in the workload partition. Default is root. If you specify the command parameter, you must specify both the -l flag and the User parameter.
command Specifies the command running within the workload partition. The command runs as a parameter to the login shell that is associated with the user.
args Specifies optional parameters to use when the command that is specified by the command parameter runs.

Security

Item Description
Access Control Only the root user can run the command.

Examples

  1. To log in to a workload partition named bucko as user dan, enter the following command:
    clogin bucko -l dan
  2. To run the /usr/bin/ps command with the -T 1 option as user root in a workload partition named howdy, enter the following command:
    clogin howdy -l root /usr/bin/ps -T 1