<?xml version="1.0" encoding="UTF-8"?><rss
version="2.0"
xmlns:content="http://purl.org/rss/1.0/modules/content/"
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:atom="http://www.w3.org/2005/Atom"
xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
> <channel><title>Comments on: Linux Tips: Password usage in sudo (PASSWD / NOPASSWD)</title> <atom:link href="http://www.ducea.com/2006/06/18/linux-tips-password-usage-in-sudo-passwd-nopasswd/feed/" rel="self" type="application/rss+xml" /><link>http://www.ducea.com/2006/06/18/linux-tips-password-usage-in-sudo-passwd-nopasswd/</link> <description>The Journal Of A Linux Sysadmin</description> <lastBuildDate>Wed, 17 Mar 2010 14:02:16 +0000</lastBuildDate> <generator>http://wordpress.org/?v=2.9.2</generator> <sy:updatePeriod>hourly</sy:updatePeriod> <sy:updateFrequency>1</sy:updateFrequency> <item><title>By: Ingmar</title><link>http://www.ducea.com/2006/06/18/linux-tips-password-usage-in-sudo-passwd-nopasswd/comment-page-1/#comment-181299</link> <dc:creator>Ingmar</dc:creator> <pubDate>Tue, 17 Nov 2009 11:31:39 +0000</pubDate> <guid
isPermaLink="false">http://www.ducea.com/2006/06/18/linux-tips-password-usage-in-sudo-passwd-nopasswd/#comment-181299</guid> <description>@AllenYou say you&#039;re using &quot;su -&quot;. The sudoers file only works for the &#039;sudo&#039; command. Sudo and su are two entirely different things.</description> <content:encoded><![CDATA[<p>@Allen</p><p>You say you&#8217;re using &#8220;su -&#8221;. The sudoers file only works for the &#8217;sudo&#8217; command. Sudo and su are two entirely different things.</p> ]]></content:encoded> </item> <item><title>By: dunull.org &#187; Blog Archive &#187; sudo - without password</title><link>http://www.ducea.com/2006/06/18/linux-tips-password-usage-in-sudo-passwd-nopasswd/comment-page-1/#comment-181231</link> <dc:creator>dunull.org &#187; Blog Archive &#187; sudo - without password</dc:creator> <pubDate>Sun, 01 Nov 2009 16:21:29 +0000</pubDate> <guid
isPermaLink="false">http://www.ducea.com/2006/06/18/linux-tips-password-usage-in-sudo-passwd-nopasswd/#comment-181231</guid> <description>[...] http://www.ducea.com/ [...]</description> <content:encoded><![CDATA[<p>[...] <a
href="http://www.ducea.com/" rel="nofollow">http://www.ducea.com/</a> [...]</p> ]]></content:encoded> </item> <item><title>By: Allan</title><link>http://www.ducea.com/2006/06/18/linux-tips-password-usage-in-sudo-passwd-nopasswd/comment-page-1/#comment-181189</link> <dc:creator>Allan</dc:creator> <pubDate>Mon, 19 Oct 2009 09:36:54 +0000</pubDate> <guid
isPermaLink="false">http://www.ducea.com/2006/06/18/linux-tips-password-usage-in-sudo-passwd-nopasswd/#comment-181189</guid> <description>@MariusEventually I am writing some shell script to support some RAID testing in my system. The script will require the system to login automatically in the normal user mode and then reboot again in one minute. Without the disable root password feature, the script cannot function well. I manage to run the script well in Ubuntu Server 9.04 but somehow I still feel headache to figure out the solution to disable the root password.</description> <content:encoded><![CDATA[<p>@Marius</p><p>Eventually I am writing some shell script to support some RAID testing in my system. The script will require the system to login automatically in the normal user mode and then reboot again in one minute. Without the disable root password feature, the script cannot function well. I manage to run the script well in Ubuntu Server 9.04 but somehow I still feel headache to figure out the solution to disable the root password.</p> ]]></content:encoded> </item> <item><title>By: Allan</title><link>http://www.ducea.com/2006/06/18/linux-tips-password-usage-in-sudo-passwd-nopasswd/comment-page-1/#comment-181188</link> <dc:creator>Allan</dc:creator> <pubDate>Mon, 19 Oct 2009 09:24:42 +0000</pubDate> <guid
isPermaLink="false">http://www.ducea.com/2006/06/18/linux-tips-password-usage-in-sudo-passwd-nopasswd/#comment-181188</guid> <description>@MariusI really appreciate that your efforts in solving my problem. Here i attach the full content of the sudoers file:## Sudoers allows particular users to run various commands as
## the root user, without needing the root password.
##
## Examples are provided at the bottom of the file for collections
## of related commands, which can then be delegated out to particular
## users or groups.
##
## This file must be edited with the &#039;visudo&#039; command.## Host Aliases
## Groups of machines. You may prefer to use hostnames (perhap using
## wildcards for entire domains) or IP addresses instead.
# Host_Alias     FILESERVERS = fs1, fs2
# Host_Alias     MAILSERVERS = smtp, smtp2## User Aliases
## These aren&#039;t often necessary, as you can use regular groups
## (ie, from files, LDAP, NIS, etc) in this file - just use %groupname
## rather than USERALIAS
# User_Alias ADMINS = jsmith, mikem## Command Aliases
## These are groups of related commands...## Networking
Cmnd_Alias NETWORKING = /sbin/route, /sbin/ifconfig, /bin/ping, /sbin/dhclient, /usr/bin/net, /sbin/iptables, /usr/bin/rfcomm, /usr/bin/wvdial, /sbin/iwconfig, /sbin/mii-tool## Installation and management of software
Cmnd_Alias SOFTWARE = /bin/rpm, /usr/bin/up2date, /usr/bin/yum## Services
Cmnd_Alias SERVICES = /sbin/service, /sbin/chkconfig## Updating the locate database
Cmnd_Alias LOCATE = /usr/bin/updatedb## Storage
Cmnd_Alias STORAGE = /sbin/fdisk, /sbin/sfdisk, /sbin/parted, /sbin/partprobe, /bin/mount, /bin/umount## Delegating permissions
Cmnd_Alias DELEGATING = /usr/sbin/visudo, /bin/chown, /bin/chmod, /bin/chgrp## Processes
Cmnd_Alias PROCESSES = /bin/nice, /bin/kill, /usr/bin/kill, /usr/bin/killall## Drivers
Cmnd_Alias DRIVERS = /sbin/modprobe# Defaults specification#
# Disable &quot;ssh hostname sudo &quot;, because it will show the password in clear.
#         You have to run &quot;ssh -t hostname sudo &quot;.
#
Defaults    requirettyDefaults    env_reset
Defaults    env_keep = &quot;COLORS DISPLAY HOSTNAME HISTSIZE INPUTRC KDEDIR \
LS_COLORS MAIL PS1 PS2 QTDIR USERNAME \
LANG LC_ADDRESS LC_CTYPE LC_COLLATE LC_IDENTIFICATION \
LC_MEASUREMENT LC_MESSAGES LC_MONETARY LC_NAME LC_NUMERIC \
LC_PAPER LC_TELEPHONE LC_TIME LC_ALL LANGUAGE LINGUAS \
_XKB_CHARSET XAUTHORITY&quot;## Next comes the main part: which users can run what software on
## which machines (the sudoers file can be shared between multiple
## systems).
## Syntax:
##
## 	user	MACHINE=COMMANDS
##
## The COMMANDS section may have other options added to it.
##
## Allow root to run any commands anywhere
root	ALL=(ALL) 	ALL## Allows members of the &#039;sys&#039; group to run networking, software,
## service management apps and more.
# %sys ALL = NETWORKING, SOFTWARE, SERVICES, STORAGE, DELEGATING, PROCESSES, LOCATE, DRIVERS## Allows people in group wheel to run all commands
# %wheel	ALL=(ALL)	ALL## Same thing without a password
# %wheel	ALL=(ALL)	NOPASSWD: ALL## Allows members of the users group to mount and unmount the
## cdrom as root
# %users  ALL=/sbin/mount /mnt/cdrom, /sbin/umount /mnt/cdrom## Allows members of the users group to shutdown this system
# %users  localhost=/sbin/shutdown -h now
ftc	ALL=NOPASSWD: ALL</description> <content:encoded><![CDATA[<p>@Marius</p><p>I really appreciate that your efforts in solving my problem. Here i attach the full content of the sudoers file:</p><p>## Sudoers allows particular users to run various commands as<br
/> ## the root user, without needing the root password.<br
/> ##<br
/> ## Examples are provided at the bottom of the file for collections<br
/> ## of related commands, which can then be delegated out to particular<br
/> ## users or groups.<br
/> ##<br
/> ## This file must be edited with the &#8216;visudo&#8217; command.</p><p>## Host Aliases<br
/> ## Groups of machines. You may prefer to use hostnames (perhap using<br
/> ## wildcards for entire domains) or IP addresses instead.<br
/> # Host_Alias     FILESERVERS = fs1, fs2<br
/> # Host_Alias     MAILSERVERS = smtp, smtp2</p><p>## User Aliases<br
/> ## These aren&#8217;t often necessary, as you can use regular groups<br
/> ## (ie, from files, LDAP, NIS, etc) in this file &#8211; just use %groupname<br
/> ## rather than USERALIAS<br
/> # User_Alias ADMINS = jsmith, mikem</p><p>## Command Aliases<br
/> ## These are groups of related commands&#8230;</p><p>## Networking<br
/> Cmnd_Alias NETWORKING = /sbin/route, /sbin/ifconfig, /bin/ping, /sbin/dhclient, /usr/bin/net, /sbin/iptables, /usr/bin/rfcomm, /usr/bin/wvdial, /sbin/iwconfig, /sbin/mii-tool</p><p>## Installation and management of software<br
/> Cmnd_Alias SOFTWARE = /bin/rpm, /usr/bin/up2date, /usr/bin/yum</p><p>## Services<br
/> Cmnd_Alias SERVICES = /sbin/service, /sbin/chkconfig</p><p>## Updating the locate database<br
/> Cmnd_Alias LOCATE = /usr/bin/updatedb</p><p>## Storage<br
/> Cmnd_Alias STORAGE = /sbin/fdisk, /sbin/sfdisk, /sbin/parted, /sbin/partprobe, /bin/mount, /bin/umount</p><p>## Delegating permissions<br
/> Cmnd_Alias DELEGATING = /usr/sbin/visudo, /bin/chown, /bin/chmod, /bin/chgrp</p><p>## Processes<br
/> Cmnd_Alias PROCESSES = /bin/nice, /bin/kill, /usr/bin/kill, /usr/bin/killall</p><p>## Drivers<br
/> Cmnd_Alias DRIVERS = /sbin/modprobe</p><p># Defaults specification</p><p>#<br
/> # Disable &#8220;ssh hostname sudo &#8220;, because it will show the password in clear.<br
/> #         You have to run &#8220;ssh -t hostname sudo &#8220;.<br
/> #<br
/> Defaults    requiretty</p><p>Defaults    env_reset<br
/> Defaults    env_keep = &#8220;COLORS DISPLAY HOSTNAME HISTSIZE INPUTRC KDEDIR \<br
/> LS_COLORS MAIL PS1 PS2 QTDIR USERNAME \<br
/> LANG LC_ADDRESS LC_CTYPE LC_COLLATE LC_IDENTIFICATION \<br
/> LC_MEASUREMENT LC_MESSAGES LC_MONETARY LC_NAME LC_NUMERIC \<br
/> LC_PAPER LC_TELEPHONE LC_TIME LC_ALL LANGUAGE LINGUAS \<br
/> _XKB_CHARSET XAUTHORITY&#8221;</p><p>## Next comes the main part: which users can run what software on<br
/> ## which machines (the sudoers file can be shared between multiple<br
/> ## systems).<br
/> ## Syntax:<br
/> ##<br
/> ## 	user	MACHINE=COMMANDS<br
/> ##<br
/> ## The COMMANDS section may have other options added to it.<br
/> ##<br
/> ## Allow root to run any commands anywhere<br
/> root	ALL=(ALL) 	ALL</p><p>## Allows members of the &#8217;sys&#8217; group to run networking, software,<br
/> ## service management apps and more.<br
/> # %sys ALL = NETWORKING, SOFTWARE, SERVICES, STORAGE, DELEGATING, PROCESSES, LOCATE, DRIVERS</p><p>## Allows people in group wheel to run all commands<br
/> # %wheel	ALL=(ALL)	ALL</p><p>## Same thing without a password<br
/> # %wheel	ALL=(ALL)	NOPASSWD: ALL</p><p>## Allows members of the users group to mount and unmount the<br
/> ## cdrom as root<br
/> # %users  ALL=/sbin/mount /mnt/cdrom, /sbin/umount /mnt/cdrom</p><p>## Allows members of the users group to shutdown this system<br
/> # %users  localhost=/sbin/shutdown -h now<br
/> ftc	ALL=NOPASSWD: ALL</p> ]]></content:encoded> </item> <item><title>By: - Marius -</title><link>http://www.ducea.com/2006/06/18/linux-tips-password-usage-in-sudo-passwd-nopasswd/comment-page-1/#comment-181176</link> <dc:creator>- Marius -</dc:creator> <pubDate>Sun, 18 Oct 2009 09:45:03 +0000</pubDate> <guid
isPermaLink="false">http://www.ducea.com/2006/06/18/linux-tips-password-usage-in-sudo-passwd-nopasswd/#comment-181176</guid> <description>@Allan: the syntax is good. Please check the rules above that one and to see what might be overwriting it. Either paste the full content of the sudoers file here or better use the contact for me send that to me directly if that is private. I will try to help you out if I see that. hth.</description> <content:encoded><![CDATA[<p>@Allan: the syntax is good. Please check the rules above that one and to see what might be overwriting it. Either paste the full content of the sudoers file here or better use the contact for me send that to me directly if that is private. I will try to help you out if I see that. hth.</p> ]]></content:encoded> </item> <item><title>By: Allan</title><link>http://www.ducea.com/2006/06/18/linux-tips-password-usage-in-sudo-passwd-nopasswd/comment-page-1/#comment-181125</link> <dc:creator>Allan</dc:creator> <pubDate>Wed, 14 Oct 2009 06:12:57 +0000</pubDate> <guid
isPermaLink="false">http://www.ducea.com/2006/06/18/linux-tips-password-usage-in-sudo-passwd-nopasswd/#comment-181125</guid> <description>@MariusI already included user ALL = NOPASSWD: ALL in /etc/sudoers but it is not working. I still need to key in the password when su - is used.Note that i use gedit to open the sudoers list and save it before the system goes to reboot.I am using RED HAT ENTERPRISE 5.1 64bit. Please don&#039;t mind to guide me because i am a Linux newbie.</description> <content:encoded><![CDATA[<p>@Marius</p><p>I already included user ALL = NOPASSWD: ALL in /etc/sudoers but it is not working. I still need to key in the password when su &#8211; is used.</p><p>Note that i use gedit to open the sudoers list and save it before the system goes to reboot.</p><p>I am using RED HAT ENTERPRISE 5.1 64bit. Please don&#8217;t mind to guide me because i am a Linux newbie.</p> ]]></content:encoded> </item> <item><title>By: - Marius -</title><link>http://www.ducea.com/2006/06/18/linux-tips-password-usage-in-sudo-passwd-nopasswd/comment-page-1/#comment-181115</link> <dc:creator>- Marius -</dc:creator> <pubDate>Tue, 13 Oct 2009 09:19:38 +0000</pubDate> <guid
isPermaLink="false">http://www.ducea.com/2006/06/18/linux-tips-password-usage-in-sudo-passwd-nopasswd/#comment-181115</guid> <description>@Allan this should work just fine:
user          ALL = NOPASSWD: ALLBe sure there is not one rule above this one that superseeds it (group based or one for the user), as the order of the rules is important. hth.</description> <content:encoded><![CDATA[<p>@Allan this should work just fine:<br
/> user          ALL = NOPASSWD: ALL</p><p>Be sure there is not one rule above this one that superseeds it (group based or one for the user), as the order of the rules is important. hth.</p> ]]></content:encoded> </item> <item><title>By: Allan</title><link>http://www.ducea.com/2006/06/18/linux-tips-password-usage-in-sudo-passwd-nopasswd/comment-page-1/#comment-181114</link> <dc:creator>Allan</dc:creator> <pubDate>Tue, 13 Oct 2009 09:15:48 +0000</pubDate> <guid
isPermaLink="false">http://www.ducea.com/2006/06/18/linux-tips-password-usage-in-sudo-passwd-nopasswd/#comment-181114</guid> <description>I tried to disable su password by adding the commands in /etc/sudoers in Red Hatuser_name   ALL=(ALL)   NOPASSWD:ALL
user_name   ALL = NOPASSWD: ALLBoth commands are not working. Can i know how to solve it?</description> <content:encoded><![CDATA[<p>I tried to disable su password by adding the commands in /etc/sudoers in Red Hat</p><p>user_name   ALL=(ALL)   NOPASSWD:ALL<br
/> user_name   ALL = NOPASSWD: ALL</p><p>Both commands are not working. Can i know how to solve it?</p> ]]></content:encoded> </item> <item><title>By: Raj</title><link>http://www.ducea.com/2006/06/18/linux-tips-password-usage-in-sudo-passwd-nopasswd/comment-page-1/#comment-180432</link> <dc:creator>Raj</dc:creator> <pubDate>Tue, 09 Jun 2009 16:48:52 +0000</pubDate> <guid
isPermaLink="false">http://www.ducea.com/2006/06/18/linux-tips-password-usage-in-sudo-passwd-nopasswd/#comment-180432</guid> <description>Sudoer: raj (ALL) NOPASSWD: ALLfile1=/etc/nodename
newhost=whateversudo echo $newhost &gt; $file1When I run my script, I always get /etc/nodename permission denied or cannot create.How can I run this command as a non-root user.Any help is appreciated.Raj</description> <content:encoded><![CDATA[<p>Sudoer: raj (ALL) NOPASSWD: ALL</p><p>file1=/etc/nodename<br
/> newhost=whatever</p><p>sudo echo $newhost &gt; $file1</p><p>When I run my script, I always get /etc/nodename permission denied or cannot create.</p><p>How can I run this command as a non-root user.</p><p>Any help is appreciated.</p><p>Raj</p> ]]></content:encoded> </item> <item><title>By: AeonFlux</title><link>http://www.ducea.com/2006/06/18/linux-tips-password-usage-in-sudo-passwd-nopasswd/comment-page-1/#comment-77727</link> <dc:creator>AeonFlux</dc:creator> <pubDate>Wed, 12 Sep 2007 13:11:18 +0000</pubDate> <guid
isPermaLink="false">http://www.ducea.com/2006/06/18/linux-tips-password-usage-in-sudo-passwd-nopasswd/#comment-77727</guid> <description>@Lang ZernerThe tee example as non-root should be:echo â€œwebmaster@example.com joeâ€ &#124; sudo tee -a /etc/mail/virtusertable</description> <content:encoded><![CDATA[<p>@Lang Zerner</p><p>The tee example as non-root should be:</p><p>echo â€œwebmaster@example.com joeâ€ | sudo tee -a /etc/mail/virtusertable</p> ]]></content:encoded> </item> </channel> </rss>
<!-- This site's performance optimized by W3 Total Cache. Dramatically improve the speed and reliability of your blog!

Learn more about our WordPress Plugins: http://www.w3-edge.com/wordpress-plugins/

Minified using memcached
Page Caching using disk (enhanced) (user agent is rejected)
Database Caching 8/24 queries in 0.014 seconds using memcached

Served from: www.ducea.com @ 2010-03-18 10:52:41 -->