Operating System - Linux
1753454 Members
6115 Online
108794 Solutions
New Discussion юеВ

Re: Cannot telnet to a port from another server

 
Yaboto
Super Advisor

Cannot telnet to a port from another server

I have installed an application that automatically assign, configure and use the ports 9500, 9501 and 9502.
Locally to the server I could enter the command and the reply would be successfull:
#telnet 172.25.6.13 9500
#telnet 172.25.6.13 9501
#telnet 172.25.6.13 9502

But when I enter those commands from another server, It doesn't work, even though I could successfully do simple telnet from any other server.

Please help !

15 REPLIES 15
Steven Schweda
Honored Contributor

Re: Cannot telnet to a port from another server

> I have installed an application [...]

Which "an application" is this?

> [...] the server [...]

Which kind of "the server" is this?

> [...] It doesn't work [...]

Which kind of "It doesn't work" is this?

As usual, showing actual commands with their
actual output can be more helpful than vague
descriptions and interpretations.

> [...] from another server [...]

How many firewalls are involved here?
Yaboto
Super Advisor

Re: Cannot telnet to a port from another server

Sorry, you are perfectly right. This was because I was working on a lot of things at a the same time.

The servers were all RHEL5 ( Red Hat Enterprise Linux version 5 )

There is no firewall involved.
John Guster
Trusted Contributor

Re: Cannot telnet to a port from another server

is the telnet service enabled on the server?
Steven E. Protter
Exalted Contributor

Re: Cannot telnet to a port from another server

Shalom,

In the server see if any app is actually listening on those ports.

netstat -an | grep 9500

repeat for other ports.

If something is listening, proceed to check network connectivity. If not, check and see about that application. It is is either not running or not running as you expect it to run.

SEP
Steven E Protter
Owner of ISN Corporation
http://isnamerica.com
http://hpuxconsulting.com
Sponsor: http://hpux.ws
Twitter: http://twitter.com/hpuxlinux
Founder http://newdatacloud.com
Yaboto
Super Advisor

Re: Cannot telnet to a port from another server

Thanks for your replies.

The telnet service is running.

Here is the output of netstat:

[root@rcbbkup ~]# netstat -an | grep 9500
tcp 0 0 :::9500 :::* LISTEN

[root@rcbbkup ~]# netstat -an | grep 9501
tcp 0 0 :::9501 :::* LISTEN

[root@rcbbkup ~]# netstat -an | grep 9502
tcp 0 0 :::9502 :::* LISTEN

[root@rcbbkup ~]# netstat -an | grep 9503
tcp 0 0 :::9503 :::* LISTEN

[root@rcbbkup ~]# netstat -an | grep 9505
tcp 0 0 :::9505 :::* LISTEN

tcp 2 0 ::ffff:10.7.2.108:9505 ::ffff:10.7.2.108:17569 CLOSE_WA
IT


Please help me interpret the output and Advice .


Steven Schweda
Honored Contributor

Re: Cannot telnet to a port from another server

> tcp 0 0 :::9500 :::* LISTEN
> [...]

Ok. Someone is listening at that (and the
other) ports. (Which was evident from the
fact that you could use Telnet to connect to
these ports from the local system.)

> > [...] It doesn't work [...]
>
> Which kind of "It doesn't work" is this?

Still wondering...

> [...] I could successfully do simple telnet
> from any other server.

> There is no firewall involved.

Those two statements seem to disagree.
Tim Nelson
Honored Contributor

Re: Cannot telnet to a port from another server

service iptables stop

try again

If it works then you need to either turn off the iptables or edit to include these port rules.

1 - this is all assuming that you have network connectivity from serverA to serverB

2 - this assumes that you can connect to these ports locally

3 - this assumes that you should not expect any input/output from these ports when using telnet ( simply a connection that would mostlikely just sit there returning nothing ).

done assuming ;)



Yaboto
Super Advisor

Re: Cannot telnet to a port from another server

Thanks very much for your replies !

The banking application is installed on server A. The application is working perfectly and locally to server A, I could TELNET to those ports mentioned above.

From the remote server B, I could TELNET server A, BUT from server B, I could not TELNET server A at the PORTS mentioned above.

There is no firewall between server A and server B, except that server A may be having in-built firewall or security features I don't know. The OS is RHEL5 Red Hat Enterprise Linux 5.

Please what are the settings I should check. I am very new to Linux.

Please Advice.
John Guster
Trusted Contributor

Re: Cannot telnet to a port from another server

what is the telnet entry in /etc/services?