You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@commons.apache.org by Gu...@tietoenator.com on 2008/05/09 10:25:39 UTC

Catalina.out and pid-file owned by root

Hi,
I want to run Tomcat on port 80 or 443 without starting as root so I use
the jsvc program.
This works fine but I would like to have the files catalina.out and
pid-file
to be owned by the user jsvc switches to (-user xxxx) and not by root.

Is that possible?
Regards
Gunnar


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


Re: Catalina.out and pid-file owned by root

Posted by Ole Ersoy <ol...@gmail.com>.
Gunnar,

My understanding is that if you launch Tomcat fresh (Never been started before) it will create catalina.out and the pid-file, and since it's running at a non-root user (Say user tomcat), user tomcat will own the pid and the catalina.out file, as well as any other files created at runtime.  

If you already started tomcat as root, then catalina.out is root owned.  Just chown it to whatever user you are running as and I would also chmod catalina.out permissions to 600 so that only tomcat can read and write to it.

Cheers,
- Ole

Gunnar.Bostrom@tietoenator.com wrote:
> Hi,
> I want to run Tomcat on port 80 or 443 without starting as root so I use
> the jsvc program.
> This works fine but I would like to have the files catalina.out and
> pid-file
> to be owned by the user jsvc switches to (-user xxxx) and not by root.
> 
> Is that possible?
> Regards
> Gunnar
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@commons.apache.org
> For additional commands, e-mail: user-help@commons.apache.org
> 
> 

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