You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@commons.apache.org by Nigel Rantor <wi...@wiggly.org> on 2004/08/26 15:18:09 UTC

[REPOST][daemon] non-root user cannot start service on unix?

Hi there,

I posted this about a week ago, if no-one is actually in charge of 
daemon could someone let me know?

Additionally if anyone uses daemon would you like to comment on how you 
think it should be working, or perhaps why it works as it does?

Cheese,

   N

-------------------------------------------------------------------

Hi all,

Using the daemon/jsvc combo I can't seem to start a daemon as a user
other than root.

The process dies in set_caps which is the code path it goes through if
the jsvc binary is compiled on Linux and uses the linux capabilities
interface to do it's thang.

I am just wondering if this is the goal or not? Should I be able to run
a daemon as another user? For a production system it won't matter since
I will want the servers to eb started from init scripts anyway and can
pass the --user arg to the jsvc program.

For development however I don't want to have to run these things as
root. Additionally some developers may not have the option of running
things as root on their systems.

So, I guess I'm asking should I be able to run jsvc as non-root or not?

Cheers,

   Nige

---------------------------------------------------------------------
To unsubscribe, e-mail: commons-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: commons-dev-help@jakarta.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commons-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: commons-dev-help@jakarta.apache.org


Re: [REPOST][daemon] non-root user cannot start service on unix?

Posted by Nigel Rantor <wi...@wiggly.org>.
jean-frederic clere wrote:
>> I am just wondering if this is the goal or not? Should I be able to run
>> a daemon as another user? For a production system it won't matter since
>> I will want the servers to eb started from init scripts anyway and can
>> pass the --user arg to the jsvc program.
>>
>> For development however I don't want to have to run these things as
>> root. Additionally some developers may not have the option of running
>> things as root on their systems.
>>
>> So, I guess I'm asking should I be able to run jsvc as non-root or not?
> 
> 
> No, use java instead.

Thanks for the response, I'm still interested in why it works like this 
though.

I would much rather be able to develop code that runs in as close to the 
production manner as possible.

If you are going to develop an app that uses Daemon then it would be a 
great advantage to be able to let developers test that the code they are 
working runs under jsvc correctly, as it would in the eventual 
production environment, without requiring that they also be given root 
access on machines that they shouldn't have root on (or that the 
sysadmins think they shouldn't have root on).

Thoughts?

   N

---------------------------------------------------------------------
To unsubscribe, e-mail: commons-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: commons-dev-help@jakarta.apache.org


Re: [REPOST][daemon] non-root user cannot start service on unix?

Posted by jean-frederic clere <jf...@fujitsu-siemens.com>.
Nigel Rantor wrote:
> 
> Hi there,
> 
> I posted this about a week ago, if no-one is actually in charge of 
> daemon could someone let me know?
> 
> Additionally if anyone uses daemon would you like to comment on how you 
> think it should be working, or perhaps why it works as it does?
> 
> Cheese,
> 
>   N
> 
> -------------------------------------------------------------------
> 
> Hi all,
> 
> Using the daemon/jsvc combo I can't seem to start a daemon as a user
> other than root.
> 
> The process dies in set_caps which is the code path it goes through if
> the jsvc binary is compiled on Linux and uses the linux capabilities
> interface to do it's thang.

That is normal.

> 
> I am just wondering if this is the goal or not? Should I be able to run
> a daemon as another user? For a production system it won't matter since
> I will want the servers to eb started from init scripts anyway and can
> pass the --user arg to the jsvc program.
> 
> For development however I don't want to have to run these things as
> root. Additionally some developers may not have the option of running
> things as root on their systems.
> 
> So, I guess I'm asking should I be able to run jsvc as non-root or not?

No, use java instead.

> 
> Cheers,
> 
>   Nige
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: commons-dev-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: commons-dev-help@jakarta.apache.org
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: commons-dev-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: commons-dev-help@jakarta.apache.org
> 
> 


---------------------------------------------------------------------
To unsubscribe, e-mail: commons-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: commons-dev-help@jakarta.apache.org