Linux useradd命令

0 Preface/Foreword

1 useradd介绍

该命令是系统管理命令(System management command)。

useradd- create a new user or update default new user information

1.1 描述

++useradd++ is a low level utility for adding users. On Debian, administrators should usually use adduserinstead.

When invoked without the**-D** option, the useradd command creates a new user account using the values specified on the command line plus the default values from the system. Depending on command line options, the useradd command will update system files and may also create the new user's home directory (主目录,根目录) and copy intial files.

1.2 --comment

-c, --comment COMMENT

Any text string. It is generally a short description of the login , and is currently used as the field for the ++user's full name++.

1.3 --create-home

-m, --create-home

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

1.4 --shell

-s, --shell SHELL

The name of theuser's login shell . The default is to leave the field blank , which causes the system to select the default login shell specified by the SHELL variable in /etc/default/useradd, or an empty string by defaut.

相关推荐
能不能别报错4 分钟前
openclaw-linux部署教程+mimo-v2-pro
linux·运维·服务器
济6171 小时前
ARM Linux 驱动开发篇---基于 pinctrl+GPIO 子系统的蜂鸣器驱动开发(设备树版)--- Ubuntu20.04
linux·嵌入式·嵌入式linux驱动开发
AiGuoHou11 小时前
Debian/Ubuntu 各个版本一键更换国内镜像源
linux·ubuntu·国内源·debian·镜像源·换源
蓝羽天空1 小时前
Ubuntu 24.04 安装 Docker
linux·ubuntu·docker
T0uken1 小时前
WSL:离线配置 Ubuntu 开发环境
linux·运维·ubuntu
�羡阳丶1 小时前
ubuntu22.04+5060显卡双系统安装,各种黑屏踩坑记录
linux·经验分享·ubuntu
b_xinjun11201 小时前
树莓派 Ubuntu 24.04.3 LTS 安装 OpenClaw 操作说明
linux·ubuntu·arcgis
硅基导游3 小时前
Linux内核观测与跟踪的利器BPF环境测试
linux·服务器·性能监控·bpf
YXXY3133 小时前
Linux进程概念(四)
linux
了一梨3 小时前
[T113] 交叉编译 OpenCV 4.5.2 + face 模块
linux·笔记·opencv