当前位置:网站首页>Rocky基础知识1
Rocky基础知识1
2022-07-05 12:41:00 【51CTO】
1、用户
1)、管理员:root ,uid : 0
2)、普通用户:1-60000自动分配
a、系统用户:1-999(centos7以后),1-499(centos6以前)
b、登录用户:1000+(centos7以后),500+(centos6以前)
2、用户组
1)、管理员组:root ,gid : 0
2)、普通组:
a、系统组:1-999(centos7以后),1-499(centos6以前),对守护进程获取资源进行权限分配
b、普通组:1000+(centos7以后),500+(centos6以前),给用户使用
3、passwd文件格式
以:分割
第1字段:登录名(用户)
第2字段:密码
第2字段:UID
第2字段:GID
第2字段:用户描述
第2字段:家目录
第2字段:用户默认shell类型
4、shadow文件格式
以:分割
登录名
用户密码:一般用sha512加密
从1970年1月1日起到密码最近一次被更改的时间
密码再过几天可以被变更(0表示随时可被变更)
密码再过几天必须被变更(99999表示永不过期)
密码过期前几天系统提醒用户(默认为一周)
密码过期几天后帐号会被锁定
从1970年1月1日算起,多少天后帐号失效
例:生成随机10为密码
[[email protected]rocky8-1 <sub>]
#cat /dev/urandom |tr -dc '[:alnum:][email protected]#$%^' |head -c10
[email protected]
#DS
[[email protected] </sub>]
#openssl rand -base64 9
aNcISeq/BYIA
[[email protected] <sub>]
#mkpasswd
v64y%FPzt
[[email protected] </sub>]
#mkpasswd -l 9 -c 2 -C 2 -d 2 -s 2
#5egg_6SV
#注:-l 9 代表长度(9位字符密码)
-c
2 代表小写字母 (2位小写字母)
-C
2 代表大写字母 (2为大写字母)
-d
2 代表数字 (2位数字)
-s
2 代表特殊符号 (2位特殊符号)
- 1.
- 2.
- 3.
- 4.
- 5.
- 6.
- 7.
- 8.
- 9.
- 10.
- 11.
- 12.
- 13.
- 14.
- 15.
- 16.
5、光盘自动挂载autofs
在使用linux中,我们有会这么一个神奇的目录,平时不存在,访问自动生成,然后
自动把光盘 挂载到此目录上,在centos7上都是/misc/cd/目录。
需要安装autofs服务:
安装完autofs后查看下服务是否开启,如果没开启,需要开启下
systemctl status autofs #查看autofs服务
systemctl start autofs #开启autofs
systemctl restart autofs #重启autofs
进入/misc/cd会惊奇的发现里边有光盘的文件了
[[email protected] ~]
#cd /misc/cd/
[[email protected]
cd]
#ls
AppStream EFI isolinux media.repo
BaseOS images LICENSE TRANS.TBL
- 1.
- 2.
- 3.
- 4.
边栏推荐
- RHCSA5
- Leetcode20. Valid parentheses
- Talk about my drawing skills in my writing career
- 在家庭智能照明中应用的测距传感芯片4530A
- How to connect the API interface of Taobao open platform (super detailed)
- Setting up sqli lab environment
- Taobao, pinduoduo, jd.com, Doudian order & Flag insertion remarks API solution
- SAP SEGW 事物码里的 ABAP 类型和 EDM 类型映射的一个具体例子
- 10 minute fitness method reading notes (3/5)
- RHCAS6
猜你喜欢

2021-12-21 transaction record

Distance measuring sensor chip 4530a used in home intelligent lighting

Shi Zhenzhen's 2021 summary and 2022 outlook | colorful eggs at the end of the article

Taobao flag insertion remarks | logistics delivery interface

国内市场上的BI软件,到底有啥区别

SAP SEGW 事物码里的 Association 建模方式

Transactions from January 6 to October 2022

激动人心!2022开放原子全球开源峰会报名火热开启!

I'm doing open source in Didi

初识Linkerd项目
随机推荐
Install rhel8.2 virtual machine
JXL notes
初识Linkerd项目
石臻臻的2021总结和2022展望 | 文末彩蛋
使用 jMeter 对 SAP Spartacus 进行并发性能测试
2021.12.16-2021.12.20 empty four hand transaction records
SAP self-development records user login logs and other information
Using docker for MySQL 8.0 master-slave configuration
Setting up sqli lab environment
Reshape the power of multi cloud products with VMware innovation
10 minute fitness method reading notes (1/5)
Common commands and basic operations of Apache Phoenix
MySQL 巨坑:update 更新慎用影响行数做判断!!!
CF:A. The Third Three Number Problem【关于我是位运算垃圾这个事情】
国内市场上的BI软件,到底有啥区别
Language model
Yyds dry inventory JS intercept file suffix
【Nacos云原生】阅读源码第一步,本地启动Nacos
How to connect the API interface of Taobao open platform (super detailed)
关于 SAP UI5 getSAPLogonLanguage is not a function 的错误消息以及 API 版本的讨论