Annotation of wikisrc/quagga.mdwn, revision 1.2

1.2     ! schmonz     1: #quagga
        !             2: 
        !             3: Quagga is a routing software package which supports following protocols: RIP, OSPF, BGP, IPv4, IPv6, etc.
        !             4: 
        !             5: NetBSD provides network configuration through *ifconfig, route, netstat, *etc.
        !             6: 
        !             7: In the alternative Quagga also can setup interface's, addresses, flags, routes and so on. Quagga provides and handles the alternative networking options. Quagga can be in use for single xDSL connection, small network configuration and to set-up backbone routers for really large network.
        !             8: 
        !             9: Very often Quagga in use together with NetBSD networking. NetBSD serves interfaces and Quagga serves routing.
        !            10: 
        !            11: Traditionally ISP's uses Quagga for RIP, OSPF and BGP routing. 
        !            12: 
        !            13: **Contents**
        !            14: 
        !            15: [[!toc]]
        !            16: 
        !            17: #Installation
        !            18: 
        !            19: To install Quagga Routing Suite do:
        !            20: 
        !            21:     # cd /usr/pkgsrc/net/quagga
        !            22:     # make install
        !            23: 
        !            24: Configuration files located at */usr/pkg/etc/zebra*.
        !            25: 
        !            26: To run quagga during machine start you can add into *rc.local* file following:
        !            27: 
        !            28:     mkdir /var/run/zebra
        !            29:     chown quagga /var/run/zebra
        !            30:     chgrp quagga /var/run/zebra
        !            31:     /usr/pkg/sbin/zebra -d
        !            32:     /usr/pkg/sbin/bgpd -d
        !            33: 
        !            34: Put in */usr/pkg/etc/zebra/zebra.conf* following:
        !            35: 
        !            36:     hostname yourhostname
        !            37:     password yourpassword
        !            38:     enable password yourpassword
        !            39: 
        !            40: Log files located at: */var/log/quagga/*. 
        !            41: 
        !            42: #Interfaces
        !            43: 
        !            44: If you need to define **lo** put the following in */usr/pkg/etc/zebra/zebra.conf*, for an example:
        !            45: 
        !            46:     interface lo
        !            47:     ip address 127.0.0.1/8 
        !            48:     ip address A.B.C.D/32 (this is your host real IP address)
        !            49: 
        !            50: To enable network interfaces put for an example:
        !            51: 
        !            52:     interface rtk0
        !            53:     ip address 192.168.170.201/24
        !            54:     multicast
        !            55: 
        !            56: *Note*. This is alternative way to setup network interfaces instead of /etc/ifconfig.xxx configuration files.
        !            57: 
        !            58: #How to set up Quagga BGP router.
        !            59: 
        !            60: Example of content for */usr/pkg/etc/zebra/bgpd.conf* file:
        !            61: <pre><code>
        !            62: !
        !            63: hostname bgpd.qw
        !            64: password xxxx
        !            65: enable password xxxx
        !            66: log file /var/log/zebra/bgpd.log
        !            67: !
        !            68: router bgp 12121
        !            69: bgp router-id 192.168.170.1
        !            70: network 192.168.170.0/24
        !            71: !
        !            72: !
        !            73: !
        !            74: neighbor 192.168.171.1 remote-as 12121
        !            75: neighbor 192.168.171.1 description GW-TER-UA
        !            76: neighbor 192.168.171.1 version 4
        !            77: neighbor 192.168.171.1 soft-reconfiguration inbound
        !            78: neighbor 192.168.171.1 router-map UA-IN in
        !            79: neighbor 192.168.171.1 prefix-list UA-OUT out
        !            80: !
        !            81: !
        !            82: !
        !            83: neighbor 192.168.172.1 remote-as 12121
        !            84: neighbor 192.168.172.1 description GW-TER-WORLD
        !            85: neighbor 192.168.172.1 version 4
        !            86: neighbor 192.168.172.1 soft-reconfiguration inbound
        !            87: neighbor 192.168.172.1 router-map WOLRD-IN in
        !            88: neighbor 192.168.172.1 prefix-list WORLD-OUT out
        !            89: !
        !            90: !
        !            91: !
        !            92: router-map WORLD-IN permit 10
        !            93:  set local-preference 200
        !            94: !
        !            95: ip prefix-list WORLD-OUT permit 192.168.170.0/24
        !            96: !
        !            97: !
        !            98: !
        !            99: router-map UA-IN permit 10
        !           100: set local-preference 100
        !           101: !
        !           102: ip prefix-list UA-OUT permit 192.168.170.0/24
        !           103: !
        !           104: !
        !           105: !
        !           106: access-list CONF permit 192.168.170.0/24
        !           107: access-list CONF deny any
        !           108: !
        !           109: !
        !           110: !
        !           111: line vty
        !           112:  access-class CONF
        !           113:  exec-timeout 120 0
        !           114: </pre></code>
        !           115: 
        !           116: #Example: osfpd.conf
        !           117: 
        !           118: Here is an example of */usr/pk/etc/zebra/ospfd.conf* file:
        !           119: 
        !           120: <pre><code>
        !           121: hostname yourhostname
        !           122: password yourpassword
        !           123: enable password yourpassword
        !           124: 
        !           125: interface rtk0
        !           126:  no ip ospf authentication-key
        !           127:  ip ospf hello-interval 2
        !           128:  ip ospf dead-interval 5
        !           129: 
        !           130: interface rtk1
        !           131:  no ip ospf authentication-key
        !           132:  ip ospf hello-interval 2
        !           133:  ip ospf dead-interval 5
        !           134: 
        !           135: router ospf
        !           136:   ospf router-id A.B.C.D
        !           137:   network 192.168.170.0/24 area 0
        !           138:   network 192.168.171.0/24 area 0
        !           139: </pre></code>
        !           140: 
        !           141: #vtysh
        !           142: 
        !           143: 
        !           144: To manage quagga router do:
        !           145: 
        !           146:     # vtysh
        !           147: 
1.1       mspo      148: See also [Quagga Routing Suite](http://www.quagga.net/)

CVSweb for NetBSD wikisrc <wikimaster@NetBSD.org> software: FreeBSD-CVSweb