Unable to connect to server using hostname with telnet and browser
Linux - NetworkingThis forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Unable to connect to server using hostname with telnet and browser
Hi,
I have a strange problem, I'm not able to connect to a host lets say
this site (I cannot put in the hostname) with the hostname using telnet or a browser.
When I use telnet it tells my that it tries to connect to 1.0.0.0!
But ... I'm able to do a nslookup or ping to this host!
Once I have done that telnet and browser work.
I tried several 2.6 Linux distributions but none of them work.
If I install a 2.4 distro I don't have a problem.
Now to my hardwar setup I'm using a DSL router + an additional router (cause the DSL router has only 1 port) to connect 2 PCs.
I'm using DHCP, but setting a static IP still doesn't work.
Any ideas?
Thanks
Last edited by Schlumpf42; 10-13-2004 at 06:20 PM.
hmmm ... I don't think the telnet service has anything to do with the problem.
I don't want to telnet to my machine. Also I can telnet using IP (once I did a nslookup and figured it out).
Also I'm only using telnet as an example of application that has problems to resolve the hostname.
What I did was something like: telnet <hostname> 80
Well ... thanks for the reply, but that's is not my problem.
I cannot access any website with telnet or a browser if I don't use IP instead of hostnames. Adding all those hosts to my hosts file is obviously not an option.
Programs other than nslookup or ping cannot resolves hostnames from the dns server it seems.
If I try the following command: telnet www.linuxquestions.org 80
it says that it tries to connect to 1.0.0.0 which means that it resolves www.linuxquestion.org as ip address 1.0.0.0 which is very unlikely.
Thanks
Last edited by Schlumpf42; 10-13-2004 at 11:40 PM.
I tried that, that is not the problem. The problem is not that my machine cannot resolve hostnames at all.
If I do a nslookup or ping it will. It seems that only certain applications like telnet or Mozilla don't resolve correctly.
I tried that, that is not the problem. The problem is not that my machine cannot resolve hostnames at all.
If I do a nslookup or ping it will. It seems that only certain applications like telnet or Mozilla don't resolve correctly.
The solution is to clean the dnscache of the computer (ifconfig /flushdns (in windows)), and the browser ( turn off pre-fetch DNS ).
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.