meeven

Well-Known Member
May 8, 2007
132
2
168
I installed the Tomcat beta that was available in an early version of cPanel 11. For the jsvc, I manually installed it using mtindor's steps since an earlier post by cPanelkenneth said the jsvc version that Apache shipped was severely out of date.

That latter post also said:
The Tomcat installer in EA3 ships the most recent release of jsvc, resolving this particular issue.
I checked WHM and it shows Easy::Apache v3.2.0 Build 3634.

To get a version of Tomcat that is integrated with cPanel, would the following be the right sequence
  • Uninstall Tomcat in WHM at cPanel >> Manage Plugins
  • Remove the /usr/local/jakarta package that contains the jsvc
  • Run the Easy Apache update to automatically install Tomcat along with the right jsvc
  • Install the servlets once again for the domain needing it

Thanks in advance,
 

jayh38

Well-Known Member
Mar 3, 2006
1,212
0
166
  • Uninstall Tomcat in WHM at cPanel >> Manage Plugins
  • Remove the /usr/local/jakarta package that contains the jsvc
  • Run the Easy Apache update to automatically install Tomcat along with the right jsvc
  • Install the servlets once again for the domain needing it

Thanks in advance,

Theres no reason for your outline not to work.
 

cPanelKenneth

cPanel Development
Staff member
Apr 7, 2006
4,607
79
458
cPanel Access Level
Root Administrator
EasyApache 3 will upgrade the Tomcat installed via the Plugin system. as long as what you modified are all in the 'default' locations, EasyApache 3 will update everything.
 

meeven

Well-Known Member
May 8, 2007
132
2
168
Thanks, jayh38 and cpanelkenneth.

Well, I don't know if this was a mistake, but I didn't remove the /usr/local/jakarta/ directory before doing the easy apache update. Now, when I click on 'Install Servlets' for a domain, WHM returns the following error:

Scanning httpd.conf...............................................................
Could not opendir /usr/local/jakarta/tomcat/lib: No such file or directory
Could not opendir /usr/local/jakarta/tomcat/lib: No such file or directory
Could not opendir /usr/local/jakarta/tomcat/lib: No such file or directory
Done: .jsp support installed for domain.com
But what's strange is this: At the root of the domain, there's now a file called jsptest.jsp and calling it up in the browser shows a page with the following:

Sample Application JSP Page
This is the output of a JSP page that is part of the Hello, World application. It displays several useful values from the requestwe are currently processing.
Request Method: GET
Servlet Path: /jsptest.jsp
Yet, when I go to 'Install Servlets' in WHM, I can't see the domain listed as having servlets installed. All I get is the UI for adding servlets. Previously, when I installed Tomcat through cPanel >> Manage Plugins and installed servlets, I would see that domain listed at the Install Servlets section.

Another odd thing. When I type in http://www.domain.com:8080/ for the domain for which I installed servlets through WHM, I get a directory listing of all files in the web root. I have already denied index listing for the domain's public_html, so I wonder why this should be showing up.

However, when I do the same for another domain for which I have NOT installed servlets, I get the Apache Tomcat page sure enough!

Very confused now:confused:

Thanks in advance for any insights.
 

appservermgr

Member
Feb 16, 2007
20
0
151
Another odd thing. When I type in http://www.domain.com:8080/ for the domain for which I installed servlets through WHM, I get a directory listing of all files in the web root. I have already denied index listing for the domain's public_html, so I wonder why this should be showing up.

However, when I do the same for another domain for which I have NOT installed servlets, I get the Apache Tomcat page sure enough!

In conf/web.xml verify that your listings entry looks like:

<servlet>
<servlet-name>default</servlet-name>
<servlet-class>org.apache.catalina.servlets.DefaultServlet</servlet-class>
<init-param>
<param-name>debug</param-name>
<param-value>0</param-value>
</init-param>
<init-param>
<param-name>listings</param-name>
<param-value>false</param-value>
</init-param>
<load-on-startup>1</load-on-startup>
</servlet>
 

cPanelKenneth

cPanel Development
Staff member
Apr 7, 2006
4,607
79
458
cPanel Access Level
Root Administrator
Thanks, jayh38 and cpanelkenneth.

Well, I don't know if this was a mistake, but I didn't remove the /usr/local/jakarta/ directory before doing the easy apache update. Now, when I click on 'Install Servlets' for a domain, WHM returns the following error:



But what's strange is this: At the root of the domain, there's now a file called jsptest.jsp and calling it up in the browser shows a page with the following:



Yet, when I go to 'Install Servlets' in WHM, I can't see the domain listed as having servlets installed. All I get is the UI for adding servlets. Previously, when I installed Tomcat through cPanel >> Manage Plugins and installed servlets, I would see that domain listed at the Install Servlets section.

Another odd thing. When I type in http://www.domain.com:8080/ for the domain for which I installed servlets through WHM, I get a directory listing of all files in the web root. I have already denied index listing for the domain's public_html, so I wonder why this should be showing up.

However, when I do the same for another domain for which I have NOT installed servlets, I get the Apache Tomcat page sure enough!

Very confused now:confused:

Thanks in advance for any insights.
If you would, please open a support ticket at https://tickets.cpanel.net/submit/ so we can determine what went wrong and prevent its repetition.

Thank you.
 

meeven

Well-Known Member
May 8, 2007
132
2
168
Thank you, everyone.

It turned out that the payment gateway didn't want Tomcat at all but just JDK 1.3 and above. So, my host installed JDK 1.4.2 for me and all is well at least for now.

Thanks once again.