Operating System - HP-UX
1832458 Members
2915 Online
110043 Solutions
New Discussion

Re: tomcat server and rksh

 
SOLVED
Go to solution
Thomas Schler_1
Trusted Contributor

tomcat server and rksh

Hi,

how do I start the Tomcat server 4.1 as user 'www' using rksh?

OS: HP-UX 11.00

The tomcat server should be started from the start/stop script /sbin/init.d/hpws_tomcat. The command to start tomcat should be something like:
su www -c startup.sh

Since rksh is used the command cannot contain any slash (/). Therefore, ~www/.profile contains following lines:
PATH=/www/tomcat/bin:~/bin
export PATH
ksh(1) mentions that restrictions get activated after .profile is executed (i.e. PATH can be set within .profile).

startup.sh is in /www/tomcat/bin. HPWS_TOMCAT_HOME is defined as /www/tomcat. File permissions are ok.

Executing '/sbin/init.d/hpws_tomcat start' results:
rksh: startup.sh: not found
ERROR: Could not start Tomcat.

Tomcat server would start if I use ksh and the command 'su www -c $HPWS_TOMCAT_HOME/bin/startup.sh'.

So, how would you start the tomcat server from user www with rksh?
no users -- no problems
2 REPLIES 2
Thomas Schler_1
Trusted Contributor

Re: tomcat server and rksh

No idea from anybody?
no users -- no problems
Klaus Crusius
Trusted Contributor
Solution

Re: tomcat server and rksh

You have to use "su - -c ...", otherwise the .profile is not executed at all.

Thanks
There is a live before death!