Print this page
OS-4136 would like SIGUSR to zlogin to switch in and out of '-N' modes
Reviewed by: Jerry Jelinek <jerry.jelinek@joyent.com>
OS-4109 'zlogin -I' should close /dev/zfd/0 when it exits
OS-3524 in order to support interaction with docker containers, need to be able to connect to stdio for init from GZ
OS-3525 in order to support 'docker logs' need to be able to get stdio from zone to log file
OS-3529 would like zlogin -i
Reviewed by: Jerry Jelinek <jerry.jelinek@joyent.com>

@@ -4,28 +4,29 @@
 
 NAME
        zlogin - enter a zone
 
 SYNOPSIS
-       zlogin [-dCEQ] [-e c] [-l username] zonename
+       zlogin [-dCEINQ] [-e c] [-l username] zonename
 
 
-       zlogin [-nEQS] [-e c] [-l username] zonename utility
+       zlogin [-inEQS] [-e c] [-l username] zonename utility
             [argument]...
 
 
 DESCRIPTION
        The zlogin utility is used by the administrator to enter an operating
        system zone. Only a superuser operating in the global system zone can
        use this utility.
 
 
-       zlogin operates in one of three modes:
+       zlogin operates in one of four modes:
 
        Interactive Mode
-                               If no utility argument is given and the stdin
-                               file descriptor for the zlogin process is a tty
+                               If no utility argument is given or if the -i
+                               option is specified, and the stdin file
+                               descriptor for the zlogin process is a tty
                                device, zlogin operates in interactive mode. In
                                this mode, zlogin creates a new pseudo terminal
                                for use within the login session. Programs
                                requiring a tty device, for example, vi(1),
                                work properly in this mode. In this mode,

@@ -32,18 +33,18 @@
                                zlogin invokes login(1) to provide a suitable
                                login session.
 
 
        Non-Interactive Mode
-                               If a utility is specified, zlogin operates in
-                               non-interactive mode.  This mode can be useful
-                               for script authors since stdin, stdout, and
-                               stderr are preserved and the exit status of
-                               utility is returned upon termination. In this
-                               mode, zlogin invokes su(1M) in order to set up
-                               the user's environment and to provide a login
-                               environment.
+                               If a utility is specified and the -i option is
+                               not specified, zlogin operates in non-
+                               interactive mode.  This mode can be useful for
+                               script authors since stdin, stdout, and stderr
+                               are preserved and the exit status of utility is
+                               returned upon termination. In this mode, zlogin
+                               invokes su(1M) in order to set up the user's
+                               environment and to provide a login environment.
 
                                The specified command is passed as a string and
                                interpreted by a shell running in the non-
                                global zone. See rsh(1).
 

@@ -55,10 +56,16 @@
                                available once the zone is in the installed
                                state. Connections to the console are
                                persistent across reboot of the zone.
 
 
+       Standalone-processs Interactive Mode
+                               If the -I option is specified the user is
+                               connected to the zone's stdin, stdout and
+                               stderr zfd(7D) devices.
+
+
 OPTIONS
        The following options are supported:
 
        -C
                       Connects to the zone console.

@@ -80,10 +87,20 @@
                       Disables the ability to access extended functions or to
                       disconnect from the login by using the escape sequence
                       character.
 
 
+       -i
+                      Forces interactive mode when a utility argument is
+                      specified.
+
+
+       -I
+                      Connects to the zone's zfd(7D) devices.
+
+
+
        -l username
                       Specifies a different username for the zone login. If
                       you do not use this option, the zone username used is
                       "root". This option is invalid if the -C option is
                       specified.

@@ -94,10 +111,17 @@
                       is useful when the command running in the local zone and
                       the shell which invokes zlogin both read from standard
                       input.
 
 
+       -N
+                      Nohup. This may only be used with the -I option to avoid
+                      sending EOF to the zfd device when zlogin's stdin
+                      receives EOF. It can also be toggled by sending SIGUSR1
+                      to an attached zlogin process.
+
+
        -Q
                       Specifies quiet mode operation.  In quiet mode, extra
                       messages indicating the the function of zlogin will not
                       be displayed, giving the possibility to present the
                       appearance that the command is running locally rather

@@ -193,6 +217,6 @@
        corresponds to an NFS file. This includes the executable itself or the
        shared libraries.
 
 
 
-                                March 17, 2015                       ZLOGIN(1)
+                                March 30, 2015                       ZLOGIN(1)