]>
Commit | Line | Data |
---|---|---|
aaabb66e DL |
1 | #!/bin/sh |
2 | set -e | |
3 | ||
4 | # should have been started on install, but policy may have inhibited that | |
5 | service frr restart | |
6 | ||
7 | # these should be running by default | |
82ab1fc5 DL |
8 | pgrep watchfrr |
9 | pgrep zebra | |
10 | pgrep staticd | |
aaabb66e DL |
11 | |
12 | # configure interactively, save to file | |
13 | vtysh -c 'configure terminal' -c 'ip route 198.51.100.0/28 127.0.0.1' | |
14 | vtysh -c 'show running-config' | grep -q 'ip route 198.51.100.0/28 127.0.0.1' | |
15 | vtysh -c 'write memory' | |
16 | ||
17 | grep -q 'ip route 198.51.100.0/28 127.0.0.1' /etc/frr/frr.conf | |
18 | ||
19 | # configure in file, check interactively | |
20 | sed -e '/^ip route 198.51.100.0\/28 127.0.0.1/ c ip route 198.51.100.64/28 127.0.0.1' \ | |
21 | -i /etc/frr/frr.conf | |
22 | ||
23 | service frr reload | |
24 | ||
25 | vtysh -c 'show running-config' | grep -q 'ip route 198.51.100.64/28 127.0.0.1' | |
26 | if vtysh -c 'show running-config' | grep -q 'ip route 198.51.100.0/28 127.0.0.1'; then | |
27 | exit 1 | |
28 | fi |