Не может создать пользователя домой в/mnt

Я хочу создать пользователя домой в /mnt с useradd но это не создало его.

useradd user -d /mnt/home/user -s /bin/shell

Какие-либо предложения?

0
задан 8 January 2019 в 07:52

1 ответ

От man useradd:

       -d, --home-dir HOME_DIR
           The new user will be created using HOME_DIR as the value for the
           user's login directory. The default is to append the LOGIN name to
           BASE_DIR and use that as the login directory name. The directory
           HOME_DIR does not have to exist but will not be created if it is
           missing.

Можно или создать каталог вручную или добавить -m (--create-directory) опция:

       -m, --create-home
           Create the user's home directory if it does not exist. The files
           and directories contained in the skeleton directory (which can be
           defined with the -k option) will be copied to the home directory.

           By default, if this option is not specified and CREATE_HOME is not
           enabled, no home directories are created.
3
ответ дан 26 October 2019 в 14:31

Другие вопросы по тегам:

Похожие вопросы: