LinuxQuestions.org
Share your knowledge at the LQ Wiki.
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 12-08-2009, 03:51 AM   #1
thomas2004ch
Member
 
Registered: Aug 2009
Posts: 537

Rep: Reputation: 32
How can I test if the port by server machine is reachable or not?


I have two machines, one used as client and the other as server. I want to check if the port 7080 on server reachable from the client machine.

How can I do that? Using telnet?
 
Old 12-08-2009, 03:54 AM   #2
linuxlover.chaitanya
Senior Member
 
Registered: Apr 2008
Location: Nagpur, India
Distribution: Cent OS 5/6, Ubuntu Server 10.04
Posts: 4,629

Rep: Reputation: Disabled
You can first try and ping the server from client to confirm the network availability. And to test if the server is accepting connections you can just telnet to server on specific port like

telnet <server ip> <port>


In your case

telnet <server ip> 7080
 
Old 12-08-2009, 04:04 AM   #3
thomas2004ch
Member
 
Registered: Aug 2009
Posts: 537

Original Poster
Rep: Reputation: 32
I fid the answer now.
 
Old 12-08-2009, 04:05 AM   #4
thomas2004ch
Member
 
Registered: Aug 2009
Posts: 537

Original Poster
Rep: Reputation: 32
Quote:
Originally Posted by linuxlover.chaitanya View Post
You can first try and ping the server from client to confirm the network availability. And to test if the server is accepting connections you can just telnet to server on specific port like

telnet <server ip> <port>


In your case

telnet <server ip> 7080

Many thanks.
 
Old 12-08-2009, 04:20 AM   #5
thomas2004ch
Member
 
Registered: Aug 2009
Posts: 537

Original Poster
Rep: Reputation: 32
Quote:
Originally Posted by linuxlover.chaitanya View Post
You can first try and ping the server from client to confirm the network availability. And to test if the server is accepting connections you can just telnet to server on specific port like

telnet <server ip> <port>


In your case

telnet <server ip> 7080
How can I exit the telnet session and come back to the bash-prompt?
 
Old 12-08-2009, 05:14 AM   #6
Lee_Ball
Member
 
Registered: Jul 2005
Location: Manchester (UK)
Distribution: Fedora CentOS
Posts: 132

Rep: Reputation: 18
Quote:
Originally Posted by thomas2004ch View Post
How can I exit the telnet session and come back to the bash-prompt?
Code:
Escape character is '^]'.
CTRL+]

If you're at a telnet> screen just type quit.
 
Old 12-08-2009, 05:07 PM   #7
jefro
Moderator
 
Registered: Mar 2008
Posts: 17,188

Rep: Reputation: 2562Reputation: 2562Reputation: 2562Reputation: 2562Reputation: 2562Reputation: 2562Reputation: 2562Reputation: 2562Reputation: 2562Reputation: 2562Reputation: 2562
at the telnet prompt type help.
 
Old 12-09-2009, 02:17 AM   #8
thomas2004ch
Member
 
Registered: Aug 2009
Posts: 537

Original Poster
Rep: Reputation: 32
After the server connected I got followings.
Code:
[vger1@s001ap26-acct ~]$ telnet 130.144.163.128 7080
Trying 130.144.163.128...
Connected to 130.144.163.128 (130.144.163.128).
Escape character is '^]'.
I try Ctrl + ] and quit but it doesn't work.
 
Old 12-10-2009, 12:30 AM   #9
linuxlover.chaitanya
Senior Member
 
Registered: Apr 2008
Location: Nagpur, India
Distribution: Cent OS 5/6, Ubuntu Server 10.04
Posts: 4,629

Rep: Reputation: Disabled
Once at telnet prompt, type quit and then press enter key
 
Old 12-10-2009, 02:03 AM   #10
chrism01
LQ Guru
 
Registered: Aug 2004
Location: Sydney
Distribution: Centos 6.9, Centos 7.3
Posts: 17,417

Rep: Reputation: 2397Reputation: 2397Reputation: 2397Reputation: 2397Reputation: 2397Reputation: 2397Reputation: 2397Reputation: 2397Reputation: 2397Reputation: 2397Reputation: 2397
I usually find Ctrl-C works ...
 
Old 12-10-2009, 07:30 AM   #11
Lee_Ball
Member
 
Registered: Jul 2005
Location: Manchester (UK)
Distribution: Fedora CentOS
Posts: 132

Rep: Reputation: 18
Quote:
Originally Posted by chrism01 View Post
I usually find Ctrl-C works ...
Not really. You have to press Ctrl+C then press enter to crash the session.
 
Old 12-10-2009, 07:33 AM   #12
linuxlover.chaitanya
Senior Member
 
Registered: Apr 2008
Location: Nagpur, India
Distribution: Cent OS 5/6, Ubuntu Server 10.04
Posts: 4,629

Rep: Reputation: Disabled
For me neither are working. I need to end the session be typing quit.
 
Old 12-10-2009, 07:34 AM   #13
Lee_Ball
Member
 
Registered: Jul 2005
Location: Manchester (UK)
Distribution: Fedora CentOS
Posts: 132

Rep: Reputation: 18
Quote:
Originally Posted by thomas2004ch View Post
After the server connected I got followings.
Code:
[vger1@s001ap26-acct ~]$ telnet 130.144.163.128 7080
Trying 130.144.163.128...
Connected to 130.144.163.128 (130.144.163.128).
Escape character is '^]'.
I try Ctrl + ] and quit but it doesn't work.

The whole step would be:

Press and hold CTRL
Press ] then release all keys
Press Enter

That should take you back to telnet>

Type quit
Press Enter
 
  


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
How Can I test SSL with Single apache Server Machine? your_shadow03 Linux - Newbie 1 10-26-2009 07:40 PM
Is there any way I can test a port on a remote machine to see whether its open? neocookie Linux - Networking 3 05-09-2007 06:13 PM
WARNING : Your 16150 port is not reachable CrashedAgain Linux - Networking 2 09-23-2006 11:10 AM
apache server not reachable from out of lan huntermix *BSD 6 08-04-2006 03:40 PM
Samba Server Not Reachable from WinNTClient joelin Linux - Networking 9 01-15-2004 07:24 AM

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

All times are GMT -5. The time now is 01:19 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
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration