linux command useradd
Linux command useradd
【Purpose】
Learning linux command useradd to create a new user or update default new user information
【Eevironment】
Ubuntu 16.04 terminal
【Procdeure】
Source code:
# crate new user
useradd -s '/bin/bash' -m -G adm,sudo test # set new user password
passwd test #set root password
passwd root
Parameter description
-c:加上备注文字,备注文字保存在passwd的备注栏中。 -d:指定用户登入时的主目录,替换系统默认值/home/<用户名> -D:变更预设值。 -e:指定账号的失效日期,日期格式为MM/DD/YY,例如06/30/12。缺省表示永久有效。 -f:指定在密码过期后多少天即关闭该账号。如果为0账号立即被停用;如果为-1则账号一直可用。默认值为-1. -g:指定用户所属的群组。值可以使组名也可以是GID。用户组必须已经存在的,期默认值为100,即users。 -G:指定用户所属的附加群组。 -m:自动建立用户的登入目录。 -M:不要自动建立用户的登入目录。 -n:取消建立以用户名称为名的群组。 -r:建立系统账号。 -s:指定用户登入后所使用的shell。默认值为/bin/bash。 -u:指定用户ID号。该值在系统中必须是唯一的。0~499默认是保留给系统用户账号使用的,所以该值必须大于499。
linux command useradd的更多相关文章
- Linux Command Backup
User Structure linux command review 列出所有信号 找到名字后,kill 或者用ps找到 kill同名进程 每隔一秒高亮显示网络链接数的变化情况 启动关闭制定网卡 关 ...
- 《The Linux Command Line》 读书笔记04 Linux用户以及权限相关命令
Linux用户以及权限相关命令 查看身份 id:Display user identity. 这个命令的输出会显示uid,gid和用户所属的组. uid即user ID,这是账户创建时被赋予的. gi ...
- 《The Linux Command Line》 读书笔记02 关于命令的命令
<The Linux Command Line> 读书笔记02 关于命令的命令 命令的四种类型 type type—Indicate how a command name is inter ...
- 《The Linux Command Line》 读书笔记01 基本命令介绍
<The Linux Command Line> 读书笔记01 基本命令介绍 1. What is the Shell? The Shell is a program that takes ...
- Linux Command Line Basics
Most of this note comes from the Beginning the Linux Command Line, Second Edition by Sander van Vugt ...
- linux 的useradd 命令的p选项
linux 的useradd 命令的p选项 错误用法: #useradd gaojian -p gaojian # ...
- Linux Command Line 解析
Linux Command Line 解析 0 处理模型 Linux kernel的启动包括很多组件的初始化和相关配置,这些配置参数一般是通过command line进行配置的.在进行后续分析之前,先 ...
- 15 Examples To Master Linux Command Line History
When you are using Linux command line frequently, using the history effectively can be a major produ ...
- 10 Interesting Linux Command Line Tricks and Tips Worth Knowing
I passionately enjoy working with commands as they offer more control over a Linux system than GUIs( ...
随机推荐
- MsgWaitForMultipleObjects_测试
1.个人感觉: 1.1.MSDN中(https://msdn.microsoft.com/en-us/library/ms684242.aspx),说: “ dwWakeMask [in] The i ...
- FileNotFoundException报错, src\main\....\....(拒绝访问) , 原因:1. 方法没有判断文件夹和文件, 2.没有指明文件的具体路径和名字
- Corrupted Metadata/failed to mount /sysroot
公司电脑CentOS系统突然断电,开机后,无法进入系统.查看系统log如下: mount: mount /dev/mapper/cl-root on /sysroot failed:Structure ...
- echarts的学习
博客1.:https://zrysmt.github.io/ 博客2:http://blog.csdn.net/future_todo/article/details/60956942 工作中一个需求 ...
- sql server 学习笔记 ( backup 备份方案 )
做个记入就好 USE [master] SELECT bs.database_name AS 'Database Name', bs.backup_start_date AS 'Backup Star ...
- PhantomJS框架(初识无头浏览器)
博主今天看到大神聊起 headless,首先我去了解了下这个概念 无头浏览器 selenium框架是有头浏览器的代表,即可看得见的浏览器 而headless browser无头浏览器,即看不见的浏览 ...
- ADO.NET梳理
目录: 简单的介绍下ADO.NET SqlConnection(连接对象) SqlCommand(命令对象) SqlParameter(Sql参数) SqlDataReader(数据流读取器) Sql ...
- Web3.js 0.20.x API 中文版翻译
文档原始链接为:https://web3.learnblockchain.cn/0.2x.x/,欢迎大家前往查阅,本文只是节选开头部分的介绍及API列表索引,以下为翻译正文: 为了开发一个基于以太坊的 ...
- 55 Django静态文件配置
一.Django静态文件配置 1.项目文件夹,新建一个文件夹statics 文件夹 2.在配置文件settings.py中,配置: 文件中有第句: STATIC_URL = '/static/'#静态 ...
- P4557 [JSOI2018]战争
首先可以题目描述的两个点集是两个凸包,分别设为A和B. 考虑一个向量w不合法的条件. 即存在b+w=a,其中a属于A,b属于B. 也就是a-b=w. 即对b取反后和a的闵可夫斯基和. 求出闵可夫斯基和 ...