zoukankan      html  css  js  c++  java
  • 安装quagga

    [root@kunpeng82 devuser]# yum install quagga  -y

    [root@kunpeng82 devuser]# setsebool -P zebra_write_config 1

    [root@kunpeng82 devuser]# rpm -qal | grep quagga
    /etc/logrotate.d/quagga
    /etc/quagga
    /etc/sysconfig/quagga
    /usr/lib/tmpfiles.d/quagga.conf
    /usr/lib64/quagga
    /usr/lib64/quagga/libospf.so.0
    /usr/lib64/quagga/libospf.so.0.0.0
    /usr/lib64/quagga/libzebra.so.0
    /usr/lib64/quagga/libzebra.so.0.0.0
    /usr/share/doc/quagga-0.99.22.4
    /usr/share/doc/quagga-0.99.22.4/AUTHORS
    /usr/share/doc/quagga-0.99.22.4/COPYING
    /usr/share/doc/quagga-0.99.22.4/ChangeLog
    /usr/share/doc/quagga-0.99.22.4/INSTALL
    /usr/share/doc/quagga-0.99.22.4/NEWS
    /usr/share/doc/quagga-0.99.22.4/README
    /usr/share/doc/quagga-0.99.22.4/REPORTING-BUGS
    /usr/share/doc/quagga-0.99.22.4/SERVICES
    /usr/share/doc/quagga-0.99.22.4/TODO
    /usr/share/doc/quagga-0.99.22.4/babeld.conf.sample
    /usr/share/doc/quagga-0.99.22.4/bgpd.conf.sample
    /usr/share/doc/quagga-0.99.22.4/bgpd.conf.sample2
    /usr/share/doc/quagga-0.99.22.4/isisd.conf.sample
    /usr/share/doc/quagga-0.99.22.4/mpls
    /usr/share/doc/quagga-0.99.22.4/mpls/ChangeLog.opaque.txt
    /usr/share/doc/quagga-0.99.22.4/mpls/cli_summary.txt
    /usr/share/doc/quagga-0.99.22.4/mpls/opaque_lsa.txt
    /usr/share/doc/quagga-0.99.22.4/mpls/ospfd.conf
    /usr/share/doc/quagga-0.99.22.4/ospf6d.conf.sample
    /usr/share/doc/quagga-0.99.22.4/ospfd.conf.sample
    /usr/share/doc/quagga-0.99.22.4/quagga.html
    /usr/share/doc/quagga-0.99.22.4/ripd.conf.sample
    /usr/share/doc/quagga-0.99.22.4/ripngd.conf.sample
    /usr/share/doc/quagga-0.99.22.4/zebra.conf.sample
    /usr/share/info/quagga.info.gz
    /var/log/quagga
    /var/run/q

    [root@kunpeng82 devuser]# cat /etc/quagga/zebra.conf
    hostname kunpeng82.bogon
    [root@kunpeng82 devuser]# hostname
    kunpeng82.bogon

    [root@kunpeng82 devuser]# cat  /usr/share/doc/quagga-0.99.22.4/zebra.conf.sample

    [root@kunpeng82 devuser]# service zebra start
    Redirecting to /bin/systemctl start zebra.service
    [root@kunpeng82 devuser]#
    [root@kunpeng82 devuser]# service zebra start
    Redirecting to /bin/systemctl start zebra.service
    [root@kunpeng82 devuser]# vtysh 
    
    Hello, this is Quagga (version 0.99.22.4).
    Copyright 1996-2005 Kunihiro Ishiguro, et al.
    
    kunpeng82.bogon# configure terminal
    kunpeng82.bogon(config)# log file /var/log/quagga/quagga.log
    kunpeng82.bogon(config)# exit
    kunpeng82.bogon# write
    Building Configuration...
    Configuration saved to /etc/quagga/zebra.conf
    [OK]
    kunpeng82.bogon# show interface 
    Interface br-int is down
      index 12 metric 1 mtu 1500 
      flags: <BROADCAST,MULTICAST>
      HWaddr: 0a:d4:0c:e6:c4:4c
    Interface br-tun is down
      index 13 metric 1 mtu 1500 
      flags: <BROADCAST,MULTICAST>
      HWaddr: 2a:c9:7b:12:19:40
    Interface br-tun2 is down
      index 18 metric 1 mtu 1500 
      flags: <BROADCAST,MULTICAST>
      HWaddr: c6:4d:40:41:2a:4c
    Interface enahisic2i0 is up, line protocol detection is disa
    bled
      index 2 metric 1 mtu 1500 
      flags: <UP,BROADCAST,RUNNING,MULTICAST>
      HWaddr: 48:57:02:64:e7:ab
      inet 10.10.16.82/24
      inet6 fe80::4a57:2ff:fe64:e7ab/64
    Interface enahisic2i1 is up, line protocol detection is disa
    bled
      index 3 metric 1 mtu 1500 
      flags: <UP,BROADCAST,RUNNING,MULTICAST>
      HWaddr: 48:57:02:64:e7:ac
      inet 172.18.100.82/24
    Interface enahisic2i2 is up, line protocol detection is disa
    bled
      index 4 metric 1 mtu 1500 
      flags: <UP,BROADCAST,RUNNING,MULTICAST>
      HWaddr: 48:57:02:64:e7:ad
      inet 172.16.100.109/24 broadcast 172.16.100.255
      inet6 fe80::4a57:2ff:fe64:e7ad/64
    Interface enahisic2i3 is up, line protocol detection is disa
    bled
      index 5 metric 1 mtu 1500 
      flags: <UP,BROADCAST,RUNNING,MULTICAST>
      HWaddr: 48:57:02:64:e7:ae
    Interface lo is up, line protocol detection is disabled
      index 1 metric 1 mtu 65536 
      flags: <UP,LOOPBACK,RUNNING>
      inet 127.0.0.1/8
      inet6 ::1/128
    Interface ovs-switch is down
      index 7 metric 1 mtu 1500 
      flags: <BROADCAST,MULTICAST>
      HWaddr: 32:eb:99:f2:3a:41
    Interface ovs-system is down
      index 6 metric 1 mtu 1500 
      flags: <BROADCAST,MULTICAST>
      HWaddr: aa:8c:c4:1d:f9:25
    Interface p1 is down
      index 22 metric 1 mtu 1500 
      flags: <BROADCAST,MULTICAST>
      HWaddr: ce:52:77:9e:07:3d
    Interface p2 is down
      index 23 metric 1 mtu 1500 
      flags: <BROADCAST,MULTICAST>
      HWaddr: 36:02:e6:58:45:13
    Interface qbr01 is up, line protocol detection is disabled
      index 14 metric 1 mtu 1500 
      flags: <UP,BROADCAST,RUNNING,MULTICAST>
      HWaddr: 86:28:6e:0f:27:b5
      inet6 fe80::d4e8:17ff:fe80:7ee5/64
    Interface qvb01 is up, line protocol detection is disabled
      index 15 metric 1 mtu 1500 
      flags: <UP,BROADCAST,RUNNING,MULTICAST>
      HWaddr: 86:28:6e:0f:27:b5
      inet6 fe80::8428:6eff:fe0f:27b5/64
    Interface qvo01 is up, line protocol detection is disabled
      index 16 metric 1 mtu 1500 
      flags: <UP,BROADCAST,RUNNING,MULTICAST>
      HWaddr: c2:2a:ea:e5:23:e5
      inet6 fe80::c02a:eaff:fee5:23e5/64
    Interface s1 is down
      index 20 metric 1 mtu 1500 
      flags: <BROADCAST,MULTICAST>
      HWaddr: 12:1c:99:af:e1:47
    Interface s2 is down
      index 21 metric 1 mtu 1500 
      flags: <BROADCAST,MULTICAST>
      HWaddr: ba:c4:cf:c3:23:41
    Interface vxlan_sys_4789 is up, line protocol detection is d
    isabled
      index 19 metric 1 mtu 65000 
      flags: <UP,BROADCAST,RUNNING,MULTICAST>
      HWaddr: da:65:1e:f6:a4:72
      inet6 fe80::d865:1eff:fef6:a472/64
    kunpeng82.bogon# 
    

      

    kunpeng82.bogon# interface enahisic2i0
    % Unknown command.
    kunpeng82.bogon# configure terminal
    kunpeng82.bogon(config)# interface enahisic2i0
    kunpeng82.bogon(config-if)# description to-site-office
    kunpeng82.bogon(config-if)# interface enahisic2i1
    kunpeng82.bogon(config-if)# description to-site-ceph
    kunpeng82.bogon(config-if)# 
    

      

    kunpeng82.bogon(config-if)# interface enahisic2i1
    kunpeng82.bogon(config-if)# no shutdown 
    kunpeng82.bogon(config-if)# interface enahisic2i0
    kunpeng82.bogon(config-if)# no shutdown 
    kunpeng82.bogon(config-if)# do show interface enahisic2i0
    Interface enahisic2i0 is up, line protocol detection is disa
    bled
      Description: to-site-office
      index 2 metric 1 mtu 1500 
      flags: <UP,BROADCAST,RUNNING,MULTICAST>
      HWaddr: 48:57:02:64:e7:ab
      inet 10.10.16.82/24
      inet6 fe80::4a57:2ff:fe64:e7ab/64
    kunpeng82.bogon(config-if)# do show interface enahisic2i1
    Interface enahisic2i1 is up, line protocol detection is disa
    bled
      Description: to-site-ceph
      index 3 metric 1 mtu 1500 
      flags: <UP,BROADCAST,RUNNING,MULTICAST>
      HWaddr: 48:57:02:64:e7:ac
      inet 172.18.100.82/24
    kunpeng82.bogon(config-if)# do show interface description 
    Interface       Status  Protocol  Description
    br-int          down    down      
    br-tun          down    down      
    br-tun2         down    down      
    enahisic2i0     up      unknown   to-site-office
    enahisic2i1     up      unknown   to-site-ceph
    enahisic2i2     up      unknown   
    enahisic2i3     up      unknown  
    
    
    
    
    
    kunpeng82.bogon(config-if)#  do write
    Building Configuration...
    Configuration saved to /etc/quagga/zebra.conf
    [OK]
    kunpeng82.bogon(config-if)# exit
    kunpeng82.bogon(config)# exit
    kunpeng82.bogon# exit
    [root@kunpeng82 devuser]# service ospfd start
    Redirecting to /bin/systemctl start ospfd.service
    [root@kunpeng82 devuser]# vtysh
    
    Hello, this is Quagga (version 0.99.22.4).
    Copyright 1996-2005 Kunihiro Ishiguro, et al.
    
    kunpeng82.bogon# configure terminal
    kunpeng82.bogon(config)# router-id 10.10.16.81
    kunpeng82.bogon(config)# show ip ospf neighbor
    % Unknown command.
    kunpeng82.bogon(config)# network 10.10.16.0/24 area 0
    % Unknown command.
    kunpeng82.bogon(config)# router ospf
    kunpeng82.bogon(config-router)# show ip ospf neighbor
    % Unknown command.
    kunpeng82.bogon(config-router)# network 10.10.16.0/24 area 0
    kunpeng82.bogon(config-router)# network 172.18.100.0/24 area 0
    kunpeng82.bogon(config-router)# exit
    kunpeng82.bogon(config)# exit
    kunpeng82.bogon# show ip ospf neighbor 
    kunpeng82.bogon# 
    

      配置另外一台机器:

    kunpeng81.bogon(config-router)# network 192.168.117.0/24 area 0
    kunpeng81.bogon(config-router)# network 172.18.100.0/24 area 0
    [devuser@kunpeng82 ~]$ ip route list
    default via 10.10.16.254 dev enahisic2i0 
    10.10.16.0/24 dev enahisic2i0 proto kernel scope link src 10.10.16.82
    172.18.100.0/24 dev enahisic2i1 proto kernel scope link src 172.18.100.82 
    192.168.117.0/24 dev enahisic2i1 proto kernel scope link src 172.18.100.82 
  • 相关阅读:
    用Java实现四则运算
    敏捷开发角色分配
    需求分析之WBS
    需求分析之NABCD
    电梯演说
    开发流程的选择
    软件团队模式的选择
    维护日程管理项目
    日程管理系统中找错误
    Android的测试
  • 原文地址:https://www.cnblogs.com/dream397/p/12316210.html
Copyright © 2011-2022 走看看