Help! local hosts name resolving does not work

Help! local hosts name resolving does not work

Post by Thomas F. Dresche » Sun, 05 Mar 2000 04:00:00



Hi there specialists,

I hope some of the network programmers can help me because i'm
fuddling around with this problem since two weeks.. (thats annoying
-almost like using WINDOZE- isn't it?!?!)

My SuSE 6.2 system doesn't want to resolve the local host names in
some cases.

Question: Why is the 'route' output different now (Kernel 2.2.10) from
Kernel 2.0.xx ?

1) # /sbin/route (Kernel 2.2)

Kernel IP routing table
Destination     Gateway         Genmask         Flags Metric Ref    
Use Iface
192.168.111.3   *               255.255.255.255 UH    0      0        
0 plip1
192.168.111.99  *               255.255.255.255 UH    0      0        
0 ippp0
loopback        *               255.0.0.0       U     0      0        
0 lo
default         192.168.111.99  0.0.0.0         UG    0      0        
0 ippp0

2) # /delix5.1/sbin/route (Kernel 2.0)

Kernel routing table
Destination     Gateway         Genmask         Flags MSS    Window
Use Iface
zeppo.drescher. *               255.255.255.255 UH    0      0        
0 plip1
groucho-isdn1   *               255.255.255.255 UH    0      0        
0 ippp0
loopback        *               255.0.0.0       U     0      0        
0 lo
default         groucho-isdn1   *               UG    0      0        
0 ippp0

As u see in 2) the /etc/hosts contents are correct. DNS has been shut
down (for now) so the /etc/host.conf contains:

order hosts
multi on

1st consequence/problem: also the names in hosts.allow are not
resolved - I can work around by putting in IP numbers  127.0.0.1,
192.168.111.1, ... - WHY ?

Quote:>Feb 24 03:31:35 groucho in.telnetd[1729]: warning: /etc/hosts.allow,
>line 8: can't verify hostname: gethostbyname(groucho.drescher.net)
>failed

2nd consequence when DNS is enabled: it always tries to dial out the
ippp0 to resolve the local hosts. Hey that costs money here in .de!
(How much has the responsible been payed by the phone companies since
i've seen that's a problem which bothers much ppl)  ;-(

So any comments and helpful hints are appreciated! Can i find a
solution by recompiling the kernel with a special option? I verified
that the second route output is consistent with the /proc/net/route
content (Strange: when i delete a route in 1) it disappears...but in
/proc/net/route it is still there, also 2) displays it)

Thanks in advance and kind regards
Thomas.

P.S.:

Another(?) problem is the following tcpdump output - but i think it
already has been answered by the networking newsgroup. (No more
comment)

# ping 192.168.111.4 (default -> ippp0)

truncated-ip - 1186 bytes missing!0.84.0.216 > 0.0.64.1: (frag

truncated-ip - 1186 bytes missing!0.84.0.218 > 0.0.64.1: (frag

truncated-ip - 1186 bytes missing!0.84.0.220 > 0.0.64.1: (frag

truncated-ip - 1186 bytes missing!0.84.0.222 > 0.0.64.1: (frag

truncated-ip - 16307 bytes missing!0.84.1.107 > 0.0.64.1: (frag

truncated-ip - 16307 bytes missing!0.84.1.113 > 0.0.64.1: (frag

truncated-ip - 16307 bytes missing!0.84.1.117 > 0.0.64.1: (frag

truncated-ip - 16307 bytes missing!0.84.1.121 > 0.0.64.1: (frag

truncated-ip - 16307 bytes missing!0.84.1.125 > 0.0.64.1: (frag

g

 
 
 

Help! local hosts name resolving does not work

Post by Thomas F. Dresche » Sun, 05 Mar 2000 04:00:00


Since i have no experience in the following...

Which service or port can i monitor to find out more about host
resolving? (How?)
(Is something new here in Kernel 2.2 which i don't know yet?)
How can i switch a debug mode on in order to debug a route lookup?

Thank you again.

 
 
 

Help! local hosts name resolving does not work

Post by Thomas F. Dresche » Fri, 10 Mar 2000 04:00:00


Hoi Juergen,

thanks to you, all checks of the checklist have been done (xth time).
Since i disabled the nsswitch, i tried again using your decent
nsswitch.conf file. Same as before.

So, having seen numerous help requests in the news groups to that
subject and referring to comp.os.linux.networking 'Address resolution
works only one way: IP-to-name, but not vice versa', there must be a
bug in the name resolution functionality. Here: names in hosts.allow
are not resolved, the /etc/hosts file is ignored. Same thing in the
'route' output (not using -n option!).

Well, so good so bad. I wonder which source files have to do with the
subject? (ip_forward.c ??)

Regards, Thomas.

Quote:>>>>>>>>>>>>>>>>>> Ursprngliche Nachricht <<<<<<<<<<<<<<<<<<


Heinzl) zum Thema Re: Help! local hosts name resolving does not work:



> >Hi there specialists,

> >I hope some of the network programmers can help me because i'm
> >fuddling around with this problem since two weeks.. (thats annoying
> >-almost like using WINDOZE- isn't it?!?!)
> Almost, not quite but almost.
> >My SuSE 6.2 system doesn't want to resolve the local host names in
> >some cases.

> >Question: Why is the 'route' output different now (Kernel 2.2.10)
from
> >Kernel 2.0.xx ?

> >1) # /sbin/route (Kernel 2.2)

> >Kernel IP routing table
> >Destination     Gateway         Genmask         Flags Metric Ref
> >Use Iface
> >192.168.111.3   *               255.255.255.255 UH    0      0
> [...]
> >2) # /delix5.1/sbin/route (Kernel 2.0)

> >Kernel routing table
> >Destination     Gateway         Genmask         Flags MSS    Window
> >Use Iface
> >zeppo.drescher. *               255.255.255.255 UH    0      0
> >0 plip1
> [...]
> route -V ... different versions, no /etc/networks and resolver cannot
> resolve on one machine but not the other.

> >As u see in 2) the /etc/hosts contents are correct. DNS has been shut
> >down (for now) so the /etc/host.conf contains:

> >order hosts
> >multi on

> >1st consequence/problem: also the names in hosts.allow are not
> >resolved - I can work around by putting in IP numbers  127.0.0.1,
> >192.168.111.1, ... - WHY ?
> >>Feb 24 03:31:35 groucho in.telnetd[1729]: warning: /etc/hosts.allow,
> >>line 8: can't verify hostname: gethostbyname(groucho.drescher.net)
> >>failed
> Yes, it should be ...
> order hosts,bind
> ... and for, not only, completeness you might need a decent ...
> /etc/nsswitch.conf:
> -------------------
> [ ... stuff ........ ]
> hosts:                files dns [NOTFOUND=return UNAVAIL=return]
> [ ... more stuff ... ]
> ... for instance. Here try /etc/hosts first, then dns and in both
> cases, not found or service not available, return.
> Make sure ...
> /etc/resolv.conf:
> -----------------
> domain                seg.v.org
> nameserver    192.168.21.1 192.168.21.2 192.168.21.3
> ... is okay too.
> >2nd consequence when DNS is enabled: it always tries to dial out the
> >ippp0 to resolve the local hosts. Hey that costs money here in .de!
> >(How much has the responsible been payed by the phone companies since
> >i've seen that's a problem which bothers much ppl)  ;-(
> By the way, /etc/hosts is world readable, isn't it ?
> >So any comments and helpful hints are appreciated! Can i find a
> >solution by recompiling the kernel with a special option? I verified
> >that the second route output is consistent with the /proc/net/route
> >content (Strange: when i delete a route in 1) it disappears...but in
> >/proc/net/route it is still there, also 2) displays it)
> No.
> [...]
> >Another(?) problem is the following tcpdump output - but i think it
> >already has been answered by the networking newsgroup. (No more
> >comment)

> ># ping 192.168.111.4 (default -> ippp0)

> >truncated-ip - 1186 bytes missing!0.84.0.216 > 0.0.64.1: (frag

> >truncated-ip - 1186 bytes missing!0.84.0.218 > 0.0.64.1: (frag

> >truncated-ip - 1186 bytes missing!0.84.0.220 > 0.0.64.1: (frag

> >truncated-ip - 1186 bytes missing!0.84.0.222 > 0.0.64.1: (frag

> >truncated-ip - 16307 bytes missing!0.84.1.107 > 0.0.64.1: (frag

> >truncated-ip - 16307 bytes missing!0.84.1.113 > 0.0.64.1: (frag

> >truncated-ip - 16307 bytes missing!0.84.1.117 > 0.0.64.1: (frag

> >truncated-ip - 16307 bytes missing!0.84.1.121 > 0.0.64.1: (frag

> >truncated-ip - 16307 bytes missing!0.84.1.125 > 0.0.64.1: (frag

> >g
> Off the cuff ... cannot tell.
> Cheers,
> Juergen
> --
> \ Real name     : Jrgen Heinzl                 \       no flames      
/


/
 
 
 

1. can't resolve local host name , help !

Hi guys,

Any help would be greatly appreciated.  I am not exactly a
beginner, but there are clearly still things I need to learn
about Linux.  I have read all the networking howtos, all the
man pages I could find, and the relevant parts of the
network administrators guide.

When I put a host name in the "/etc/hosts" file, I should be
able to look it up without going to the DNS server.  But
when I type the "host" command at the shell, it always goes
to the DNS, then says "host not found".  Here are the
contents of the pertinent files:

/etc/hosts
127.0.0.1 localhost.localdomain localhost loopback
192.168.0.2 spica.localdomain spica

/etc/HOSTNAME
spica

/etc/host.conf
order hosts, bind
multi on

/etc/resolv.conf
domain localdomain
search localdomain
nameserver 192.168.0.1

When I type:
host spica
I get the response "host not found".  But it is sitting
right there in the "hosts" file, just like the HOWTO says to
do it.

Are there any other files that are involved in resolving
host names?

Thanks,
Bert

2. Help me, Linux is dying on me!!

3. Help: DHCP works but Host Name Doesn't Resolve

4. Backup software for Solaris 2.5

5. Resolving Local Host Names

6. 2.4.20 + XFS patches + rmap15a + Ingo's 2.4.20-rc3 O(1) sched

7. Why does bad host name resolve back to local machine?

8. How to start over installing kde3

9. error starting httpd - local host name cannot be resolved

10. Q: local host name cannot be resolved ?!?

11. From netscape browser - resolve name of local site yahoo.com to local site on apache

12. Apache is not resolving host names in my log files...

13. host command not resolving names to addresses anymore