Print this page
293 useradd/del/mod should be ZFS-aware
   1 USERADD(1M)                  Maintenance Commands                  USERADD(1M)
   2 
   3 
   4 
   5 NAME
   6        useradd - administer a new user login on the system
   7 
   8 SYNOPSIS
   9        useradd [-A authorization [,authorization...]]
  10             [-b base_dir] [-c comment] [-d dir] [-e expire]
  11             [-f inactive] [-g group] [-G group [,group]...]
  12             [-K key=value] [-m [-k skel_dir]] [-p projname]
  13             [-P profile [,profile...]] [-R role [,role...]]
  14             [-s shell] [-u uid [-o]] login
  15 
  16 
  17        useradd -D [-A authorization [,authorization...]]
  18             [-b base_dir] [-s shell [-k skel_dir]] [-e expire]
  19             [-f inactive] [-g group] [-K key=value] [-p projname]
  20             [-P profile [,profile...]] [-R role [,role...]]
  21 
  22 
  23 DESCRIPTION
  24        useradd adds a new user to the /etc/passwd and /etc/shadow and
  25        /etc/user_attr files. The -A and -P options respectively assign
  26        authorizations and profiles to the user. The -R option assigns roles to
  27        a user. The -p option associates a project with a user. The -K option
  28        adds a key=value pair to /etc/user_attr for the user. Multiple
  29        key=value pairs may be added with multiple -K options.
  30 
  31 
  32        useradd also creates supplementary group memberships for the user (-G


 172            NGROUPS_MAX groups can be specified. GIDs 0-99 are reserved for
 173            allocation by the Solaris Operating System.
 174 
 175 
 176        -K key=value
 177            A key=value pair to add to the user's attributes. Multiple -K
 178            options may be used to add multiple key=value pairs. The generic -K
 179            option with the appropriate key may be used instead of the specific
 180            implied key options (-A, -P, -R, -p). See user_attr(4) for a list
 181            of valid key=value pairs. The "type" key is not a valid key for
 182            this option. Keys may not be repeated.
 183 
 184 
 185        -k skel_dir
 186            A directory that contains skeleton information (such as .profile)
 187            that can be copied into a new user's home directory. This directory
 188            must already exist. The system provides the /etc/skel directory
 189            that can be used for this purpose.
 190 
 191 
 192        -m
 193            Create the new user's home directory if it does not already exist.
 194            If the directory already exists, it must have read, write, and
 195            execute permissions by group, where group is the user's primary
 196            group.






 197 
 198 
 199        -o
 200            This option allows a UID to be duplicated (non-unique).
 201 
 202 
 203        -P profile
 204            One or more comma-separated execution profiles defined in
 205            prof_attr(4).
 206 
 207 
 208        -p projname
 209            Name of the project with which the added user is associated. See
 210            the projname field as defined in project(4).
 211 
 212 
 213        -R role
 214            One or more comma-separated execution profiles defined in
 215            user_attr(4).  Roles cannot be assigned to other roles.
 216 


   1 USERADD(1M)                  Maintenance Commands                  USERADD(1M)
   2 
   3 
   4 
   5 NAME
   6        useradd - administer a new user login on the system
   7 
   8 SYNOPSIS
   9        useradd [-A authorization [,authorization...]]
  10             [-b base_dir] [-c comment] [-d dir] [-e expire]
  11             [-f inactive] [-g group] [-G group [,group]...]
  12             [-K key=value] [-m [-z|-Z] [-k skel_dir]] [-p projname]
  13             [-P profile [,profile...]] [-R role [,role...]]
  14             [-s shell] [-u uid [-o]] login
  15 
  16 
  17        useradd -D [-A authorization [,authorization...]]
  18             [-b base_dir] [-s shell [-k skel_dir]] [-e expire]
  19             [-f inactive] [-g group] [-K key=value] [-p projname]
  20             [-P profile [,profile...]] [-R role [,role...]]
  21 
  22 
  23 DESCRIPTION
  24        useradd adds a new user to the /etc/passwd and /etc/shadow and
  25        /etc/user_attr files. The -A and -P options respectively assign
  26        authorizations and profiles to the user. The -R option assigns roles to
  27        a user. The -p option associates a project with a user. The -K option
  28        adds a key=value pair to /etc/user_attr for the user. Multiple
  29        key=value pairs may be added with multiple -K options.
  30 
  31 
  32        useradd also creates supplementary group memberships for the user (-G


 172            NGROUPS_MAX groups can be specified. GIDs 0-99 are reserved for
 173            allocation by the Solaris Operating System.
 174 
 175 
 176        -K key=value
 177            A key=value pair to add to the user's attributes. Multiple -K
 178            options may be used to add multiple key=value pairs. The generic -K
 179            option with the appropriate key may be used instead of the specific
 180            implied key options (-A, -P, -R, -p). See user_attr(4) for a list
 181            of valid key=value pairs. The "type" key is not a valid key for
 182            this option. Keys may not be repeated.
 183 
 184 
 185        -k skel_dir
 186            A directory that contains skeleton information (such as .profile)
 187            that can be copied into a new user's home directory. This directory
 188            must already exist. The system provides the /etc/skel directory
 189            that can be used for this purpose.
 190 
 191 
 192        -m [-z|-Z]
 193            Create the new user's home directory if it does not already exist.
 194            If the directory already exists, it must have read, write, and
 195            execute permissions by group, where group is the user's primary
 196            group.  CHANGE_ZFS_FS option in /etc/default/useradd file
 197            determines if ZFS filesystem will be created for new user. If this
 198            option is set to yes and parent directory of user's home directory
 199            is ZFS filesystem mount point, a new ZFS filesystem is created. -z
 200            and -Z options allow overwrite default behavior.  If -z option is
 201            specified, useradd tries to create new file system for user. If -Z
 202            option is specified, new file system is not created.
 203 
 204 
 205        -o
 206            This option allows a UID to be duplicated (non-unique).
 207 
 208 
 209        -P profile
 210            One or more comma-separated execution profiles defined in
 211            prof_attr(4).
 212 
 213 
 214        -p projname
 215            Name of the project with which the added user is associated. See
 216            the projname field as defined in project(4).
 217 
 218 
 219        -R role
 220            One or more comma-separated execution profiles defined in
 221            user_attr(4).  Roles cannot be assigned to other roles.
 222