LinuxQuestions.org
Review your favorite Linux distribution.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices


Reply
  Search this Thread
Old 04-03-2005, 11:03 PM   #1
cqmyg5
LQ Newbie
 
Registered: Apr 2005
Posts: 29

Rep: Reputation: 15
How to authorize common-user to run "ifconfig eth0 up"???


Hello All,

I couldn't run "ifconfig eth0 up" command if login as a common user, the error message is "Permission deny".

How to authorize common-user to run "ifconfig eth0 up"?

BTW, My linux is Slackware 10.1 and I could run "ifconfig -a" properly as a common user.

Thanks!

Last edited by cqmyg5; 04-03-2005 at 11:16 PM.
 
Old 04-03-2005, 11:10 PM   #2
gbonvehi
Senior Member
 
Registered: Jun 2004
Location: Argentina (SR, LP)
Distribution: Slackware
Posts: 3,145

Rep: Reputation: 53
You can configure sudo to allow users to execute that command. You should use visudo and add a line like:
youruser yourmachinename= NOPASSWD: /sbin/ifconfig eth0 up
Then your user can do: sudo /sbin/ifconfig eth0 up
Note that, visudo is actually vi, i'll make a quick guide on how to use it.
Execute visudo as root, it will automatically open the sudoers file for you. Now,
scroll to the end using the arrow keys and press "o". That will insert a line and let you in Input mode. Type the line I said above, then press ESC and finally :wq .
If you need to delete, quit Input mode with ESC, use the "x" key to delete, then go back to Input mode with the "i" (that won't insert a line as the o).

Last edited by gbonvehi; 04-03-2005 at 11:12 PM.
 
Old 04-03-2005, 11:22 PM   #3
cqmyg5
LQ Newbie
 
Registered: Apr 2005
Posts: 29

Original Poster
Rep: Reputation: 15
Get it! Thank you for your nice and quick reply, and It is so detailed!
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
X says "user not authorized to run the x server" infamous41md Linux - Newbie 3 08-05-2009 08:36 PM
Shell Script: Find "Word" Run "Command" granatica Linux - Software 5 07-25-2007 07:42 AM
tying "dhcpcd" into "ifconfig" up and down Riddick Linux - Software 8 09-10-2005 07:14 PM
which file can i set "ifconfig eth0 up"? Mathsniper Debian 6 04-27-2005 02:17 PM
Can't run "halt" or "reboot" as user, can somebody help? ro_nicu Slackware 4 11-01-2004 07:57 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware

All times are GMT -5. The time now is 06:49 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration