{"id":244,"date":"2015-07-06T11:20:26","date_gmt":"2015-07-06T11:20:26","guid":{"rendered":"http:\/\/www.howtolearnlinux.com\/?p=244"},"modified":"2015-07-06T13:32:50","modified_gmt":"2015-07-06T13:32:50","slug":"redhat-linux-sudo-users","status":"publish","type":"post","link":"http:\/\/shijuvarghese.com\/?p=244","title":{"rendered":"Redhat Linux sudo users"},"content":{"rendered":"<p>This page gives basic information about Sudo users.<\/p>\n<p><span style=\"font-family: verdana; font-size: small;\">The file used by sudo is <b>\/etc\/sudoers<\/b><\/span><\/p>\n<p><b>Never use vi to open this file. Use the command &#8220;visudo&#8221;<\/b><\/p>\n<p>user1 ALL=\/usr\/sbin\/useradd<\/p>\n<p>By adding this in sido file user1 will be able to add users<br \/>\n<b>ALL<\/b> means user1 can run this command from any IP. Instead we could specify an IP.<\/p>\n<p>If user1 wants to add a user he should execute the command:<br \/>\n[Hostname]# <b>sudo =\/usr\/sbin\/useradd user2<\/b><br \/>\nPassword for user1 will be asked<\/p>\n<p><b>user1 ALL=\/usr\/sbin\/<\/b><\/p>\n<p>By this all command =\/usr\/sbin\/ will be accessible to user1<\/p>\n<p><b>%group1 ALL=\/usr\/sbin\/<\/b><\/p>\n<p>By this everyone in the group group1 could run command in \/usr\/sbin\/<\/p>\n","protected":false},"excerpt":{"rendered":"<div class=\"mh-excerpt\"><p>This page gives basic information about Sudo users. The file used by sudo is \/etc\/sudoers Never use vi to open this file. Use the command <a class=\"mh-excerpt-more\" href=\"http:\/\/shijuvarghese.com\/?p=244\" title=\"Redhat Linux sudo users\">[&#8230;]<\/a><\/p>\n<\/div>","protected":false},"author":1,"featured_media":252,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[3],"tags":[],"class_list":["post-244","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-linux"],"_links":{"self":[{"href":"http:\/\/shijuvarghese.com\/index.php?rest_route=\/wp\/v2\/posts\/244","targetHints":{"allow":["GET"]}}],"collection":[{"href":"http:\/\/shijuvarghese.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/shijuvarghese.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/shijuvarghese.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"http:\/\/shijuvarghese.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=244"}],"version-history":[{"count":2,"href":"http:\/\/shijuvarghese.com\/index.php?rest_route=\/wp\/v2\/posts\/244\/revisions"}],"predecessor-version":[{"id":246,"href":"http:\/\/shijuvarghese.com\/index.php?rest_route=\/wp\/v2\/posts\/244\/revisions\/246"}],"wp:featuredmedia":[{"embeddable":true,"href":"http:\/\/shijuvarghese.com\/index.php?rest_route=\/wp\/v2\/media\/252"}],"wp:attachment":[{"href":"http:\/\/shijuvarghese.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=244"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/shijuvarghese.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=244"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/shijuvarghese.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=244"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}