我尝试以 root 身份登录,如下gnome 3
所示:我按下Not listed?
,然后输入root
用户名,然后输入我的 root 密码,但它显示That didn't work
.
我无法使用命令route
:
route
bash: route: command not found
Run Code Online (Sandbox Code Playgroud)
为什么找不到?(我使用的是 debian 9)。
我试图以 root 身份运行它,但它仍然不起作用。然而,它应该也可以在没有 root 的情况下工作。
附加诊断:
whereis route
route:
Run Code Online (Sandbox Code Playgroud)
which route
(空输出)。
export PATH=$PATH:/sbin
(无输出)并且没有任何变化。
我已经iproute2
安装了,确保我运行了:
apt --reinstall install iproute2
在/etc/sudoers
我补充说:
%myuser ALL=(ALL) NOPASSWD:ALL
现在,如果我输入,sudo apt update
我不需要输入密码。
但我想要完整的 root 权限:即,我只想使用apt update
.
apt 是我想要 FULL ROOT PERMISSIONS 的一个例子,另一个例子是能够在任何地方创建/修改文件。
我试图root ALL=(ALL:ALL) ALL
在 myuser 行中使用根行 ( ) 但什么也没用:
%myuser ALL=(ALL:ALL) ALL
这是我的/etc/sudoers
文件:
#
# This file MUST be edited with the 'visudo' command as root.
#
# Please consider adding local content in /etc/sudoers.d/ instead of
# directly modifying this file.
#
# See the man page for details on how to write …
Run Code Online (Sandbox Code Playgroud)