Distributions
› Ubuntu
› Fedora
› CentOS
中文资源站
› 网易开源镜像站
leadfast
V2EX  ›  Linux

我这 sudo 发生了什么事情

  •  
  •   leadfast · Aug 23, 2019 · 4792 views
    This topic created in 2649 days ago, the information mentioned may be changed or developed.

    想用 www 用户去运行下 git

    20190823223228.png

    4 replies  •  2019-08-24 10:43:44 +08:00
    lechain
    lechain
    Aug 23, 2019
    1
    sudo su www
    leadfast
    leadfast
    OP
    Aug 23, 2019❤️1
    2
    找到原因了,系统是 centos6,前段时间升级了 gcc,一顿操作结束后 sudo 现在是这个状态:
    $ which sudo
    /opt/rh/devtoolset-6/root/usr/bin/sudo

    现在这样就没问题了:
    /usr/bin/sudo -u www git version
    starsriver
    starsriver
    Aug 24, 2019 via Android
    3
    环境变量没了没看出来?。。。
    ryd994
    ryd994
    Aug 24, 2019 via Android
    4
    这种残废命令大概率是 busybox
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Privacy   ·   Solana   ·   918 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 42ms · UTC 21:22 · PVG 05:22 · LAX 13:22 · JFK 16:22
    ♥ Do have faith in what you're doing.