So I've followed the list of steps on : .
When I try to run the startup script, I get this message:
$CATALINA_HOME/bin/startup.sh Using CATALINA_BASE: /usr/share/tomcat7 Using CATALINA_HOME: /usr/share/tomcat7 Using CATALINA_TMPDIR: /usr/share/tomcat7/temp Using JRE_HOME: /usr/lib/jvm/default-java Using CLASSPATH: /usr/share/tomcat7/bin/bootstrap.jar:/usr/share/tomcat7/bin/tomcat-juli.jar touch: cannot touch `/usr/share/tomcat7/logs/catalina.out': No such file or directory /usr/share/tomcat7/bin/catalina.sh: 389: /usr/share/tomcat7/bin/catalina.sh: cannot create /usr/share/tomcat7/logs/catalina.out: Directory nonexistent What am I supposed to do to fix this? And am I supposed to modify the CATALINA_BASE variable?
2 Answers
Your problem is that you cannot mix guides. Just revert the modifications to the ~/.bashrc file. With the first command you already have tomcat installed but without starting the webserver. Just run sudo service tomcat7 start then go to your web browser and type and done.

sudo lsof -i:8080 COMMAND PID USER FD TYPE DEVICE SIZE/OFF NODE NAME java 11399 tomcat7 44u IPv6 632616 0t0 TCP *:http-alt (LISTEN) 19You will need to create logs folder and catalina.out file under the folder that it is complaining for 'no such file or directory' and give chmod 766 catalina.out. After that run $CATALINA_HOME/bin/startup.sh again.