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( ...
随机推荐
- Python中什么是变量
在Python中,变量的概念基本上和初中代数的方程变量是一致的. 例如,对于方程式 y=x*x ,x就是变量.当x=2时,计算结果是4,当x=5时,计算结果是25. 只是在计算机程序中,变量不仅可以是 ...
- cocos2dx lua 绑定之一:自动绑定自定义类中的函数
cococs2dx 3.13.1 + vs2013 + win10 1.首先定义C++类Student 在cocos2d-x\cocos文件夹下新建一个user_define的文件夹放置两个文件. 注 ...
- C#定义只能处理枚举类型的泛型类型
internal sealed class GenericTypeThatRequireAnEnum<T> { ; //该 static 字段在不同的封闭类型之间是独立不共享的 //静态构 ...
- 记录python接口自动化测试--根据excel中的期望输出是否存在请求返回的响应来判断用例是否执行成功(第八目)
1.首先在excel中的expectValue列填好预期结果值 这里判断接口成功的依据是预期结果值是否存在于接口返回的数据中. 首先,要知道在之前封装的get/post请求方法中返回的是‘str’,也 ...
- idea maven环境下 java实现发送邮件验证
1.开通smtp授权 QQ邮箱-设置-账户-开启 得到一个授权码 2.下载javax.email包 maven项目中 pom文件加入: <dependency> <groupId&g ...
- spring cloud: zuul(四): 正则表达式匹配其他微服务(给其他微服务加版本号)
spring cloud: zuul(四): 正则表达式匹配其他微服务(给其他微服务加版本号) 比如我原来有,spring-boot-user微服务,后台进行迭代更新,另外其了一个微服务: sprin ...
- 纯js无缝滚动
HTML代码 <!--父容器要使用overflow: hidden;--> <div id="imgsList" style="height:150px ...
- 『MXNet』第十二弹_再谈新建计算节点
上一节我们已经谈到了计算节点,但是即使是官方文档介绍里面相关内容也过于简略,我们使用Faster-RCNN代码中的新建节点为例,重新介绍一下新建节点的调用栈. 1.调用新建节点 参数分为三部分,op_ ...
- Matlab-10:Ritz-Galerkin方法求解二阶常微分方程
一.代数多项式法: tic; clear clc % N=input('please key in the value of ''N'''); N=10; M=100; h=1/M; X=0:h:1; ...
- 【MySQL】【2】数字排序问题
--我用的方案 SELECT * FROM TABLE_Q ORDER BY CAST(ID AS SIGNED) ASC 备注: 不做特殊处理的话,数字位数不一样时排序有问题,比如10会比2小. 其 ...