Add a new user to the “sudo” group.
Add a new user to the “sudo” group. The change will take effect the next time the user logs in. If you have an existing user, you could pass it.In my case.
Grant sudo privileges to an existing user.
In my case.
Add NOPASSWD:ALL into id setting.
$ echo "<username> ALL = (root) NOPASSWD:ALL" | tee /etc/sudoers.d/<username>
In my case.
root@jose-desktop:~$ echo "jose ALL = (root) NOPASSWD:ALL" | tee /etc/sudoers.d/jose
Change file attributes as root privileges
$ exit
In my case.
root@jose-desktop:~$ exit
jose@jose-desktop:~$
Jose’s Google+ profile
沒有留言:
張貼留言