享受我的英语。我正在使用 Ipv6 在 Mininet 中运行图像拓扑,为此我通过 ospf6d 使用 Quagga。但是我无法获得路由,我已经完成了正确的脚本,但我觉得它是配置的一部分,使其无法正常工作。
r1.cmd('ifconfig r1-eth1 inet6 add 2001:1::12/64')
r2.cmd('ifconfig r2-eth1 inet6 add 2001:1::21/64')
r1.cmd('ifconfig r1-eth2 inet6 add 1::10/64')
h1.cmd('ifconfig h1-eth0 inet6 add 1::1/96')
h1.cmd('route -6 add default gw 1::10 dev h1-eth0') # add ipv6 default route for h1
r2.cmd('ifconfig r2-eth2 inet6 add 2::20/64')
h2.cmd('ifconfig h2-eth0 inet6 add 2::2/64')
h2.cmd('route -6 add default gw 2::20 dev h2-eth0') # add ipv6 default route for h2
info('starting zebra and ospfd service:\n')
r1.cmd('zebra -f /usr/local/etc/r1zebra.conf -d -z ~/Desktop/Apis/r1zebra.api -i ~/Desktop/Apis/r1zebra.interface')
time.sleep(1) # time for zebra to create api socket
r2.cmd('zebra -f /usr/local/etc/r2zebra.conf -d -z ~/Desktop/Apis/r2zebra.api -i ~/Desktop/Apis/r2zebra.interface')
r1.cmd('ospfd -f /usr/local/etc/r1ospfd.conf -d -z ~/Desktop/Apis/r1zebra.api -i ~/Desktop/Apis/r1ospfd.interface')
r2.cmd('ospfd -f /usr/local/etc/r2ospfd.conf -d -z ~/Desktop/Apis/r2zebra.api -i ~/Desktop/Apis/r2ospfd.interface')
r1.cmd('ospf6d -f /usr/local/etc/r1ospf6d.conf -d -z ~/Desktop/Apis/r1zebra.api -i ~/Desktop/Apis/r1ospf6d.interface')
r2.cmd('ospf6d -f /usr/local/etc/r2ospf6d.conf -d -z ~/Desktop/Apis/r2zebra.api -i ~/Desktop/Apis/r2ospf6d.interface'
这是 OPv6 分配和配置的顺序。使用 ipv4 进行测试和执行测试,它运行正常,但在 ipv6 中,我只有 h1-eth0 - r1-eth1 和 h2-eth0 - r2-eth1 之间的连接,但没有极端连接,也没有 r1-eth1 - r2 - eth1。执行时,应该为我创建套接字,但是,仅创建来自 ospfd 的用于 ipv4 的套接字,而不创建来自 ospf6d 的用于 ipv6 的套接字。有这方面工作的人,请帮助我。