当前位置:网站首页>2022.07.02
2022.07.02
2022-07-07 19:16:00 【ifuudoudou】
Class hour 10 Review and learning objectives
Class hour 11 user , User groups and rights management
In the use of su root At first, I failed , Because there is no initialization root.
So you need to input sudo passwd root, To initialize the , To succeed .
After entering the root directory , It can be used whoami This command checks the current login account .
When creating a new user , At first I used “add user” The result is an error saying that there is no such order .
Later I read this document Linux How to manually create a new user (How to create new users manually under Linux) - Douding net , Only to find that there is no space in the middle , yes “adduser”.
You should also pay attention to when viewing the newly created user information ,cat /etc/passwd This catalogue contains cotton ,cat There must be a space after .
The information of the newly created user is at the bottom .
Class hour 12
Switch back to the home, Reuse ll Check the information in the file , You can find that there is no user directory just created .
in other words , The user was not created successfully .
Because we didn't add details just now .
Now we use -m To create , And then reuse it cat /etc/passwd Check it out. , It can be seen that there are already .
Then we use password To set the password of new users .
Use after setting su test02 To switch .
use whoami Check it out. , I found that I did switch to test02.
If you want to go back to the original directory , utilize crtl+d You can quit .
If you want to switch users at the same time , Switch to the added directory .
stay su Add a horizontal line in front of it .
Use when deleting userdel test02.
But the added directory will not be deleted .
Delete the added directory by recursion .
Then a new one is established according to the above method test03, Reuse userdel -r test03 To delete .
In this way, even the added directory can be deleted .
Although the report is wrong , But it doesn't affect .
边栏推荐
- DeSci:去中心化科学是Web3.0的新趋势?
- Reject policy of thread pool
- First time in China! The language AI strength of this Chinese enterprise is recognized as No.2 in the world! Second only to Google
- Standard ACL and extended ACL
- Key points of anti reptile: identifying reptiles
- 网易云信参与中国信通院《实时音视频服务(RTC)基础能力要求及评估方法》标准编制...
- POJ 1182: food chain (parallel search) [easy to understand]
- Seize Jay Chou
- Realize payment function in applet
- SlashData开发者工具榜首等你而定!!!
猜你喜欢
随机推荐
Antisamy: a solution against XSS attack tutorial
Reuse of data validation framework Apache bval
2022-07-04 matlab reads video frames and saves them
GSAP animation library
反爬虫的重点:识别爬虫
Command mode - unity
SD_ DATA_ SEND_ SHIFT_ REGISTER
【Base64笔记】「建议收藏」
Cloud security daily 220707: Cisco Expressway series and telepresence video communication server have found remote attack vulnerabilities and need to be upgraded as soon as possible
How to choose the appropriate automated testing tools?
ES6 note 1
Version 2.0 of tapdata, the open source live data platform, has been released
二叉树的基本概念和性质
testing and SQA_ Dynamic white box test [easy to understand]
我感觉被骗了,微信内测 “大小号” 功能,同一手机号可注册两个微信
Charles+Postern的APP抓包
Zhong Xuegao wants to remain innocent in the world
Redis
前首富,沉迷种田
Is AI more fair than people in the distribution of wealth? Research on multiplayer game from deepmind