免费注册 查看新帖 |

Chinaunix

  平台 论坛 博客 文库
最近访问板块 发新帖
查看: 2554 | 回复: 6
打印 上一主题 下一主题

arplookup failed host is not on local network [复制链接]

论坛徽章:
0
跳转到指定楼层
1 [收藏(0)] [报告]
发表于 2003-05-30 00:10 |只看该作者 |倒序浏览
出错信息:     arplookup xxx_xxx_xxx_xxx failed host is not on local network

用arp命令可以双方都能显示对方的MAC地址,但却ping不到对方,dns等服务
只在本地有效。对方接收不了。

我不清楚这是什么问题?
有谁可以答复。

论坛徽章:
0
2 [报告]
发表于 2003-05-30 07:59 |只看该作者

arplookup failed host is not on local network

看看是否开了防火墙。

论坛徽章:
0
3 [报告]
发表于 2003-06-05 03:00 |只看该作者

arplookup failed host is not on local network

并非防火墙问题:防火墙是开放这些服务的,防火墙即使关闭问题依旧!

论坛徽章:
0
4 [报告]
发表于 2003-06-05 06:19 |只看该作者

arplookup failed host is not on local network

[quote]原帖由 "radnows"]并非防火墙问题:防火墙是开放这些服务的,防火墙即使关闭问题依旧![/quote 发表:
   

检查掩码和路由

论坛徽章:
0
5 [报告]
发表于 2003-06-06 15:43 |只看该作者

arplookup failed host is not on local network

这个我早已检查过,两个网络都有不同子网才会有问题;但同样的设置在linux下没问题;

论坛徽章:
0
6 [报告]
发表于 2003-06-06 16:40 |只看该作者

arplookup failed host is not on local network

[quote]原帖由 "radnows"]这个我早已检查过,两个网络都有不同子网才会有问题;但同样的设置在linux下没问题;[/quote 发表:
     


因为Linux 变态!!   

论坛徽章:
0
7 [报告]
发表于 2003-06-08 23:56 |只看该作者

arplookup failed host is not on local network

This is a netmask problem, but not really the one that other people
have described. This is how it usually works. Your troubled machine
above, "servername," receives an ARP who-has from another machine on
the LAN called "clientname." However, the IP address that clientname
gives as a source does not match up to any local networks that
servername knows about.

For example, say servername has an address of 192.0.2.10/25. The other
machine has 192.0.2.210/24. When servername gets an ARP (which is
broadcast so servername gets it fine),

  who-has 192.0.2.10 tell 192.0.2.210

It gets confused. 192.0.2.210 is not local (as far as it is concerned)
so it logs an error.

Note that this is not a harmless error. These two machine cannot talk
to each other.

The fix, of course, is to make sure all machines on the same LAN have
the same netmask.


===============================================

我們先看看這問題出在那兒:
ARP 在正常使用時是只在同一subnet中跑而已, 而且,  IP nodes只會對Destination
Protocol Address 是自己的Address之ARP作處理.

所以當Subnet 中每一部機器都正確地Configure, 且機器正確implement ARP protocol時,
every thing is all right....呵呵~

問題會產生的架構應為 一個router interface接兩(或以上)個subnet的情況:
(我用sniffer看, 再參考if_ether.c 歸納之):

    +--------+
---| Router |----------a.b.c.0/24
    |        |          a.b.e.0/24
    +--------+

一個router interface接兩個subnet:

  正常情況底下, a.b.c.? 要與 a.b.e.? 通訊是要透過ROUTER.
  這時候, 如果有一部a.b.e.x的mask是用/16而非/24, 那它要與a.b.c.y通訊時,
會直接送ARP Request給a.b.c.y而非ROUTER, a.b.c.y會回ARP Reply及檢
查本身的ARP table(要做reflesh, update等), 一檢查就發現a.b.e.x不在同一sunet,

    arplookup a.b.e.x failed: host is not on local network
就出來了, 呵~

解決方法:1.給a.b.e.x正確的subnet mask(治本), 如果a.b.e.x是別人家的,就.....
         2.我建議把這個message
           完全弄掉:

        /sys/netinet/if_ether.c

       arplookup(...) 之這一後:

        if (rt->;rt_flags & RTF_GATEWAY)
                why = "host is not on local network"
        else if ((rt->;rt_flags & RTF_LLINFO) == 0)
                why = "could not allocate llinfo"
        else if (rt->;rt_gateway->;sa_family != AF_LINK)
                why = "gateway route is not ours"
        改為:
        if (rt->;rt_flags & RTF_GATEWAY){
           // why = "host is not on local network"
           return 0;
        }
        else if ((rt->;rt_flags & RTF_LLINFO) == 0)
                why = "could not allocate llinfo"
        else if (rt->;rt_gateway->;sa_family != AF_LINK)
                why = "gateway route is not ours"

        這麼一來, 人人通用囉.....
您需要登录后才可以回帖 登录 | 注册

本版积分规则 发表回复

  

北京盛拓优讯信息技术有限公司. 版权所有 京ICP备16024965号-6 北京市公安局海淀分局网监中心备案编号:11010802020122 niuxiaotong@pcpop.com 17352615567
未成年举报专区
中国互联网协会会员  联系我们:huangweiwei@itpub.net
感谢所有关心和支持过ChinaUnix的朋友们 转载本站内容请注明原作者名及出处

清除 Cookies - ChinaUnix - Archiver - WAP - TOP