Skip to content

Commit d074d3f

Browse files
authored
fix(openthread-br): use correct ipv6 configuration (#14829)
1 parent 65f3a23 commit d074d3f

2 files changed

Lines changed: 32 additions & 0 deletions

File tree

ct/openthread-br.sh

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -70,6 +70,27 @@ function update_script() {
7070
$STD ninja install
7171
msg_ok "Rebuilt OpenThread Border Router"
7272

73+
if ! grep -q "net.ipv6.conf.all.accept_ra=2" /etc/sysctl.d/99-otbr.conf; then
74+
msg_info "Configuring Network"
75+
cat <<EOF >/etc/sysctl.d/99-otbr.conf
76+
net.ipv6.conf.all.forwarding=1
77+
net.ipv6.conf.all.accept_ra=2
78+
net.ipv6.conf.all.accept_ra_rtr_pref=1
79+
net.ipv6.conf.all.accept_ra_rt_info_max_plen=64
80+
net.ipv6.conf.default.forwarding=1
81+
net.ipv6.conf.default.accept_ra=2
82+
net.ipv6.conf.default.accept_ra_rtr_pref=1
83+
net.ipv6.conf.default.accept_ra_rt_info_max_plen=64
84+
net.ipv6.conf.eth0.forwarding=1
85+
net.ipv6.conf.eth0.accept_ra=2
86+
net.ipv6.conf.eth0.accept_ra_rtr_pref=1
87+
net.ipv6.conf.eth0.accept_ra_rt_info_max_plen=64
88+
net.ipv4.ip_forward=1
89+
EOF
90+
$STD sysctl -p /etc/sysctl.d/99-otbr.conf
91+
msg_ok "Configured Network"
92+
fi
93+
7394
msg_info "Starting Services"
7495
systemctl start otbr-agent
7596
systemctl start otbr-web

install/openthread-br-install.sh

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -67,6 +67,17 @@ msg_ok "Built OpenThread Border Router"
6767
msg_info "Configuring Network"
6868
cat <<EOF >/etc/sysctl.d/99-otbr.conf
6969
net.ipv6.conf.all.forwarding=1
70+
net.ipv6.conf.all.accept_ra=2
71+
net.ipv6.conf.all.accept_ra_rtr_pref=1
72+
net.ipv6.conf.all.accept_ra_rt_info_max_plen=64
73+
net.ipv6.conf.default.forwarding=1
74+
net.ipv6.conf.default.accept_ra=2
75+
net.ipv6.conf.default.accept_ra_rtr_pref=1
76+
net.ipv6.conf.default.accept_ra_rt_info_max_plen=64
77+
net.ipv6.conf.eth0.forwarding=1
78+
net.ipv6.conf.eth0.accept_ra=2
79+
net.ipv6.conf.eth0.accept_ra_rtr_pref=1
80+
net.ipv6.conf.eth0.accept_ra_rt_info_max_plen=64
7081
net.ipv4.ip_forward=1
7182
EOF
7283
$STD sysctl -p /etc/sysctl.d/99-otbr.conf

0 commit comments

Comments
 (0)