Find knowledge base article(s) by searching for keywords in the title e.g. type linux in the search box below
Find knowledge base article(s) by browsing the subject categories of articles
Technology quick references, cheatsheets, user manuals etc.
Shop Online through ShopifyLite
Tutorials on various IT applications.
Search Title    (UL:0 |SS:f)

Software >> OS >> Unix >> Linux >> commands >> sudo >> How to have allow multiple commands without password and also commands with parameters

Example 1 of  /etc/sudoers

user1 ALL=NOPASSWD: /bin/su -,/bin/su -c [!-]*

 

=> user1 will not be prompted for password to run sudo su -

=> user1 will not be prompted for password to run sudo su - c "some shell command"

 

Example 2 of /etc/sudoers (allows all commands without password)

user1        ALL=(ALL)       NOPASSWD: ALL
 

[ © 2008-2021 myfaqbase.com - A property of WPDC Consulting ]