LinuxQuestions.org
Visit Jeremy's Blog.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices


Reply
  Search this Thread
Old 04-26-2011, 04:08 PM   #1
Clarkman
LQ Newbie
 
Registered: Mar 2011
Posts: 24

Rep: Reputation: 0
/etc/rc.local behavior different in Ubuntu vs. Debian ?!?


Hi all;

A rather obscure problem, clearly our understanding here is challenged!

On ubuntu (10.04 & earlier) we boot our apps under a user account from /etc/rc.local which runs under root. First the boot script installs drivers and does rooty things, then we launch the executable under the "myaccount" account:

su myaccount -c startPrg.bash (Inside is the actual /mybin/myprg &; )

and the program is left running (our goal of course)

BUT in debian (lenny) the exit from su terminates its child, which also seems right.

Now confused...

1) How can we spin off a child from /etc/rc.local that executes under a user account, but is not terminated when the su exits?

2) Why does the script act differently on ubuntu vs. debian?

THANKS A LOT!!!

Last edited by Clarkman; 04-26-2011 at 05:16 PM.
 
Old 04-27-2011, 11:37 AM   #2
bsdunix
Senior Member
 
Registered: May 2006
Distribution: BeOS, BSD, Caldera, CTOS, Debian, LFS, Mac, Mandrake, Red Hat, Slackware, Solaris, SuSE
Posts: 1,761

Rep: Reputation: 80
Did you try?

sudo -u username /path/to/command

Works for me in Slackware, not sure about Ubuntu or Debian.
 
  


Reply



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 On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Ubuntu 9.10 unexpected internet behavior Zac Matthew Joseph Linux - Newbie 5 03-10-2010 11:47 PM
Confused About Ubuntu Behavior scorpioofthewoods Ubuntu 2 11-04-2009 11:30 AM
LXer: How To Create A Local Debian/Ubuntu Mirror With apt-mirror LXer Syndicated Linux News 0 01-04-2007 05:33 PM
XTerm url selection SUSE behavior in Debian subspawn Linux - Software 0 12-20-2005 05:38 AM
Debian strange behavior about network config Half_Elf Debian 3 04-01-2004 12:07 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - General

All times are GMT -5. The time now is 03:33 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