LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 08-15-2004, 10:09 AM   #1
marsques
Member
 
Registered: Jan 2004
Location: Manchester
Distribution: slackware...
Posts: 344

Rep: Reputation: 32
running programs as root


how would i make a program that requires root privilages run automatically say when KDE loads with out me having to enter the root password everytime (actually if this can be done when X starts it would be fantastic - as it would independent of the window manager)...

thanks in advance...
 
Old 08-15-2004, 10:17 AM   #2
masand
LQ Guru
 
Registered: May 2003
Location: INDIA
Distribution: Ubuntu, Solaris,CentOS
Posts: 5,522

Rep: Reputation: 69
u need to give superroot status to that program

thuis can be done by

#chmod u+s <programname with path>

this will allow the program to be executed by any user not only by root

regards
 
Old 08-15-2004, 11:36 AM   #3
marsques
Member
 
Registered: Jan 2004
Location: Manchester
Distribution: slackware...
Posts: 344

Original Poster
Rep: Reputation: 32
thanks ...

is there any way that i can make the program(firestarter - firewall) which requires superroot status to automatically load when KDE or any other window manager loads and not alow any other user to shut it down...
 
Old 08-15-2004, 11:44 AM   #4
masand
LQ Guru
 
Registered: May 2003
Location: INDIA
Distribution: Ubuntu, Solaris,CentOS
Posts: 5,522

Rep: Reputation: 69
why dont u make up a script and put it in
/etc/rc.d/init.d
where all the startup scripts are there
only root will able to close that or when the system shuts down

for the syntax for that script u lookup at any script in that directory

regards

gaurav
 
Old 08-15-2004, 12:41 PM   #5
marsques
Member
 
Registered: Jan 2004
Location: Manchester
Distribution: slackware...
Posts: 344

Original Poster
Rep: Reputation: 32
thanks...

tried that... the program needs xwindows loaded up before it can be run... so when i put it in /etc/rc.d/rc.myprogram

it tries to load the program just before the login promp appears...

is there any way i can make this to happen after Xwindows has been loaded up?

thanks in advance...
 
Old 08-15-2004, 01:18 PM   #6
masand
LQ Guru
 
Registered: May 2003
Location: INDIA
Distribution: Ubuntu, Solaris,CentOS
Posts: 5,522

Rep: Reputation: 69
yes there is method where u can see that the script runs at the end,

have a look at the '/etc/rc.d/rc' script

i haven't done it so give it a try

regards
gaurav
 
  


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
Running programs as root via launcher? Fenster Fedora 3 10-06-2004 03:06 PM
running programs from root oscarp Linux - Software 2 09-17-2004 08:08 AM
Running programs as root from launcher Myrkul23 Linux - General 3 07-19-2004 09:26 PM
running programs as root mehesque Linux - General 16 06-09-2004 04:18 PM
Fluxbox and Running Programs as Root jrdioko Linux - Newbie 5 06-14-2003 07:20 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 09:53 PM.

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