V2EX = way to explore
V2EX 是一个关于分享和探索的地方
现在注册
已注册用户请  登录
Distributions
Ubuntu
Fedora
CentOS
中文资源站
网易开源镜像站
mingtdlb
V2EX  ›  Linux

sudo -i 和 su - root

  •  
  •   mingtdlb · 2021-01-22 17:05:41 +08:00 · 1826 次点击
    这是一个创建于 1338 天前的主题,其中的信息可能已经有所发展或是发生改变。

    sudo -i 和 su -l root 效果是不是一样啊?切换成功后感觉没差别

    • -i run login shell as the target user; a command may also be specified
    • -l make the shell a login shell
    1 条回复    2021-01-25 12:52:29 +08:00
    julyclyde
        1
    julyclyde  
       2021-01-25 12:52:29 +08:00
    效果一样,但是语义不一样
    关于   ·   帮助文档   ·   博客   ·   API   ·   FAQ   ·   实用小工具   ·   981 人在线   最高记录 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 21ms · UTC 20:14 · PVG 04:14 · LAX 13:14 · JFK 16:14
    Developed with CodeLauncher
    ♥ Do have faith in what you're doing.