ospf loopback
阿新 • • 發佈:2020-07-29
192.168.122.164節點
2: enp1s0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc fq_codel state UP group default qlen 1000 link/ether 52:54:00:73:55:cd brd ff:ff:ff:ff:ff:ff inet 192.168.122.164/24 brd 192.168.122.255 scope global enp1s0 valid_lft forever preferred_lft forever 3: lo1: <BROADCAST,NOARP,UP,LOWER_UP> mtu 1500qdisc noqueue state UNKNOWN group default qlen 1000 link/ether 02:03:d8:fd:a2:07 brd ff:ff:ff:ff:ff:ff inet 4.4.4.4/32 scope global lo1 valid_lft forever preferred_lft forever inet6 fe80::3:d8ff:fefd:a207/64 scope link valid_lft forever preferred_lft forever
ubuntu# show run Building configuration... Current configuration:! frr version 7.3.1 frr defaults traditional hostname ubuntu log file /var/log/frr/ospfd.log log syslog informational service integrated-vtysh-config ! debug ospf event debug ospf packet all ! router ospf ospf router-id 192.168.122.164 network 4.4.4.4/32 area 0 network 192.168.122.0/24 area 0 ! mpls ldp router-id 192.168.122.164 ! address-family ipv4 discovery transport-address 192.168.122.164 ! interface enp1s0 ! exit-address-family ! ! line vty ! end ubuntu#
192.168.122.198節點
root@ubuntu:/home/devuser# ip a 1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN group default qlen 1000 link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00 inet 127.0.0.1/8 scope host lo valid_lft forever preferred_lft forever inet6 ::1/128 scope host valid_lft forever preferred_lft forever 2: enp1s0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc fq_codel state UP group default qlen 1000 link/ether 52:54:00:e5:30:19 brd ff:ff:ff:ff:ff:ff inet 192.168.122.198/24 brd 192.168.122.255 scope global dynamic enp1s0 valid_lft 3356sec preferred_lft 3356sec inet6 fe80::5054:ff:fee5:3019/64 scope link valid_lft forever preferred_lft forever root@ubuntu:/home/devuser# vtysh Hello, this is FRRouting (version 7.3.1). Copyright 1996-2005 Kunihiro Ishiguro, et al. ubuntu# sh run Building configuration... Current configuration: ! frr version 7.3.1 frr defaults traditional hostname ubuntu log syslog informational service integrated-vtysh-config ! router ospf ospf router-id 192.168.122.198 network 192.168.122.0/24 area 0 ! mpls ldp router-id 192.168.122.198 ! address-family ipv4 discovery transport-address 192.168.122.198 ! interface enp1s0 ! exit-address-family ! ! line vty ! end ubuntu#
192.168.122.164節點
root@ubuntu:/home/devuser# ping 192.168.122.198 -I lo1 PING 192.168.122.198 (192.168.122.198) from 4.4.4.4 lo1: 56(84) bytes of data. ^C --- 192.168.122.198 ping statistics --- 4 packets transmitted, 0 received, 100% packet loss, time 3052ms root@ubuntu:/home/devuser#
root@ubuntu:/home/devuser# tcpdump -i enp1s0 icmp -env tcpdump: listening on enp1s0, link-type EN10MB (Ethernet), capture size 262144 bytes 12:15:42.688992 52:54:00:e5:30:19 > 52:54:00:73:55:cd, ethertype IPv4 (0x0800), length 98: (tos 0x0, ttl 64, id 6370, offset 0, flags [DF], proto ICMP (1), length 84) 192.168.122.198 > 4.4.4.4: ICMP echo request, id 1895, seq 6, length 64 12:15:42.689017 52:54:00:73:55:cd > 52:54:00:e5:30:19, ethertype IPv4 (0x0800), length 98: (tos 0x0, ttl 64, id 26095, offset 0, flags [none], proto ICMP (1), length 84) 4.4.4.4 > 192.168.122.198: ICMP echo reply, id 1895, seq 6, length 64 12:15:43.712940 52:54:00:e5:30:19 > 52:54:00:73:55:cd, ethertype IPv4 (0x0800), length 98: (tos 0x0, ttl 64, id 6451, offset 0, flags [DF], proto ICMP (1), length 84) 192.168.122.198 > 4.4.4.4: ICMP echo request, id 1895, seq 7, length 64 12:15:43.712966 52:54:00:73:55:cd > 52:54:00:e5:30:19, ethertype IPv4 (0x0800), length 98: (tos 0x0, ttl 64, id 26306, offset 0, flags [none], proto ICMP (1), length 84) 4.4.4.4 > 192.168.122.198: ICMP echo reply, id 1895, seq 7, length 64 12:15:44.736938 52:54:00:e5:30:19 > 52:54:00:73:55:cd, ethertype IPv4 (0x0800), length 98: (tos 0x0, ttl 64, id 6528, offset 0, flags [DF], proto ICMP (1), length 84) 192.168.122.198 > 4.4.4.4: ICMP echo request, id 1895, seq 8, length 64 12:15:44.736961 52:54:00:73:55:cd > 52:54:00:e5:30:19, ethertype IPv4 (0x0800), length 98: (tos 0x0, ttl 64, id 26478, offset 0, flags [none], proto ICMP (1), length 84) 4.4.4.4 > 192.168.122.198: ICMP echo reply, id 1895, seq 8, length 64 12:15:45.760874 52:54:00:e5:30:19 > 52:54:00:73:55:cd, ethertype IPv4 (0x0800), length 98: (tos 0x0, ttl 64, id 6537, offset 0, flags [DF], proto ICMP (1), length 84) 192.168.122.198 > 4.4.4.4: ICMP echo request, id 1895, seq 9, length 64 12:15:45.760892 52:54:00:73:55:cd > 52:54:00:e5:30:19, ethertype IPv4 (0x0800), length 98: (tos 0x0, ttl 64, id 26560, offset 0, flags [none], proto ICMP (1), length 84) 4.4.4.4 > 192.168.122.198: ICMP echo reply, id 1895, seq 9, length 64 12:15:46.784859 52:54:00:e5:30:19 > 52:54:00:73:55:cd, ethertype IPv4 (0x0800), length 98: (tos 0x0, ttl 64, id 6747, offset 0, flags [DF], proto ICMP (1), length 84) 192.168.122.198 > 4.4.4.4: ICMP echo request, id 1895, seq 10, length 64 12:15:46.784886 52:54:00:73:55:cd > 52:54:00:e5:30:19, ethertype IPv4 (0x0800), length 98: (tos 0x0, ttl 64, id 26651, offset 0, flags [none], proto ICMP (1), length 84) 4.4.4.4 > 192.168.122.198: ICMP echo reply, id 1895, seq 10, length 64 ^C 10 packets captured 10 packets received by filter 0 packets dropped by kernel
192.168.122.198節點
root@ubuntu:/home/devuser# ping 4.4.4.4 PING 4.4.4.4 (4.4.4.4) 56(84) bytes of data. 64 bytes from 4.4.4.4: icmp_seq=1 ttl=64 time=0.111 ms 64 bytes from 4.4.4.4: icmp_seq=2 ttl=64 time=0.102 ms 64 bytes from 4.4.4.4: icmp_seq=3 ttl=64 time=0.086 ms 64 bytes from 4.4.4.4: icmp_seq=4 ttl=64 time=0.100 ms 64 bytes from 4.4.4.4: icmp_seq=5 ttl=64 time=0.094 ms 64 bytes from 4.4.4.4: icmp_seq=6 ttl=64 time=0.110 ms 64 bytes from 4.4.4.4: icmp_seq=7 ttl=64 time=0.107 ms 64 bytes from 4.4.4.4: icmp_seq=8 ttl=64 time=0.098 ms 64 bytes from 4.4.4.4: icmp_seq=9 ttl=64 time=0.088 ms 64 bytes from 4.4.4.4: icmp_seq=10 ttl=64 time=0.108 ms 64 bytes from 4.4.4.4: icmp_seq=11 ttl=64 time=0.089 ms 64 bytes from 4.4.4.4: icmp_seq=12 ttl=64 time=0.092 ms ^C --- 4.4.4.4 ping statistics --- 12 packets transmitted, 12 received, 0% packet loss, time 11255ms rtt min/avg/max/mdev = 0.086/0.098/0.111/0.014 ms root@ubuntu:/home/devuser#