Koozali.org: home of the SME Server
Obsolete Releases => SME 7.x Contribs => Topic started by: EastEnder01 on July 14, 2008, 09:41:06 PM
-
I installed tomcat following the instructions in http://wiki.contribs.org/Tomcat, but it does not seem to be working. I cannot access http://mysite:8080, and a site I installed in an ibay has servlets that do not work.
I placed the necessary war file in tomcat/webapps
config show tomcat results in:
tomcat=service
TCPPort=8080
access=public
status=enabled
Where do I start to troubleshoot?
-
Where do I start to troubleshoot?
What does /var/log/messages say? Any clues especially around the time you issued this command?
signal-event remoteaccess-update
-
Where do I start to troubleshoot?
Start with this command...
[root@sme ~]# /opt/tomcat/bin/startup.sh
And view the logs in...
/opt/tomcat/logs
-
This is what I did...
Login as root
mkdir sun
cd sun
Download latest JDK (jdk-6u7-linux-i586-rpm.bin)
chmod a+x jdk-6u7-linux-i586-rpm.bin
./jdk-6u7-linux-i586-rpm.bin
ln -s /usr/java/jdk1.6.0_07 /usr/java/jdk
wget http://apache.root.lu/tomcat/tomcat-6/v6.0.14/bin/apache-tomcat-6.0.14.tar.gz
tar -xvzf apache-tomcat-6.0.14.tar.gz
mv apache-tomcat-6.0.14 /opt/tomcat
Go into server manager and create a user named tomcat
chown -R tomcat:tomcat /opt/tomcat/
chmod 770 /opt/tomcat/
db accounts setprop tomcat Shell /bin/bash
signal-event user-modify tomcat
pico -w /etc/rc.d/init.d/tomcat
############################################################
Paste in...
#! /bin/bash
#
# tomcat Start the tomcat server.
#
NAME="Jakarta Tomcat 6"
TOMCAT_HOME=/opt/tomcat
CATALINA_HOME=/opt/tomcat
JAVA_HOME=/usr/java/jdk
CATALINA_OPTS="-Dfile.encoding=iso8859-1"
TOMCAT_USER=tomcat
LC_ALL=en_US
export TOMCAT_HOME CATALINA_HOME JAVA_HOME CATALINA_OPTS TOMCAT_USER LC_ALL
cd $TOMCAT_HOME/logs
case "$1" in
start)
echo -ne "Starting $NAME.\n"
/bin/su $TOMCAT_USER $TOMCAT_HOME/bin/startup.sh
;;
stop)
echo -ne "Stopping $NAME.\n"
/bin/su $TOMCAT_USER $TOMCAT_HOME/bin/shutdown.sh
;;
*)
echo "Usage: /etc/init.d/tomcat {start|stop}"
exit 1
;;
esac
exit 0
#########################################################
chmod 755 /etc/rc.d/init.d/tomcat
ln -s /etc/rc.d/init.d/tomcat /etc/rc.d/rc7.d/S98tomcat
ln -s /etc/rc.d/init.d/tomcat /etc/rc.d/rc6.d/K02tomcat
ln -s /etc/rc.d/init.d/tomcat /etc/rc.d/rc2.d/K02tomcat
ln -s /etc/rc.d/init.d/tomcat /etc/rc.d/rc1.d/K02tomcat
ln -s /etc/rc.d/init.d/tomcat /etc/rc.d/rc0.d/K02tomcat
config set tomcat service access public status enabled TCPPort 8080
signal-event remoteaccess-update
pico -w /opt/tomcat/conf/tomcat-users.xml
#########################################################
Paste in between <tomcat-users> </tomcat-users>
<user name="admin" password="admin" roles="standard,manager" />
#########################################################
/etc/rc.d/rc7.d/S98tomcat start
And it works for me...
http://secure.magicwilly.info:8080
-
Start with this command...
[root@sme ~]# /opt/tomcat/bin/startup.sh
And view the logs in...
/opt/tomcat/logs
This gives me the following ourput:
Neither the JAVA_HOME nor the JRE_HOME environment variable is defined
At least one of these environment variable is needed to run this program
-
This is what I did...
Login as root
mkdir sun
cd sun
Download latest JDK (jdk-6u7-linux-i586-rpm.bin)
chmod a+x jdk-6u7-linux-i586-rpm.bin
./jdk-6u7-linux-i586-rpm.bin
ln -s /usr/java/jdk1.6.0_07 /usr/java/jdk
wget http://apache.root.lu/tomcat/tomcat-6/v6.0.14/bin/apache-tomcat-6.0.14.tar.gz
tar -xvzf apache-tomcat-6.0.14.tar.gz
mv apache-tomcat-6.0.14 /opt/tomcat
Go into server manager and create a user named tomcat
chown -R tomcat:tomcat /opt/tomcat/
chmod 770 /opt/tomcat/
db accounts setprop tomcat Shell /bin/bash
signal-event user-modify tomcat
pico -w /etc/rc.d/init.d/tomcat
############################################################
Paste in...
#! /bin/bash
#
# tomcat Start the tomcat server.
#
NAME="Jakarta Tomcat 6"
TOMCAT_HOME=/opt/tomcat
CATALINA_HOME=/opt/tomcat
JAVA_HOME=/usr/java/jdk
CATALINA_OPTS="-Dfile.encoding=iso8859-1"
TOMCAT_USER=tomcat
LC_ALL=en_US
export TOMCAT_HOME CATALINA_HOME JAVA_HOME CATALINA_OPTS TOMCAT_USER LC_ALL
cd $TOMCAT_HOME/logs
case "$1" in
start)
echo -ne "Starting $NAME.\n"
/bin/su $TOMCAT_USER $TOMCAT_HOME/bin/startup.sh
;;
stop)
echo -ne "Stopping $NAME.\n"
/bin/su $TOMCAT_USER $TOMCAT_HOME/bin/shutdown.sh
;;
*)
echo "Usage: /etc/init.d/tomcat {start|stop}"
exit 1
;;
esac
exit 0
#########################################################
chmod 755 /etc/rc.d/init.d/tomcat
ln -s /etc/rc.d/init.d/tomcat /etc/rc.d/rc7.d/S98tomcat
ln -s /etc/rc.d/init.d/tomcat /etc/rc.d/rc6.d/K02tomcat
ln -s /etc/rc.d/init.d/tomcat /etc/rc.d/rc2.d/K02tomcat
ln -s /etc/rc.d/init.d/tomcat /etc/rc.d/rc1.d/K02tomcat
ln -s /etc/rc.d/init.d/tomcat /etc/rc.d/rc0.d/K02tomcat
config set tomcat service access public status enabled TCPPort 8080
signal-event remoteaccess-update
pico -w /opt/tomcat/conf/tomcat-users.xml
#########################################################
Paste in between <tomcat-users> </tomcat-users>
<user name="admin" password="admin" roles="standard,manager" />
#########################################################
/etc/rc.d/rc7.d/S98tomcat start
And it works for me...
http://secure.magicwilly.info:8080
Tried as you suggested - I removed the previous installation and reinstalled exactly as you outined above. Still nothin
-
Tried as you suggested - I removed the previous installation and reinstalled exactly as you outined above. Still nothin
And you still did not provide any information on the contents of /var/log/messages? Perhaps there are some clues there (especially when starting the service)...
-
Clipped from the middle of /var/logs/messages:
Jul 15 15:26:13 cmenl esmith::event[5249]: generic_template_expand=action|Event|user-modify|Action|generic_template_expand|Start|1216144570 894201|End|1216144573 910785|Elapsed$
Jul 15 15:26:13 cmenl esmith::event[5249]: Running event handler: /etc/e-smith/events/user-modify/S15user-modify-unix
Jul 15 15:26:14 cmenl esmith::event[5249]: No account db record found for user tomcat at /etc/e-smith/events/user-modify/S15user-modify-unix line 43.
Jul 15 15:26:14 cmenl esmith::event[5249]: S15user-modify-unix=action|Event|user-modify|Action|S15user-modify-unix|Start|1216144573 911782|End|1216144574 205388|Elapsed|0.29360$
Jul 15 15:26:14 cmenl esmith::event[5249]: Running event handler: /etc/e-smith/events/user-modify/S20qmail-update-group
Jul 15 15:26:14 cmenl esmith::event[5249]: Group tomcat not found in accounts db
Jul 15 15:26:14 cmenl esmith::event[5249]: S20qmail-update-group=action|Event|user-modify|Action|S20qmail-update-group|Start|1216144574 206074|End|1216144574 569077|Elapsed|0.3$
Jul 15 15:26:14 cmenl esmith::event[5249]: Running event handler: /etc/e-smith/events/user-modify/S20qmail-update-user
Jul 15 15:26:14 cmenl esmith::event[5249]: Account tomcat is not a user account; update email forwarding failed.
Jul 15 15:26:14 cmenl esmith::event[5249]: S20qmail-update-user=action|Event|user-modify|Action|S20qmail-update-user|Start|1216144574 569750|End|1216144574 891496|Elapsed|0.321$
Jul 15 15:26:14 cmenl esmith::event[5249]: Running event handler: /etc/e-smith/events/user-modify/S25ldap-update
Jul 15 15:26:15 cmenl esmith::event[5249]: Account tomcat not found.
Jul 15 15:26:15 cmenl esmith::event[5249]: S25ldap-update=action|Event|user-modify|Action|S25ldap-update|Start|1216144574 892146|End|1216144575 781251|Elapsed|0.889105|Status|6$
Jul 15 15:26:15 cmenl esmith::event[5249]: Running event handler: /etc/e-smith/events/user-modify/S50user-modify-quota
Jul 15 15:26:16 cmenl esmith::event[5249]: Account "tomcat" is not a user account; modify user quota failed.
Jul 15 15:26:16 cmenl esmith::event[5249]: S50user-modify-quota=action|Event|user-modify|Action|S50user-modify-quota|Start|1216144575 781927|End|1216144576 176073|Elapsed|0.394$
Jul 15 15:26:16 cmenl esmith::event[5249]: Running event handler: /etc/e-smith/events/user-modify/S55email-assign
Jul 15 15:26:16 cmenl esmith::event[5249]: S55email-assign=action|Event|user-modify|Action|S55email-assign|Start|1216144576 176748|End|1216144576 206310|Elapsed|0.029562
Jul 15 15:26:16 cmenl esmith::event[5249]: Running event handler: /etc/e-smith/events/user-modify/S85user-group-modify
Jul 15 15:26:16 cmenl esmith::event[5249]: S85user-group-modify=action|Event|user-modify|Action|S85user-group-modify|Start|1216144576 207297|End|1216144576 720875|Elapsed|0.513$
Jul 15 15:26:16 cmenl esmith::event[5249]: Running event handler: /etc/e-smith/events/actions/adjust-services
Jul 15 15:26:17 cmenl esmith::event[5249]: adjusting supervised radiusd (sigterm)
Jul 15 15:26:17 cmenl esmith::event[5249]: adjusting supervised radiusd (up)
Jul 15 15:26:17 cmenl esmith::event[5249]: adjusting supervised qmail (sighup)
Jul 15 15:26:17 cmenl esmith::event[5249]: adjusting supervised qmail (up)
Jul 15 15:26:17 cmenl esmith::event[5249]: adjusting supervised smbd (sighup)
Jul 15 15:26:17 cmenl esmith::event[5249]: adjusting supervised smbd (up)
Jul 15 15:26:17 cmenl esmith::event[5249]: adjust-services=action|Event|user-modify|Action|adjust-services|Start|1216144576 721664|End|1216144577 569448|Elapsed|0.847784
Jul 15 15:28:11 cmenl /sbin/e-smith/db[5279]: /home/e-smith/db/configuration: OLD tomcat=service|TCPPort|8080|access|public|status|enabled
Jul 15 15:28:11 cmenl /sbin/e-smith/db[5279]: /home/e-smith/db/configuration: NEW tomcat=service
Jul 15 15:28:11 cmenl /sbin/e-smith/db[5279]: /home/e-smith/db/configuration: OLD tomcat=service
Jul 15 15:28:11 cmenl /sbin/e-smith/db[5279]: /home/e-smith/db/configuration: NEW tomcat=service|TCPPort|8080
Jul 15 15:28:11 cmenl /sbin/e-smith/db[5279]: /home/e-smith/db/configuration: OLD tomcat=service|TCPPort|8080
Jul 15 15:28:11 cmenl /sbin/e-smith/db[5279]: /home/e-smith/db/configuration: NEW tomcat=service|TCPPort|8080|access|public
Jul 15 15:28:11 cmenl /sbin/e-smith/db[5279]: /home/e-smith/db/configuration: OLD tomcat=service|TCPPort|8080|access|public
Jul 15 15:28:11 cmenl /sbin/e-smith/db[5279]: /home/e-smith/db/configuration: NEW tomcat=service|TCPPort|8080|access|public|status|enabled
Jul 15 15:28:22 cmenl esmith::event[5280]: Processing event: remoteaccess-update
-
Clipped from the middle of /var/logs/messages:
Jul 15 15:26:13 cmenl esmith::event[5249]: generic_template_expand=action|Event|user-modify|Action|generic_template_expand|Start|1216144570 894201|End|1216144573 910785|Elapsed$
Jul 15 15:26:13 cmenl esmith::event[5249]: Running event handler: /etc/e-smith/events/user-modify/S15user-modify-unix
Jul 15 15:26:14 cmenl esmith::event[5249]: No account db record found for user tomcat at /etc/e-smith/events/user-modify/S15user-modify-unix line 43.
Jul 15 15:26:14 cmenl esmith::event[5249]: S15user-modify-unix=action|Event|user-modify|Action|S15user-modify-unix|Start|1216144573 911782|End|1216144574 205388|Elapsed|0.29360$
Jul 15 15:26:14 cmenl esmith::event[5249]: Running event handler: /etc/e-smith/events/user-modify/S20qmail-update-group
Jul 15 15:26:14 cmenl esmith::event[5249]: Group tomcat not found in accounts db
Jul 15 15:26:14 cmenl esmith::event[5249]: S20qmail-update-group=action|Event|user-modify|Action|S20qmail-update-group|Start|1216144574 206074|End|1216144574 569077|Elapsed|0.3$
Jul 15 15:26:14 cmenl esmith::event[5249]: Running event handler: /etc/e-smith/events/user-modify/S20qmail-update-user
Jul 15 15:26:14 cmenl esmith::event[5249]: Account tomcat is not a user account; update email forwarding failed.
Jul 15 15:26:14 cmenl esmith::event[5249]: S20qmail-update-user=action|Event|user-modify|Action|S20qmail-update-user|Start|1216144574 569750|End|1216144574 891496|Elapsed|0.321$
Jul 15 15:26:14 cmenl esmith::event[5249]: Running event handler: /etc/e-smith/events/user-modify/S25ldap-update
Jul 15 15:26:15 cmenl esmith::event[5249]: Account tomcat not found.
Jul 15 15:26:15 cmenl esmith::event[5249]: S25ldap-update=action|Event|user-modify|Action|S25ldap-update|Start|1216144574 892146|End|1216144575 781251|Elapsed|0.889105|Status|6$
Jul 15 15:26:15 cmenl esmith::event[5249]: Running event handler: /etc/e-smith/events/user-modify/S50user-modify-quota
Jul 15 15:26:16 cmenl esmith::event[5249]: Account "tomcat" is not a user account; modify user quota failed.
Jul 15 15:26:16 cmenl esmith::event[5249]: S50user-modify-quota=action|Event|user-modify|Action|S50user-modify-quota|Start|1216144575 781927|End|1216144576 176073|Elapsed|0.394$
Jul 15 15:26:16 cmenl esmith::event[5249]: Running event handler: /etc/e-smith/events/user-modify/S55email-assign
Jul 15 15:26:16 cmenl esmith::event[5249]: S55email-assign=action|Event|user-modify|Action|S55email-assign|Start|1216144576 176748|End|1216144576 206310|Elapsed|0.029562
Jul 15 15:26:16 cmenl esmith::event[5249]: Running event handler: /etc/e-smith/events/user-modify/S85user-group-modify
Jul 15 15:26:16 cmenl esmith::event[5249]: S85user-group-modify=action|Event|user-modify|Action|S85user-group-modify|Start|1216144576 207297|End|1216144576 720875|Elapsed|0.513$
Jul 15 15:26:16 cmenl esmith::event[5249]: Running event handler: /etc/e-smith/events/actions/adjust-services
Jul 15 15:26:17 cmenl esmith::event[5249]: adjusting supervised radiusd (sigterm)
Jul 15 15:26:17 cmenl esmith::event[5249]: adjusting supervised radiusd (up)
Jul 15 15:26:17 cmenl esmith::event[5249]: adjusting supervised qmail (sighup)
Jul 15 15:26:17 cmenl esmith::event[5249]: adjusting supervised qmail (up)
Jul 15 15:26:17 cmenl esmith::event[5249]: adjusting supervised smbd (sighup)
Jul 15 15:26:17 cmenl esmith::event[5249]: adjusting supervised smbd (up)
Jul 15 15:26:17 cmenl esmith::event[5249]: adjust-services=action|Event|user-modify|Action|adjust-services|Start|1216144576 721664|End|1216144577 569448|Elapsed|0.847784
Jul 15 15:28:11 cmenl /sbin/e-smith/db[5279]: /home/e-smith/db/configuration: OLD tomcat=service|TCPPort|8080|access|public|status|enabled
Jul 15 15:28:11 cmenl /sbin/e-smith/db[5279]: /home/e-smith/db/configuration: NEW tomcat=service
Jul 15 15:28:11 cmenl /sbin/e-smith/db[5279]: /home/e-smith/db/configuration: OLD tomcat=service
Jul 15 15:28:11 cmenl /sbin/e-smith/db[5279]: /home/e-smith/db/configuration: NEW tomcat=service|TCPPort|8080
Jul 15 15:28:11 cmenl /sbin/e-smith/db[5279]: /home/e-smith/db/configuration: OLD tomcat=service|TCPPort|8080
Jul 15 15:28:11 cmenl /sbin/e-smith/db[5279]: /home/e-smith/db/configuration: NEW tomcat=service|TCPPort|8080|access|public
Jul 15 15:28:11 cmenl /sbin/e-smith/db[5279]: /home/e-smith/db/configuration: OLD tomcat=service|TCPPort|8080|access|public
Jul 15 15:28:11 cmenl /sbin/e-smith/db[5279]: /home/e-smith/db/configuration: NEW tomcat=service|TCPPort|8080|access|public|status|enabled
Jul 15 15:28:22 cmenl esmith::event[5280]: Processing event: remoteaccess-update
It seems there are problems with the tomcat user/group... perhaps this might be the cause. I also do not see that you are starting the service... did you already do try to start the service?
-
On the user/group, these lines from the wiki/howto:
give me back the following:
[root@cmenl ~]# groupadd tomcat
groupadd: group tomcat exists
[root@cmenl ~]# useradd -g tomcat -d /opt/tomcat tomcat
useradd: user tomcat exists
As for starting the service doesn't /etc/rc.d/init.d/tomcat do that?
I tried doing this:
/bin/su $TOMCAT_USER $TOMCAT_HOME/bin/startup.sh
and got this...
/bin/su: user /bin/startup.sh does not exist
-
On the user/group, these lines from the wiki/howto:
give me back the following:
[root@cmenl ~]# groupadd tomcat
groupadd: group tomcat exists
[root@cmenl ~]# useradd -g tomcat -d /opt/tomcat tomcat
useradd: user tomcat exists
So you created the user at a later stage, seems OK.
As for starting the service doesn't /etc/rc.d/init.d/tomcat do that?
Yes but not by only adding the (sym)link.
I tried doing this:
/bin/su $TOMCAT_USER $TOMCAT_HOME/bin/startup.sh
and got this...
/bin/su: user /bin/startup.sh does not exist
That is because most likely the $TOMCAT_USER and $TOMCAT_HOME are set in the script and not known on the CLI. Why don't you just try the commands in the wiki, it states even in bold:
Make startup script runable and make tomcat start automatically at boot
Which means reboot and the service should be started... did you already try that? Perhaps this will work as well, although I can not test it:
service tomcat start
-
So you created the user at a later stage, seems OK.
Had done this right from the start - following the wiki...
Yes but not by only adding the (sym)link.
That is because most likely the $TOMCAT_USER and $TOMCAT_HOME are set in the script and not known on the CLI. Why don't you just try the commands in the wiki, it states even in bold:Which means reboot and the service should be started... did you already try that?
Yes I did
Perhaps this will work as well, although I can not test it:
service tomcat start
Gives me this:
[root@cmenl ~]# service tomcat start
Starting Jakarta Tomcat 6.
Using CATALINA_BASE: /opt/tomcat
Using CATALINA_HOME: /opt/tomcat
Using CATALINA_TMPDIR: /opt/tomcat/temp
Using JRE_HOME: /usr/java/jdk
-
Had done this right from the start - following the wiki...
Yes I did
Gives me this:
[root@cmenl ~]# service tomcat start
Starting Jakarta Tomcat 6.
Using CATALINA_BASE: /opt/tomcat
Using CATALINA_HOME: /opt/tomcat
Using CATALINA_TMPDIR: /opt/tomcat/temp
Using JRE_HOME: /usr/java/jdk
And... what is the result when you try to access the server? This does not say much to me other than that it seems to be starting, but I have no way of testing this as I do not have it installed.
I guess, as you said you already rebooted, the symlinks, that should start tomcat at boot time, might not be correct... provided that you can access your tomcat server now after manually starting it...
-
when i try going to www.mysite:8080 I get a "Page cannot be found error"
-
The only changes I made from the wiki was..
Create the tomcat user via the server-manager
Gave the tomcat user access to a shell but with no password set.
Prior to doing the above it appeared that JAVA_HOME wasn't being set.
(http://magicwilly.webhostingpal.com/ContribsForumPictures/tomcat/tomcat.png)
-
On the user/group, these lines from the wiki/howto:
give me back the following:
[root@cmenl ~]# groupadd tomcat
groupadd: group tomcat exists
[root@cmenl ~]# useradd -g tomcat -d /opt/tomcat tomcat
useradd: user tomcat exists
I really don't think creating users and groups at the command line using regular linux tools is a good idea with smeserver.
As for starting the service doesn't /etc/rc.d/init.d/tomcat do that?
I tried doing this:
/bin/su $TOMCAT_USER $TOMCAT_HOME/bin/startup.sh
and got this...
/bin/su: user /bin/startup.sh does not exist
$TOMCAT_USER and $TOMCAT_HOME are variables that have to be set to some value before you use them.
In the init script, they get set to tomcat and /opt/tomcat respectively.
So, to expand out that line like the script would you need to type
/bin/su tomcat /opt/tomcat/bin/startup.sh
-
Tried creating tomcat user in server-manager, but it wouldn't allow me. It came back with an error message saying that a system user by the same name already exists. I took that to mean that the tomcat user I created from the wiki was already there...
-
/bin/su tomcat /opt/tomcat/bin/startup.sh
When I do that I get the following:
Neither the JAVA_HOME nor the JRE_HOME environment variable is defined
At least one of these environment variable is needed to run this program
-
When I do that I get the following:
Neither the JAVA_HOME nor the JRE_HOME environment variable is defined
At least one of these environment variable is needed to run this program
It should be defined in the script... you did create the script as stated in the wiki, did you? Or are you just trying to execute lines from that on the command line? If you did not create the script I think we have the reason that your tomcat server is not starting at boot time.
I am still wondering if you are following the HowTo to the letter as other user(s) have had no problems getting it to run with the instructions stated there.
-
I followed it absolutely to the letter...
The script I created was cut and paste from the wiki - as below:
#! /bin/bash
#
# tomcat Start the tomcat server.
#
NAME="Jakarta Tomcat 6"
TOMCAT_HOME=/opt/tomcat
CATALINA_HOME=/opt/tomcat
JAVA_HOME=/usr/java/jdk
CATALINA_OPTS="-Dfile.encoding=iso8859-1"
TOMCAT_USER=tomcat
LC_ALL=en_US
export TOMCAT_HOME CATALINA_HOME JAVA_HOME CATALINA_OPTS TOMCAT_USER LC_ALL
cd $TOMCAT_HOME/logs
case "$1" in
start)
echo -ne "Starting $NAME.\n"
/bin/su $TOMCAT_USER $TOMCAT_HOME/bin/startup.sh
;;
stop)
echo -ne "Stopping $NAME.\n"
/bin/su $TOMCAT_USER $TOMCAT_HOME/bin/shutdown.sh
;;
*)
echo "Usage: /etc/init.d/tomcat {start|stop}"
exit 1
;;
esac
exit 0
Is there an easy way to start-over???
-
I followed it absolutely to the letter...
Then I still do not understand why a reboot does not start it...
Comparing this post of you (http://forums.contribs.org/index.php?topic=41593.msg194222#msg194222) to the results shown in this post of william_syd (http://forums.contribs.org/index.php?topic=41593.msg194222#msg194222) I think it is starting fine as the output looks more or less the same.
That still leaves the issue why you can not access it. Does tomcat have errorlogs as well? Perhaps a clue might be in there.
After you have started it does it stay up? Try this a few times after starting the service:
ps aux | grep tomcat
Above should at least output all process run as the tomcat user under which the process should be started judging from the script.
If not it seems it does not stay up... otherwise it should be up and accessible. Did you try and access it from your server itself already?
elinks http://localhost:8080
-
Then I still do not understand why a reboot does not start it...
Comparing this post of you (http://forums.contribs.org/index.php?topic=41593.msg194222#msg194222) to the results shown in this post of william_syd (http://forums.contribs.org/index.php?topic=41593.msg194222#msg194222) I think it is starting fine as the output looks more or less the same.
That still leaves the issue why you can not access it. Does tomcat have errorlogs as well? Perhaps a clue might be in there.
This is from the only file in the tomcat log directory (catalina.out):
/opt/tomcat/bin/catalina.sh: line 273: /usr/java/jdk/bin/java: is a directory
/opt/tomcat/bin/catalina.sh: line 273: /usr/java/jdk/bin/java: is a directory
/opt/tomcat/bin/catalina.sh: line 273: /usr/java/jdk/bin/java: is a directory
After you have started it does it stay up? Try this a few times after starting the service:
ps aux | grep tomcat
Above should at least output all process run as the tomcat user under which the process should be started judging from the script.
That gives me this output:
root 5811 0.0 0.1 5712 572 pts/0 S+ 15:30 0:00 grep tomcat
If not it seems it does not stay up... otherwise it should be up and accessible. Did you try and access it from your server itself already?
elinks http://localhost:8080
elinks http://localhost:8080 gives me a Connection Refused error screen... :sad: :-?
-
From the cli, remove the tomcat user and group.
Then...
Go into server manager and create a user named tomcat
chown -R tomcat:tomcat /opt/tomcat/
chmod 770 /opt/tomcat/
db accounts setprop tomcat Shell /bin/bash
signal-event user-modify tomcat
-
From the cli, remove the tomcat user and group.
Then...
Go into server manager and create a user named tomcat
chown -R tomcat:tomcat /opt/tomcat/
chmod 770 /opt/tomcat/
db accounts setprop tomcat Shell /bin/bash
signal-event user-modify tomcat
Wouldn't this do as well (although your method might be preffered as you have the user displayed in te server-manager as well)?
usermod -s /bin/bash tomcat