holiday12--linux basis

super user(root)

  • In linux, account root usually use for system maintain and managerment ,it has all access permission for all resources of system
  • In most linux system version,not recommended use root account log in system directly

sudo

  • su is abbreviation of substitute user , repersent use another user
  • sudo command used to execute commands in othter user , default identity is root

group managerment command

tips:add/delete group must execute as root

add/delete group

command action
groupadd [group name] add group
groupdel [group name] delete group
cat /etc/group make sure group information
chgrp -R [group name] [file/directory] recursive modify the group of file directory

user managerment command

tips:add/delete user or modify other users password must execute as root

add/delete user and change password

command action description
useradd -m -g [grup] [new user] add new user -m automatically create home directory, -g appoint the user's group, otherwise will create a group which has same name with user
passwd user set user's password if you are normal user, you can use passwd command to change password directly
userdel -r [user name] delete user -r option will delete home directory automatically

cat /etc/passwd | grep [user name] #make sure user's information

最新文章

  1. 自然语言20_The corpora with NLTK
  2. VC++ 用setsockopt()来控制recv()与send()的超时
  3. Win7下安装配置gVim
  4. NSEnumerator
  5. HDU 3667 费用流(拆边)
  6. Android如何区分app原生和webview实现
  7. 如何在ubuntu 12.04 中安装经典的 GNOME桌面
  8. android中判断sim卡状态和读取联系人资料的方法
  9. shallow copy & deep copy
  10. Hibernate 主键策略
  11. AJAX 跨域
  12. Python代码一定要对齐
  13. sql server 2005导出数据
  14. Lucene全文搜索之分词器:使用IK Analyzer中文分词器(修改IK Analyzer源码使其支持lucene5.5.x)
  15. RESTful服务最佳实践
  16. 201621123043 《Java程序设计》第3周学习总结
  17. python中的赋值与深浅拷贝
  18. 使用cURL尝试ElasticSearch
  19. Jupyter中python3之numpy练习
  20. Luogu P3455 [POI2007]ZAP-Queries

热门文章

  1. js动态删除添加一行
  2. 15. 测试环境部署-linux
  3. 快速确定execl 列数
  4. kumquat
  5. ubuntu新建的用户的终端前不能/没有显示路径
  6. K8S-PV和PVC
  7. xss-labs
  8. [部署日记]GO在Visual Studio Code初次运行时提示The "gopls" command is not available. Run "go get -v golang.org/x/tools/gopls" to install.
  9. <string> <cstring> <string.h>
  10. satpy 处理卫星 FY4A 数据