Provided by: smbldap-tools_0.9.11-3ubuntu1_all 

NAME
smbldap-useradd - Create a new user
SYNOPSIS
smbldap-useradd [-abinwPW] [-c comment] [-d home_dir] [-g initial_group] [-m [-k skeleton_dir]] [-o
user_ou] [-s shell] [-t time] [-u uid] [-A canchange] [-B mustchange] [-C smbhome] [-D homedrive] [-E
scriptpath] [-F profilepath] [-G group[,...]] [-H acctflags] [-M mailaddr[,...]] [-N givenname] [-O
mailaddr[,...]] [-S surname] [-T mailaddr[,...]] [-X encoding] [-Z name=value[,...]] login
DESCRIPTION
Creating New Users The smbldap-useradd command creates a new user account using the values specified on
the command line and the default values from the system and from the configuration files (in the
/etc/smbldap-tools directory).
Without any option, the account created will be a Unix (Posix) account. The following options may be used
to add information:
-a
The user will have a Samba account (and Unix).
-A
Can change password? 0 if no, 1 if yes.
-b
The user is an AIX account.
-B
Must change password? 0 if no, 1 if yes.
-c "comment"
The new user's comment field (gecos). This option is for gecos only! To set as user's full name use
the -N and -S options.
-C sambaHomePath
SMB home share, like '\\\\PDC-SRV\\homes'.
-d home_dir
The new user will be created using home_dir for the user's login directory. The default is to append
the login name to userHomePrefix (defined in the configuration file) and use that as the login directory
name.
-D sambaHomeDrive
Letter associated with home share, like 'H:'.
-E sambaLogonScript
Relative to the [netlogon] share (DOS script to execute on login, like 'foo.bat'.
-F sambaProfilePath
Profile directory, like '\\\\PDC-SRV\\profiles\\foo'.
-g initial_group
The group name or number of the user's initial login group. The group name must exist. A group number
must refer to an already existing group. The default group number is defined in the configuration file
(defaultUserGid="513").
-G group,[...]
A list of supplementary groups that the user is also a member of. Each group is separated from the
next by a comma, with no intervening whitespace. The groups are subject to the same restrictions as the
group given with the -g option. The default is for the user to belong only to the initial group.
-H sambaAcctFlags
Spaces and trailing bracket are ignored (samba account control bits like '[NDHTUMWSLKI]').
-i
Creates an interdomain trust account (machine Workstation). A password will be asked for the trust
account.
-k skeletonDir
When creating the user's home directory, copy files and directories from skeletonDir rather than
/etc/skel. The -k option is only valid in conjunction with the -m option. The default is not to create
the directory and not to copy any files.
-m
The user's home directory will be created if it does not exist. The files contained in skeletonDir
will be copied to the home directory if the -k option is used, otherwise the files contained in /etc/skel
will be used instead. Any directories contained in skeletonDir or /etc/skel will be created in the
user's home directory as well.
-M mail
E-mail addresses (multiple addresses are separated by commas).
--non-unique
Allow the creation of a user account with a duplicate (non-unique) UID.
-n
Do not print banner message.
-N givenname
Family name. Defaults to username.
-o node
The user's account will be created in the specified organizational unit. It is relative to the user
suffix dn ($usersdn) defined in the configuration file. Ex: 'ou=admin,ou=all'
-O localMailAddress
localMailAddresses (multiple addresses are separated by commas).
-P
Ends by invoking smbldap-passwd.
-p
Read password from STDIN without verification.
-s shell
The name of the user's login shell. The default is to leave this field blank, which causes the system
to select the default login shell.
-S surname
Defaults to username.
-t time
Wait <time> seconds before exiting script when adding computer's account. This is useful when
Master/PDC and Slaves/BDCs are connected through the Internet (replication is not real time).
-T mailToAddress
Forward address (multiple addresses are separated by commas).
-u uid
The numerical value of the user's ID. This value must be unique, unless the --non-unique option is
used. The value must be non-negative. The default is to use the smallest ID value greater than 1000 and
greater than every other user.
-w/-W
Creates an account for a Samba machine (Workstation), so that it can join a sambaDomainName. Normally
-w is used for adding machines through Samba but -W can be used for manual addition of samba attributes.
-X encoding
Specify input encoding for givenname and surname (default UTF-8).
-Z name=value
Specify custom LDAP attributes, using comma-separated name=value pairs.
SEE ALSO
useradd(1)
perl v5.32.1 2021-11-07 SMBLDAP-USERADD.CMD(8)