I backup and installed the 7.0.28 of Tomcat.
I used the setup as follows:

sudo ln -s /usr/local/apache-tomcat-7.0.28/ /Library/Tomcat
sudo chown -R "myusername" /Library/Tomcat
issued command export Catalina_HOME=/Library/Tomcat

upon issue of : /Library/Tomcat/bin/startup.sh
get the following output:

Using CATALINA_BASE:   /Library/Tomcat
Using CATALINA_HOME:   /Library/Tomcat
Using CATALINA_TMPDIR: /Library/Tomcat/temp
Using JRE_HOME:        
/System/Library/Frameworks/JavaVM.framework/Versions/CurrentJDK/Home
Using CLASSPATH:       
/Library/Tomcat/bin/bootstrap.jar:/Library/Tomcat/bin/tomcat-juli.jar

OutPut of Catalina.out:

Exception in thread "main" java.lang.NoClassDefFoundError: 
org/apache/catalina/startup/Bootstrap
Caused by: java.lang.ClassNotFoundException: 
org.apache.catalina.startup.Bootstrap
        at java.net.URLClassLoader$1.run(URLClassLoader.java:202)
        at java.security.AccessController.doPrivileged(Native Method)
        at java.net.URLClassLoader.findClass(URLClassLoader.java:190)
        at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
        at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301)
        at java.lang.ClassLoader.loadClass(ClassLoader.java:247)

Non comment server.xml :

server.xml :

<?xml version='1.0' encoding='utf-8'?>

<Server port="8005" shutdown="SHUTDOWN">
  
  <Listener className="org.apache.catalina.core.AprLifecycleListener" 
SSLEngine="on" />
  <Listener className="org.apache.catalina.core.JasperListener" />
  <Listener 
className="org.apache.catalina.core.JreMemoryLeakPreventionListener" />
  <Listener 
className="org.apache.catalina.mbeans.GlobalResourcesLifecycleListener" />
  <Listener 
className="org.apache.catalina.core.ThreadLocalLeakPreventionListener" />

  <GlobalNamingResources>
    
    <Resource name="UserDatabase" auth="Container"
              type="org.apache.catalina.UserDatabase"
              description="User database that can be updated and saved"
              factory="org.apache.catalina.users.MemoryUserDatabaseFactory"
              pathname="conf/tomcat-users.xml" />
  </GlobalNamingResources>

  
  <Service name="Catalina">

    
    <Connector port="8080" protocol="HTTP/1.1"
               connectionTimeout="20000"
               redirectPort="8443" />
    
    <Connector port="8009" protocol="AJP/1.3" redirectPort="8443" />

    <Engine name="Catalina" defaultHost="localhost">

      <Realm className="org.apache.catalina.realm.LockOutRealm">
        
        <Realm className="org.apache.catalina.realm.UserDatabaseRealm"
               resourceName="UserDatabase"/>
      </Realm>

      <Host name="localhost"  appBase="webapps"
            unpackWARs="true" autoDeploy="true">

       
        <Valve className="org.apache.catalina.valves.AccessLogValve" 
directory="logs"
               prefix="localhost_access_log." suffix=".txt"
               pattern="%h %l %u %t &quot;%r&quot; %s %b" />

      </Host>
    </Engine>
  </Service>
</Server>

So I'm still unable to access http://localhost:8080

Question:

Are there main "set" environment variables that I can set within
my .bash_profile once I get Tomcat started that will fulfill environment needs 
in the future?

I've set up Tomcat years ago on older OSX versions and had no problems.
So it "may be "easy" to you, but there is something I'm missing.

Thank you,

Samuel.


On Jun 19, 2012, at 8:40 AM, Christopher Schultz wrote:

> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
> 
> Samuel,
> 
> On 6/18/12 11:34 PM, Samuel V Green III wrote:
>> I followed directions for install and config here: 
>> http://wolfpaulus.com/journal/mac/tomcat7
> 
> I use Tomcat 7.0.27 on my Mac every day. I'm not sure why you needed
> an "installation guide" when the instructions are so darned simple:
> 
> 1. Download tarball
> 2. Un-tar tarball
> 
> Done.
> 
> Oh, you want to actually /run/ it? That's easy:
> 
> $ bin/startup.sh
> 
> You don't need any sudo access or anything like that.
> 
>> and here:
>> 
>> http://www.janhellevik.no/blog/?p=323
>> 
>> When attempting to start Tomcat I get the following error…. ( I've
>> googled the _ _ it out of this error and can't find a fix.
>> 
>> sudo $CATALINA_HOME/bin/catalina.sh run
> 
> You really shouldn't run Tomcat as root.
> 
>> Password: Using CATALINA_BASE:   /Library/Tomcat Using
>> CATALINA_HOME:   /Library/Tomcat Using CATALINA_TMPDIR:
>> /Library/Tomcat/temp Using JRE_HOME:
>> /System/Library/Frameworks/JavaVM.framework/Versions/CurrentJDK/Home
>> 
>> 
> Using CLASSPATH:
> /Library/Tomcat/bin/bootstrap.jar:/Library/Tomcat/bin/tomcat-juli.jar
>> Exception in thread "main" java.lang.NoClassDefFoundError:
>> org/apache/catalina/startup/Bootstrap Caused by:
>> java.lang.ClassNotFoundException:
>> org.apache.catalina.startup.Bootstrap at
>> java.net.URLClassLoader$1.run(URLClassLoader.java:202) at
>> java.security.AccessController.doPrivileged(Native Method) at
>> java.net.URLClassLoader.findClass(URLClassLoader.java:190) at
>> java.lang.ClassLoader.loadClass(ClassLoader.java:306) at
>> sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301) at
>> java.lang.ClassLoader.loadClass(ClassLoader.java:247)
>> 
>> When I attempt start this way:
>> 
>> sudo /Library/Tomcat/bin/startup.sh Password: Using CATALINA_BASE:
>> /Library/Tomcat Using CATALINA_HOME:   /Library/Tomcat Using
>> CATALINA_TMPDIR: /Library/Tomcat/temp Using JRE_HOME:
>> /System/Library/Frameworks/JavaVM.framework/Versions/CurrentJDK/Home
>> 
>> 
> Using CLASSPATH:
> /Library/Tomcat/bin/bootstrap.jar:/Library/Tomcat/bin/tomcat-juli.jar
>> 
>> I get no errors, but http://localhost:8080 does not connect.
> 
> That's odd that explicitly-specifying the path to Tomcat instead of
> using the CATALINA_HOME environment variable changes anything.
> 
> Do this:
> 
> 1. Stop Tomcat (use 'ps' or 'Activity Monitor' to make sure it's dead)
> 2. Remove all log files from $CATALINA_HOME/logs/*
> 3. Start Tomcat using "startup.sh"
> 4. Post-back the entire contents of $CATALINA_HOME/logs/catalina.out
> 5. Also post the non-comment portions of your conf/server.xml file
> 
> - -chris
> -----BEGIN PGP SIGNATURE-----
> Version: GnuPG/MacGPG2 v2.0.17 (Darwin)
> Comment: GPGTools - http://gpgtools.org
> Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/
> 
> iEYEARECAAYFAk/gnYQACgkQ9CaO5/Lv0PC6IwCgmAkO/IZaejjEx8Rg4CdG8557
> zt8AoITGZrnbIp/+KMMOyKnR2dosiS+C
> =m/X+
> -----END PGP SIGNATURE-----
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
> For additional commands, e-mail: users-h...@tomcat.apache.org
> 


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org

Reply via email to