xref: /aosp_15_r20/external/openthread/src/cli/README_BR.md (revision cfb92d1480a9e65faed56933e9c12405f45898b4)
1*cfb92d14SAndroid Build Coastguard Worker# OpenThread CLI - Border Router (BR)
2*cfb92d14SAndroid Build Coastguard Worker
3*cfb92d14SAndroid Build Coastguard Worker## Command List
4*cfb92d14SAndroid Build Coastguard Worker
5*cfb92d14SAndroid Build Coastguard WorkerUsage : `br [command] ...`
6*cfb92d14SAndroid Build Coastguard Worker
7*cfb92d14SAndroid Build Coastguard Worker- [counters](#counters)
8*cfb92d14SAndroid Build Coastguard Worker- [disable](#disable)
9*cfb92d14SAndroid Build Coastguard Worker- [enable](#enable)
10*cfb92d14SAndroid Build Coastguard Worker- [help](#help)
11*cfb92d14SAndroid Build Coastguard Worker- [init](#init)
12*cfb92d14SAndroid Build Coastguard Worker- [nat64prefix](#nat64prefix)
13*cfb92d14SAndroid Build Coastguard Worker- [omrprefix](#omrprefix)
14*cfb92d14SAndroid Build Coastguard Worker- [onlinkprefix](#onlinkprefix)
15*cfb92d14SAndroid Build Coastguard Worker- [pd](#pd)
16*cfb92d14SAndroid Build Coastguard Worker- [peers](#peers)
17*cfb92d14SAndroid Build Coastguard Worker- [prefixtable](#prefixtable)
18*cfb92d14SAndroid Build Coastguard Worker- [rioprf](#rioprf)
19*cfb92d14SAndroid Build Coastguard Worker- [routeprf](#routeprf)
20*cfb92d14SAndroid Build Coastguard Worker- [routers](#routers)
21*cfb92d14SAndroid Build Coastguard Worker- [state](#state)
22*cfb92d14SAndroid Build Coastguard Worker
23*cfb92d14SAndroid Build Coastguard Worker## Command Details
24*cfb92d14SAndroid Build Coastguard Worker
25*cfb92d14SAndroid Build Coastguard Worker### help
26*cfb92d14SAndroid Build Coastguard Worker
27*cfb92d14SAndroid Build Coastguard WorkerUsage: `br help`
28*cfb92d14SAndroid Build Coastguard Worker
29*cfb92d14SAndroid Build Coastguard WorkerPrint BR command help menu.
30*cfb92d14SAndroid Build Coastguard Worker
31*cfb92d14SAndroid Build Coastguard Worker```bash
32*cfb92d14SAndroid Build Coastguard Worker> br help
33*cfb92d14SAndroid Build Coastguard Workercounters
34*cfb92d14SAndroid Build Coastguard Workerdisable
35*cfb92d14SAndroid Build Coastguard Workerenable
36*cfb92d14SAndroid Build Coastguard Workeromrprefix
37*cfb92d14SAndroid Build Coastguard Workeronlinkprefix
38*cfb92d14SAndroid Build Coastguard Workerpd
39*cfb92d14SAndroid Build Coastguard Workerpeers
40*cfb92d14SAndroid Build Coastguard Workerprefixtable
41*cfb92d14SAndroid Build Coastguard Workerraoptions
42*cfb92d14SAndroid Build Coastguard Workerrioprf
43*cfb92d14SAndroid Build Coastguard Workerrouteprf
44*cfb92d14SAndroid Build Coastguard Workerrouters
45*cfb92d14SAndroid Build Coastguard Workerstate
46*cfb92d14SAndroid Build Coastguard WorkerDone
47*cfb92d14SAndroid Build Coastguard Worker```
48*cfb92d14SAndroid Build Coastguard Worker
49*cfb92d14SAndroid Build Coastguard Worker### init
50*cfb92d14SAndroid Build Coastguard Worker
51*cfb92d14SAndroid Build Coastguard WorkerUsage: `br init <interface> <enabled>`
52*cfb92d14SAndroid Build Coastguard Worker
53*cfb92d14SAndroid Build Coastguard WorkerInitializes the Border Routing Manager on given infrastructure interface.
54*cfb92d14SAndroid Build Coastguard Worker
55*cfb92d14SAndroid Build Coastguard Worker```bash
56*cfb92d14SAndroid Build Coastguard Worker> br init 2 1
57*cfb92d14SAndroid Build Coastguard WorkerDone
58*cfb92d14SAndroid Build Coastguard Worker```
59*cfb92d14SAndroid Build Coastguard Worker
60*cfb92d14SAndroid Build Coastguard Worker### enable
61*cfb92d14SAndroid Build Coastguard Worker
62*cfb92d14SAndroid Build Coastguard WorkerUsage: `br enable`
63*cfb92d14SAndroid Build Coastguard Worker
64*cfb92d14SAndroid Build Coastguard WorkerEnable the Border Routing functionality.
65*cfb92d14SAndroid Build Coastguard Worker
66*cfb92d14SAndroid Build Coastguard Worker```bash
67*cfb92d14SAndroid Build Coastguard Worker> br enable
68*cfb92d14SAndroid Build Coastguard WorkerDone
69*cfb92d14SAndroid Build Coastguard Worker```
70*cfb92d14SAndroid Build Coastguard Worker
71*cfb92d14SAndroid Build Coastguard Worker### disable
72*cfb92d14SAndroid Build Coastguard Worker
73*cfb92d14SAndroid Build Coastguard WorkerUsage: `br disable`
74*cfb92d14SAndroid Build Coastguard Worker
75*cfb92d14SAndroid Build Coastguard WorkerDisable the Border Routing functionality.
76*cfb92d14SAndroid Build Coastguard Worker
77*cfb92d14SAndroid Build Coastguard Worker```bash
78*cfb92d14SAndroid Build Coastguard Worker> br disable
79*cfb92d14SAndroid Build Coastguard WorkerDone
80*cfb92d14SAndroid Build Coastguard Worker```
81*cfb92d14SAndroid Build Coastguard Worker
82*cfb92d14SAndroid Build Coastguard Worker### state
83*cfb92d14SAndroid Build Coastguard Worker
84*cfb92d14SAndroid Build Coastguard WorkerUsage: `br state`
85*cfb92d14SAndroid Build Coastguard Worker
86*cfb92d14SAndroid Build Coastguard WorkerGet the Border Routing state:
87*cfb92d14SAndroid Build Coastguard Worker
88*cfb92d14SAndroid Build Coastguard Worker- `uninitialized`: Routing Manager is uninitialized.
89*cfb92d14SAndroid Build Coastguard Worker- `disabled`: Routing Manager is initialized but disabled.
90*cfb92d14SAndroid Build Coastguard Worker- `stopped`: Routing Manager in initialized and enabled but currently stopped.
91*cfb92d14SAndroid Build Coastguard Worker- `running`: Routing Manager is initialized, enabled, and running.
92*cfb92d14SAndroid Build Coastguard Worker
93*cfb92d14SAndroid Build Coastguard Worker```bash
94*cfb92d14SAndroid Build Coastguard Worker> br state
95*cfb92d14SAndroid Build Coastguard Workerrunning
96*cfb92d14SAndroid Build Coastguard Worker```
97*cfb92d14SAndroid Build Coastguard Worker
98*cfb92d14SAndroid Build Coastguard Worker### counters
99*cfb92d14SAndroid Build Coastguard Worker
100*cfb92d14SAndroid Build Coastguard WorkerUsage : `br counters`
101*cfb92d14SAndroid Build Coastguard Worker
102*cfb92d14SAndroid Build Coastguard WorkerGet the Border Router counter.
103*cfb92d14SAndroid Build Coastguard Worker
104*cfb92d14SAndroid Build Coastguard Worker```bash
105*cfb92d14SAndroid Build Coastguard Worker> br counters
106*cfb92d14SAndroid Build Coastguard WorkerInbound Unicast: Packets 4 Bytes 320
107*cfb92d14SAndroid Build Coastguard WorkerInbound Multicast: Packets 0 Bytes 0
108*cfb92d14SAndroid Build Coastguard WorkerOutbound Unicast: Packets 2 Bytes 160
109*cfb92d14SAndroid Build Coastguard WorkerOutbound Multicast: Packets 0 Bytes 0
110*cfb92d14SAndroid Build Coastguard WorkerRA Rx: 4
111*cfb92d14SAndroid Build Coastguard WorkerRA TxSuccess: 2
112*cfb92d14SAndroid Build Coastguard WorkerRA TxFailed: 0
113*cfb92d14SAndroid Build Coastguard WorkerRS Rx: 0
114*cfb92d14SAndroid Build Coastguard WorkerRS TxSuccess: 2
115*cfb92d14SAndroid Build Coastguard WorkerRS TxFailed: 0
116*cfb92d14SAndroid Build Coastguard WorkerDone
117*cfb92d14SAndroid Build Coastguard Worker```
118*cfb92d14SAndroid Build Coastguard Worker
119*cfb92d14SAndroid Build Coastguard Worker### omrprefix
120*cfb92d14SAndroid Build Coastguard Worker
121*cfb92d14SAndroid Build Coastguard WorkerUsage: `br omrprefix [local|favored]`
122*cfb92d14SAndroid Build Coastguard Worker
123*cfb92d14SAndroid Build Coastguard WorkerGet local or favored or both off-mesh-routable prefixes of the Border Router.
124*cfb92d14SAndroid Build Coastguard Worker
125*cfb92d14SAndroid Build Coastguard Worker```bash
126*cfb92d14SAndroid Build Coastguard Worker> br omrprefix
127*cfb92d14SAndroid Build Coastguard WorkerLocal: fdfc:1ff5:1512:5622::/64
128*cfb92d14SAndroid Build Coastguard WorkerFavored: fdfc:1ff5:1512:5622::/64 prf:low
129*cfb92d14SAndroid Build Coastguard WorkerDone
130*cfb92d14SAndroid Build Coastguard Worker
131*cfb92d14SAndroid Build Coastguard Worker> br omrprefix favored
132*cfb92d14SAndroid Build Coastguard Workerfdfc:1ff5:1512:5622::/64 prf:low
133*cfb92d14SAndroid Build Coastguard WorkerDone
134*cfb92d14SAndroid Build Coastguard Worker
135*cfb92d14SAndroid Build Coastguard Worker> br omrprefix local
136*cfb92d14SAndroid Build Coastguard Workerfdfc:1ff5:1512:5622::/64
137*cfb92d14SAndroid Build Coastguard WorkerDone
138*cfb92d14SAndroid Build Coastguard Worker```
139*cfb92d14SAndroid Build Coastguard Worker
140*cfb92d14SAndroid Build Coastguard Worker### onlinkprefix
141*cfb92d14SAndroid Build Coastguard Worker
142*cfb92d14SAndroid Build Coastguard WorkerUsage: `br onlinkprefix [local|favored]`
143*cfb92d14SAndroid Build Coastguard Worker
144*cfb92d14SAndroid Build Coastguard WorkerGet local or favored or both on-link prefixes of the Border Router.
145*cfb92d14SAndroid Build Coastguard Worker
146*cfb92d14SAndroid Build Coastguard Worker```bash
147*cfb92d14SAndroid Build Coastguard Worker> br onlinkprefix
148*cfb92d14SAndroid Build Coastguard WorkerLocal: fd41:2650:a6f5:0::/64
149*cfb92d14SAndroid Build Coastguard WorkerFavored: 2600::0:1234:da12::/64
150*cfb92d14SAndroid Build Coastguard WorkerDone
151*cfb92d14SAndroid Build Coastguard Worker
152*cfb92d14SAndroid Build Coastguard Worker> br onlinkprefix favored
153*cfb92d14SAndroid Build Coastguard Worker2600::0:1234:da12::/64
154*cfb92d14SAndroid Build Coastguard WorkerDone
155*cfb92d14SAndroid Build Coastguard Worker
156*cfb92d14SAndroid Build Coastguard Worker> br onlinkprefix local
157*cfb92d14SAndroid Build Coastguard Workerfd41:2650:a6f5:0::/64
158*cfb92d14SAndroid Build Coastguard WorkerDone
159*cfb92d14SAndroid Build Coastguard Worker```
160*cfb92d14SAndroid Build Coastguard Worker
161*cfb92d14SAndroid Build Coastguard Worker### nat64prefix
162*cfb92d14SAndroid Build Coastguard Worker
163*cfb92d14SAndroid Build Coastguard WorkerUsage: `br nat64prefix [local|favored]`
164*cfb92d14SAndroid Build Coastguard Worker
165*cfb92d14SAndroid Build Coastguard WorkerGet local or favored or both NAT64 prefixes of the Border Router.
166*cfb92d14SAndroid Build Coastguard Worker
167*cfb92d14SAndroid Build Coastguard Worker`OPENTHREAD_CONFIG_NAT64_BORDER_ROUTING_ENABLE` is required.
168*cfb92d14SAndroid Build Coastguard Worker
169*cfb92d14SAndroid Build Coastguard Worker```bash
170*cfb92d14SAndroid Build Coastguard Worker> br nat64prefix
171*cfb92d14SAndroid Build Coastguard WorkerLocal: fd14:1078:b3d5:b0b0:0:0::/96
172*cfb92d14SAndroid Build Coastguard WorkerFavored: fd14:1078:b3d5:b0b0:0:0::/96 prf:low
173*cfb92d14SAndroid Build Coastguard WorkerDone
174*cfb92d14SAndroid Build Coastguard Worker
175*cfb92d14SAndroid Build Coastguard Worker> br nat64prefix favored
176*cfb92d14SAndroid Build Coastguard Workerfd14:1078:b3d5:b0b0:0:0::/96 prf:low
177*cfb92d14SAndroid Build Coastguard WorkerDone
178*cfb92d14SAndroid Build Coastguard Worker
179*cfb92d14SAndroid Build Coastguard Worker> br nat64prefix
180*cfb92d14SAndroid Build Coastguard Workerfd14:1078:b3d5:b0b0:0:0::/96
181*cfb92d14SAndroid Build Coastguard WorkerDone
182*cfb92d14SAndroid Build Coastguard Worker```
183*cfb92d14SAndroid Build Coastguard Worker
184*cfb92d14SAndroid Build Coastguard Worker### pd
185*cfb92d14SAndroid Build Coastguard Worker
186*cfb92d14SAndroid Build Coastguard WorkerUsage: `br pd [enable|disable]`
187*cfb92d14SAndroid Build Coastguard Worker
188*cfb92d14SAndroid Build Coastguard WorkerEnable/Disable the DHCPv6 PD.
189*cfb92d14SAndroid Build Coastguard Worker
190*cfb92d14SAndroid Build Coastguard Worker```bash
191*cfb92d14SAndroid Build Coastguard Worker> br pd enable
192*cfb92d14SAndroid Build Coastguard WorkerDone
193*cfb92d14SAndroid Build Coastguard Worker
194*cfb92d14SAndroid Build Coastguard Worker> br pd disable
195*cfb92d14SAndroid Build Coastguard WorkerDone
196*cfb92d14SAndroid Build Coastguard Worker```
197*cfb92d14SAndroid Build Coastguard Worker
198*cfb92d14SAndroid Build Coastguard WorkerUsage: `br pd state`
199*cfb92d14SAndroid Build Coastguard Worker
200*cfb92d14SAndroid Build Coastguard WorkerGet the state of DHCPv6 PD.
201*cfb92d14SAndroid Build Coastguard Worker
202*cfb92d14SAndroid Build Coastguard Worker`OPENTHREAD_CONFIG_BORDER_ROUTING_DHCP6_PD_ENABLE` is required.
203*cfb92d14SAndroid Build Coastguard Worker
204*cfb92d14SAndroid Build Coastguard Worker- `disabled`: DHCPv6 PD is disabled on the border router.
205*cfb92d14SAndroid Build Coastguard Worker- `stopped`: DHCPv6 PD in enabled but won't try to request and publish a prefix.
206*cfb92d14SAndroid Build Coastguard Worker- `running`: DHCPv6 PD is enabled and will try to request and publish a prefix.
207*cfb92d14SAndroid Build Coastguard Worker
208*cfb92d14SAndroid Build Coastguard Worker```bash
209*cfb92d14SAndroid Build Coastguard Worker> br pd state
210*cfb92d14SAndroid Build Coastguard Workerrunning
211*cfb92d14SAndroid Build Coastguard WorkerDone
212*cfb92d14SAndroid Build Coastguard Worker```
213*cfb92d14SAndroid Build Coastguard Worker
214*cfb92d14SAndroid Build Coastguard WorkerUsage `br pd omrprefix`
215*cfb92d14SAndroid Build Coastguard Worker
216*cfb92d14SAndroid Build Coastguard WorkerGet the DHCPv6 Prefix Delegation (PD) provided off-mesh-routable (OMR) prefix.
217*cfb92d14SAndroid Build Coastguard Worker
218*cfb92d14SAndroid Build Coastguard Worker`OPENTHREAD_CONFIG_BORDER_ROUTING_DHCP6_PD_ENABLE` is required.
219*cfb92d14SAndroid Build Coastguard Worker
220*cfb92d14SAndroid Build Coastguard Worker```bash
221*cfb92d14SAndroid Build Coastguard Worker> br pd omrprefix
222*cfb92d14SAndroid Build Coastguard Worker2001:db8:cafe:0:0/64 lifetime:1800 preferred:1800
223*cfb92d14SAndroid Build Coastguard WorkerDone
224*cfb92d14SAndroid Build Coastguard Worker```
225*cfb92d14SAndroid Build Coastguard Worker
226*cfb92d14SAndroid Build Coastguard Worker### peers
227*cfb92d14SAndroid Build Coastguard Worker
228*cfb92d14SAndroid Build Coastguard WorkerUsage: `br peers`
229*cfb92d14SAndroid Build Coastguard Worker
230*cfb92d14SAndroid Build Coastguard WorkerGet the list of peer BRs found in the Network Data.
231*cfb92d14SAndroid Build Coastguard Worker
232*cfb92d14SAndroid Build Coastguard Worker`OPENTHREAD_CONFIG_BORDER_ROUTING_TRACK_PEER_BR_INFO_ENABLE` is required.
233*cfb92d14SAndroid Build Coastguard Worker
234*cfb92d14SAndroid Build Coastguard WorkerPeer BRs are other devices within the Thread mesh that provide external IP connectivity. A device is considered to provide external IP connectivity if at least one of the following conditions is met regarding its Network Data entries:
235*cfb92d14SAndroid Build Coastguard Worker
236*cfb92d14SAndroid Build Coastguard Worker- It has added at least one external route entry.
237*cfb92d14SAndroid Build Coastguard Worker- It has added at least one prefix entry with both the default-route and on-mesh flags set.
238*cfb92d14SAndroid Build Coastguard Worker- It has added at least one domain prefix (with both the domain and on-mesh flags set).
239*cfb92d14SAndroid Build Coastguard Worker
240*cfb92d14SAndroid Build Coastguard WorkerThe list of peer BRs specifically excludes the current device, even if it is itself acting as a BR.
241*cfb92d14SAndroid Build Coastguard Worker
242*cfb92d14SAndroid Build Coastguard WorkerInfo per BR entry:
243*cfb92d14SAndroid Build Coastguard Worker
244*cfb92d14SAndroid Build Coastguard Worker- RLOC16 of the BR
245*cfb92d14SAndroid Build Coastguard Worker- Age as the duration interval since this BR appeared in Network Data. It is formatted as `{hh}:{mm}:{ss}` for hours, minutes, seconds, if the duration is less than 24 hours. If the duration is 24 hours or more, the format is `{dd}d.{hh}:{mm}:{ss}` for days, hours, minutes, seconds.
246*cfb92d14SAndroid Build Coastguard Worker
247*cfb92d14SAndroid Build Coastguard Worker```bash
248*cfb92d14SAndroid Build Coastguard Worker> br peers
249*cfb92d14SAndroid Build Coastguard Workerrloc16:0x5c00 age:00:00:49
250*cfb92d14SAndroid Build Coastguard Workerrloc16:0xf800 age:00:01:51
251*cfb92d14SAndroid Build Coastguard WorkerDone
252*cfb92d14SAndroid Build Coastguard Worker```
253*cfb92d14SAndroid Build Coastguard Worker
254*cfb92d14SAndroid Build Coastguard WorkerUsage: `br peers count`
255*cfb92d14SAndroid Build Coastguard Worker
256*cfb92d14SAndroid Build Coastguard WorkerGets the number of peer BRs found in the Network Data.
257*cfb92d14SAndroid Build Coastguard Worker
258*cfb92d14SAndroid Build Coastguard WorkerThe count does not include the current device, even if it is itself acting as a BR.
259*cfb92d14SAndroid Build Coastguard Worker
260*cfb92d14SAndroid Build Coastguard WorkerThe output indicates the minimum age among all peer BRs. Age is formatted as `{hh}:{mm}:{ss}` for hours, minutes, seconds, if the duration is less than 24 hours. If the duration is 24 hours or more, the format is `{dd}d.{hh}:{mm}:{ss}` for days, hours, minutes, seconds.
261*cfb92d14SAndroid Build Coastguard Worker
262*cfb92d14SAndroid Build Coastguard Worker```bash
263*cfb92d14SAndroid Build Coastguard Worker> br peer count
264*cfb92d14SAndroid Build Coastguard Worker2 min-age:00:00:49
265*cfb92d14SAndroid Build Coastguard WorkerDone
266*cfb92d14SAndroid Build Coastguard Worker```
267*cfb92d14SAndroid Build Coastguard Worker
268*cfb92d14SAndroid Build Coastguard Worker### prefixtable
269*cfb92d14SAndroid Build Coastguard Worker
270*cfb92d14SAndroid Build Coastguard WorkerUsage: `br prefixtable`
271*cfb92d14SAndroid Build Coastguard Worker
272*cfb92d14SAndroid Build Coastguard WorkerGet the discovered prefixes by Border Routing Manager on the infrastructure link.
273*cfb92d14SAndroid Build Coastguard Worker
274*cfb92d14SAndroid Build Coastguard WorkerInfo per prefix entry:
275*cfb92d14SAndroid Build Coastguard Worker
276*cfb92d14SAndroid Build Coastguard Worker- The prefix
277*cfb92d14SAndroid Build Coastguard Worker- Whether the prefix is on-link or route
278*cfb92d14SAndroid Build Coastguard Worker- Milliseconds since last received Router Advertisement containing this prefix
279*cfb92d14SAndroid Build Coastguard Worker- Prefix lifetime in seconds
280*cfb92d14SAndroid Build Coastguard Worker- Preferred lifetime in seconds only if prefix is on-link
281*cfb92d14SAndroid Build Coastguard Worker- Route preference (low, med, high) only if prefix is route (not on-link)
282*cfb92d14SAndroid Build Coastguard Worker- The router IPv6 address which advertising this prefix
283*cfb92d14SAndroid Build Coastguard Worker- Flags in received Router Advertisement header:
284*cfb92d14SAndroid Build Coastguard Worker  - M: Managed Address Config flag
285*cfb92d14SAndroid Build Coastguard Worker  - O: Other Config flag
286*cfb92d14SAndroid Build Coastguard Worker  - Stub: Stub Router flag (indicates whether the router is a stub router)
287*cfb92d14SAndroid Build Coastguard Worker
288*cfb92d14SAndroid Build Coastguard Worker```bash
289*cfb92d14SAndroid Build Coastguard Worker> br prefixtable
290*cfb92d14SAndroid Build Coastguard Workerprefix:fd00:1234:5678:0::/64, on-link:no, ms-since-rx:29526, lifetime:1800, route-prf:med, router:ff02:0:0:0:0:0:0:1 (M:0 O:0 Stub:1)
291*cfb92d14SAndroid Build Coastguard Workerprefix:1200:abba:baba:0::/64, on-link:yes, ms-since-rx:29527, lifetime:1800, preferred:1800, router:ff02:0:0:0:0:0:0:1 (M:0 O:0 Stub:1)
292*cfb92d14SAndroid Build Coastguard WorkerDone
293*cfb92d14SAndroid Build Coastguard Worker```
294*cfb92d14SAndroid Build Coastguard Worker
295*cfb92d14SAndroid Build Coastguard Worker### raoptions
296*cfb92d14SAndroid Build Coastguard Worker
297*cfb92d14SAndroid Build Coastguard WorkerUsage: `br raoptions <options>`
298*cfb92d14SAndroid Build Coastguard Worker
299*cfb92d14SAndroid Build Coastguard WorkerSets additional options to append at the end of emitted Router Advertisement (RA) messages. `<options>` provided as hex bytes.
300*cfb92d14SAndroid Build Coastguard Worker
301*cfb92d14SAndroid Build Coastguard Worker```bash
302*cfb92d14SAndroid Build Coastguard Worker> br raoptions 0400ff00020001
303*cfb92d14SAndroid Build Coastguard WorkerDone
304*cfb92d14SAndroid Build Coastguard Worker```
305*cfb92d14SAndroid Build Coastguard Worker
306*cfb92d14SAndroid Build Coastguard Worker### raoptions clear
307*cfb92d14SAndroid Build Coastguard Worker
308*cfb92d14SAndroid Build Coastguard WorkerUsage: `br raoptions clear`
309*cfb92d14SAndroid Build Coastguard Worker
310*cfb92d14SAndroid Build Coastguard WorkerClear any previously set additional options to append at the end of emitted Router Advertisement (RA) messages.
311*cfb92d14SAndroid Build Coastguard Worker
312*cfb92d14SAndroid Build Coastguard Worker```bash
313*cfb92d14SAndroid Build Coastguard Worker> br raoptions clear
314*cfb92d14SAndroid Build Coastguard WorkerDone
315*cfb92d14SAndroid Build Coastguard Worker```
316*cfb92d14SAndroid Build Coastguard Worker
317*cfb92d14SAndroid Build Coastguard Worker### rioprf
318*cfb92d14SAndroid Build Coastguard Worker
319*cfb92d14SAndroid Build Coastguard WorkerUsage: `br rioprf`
320*cfb92d14SAndroid Build Coastguard Worker
321*cfb92d14SAndroid Build Coastguard WorkerGet the preference used when advertising Route Info Options (e.g., for discovered OMR prefixes) in emitted Router Advertisement message.
322*cfb92d14SAndroid Build Coastguard Worker
323*cfb92d14SAndroid Build Coastguard Worker```bash
324*cfb92d14SAndroid Build Coastguard Worker> br rioprf
325*cfb92d14SAndroid Build Coastguard Workermed
326*cfb92d14SAndroid Build Coastguard WorkerDone
327*cfb92d14SAndroid Build Coastguard Worker```
328*cfb92d14SAndroid Build Coastguard Worker
329*cfb92d14SAndroid Build Coastguard Worker### rioprf \<prf\>
330*cfb92d14SAndroid Build Coastguard Worker
331*cfb92d14SAndroid Build Coastguard WorkerUsage: `br rioprf high|med|low`
332*cfb92d14SAndroid Build Coastguard Worker
333*cfb92d14SAndroid Build Coastguard WorkerSet the preference (which may be 'high', 'med', or 'low') to use when advertising Route Info Options (e.g., for discovered OMR prefixes) in emitted Router Advertisement message.
334*cfb92d14SAndroid Build Coastguard Worker
335*cfb92d14SAndroid Build Coastguard Worker```bash
336*cfb92d14SAndroid Build Coastguard Worker> br rioprf low
337*cfb92d14SAndroid Build Coastguard WorkerDone
338*cfb92d14SAndroid Build Coastguard Worker```
339*cfb92d14SAndroid Build Coastguard Worker
340*cfb92d14SAndroid Build Coastguard Worker### rioprf clear
341*cfb92d14SAndroid Build Coastguard Worker
342*cfb92d14SAndroid Build Coastguard WorkerUsage: `br rioprf clear`
343*cfb92d14SAndroid Build Coastguard Worker
344*cfb92d14SAndroid Build Coastguard WorkerClear a previously set preference value for advertising Route Info Options (e.g., for discovered OMR prefixes) in emitted Router Advertisement message. When cleared BR will use device's role to determine the RIO preference: Medium preference when in router/leader role and low preference when in child role.
345*cfb92d14SAndroid Build Coastguard Worker
346*cfb92d14SAndroid Build Coastguard Worker```bash
347*cfb92d14SAndroid Build Coastguard Worker> br rioprf clear
348*cfb92d14SAndroid Build Coastguard WorkerDone
349*cfb92d14SAndroid Build Coastguard Worker```
350*cfb92d14SAndroid Build Coastguard Worker
351*cfb92d14SAndroid Build Coastguard Worker### routeprf
352*cfb92d14SAndroid Build Coastguard Worker
353*cfb92d14SAndroid Build Coastguard WorkerUsage: `br routeprf`
354*cfb92d14SAndroid Build Coastguard Worker
355*cfb92d14SAndroid Build Coastguard WorkerGet the preference used for publishing routes in Thread Network Data. This may be the automatically determined route preference, or an administratively set fixed route preference - if applicable.
356*cfb92d14SAndroid Build Coastguard Worker
357*cfb92d14SAndroid Build Coastguard Worker```bash
358*cfb92d14SAndroid Build Coastguard Worker> br routeprf
359*cfb92d14SAndroid Build Coastguard Workermed
360*cfb92d14SAndroid Build Coastguard WorkerDone
361*cfb92d14SAndroid Build Coastguard Worker```
362*cfb92d14SAndroid Build Coastguard Worker
363*cfb92d14SAndroid Build Coastguard Worker### routeprf \<prf\>
364*cfb92d14SAndroid Build Coastguard Worker
365*cfb92d14SAndroid Build Coastguard WorkerUsage: `br routeprf high|med|low`
366*cfb92d14SAndroid Build Coastguard Worker
367*cfb92d14SAndroid Build Coastguard WorkerSet the preference (which may be 'high', 'med', or 'low') to use publishing routes in Thread Network Data. Setting a preference value overrides the automatic route preference determination. It is used only for an explicit administrative configuration of a Border Router.
368*cfb92d14SAndroid Build Coastguard Worker
369*cfb92d14SAndroid Build Coastguard Worker```bash
370*cfb92d14SAndroid Build Coastguard Worker> br routeprf low
371*cfb92d14SAndroid Build Coastguard WorkerDone
372*cfb92d14SAndroid Build Coastguard Worker```
373*cfb92d14SAndroid Build Coastguard Worker
374*cfb92d14SAndroid Build Coastguard Worker### routeprf clear
375*cfb92d14SAndroid Build Coastguard Worker
376*cfb92d14SAndroid Build Coastguard WorkerUsage: `br routeprf clear`
377*cfb92d14SAndroid Build Coastguard Worker
378*cfb92d14SAndroid Build Coastguard WorkerClear a previously set preference value for publishing routes in Thread Network Data. When cleared BR will automatically determine the route preference based on device's role and link quality to parent (when acting as end-device).
379*cfb92d14SAndroid Build Coastguard Worker
380*cfb92d14SAndroid Build Coastguard Worker```bash
381*cfb92d14SAndroid Build Coastguard Worker> br routeprf clear
382*cfb92d14SAndroid Build Coastguard WorkerDone
383*cfb92d14SAndroid Build Coastguard Worker```
384*cfb92d14SAndroid Build Coastguard Worker
385*cfb92d14SAndroid Build Coastguard Worker### routers
386*cfb92d14SAndroid Build Coastguard Worker
387*cfb92d14SAndroid Build Coastguard WorkerUsage: `br routers`
388*cfb92d14SAndroid Build Coastguard Worker
389*cfb92d14SAndroid Build Coastguard WorkerGet the list of discovered routers by Border Routing Manager on the infrastructure link.
390*cfb92d14SAndroid Build Coastguard Worker
391*cfb92d14SAndroid Build Coastguard WorkerInfo per router:
392*cfb92d14SAndroid Build Coastguard Worker
393*cfb92d14SAndroid Build Coastguard Worker- The router IPv6 address
394*cfb92d14SAndroid Build Coastguard Worker- Flags in received Router Advertisement header:
395*cfb92d14SAndroid Build Coastguard Worker  - M: Managed Address Config flag
396*cfb92d14SAndroid Build Coastguard Worker  - O: Other Config flag
397*cfb92d14SAndroid Build Coastguard Worker  - Stub: Stub Router flag (indicates whether the router is a stub router)
398*cfb92d14SAndroid Build Coastguard Worker- Milliseconds since last received message from this router
399*cfb92d14SAndroid Build Coastguard Worker- Reachability flag: A router is marked as unreachable if it fails to respond to multiple Neighbor Solicitation probes.
400*cfb92d14SAndroid Build Coastguard Worker- Age: Duration interval since this router was first discovered. It is formatted as `{hh}:{mm}:{ss}` for hours, minutes, seconds, if the duration is less than 24 hours. If the duration is 24 hours or more, the format is `{dd}d.{hh}:{mm}:{ss}` for days, hours, minutes, seconds.
401*cfb92d14SAndroid Build Coastguard Worker- `(this BR)` is appended when the router is the local device itself.
402*cfb92d14SAndroid Build Coastguard Worker- `(peer BR)` is appended when the router is likely a peer BR connected to the same Thread mesh. This requires `OPENTHREAD_CONFIG_BORDER_ROUTING_TRACK_PEER_BR_INFO_ENABLE`.
403*cfb92d14SAndroid Build Coastguard Worker
404*cfb92d14SAndroid Build Coastguard Worker```bash
405*cfb92d14SAndroid Build Coastguard Worker> br routers
406*cfb92d14SAndroid Build Coastguard Workerff02:0:0:0:0:0:0:1 (M:0 O:0 Stub:1) ms-since-rx:1505 reachable:yes age:00:18:13
407*cfb92d14SAndroid Build Coastguard WorkerDone
408*cfb92d14SAndroid Build Coastguard Worker```
409