Link to home
Start Free TrialLog in
Avatar of fyness
fyness

asked on

SSL with Tomcat 5 and apache axis


Hi,

Im trying to configure tomcat to use SSL and I've followed the steps in the how-to guide and i cant get it to work.  I changed the server.xml to allow for SSL using the following

<Connector className="org.apache.catalina.connector.http.HttpConnector"
               port="8443" minProcessors="5" maxProcessors="75"
               enableLookups="true" acceptCount="10" debug="0"
                     scheme="https" secure="true">
      <Factory className="org.apache.catalina.net.SSLServerSocketFactory"
               keystoreFile="c:\jakarta-tomcat-5.0.27\webapps\WSOverSSL\axis\server.keystore"
               keystorePass="changeit"
               clientAuth="false" protocol="TLS"/>
    </Connector>

But tomcat wont start when I put in the Factory element. I had initally used tomcat-jwsdp-1.4, would this have over riden anything or something. If anyone can help would much appricate it!

Thanks,
Suzy
Avatar of TimYates
TimYates
Flag of United Kingdom of Great Britain and Northern Ireland image

what exception do you get?
Avatar of fyness
fyness

ASKER



when tomcat doesnt start im not getting an exception that i can see, its not in the logs. if i take the factory element out its still doesnt run. I get the following when i run startup.bat

C:\jakarta-tomcat-5.0.27\bin>startup.bat
Using CATALINA_BASE:   C:\jakarta-tomcat-5.0.27
Using CATALINA_HOME:   C:\jakarta-tomcat-5.0.27
Using CATALINA_TMPDIR: C:\jakarta-tomcat-5.0.27\temp
Using JAVA_HOME:       C:\j2sdk1.4.2_02
What does it display if you type:

catalina.bat start

instead of startup.bat

?
Sory, I meant:

catalina.bat run
Avatar of fyness

ASKER

its not finding the

Catalina.start using conf/server.xml: java.lang.ClassNotFoundException: org.apac
he.catalina.connector.http.HttpConnector
java.lang.ClassNotFoundException: org.apache.catalina.connector.http.HttpConnector

i took it out be still doesnt work.
Avatar of fyness

ASKER

when i take the two classnames out i get the following error

SEVERE: Null component Catalina:type=protocolHandler,className=null
27-Aug-2004 13:13:18 org.apache.catalina.startup.Catalina start
SEVERE: Catalina.start:
LifecycleException:  Protocol handler start failed: java.lang.NullPointerExcept
on
        at org.apache.coyote.tomcat5.CoyoteConnector.start(CoyoteConnector.java
1529)
        at org.apache.catalina.core.StandardService.start(StandardService.java:
89)
        at org.apache.catalina.core.StandardServer.start(StandardServer.java:23
3)
        at org.apache.catalina.startup.Catalina.start(Catalina.java:556)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl
java:39)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcce
sorImpl.java:25)
        at java.lang.reflect.Method.invoke(Method.java:324)
        at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:284)
        at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:422)
27-Aug-2004 13:13:18 org.apache.catalina.startup.Catalina start
INFO: Server startup in 6516 ms
Where did you install Tomcat? Does the path contain any special characters (space, "+", "-" etc)?
Avatar of fyness

ASKER

its in stalled in jakarka-tomcat-5.0.27 on my c drive, the path is just jakarka-tomcat-5.0.27/bin
Did you try to run it before you installed the SSL? It might be that there was a problem with the installation. You might need to reinstall Tomcat.
Avatar of fyness

ASKER

works fine without the ssl connection been opened i.e. removing the tags from the server.xml
Can you check Tomcat's jar files to see in which jar file the HttpConnector is? And also can you tell us the location of this class?
Avatar of fyness

ASKER

I cant find the jar's actually im having trouble getting my localhost page up now. Im also getting this error

Catalina.start using conf/server.xml: java.lang.ClassNotFoundException: org.apac
he.tomcat.service.PoolTcpConnector
java.lang.ClassNotFoundException: org.apache.tomcat.service.PoolTcpConnector
        at org.apache.commons.digester.Digester.createSAXException(Digester.java
:2540)
        at org.apache.commons.digester.Digester.createSAXException(Digester.java
:2566)
        at org.apache.commons.digester.Digester.startElement(Digester.java:1276)

        at org.apache.catalina.util.CatalinaDigester.startElement(CatalinaDigest
er.java:65)
        at org.apache.xerces.parsers.AbstractSAXParser.startElement(Unknown Sour
ce)
        at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanStartElemen
t(Unknown Source)
        at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl$FragmentContent
Dispatcher.dispatch(Unknown Source)
        at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(Un
known Source)
        at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
        at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
        at org.apache.xerces.parsers.XMLParser.parse(Unknown Source)
        at org.apache.xerces.parsers.AbstractSAXParser.parse(Unknown Source)
        at org.apache.commons.digester.Digester.parse(Digester.java:1548)
        at org.apache.catalina.startup.Catalina.load(Catalina.java:489)
        at org.apache.catalina.startup.Catalina.start(Catalina.java:548)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.
java:39)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
sorImpl.java:25)
        at java.lang.reflect.Method.invoke(Method.java:324)
        at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:284)
        at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:422)
27-Aug-2004 16:25:03 org.apache.catalina.startup.Catalina start
INFO: Server startup in 0 ms
java.lang.reflect.InvocationTargetException
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.
java:39)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
sorImpl.java:25)
        at java.lang.reflect.Method.invoke(Method.java:324)
        at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:284)
        at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:422)
Caused by: java.lang.NullPointerException
        at org.apache.catalina.startup.Catalina.await(Catalina.java:619)
        at org.apache.catalina.startup.Catalina.start(Catalina.java:579)
        ... 6 more

ANy ideas what the problem may be?

thanks
sue
Is that when you are running Tomcat or when you try to access your page?
Avatar of fyness

ASKER

when i start up i think, i just tried starting up again and its not working and getting the same error as above
ASKER CERTIFIED SOLUTION
Avatar of girionis
girionis
Flag of Greece image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
I believe that a re-installation of Tomcat would have solved the problem.
Avatar of fyness

ASKER

I had to export classpaths in bashrc to get it working

You can have the points though

THanks for you help