Reject log message; bgp_community comparaison

Arnaud Fenioux afenioux at franceix.net
Wed Jan 28 15:20:09 CET 2015


Hello the bird community,

I’ve two small questions, I've put them in the same mail even if they are not related :

1/ I currently use this code in my config to reject “martians”

        if ( is_martian() ) then {
                reject "prefix rejected by is_martian";
        }

Which prints in logs : <INFO> prefix rejected by is_martian
Do you know if there is a way to add some variables in the log (like bgp_path.first, from or net) ?


2/ I’ve notice a “strange” behaviour when comparing communities, is this voluntary?

Pair set have to be compared on the right :
bird> show route where bgp_community ~ [ (51706,51706) ] count
2467 of 2467 routes for 2426 networks

bird> show route where [ (51706,51706) ] ~ bgp_community count
0 of 2467 routes for 2426 networks


Pair have to be compared on the left :
bird> show route where (51706,51706) ~ bgp_community count
2467 of 2467 routes for 2426 networks

bird> show route where bgp_community ~ (51706,51706) count
0 of 2467 routes for 2426 networks


Thanks

--
Arnaud Fenioux
Network Engineer - FranceIX

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 842 bytes
Desc: Message signed with OpenPGP using GPGMail
URL: <http://trubka.network.cz/pipermail/bird-users/attachments/20150128/60857b93/attachment.asc>


More information about the Bird-users mailing list