Print this page
293 useradd/del/mod should be ZFS-aware

*** 8,37 **** usermod \- modify a user's login information on the system .SH SYNOPSIS .LP .nf \fBusermod\fR [\fB-u\fR \fIuid\fR [\fB-o\fR]] [\fB-g\fR \fIgroup\fR] [\fB-G\fR \fIgroup\fR [, \fIgroup\fR...]] ! [\fB-d\fR \fIdir\fR [\fB-m\fR]] [\fB-s\fR \fIshell\fR] [\fB-c\fR \fIcomment\fR] [\fB-l\fR \fInew_name\fR] [\fB-f\fR \fIinactive\fR] [\fB-e\fR \fIexpire\fR] [\fB-A\fR \fIauthorization\fR [, \fIauthorization\fR]] [\fB-P\fR \fIprofile\fR [, \fIprofile\fR]] [\fB-R\fR \fIrole\fR [, \fIrole\fR]] [\fB-K\fR \fIkey=value\fR] \fIlogin\fR .fi .SH DESCRIPTION - .sp .LP The \fBusermod\fR utility modifies a user's login definition on the system. It changes the definition of the specified login and makes the appropriate login-related system file and file system changes. .sp .LP The system file entries created with this command have a limit of 512 characters per line. Specifying long arguments to several options might exceed this limit. .SH OPTIONS - .sp .LP The following options are supported: .sp .ne 2 .na --- 8,35 ---- usermod \- modify a user's login information on the system .SH SYNOPSIS .LP .nf \fBusermod\fR [\fB-u\fR \fIuid\fR [\fB-o\fR]] [\fB-g\fR \fIgroup\fR] [\fB-G\fR \fIgroup\fR [, \fIgroup\fR...]] ! [\fB-d\fR \fIdir\fR [\fB-m\fR [\fB-z|-Z\fR]]] [\fB-s\fR \fIshell\fR] [\fB-c\fR \fIcomment\fR] [\fB-l\fR \fInew_name\fR] [\fB-f\fR \fIinactive\fR] [\fB-e\fR \fIexpire\fR] [\fB-A\fR \fIauthorization\fR [, \fIauthorization\fR]] [\fB-P\fR \fIprofile\fR [, \fIprofile\fR]] [\fB-R\fR \fIrole\fR [, \fIrole\fR]] [\fB-K\fR \fIkey=value\fR] \fIlogin\fR .fi .SH DESCRIPTION .LP The \fBusermod\fR utility modifies a user's login definition on the system. It changes the definition of the specified login and makes the appropriate login-related system file and file system changes. .sp .LP The system file entries created with this command have a limit of 512 characters per line. Specifying long arguments to several options might exceed this limit. .SH OPTIONS .LP The following options are supported: .sp .ne 2 .na
*** 161,178 **** .RE .sp .ne 2 .na ! \fB\fB-m\fR\fR .ad .sp .6 .RS 4n Move the user's home directory to the new directory specified with the \fB-d\fR option. If the directory already exists, it must have permissions read/write/execute by \fIgroup\fR, where \fIgroup\fR is the user's primary group. .RE .sp .ne 2 .na --- 159,185 ---- .RE .sp .ne 2 .na ! \fB\fB-m\fR\fR [\fB-z|-Z\fR] .ad .sp .6 .RS 4n Move the user's home directory to the new directory specified with the \fB-d\fR option. If the directory already exists, it must have permissions read/write/execute by \fIgroup\fR, where \fIgroup\fR is the user's primary group. + CHANGE_ZFS_FS option in /etc/default/useradd file determines if ZFS filesystem + will be created or destroyed during this action. If this option is set to yes + and parent directory of user's home directory is ZFS filesystem mount point, a + new ZFS filesystem is created. If old user's home directory is a ZFS file system + and CHANGE_ZFS_FS is set to yes, the filesystem will be destroyed. + \fB-z\fB and \fB-Z\fR options allow overwrite default behavior. If \fB-z\fR + option is specified, \fBusermod\fR tries to create new file system and destroy the + old one. If \fB-Z\fR option is specified, new filesystem is not created and the old + one is not destroyed. .RE .sp .ne 2 .na
*** 231,241 **** user will not have access to their home directory until the \fBUID\fR is manually reassigned using \fBchown\fR(1). .RE .SH OPERANDS - .sp .LP The following operands are supported: .sp .ne 2 .na --- 238,247 ----
*** 367,377 **** .fi .in -2 .sp .SH EXIT STATUS - .sp .LP In case of an error, \fBusermod\fR prints an error message and exits with one of the following values: .sp .ne 2 --- 373,382 ----
*** 477,486 **** --- 482,500 ---- .RS 4n Unable to complete the move of the home directory to the new home directory. .RE .SH FILES + .ne 2 + .na + \fB\fB/etc/default/useradd\fR\fR + .ad + .sp .6 + .RS 4n + useradd, usermod and userdel configuration file + .RE + .sp .ne 2 .na \fB\fB/etc/group\fR\fR .ad
*** 528,538 **** .RS 4n system file containing additional user and role attributes .RE .SH ATTRIBUTES - .sp .LP See \fBattributes\fR(5) for descriptions of the following attributes: .sp .sp --- 542,551 ----
*** 544,563 **** _ Interface Stability Committed .TE .SH SEE ALSO - .sp .LP \fBchown\fR(1), \fBpasswd\fR(1), \fBusers\fR(1B), \fBgroupadd\fR(1M), \fBgroupdel\fR(1M), \fBgroupmod\fR(1M), \fBlogins\fR(1M), \fBpwconv\fR(1M), \fBroleadd\fR(1M), \fBroledel\fR(1M), \fBrolemod\fR(1M), \fBuseradd\fR(1M), \fBuserdel\fR(1M), \fBgetdate\fR(3C), \fBauth_attr\fR(4), \fBpasswd\fR(4), \fBpolicy.conf\fR(4), \fBprof_attr\fR(4), \fBuser_attr\fR(4), \fBattributes\fR(5) .SH NOTES - .sp .LP The \fBusermod\fR utility modifies \fBpasswd\fR definitions only in the local \fB/etc/passwd\fR and \fB/etc/shadow\fR files. If a network nameservice such as \fBNIS\fR or \fBNIS+\fR is being used to supplement the local files with additional entries, \fBusermod\fR cannot change information supplied by the --- 557,574 ----