如何使用 fastethernet 连接两个 Juniper gns3?

网络工程 杜松 瞻博网络 GNSS3
2021-07-16 15:47:48

我需要使用 fastethernet 接口连接两个 Juniper 路由器。当我通过em0连接时,我可以通过ping检查它们之间的连接。但是当我尝试在两个路由器中设置 fe-0/0/0 时,我无法 ping 通它们。我看到这条消息:ping: sendto: No route to host如何解决这个问题?

我的第一个路由器配置是这样的:

fe-1/0/0 {
unit 0 {
    family inet {
        address 192.168.1.2/24;
    }
}
em1 {
description R1;
vlan-tagging;
unit 0 {
    vlan-id 10;
    family inet {
        address 192.168.10.1/30;
    }
}

第二个是这样的:

fe-1/0/0 {
unit 0 {
    family inet {
        address 192.168.1.1/24;
    }
}
em1 {
description R2;
vlan-tagging;
unit 0 {
    vlan-id 10;
    family inet {
        address 192.168.10.2/30;
    }
}

症状:

root> ping 192.168.10.2
PING 192.168.10.2 (192.168.10.2): 56 data bytes
64 bytes from 192.168.10.2: icmp_seq=0 ttl=64 time=16.168 ms
64 bytes from 192.168.10.2: icmp_seq=1 ttl=64 time=5.968 ms
64 bytes from 192.168.10.2: icmp_seq=2 ttl=64 time=3.244 ms
^Z
Suspended
root@% ping 192.168.1.2
PING 192.168.1.2 (192.168.1.2): 56 data bytes
ping: sendto: No route to host
ping: sendto: No route to host
1个回答

这些em接口是 Olive(Junos 模拟器)上唯一可用的接口。尽管 Junos 允许您配置其他接口,但它们不会显示,您分配给它们的前缀也不会安装在路由表中。

您可以轻松地自己检查:

在模拟 Juniper 上配置三个接口:

root> show configuration interfaces | display set 
set interfaces fe-0/0/0 unit 0 family inet address 10.10.10.1/30
set interfaces ge-0/0/1 unit 0 family inet address 10.10.99.1/30
set interfaces em0 unit 0 family inet address 192.168.99.1/30

root> 

检查您的接口 - (快速/千兆)以太网接口不显示:

root> show interfaces terse 
Interface               Admin Link Proto    Local                 Remote
cbp0                    up    up 
demux0                  up    up 
dsc                     up    up 
em0                     up    up 
em0.0                   up    up   inet     192.168.99.1/30 
em1                     up    up 
em2                     up    up 
em3                     up    up 
gre                     up    up 
<...>

您的路由表也是如此:

root> show route 

inet.0: 2 destinations, 2 routes (2 active, 0 holddown, 0 hidden)
+ = Active Route, - = Last Active, * = Both 
192.168.99.0/30    *[Direct/0] 00:12:13
                    > via em0.0
192.168.99.1/32    *[Local/0] 00:12:13
                      Local via em0.0

root>

请注意,这种行为(为不存在的接口创建配置的能力)模仿了“真实”瞻博网络路由器的行为(这是有道理的,因为 Olive 是一个模拟器):在现实生活中,您还可以准备并提交您的配置,例如在插入新线路卡之前。