In order to Install Apache Tomcat version 8.x.x (Supports Servlet 3.1 specifications) on your Mac OS X (macOS) running Yosemite OS 10.10.x you must have Java version 7 or later installed on your Mac.
How to check your Java version installed :- Go to Terminal
- Run command: java -version
- If it is less than 1.8, download and install java8:
- http://www.oracle.com/technetwork/java/javase/downloads/jdk8-downloads-2133151.html
bash-3.2$ java -version
java version "1.8.0_25"
Java(TM) SE Runtime Environment (build 1.8.0_25-b17)
Java HotSpot(TM) 64-Bit Server VM (build 25.25-b02, mixed mode)
bash-3.2$
Installing Tomcat 8.0.22
- Download the latest tomcat binary from : https://tomcat.apache.org/download-80.cgi (apache-tomcat-8.0.22.tar.gz)
- Extract the files to any directory you prefer.
- Open Terminal and move to bin directory location where you have extracted apache binaries.
- Run the command ./startup.sh to start the apache server.
- Now open any browser and open address: http://localhost:8080, you must see the should see "If you're seeing this, you've successfully installed Tomcat. Congratulations!" page.
bash-3.2$ ./startup.sh
Using CATALINA_BASE: /Users/c2c/Setups/apache-tomcat-8.0.22
Using CATALINA_HOME: /Users/c2c/Setups/apache-tomcat-8.0.22
Using CATALINA_TMPDIR: /Users/c2c/Setups/apache-tomcat-8.0.22/temp
Using JRE_HOME: /Library/Java/JavaVirtualMachines/jdk1.8.0_25.jdk/Contents/Home
Using CLASSPATH: /Users/c2c/Setups/apache-tomcat-8.0.22/bin/bootstrap.jar:/Users/c2c/Setups/apache-tomcat-8.0.22/bin/tomcat-juli.jar
Tomcat started.
bash-3.2$
bash-3.2$ ./shutdown.sh
Using CATALINA_BASE: /Users/c2c/Setups/apache-tomcat-8.0.22
Using CATALINA_HOME: /Users/c2c/Setups/apache-tomcat-8.0.22
Using CATALINA_TMPDIR: /Users/c2c/Setups/apache-tomcat-8.0.22/temp
Using JRE_HOME: /Library/Java/JavaVirtualMachines/jdk1.8.0_25.jdk/Contents/Home
Using CLASSPATH: /Users/c2c/Setups/apache-tomcat-8.0.22/bin/bootstrap.jar:/Users/c2c/Setups/apache-tomcat-8.0.22/bin/tomcat-juli.jar
bash-3.2$
- Servlet Spec: 3.1
- JSP Spec: 2.3
- EL Spec: 3.0
- WebSocket Spec: 1.1
- Java Support: 7 or later
Provide Feedback For This Article
We take your feedback seriously and use it to improve our content. Thank you for helping us serve you better!
😊 Thanks for your time, your feedback has been registered!
Comments & Discussion
Facing issues? Have questions? Post them here! We're happy to help!