LinuxQuestions.org
Help answer threads with 0 replies.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 02-12-2014, 03:21 PM   #1
Whatif
Member
 
Registered: Nov 2010
Distribution: VectorLinux
Posts: 87

Rep: Reputation: 0
Tomcat server not found


Hi,

I installed CentOS 6.5 to learn servlets and jsp. When I tried to access localhost:8080, I got server not found. I did the following:

su
service tomcat6 status
tomcat is stopped
service tomcat6 start
starting tomcat6: [OK]
service tomcat6 status
tomcat is running [OK]

I tried again, same error. What can I do to get it to work?
 
Old 02-12-2014, 04:08 PM   #2
MensaWater
LQ Guru
 
Registered: May 2005
Location: Atlanta Georgia USA
Distribution: Redhat (RHEL), CentOS, Fedora, CoreOS, Debian, FreeBSD, HP-UX, Solaris, SCO
Posts: 7,831
Blog Entries: 15

Rep: Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669
Default port for web service is 80 rather than 8080. (for https it is 443).

So first thing is to see if you have a port LISTENing on port 8080:

lsof -i :8080

If anything is LISTENing or attached you should see there. You'd want to verify your tomcat process was LISTENing there.

Compare that to what you see if you run "lsof -i :80".

Are you running httpd?

You might also want to verify you're allowing the ports in your local firewall (iptables) the server.
 
Old 02-12-2014, 04:43 PM   #3
Whatif
Member
 
Registered: Nov 2010
Distribution: VectorLinux
Posts: 87

Original Poster
Rep: Reputation: 0
Thank you very much for taking the time to help me!

lsof -i :8080
lsof -i :80

got no output from the above commands. Then,

su
service tomcat6 status
tomcat is stopped [OK]
service tomcat6 start
starting tomcat6: [OK]
service tomcat6 status
tomcat is running [OK]
lsof -i :8080

COMMAND PID USER FD TYPE DEVICE SIZE/OFF NODE NAME
java 2111 tomcat 37u IPv6 19983 0t0 TCP *:webcache(LISTEN)

service httpd status
httpd is stopped [OK]
service httpd start
starting httpd : [OK]
service httpd status
httpd is running [OK]
lsof -i :80

COMMAND PID USER FD TYPE DEVICE SIZE/OFF NODE NAME
httpd 2187 root 5u IPv6 20109 0t0 TCP *:http(LISTEN)
httpd 2189 apache 5u IPv6 20109 0t0 TCP *:http(LISTEN)
httpd 2190 apache 5u IPv6 20109 0t0 TCP *:http(LISTEN)
httpd 2191 apache 5u IPv6 20109 0t0 TCP *:http(LISTEN)
httpd 2192 apache 5u IPv6 20109 0t0 TCP *:http(LISTEN)
httpd 2193 apache 5u IPv6 20109 0t0 TCP *:http(LISTEN)
httpd 2194 apache 5u IPv6 20109 0t0 TCP *:http(LISTEN)
httpd 2195 apache 5u IPv6 20109 0t0 TCP *:http(LISTEN)
httpd 2196 apache 5u IPv6 20109 0t0 TCP *:http(LISTEN)


I then started firefox, type localhostand the Apache 2 Test Page Powered by CentOS displayed. Tried localhost:8080, got a blank white page.

What can I try next to get it to work?
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
tomcat 7 server not found Whatif Linux - Newbie 6 12-15-2012 10:18 AM
how to start mysql server & apache server at startup and then tomcat at last at boot sanjay87 Linux - Server 5 06-16-2012 08:19 AM
How to make Tomcat 4.0.1 and Tomcat 5.0.28 coexist in one server? g18397 Linux - Software 0 05-16-2006 03:16 AM
URGENT!!! (apxs not found) Integrating Apache & Tomcat on RedHatLinux AS 4 amitkanodia Linux - General 5 12-01-2005 10:43 AM
worket not found error on tomcat/apahce mattg Linux - Software 1 11-14-2003 09:04 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 01:23 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration