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

holiday12的更多相关文章

随机推荐

  1. [记] OpenCV4 源码编译安装 | 记录

    OpenCV4 源码编译安装 | 记录 参考资料 官方文档:https://docs.opencv.org/4.x/d7/d9f/tutorial_linux_install.html 环境 wsl2 ...

  2. Mysql之迂回连接术

    转载请注明来源:https://www.cnblogs.com/Sherlock-L/p/14932870.html 关键词:OmniDB.Mysql Router 背景:项目的测试数据库放在了生产机 ...

  3. Python自动发邮件(QQ为例)

    import smtplib from email.mime.text import MIMEText from email.header import Header from email.mime. ...

  4. Win10桌面点鼠标右键一直转圈的解决方法

    win10桌面右键菜单就一直转圈,无法调出桌面右键菜单,下面给大家分享一下怎么解决的问题,一起了解一下!            步骤阅读   工具/原料   win10 企业版 HT1902 方法/步 ...

  5. Jmeter学习:字符串,加密相关函数,groovy脚本函数

    一.__digest 功能介绍: 将输入进行 MD5 加密 ${__MD5(参数 1,参数 2)} 参数 1:加密算法,必选,MD2 MD5 SHA-1 SHA-224 SHA-256 SHA-384 ...

  6. TIDB-DM数据迁移第三部(集群管理)

    1.对现在 dm 集群进行缩容,将 free 状态的 worker 下线. tiup dm display dm-test 查看 free 状态节点 tiup dm scale-in dm 172.1 ...

  7. Spring Web MVC注解

        @RequestMapping @RequestMapping注解的主要用途是将Web请求与请求处理类中的方法进行映射. Spring MVC和Spring WebFlux都通过RquestM ...

  8. Zebra GT800标签打印机打印时脱机并亮红灯的故障处理

    Zebra GT800标签打印机打印时脱机并亮红灯的故障处理 打印测试正常,所有设置都正常,驱动原厂的,打印时只打印一点头,把所有的东西都测试了,花了1天半时间,该摸到的点都测了一般,甚至打算把这款打 ...

  9. python实现web应用程序(1)虚拟环境与Django

    前言 在这个系列博客中,我将使用python实现一个名为"OI笔记"的项目. 1 建立项目目录 第一步,我们先为自己的项目建立一个目录. 首先,打开终端. win+r键,然后输入c ...

  10. Cesium测量优化1

    简介:优化绘制点.线,面鼠标位置获取精度.支持3dties,gltf model,以及box等Geometry Entity上的位置拾取. 测试代码 <template> <div ...