zoukankan      html  css  js  c++  java
  • Linux用户提权知识点及用户工作环境相关文件

    1. su  使用普通用户登录,然后执行su命令切换到root用户     优点:简单   缺点:需要知道root密码
    2. sudo  使用普通用户管理,当需要使用root的权限的时候,进行提权   优点:安全、方便   缺点:复杂 

    shell的分类及执行的过程

    交互式shell                     #终端操作  输入一条指令,需要等待系统的处理及返回结果
    非交互式shell                 #脚本的执行方式就是  用户执行完指令 不需要跟系统进行交互
    登录式shell                     #通过用户名和密码的方式进行登录的
    非登录式shell                 #不是通过用户名和密码的方式进行登录的    执行一个bash,就是一个非登录式shell
     
     
    #个人配置文件
    /root/.bash_profile
    /root/.bashrc
     
    #全局配置文件
    /etc/bashrc
    /etc/profile
    /etc/profile.d/test.sh
     
                                                                              执行顺序
     
    #登录式Shell执行顺序
    1./etc/profile
    2./etc/profile.d/test.sh
    3./root/.bash_profile
    4./root/.bashrc
    5./etc/bashrc
     
     
    #非登录式shell执行顺序
    1./root/.bashrc
    2./etc/bashrc
    3./etc/profile.d/test.sh
     
     
     
     
     
     
     
     
     
     
     
     
  • 相关阅读:
    JVM—Java内存结构
    myeclipse中页面utf-8的设置
    Python-统计txt文件里面的分数
    Python-字符串常用函数
    初识C#扩展方法
    Artwork 18年中南多校第一场A
    HDU2586 How far away ?
    HDU5952 Counting Cliques 暴搜优化
    POJ 2763 Housewife Wind 树链拋分
    HDU 3966 Aragorn's Story 树链拋分
  • 原文地址:https://www.cnblogs.com/chenlifan/p/13360770.html
Copyright © 2011-2022 走看看