Go Premium for a chance to win a PS4. Enter to Win


telnet to local ip not working

Posted on 2001-06-19
Medium Priority
Last Modified: 2008-02-01
I have two network cards installed. and  I can ping and telnet out on both interfaces.  

Other computers can ping both interfaces.  The problem is that telnetd and httpd are only responding on the interface.  When I try to telnet into, I get "Connection refused by remote host".  Same thing happens with http.  Also when I try to telnet to the local IP, I get the same thing and localhost dosn't answer telnet requests either.

I'm running Linux Redhat version 7.1 and there are no restrictions set in the firewall.
Question by:bnewton
LVL 40

Expert Comment

ID: 6209137
From the question it looks like this box is intended to function as a firewall/gateway using IPMASQ. Is it set up to use ipchains (the default on 7.1) or iptables? If you are using the default, what does "ipchains -L" and "ipchains -M" show?

Expert Comment

ID: 6211520
I am not sure But I think the IP doesn't blong to the same group so that why its refused.


Author Comment

ID: 6212572
I'm pretty much a Linux newbie so I used the default's and havn't really configured anything yet other then the drivers.  This is the outpuut to that command.

[root@localhost /sbin]# ./ipchains -L
Chain input (policy ACCEPT):
Chain forward (policy ACCEPT):
Chain output (policy ACCEPT):

[root@localhost /sbin]# ./ipchains -M -L
IP masquerading entries

Harwantgrewal, what do you mean by the IP doesn't belong to the same group?

Concerto Cloud for Software Providers & ISVs

Can Concerto Cloud Services help you focus on evolving your application offerings, while delivering the best cloud experience to your customers? From DevOps to revenue models and customer support, the answer is yes!

Learn how Concerto can help you.

LVL 40

Expert Comment

ID: 6215141
I may have made an improper assumption when I read the question. So let me see if I can clarify things.

From within the private network ( you can telnet to the gateway's inside interface (, but you can't telnet to it's outside ip ( from within the private network. And I'd expect that you can't telnet to the outside IP of the gateway from the Internet. From within the private network you should only be opening sessions to the inside IP of the box for security reasons. And to allow inbound connections to the gateway from the Internet I believe you'll need to set up a port forward for telnet that points the inbound telnet connection to the inside IP of the gateway.


Author Comment

ID: 6215304
No I'm only trying to telnet to the port on the subnet that I'm attached.  The most puzzeling thing to me is that I can't telnet to the local ip when I'm actually on the server console.  Ie. telnet dosn't work.
LVL 40

Expert Comment

ID: 6216966
Okay so you are saying that from a host on the network attached to the interface with the IP that you can telnet to Yet from a host on the network attached to the other interface you can't telnet to How about showing me the output of "ifconfig -a" and "netstat -rn", please.

Accepted Solution

rgirish earned 400 total points
ID: 6233729

To troubleshoot, lot of things are needed:

1. Did you add the 172.x.x.x interface card after the installation.
2. What does your hosts file look like? does it have an entry for localhost
3. Copy and Paste the xinetd.conf file (maybe the telnet daemon is configured to run on only that interface)
4. Copy and Paste fstab file (got to check if pseudo terminals are mounted)
5. Run ifconfig -a
6. run a traceroute (or tracert from a windows system) from any client on 172.x.x.x network to Copy and Paste the results.

With the help of these answers, we can troubleshoot the problem.


Author Comment

ID: 6240873
Hi Girish, Thanks in advance for your help.

1. Yes, the 172.x.x.x card was added after installation.  I activated the card using linuxconf, but have done nothing else.

[si@localhost si]$ cat /etc/hosts
# Do not remove the following line, or various programs
# that require network functionality will fail.          fwtest localhost.localdomain localhost

[si@localhost /etc]$ cat xinetd.conf
# Simple configuration file for xinetd
# Some defaults, and include /etc/xinetd.d/

     instances               = 60
        log_type                = SYSLOG authpriv
        log_on_success          = HOST PID
        log_on_failure          = HOST

includedir /etc/xinetd.d

4. [si@localhost /etc]$ cat fstab
LABEL=/                 /                       ext2    defaults        1 1
LABEL=/boot             /boot                   ext2    defaults        1 2
LABEL=/home             /home                   ext2    defaults        1 2
/dev/fd0                /mnt/floppy             auto    noauto,owner    0 0
LABEL=/usr              /usr                    ext2    defaults        1 2
LABEL=/var              /var                    ext2    defaults        1 2
none                    /proc                   proc    defaults        0 0
none                    /dev/pts                devpts  gid=5,mode=620  0 0
/dev/hde9               swap                    swap    defaults        0 0
/dev/cdrom              /mnt/cdrom              iso9660 noauto,owner,kudzu,ro 0 0


[si@localhost /sbin]$ ./ifconfig -a
eth0      Link encap:Ethernet  HWaddr 00:50:BA:1A:1D:93  
          inet addr:  Bcast:  Mask:
          RX packets:496 errors:0 dropped:0 overruns:0 frame:0
          TX packets:495 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:100
          Interrupt:3 Base address:0xa000

eth1      Link encap:Ethernet  HWaddr 00:48:54:6D:C4:76  
          inet addr:  Bcast:  Mask:
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:100
          Interrupt:10 Base address:0xc000

lo        Link encap:Local Loopback  
          inet addr:  Mask:
          UP LOOPBACK RUNNING  MTU:16436  Metric:1
          RX packets:8 errors:0 dropped:0 overruns:0 frame:0
          TX packets:8 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0


Type escape sequence to about.
Tracing the route to

  1 4 msec 0 msec 0 msec

Featured Post

Hire Technology Freelancers with Gigs

Work with freelancers specializing in everything from database administration to programming, who have proven themselves as experts in their field. Hire the best, collaborate easily, pay securely, and get projects done right.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

I have seen several blogs and forum entries elsewhere state that because NTFS volumes do not support linux ownership or permissions, they cannot be used for anonymous ftp upload through the vsftpd program.   IT can be done and here's how to get i…
Note: for this to work properly you need to use a Cross-Over network cable. 1. Connect both servers S1 and S2 on the second network slots respectively. Note that you can use the 1st slots but usually these would be occupied by the Service Provide…
If you're a developer or IT admin, you’re probably tasked with managing multiple websites, servers, applications, and levels of security on a daily basis. While this can be extremely time consuming, it can also be frustrating when systems aren't wor…
Want to learn how to record your desktop screen without having to use an outside camera. Click on this video and learn how to use the cool google extension called "Screencastify"! Step 1: Open a new google tab Step 2: Go to the left hand upper corn…
Suggested Courses

971 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question