482 lines
13 KiB
HTML
482 lines
13 KiB
HTML
|
|
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
|
<HTML><HEAD><TITLE>Man page of NEWUSERS</TITLE>
|
|
</HEAD><BODY>
|
|
<H1>NEWUSERS</H1>
|
|
Section: Commandes de gestion du systèm (8)<BR>Updated: 28/05/2020<BR><A HREF="#index">Index</A>
|
|
<A HREF="/cgi-bin/man/man2html">Return to Main Contents</A><HR>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<A NAME="lbAB"> </A>
|
|
<H2>NOM</H2>
|
|
|
|
newusers - Mettre à jour, ou créer de nouveaux utilisateurs par lots
|
|
<A NAME="lbAC"> </A>
|
|
<H2>SYNOPSIS</H2>
|
|
|
|
<DL COMPACT>
|
|
<DT id="1">
|
|
<B>newusers</B> [<I>options</I>] [<I>fichier</I>]
|
|
</DL>
|
|
<A NAME="lbAD"> </A>
|
|
<H2>DESCRIPTION</H2>
|
|
|
|
<P>
|
|
|
|
<DD>The
|
|
<B>newusers</B>
|
|
command reads a
|
|
<I>file</I>
|
|
(or the standard input by default) and uses this information to update a set of existing users or to create new users. Each line is in the same format as the standard password file (see
|
|
<B><A HREF="/cgi-bin/man/man2html?5+passwd">passwd</A></B>(5)) with the exceptions explained below:
|
|
<P>
|
|
|
|
pw_name:pw_passwd:pw_uid:pw_gid:pw_gecos:pw_dir:pw_shell
|
|
<P>
|
|
|
|
<I>pw_name</I>
|
|
<DL COMPACT><DT id="2"><DD>
|
|
C'est le nom de l'utilisateur.
|
|
<P>
|
|
It can be the name of a new user or the name of an existing user (or a user created before by
|
|
<B>newusers</B>). In case of an existing user, the user's information will be changed, otherwise a new user will be created.
|
|
</DL>
|
|
|
|
<P>
|
|
|
|
<I>pw_passwd</I>
|
|
<DL COMPACT><DT id="3"><DD>
|
|
Ce champ sera chiffré et utilisé comme nouvelle valeur du mot de passe chiffré.
|
|
</DL>
|
|
|
|
<P>
|
|
|
|
<I>pw_uid</I>
|
|
<DL COMPACT><DT id="4"><DD>
|
|
Ce champ est utilisé pour définir l'UID de l'utilisateur.
|
|
<P>
|
|
If the field is empty, a new (unused) UID will be defined automatically by
|
|
<B>newusers</B>.
|
|
<P>
|
|
Si ce champ contient un nombre, ce nombre sera utilisé comme UID.
|
|
<P>
|
|
If this field contains the name of an existing user (or the name of a user created before by
|
|
<B>newusers</B>), the UID of the specified user will be used.
|
|
<P>
|
|
Si l'UID d'un utilisateur existant est modifié, vous devrez configurer vous-même le propriétaire des fichiers de l'utilisateur.
|
|
</DL>
|
|
|
|
<P>
|
|
|
|
<I>pw_gid</I>
|
|
<DL COMPACT><DT id="5"><DD>
|
|
Ce champ est utilisé pour définir l'identifiant du groupe primaire de l'utilisateur.
|
|
<P>
|
|
If this field contains the name of an existing group (or a group created before by
|
|
<B>newusers</B>), the GID of this group will be used as the primary group ID for the user.
|
|
<P>
|
|
Si ce champ est un nombre, ce nombre sera utilisé comme identifiant de groupe primaire de cet utilisateur. Si aucun groupe n'existe avec ce GID, un nouveau groupe sera créé avec ce GID et le nom de l'utilisateur.
|
|
<P>
|
|
If this field is empty, a new group will be created with the name of the user and a GID will be automatically defined by
|
|
<B>newusers</B>
|
|
to be used as the primary group ID for the user and as the GID for the new group.
|
|
<P>
|
|
If this field contains the name of a group which does not exist (and was not created before by
|
|
<B>newusers</B>), a new group will be created with the specified name and a GID will be automatically defined by
|
|
<B>newusers</B>
|
|
to be used as the primary group ID for the user and GID for the new group.
|
|
</DL>
|
|
|
|
<P>
|
|
|
|
<I>pw_gecos</I>
|
|
<DL COMPACT><DT id="6"><DD>
|
|
Ce champ est copié dans le champ GECOS de l'utilisateur.
|
|
</DL>
|
|
|
|
<P>
|
|
|
|
<I>pw_dir</I>
|
|
<DL COMPACT><DT id="7"><DD>
|
|
Ce champ est utilisé pour définir le répertoire personnel de l'utilisateur.
|
|
<P>
|
|
Si ce champ n'indique pas de répertoire existant, le répertoire indiqué est créé, avec comme propriétaire l'utilisateur en cours de création ou mis à jour et son groupe primaire.
|
|
<P>
|
|
If the home directory of an existing user is changed,
|
|
<B>newusers</B>
|
|
does not move or copy the content of the old directory to the new location. This should be done manually.
|
|
</DL>
|
|
|
|
<P>
|
|
|
|
<I>pw_shell</I>
|
|
<DL COMPACT><DT id="8"><DD>
|
|
Ce champ définit l'interpréteur de commande de l'utilisateur. Aucune vérification n'est effectuée sur ce champ.
|
|
</DL>
|
|
|
|
<P>
|
|
|
|
<B>newusers</B>
|
|
first tries to create or change all the specified users, and then write these changes to the user or group databases. If an error occurs (except in the final writes to the databases), no changes are committed to the databases.
|
|
<P>
|
|
|
|
Lors du premier passage, les utilisateurs sont créés avec un mot de passe verrouillé (les mots de passe ne sont pas modifiés pour les utilisateurs non créés). Un second passage est utilisé pour mettre à jour les mots de passe en utilisant PAM. Les échecs de mise à jour des mots de passe sont signalés, mais n'empêchent pas les mises à jour des autres mots de passe.
|
|
<P>
|
|
|
|
Cette commande a été conçue pour les gros systèmes pour lesquels un grand nombre de comptes sont mis à jour en même temps.
|
|
<A NAME="lbAE"> </A>
|
|
<H2>OPTIONS</H2>
|
|
|
|
<P>
|
|
|
|
The options which apply to the
|
|
<B>newusers</B>
|
|
command are:
|
|
<P>
|
|
|
|
<B>--badname</B>
|
|
<DL COMPACT><DT id="9"><DD>
|
|
Allow names that do not conform to standards.
|
|
</DL>
|
|
|
|
<P>
|
|
|
|
<B>-h</B>, <B>--help</B>
|
|
<DL COMPACT><DT id="10"><DD>
|
|
Afficher un message d'aide et quitter.
|
|
</DL>
|
|
|
|
<P>
|
|
|
|
<B>-r</B>, <B>--system</B>
|
|
<DL COMPACT><DT id="11"><DD>
|
|
Créer un compte système.
|
|
<P>
|
|
System users will be created with no aging information in
|
|
/etc/shadow, and their numeric identifiers are chosen in the
|
|
<B>SYS_UID_MIN</B>-<B>SYS_UID_MAX</B>
|
|
range, defined in
|
|
login.defs, instead of
|
|
<B>UID_MIN</B>-<B>UID_MAX</B>
|
|
(and their
|
|
<B>GID</B>
|
|
counterparts for the creation of groups).
|
|
</DL>
|
|
|
|
<P>
|
|
|
|
<B>-R</B>, <B>--root</B> <I>CHROOT_DIR</I>
|
|
<DL COMPACT><DT id="12"><DD>
|
|
Apply changes in the
|
|
<I>CHROOT_DIR</I>
|
|
directory and use the configuration files from the
|
|
<I>CHROOT_DIR</I>
|
|
directory.
|
|
</DL>
|
|
|
|
<A NAME="lbAF"> </A>
|
|
<H2>AVERTISSEMENTS</H2>
|
|
|
|
<P>
|
|
|
|
Le fichier d'entrée doit être correctement protégé puisqu'il contient des mots de passe en clair.
|
|
<A NAME="lbAG"> </A>
|
|
<H2>CONFIGURATION</H2>
|
|
|
|
<P>
|
|
|
|
The following configuration variables in
|
|
/etc/login.defs
|
|
change the behavior of this tool:
|
|
<P>
|
|
|
|
<B>GID_MAX</B> (number), <B>GID_MIN</B> (number)
|
|
<DL COMPACT><DT id="13"><DD>
|
|
Range of group IDs used for the creation of regular groups by
|
|
<B>useradd</B>,
|
|
<B>groupadd</B>, or
|
|
<B>newusers</B>.
|
|
<P>
|
|
The default value for
|
|
<B>GID_MIN</B>
|
|
(resp.
|
|
<B>GID_MAX</B>) is 1000 (resp. 60000).
|
|
</DL>
|
|
|
|
<P>
|
|
|
|
<B>HOME_MODE</B> (number)
|
|
<DL COMPACT><DT id="14"><DD>
|
|
The mode for new home directories. If not specified, the
|
|
<B>UMASK</B>
|
|
is used to create the mode.
|
|
<P>
|
|
<B>useradd</B>
|
|
and
|
|
<B>newusers</B>
|
|
use this to set the mode of the home directory they create.
|
|
</DL>
|
|
|
|
<P>
|
|
|
|
<B>MAX_MEMBERS_PER_GROUP</B> (number)
|
|
<DL COMPACT><DT id="15"><DD>
|
|
Maximum members per group entry. When the maximum is reached, a new group entry (line) is started in
|
|
/etc/group
|
|
(with the same name, same password, and same GID).
|
|
<P>
|
|
La valeur par défaut est 0, ce qui signifie qu'il n'y a pas de limites pour le nombre de membres dans un groupe.
|
|
<P>
|
|
Cette fonctionnalité (groupe découpé) permet de limiter la longueur des lignes dans le fichier de groupes. Ceci est utile pour s'assurer que les lignes pour les groupes NIS ne sont pas plus grandes que 1024 caractères.
|
|
<P>
|
|
Si vous avez besoin de configurer cette limite, vous pouvez utiliser 25.
|
|
<P>
|
|
Remarque : les groupes découpés ne sont peut-être pas pris en charge par tous les outils (même dans la suite d'outils Shadow). Vous ne devriez pas utiliser cette variable, sauf si vous en avez vraiment besoin.
|
|
</DL>
|
|
|
|
<P>
|
|
|
|
<B>PASS_MAX_DAYS</B> (number)
|
|
<DL COMPACT><DT id="16"><DD>
|
|
Nombre maximum de jours de validité d'un mot de passe. Après cette durée, une modification du mot de passe est obligatoire. S'il n'est pas précisé, la valeur de -1 est utilisée (ce qui enlève toute restriction).
|
|
</DL>
|
|
|
|
<P>
|
|
|
|
<B>PASS_MIN_DAYS</B> (number)
|
|
<DL COMPACT><DT id="17"><DD>
|
|
Nombre minimum de jours autorisé avant la modification d'un mot de passe. Toute tentative de modification du mot de passe avant cette durée est rejetée. S'il n'est pas précisé, la valeur de -1 est utilisée (ce qui enlève toute restriction).
|
|
</DL>
|
|
|
|
<P>
|
|
|
|
<B>PASS_WARN_AGE</B> (number)
|
|
<DL COMPACT><DT id="18"><DD>
|
|
Nombre de jours durant lesquels l'utilisateur recevra un avertissement avant que son mot de passe n'arrive en fin de validité. Une valeur négative signifie qu'aucun avertissement n'est donné. S'il n'est pas précisé, aucun avertissement n'est donné.
|
|
</DL>
|
|
|
|
<P>
|
|
|
|
<B>SUB_GID_MIN</B> (number), <B>SUB_GID_MAX</B> (number), <B>SUB_GID_COUNT</B> (number)
|
|
<DL COMPACT><DT id="19"><DD>
|
|
If
|
|
/etc/subuid
|
|
exists, the commands
|
|
<B>useradd</B>
|
|
and
|
|
<B>newusers</B>
|
|
(unless the user already have subordinate group IDs) allocate
|
|
<B>SUB_GID_COUNT</B>
|
|
unused group IDs from the range
|
|
<B>SUB_GID_MIN</B>
|
|
to
|
|
<B>SUB_GID_MAX</B>
|
|
for each new user.
|
|
<P>
|
|
The default values for
|
|
<B>SUB_GID_MIN</B>,
|
|
<B>SUB_GID_MAX</B>,
|
|
<B>SUB_GID_COUNT</B>
|
|
are respectively 100000, 600100000 and 65536.
|
|
</DL>
|
|
|
|
<P>
|
|
|
|
<B>SUB_UID_MIN</B> (number), <B>SUB_UID_MAX</B> (number), <B>SUB_UID_COUNT</B> (number)
|
|
<DL COMPACT><DT id="20"><DD>
|
|
If
|
|
/etc/subuid
|
|
exists, the commands
|
|
<B>useradd</B>
|
|
and
|
|
<B>newusers</B>
|
|
(unless the user already have subordinate user IDs) allocate
|
|
<B>SUB_UID_COUNT</B>
|
|
unused user IDs from the range
|
|
<B>SUB_UID_MIN</B>
|
|
to
|
|
<B>SUB_UID_MAX</B>
|
|
for each new user.
|
|
<P>
|
|
The default values for
|
|
<B>SUB_UID_MIN</B>,
|
|
<B>SUB_UID_MAX</B>,
|
|
<B>SUB_UID_COUNT</B>
|
|
are respectively 100000, 600100000 and 65536.
|
|
</DL>
|
|
|
|
<P>
|
|
|
|
<B>SYS_GID_MAX</B> (number), <B>SYS_GID_MIN</B> (number)
|
|
<DL COMPACT><DT id="21"><DD>
|
|
Range of group IDs used for the creation of system groups by
|
|
<B>useradd</B>,
|
|
<B>groupadd</B>, or
|
|
<B>newusers</B>.
|
|
<P>
|
|
The default value for
|
|
<B>SYS_GID_MIN</B>
|
|
(resp.
|
|
<B>SYS_GID_MAX</B>) is 101 (resp.
|
|
<B>GID_MIN</B>-1).
|
|
</DL>
|
|
|
|
<P>
|
|
|
|
<B>SYS_UID_MAX</B> (number), <B>SYS_UID_MIN</B> (number)
|
|
<DL COMPACT><DT id="22"><DD>
|
|
Range of user IDs used for the creation of system users by
|
|
<B>useradd</B>
|
|
or
|
|
<B>newusers</B>.
|
|
<P>
|
|
The default value for
|
|
<B>SYS_UID_MIN</B>
|
|
(resp.
|
|
<B>SYS_UID_MAX</B>) is 101 (resp.
|
|
<B>UID_MIN</B>-1).
|
|
</DL>
|
|
|
|
<P>
|
|
|
|
<B>UID_MAX</B> (number), <B>UID_MIN</B> (number)
|
|
<DL COMPACT><DT id="23"><DD>
|
|
Range of user IDs used for the creation of regular users by
|
|
<B>useradd</B>
|
|
or
|
|
<B>newusers</B>.
|
|
<P>
|
|
The default value for
|
|
<B>UID_MIN</B>
|
|
(resp.
|
|
<B>UID_MAX</B>) is 1000 (resp. 60000).
|
|
</DL>
|
|
|
|
<P>
|
|
|
|
<B>UMASK</B> (number)
|
|
<DL COMPACT><DT id="24"><DD>
|
|
Valeur d'initialisation du masque de permissions. S'il n'est pas précisé, le masque des permissions sera initialisé à 022.
|
|
<P>
|
|
<B>useradd</B>
|
|
and
|
|
<B>newusers</B>
|
|
use this mask to set the mode of the home directory they create if
|
|
<B>HOME_MODE</B>
|
|
is not set.
|
|
<P>
|
|
It is also used by
|
|
<B>pam_umask</B>
|
|
as the default umask value.
|
|
</DL>
|
|
|
|
<A NAME="lbAH"> </A>
|
|
<H2>FICHIERS</H2>
|
|
|
|
<P>
|
|
|
|
/etc/passwd
|
|
<DL COMPACT><DT id="25"><DD>
|
|
Informations sur les comptes des utilisateurs.
|
|
</DL>
|
|
|
|
<P>
|
|
|
|
/etc/shadow
|
|
<DL COMPACT><DT id="26"><DD>
|
|
Informations sécurisées sur les comptes utilisateurs.
|
|
</DL>
|
|
|
|
<P>
|
|
|
|
/etc/group
|
|
<DL COMPACT><DT id="27"><DD>
|
|
Informations sur les groupes.
|
|
</DL>
|
|
|
|
<P>
|
|
|
|
/etc/gshadow
|
|
<DL COMPACT><DT id="28"><DD>
|
|
Informations sécurisées sur les groupes.
|
|
</DL>
|
|
|
|
<P>
|
|
|
|
/etc/login.defs
|
|
<DL COMPACT><DT id="29"><DD>
|
|
Configuration de la suite des mots de passe cachés « shadow password ».
|
|
</DL>
|
|
|
|
<P>
|
|
|
|
/etc/pam.d/newusers
|
|
<DL COMPACT><DT id="30"><DD>
|
|
PAM configuration for
|
|
<B>newusers</B>.
|
|
</DL>
|
|
|
|
<P>
|
|
|
|
/etc/subgid
|
|
<DL COMPACT><DT id="31"><DD>
|
|
IDs des groupes subalternes d'un utilisateur.
|
|
</DL>
|
|
|
|
<P>
|
|
|
|
/etc/subuid
|
|
<DL COMPACT><DT id="32"><DD>
|
|
IDs de utilisateurs subalternes d'un utilisateur.
|
|
</DL>
|
|
|
|
<A NAME="lbAI"> </A>
|
|
<H2>VOIR AUSSI</H2>
|
|
|
|
<P>
|
|
|
|
<B><A HREF="/cgi-bin/man/man2html?5+login.defs">login.defs</A></B>(5),
|
|
<B><A HREF="/cgi-bin/man/man2html?1+passwd">passwd</A></B>(1),
|
|
<B><A HREF="/cgi-bin/man/man2html?5+subgid">subgid</A></B>(5), <B><A HREF="/cgi-bin/man/man2html?5+subuid">subuid</A></B>(5),
|
|
<B><A HREF="/cgi-bin/man/man2html?8+useradd">useradd</A></B>(8).
|
|
<P>
|
|
|
|
<HR>
|
|
<A NAME="index"> </A><H2>Index</H2>
|
|
<DL>
|
|
<DT id="33"><A HREF="#lbAB">NOM</A><DD>
|
|
<DT id="34"><A HREF="#lbAC">SYNOPSIS</A><DD>
|
|
<DT id="35"><A HREF="#lbAD">DESCRIPTION</A><DD>
|
|
<DT id="36"><A HREF="#lbAE">OPTIONS</A><DD>
|
|
<DT id="37"><A HREF="#lbAF">AVERTISSEMENTS</A><DD>
|
|
<DT id="38"><A HREF="#lbAG">CONFIGURATION</A><DD>
|
|
<DT id="39"><A HREF="#lbAH">FICHIERS</A><DD>
|
|
<DT id="40"><A HREF="#lbAI">VOIR AUSSI</A><DD>
|
|
</DL>
|
|
<HR>
|
|
This document was created by
|
|
<A HREF="/cgi-bin/man/man2html">man2html</A>,
|
|
using the manual pages.<BR>
|
|
Time: 00:05:03 GMT, March 31, 2021
|
|
</BODY>
|
|
</HTML>
|