Slackware This Forum is for the discussion of Slackware Linux.
|
Notices |
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
Are you new to LinuxQuestions.org? Visit the following links:
Site Howto |
Site FAQ |
Sitemap |
Register Now
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
|
 |
03-18-2006, 12:18 AM
|
#1
|
Senior Member
Registered: Mar 2006
Distribution: SLACKWARE 4TW! =D
Posts: 1,519
Rep:
|
How I got XFCE to allow users to shutdown or reboot Slackware 10.2
Hi all,
Just putting this here becuase it took me 4 hours to figure this out
As allways back up first.
1. open terminal as root.
2. type "visudo" and hit enter.
3. use your arrow keys to navigate down to #samples section.
4. use "X" key to get rid of # sign by %users...then when done hit escape key.
5. then go to next line (that is the next line down without anything in it under the users) and hit "i" key to insert the following line:
%users pooter-name=NOPASSWD: /usr/libexec/xfsm-shutdown-helper
6. now hit escape key
7: now type ":"
8. now type w
9. now type ":"
10. now type "q"
Last edited by Old_Fogie; 06-10-2006 at 01:44 AM.
|
|
|
03-18-2006, 01:45 AM
|
#2
|
Member
Registered: Mar 2005
Location: chennai(madras), India
Distribution: slackware ofcourse
Posts: 654
Rep:
|
nice work, but "sudo"
Quote:
with a goofy and hard to use program called "visudo"
|
seems like it is similar to "vi", vi is powerfull and i like it the most.  , u acn start from "vimtutor" then u wil find it easier
Quote:
7: now type ":"
8. now type w
9. now type ":"
10. now type "q"
|
":wq" wil do the job in a single line-means-write and quit
|
|
|
03-18-2006, 12:19 PM
|
#3
|
Newbie
Registered: Nov 2005
Location: MN, USA
Distribution: Slackware-Current, WinXP Pro SP2
Posts: 20
Rep:
|
Where does it say you need to use visudo? I edited my /etc/sudoers, and all of the other config files, with evim.
either way, glad it worked out for you though!
|
|
|
03-18-2006, 12:29 PM
|
#4
|
Senior Member
Registered: Oct 2004
Posts: 1,272
Rep: 
|
visudo checks the sudoers file after it has been edited for errors and invites you to fix them if errors are found.
|
|
|
03-18-2006, 03:07 PM
|
#5
|
Senior Member
Registered: Oct 2005
Distribution: Slackware 14.1
Posts: 3,482
|
I empathize with Old_Fogie. Although I can more or less use vi/vim when in a pinch, I find all 'nix console text editors to be a Neanderthal joke (See Item No. 1 at A Software Wish List).
I keep a short cheat sheet handy so I can use vim in those few situations when I can't launch X and must edit a file from the console. Otherwise I use Kate to modify all of my config files, including my sudoers list.
As mentioned by phil.d.g, visudo provides some syntax and typo error checking, and that is a Good Thing. However, one can run visudo independently to only check errors ( visudo -c) and need not use that Neanderthal tool to actually edit the sudoers file. Read the visudo man page for additional details. Do know that by default the sudoers file is not writeable and users must first chmod +x the file before editing with an editor other than visudo.
|
|
|
03-18-2006, 03:34 PM
|
#6
|
Senior Member
Registered: Oct 2004
Posts: 1,272
Rep: 
|
I've just read the man page for visudo and you can change the editor used by visudo, in your sudoers file you can put a line
Code:
Defaults editor=/path/to/your/editor
So you get all the benefits of visudo and you get to use your favourite editor. Though, personally I think I'll stick to that "Neanderthal joke" of an editor that goes by the more common name "vi" 
|
|
|
03-21-2006, 08:13 AM
|
#7
|
Senior Member
Registered: Mar 2006
Distribution: SLACKWARE 4TW! =D
Posts: 1,519
Original Poster
Rep:
|
yes i stand corrected.
the program is "VI"
and it is quite goofy
but, interestingly enough I too have found myself using it when at console/tty. it works quite well.
another point of mention; i cannot use "visudo" in mepis even as root. strange.
LOL Woodsman, you should see my notebooks over here, printouts, sticky's 
|
|
|
03-21-2006, 08:50 AM
|
#8
|
Moderator
Registered: Jan 2005
Location: Central Florida 20 minutes from Disney World
Distribution: SlackwareŽ
Posts: 13,979
|
Quote:
Originally Posted by Old_Fogie
yes i stand corrected.
the program is "VI"
and it is quite goofy
but, interestingly enough I too have found myself using it when at console/tty. it works quite well.
another point of mention; i cannot use "visudo" in mepis even as root. strange.
LOL Woodsman, you should see my notebooks over here, printouts, sticky's 
|
Hi,
Some good points! Vi is not goofy if you understand the syntax.
Try the vi tutorial!
I think everyone should at least get the experience with vi,vim or whatever basic text editor to allow edits of config files.
Hey, at times you might not have that X app that you faithfully use to make the task easier on you. Sure I use X and like it for ease of use. But and a big BUT here. You need to be aware of cli usage or you will fall to the use of a poor OS. I want slack to run at the best possible configuration on any machine within my control.
Sure pride is the reason here!
Slackware is my OS rock!
|
|
|
03-21-2006, 09:51 AM
|
#9
|
Member
Registered: Nov 2003
Location: 46N 76W
Distribution: Slackware 14.1
Posts: 380
Rep:
|
Am I the only one here who likes MidnightCommander?
I just type mc at the command line as root, and can do anything.
|
|
|
03-21-2006, 04:16 PM
|
#10
|
Senior Member
Registered: Oct 2005
Distribution: Slackware 14.1
Posts: 3,482
|
Quote:
Am I the only one here who likes MidnightCommander?
I just type mc at the command line as root, and can do anything.
|
I use mc and mc edit. However, because I seldom need to edit files from the console I tend to forget about using the mc editor until I need to manage files from the console. Using mc to manage files is easier than playing command line commando. As I mentioned, I can use vim, but there simply does not exist a console-based editor that satisfies my criteria of an editor. vi/vim/emacs, etc., probably all made sense 20 to 30 years ago, but nobody will convince me that those editors are user-friendly. Still, mc edit is another option to consider.
|
|
|
03-22-2006, 10:42 AM
|
#11
|
Moderator
Registered: Jan 2005
Location: Central Florida 20 minutes from Disney World
Distribution: SlackwareŽ
Posts: 13,979
|
Quote:
Originally Posted by Woodsman
I use mc and mc edit. However, because I seldom need to edit files from the console I tend to forget about using the mc editor until I need to manage files from the console. Using mc to manage files is easier than playing command line commando. As I mentioned, I can use vim, but there simply does not exist a console-based editor that satisfies my criteria of an editor. vi/vim/emacs, etc., probably all made sense 20 to 30 years ago, but nobody will convince me that those editors are user-friendly. Still, mc edit is another option to consider.
|
Hi,
Like I said in a previous post an admin needs to be able to use a basic editor. mc seems to meet your needs. As for the 20-30 years ago reference, the core of the thought is to use a simple editor on the cli. No one stated they are user friendly! But if you use them on a regular basis then the ease of use becomes comfortable.
Tell me the first time you used mc you knew it. No mc had a learning curve but the use is intuitive. I don't use mc that often but when I need to the use is easy. I'm comfortable with vi/vim and the layout of my system so the point and click is not that important to me.
Heck, I do some maintenance in X for some of the installations.
But most is cli.
Tools are tools! You should use the one that meets the needs at the time. Be for hardware or software!
|
|
|
03-22-2006, 03:04 PM
|
#12
|
Senior Member
Registered: Mar 2006
Distribution: SLACKWARE 4TW! =D
Posts: 1,519
Original Poster
Rep:
|
Quote:
Originally Posted by WilliamS
Am I the only one here who likes MidnightCommander?
I just type mc at the command line as root, and can do anything.
|
OMG I didn't know you could do that hahahahah, remember I'm a month on Linux "nub". I learn-yid sumtin new maw! 
|
|
|
All times are GMT -5. The time now is 10:59 AM.
|
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.
|
Latest Threads
LQ News
|
|