if you are upset with sudo password, add this line in /etc/sudoers xxxxxx ALL=(ALL) NOPASSWD: ALL (xxxxxx is your login name) sudo will not ask anymore for a password 即: sudo gedit /etc/sudoers 在最后添加: xxxxx ALL=(ALL)NOPASSWD:ALL 其中xxxxx换成自己的名字. 原文地址:
#一般安全起见生产环境都会禁止root账号登录,基本上都是用普通用户ssh登录以后再切换root账户. #而默认sudo su -切换root是需要密码的. 解决: 1.编辑配置文件/etc/pam.d/su vim /etc/pam.d/su # Uncomment the following line to implicitly trust users in the "wheel" group. auth sufficient pam_wheel.s