vim /etc/sudoers
3、找到这一 行:"root ALL=(ALL) ALL"在起下面添加"xxx ALL=(ALL) ALL" ,(这里的xxx是你的用户名),
然后保存退出。然后就行了。