1
0
Fork 0
mirror of https://github.com/pavel-odintsov/fastnetmon synced 2024-05-27 00:36:12 +02:00

Add docs about flow spec configuration on Git's ExaBGP

This commit is contained in:
Pavel Odintsov 2015-07-13 17:56:39 +02:00
parent 299e03b629
commit a87c07270b

47
docs/BGP_FLOW_SPEC.md Normal file
View File

@ -0,0 +1,47 @@
### All this docs about ExaBGP 4.0 (Git master branch)
Thay are not compatible with ExaBGP 3.0
vim /root/announcer.py:
```bash
#!/usr/bin/python
fl=open("/var/run/exabgp.cmd", "w")
fl.write("announce flow route source 4.0.0.0/24 destination 127.0.0.0/24 protocol [ udp ] source-port [ =53 ] destination-port [ =80 ] packet-length [ =777 =1122 ] fragment [ is-fragment dont-fragment ] rate-limit 1024" + '\n')
fl.flush()
fl.close
```
Please be careful about flush and trailing '\n'!!!
vim /etc/exabgp_flowspec.conf:
```bash
process announce-routes {
run /usr/bin/socat stdout pipe:/var/run/exabgp.cmd;
encoder json;
}
neighbor 127.0.0.1 {
router-id 1.2.3.4;
local-address 127.0.0.1;
local-as 1;
peer-as 1;
group-updates false;
family {
ipv4 flow;
}
api {
processes [ anounce-routes ];
}
}
```
Run it:
```bash
env exabgp.api.file=/tmp/exabgp.cmd exabgp.daemon.user=root exabgp.daemon.daemonize=false exabgp.daemon.pid=/var/run/exabgp.pid exabgp.log.destination=/var/log/exabgp.log sbin/exabgp --debug /etc/exabgp_flowspec.conf
```