方法一: 修改 /etc/sudoers 文件,找到下面一行,把前面的注釋(#)去掉 ## Allows people in group wheel to run all commands %wheel ALL=(ALL) ALL 然后修改用戶,使其屬于root組(wheel),命令如下: #usermod -g root tommy 修改完畢,現(xiàn)在可以用tommy帳號登錄,然后用命令 su - ,即可獲得root權(quán)限進(jìn)行操作。
www.dbjr.com.cn/article/1805...htm 2025-6-7