05-Layer 3—IP Routing Command Reference

HomeSupportReference GuidesCommand ReferencesH3C S12500-X & S12500X-AF Switch Series Command References-Release 113x-6W10105-Layer 3—IP Routing Command Reference
Table of Contents
Related Documents
01-Text
Title Size Download
01-Text 1.88 MB

Contents

Basic IP routing commands· 1

address-family ipv4· 1

display ecmp mode· 1

display ip routing-table· 2

display ip routing-table acl 5

display ip routing-table ip-address· 8

display ip routing-table prefix-list 10

display ip routing-table protocol 12

display ip routing-table statistics· 13

display rib attribute· 15

display rib graceful-restart 16

display rib nib· 18

display route-direct nib· 22

ecmp mode enhanced· 24

fib lifetime· 25

protocol lifetime· 25

reset ip routing-table statistics protocol 26

rib· 27

Static routing commands· 28

delete static-routes all 28

display route-static nib· 28

display route-static routing-table· 31

ip route-static· 33

ip route-static default-preference· 35

ip route-static primary-path-detect bfd echo· 36

RIP commands· 37

checkzero· 37

default cost 37

default-route· 38

display rip· 39

display rip database· 40

display rip interface· 41

display rip route· 43

fast-reroute· 45

filter-policy export 46

filter-policy import 47

graceful-restart 48

host-route· 49

import-route· 50

maximum load-balancing· 51

network· 51

output-delay· 52

peer 53

preference· 53

reset rip process· 54

reset rip statistics· 55

rip· 55

rip authentication-mode· 56

rip bfd enable· 57

rip bfd enable destination· 57

rip default-route· 58

rip enable· 59

rip input 60

rip max-packet-length· 60

rip metricin· 61

rip metricout 62

rip mib-binding· 63

rip output 63

rip poison-reverse· 64

rip primary-path-detect bfd echo· 64

rip split-horizon· 65

rip summary-address· 66

rip version· 66

silent-interface· 67

summary· 68

timers· 69

validate-source-address· 70

version· 70

OSPF commands· 72

abr-summary (OSPF area view) 72

area (OSPF view) 72

asbr-summary· 73

authentication-mode· 74

bandwidth-reference (OSPF view) 76

default 76

default-cost (OSPF area view) 77

default-route-advertise (OSPF view) 78

description (OSPF/OSPF area view) 79

discard-route· 80

display ospf 80

display ospf abr-asbr 86

display ospf abr-summary· 87

display ospf asbr-summary· 89

display ospf event-log· 91

display ospf fast-reroute lfa-candidate· 94

display ospf graceful-restart 95

display ospf interface· 98

display ospf lsdb· 100

display ospf nexthop· 103

display ospf peer 104

display ospf peer statistics· 107

display ospf request-queue· 108

display ospf retrans-queue· 109

display ospf routing· 110

display ospf spf-tree· 113

display ospf statistics· 116

display ospf vlink· 120

display router id· 121

dscp· 122

enable link-local-signaling· 122

enable out-of-band-resynchronization· 123

event-log· 123

fast-reroute (OSPF view) 124

filter (OSPF area view) 125

filter-policy export (OSPF view) 126

filter-policy import (OSPF view) 127

graceful-restart (OSPF view) 128

graceful-restart helper enable· 129

graceful-restart helper strict-lsa-checking· 130

graceful-restart interval (OSPF view) 130

host-advertise· 131

import-route (OSPF view) 132

ispf enable· 133

log-peer-change· 134

lsa-arrival-interval 134

lsdb-overflow-interval 135

lsa-generation-interval 136

lsdb-overflow-limit 136

maximum load-balancing (OSPF view) 137

network (OSPF area view) 137

nssa· 138

opaque-capability enable· 140

ospf 140

ospf area· 141

ospf authentication-mode· 142

ospf bfd enable· 143

ospf cost 144

ospf dr-priority· 145

ospf fast-reroute lfa-backup· 145

ospf mib-binding· 146

ospf mtu-enable· 146

ospf network-type· 147

ospf prefix-suppression· 148

ospf primary-path-detect bfd echo· 149

ospf timer dead· 150

ospf timer hello· 150

ospf timer poll 151

ospf timer retransmit 152

ospf trans-delay· 152

peer 153

pic· 154

preference· 155

prefix-priority· 155

prefix-suppression· 156

reset ospf statistics· 157

reset ospf event-log· 157

reset ospf process· 158

reset ospf redistribution· 159

rfc1583 compatible· 159

router id· 160

silent-interface (OSPF view) 161

snmp-agent trap enable ospf 161

snmp trap rate-limit 163

spf-schedule-interval 163

stub (OSPF area view) 164

stub-router 165

transmit-pacing· 166

vlink-peer (OSPF area view) 167

IS-IS commands· 169

area-authentication-mode· 169

auto-cost enable· 170

bandwidth-reference (IS-IS view) 171

circuit-cost 171

cost-style· 172

default-route-advertise (IS-IS view) 173

display isis brief 174

display isis graceful-restart event-log· 175

display isis graceful-restart status· 176

display isis interface· 178

display isis lsdb· 180

display isis name-table· 183

display isis peer 184

display isis redistribute· 187

display isis route· 188

display isis spf-tree· 191

display isis statistics· 197

display osi 199

display osi statistics· 200

domain-authentication-mode· 202

fast-reroute· 203

filter-policy export 203

filter-policy import 204

flash-flood· 206

graceful-restart 206

graceful-restart suppress-sa· 207

graceful-restart t1· 208

graceful-restart t2· 208

graceful-restart t3· 209

import-route· 210

import-route isis level-1 into level-2· 211

import-route isis level-2 into level-1· 212

import-route limit 213

isis· 214

isis authentication-mode· 214

isis bfd enable· 216

isis circuit-level 216

isis circuit-type p2p· 217

isis cost 218

isis dis-name· 218

isis dis-priority· 219

isis enable· 220

isis mib-binding· 221

isis primary-path-detect bfd echo· 221

isis silent 222

isis small-hello· 222

isis timer csnp· 223

isis timer hello· 224

isis timer holding-multiplier 225

isis timer lsp· 226

isis timer retransmit 226

ispf enable· 227

is-level 228

is-name· 228

is-name map· 229

log-peer-change· 230

lsp-fragments-extend· 230

lsp-length originate· 231

lsp-length receive· 232

maximum load-balancing (IS-IS view) 232

network-entity· 233

preference· 234

priority· 234

reset isis all 235

reset isis graceful-restart event-log· 236

reset isis peer 236

reset osi statistics· 237

set-overload· 237

snmp context-name· 238

snmp-agent trap enable isis· 239

summary (IS-IS view) 240

timer lsp-generation· 241

timer lsp-max-age· 242

timer lsp-refresh· 243

timer spf 243

virtual-system·· 244

BGP commands· 246

address-family ipv4· 246

advertise-rib-active· 246

aggregate· 247

balance· 250

balance as-path-neglect 251

bestroute as-path-neglect 251

bestroute compare-med· 252

bestroute med-confederation· 253

bgp· 254

bgp update-delay on-startup· 254

compare-different-as-med· 255

confederation id· 256

confederation nonstandard· 257

confederation peer-as· 257

dampening· 258

default local-preference· 259

default med· 260

default-route imported· 261

display bgp dampening parameter ipv4 unicast 262

display bgp group· 263

display bgp network· 265

display bgp non-stop-routing status· 266

display bgp paths· 267

display bgp peer 268

display bgp routing-table dampened ipv4 unicast 272

display bgp routing-table flap-info ipv4 unicast 273

display bgp routing-table ipv4 unicast 275

display bgp routing-table ipv4 unicast advertise-info· 278

display bgp routing-table ipv4 unicast as-path-acl 280

display bgp routing-table ipv4 unicast community-list 281

display bgp routing-table ipv4 unicast peer 282

display bgp routing-table ipv4 unicast statistics· 284

display bgp update-group· 285

ebgp-interface-sensitive· 287

fast-reroute route-policy· 288

filter-policy export 289

filter-policy import 290

graceful-restart 291

graceful-restart timer purge-time· 292

graceful-restart timer restart 293

graceful-restart timer wait-for-rib· 294

group· 295

ignore-first-as· 296

import-route· 297

ip vpn-instance (BGP view) 298

log-peer-change· 299

log-route-flap· 300

network· 300

network short-cut 301

non-stop-routing· 302

peer advertise-community· 303

peer advertise-ext-community· 304

peer allow-as-loop· 305

peer as-number (for a BGP peer group) 306

peer as-number (for a BGP peer) 307

peer as-path-acl 308

peer bfd· 309

peer capability-advertise conventional 311

peer capability-advertise route-refresh· 312

peer capability-advertise suppress-4-byte-as· 313

peer connect-interface· 314

peer default-route-advertise· 315

peer description· 316

peer ebgp-max-hop· 317

peer enable· 318

peer fake-as· 320

peer filter-policy· 321

peer group· 322

peer ignore· 323

peer ignore-originatorid· 324

peer keep-all-routes· 325

peer low-memory-exempt 326

peer next-hop-local 327

peer password· 328

peer preferred-value· 330

peer prefix-list 331

peer public-as-only· 332

peer reflect-client 333

peer route-limit 334

peer route-policy· 335

peer route-update-interval 336

peer source-address· 337

peer substitute-as· 338

peer timer 339

peer ttl-security· 341

pic· 342

preference· 343

primary-path-detect bfd· 344

reflect between-clients· 344

reflector cluster-id· 345

refresh bgp· 346

reset bgp· 347

reset bgp all 348

reset bgp dampening ipv4 unicast 349

reset bgp flap-info ipv4 unicast 350

router id (system view) 351

router-id (BGP view) 352

router-id (BGP-VPN instance view) 352

snmp-agent trap enable bgp· 353

summary automatic· 354

timer 355

Policy-based routing commands· 357

apply default-next-hop· 357

apply next-hop· 357

apply output-interface NULL 0· 358

display ip policy-based-route· 359

display ip policy-based-route interface· 360

display ip policy-based-route local 362

display ip policy-based-route setup· 363

if-match acl 364

if-match vxlan-id· 364

ip local policy-based-route· 365

ip policy-based-route· 366

ip policy-based-route egress· 366

ip policy-based-route vxlan-mode enable· 367

policy-based-route· 368

reset ip policy-based-route statistics· 368

Routing policy commands· 370

Common routing policy commands· 370

apply as-path· 370

apply comm-list delete· 370

apply community· 371

apply cost 372

apply cost-type· 373

apply extcommunity· 374

apply isis· 374

apply local-preference· 375

apply origin· 376

apply preference· 376

apply preferred-value· 377

apply prefix-priority· 377

apply tag· 378

continue· 379

display ip as-path· 379

display ip community-list 380

display ip extcommunity-list 381

display route-policy· 382

if-match as-path· 382

if-match community· 383

if-match cost 384

if-match extcommunity· 384

if-match interface· 385

if-match local-preference· 386

if-match route-type· 386

if-match tag· 387

ip as-path· 388

ip community-list 389

ip extcommunity-list 390

route-policy· 391

IPv4 routing policy commands· 392

apply fast-reroute· 392

apply ip-address next-hop· 393

display ip prefix-list 393

if-match ip· 394

ip prefix-list 395

reset ip prefix-list 396

Index· 398


Basic IP routing commands

The term "interface" in the routing features collectively refers to Layer 3 interfaces, including VLAN interfaces and Layer 3 Ethernet interfaces. You can set an Ethernet port as a Layer 3 interface by using the port link-mode route command (see Layer 2—LAN Switching Configuration Guide).

address-family ipv4

Use address-family ipv4 to create a RIB IPv4 address family and enter RIB IPv4 address family view.

Use undo address-family ipv4 to remove a RIB IPv4 address family and all configurations in the view.

Syntax

address-family ipv4

undo address-family ipv4

Default

No RIB IPv4 address family is created.

Views

RIB view

Predefined user roles

network-admin

mdc-admin

Examples

# Create a RIB IPv4 address family and enter RIB IPv4 address family view.

<Sysname> system-view

[Sysname] rib

[Sysname-rib] address-family ipv4

[Sysname-rib-ipv4]

display ecmp mode

Use display ecmp mode to display the ECMP mode.

Syntax

display ecmp mode

Views

Any view

Predefined user roles

network-admin

network-operator

mdc-admin

mdc-operator

Examples

# Display the ECMP mode.

<Sysname> display ecmp mode

  ECMP-mode in use: Default

  ECMP-mode at the next reboot: Enhanced

display ip routing-table

Use display ip routing-table to display routing table information.

Syntax

In standalone mode:

display ip routing-table [ vpn-instance vpn-instance-name ] [ verbose ] [ standby slot slot-number ]

In IRF mode:

display ip routing-table [ vpn-instance vpn-instance-name ] [ verbose ] [ standby chassis chassis-number slot slot-number ]

Views

Any view

Predefined user roles

network-admin

network-operator

mdc-admin

mdc-operator

Parameters

vpn-instance vpn-instance-name: Specifies an MPLS L3VPN instance by its name, a case-sensitive string of 1 to 31 characters. Without this option, the command displays the routing table information for the public network.

verbose: Displays detailed routing table information, including information about both active and inactive routes. Without this keyword, the command displays only brief information about active routes.

standby slot slot-number: Displays backup routing table information for a card. Without this option, the command displays routing table information. (In standalone mode.)

standby chassis chassis-number slot slot-number: Displays backup routing table information for a card on an IRF member device. The chassis-number argument specifies the ID of the IRF member device. The slot-number argument specifies the slot number of the card. Without this option, the command displays routing table information. (In IRF mode.)

Examples

# Display brief information about active routes in the routing table.

<Sysname> display ip routing-table

 

         Destinations : 13        Routes : 13

 

Destination/Mask    Proto  Pre  Cost         NextHop         Interface

0.0.0.0/32          Direct 0    0            127.0.0.1       InLoop0

1.1.1.0/24          Static 60   0            192.168.47.4    Vlan1

127.0.0.0/8         Direct 0    0            127.0.0.1       InLoop0

127.0.0.0/32        Direct 0    0            127.0.0.1       InLoop0

127.0.0.1/32        Direct 0    0            127.0.0.1       InLoop0

127.255.255.255/32  Direct 0    0            127.0.0.1       InLoop0

192.168.1.0/24      Direct 0    0            192.168.1.40    Vlan11

192.168.1.0/32      Direct 0    0            192.168.1.40    Vlan11

192.168.1.40/32     Direct 0    0            127.0.0.1       InLoop0

192.168.1.255/32    Direct 0    0            192.168.1.40    Vlan11

224.0.0.0/4         Direct 0    0            0.0.0.0         NULL0

224.0.0.0/24        Direct 0    0            0.0.0.0         NULL0

255.255.255.255/32  Direct 0    0            127.0.0.1       InLoop0

Table 1 Command output

Field

Description

Destinations

Number of destination addresses.

Routes

Number of routes.

Destination/Mask

Destination address/mask length.

Proto

Protocol that installed the route. The following route types are available:

·     O_INTRA—OSPF intra-area route.

·     O_INTER—OSPF inter-area route.

·     O_ASE1—OSPF external Type-1 route.

·     O_ASE2—OSPF external Type-2 route.

·     O_NSSA1—OSPF NSSA external Type-1 route.

·     O_NSSA2—OSPF NSSA external Type-2 route.

·     O_SUM—OSPF summary route.

·     IS_L1—IS-IS Level-1 route.

·     IS_L2—IS-IS Level-2 route.

·     IS_SUM—IS-IS summary route.

Pre

Preference of the route.

Cost

Cost of the route.

NextHop

Next hop address of the route.

Interface

Output interface for packets to be forwarded along the route.

Summary Count

Number of routes.

 

# Display detailed information about all routes in the routing table.

<Sysname> display ip routing-table verbose

 

         Destinations : 13        Routes : 13

 

Destination: 0.0.0.0/32

   Protocol: Direct          Process ID: 0

  SubProtID: 0x0                    Age: 08h34m37s

       Cost: 0               Preference: 0

      IpPre: N/A             QosLocalID: N/A

        Tag: 0                    State: Active NoAdv

  OrigTblID: 0x0                OrigVrf: default-vrf

    TableID: 0x2                 OrigAs: 0

      NibID: 0x10000000          LastAs: 0

     AttrID: 0xffffffff        Neighbor: 0.0.0.0

      Flags: 0x1000c        OrigNextHop: 127.0.0.1

      Label: NULL           RealNextHop: 127.0.0.1

    BkLabel: NULL             BkNextHop: N/A

  Tunnel ID: Invalid          Interface: InLoopBack0

BkTunnel ID: Invalid        BkInterface: N/A

 

Destination: 1.1.1.0/24

   Protocol: Static          Process ID: 0

  SubProtID: 0x0                    Age: 04h20m37s

       Cost: 0               Preference: 60

      IpPre: N/A             QosLocalID: N/A

        Tag: 0                    State: Active Adv

  OrigTblID: 0x0                OrigVrf: default-vrf

    TableID: 0x2                 OrigAs: 0

      NibID: 0x10000003          LastAs: 0

     AttrID: 0xffffffff        Neighbor: 0.0.0.0

      Flags: 0x1008c        OrigNextHop: 192.168.47.4

      Label: NULL           RealNextHop: 192.168.47.4

    BkLabel: NULL             BkNextHop: N/A

  Tunnel ID: Invalid          Interface: Vlan-interface1

BkTunnel ID: Invalid        BkInterface: N/A

 

...

Table 2 Command output

Field

Description

Destinations

Number of destination addresses.

Routes

Number of routes.

Destination

Destination address/mask length.

Protocol

Protocol that installed the route.

SubProtID

ID of the subprotocol for routing.

Age

Time for which the route has been in the routing table.

Cost

Cost of the route.

Preference

Preference of the route.

QosLocalID

Local QoS ID.

Tag

Route tag.

State

Route status:

·     Active—Active unicast route.

·     Adv—Route that can be advertised.

·     Inactive—Inactive route.

·     NoAdv—Route that the router must not advertise.

·     Vrrp—Routes generated by VRRP.

·     Nat—Routes generated by NAT.

·     TunE—Tunnel.

OrigTblID

Original routing table ID.

OrigVrf

Original VPN that the route belongs to.

TableID

ID of the routing table.

OrigAs

Original AS number.

NibID

ID of the next hop.

LastAs

Last AS number.

AttrID

Attribute ID.

Neighbor

Address of the neighbor determined by the routing protocol.

Flags

Flags of the route.

OrigNextHop

Next hop address of the route.

RealNextHop

Real next hop of the route.

BkLabel

Backup label.

BkNexthop

Backup next hop.

Interface

Output interface for packets to be forwarded along the route.

BkTunnel ID

Backup tunnel ID.

BkInterface

Backup output interface.

 

display ip routing-table acl

Use display ip routing-table acl to display information about routes permitted by a basic ACL.

Syntax

In standalone mode:

display ip routing-table [ vpn-instance vpn-instance-name ] acl acl-number [ verbose ] [ standby slot slot-number ]

In IRF mode:

display ip routing-table [ vpn-instance vpn-instance-name ] acl acl-number [ verbose ] [ standby chassis chassis-number slot slot-number ]

Views

Any view

Predefined user roles

network-admin

network-operator

mdc-admin

mdc-operator

Parameters

vpn-instance vpn-instance-name: Specifies an MPLS L3VPN instance by its name, a case-sensitive string of 1 to 31 characters. Without this option, the command displays routing information for the public network.

acl-number: Specifies a basic ACL by its number in the range of 2000 to 2999.

verbose: Displays detailed information about all routes permitted by the basic ACL. Without this keyword, the command displays only brief information about active routes permitted by the basic ACL.

standby slot slot-number: Displays backup information about routes permitted by the basic ACL for a card. Without this option, the command displays information about routes permitted by the basic ACL. (In standalone mode.)

standby chassis chassis-number slot slot-number: Displays backup information about routes permitted by the basic ACL for a card on an IRF member device. The chassis-number argument specifies the ID of the IRF member device. The slot-number argument specifies the slot number of the card. Without this option, the command displays information about routes permitted by the basic ACL. (In IRF mode.)

Usage guidelines

If the specified ACL does not exist or has no rules configured, the command displays information about all routes.

Examples

# Define basic ACL 2000 and set the route filtering rules.

<Sysname> system-view

[Sysname] acl number 2000

[Sysname-acl-basic-2000] rule permit source 192.168.1.0 0.0.0.255

[Sysname-acl-basic-2000] rule deny source any

# Display brief information about active routes permitted by basic ACL 2000.

[Sysname-acl-basic-2000] display ip routing-table acl 2000

 

Routes Matched by Access control list : 2000

Summary Count : 4

 

Destination/Mask    Proto  Pre  Cost         NextHop         Interface

192.168.1.0/24      Direct 0    0            192.168.1.111   Vlan 1

192.168.1.0/32      Direct 0    0            192.168.1.111   Vlan 1

192.168.1.111/32    Direct 0    0            127.0.0.1       InLoop0

192.168.1.255/32    Direct 0    0            192.168.1.111   Vlan 1

For command output, see Table 1.

# Display detailed information about all routes permitted by basic ACL 2000.

<Sysname> display ip routing-table acl 2000 verbose

 

Routes Matched by Access control list : 2000

Summary Count : 4

 

Destination: 192.168.1.0/24

   Protocol: Direct          Process ID: 0

  SubProtID: 0x1                    Age: 04h20m37s

       Cost: 0               Preference: 0

        Tag: 0                    State: Active Adv

  OrigTblID: 0x0                OrigVrf: default-vrf

    TableID: 0x2                 OrigAs: 0

      NibID: 0x10000003          LastAs: 0

     AttrID: 0xffffffff        Neighbor: 0.0.0.0

      Flags: 0x10080        OrigNextHop: 192.168.1.111

      Label: NULL           RealNextHop: 192.168.1.111

    BkLabel: NULL             BkNextHop: N/A

  Tunnel ID: Invalid          Interface: Vlan-interface1

BkTunnel ID: Invalid        BkInterface: N/A

 

Destination: 192.168.1.0/32

   Protocol: Direct          Process ID: 0

  SubProtID: 0x0                    Age: 04h20m37s

       Cost: 0               Preference: 0

        Tag: 0                    State: Active NoAdv

  OrigTblID: 0x0                OrigVrf: default-vrf

    TableID: 0x2                 OrigAs: 0

      NibID: 0x10000003          LastAs: 0

     AttrID: 0xffffffff        Neighbor: 0.0.0.0

      Flags: 0x1008c        OrigNextHop: 192.168.1.111

      Label: NULL           RealNextHop: 192.168.1.111

    BkLabel: NULL             BkNextHop: N/A

  Tunnel ID: Invalid          Interface: Vlan-interface1

BkTunnel ID: Invalid        BkInterface: N/A

 

Destination: 192.168.1.111/32

   Protocol: Direct          Process ID: 0

  SubProtID: 0x1                    Age: 04h20m37s

       Cost: 0               Preference: 0

        Tag: 0                    State: Active NoAdv

  OrigTblID: 0x0                OrigVrf: default-vrf

    TableID: 0x2                 OrigAs: 0

      NibID: 0x10000000          LastAs: 0

     AttrID: 0xffffffff        Neighbor: 0.0.0.0

      Flags: 0x10004        OrigNextHop: 127.0.0.1

      Label: NULL           RealNextHop: 127.0.0.1

    BkLabel: NULL             BkNextHop: N/A

  Tunnel ID: Invalid          Interface: InLoopBack0

BkTunnel ID: Invalid        BkInterface: N/A

   FtnIndex: 0x0

 

Destination: 192.168.1.255/32

   Protocol: Direct          Process ID: 0

  SubProtID: 0x0                    Age: 04h20m37s

       Cost: 0               Preference: 0

        Tag: 0                    State: Active NoAdv

  OrigTblID: 0x0                OrigVrf: default-vrf

    TableID: 0x2                 OrigAs: 0

      NibID: 0x10000003          LastAs: 0

     AttrID: 0xffffffff        Neighbor: 0.0.0.0

      Flags: 0x1008c        OrigNextHop: 192.168.1.111

      Label: NULL           RealNextHop: 192.168.1.111

    BkLabel: NULL             BkNextHop: N/A

  Tunnel ID: Invalid          Interface: Vlan-interface1

BkTunnel ID: Invalid        BkInterface: N/A

For command output, see Table 2.

display ip routing-table ip-address

Use display ip routing-table ip-address to display information about routes to a specific destination address.

Use display ip routing-table ip-address1 to ip-address2 to display information about routes to a range of destination addresses.

Syntax

In standalone mode:

display ip routing-table [ vpn-instance vpn-instance-name ] ip-address [ mask | mask-length ] [ longer-match ] [ verbose ] [ standby slot slot-number ]

display ip routing-table [ vpn-instance vpn-instance-name ] ip-address1 to ip-address2 [ verbose ] [ standby slot slot-number ]

In IRF mode:

display ip routing-table [ vpn-instance vpn-instance-name ] ip-address [ mask | mask-length ] [ longer-match ] [ verbose ] [ standby chassis chassis-number slot slot-number ]

display ip routing-table [ vpn-instance vpn-instance-name ] ip-address1 to ip-address2 [ verbose ] [ standby chassis chassis-number slot slot-number ]

Views

Any view

Predefined user roles

network-admin

network-operator

mdc-admin

mdc-operator

Parameters

vpn-instance vpn-instance-name: Specifies an MPLS L3VPN instance by its name, a case-sensitive string of 1 to 31 characters. Without this option, the command displays routing information for the public network.

ip-address: Specifies a destination IP address in dotted decimal notation.

mask: Specifies the IP address mask in dotted decimal notation.

mask-length: Specifies the mask length, an integer in the range of 0 to 32.

longer-match: Displays the route entry with the longest mask.

ip-address1 to ip-address2: Specifies a destination IP address range.

verbose: Displays detailed routing table information, including information about both active and inactive routes. Without this keyword, the command displays brief information about active routes.

standby slot slot-number: Displays backup information about routes for a card. Without this option, the command displays information about routes. (In standalone mode.)

standby chassis chassis-number slot slot-number: Displays backup information about routes for a card on an IRF member device. The chassis-number argument specifies the ID of the IRF member device. The slot-number argument specifies the slot number of the card. Without this option, the command displays information about routes. (In IRF mode.)

Usage guidelines

Executing the command with different parameters yields different outputs:

·     display ip routing-table ip-address:

¡     The system ANDs the entered destination IP address with the subnet mask in each active route entry.

¡     The system ANDs the destination IP address in each active route entry with its own subnet mask.

If the two operations yield the same result for an entry, the entry is displayed.

·     display ip routing-table ip-address mask:

¡     The system ANDs the entered destination IP address with the entered subnet mask.

¡     The system ANDs the destination IP address in each active route entry with the entered subnet mask.

If the two operations yield the same result for an entry with a subnet mask not greater than the entered subnet mask, the entry is displayed.

·     display ip routing-table ip-address longer-match:

¡     The system ANDs the entered destination IP address with the subnet mask in each active route entry.

¡     The system ANDs the destination IP address in each active route entry with its own subnet mask.

If the two operations yield the same result for multiple entries, the entry with the longest mask length is displayed.

·     display ip routing-table ip-address mask longer-match:

¡     The system ANDs the entered destination IP address with the entered subnet mask.

¡     The system ANDs the destination IP address in each active route entry with the entered subnet mask.

If the two operations yield the same result for multiple entries with a mask not greater than the entered subnet mask, the entry with the longest mask length is displayed.

·     display ip routing-table ip-address1 to ip-address2:

The system displays active route entries with destinations in the range of ip-address1/32 to ip-address2/32.

Examples

# Display brief information about the routes to the destination IP address 11.0.0.1.

<Sysname> display ip routing-table 11.0.0.1

 

Summary Count : 3

 

Destination/Mask    Proto  Pre  Cost         NextHop         Interface

11.0.0.0/8          Static 60   0            0.0.0.0         NULL0

11.0.0.0/16         Static 60   0            0.0.0.0         NULL0

11.0.0.0/24         Static 60   0            0.0.0.0         NULL0

# Display brief information about the routes to the destination IP address 11.0.0.1 and mask length 20.

<Sysname> display ip routing-table 11.0.0.1 20

 

Summary Count : 2

 

Destination/Mask    Proto  Pre  Cost         NextHop         Interface

11.0.0.0/8          Static 60   0            0.0.0.0         NULL0

11.0.0.0/16         Static 60   0            0.0.0.0         NULL0

# Display brief information about the most specific route to the destination address 11.0.0.1.

<Sysname> display ip routing-table 11.0.0.1 longer-match

 

Summary Count : 1

 

Destination/Mask    Proto  Pre  Cost         NextHop         Interface

11.0.0.0/24         Static 60   0            0.0.0.0         NULL0

# Display brief information about the most specific route to the destination IP address 11.0.0.1 and mask length 20.

<Sysname> display ip routing-table 11.0.0.1 20 longer-match

 

Summary Count : 1

 

Destination/Mask    Proto  Pre  Cost         NextHop         Interface

11.0.0.0/16         Static 60   0            0.0.0.0         NULL0

# Display brief information about the routes to destination addresses in the range of 1.1.1.0 to 5.5.5.0.

<Sysname> display ip routing-table 1.1.1.0 to 5.5.5.0

 

Summary Count : 6

 

Destination/Mask    Proto  Pre  Cost         NextHop         Interface

1.1.1.1/32          Direct 0    0            127.0.0.1       InLoop0

2.2.2.0/24          Direct 0    0            2.2.2.1         Vlan2

3.3.3.0/24          Direct 0    0            3.3.3.1         Vlan2

3.3.3.1/32          Direct 0    0            127.0.0.1       InLoop0

4.4.4.0/24          Direct 0    0            4.4.4.1         Vlan1

4.4.4.1/32          Direct 0    0            127.0.0.1       InLoop0

For command output, see Table 1.

display ip routing-table prefix-list

Use display ip routing-table prefix-list to display routes permitted by an IP prefix list.

Syntax

In standalone mode:

display ip routing-table [ vpn-instance vpn-instance-name ] prefix-list prefix-list-name [ verbose ] [ standby slot slot-number ]

In IRF mode:

display ip routing-table [ vpn-instance vpn-instance-name ] prefix-list prefix-list-name [ verbose ] [ standby chassis chassis-number slot slot-number ]

Views

Any view

Predefined user roles

network-admin

network-operator

mdc-admin

mdc-operator

Parameters

vpn-instance vpn-instance-name: Specifies an MPLS L3VPN instance by its name, a case-sensitive string of 1 to 31 characters. Without this option, the command displays routing information for the public network.

prefix-list-name: Specifies an IP prefix list by its name, a case-sensitive string of 1 to 63 characters.

verbose: Displays detailed information about all routes permitted by the IP prefix list. Without this keyword, the command displays brief information about active routes permitted by the IP prefix list.

standby slot slot-number: Displays backup routes permitted by the IP prefix list for a card. Without this option, the command displays routes permitted by the IP prefix list. (In standalone mode.)

standby chassis chassis-number slot slot-number: Displays backup routes permitted by the IP prefix list for a card on an IRF member device. The chassis-number argument specifies the ID of the IRF member device. The slot-number argument specifies the slot number of the card. Without this option, the command displays routes permitted by the IP prefix list. (In IRF mode.)

Usage guidelines

If the specified IP prefix list does not exist, the command displays information about all routes.

Examples

# Create an IP prefix list named test to permit the route 1.1.1.0/24.

<Sysname> system-view

[Sysname] ip prefix-list test permit 1.1.1.0 24

# Display brief information about the active route permitted by the IP prefix list.

[Sysname] display ip routing-table prefix-list test

 

Routes Matched by Prefix list : test

Summary Count : 1

 

Destination/Mask    Proto  Pre  Cost         NextHop         Interface

1.1.1.0/24          Direct 0    0            1.1.1.2         Vlan 2

For command output, see Table 1.

# Display detailed information about all routes permitted by the IP prefix list.

[Sysname] display ip routing-table prefix-list test verbose

 

Routes Matched by Prefix list : test

Summary Count : 1

 

Destination: 1.1.1.0/24

   Protocol: Direct          Process ID: 0

  SubProtID: 0x1                    Age: 04h20m37s

       Cost: 0               Preference: 0

        Tag: 0                    State: Active Adv

  OrigTblID: 0x0                OrigVrf: default-vrf

    TableID: 0x2                 OrigAs: 0

      NibID: 0x10000003          LastAs: 0

     AttrID: 0xffffffff        Neighbor: 0.0.0.0

      Flags: 0x1008c        OrigNextHop: 1.1.1.2

      Label: NULL           RealNextHop: 1.1.1.2

    BkLabel: NULL             BkNextHop: N/A

  Tunnel ID: Invalid          Interface: Vlan-interface2

BkTunnel ID: Invalid        BkInterface: N/A

For command output, see Table 2.

display ip routing-table protocol

Use display ip routing-table protocol to display information about routes installed by a protocol.

Syntax

In standalone mode:

display ip routing-table [ vpn-instance vpn-instance-name ] protocol protocol [ inactive | verbose ] [ standby slot slot-number ]

In IRF mode:

display ip routing-table [ vpn-instance vpn-instance-name ] protocol protocol [ inactive | verbose ] [ standby chassis chassis-number slot slot-number ]

Views

Any view

Predefined user roles

network-admin

network-operator

mdc-admin

mdc-operator

Parameters

vpn-instance vpn-instance-name: Specifies MPLS L3VPN instance by its name, a case-sensitive string of 1 to 31 characters. Without this option, the command displays routing information for the public network.

protocol: Specifies a routing protocol. It can be bgp, direct, isis, ospf, rip, or static.

inactive: Displays information about inactive routes. Without this keyword, the command displays information about both active and inactive routes.

verbose: Displays detailed routing table information. Without this keyword, the command displays brief routing information.

standby slot slot-number: Displays backup information about routes installed by the protocol for a card. Without this option, the command displays information about routes installed by the protocol. (In standalone mode.)

standby chassis chassis-number slot slot-number: Displays backup information about routes installed by the protocol for a card on an IRF member device. The chassis-number argument specifies the ID of the IRF member device. The slot-number argument specifies the slot number of the card. Without this option, the command displays information about routes installed by the protocol. (In IRF mode.)

Examples

# Display brief information about direct routes.

<Sysname> display ip routing-table protocol direct

 

Summary Count : 13

 

Direct Routing Table Status : <Active>

Summary Count : 13

 

Destination/Mask    Proto  Pre  Cost         NextHop         Interface

0.0.0.0/32          Direct 0    0            127.0.0.1       InLoop0

2.2.2.0/24          Direct 0    0            2.2.2.1         Vlan2

2.2.2.0/32          Direct 0    0            2.2.2.1         Vlan2

2.2.2.2/32          Direct 0    0            127.0.0.1       InLoop0

2.2.2.255/32        Direct 0    0            2.2.2.1         Vlan2

127.0.0.0/8         Direct 0    0            127.0.0.1       InLoop0

127.0.0.0/32        Direct 0    0            127.0.0.1       InLoop0

127.0.0.1/32        Direct 0    0            127.0.0.1       InLoop0

127.255.255.255/32  Direct 0    0            127.0.0.1       InLoop0

192.168.80.0/24     Direct 0    0            192.168.80.10   Vlan 1

192.168.80.0/32     Direct 0    0            192.168.80.10   Vlan 1

192.168.80.10/32    Direct 0    0            127.0.0.1       InLoop0

192.168.80.255/32   Direct 0    0            192.168.80.10   Vlan 1

 

Direct Routing Table Status : <Inactive>

Summary Count : 0

# Display brief information about static routes.

<Sysname> display ip routing-table protocol static

 

Summary Count : 2

 

Static Routing Table Status : <Active>

Summary Count : 0

 

Static Routing Table Status : <Inactive>

Summary Count : 2

 

Destination/Mask    Proto  Pre  Cost         NextHop        Interface

1.2.3.0/24          Static 60   0            1.2.4.5        Vlan10

3.0.0.0/8           Static 60   0            2.2.2.2        Vlan 1

For command output, see Table 1.

display ip routing-table statistics

Use display ip routing-table statistics to display route statistics.

Syntax

In standalone mode:

display ip routing-table [ vpn-instance vpn-instance-name ] statistics [ standby slot slot-number ]

In IRF mode:

display ip routing-table [ vpn-instance vpn-instance-name ] statistics [ standby chassis chassis-number slot slot-number ]

Views

Any view

Predefined user roles

network-admin

network-operator

mdc-admin

mdc-operator

Parameters

vpn-instance vpn-instance-name: Specifies an MPLS L3VPN instance by its name, a case-sensitive string of 1 to 31 characters. Without this option, the command displays route statistics for the public network.

standby slot slot-number: Displays backup route statistics for a card. Without this option, the command displays route statistics. (In standalone mode.)

standby chassis chassis-number slot slot-number: Displays backup route statistics for a card on an IRF member device. The chassis-number argument specifies the ID of the IRF member device. The slot-number argument specifies the slot number of the card. Without this option, the command displays route statistics. (In IRF mode.)

Examples

# Display route statistics for the public network.

<Sysname> display ip routing-table statistics

 

Proto      route       active      added       deleted

DIRECT     12          12          30          18

STATIC     3           3           5           2

RIP        0           0           0           0

OSPF       0           0           0           0

ISIS       0           0           0           0

BGP        0           0           0           0

Total      15          15          35          20

Table 3 Command output

Field

Description

Proto

Protocol that installed the route.

route

Number of routes installed by the protocol.

active

Number of active routes.

added

Number of routes added to the routing table after the router started up or the routing table was cleared most recently.

deleted

Number of routes marked as deleted, which will be cleared after a period.

Total

Total number of routes.

 

display rib attribute

Use display rib attribute to display route attribute information in the RIB.

Syntax

In standalone mode:

display rib attribute [ attribute-id ] [ standby slot slot-number ]

In IRF mode:

display rib attribute [ attribute-id ] [ standby chassis chassis-number slot slot-number ]

Views

Any view

Predefined user roles

network-admin

network-operator

mdc-admin

mdc-operator

Parameters

attribute-id: Specifies a route attribute by its ID in the range of 0 to FFFFFFFF.

standby slot slot-number: Displays backup route attribute information in the RIB for a card. Without this option, the command displays route attribute information in the RIB. (In standalone mode.)

standby chassis chassis-number slot slot-number: Displays backup route attribute information in the RIB for a card on an IRF member device. The chassis-number argument specifies the ID of the IRF member device. The slot-number argument specifies the slot number of the card. Without this option, the command displays route attribute information in the RIB. (In IRF mode.)

Examples

# Display route attribute information in the RIB.

<Sysname> display rib attribute

Total number of attribute(s): 10

 

Detailed information of attribute 0x0:

                  Flag: 0x0

              Protocol: BGP

        Address family: IPv4

       Reference count: 0

      Local preference: 0

Ext-communities number: 26

 Ext-communities value: <RT: 1:1> <RT: 2:2> <RT: 3:3> <RT: 123.123.123.123:65535

                        > <RT: 1234567890:65535> <RT: 123.123.123.123:65534> <RT

                        : 4:4> <RT: 5:5> <RT: 6:6> <RT: 7:7> <RT: 8:8> <RT: 9:9>

                         <RT: 10:10> <RT: 10:1> <RT: 10:11> <RT: 10:12> <RT: 10:

                        13> <RT: 10:14> <RT: 10:15> <RT: 10:16> ...

    Communities number: 0

     Communities value: N/A

        AS-path number: 0

         AS-path value: N/A

 

Detailed information of attribute 0x1:

                  Flag: 0x0

              Protocol: BGP

        Address family: IPv4

       Reference count: 0

      Local preference: 0

Ext-communities number: 1

 Ext-communities value: <RT: 1:2>

    Communities number: 0

     Communities value: N/A

        AS-path number: 0

         AS-path value: N/A

Table 4 Command output

Field

Description

Protocol

Protocol that generates the attribute.

Ext-communities number

Number of the extended community attribute values.

Ext-communities value

Values of the extended community attribute. This field displays N/A when no values exist, and it can display up to 20 values.

Communities number

Number of the COMMUNITY attribute values.

Communities value

Values of the COMMUNITY attribute. This field displays N/A when no values exist, and it can display up to 20 values.

AS-path number

Number of ASs in the AS_PATH attribute.

AS-path value

Values of the AS_PATH attribute, including AS_SET, AS_SEQUENCE, confederation AS_SET, and confederation AS_SEQUENCE. This field displays N/A when no values exist, and it can display up to 20 values.

 

display rib graceful-restart

Use display rib graceful-restart to display RIB GR state information.

Syntax

display rib graceful-restart

Views

Any view

Predefined user roles

network-admin

network-operator

mdc-admin

mdc-operator

Examples

# Display RIB GR state information.

<Sysname> display rib graceful-restart

RIB GR state     : Phase2-calculation end

RCOM GR State    : Flush end

Protocol GR state:

 No.  Protocol   Lifetime FD   State    Start/End

--------------------------------------------------

 1    DIRECT     100      30   End      No/No

 2    STATIC     480      34   End      No/No

 3    OSPF       480      36   End      No/No

 4    ISIS       480      32   End      No/No

 5    BGP        480      31   End      No/No

 6    LDP        480      35   End      No/No

 7    SLSP       480      29   End      No/No

Table 5 Command output

Field

Description

RIB GR state

RIB GR status:

·     Start—GR starts.

·     IGP end—All IGP protocols complete GR.

·     VPN-triggering end—Optimal route selection triggered by VPN routes completes.

·     VPN-calculation end—Optimal VPN route selection completes.

·     Routing protocol end—All routing protocols complete GR.

·     Triggering start—All triggered optimal route selection starts.

·     Triggering end—All triggered optimal route selection completes.

·     Phase1-calculation end—Optimal route selection phase 1 completes.

·     All end—All protocols complete GR.

·     Phase2-calculation end—Optimal route selection phase 2 completes.

RCOM GR state

RCOM GR status:

·     Start—GR starts.

·     VPN-calculation end—Optimal VPN route selection completes.

·     VPN-notification end—VPN routes have been delivered to the route management module.

·     Routing protocol end—All routing protocols complete GR.

·     Phase1-calculation end—Optimal route selection phase 1 completes.

·     Notification end—All routes have been delivered to the route management module.

·     Phase2-calculation end—Optimal route selection phase 2 completes.

·     Flush start—Starts to flush routes to the FIB.

·     Flush end—Completes flushing routes to the FIB.

No.

Protocol number.

Lifetime

Lifetime (in seconds) of routes/labels in the RIB during GR.

FD

Handle between the protocol and the RIB.

State

Protocol GR state:

·     InitInitialization state.

·     ListenListening state.

·     Idle.

·     Active.

·     StartGR starts.

·     EndGR completes.

Start/End

Message sending state:

·     No—The message has not been sent.

·     Yes—The message has been sent.

 

display rib nib

Use display rib nib to display next hop information in the RIB.

Syntax

In standalone mode:

display rib nib [ self-originated ] [ nib-id ] [ verbose ] [ standby slot slot-number ]

display rib nib protocol protocol-name [ verbose ] [ standby slot slot-number ]

In IRF mode:

display rib nib [ self-originated ] [ nib-id ] [ verbose ] [ standby chassis chassis-number slot slot-number ]

display rib nib protocol protocol-name [ verbose ] [ standby chassis chassis-number slot slot-number ]

Views

Any view

Predefined user roles

network-admin

network-operator

mdc-admin

mdc-operator

Parameters

self-originated: Displays information about next hops of self-originated routes in the RIB.

nib-id: Specifies a NIB by its ID in the range of 1 to FFFFFFFF.

verbose: Displays detailed next hop information in the RIB. Without this keyword, the command displays brief next hop information in the RIB.

protocol protocol-name: Specifies a protocol by its name, which can be bgp, direct, isis, ospf, rip, or static.

standby slot slot-number: Displays backup next hop information in the RIB for a card. Without this option, the command displays next hop information in the RIB. (In standalone mode.)

standby chassis chassis-number slot slot-number: Displays backup next hop information in the RIB for a card on an IRF member device. The chassis-number argument specifies the ID of the IRF member device. The slot-number argument specifies the slot number of the card. Without this option, the command displays next hop information in the RIB. (In IRF mode.)

Examples

# Display brief next hop information in the RIB.

<Sysname> display rib nib

Total number of nexthop(s): 176

 

      NibID: 0x10000000        Sequence: 0

       Type: 0x1                Flushed: Yes

   UserKey0: 0x0                VrfNthp: 1

   UserKey1: 0x0                Nexthop: 0.0.0.0

    IFIndex: 0x111            LocalAddr: 0.0.0.0

 

      NibID: 0x10000001        Sequence: 1

       Type: 0x1                Flushed: Yes

   UserKey0: 0x0                VrfNthp: 1

   UserKey1: 0x0                Nexthop: 127.0.0.1

    IFIndex: 0x112            LocalAddr: 127.0.0.1

 

      NibID: 0x10000002        Sequence: 2

       Type: 0x5                Flushed: Yes

   UserKey0: 0x0                VrfNthp: 1

   UserKey1: 0x0                Nexthop: 127.0.0.1

    IFIndex: 0x112            LocalAddr: 127.0.0.1

 

      NibID: 0x26000000        Sequence: 42

       Type: 0x2000             Flushed: Yes

   SubNibID: 0x21000023          SubSeq: 35

    NthpCnt: 1                    Samed: 0

   NthpType: IP

   SubNibID: 0x21000003          SubSeq: 36

    NthpCnt: 1                    Samed: 0

   NthpType: IP

   SubNibID: 0x21000004          SubSeq: 37

    NthpCnt: 1                    Samed: 0

   NthpType: IP

   SubNibID: 0x21000005          SubSeq: 38

    NthpCnt: 1                    Samed: 0

   NthpType: IP

 

...

Table 6 Command output

Field

Description

NibID

ID of the next hop.

Sequence

Sequence number of the next hop.

Type

Type of the next hop.

Flushed

Indicates whether the route with the next hop has been flushed to the FIB.

UserKey0

Reserved data 1.

UserKey1

Reserved data 2.

VrfNthp

VPN to which the next hop belongs.

Nexthop

Next hop address.

IFIndex

Interface index.

LocalAddr

Local interface address.

SubNibID

ID of the sub-next hop.

SubSeq

Sequence number of the sub-next hop.

NthpCnt

Number of sub-next hops.

Samed

Number of the same sub-next hops.

NthpType

Type of the sub-next hop:

·     IPIP forwarding.

·     MPLSMPLS forwarding.

 

# Display detailed next hop information in the RIB.

<Sysname> display rib nib verbose

Total number of nexthop(s): 176

 

      NibID: 0x10000000        Sequence: 0

       Type: 0x1                Flushed: Yes

   UserKey0: 0x0                VrfNthp: 1

   UserKey1: 0x0                Nexthop: 0.0.0.0

    IFIndex: 0x111            LocalAddr: 0.0.0.0

     RefCnt: 6              FlushRefCnt: 2

       Flag: 0x84               Version: 1

 1 nexthop(s):

PrefixIndex: 0              OrigNexthop: 0.0.0.0

  RelyDepth: 0              RealNexthop: 0.0.0.0

  Interface: NULL0            LocalAddr: 0.0.0.0

  TunnelCnt: 0                      Vrf: vpn1

   TunnelID: N/A

 

      NibID: 0x10000001        Sequence: 1

       Type: 0x1                Flushed: Yes

   UserKey0: 0x0                VrfNthp: 1

   UserKey1: 0x0                Nexthop: 127.0.0.1

    IFIndex: 0x112            LocalAddr: 127.0.0.1

     RefCnt: 13             FlushRefCnt: 5

       Flag: 0x84               Version: 1

 1 nexthop(s):

PrefixIndex: 0              OrigNexthop: 127.0.0.1

  RelyDepth: 0              RealNexthop: 127.0.0.1

  Interface: InLoop0          LocalAddr: 127.0.0.1

  TunnelCnt: 0                      Vrf: vpn1

   TunnelID: N/A

 

      NibID: 0x15000003        Sequence: 3

       Type: 0x43               Flushed: Yes

   UserKey0: 0x100010000        VrfNthp: 0

   UserKey1: 0x0                Nexthop: 22.22.22.22

    IFIndex: 0x0              LocalAddr: 0.0.0.0

     RefCnt: 9              FlushRefCnt: 3

       Flag: 0x84               Version: 1

     Policy: tnl-policy1

 1 nexthop(s):

PrefixIndex: 0              OrigNexthop: 22.22.22.22

  RelyDepth: 1              RealNexthop: 13.1.1.2

  Interface: GE0/1/3          LocalAddr: 13.1.1.1

  TunnelCnt: 1                      Vrf: default-vrf

   TunnelID: 1025

 

      NibID: 0x16000000        Sequence: 0

       Type: 0x2000             Flushed: Yes

   SubNibID: 0x11000009          SubSeq: 13

    NthpCnt: 1                    Samed: 0

   NthpType: IP

   SubNibID: 0x1100000d          SubSeq: 14

    NthpCnt: 1                    Samed: 0

   NthpType: IP

 2 nexthop(s):

PrefixIndex: 0              OrigNexthop: 10.1.1.2

  RelyDepth: 0              RealNexthop: 10.1.1.2

  Interface: Vlan10           LocalAddr: 10.1.1.1

  TunnelCnt: 0                      Vrf: default-vrf

   TunnelID: N/A

PrefixIndex: 1              OrigNexthop: 11.1.1.2

  RelyDepth: 0              RealNexthop: 11.1.1.2

  Interface: Vlan11           LocalAddr: 11.1.1.1

  TunnelCnt: 0                      Vrf: default-vrf

   TunnelID: N/A

 

...

Table 7 Command output

Field

Description

Policy

Tunnel policy name.

x nexthop (s)

Number of next hops.

PrefixIndex

Prefix index of the next hop for an ECMP route.

Vrf

VPN name.

OrigNexthop

Original next hop.

RealNexthop

Real next hop.

Interface

Output interface.

LocalAddr

Local interface address.

RelyDepth

Recursion depth.

TunnelCnt

Number of tunnels after route recursion.

TunnelID

ID of the tunnel after route recursion.

RefCnt

Reference count of the next hop.

FlushRefCnt

Reference count of the next hop that is flushed to the FIB.

Flag

Flag of the next hop.

Version

Version of the next hop.

 

display route-direct nib

Use display route-direct nib to display next hop information for direct routes.

Syntax

display route-direct nib [ nib-id ] [ verbose ]

Views

Any view

Predefined user roles

network-admin

network-operator

mdc-admin

mdc-operator

Parameters

nib-id: Specifies a NIB by its ID in the range of 1 to FFFFFFFF.

verbose: Displays detailed next hop information for direct routes. Without this keyword, the command displays brief next hop information for direct routes.

Examples

# Display brief next hop information for direct routes.

<Sysname> display route-direct nib

Total number of nexthop(s): 116

 

      NibID: 0x10000000        Sequence: 0

       Type: 0x1                Flushed: Yes

   UserKey0: 0x0                VrfNthp: 1

   UserKey1: 0x0                Nexthop: 0.0.0.0

    IFIndex: 0x111            LocalAddr: 0.0.0.0

 

      NibID: 0x10000001        Sequence: 1

       Type: 0x1                Flushed: Yes

   UserKey0: 0x0                VrfNthp: 1

   UserKey1: 0x0                Nexthop: 127.0.0.1

    IFIndex: 0x112            LocalAddr: 127.0.0.1

 

...

Table 8 Command output

Field

Description

NibID

ID of the NIB.

Sequence

Sequence number of the NIB.

Type

Type of the NIB.

Flushed

Indicates whether the route with the NIB has been flushed to the FIB.

UserKey0

Reserved data 1.

UserKey1

Reserved data 2.

VrfNthp

VPN to which the next hop belongs.

Nexthop

Next hop address.

IFIndex

Interface index.

 

# Display detailed next hop information for direct routes.

<Sysname> display route-direct nib verbose

Total number of nexthop(s): 116

 

      NibID: 0x10000000        Sequence: 0

       Type: 0x1                Flushed: Yes

   UserKey0: 0x0                VrfNthp: 1

   UserKey1: 0x0                Nexthop: 0.0.0.0

    IFIndex: 0x111            LocalAddr: 0.0.0.0

     RefCnt: 2              FlushRefCnt: 0

       Flag: 0x2                Version: 1

 1 nexthop(s):

PrefixIndex: 0              OrigNexthop: 0.0.0.0

  RelyDepth: 0              RealNexthop: 0.0.0.0

  Interface: NULL0            LocalAddr: 0.0.0.0

  TunnelCnt: 0                      Vrf: vpn1

   TunnelID: N/A

 

      NibID: 0x10000001        Sequence: 1

       Type: 0x1                Flushed: Yes

   UserKey0: 0x0                VrfNthp: 1

   UserKey1: 0x0                Nexthop: 127.0.0.1

    IFIndex: 0x112            LocalAddr: 127.0.0.1

     RefCnt: 5              FlushRefCnt: 0

       Flag: 0x2                Version: 1

 1 nexthop(s):

PrefixIndex: 0              OrigNexthop: 127.0.0.1

  RelyDepth: 0              RealNexthop: 127.0.0.1

  Interface: InLoop0          LocalAddr: 127.0.0.1

  TunnelCnt: 0                      Vrf: vpn1

   TunnelID: N/A

...

Table 9 Command output

Field

Description

x nexthop(s)

Number of next hops.

PrefixIndex

Prefix index of the next hop for an ECMP route.

Vrf

VPN name.

OrigNexthop

Original next hop.

RealNexthop

Real next hop.

Interface

Output interface.

localAddr

Local interface address.

RelyDepth

Recursion depth.

TunnelCnt

Number of tunnels after route recursion.

TunnelID

ID of the tunnel after route recursion.

RefCnt

Reference count of the next hop.

FlushRefCnt

Reference count of the next hop that is flushed to the FIB.

Flag

Flag of the next hop.

Version

Version of the next hop.

 

ecmp mode enhanced

Use ecmp mode enhanced to enable the enhanced ECMP mode.

Use undo ecmp mode to restore the default.

Syntax

ecmp mode enhanced

undo ecmp mode

Default

The enhanced ECMP mode is disabled.

Views

System view

Predefined user roles

network-admin

mdc-admin

Examples

# Enable the enhanced ECMP mode.

<Sysname> system-view

[Sysname] ecmp mode enhanced

The configuration will take effect at the next reboot. Continue? [Y/N]:y

Reboot device to make the configuration take effect.

fib lifetime

Use fib lifetime to set the maximum lifetime for routes in the FIB.

Use undo fib lifetime to restore the default.

Syntax

fib lifetime seconds

undo fib lifetime

Default

The maximum lifetime for routes in the FIB is 600 seconds.

Views

RIB IPv4 address family view

Predefined user roles

network-admin

mdc-admin

Parameters

second: Specifies the maximum lifetime for routes in the FIB, in the range of 0 to 900 seconds. When this argument is set to 0, FIB entries immediately age out after a protocol or RIB process switchover.

Usage guidelines

When a protocol or RIB process switchover occurs and GR or NSR is not configured, FIB entries age out after the time specified in this command.

Examples

# Set the maximum lifetime for routes in the FIB to 60 seconds.

<Sysname> system-view

[Sysname] rib

[Sysname-rib] address-family ipv4

[Sysname-rib-ipv4] fib lifetime 60

protocol lifetime

Use protocol lifetime to set the maximum lifetime for routes and labels in the RIB.

Use undo protocol lifetime to restore the default.

Syntax

protocol protocol lifetime seconds

undo protocol protocol lifetime

Default

The maximum lifetime for routes and labels in the RIB is 480 seconds.

Views

RIB IPv4 address family view

Predefined user roles

network-admin

mdc-admin

Parameters

seconds: Specifies the maximum lifetime for routes and labels in the RIB, in the range of 0 to 900 seconds. When this argument is set to 0, RIB entries immediately age out after a protocol switchover.

Usage guidelines

When GR is enabled, make sure the protocol can complete GR and install all route entries to the RIB within the lifetime configured in this command.

Examples

# Set the maximum lifetime for OSPF routes and labels in the RIB to 60 seconds.

<Sysname> system-view

[Sysname] rib

[Sysname-rib] address-family ipv4

[Sysname-rib-ipv4] protocol ospf lifetime 60

reset ip routing-table statistics protocol

Use reset ip routing-table statistics protocol to clear route statistics.

Syntax

In standalone mode:

reset ip routing-table statistics protocol [ vpn-instance vpn-instance-name ] { protocol | all } [ standby slot slot-number ]

In IRF mode:

reset ip routing-table statistics protocol [ vpn-instance vpn-instance-name ] { protocol | all } [ standby chassis chassis-number slot slot-number ]

Views

User view

Predefined user roles

network-admin

mdc-admin

Parameters

vpn-instance vpn-instance-name: Clears the route statistics for an MPLS L3VPN instance specified by its name, a case-sensitive string of 1 to 31 characters. Without this option, the command clears route statistics for the public network.

protocol: Clears route statistics for a routing protocol. It can be bgp, direct, isis, ospf, rip, or static.

all: Clears route statistics for all routing protocols.

standby slot slot-number: Clears backup route statistics for a card. Without this option, the command clears route statistics. (In standalone mode.)

standby chassis chassis-number slot slot-number: Clears backup route statistics for a card on an IRF member device. The chassis-number argument specifies the ID of the IRF member device. The slot-number argument specifies the slot number of the card. Without this option, the command clears route statistics. (In IRF mode.)

Examples

# Clear all route statistics for the public network.

<Sysname> reset ip routing-table statistics protocol all

rib

Use rib to enter RIB view.

Use undo rib to remove all configurations in RIB view.

Syntax

rib

undo rib

Views

System view

Predefined user roles

network-admin

mdc-admin

Examples

# Enter RIB view.

<Sysname> system-view

[Sysname] rib

[Sysname-rib]

 


Static routing commands

delete static-routes all

Use delete static-routes all to delete all static routes.

Syntax

delete [ vpn-instance vpn-instance-name ] static-routes all

Views

System view

Predefined user roles

network-admin

mdc-admin

Parameters

vpn-instance vpn-instance-name: Specifies an MPLS L3VPN instance by its name, a case-sensitive string of 1 to 31 characters. Without this option, the command deletes all static routes for the public network.

Usage guidelines

When you use this command, the system will prompt you to confirm the operation before deleting all the static routes.

To delete one static route, use the undo ip route-static command. To delete all static routes, including the default route, use the delete static-routes all command.

Examples

# Delete all static routes.

<Sysname> system-view

[Sysname] delete static-routes all

This will erase all IPv4 static routes and their configurations, you must reconfigure all static routes.

Are you sure?[Y/N]:y

Related commands

ip route-static

display route-static nib

Use display route-static nib to display static route next hop information.

Syntax

display route-static nib [ nib-id ] [ verbose ]

Views

Any view

Predefined user roles

network-admin

network-operator

mdc-admin

mdc-operator

Parameters

nib-id: Specifies a NIB by its ID in the range of 1 to FFFFFFFF.

verbose: Displays detailed static route next hop information. Without this keyword, the command displays brief static route next hop information.

Examples

# Displays brief static route next hop information.

<Sysname> display route-static nib

Total number of nexthop(s): 44

 

      NibID: 0x11000000        Sequence: 0

       Type: 0x21               Flushed: Yes

   UserKey0: 0x111              VrfNthp: 0

   UserKey1: 0x0                Nexthop: 0.0.0.0

    IFIndex: 0x111            LocalAddr: 0.0.0.0

 

      NibID: 0x11000001        Sequence: 1

       Type: 0x41               Flushed: Yes

   UserKey0: 0x0                VrfNthp: 5

   UserKey1: 0x0                Nexthop: 2.2.2.2

    IFIndex: 0x0              LocalAddr: 0.0.0.0

 

...

Table 10 Command output

Field

Description

NibID

ID of the NIB.

NibSeq

Sequence number of the NIB.

Type

Type of the NIB.

Flushed

Indicates whether the route with the NIB has been flushed to the FIB.

UserKey0

Reserved data 1.

UserKey1

Reserved data 2.

VrfNthp

VPN instance to which the next hop belongs.

Nexthop

Next hop address.

IFIndex

Interface index

LocalAddr

Local interface address.

 

# Displays detailed static route next hop information.

<Sysname> display route-static nib verbose

Total number of nexthop(s): 44

 

      NibID: 0x11000000        Sequence: 0

       Type: 0x21               Flushed: Yes

   UserKey0: 0x111              VrfNthp: 0

   UserKey1: 0x0                Nexthop: 0.0.0.0

    IFIndex: 0x111            LocalAddr: 0.0.0.0

     RefCnt: 2              FlushRefCnt: 0

       Flag: 0x2                Version: 1

 1 nexthop(s):

PrefixIndex: 0              OrigNexthop: 0.0.0.0

  RelyDepth: 0              RealNexthop: 0.0.0.0

  Interface: NULL0            LocalAddr: 0.0.0.0

  TunnelCnt: 0                      Vrf: default-vrf

   TunnelID: N/A

 

      NibID: 0x11000001        Sequence: 1

       Type: 0x41               Flushed: Yes

   UserKey0: 0x0                VrfNthp: 5

   UserKey1: 0x0                Nexthop: 2.2.2.2

    IFIndex: 0x0              LocalAddr: 0.0.0.0

     RefCnt: 1              FlushRefCnt: 0

       Flag: 0x12               Version: 1

 2 nexthop(s):

PrefixIndex: 0              OrigNexthop: 2.2.2.2

  RelyDepth: 7              RealNexthop: 8.8.8.8

  Interface: Dia0             LocalAddr: 12.12.12.12

  TunnelCnt: 0                      Vrf: default-vrf

   TunnelID: N/A

PrefixIndex: 0              OrigNexthop: 2.2.2.2

  RelyDepth: 9              RealNexthop: 0.0.0.0

  Interface: NULL0            LocalAddr: 0.0.0.0

  TunnelCnt: 0                      Vrf: default-vrf

   TunnelID: N/A

 

...

Table 11 Command output

Field

Description

x nexthop(s)

Number of next hops.

PrefixIndex

Prefix index of the next hop for an ECMP route.

Vrf

VPN name.

OrigNexthop

Original next hop.

RealNexthop

Real next hop.

Interface

Output interface.

localAddr

Local interface address.

RelyDepth

Recursion depth.

TunnelCnt

Number of tunnels after route recursion.

TunnelID

ID of the tunnel after route recursion.

RefCnt

Reference count of the next hop.

FlushRefCnt

Reference count of the next hop that is flushed to the FIB.

Flag

Flag of the next hop.

Version

Version of the next hop.

 

display route-static routing-table

Use display route-static routing-table to display static routing table information.

Syntax

display route-static routing-table [ vpn-instance vpn-instance-name ] [ ip-address { mask-length | mask } ]

Views

Any view

Predefined user roles

network-admin

network-operator

mdc-admin

mdc-operator

Parameters

vpn-instance vpn-instance-name: Specifies an MPLS L3VPN instance by its name, a case-sensitive string of 1 to 31 characters. Without this option, the command displays static routing table information for the public network.

ip-address: Specifies the destination IP address in dotted decimal notation.

mask-length/mask: Specifies the mask length or mask of the IP address. It must be an integer in the range of 0 to 32 or in dotted decimal notation.

Examples

# Display static routing table information.

<Sysname> display route-static routing-table

Total number of routes: 24

 

Status: * - valid

 

*Destination: 0.0.0.0/0

       NibID: 0x1100000a         NextHop: 2.2.2.10

   MainNibID: N/A              BkNextHop: N/A

     BkNibID: N/A              Interface: N/A

     TableID: 0x2            BkInterface: N/A

        Flag: 0x82d01           BfdSrcIp: N/A

     DbIndex: 0xd             BfdIfIndex: 0x0

        Type: Normal         BfdVrfIndex: 0

  TrackIndex: 0xffffffff           Label: NULL

  Preference: 60             vrfIndexDst: 0

     BfdMode: N/A             vrfIndexNH: 0

   Permanent: 0                      Tag: 0

 

Destination: 0.0.0.0/0

       NibID: 0x1100000b         NextHop: 2.2.2.11

   MainNibID: N/A              BkNextHop: N/A

     BkNibID: N/A              Interface: N/A

     TableID: 0x2            BkInterface: N/A

        Flag: 0x82d01           BfdSrcIp: N/A

     DbIndex: 0xd             BfdIfIndex: 0x0

        Type: Normal         BfdVrfIndex: 0

  TrackIndex: 0xffffffff           Label: NULL

  Preference: 60             vrfIndexDst: 0

     BfdMode: N/A             vrfIndexNH: 0

   Permanent: 0                      Tag: 0

 

...

# Display information about the static route with destination address 1.2.3.4/32.

<Sysname> display route-static routing-table 1.2.3.4 32

 

*Destination: 1.2.3.4/32

      NibID: 0x11000017         NextHop: 4.4.4.4

  MainNibID: 0x11000015       BkNextHop: 5.5.5.5

    BkNibID: 0x11000016       Interface: Vlan-interface1

    TableID: 0x2            BkInterface: Vlan-interface2

       Flag: 0xa8d0b           BfdSrcIp: N/A

    DbIndex: 0x17            BfdIfIndex: 0x0

       Type: Normal         BfdVrfIndex: 0

 TrackIndex: 0xffffffff           Label: NULL

 Preference: 60             vrfIndexDst: 0

    BfdMode: N/A             vrfIndexNH: 0

  Permanent: 0                      Tag: 0

Table 12 Command output

Field

Description

destination

Destination address/prefix.

NibID

ID of the NIB.

MainNibID

ID of the primary next hop for static route FRR.

BkNibID

ID of the backup next hop for static route FRR.

NextHop

Next hop address.

BkNextHop

Backup next hop address.

Interface

Output interface of the route.

BkInterface

Backup output interface.

TableID

ID of the table to which the route belongs.

Flag

Flag of the route.

DbIndex

Index of the database to which the route belongs.

Type

Route type:

·     Normal.

·     DHCP.

·     NAT.

BfdSrcIp

Source IP address of the indirect BFD session.

BfdIfIndex

Index of the interface where BFD is enabled.

BfdVrfIndex

Index of the VPN instance where BFD is enabled.

BfdMode

BFD session mode:

·     N/A—No BFD session is configured.

·     Ctrl—Control packet mode

·     EchoEcho packet mode.

TrackIndex

NQA Track index.

vrfIndexDst

Index of the destination VPN.

vrfIndexNH

Index of the VPN to which the next hop belongs.

Permanent

Permanent static route flag. 1 indicates a permanent static route.

 

ip route-static

Use ip route-static to configure a static route.

Use undo ip route-static to delete a static route.

Syntax

ip route-static dest-address { mask-length | mask } { interface-type interface-number [ next-hop-address ] [ backup-interface interface-type interface-number [ backup-nexthop backup-nexthop-address ] [ permanent ] | bfd { control-packet | echo-packet } | permanent ] | next-hop-address [ bfd control-packet bfd-source ip-address | permanent | track track-entry-number ] | vpn-instance d-vpn-instance-name next-hop-address [ bfd control-packet bfd-source ip-address | permanent | track track-entry-number ] } [ preference preference-value ] [ tag tag-value ] [ description description-text ]

undo ip route-static dest-address { mask-length | mask } [ interface-type interface-number [ next-hop-address ] | next-hop-address | vpn-instance d-vpn-instance-name next-hop-address ] [ preference preference-value ]

ip route-static vpn-instance s-vpn-instance-name dest-address { mask-length | mask } { interface-type interface-number [ next-hop-address ] [ backup-interface interface-type interface-number [ backup-nexthop backup-nexthop-address ] [ permanent ] | bfd { control-packet | echo-packet } | permanent ] | next-hop-address [ public ] [ bfd control-packet bfd-source ip-address | permanent | track track-entry-number ] | vpn-instance d-vpn-instance-name next-hop-address [ bfd control-packet bfd-source ip-address | permanent | track track-entry-number ] } [ preference preference-value ] [ tag tag-value ] [ description description-text ]

undo ip route-static vpn-instance s-vpn-instance-name dest-address { mask-length | mask } [ interface-type interface-number [ next-hop-address ] | next-hop-address [ public ] | vpn-instance d-vpn-instance-name next-hop-address ] [ preference preference-value ]

Default

No static route is configured.

Views

System view

Predefined user roles

network-admin

mdc-admin

Parameters

vpn-instance s-vpn-instance-name: Specifies a source MPLS L3VPN instance by its name, a case-sensitive string of 1 to 31 characters. Each VPN has its own routing table, and the configured static route is installed in the routing tables of the specified VPNs.

dest-address: Specifies the destination IP address of the static route, in dotted decimal notation.

mask-length/mask: Specifies the mask length or mask of the IP address. It must be an integer in the range of 0 to 32 or in dotted decimal notation.

vpn-instance d-vpn-instance-name: Specifies a destination MPLS L3VPN instance by its name, a case-sensitive string of 1 to 31 characters. If a destination VPN is specified, packets will search for the output interface in the destination VPN based on the configured next hop address.

next-hop-address: Specifies the IP address of the next hop, in dotted decimal notation.

backup-interface interface-type interface-number: Specifies a backup output interface by its type and number. If the backup output interface is an NBMA interface or broadcast interface (such as an Ethernet interface or a VLAN interface), rather than a P2P interface, you must specify the backup next hop address.

backup-nexthop backup-nexthop-address: Specifies a backup next hop address.

bfd: Enables BFD to detect reachability of the static route's next hop. When the next hop is unreachable, the system immediately switches to the backup route.

control-packet: Specifies the BFD control mode.

bfd-source ip-address: Specifies the source IP address of BFD packets. As a best practice, specify the loopback interface address.

permanent: Specifies the route as a permanent static route. If the output interface is down, the permanent static route is still active.

track track-entry-number: Associates the static route with a track entry specified by its number in the range of 1 to 1024. For more information about Track, see High Availability Configuration Guide.

echo-packet: Specifies the BFD echo mode.

public: Indicates that the specified next hop address is on the public network.

interface-type interface-number: Specifies an output interface by its type and number. If the output interface is an NBMA interface or broadcast interface (such as an Ethernet interface or a VLAN interface), rather than a P2P interface, the next hop address must be specified.

preference preference-value: Specifies a preference for the static route, in the range of 1 to 255. The default is 60.

tag tag-value: Sets a tag value for marking the static route, in the range of 1 to 4294967295. The default is 0. Tags of routes are used for route control in routing policies. For more information about routing policies, see Layer 3—IP Routing Configuration Guide.

description description-text: Configures a description of 1 to 60 characters for the static route. The description can include special characters like the space, but excluding the question mark (?).

Usage guidelines

If the destination IP address and the mask are both 0.0.0.0 (or 0), the configured route is a default route. The default route is used for forwarding a packet matching no entry in the routing table.

Implement different routing policies to configure different route preferences. For example, to enable load sharing for multiple routes to the same destination, assign the same preference to the routes; to enable them to back up one another, assign different preferences to them.

Follow these guidelines when you specify the output interface or the next hop address of the static route:

·     If the output interface is a Null 0 interface, no next hop address is required.

·     If the output interface is a broadcast interface (such as an Ethernet interface or a VLAN interface) that might have multiple next hops, you must specify the output interface and the next hop address at the same time.

Follow these guidelines when you configure a static route:

·     Enabling BFD for a flapping route could worsen the situation. Therefore, use it with caution. For more information about BFD, see High Availability Configuration Guide.

·     If the Track module uses NQA to detect the reachability of the private network static route's next hop, the VPN instance ID of the static route's next hop must be identical to that configured for the NQA operation.

·     If a static route needs route recursion, the associated track entry must monitor the next hop of the recursive route instead of that of the static route. Otherwise, a valid route might be mistakenly considered invalid.

·     Do not specify the permanent keyword together with the bfd or track keyword.

Examples

# Configure a static route, whose destination address is 1.1.1.1/24, next hop address is 2.2.2.2, tag value is 45, and description information is for internet.

<Sysname> system-view

[Sysname] ip route-static 1.1.1.1 24 2.2.2.2 tag 45 description for internet

Related commands

display ip routing-table protocol

ip route-static default-preference

Use ip route-static default-preference to configure a default preference for static routes.

Use undo ip route-static default-preference to restore the default.

Syntax

ip route-static default-preference default-preference-value

undo ip route-static default-preference

Default

The default preference of static routes is 60.

Views

System view

Predefined user roles

network-admin

mdc-admin

Parameters

default-preference-value: Specifies a default preference for static routes, in the range of 1 to 255.

Usage guidelines

If no preference is specified for a static route, the default preference applies.

When the default preference is reconfigured, it applies to only newly added static routes.

Examples

# Set a default preference of 120 for static routes.

<Sysname> system-view

[Sysname] ip route-static default-preference 120

Related commands

display ip routing-table protocol

ip route-static primary-path-detect bfd echo

Use ip route-static primary-path-detect bfd echo to enable BFD echo packet mode for static route FRR.

Use undo ip route-static primary-path-detect bfd to restore the default.

Syntax

ip route-static primary-path-detect bfd echo

undo ip route-static primary-path-detect bfd

Default

BFD echo packet mode for static route FRR is disabled.

Views

System view

Predefined user roles

network-admin

mdc-admin

Usage guidelines

This command enables static route FRR to use BFD echo packet mode for fast failure detection on the primary link.

Examples

# Enable BFD echo packet mode for static route FRR.

<Sysname> system-view

[Sysname] ip route-static 1.1.1.1 24 2.2.2.2 tag 45 description for internet

[Sysname] ip route-static primary-path-detect bfd echo

 


RIP commands

checkzero

Use checkzero to enable zero field check on RIPv1 messages.

Use undo checkzero to disable zero field check.

Syntax

checkzero

undo checkzero

Default

The zero field check function is enabled.

Views

RIP view

Predefined user roles

network-admin

mdc-admin

Usage guidelines

When the zero field check is enabled, the router discards RIPv1 messages in which zero fields contain non-zero values. If all messages are trustworthy, disable this feature to reduce the workload of the CPU.

Examples

# Disable zero field check on RIPv1 messages for RIP process 100.

<Sysname> system-view

[Sysname] rip 100

[Sysname-rip-100] undo checkzero

default cost

Use default cost to configure a default metric for redistributed routes.

Use undo default cost to restore the default.

Syntax

default cost value

undo default cost

Default

The default metric of redistributed routes is 0.

Views

RIP view

Predefined user roles

network-admin

mdc-admin

Parameters

value: Specifies a default metric for redistributed routes, in the range of 0 to 16.

Usage guidelines

When you use the import-route command to redistribute routes from another routing protocol without specifying a metric, the metric specified by the default cost command applies.

Examples

# Configure a default metric of 3 for redistributed routes.

<Sysname> system-view

[Sysname] rip 1

[Sysname-rip-1] default cost 3

Related commands

import-route

default-route

Use default-route to configure all interfaces running a RIP process to advertise a default route with a specified metric to RIP neighbors.

Use undo default-route to restore the default.

Syntax

default-route { only | originate } [ cost cost ]

undo default-route

Default

No default route is sent to RIP neighbors.

Views

RIP view

Predefined user roles

network-admin

mdc-admin

Parameters

only: Advertises only a default route.

originate: Advertises both a default route and other routes.

cost: Specifies a cost for the default route, in the range of 1 to 15. The default is 1.

Usage guidelines

A RIP router configured with this feature does not receive any default route from RIP neighbors.

Examples

# Configure all interfaces running RIP process 100 to send only a default route with a metric of 2 to RIP neighbors.

<Sysname> system-view

[Sysname] rip 100

[Sysname-rip-100] default-route only cost 2

Related commands

rip default-route

display rip

Use display rip to display state and configuration information for a RIP process.

Syntax

display rip [ process-id ]

Views

Any view

Predefined user roles

network-admin

network-operator

mdc-admin

mdc-operator

Parameters

process-id: Specifies a RIP process by its ID in the range of 1 to 65535. If no process is specified, the command displays state and configuration information for all RIP processes.

Examples

# Display current state and configuration information for all RIP processes.

<Sysname> display rip

  Public VPN-instance name:

 

    RIP process: 1

       RIP version: 1

       Preference: 100

           Routing policy: abc

       Fast-reroute:

           Routing policy: frr

       Checkzero: Enabled

       Default cost: 0

       Summary: Enabled

       Host routes: Enabled

       Maximum number of load balanced routes: 8

       Update time   :   30 secs  Timeout time         :  180 secs

       Suppress time :  120 secs  Garbage-collect time :  120 secs

       Update output delay:   20(ms)  Output count:    3

       Silent interfaces: None

       Default routes: Originate  Default routes cost: 3

       Verify-source: Enabled

       Networks:

           1.0.0.0

       Configured peers:

           197.168.6.2

       Triggered updates sent: 0

       Number of routes changes: 1

       Number of replies to queries: 0

Table 13 Command output

Field

Description

Public VPN-instance name/Private VPN-instance name

Public network or VPN where the RIP process runs.

RIP process

RIP process ID.

RIP version

RIP version 1 or 2.

Preference

RIP preference.

Checkzero

Indicates whether the zero field check is enabled for RIPv1 messages.

Default cost

Default cost of redistributed routes.

Summary

Indicates whether route summarization is enabled.

Host routes

Indicates whether to receive host routes.

Update time

RIP update interval.

Timeout time

RIP timeout time.

Suppress time

RIP suppress interval.

Update output delay

RIP packet sending interval.

Output count

Maximum number of RIP packets sent at each interval.

Garbage-collect time

RIP garbage collection interval.

Silent interfaces

Silent interfaces, which do not periodically send updates.

Default routes

Indicates whether a default route is sent to RIP neighbors.

·     only—Only a default route is advertised.

·     originate—A default route is advertised along with other routes.

·     disable—No default route is advertised.

Default routes cost

Metric for a default route.

Verify-source

Indicates whether the source IP address is checked for received RIP routing updates.

Networks

Networks enabled with RIP.

Configured peers

Configured neighbors.

Triggered updates sent

Number of triggered updates sent.

Number of routes changes

Number of route changes.

Number of replies to queries

Number of RIP responses.

 

display rip database

Use display rip database to display active routes for a RIP process. RIP advertises active routes in RIP routing updates.

Syntax

display rip process-id database [ ip-address { mask-length | mask } ]

Views

Any view

Predefined user roles

network-admin

network-operator

mdc-admin

mdc-operator

Parameters

process-id: Specifies a RIP process by its ID in the range of 1 to 65535.

ip-address { mask-length | mask }: Displays active routes for the specified IP address. Without this argument, the command displays all actives routes for a RIP process.

Examples

# Display active routes for RIP process 100.

<Sysname> display rip 100 database

   1.0.0.0/8, auto-summary

       1.1.1.0/24, cost 16, interface summary

       1.1.1.0/24, cost 0, nexthop 1.1.1.1, RIP-interface

       1.1.2.0/24, cost 0, imported

   2.0.0.0/8, auto-summary

   2.0.0.0/8, cost 1, nexthop 1.1.1.2

# Display active routes with destination IP address 1.1.1.0 and mask length 24 for RIP process 100.

<Sysname> display rip 100 database 1.1.1.0 24

   1.1.1.0/24, cost 16, interface summary

   1.1.1.0/24, cost 0, nexthop 1.1.1.1, RIP-interface

Table 14 Command output

Field

Description

cost

Cost of the route.

auto-summary

Indicates that the route is a RIP automatic summary route.

interface summary

Indicates that the route is a RIP interface summary route.

nexthop

Address of the next hop.

RIP-interface

Direct route on a RIP-enabled interface.

imported

Indicates that the route is redistributed from another routing protocol.

 

display rip interface

Use display rip interface to display RIP interface information for a RIP process.

Syntax

display rip process-id interface [ interface-type interface-number ]

Views

Any view

Predefined user roles

network-admin

network-operator

mdc-admin

mdc-operator

Parameters

process-id: Specifies a RIP process by its ID in the range of 1 to 65535.

interface-type interface-number: Specifies an interface by its type and number. If no interface is specified, the command displays information about all RIP interfaces for the RIP process.

Examples

# Display information about all interfaces for RIP process 1.

<Sysname> display rip 1 interface

 

 Interface: Vlan-interface2

    Address/Mask: 1.1.1.1/24          Version: RIPv1

    MetricIn: 0                       MetricIn route policy: Not designated

    MetricOut: 1                      MetricOut route policy: Not designated

    Split-horizon/Poison-reverse: On/Off  Input/Output: On/On

    Default route: Off

    Current number of packets/Maximum number of packets: 0/2000

Table 15 Command output

Field

Description

Interface

Name of an interface running RIP.

Address/Mask

IP address and mask of the interface.

Version

RIP version running on the interface.

MetricIn

Additional metric added to incoming routes.

MetricIn route policy

Name of the routing policy used to add an additional metric for incoming routes. If no routing policy is used, the field displays Not designated.

MetricOut

Additional metric added to outgoing routes.

MetricOut route policy

Name of the routing policy used to add an additional routing metric for outgoing routes. If no routing policy is used, the field displays Not designated.

Split-horizon

Indicates whether split horizon is enabled:

·     on—Enabled.

·     off—Disabled.

Poison-reverse

Indicates whether poison reverse is enabled:

·     on—Enabled.

·     off—Disabled.

Input/Output

Indicates whether the interface is enabled to receive and send RIP messages:

·     onEnabled.

·     offDisabled.

Default route

Indicates whether to send a default route to RIP neighbors:

·     OnlyAdvertises only a default route.

·     OriginateAdvertises both a default route and other routes.

·     No-originateAdvertises only non-default routes.

·     OffAdvertises no default route.

Default route cost

Metric for a default route.

Current number of packets /Maximum number of packets

Number of RIP packets to be sent/maximum number of RIP packets that can be sent within a certain interval.

 

display rip route

Use display rip route to display routing information for a RIP process.

Syntax

display rip process-id route [ ip-address { mask-length | mask } [ verbose ] | peer ip-address | statistics ]

Views

Any view

Predefined user roles

network-admin

network-operator

mdc-admin

mdc-operator

Parameters

process-id: Specifies a RIP process by its ID in the range of 1 to 65535.

ip-address { mask-length | mask }: Displays route information for the specified IP address.

verbose: Displays all routing information for the specified destination IP address. Without this keyword, the command displays only information about optimal routes with the specified destination IP address.

peer ip-address: Displays route information learned from the specified neighbor.

statistics: Displays route statistics, including the total number of routes and number of routes from each neighbor.

Usage guidelines

If no optional parameters are specified, the display rip process-id route command displays all routing information for a RIP process.

Examples

# Display all routing information for RIP process 1.

<Sysname> display rip 1 route

 Route Flags: R - RIP

              A - Aging, S - Suppressed, G - Garbage-collect

              O - Optimal, F - Flush to RIB

 ----------------------------------------------------------------------------

 Peer 111.1.1.2 on Vlan-interface1

      Destination/Mask        Nexthop           Cost    Tag     Flags   Sec

      122.0.0.0/8             111.1.1.2         1       0       RAOF    22

      123.0.0.0/8             111.1.1.2         1       0       RAOF    20

# Display specified routing information for RIP process 1.

<Sysname> display rip 1 route 123.0.0.0 8 verbose

 Route Flags: R – RIP

              A - Aging, S - Suppressed, G - Garbage-collect

              O - Optimal, F - Flush to RIB

 ----------------------------------------------------------------------------

 Peer 111.1.1.2 on Vlan-interface1

  Destination/Mask    OrigNexthop/RealNexthop          Cost  Tag   Flags Sec

  123.0.0.0/8         111.1.1.2/123.4.5.6              1     0     RAOF  20

 Peer 111.1.1.3 on Vlan-interface2

  Destination/Mask    OrigNexthop/RealNexthop          Cost  Tag   Flags Sec

  123.0.0.0/8         111.1.1.3/ -                     2     0     RA    20

Table 16 Command output

Field

Description

Route Flags

·     R—RIP route.

·     A—The route is aging.

·     S—The route is suppressed.

·     G—The route is in Garbage-collect state.

·     OThe route is an optimal route.

·     FThe route has been flushed to the RIB.

Peer X.X.X.X on interface-type interface-number

Routing information learned from a neighbor on a RIP interface.

Destination/Mask

Destination IP address and subnet mask.

Nexthop

Next hop of the route.

OrigNexthop/RealNexthop

If the route is from a directly connected neighbor, the original next hop is the real next hop.

If the route is from an indirectly connected neighbor, the RealNexthop field displays the recursive next hop for the route. Otherwise, the field is blank.

Cost

Cost of the route.

Tag

Route tag.

Flags

Route state.

Sec

Remaining time of the timer corresponding to the route state.

 

# Display routing statistics for RIP process 1.

<Sysname> display rip 1 route statistics

 Peer              Optimal/Aging        Garbage

 125.2.105.2       100/100              0

 Total             100/100              0

Table 17 Command output

Field

Description

Peer

IP address of a neighbor.

Optimal

Total number of optimal routes.

Aging

Total number of aging routes.

Garbage

Total number of routes in the Garbage-collection state.

Total

Total number of routes learned from all RIP neighbors.

 

fast-reroute

Use fast-reroute to configure RIP FRR.

Use undo fast-reroute to restore the default.

Syntax

fast-reroute route-policy route-policy-name

undo fast-reroute

Default

RIP FRR is disabled.

Views

RIP view

Predefined user roles

network-admin

mdc-admin

Parameters

route-policy route-policy-name: Uses the specified routing policy to designate a backup next hop. The route-policy-name argument is a case-sensitive string of 1 to 63 characters.

Usage guidelines

RIP FRR is available only when the state of primary link (with Layer 3 interfaces staying up) changes from bidirectional to unidirectional or down. A unidirectional link refers to the link through which packets are forwarded only from one end to the other.

RIP FRR is only effective for RIP routes that are learned from directly connected neighbors.

Do not use RIP FRR and BFD for RIP at the same time. Otherwise, RIP FRR might fail to work.

Equal-cost routes do not support RIP FRR. RIP FRR does not take effect when the backup route information is the same as the primary route information.

Examples

# Enable RIP FRR and use routing policy frr to specify a backup next hop.

<Sysname> system-view

[Sysname] bfd echo-source-ip 1.1.1.1

[Sysname] ip prefix-list abc index 10 permit 100.1.1.0 24

[Sysname] route-policy frr permit node 10

[Sysname-route-policy-frr-10] if-match ip address prefix-list abc

[Sysname-route-policy-frr-10] apply fast-reroute backup-interface vlan-interface 1 backup-nexthop 193.1.1.8

[Sysname-route-policy-frr-10] quit

[Sysname] rip 100

[Sysname-rip-100] fast-reroute route-policy frr

filter-policy export

Use filter-policy export to configure RIP to filter redistributed routes.

Use undo filter-policy export to remove the filtering.

Syntax

filter-policy { acl-number | prefix-list prefix-list-name } export [ protocol [ process-id ] | interface-type interface-number ]

undo filter-policy export [ protocol [ process-id ] | interface-type interface-number ]

Default

RIP does not filter redistributed routes.

Views

RIP view

Predefined user roles

network-admin

mdc-admin

Parameters

acl-number: Specifies an ACL by its number in the range of 2000 to 3999 to filter redistributed routes.

prefix-list prefix-list-name: Specifies an IP prefix list by its name, a case-sensitive string of 1 to 63 characters, to filter redistributed routes.

protocol: Filters routes redistributed from the specified routing protocol, which can be bgp, direct, isis, ospf, rip, or static.

process-id: Specifies the process ID of the specified routing protocol, in the range of 1 to 65535. Specify a process ID when the routing protocol is rip, ospf, or isis. If no process ID is specified, the default process ID is 1.

interface-type interface-number: Specifies an interface by its type and number.

Usage guidelines

If a protocol is specified, RIP filters only routes redistributed from the specified routing protocol. Otherwise, RIP filters all redistributed routes.

If an interface is specified, RIP filters only routes advertised by the specified interface. Otherwise, RIP filters routes advertised by all RIP interfaces.

To reference an advanced ACL (with a number from 3000 to 3999) in the command, configure the ACL using one of the following methods:

·     To deny/permit a route with the specified destination, use the rule [ rule-id ] { deny | permit } ip source sour-addr sour-wildcard command.

·     To deny/permit a route with the specified destination and mask, use the rule [ rule-id ] { deny | permit } ip source sour-addr sour-wildcard destination dest-addr dest-wildcard command.

The source keyword specifies the destination address of a route and the destination keyword specifies the subnet mask of the route. The specified subnet mask must be contiguous. Otherwise, the mask configuration does not take effect.

Examples

# Use ACL 2000 to filter redistributed routes.

<Sysname> system-view

[Sysname] acl number 2000

[Sysname-acl-basic-2000] rule deny source 192.168.10.0 0.0.0.255

[Sysname-acl-basic-2000] quit

[Sysname] rip 1

[Sysname-rip-1] filter-policy 2000 export

# Use IP prefix list abc to filter redistributed routes.

<Sysname> system-view

[Sysname] ip prefix-list abc index 10 permit 11.0.0.0 8

[Sysname] rip 1

[Sysname-rip-1] filter-policy prefix-list abc export

# Configure ACL 3000 to permit only route 113.0.0.0/16 to pass. Use ACL 3000 to filter redistributed routes.

<Sysname> system-view

[Sysname] acl number 3000

[Sysname-acl-adv-3000] rule 10 permit ip source 113.0.0.0 0 destination 255.255.0.0 0

[Sysname-acl-adv-3000] rule 100 deny ip

[Sysname-acl-adv-3000] quit

[Sysname] rip 1

[Sysname-rip 1] filter-policy 3000 export

Related commands

·     acl (ACL and QoS Command Reference)

·     import-route

·     ip prefix-list

filter-policy import

Use filter-policy import to configure RIP to filter received routes.

Use undo filter-policy import to restore the default.

Syntax

filter-policy { acl-number | gateway prefix-list-name | prefix-list prefix-list-name [ gateway prefix-list-name ] } import [ interface-type interface-number ]

undo filter-policy import [ interface-type interface-number ]

Default

RIP does not filter received routes.

Views

RIP view

Predefined user roles

network-admin

mdc-admin

Parameters

acl-number: Specifies an ACL by its number in the range of 2000 to 3999 to filter received routes.

prefix-list prefix-list-name: Specifies an IP prefix list by its name, a case-sensitive string of 1 to 63 characters, to filter received routes.

gateway prefix-list-name: Specifies an IP prefix list by its name, a case-sensitive string of 1 to 63 characters, to filter routes based on their next hops.

interface-type interface-number: Specifies an interface by its type and number.

Usage guidelines

To reference an advanced ACL (with a number from 3000 to 3999) in the command, configure the ACL using one of the following methods:

·     To deny/permit a route with the specified destination, use the rule [ rule-id ] { deny | permit } ip source sour-addr sour-wildcard command

·     To deny/permit a route with the specified destination and mask, use the rule [ rule-id ] { deny | permit } ip source sour-addr sour-wildcard destination dest-addr dest-wildcard command.

The source keyword specifies the destination address of a route and the destination keyword specifies the subnet mask of the route. The subnet mask must be contiguous. Otherwise, the mask configuration does not take effect.

Examples

# Use ACL 2000 to filter received RIP routes.

<Sysname> system-view

[Sysname] acl number 2000

[Sysname-acl-basic-2000] rule deny source 192.168.10.0 0.0.0.255

[Sysname-acl-basic-2000] quit

[Sysname] rip 1

[Sysname-rip-1] filter-policy 2000 import

# Use IP prefix list abc to filter received RIP routes.

<Sysname> system-view

[Sysname] ip prefix-list abc index 10 permit 11.0.0.0 8

[Sysname] rip 1

[Sysname-rip-1] filter-policy prefix-list abc import

# Configure ACL 3000 to permit only route 113.0.0.0/16 to pass. Use ACL 3000 to filter received routes.

<Sysname> system-view

[Sysname] acl number 3000

[Sysname-acl-adv-3000] rule 10 permit ip source 113.0.0.0 0 destination 255.255.0.0 0

[Sysname-acl-adv-3000] rule 100 deny ip

[Sysname-acl-adv-3000] quit

[Sysname] rip 1

[Sysname-rip-1] filter-policy 3000 import

Related commands

·     acl (ACL and QoS Command Reference)

·     ip prefix-list

graceful-restart

Use graceful-restart to enable GR for RIP.

Use undo graceful-restart to disable RIP GR capability.

Syntax

graceful-restart

undo graceful-restart

Default

RIP GR is disabled.

Views

RIP view

Predefined user roles

network-admin

mdc-admin

Examples

# Enable GR for RIP process 1.

<Sysname> system-view

[Sysname] rip 1

[Sysname-rip-1] graceful-restart

host-route

Use host-route to enable host route reception.

Use undo host-route to disable host route reception.

Syntax

host-route

undo host-route

Default

RIP receives host routes.

Views

RIP view

Predefined user roles

network-admin

mdc-admin

Usage guidelines

A router might receive many host routes from the same subnet. These routes are not helpful for routing and occupy many resources. To solve this problem, use the undo host-route command to disable RIP from receiving host routes.

This command takes effect only for RIPv2 routes.

Examples

# Disable RIP from receiving host routes.

<Sysname> system-view

[Sysname] rip 1

[Sysname-rip-1] undo host-route

import-route

Use import-route to enable route redistribution from another routing protocol.

Use undo import-route to disable route redistribution.

Syntax

import-route protocol [ process-id | all-processes | allow-ibgp ] [ cost cost | route-policy route-policy-name | tag tag ] *

undo import-route protocol [ process-id | all-processes ]

Default

RIP does not redistribute routes from any other routing protocol.

Views

RIP view

Predefined user roles

network-admin

mdc-admin

Parameters

protocol: Specifies a routing protocol from which RIP redistributes routes. It can be bgp, direct, isis, ospf, rip, or static.

process-id: Specifies a process by its ID in the range of 1 to 65535. The default is 1. This argument is available only when the protocol is isis, rip, or ospf.

all-processes: Enables route redistribution from all the processes of the specified protocol. This keyword takes effect only when the protocol is rip, ospf, or isis.

allow-ibgp: Allows redistribution of IBGP routes. This keyword is available when the protocol argument is set to bgp.

cost cost: Specifies a cost for redistributed routes, in the range of 0 to 16. The default cost is 0.

route-policy route-policy-name: Specifies a routing policy by its name, a case-sensitive string of 1 to 63 characters.

tag tag: Specifies a tag for marking redistributed routes, in the range of 0 to 65535. The default is 0.

Usage guidelines

The import-route bgp command redistributes only EBGP routes. The import-route bgp allow-ibgp command additionally redistributes IBGP routes and might cause routing loops. Therefore, use it with caution.

This command redistributes only active routes. To view route state information, use the display ip routing-table protocol command.

The undo import-route protocol all-processes command removes only the configuration made by the import-route protocol all-processes command, instead of the configuration made by the import-route protocol process-id command.

Examples

# Redistribute static routes into RIP, and set the cost for redistributed routes to 4.

<Sysname> system-view

[Sysname] rip 1

[Sysname-rip-1] import-route static cost 4

Related commands

default cost

maximum load-balancing

Use maximum load-balancing to set the maximum number of equal-cost multi-path (ECMP) routes for load balancing.

Use undo maximum load-balancing to restore the default.

Syntax

maximum load-balancing number

undo maximum load-balancing

Default

The maximum number of ECMP routes is 128.

Views

RIP view

Predefined user roles

network-admin

mdc-admin

Parameters

number: Specifies the maximum number of ECMP routes, in the range of 1 to 128.

Examples

# Set the maximum number of ECMP routes to 2.

<Sysname> system-view

[Sysname] rip

[Sysname-rip-1] maximum load-balancing 2

network

Use network to enable RIP on an interface attached to a specified network.

Use undo network to disable RIP on an interface attached to a specified network.

Syntax

network network-address [ wildcard-mask ]

undo network network-address

Default

RIP is disabled on an interface.

Views

RIP view

Predefined user roles

network-admin

mdc-admin

Parameters

network-address: Specifies a subnet address where an interface resides.

wildcard-mask: Specifies an IP address wildcard mask. A wildcard mask can be thought of as a subnet mask, with 1s and 0s inverted. For example, a wildcard mask of 255.255.255.0 corresponds to a subnet mask of 0.0.0.255.

Usage guidelines

RIP runs only on an interface attached to the specified network, which can be configured with a wildcard mask. An interface not on the specified network does not receive or send RIP routes, or advertise its direct routes.

For a single RIP process, the network 0.0.0.0 command can enable RIP on all interfaces. If multiple RIP processes exist, the command is not applicable.

If a physical interface is attached to multiple networks, you cannot advertise these networks in different RIP processes.

Examples

# Enable RIP process 100 on the interface attached to the network 129.102.0.0.

<Sysname> system-view

[Sysname] rip 100

[Sysname-rip-100] network 129.102.0.0

Related commands

rip enable

output-delay

Use output-delay to set the rate at which an interface sends RIP packets.

Use undo output-delay to restore the default.

Syntax

output-delay time count count

undo output-delay

Default

An interface sends up to three RIP packets every 20 milliseconds.

Views

RIP view

Predefined user roles

network-admin

mdc-admin

Parameters

time: Specifies the sending interval in the range of 10 to 100 milliseconds.

count: Specifies the maximum number of RIP packets sent at each interval, in the range of 1 to 30.

Examples

# Configure all interfaces running RIP process 1 to send up to 10 RIP packets every 60 milliseconds.

<Sysname> system-view

[Sysname] rip 1

[Sysname-rip-1] output-delay 60 count 10

peer

Use peer to specify a RIP neighbor in the NBMA network, where routing updates destined for the neighbor are only unicasts and not multicast or broadcast.

Use undo peer to remove a RIP neighbor.

Syntax

peer ip-address

undo peer ip-address

Default

RIP does not unicast updates to any neighbor.

Views

RIP view

Predefined user roles

network-admin

mdc-admin

Parameters

ip-address: Specifies the IP address of a RIP neighbor, in dotted decimal notation.

Usage guidelines

Do not use the peer ip-address command when the neighbor is directly connected. Otherwise, the neighbor might receive both unicast and multicast (or broadcast) messages with the same routing information.

This command must be executed together with the undo validate-source-address command, which disables source IP address check on inbound RIP routing updates.

Examples

# Configure RIP to unicast updates to peer 202.38.165.1.

<Sysname> system-view

[Sysname] rip 1

[Sysname-rip-1] peer 202.38.165.1

Related commands

validate-source-address

preference

Use preference to specify a preference for RIP routes.

Use undo preference to restore the default.

Syntax

preference [ route-policy route-policy-name ] value

undo preference

Default

The preference of RIP routes is 100.

Views

RIP view

Predefined user roles

network-admin

mdc-admin

Parameters

route-policy route-policy-name: Specifies a routing policy by its name, a case-sensitive string of 1 to 63 characters.

value: Specifies a preference for RIP routes, in the range of 1 to 255. The smaller the value, the higher the preference.

Usage guidelines

You can specify a routing policy by using the keyword route-policy to set a preference for matching RIP routes.

·     The preference set by the routing policy applies to all matching RIP routes. The preference of other routes is set by the preference command.

·     If no preference is set by the routing policy, the preference of all RIP routes is set by the preference command.

Examples

# Set a preference of 120 for RIP routes.

<Sysname> system-view

[Sysname] rip 1

[Sysname-rip-1] preference 120

reset rip process

Use reset rip process to reset a RIP process.

Syntax

reset rip process-id process

Views

User view

Predefined user roles

network-admin

mdc-admin

Parameters

process-id: Specifies a RIP process by its ID in the range of 1 to 65535.

Usage guidelines

After executing the command, you are prompted to confirm the operation.

Examples

# Reset RIP process 100.

<Sysname> reset rip 100 process

Reset RIP process? [Y/N]:y

reset rip statistics

Use reset rip statistics to clear statistics for a RIP process.

Syntax

reset rip process-id statistics

Views

User view

Predefined user roles

network-admin

network-operator

mdc-admin

mdc-operator

Parameters

process-id: Specifies a RIP process by its ID in the range of 1 to 65535.

Examples

# Clear statistics for RIP process 100.

<Sysname> reset rip 100 statistics

rip

Use rip to enable RIP and enter RIP view.

Use undo rip to disable RIP.

Syntax

rip [ process-id ] [ vpn-instance vpn-instance-name ]

undo rip [ process-id ]

Default

RIP is disabled.

Views

System view

Predefined user roles

network-admin

mdc-admin

Parameters

process-id: Specifies a RIP process by its ID in the range of 1 to 65535. The default is 1.

vpn-instance vpn-instance-name: Specifies an MPLS L3VPN instance by its name, a case-sensitive string of 1 to 31 characters. If no VPN is specified, the RIP process runs on the public network.

Usage guidelines

You must enable a RIP process before configuring global parameters for it. This restriction does not apply to configuring interface parameters.

If you disable a RIP process, the configured interface parameters become invalid.

Examples

# Enable RIP process 1 and enter RIP view.

<Sysname> system-view

[Sysname] rip

[Sysname-rip-1]

rip authentication-mode

Use rip authentication-mode to configure RIPv2 authentication.

Use undo rip authentication-mode to cancel RIPv2 authentication.

Syntax

rip authentication-mode { md5 { rfc2082 { cipher cipher-string | plain plain-string } key-id | rfc2453 { cipher cipher-string | plain plain-string } } | simple { cipher cipher-string | plain plain-string } }

undo rip authentication-mode

Default

RIPv2 authentication is not configured.

Views

Interface view

Predefined user roles

network-admin

mdc-admin

Parameters

md5: Specifies the MD5 authentication.

rfc2082: Uses the message format defined in RFC 2082.

cipher: Sets a ciphertext key.

cipher-string: Specifies a ciphertext key, a case-sensitive string of 33 to 53 characters.

plain: Sets a plaintext key.

plain-string: Specifies a plaintext key, a case-sensitive string of 1 to 16 characters.

key-id: Specifies the RFC 2082 MD5 key ID in the range of 1 to 255.

rfc2453: Uses the message format defined in RFC 2453 (IETF standard).

simple: Specifies the simple authentication mode.

Usage guidelines

A newly configured key overwrites the old one, if any.

Although you can specify an authentication mode for RIPv1 in interface view, the configuration does not take effect because RIPv1 does not support authentication.

For security purposes, all keys, including keys configured in plain text, are saved in cipher text.

Examples

# Configure MD5 authentication on VLAN-interface 10 and specify a plaintext key rose in the format defined in RFC 2453.

<Sysname> system-view

[Sysname] interface vlan-interface 10

[Sysname-Vlan-interface10] rip version 2

[Sysname-Vlan-interface10] rip authentication-mode md5 rfc2453 plain rose

Related commands

rip version

rip bfd enable

Use rip bfd enable to enable BFD for RIP on an interface.

Use undo rip bfd enable to restore the default.

Syntax

rip bfd enable

undo rip bfd enable

Default

BFD for RIP is disabled on an interface.

Views

Interface view

Predefined user roles

network-admin

mdc-admin

Usage guidelines

RIP supports BFD echo-mode detection for a directly connected neighbor, and BFD control-mode detection for an indirectly neighbor.

BFD echo-mode detection only applies to a RIP neighbor one hop away.

Using the undo peer command does not delete the neighbor relationship immediately and cannot bring down the BFD session immediately.

The rip bfd enable command and the rip bfd enable destination command are mutually exclusive and cannot be configured on a device at the same time.

Examples

# Enable BFD for RIP on VLAN-interface 11.

<Sysname> system-view

[Sysname] interface vlan-interface 11

[Sysname-Vlan-interface11] rip bfd enable

rip bfd enable destination

Use rip bfd enable destination to enable BFD single-hop echo detection for a specific destination.

Use undo rip bfd enable to disable BFD for RIP.

Syntax

rip bfd enable destination ip-address

undo rip bfd enable

Default

BFD single-hop echo detection for a specific destination is disabled on an interface.

Views

Interface view

Predefined user roles

network-admin

mdc-admin

Usage guidelines

The rip bfd enable destination command applies to only BFD echo-mode detection.

The rip bfd enable destination command and the rip bfd enable command are mutually exclusive and cannot be configured on a device at the same time.

When a link failure occurs between the local device and the specified neighbor, BFD can detect the failure and the local device does not receive or send any RIP packets through the interface connected to the neighbor.

Examples

# Enable BFD on VLAN-interface 10 for a specific destination 202.38.165.1.

<Sysname> system-view

[Sysname] interface vlan-interface 10

[Sysname-Vlan-interface10] rip bfd enable destination 202.38.165.1

rip default-route

Use rip default-route to configure a RIP interface to advertise a default route with a specified metric.

Use undo rip default-route to disable a RIP interface from sending a default route.

Syntax

rip default-route { { only | originate } [ cost cost ] | no-originate }

undo rip default-route

Default

A RIP interface advertises a default route if the RIP process that the interface runs is enabled to advertise a default route.

Views

Interface view

Predefined user roles

network-admin

mdc-admin

Parameters

only: Advertises only a default route.

originate: Advertises both a default route and other routes.

cost: Specifies a cost for the default route, in the range of 1 to 15. The default is 1.

no-originate: Advertises only non-default routes.

Usage guidelines

An interface that is enabled to advertise a default route does not receive any default route from RIP neighbors.

Examples

# Configure VLAN-interface 10 to advertise only a default route with a metric of 2.

<Sysname> system-view

[Sysname] interface vlan-interface 10

[Sysname-Vlan-interface10] rip default-route only cost 2

# Configure VLAN-interface 10 to advertise a default route with a metric of 2 and other routes.

<Sysname> system-view

[Sysname] interface vlan-interface 10

[Sysname-Vlan-interface10] rip default-route originate cost 2

Related commands

default-route

rip enable

Use rip enable to enable RIP on an interface.

Use undo rip enable to disable RIP on an interface.

Syntax

rip process-id enable [ exclude-subip ]

undo rip enable

Default

RIP is disabled on an interface.

Views

Interface view

Predefined user roles

network-admin

mdc-admin

Parameters

process-id: Specifies a RIP process by its ID in the range of 1 to 65535.

exclude-subip: Excludes secondary IP addresses from being enabled with RIP. Without this keyword, RIP is also enabled on secondary IP addresses of a RIP-enabled interface.

Usage guidelines

The rip enable command has a higher priority than the network command.

Examples

# Enable RIP process 100 on VLAN-interface 10.

<Sysname> system-view

[Sysname] interface vlan-interface 10

[Sysname-Vlan-interface10] rip 100 enable

Related commands

network

rip input

Use rip input to enable an interface to receive RIP messages.

Use undo rip input to disable an interface from receiving RIP messages.

Syntax

rip input

undo rip input

Default

An interface is enabled to receive RIP messages.

Views

Interface view

Predefined user roles

network-admin

mdc-admin

Examples

# Disable VLAN-interface 10 from receiving RIP messages.

<Sysname> system-view

[Sysname] interface vlan-interface 10

[Sysname-Vlan-interface10] undo rip input

rip max-packet-length

Use rip max-packet-length to set the maximum length of RIP packets.

Use undo rip max-packet-length to restore the default.

Syntax

rip max-packet-length value

undo rip max-packet-length

Default

The maximum length of RIP packets is 512 bytes.

Views

Interface view

Predefined user roles

network-admin

mdc-admin

Parameters

value: Specifies the maximum length of RIP packets, in the range of 32 to 65535 bytes.

Usage guidelines

If the configured value in the rip max-packet-length command is greater than the MTU of an interface, the interface MTU value is used as the maximum length of RIP packets.

The supported maximum length of RIP packets varies by vendor. Use this feature with caution to avoid compatibility issues.

When authentication is enabled, follow these guidelines to ensure packet forwarding:

·     For simple authentication, the maximum length of RIP packets must be no less than 52 bytes.

·     For MD5 authentication (with packet format defined in RFC 2453), the maximum length of RIP packets must be no less than 56 bytes.

·     For MD5 authentication (with packet format defined in RFC 2082), the maximum length of RIP packets must be no less than 72 bytes.

Examples

# Set the maximum length of RIP packets on VLAN-interface 10 to 1024 bytes.

<Sysname> system-view

[Sysname] interface vlan-interface 10

[Sysname-Vlan-interface10] rip max-packet-length 1024

rip metricin

Use rip metricin to configure an interface to add a metric to inbound routes.

Use undo rip metricin to restore the default.

Syntax

rip metricin [ route-policy route-policy-name ] value

undo rip metricin

Default

The additional metric of an inbound route is 0.

Views

Interface view

Predefined user roles

network-admin

mdc-admin

Parameters

route-policy route-policy-name: Uses the specified routing policy to add an additional metric for the routes matching it. The route-policy-name argument is a case-sensitive string of 1 to 63 characters.

value: Adds an additional metric to inbound routes, in the range of 0 to 16.

Usage guidelines

When a valid RIP route is received, the system adds a metric to it and then installs it into the routing table. The metric of the route received on the configured interface is then increased. If the sum of the additional metric and the original metric is greater than 16, the metric of the route will be 16.

If a routing policy is referenced with the route-policy keyword, the following operations can be performed:

·     Routes matching the policy are added with the metric specified in the apply cost command configured in the policy. Routes not matching it are added with the metric specified in the rip metricin command. The rip metricin command does not support the + or keyword—used to add or reduce a metric—specified in the apply cost command.

·     If the apply cost command is not configured in the policy, all the inbound routes are added with the metric specified in the rip metricin command.

Examples

# Configure VLAN-interface 10 to add a metric of 6 to the inbound route 1.0.0.0/8 and to add a metric of 2 to other inbound routes.

<Sysname> system-view

[Sysname] ip prefix-list 123 permit 1.0.0.0 8

[Sysname] route-policy abc permit node 0

[Sysname-route-policy-abc-10] if-match ip address prefix-list 123

[Sysname-route-policy-abc-10] apply cost 6

[Sysname-route-policy-abc-10] quit

[Sysname] interface vlan-interface 10

[Sysname-Vlan-interface10] rip metricin route-policy abc 2

Related commands

apply cost

rip metricout

Use rip metricout to configure an interface to add a metric to outbound routes.

Use undo rip metricout to restore the default.

Syntax

rip metricout [ route-policy route-policy-name ] value

undo rip metricout

Default

The additional metric for outbound routes is 1.

Views

Interface view

Predefined user roles

network-admin

mdc-admin

Parameters

route-policy route-policy-name: Uses the specified routing policy to add an additional metric for the routes matching it. The route-policy-name argument is a case-sensitive string of 1 to 63 characters.

value: Adds an additional metric to outbound routes, in the range of 1 to 16.

Usage guidelines

With the command configured on an interface, the metric of RIP routes sent on the interface will be increased.

If a routing policy is referenced with the route-policy keyword, the following operations can be performed:

·     Routes matching the policy is added with the metric specified in the apply cost command configured in the policy. Routes not matching it are added with the metric specified in the rip metricout command. The rip metricout command does not support the + or keyword—used to add or reduce a metric—specified in the apply cost command.

·     If the apply cost command is not configured in the policy, all the outbound routes are added with the metric specified in the rip metricout command.

Examples

# Configure VLAN-interface 10 to add a metric of 6 to the outbound route 1.0.0.0/8 and to add a metric of 2 to other outbound routes.

<Sysname> system-view

[Sysname] ip prefix-list 123 permit 1.0.0.0 8

[Sysname] route-policy abc permit node 0

[Sysname-route-policy-abc-10] if-match ip address prefix-list 123

[Sysname-route-policy-abc-10] apply cost 6

[Sysname-route-policy-abc-10] quit

[Sysname] interface vlan-interface 10

[Sysname-Vlan-interface10] rip metricout route-policy abc 2

Related commands

apply cost

rip mib-binding

Use rip mib-binding to bind a RIP process to MIB operation.

Use undo rip mib-binding to restore the default.

Syntax

rip mib-binding process-id

undo rip mib-binding

Default

MIB operation is bound to the RIP process with the smallest process ID.

Views

System view

Predefined user roles

network-admin

mdc-admin

Parameters

process-id: Specifies a RIP process by its ID in the range of 1 to 65535.

Usage guidelines

If the specified process ID does not exist, the MIB binding configuration fails.

Deleting a RIP process bound to MIB operation deletes the MIB binding configuration. After the RIP process is deleted, MIB operation is bound to the RIP process with the smallest process ID.

Examples

# Bind MIB operation to RIP process 100.

<Sysname> system-view

[Sysname] rip mib-binding 100

rip output

Use rip output to enable an interface to send RIP messages.

Use undo rip output to disable an interface from sending RIP messages.

Syntax

rip output

undo rip output

Default

An interface sends RIP messages.

Views

Interface view

Predefined user roles

network-admin

mdc-admin

Examples

# Disable VLAN-interface 10 from sending RIP messages.

<Sysname> system-view

[Sysname] interface vlan-interface 10

[Sysname-Vlan-interface10] undo rip output

rip poison-reverse

Use rip poison-reverse to enable the poison reverse function.

Use undo rip poison-reverse to disable the poison reverse function.

Syntax

rip poison-reverse

undo rip poison-reverse

Default

The poison reverse function is disabled.

Views

Interface view

Predefined user roles

network-admin

mdc-admin

Examples

# Enable the poison reverse function on VLAN-interface 10.

<Sysname> system-view

[Sysname] interface vlan-interface 10

[Sysname-Vlan-interface10] rip poison-reverse

rip primary-path-detect bfd echo

Use rip primary-path-detect bfd echo to enable BFD single-hop echo detection for RIP FRR.

Use undo rip primary-path-detect bfd to restore the default.

Syntax

rip primary-path-detect bfd echo

undo rip primary-path-detect bfd

Default

BFD single-hop echo detection for RIP FRR is disabled.

Views

Interface view

Predefined user roles

network-admin

mdc-admin

Usage guidelines

This command enables RIP FRR to use BFD single-hop echo detection to detect primary link failures.

Examples

# Enable BFD single-hop echo detection for RIP FRR on VLAN-interface 10.

<Sysname> system-view

[Sysname] rip 1

[Sysname-rip-1] fast-reroute route-policy frr

[Sysname-rip-1] quit

[Sysname] bfd echo-source-ip 1.1.1.1

[Sysname] interface vlan-interface 10

[Sysname-Vlan-interface10] rip primary-path-detect bfd echo

rip split-horizon

Use rip split-horizon to enable the split horizon function.

Use undo rip split-horizon to disable the split horizon function.

Syntax

rip split-horizon

undo rip split-horizon

Default

The split horizon function is enabled.

Views

Interface view

Predefined user roles

network-admin

mdc-admin

Usage guidelines

·     The split horizon function prevents routing loops. If you want to disable the function, make sure the operation is necessary.

·     If both split horizon and poison reverse are enabled, only the poison reverse function takes effect.

Examples

# Enable the split horizon function on VLAN-interface 10.

<Sysname> system-view

[Sysname] interface vlan-interface 10

[Sysname-Vlan-interface10] rip split-horizon

rip summary-address

Use rip summary-address to configure RIPv2 to advertise a summary route on an interface.

Use undo rip summary-address to remove the configuration.

Syntax

rip summary-address ip-address { mask-length | mask }

undo rip summary-address ip-address { mask-length | mask }

Default

RIPv2 does not advertise a summary route.

Views

Interface view

Predefined user roles

network-admin

mdc-admin

Parameters

ip-address: Specifies the destination IP address of the summary route.

mask-length: Specifies the subnet mask length of the summary route, in the range of 0 to 32.

mask: Specifies the subnet mask of the summary route, in dotted decimal notation.

Usage guidelines

This command takes effect only when automatic route summarization is disabled.

Examples

# Advertise a summary route on VLAN-interface 10.

<Sysname> system-view

[Sysname] interface vlan-interface 10

[Sysname-Vlan-interface10] rip summary-address 10.0.0.0 255.255.255.0

Related commands

summary

rip version

Use rip version to specify a RIP version on an interface.

Use undo rip version to restore the default.

Syntax

rip version { 1 | 2 [ broadcast | multicast ] }

undo rip version

Default

No RIP version is configured on an interface. The interface can send RIPv1 broadcasts, and receive RIPv1 broadcasts and unicasts, and RIPv2 broadcasts, multicasts, and unicasts.

Views

Interface view

Predefined user roles

network-admin

mdc-admin

Parameters

1: Specifies the RIP version as RIPv1.

2: Specifies the RIP version as RIPv2.

[ broadcast | multicast ]: Sends RIPv2 messages in broadcast mode or multicast mode (default).

Usage guidelines

If an interface has no RIP version configured, it uses the global RIP version. Otherwise, it uses the RIP version configured on it.

An interface running RIPv1 can perform the following operations:

·     Sends RIPv1 broadcast messages.

·     Receives RIPv1 broadcast and unicast messages.

An interface running RIPv2 in broadcast mode can perform the following operations:

·     Sends RIPv2 broadcast messages.

·     Receives RIPv1 broadcast and unicast messages, and RIPv2 broadcast, multicast, and unicast messages.

An interface running RIPv2 in multicast mode can perform the following operations:

·     Sends RIPv2 multicast messages.

·     Receives RIPv2 broadcast, multicast, and unicast messages.

Examples

# Configure RIPv2 in broadcast mode on VLAN-interface 10.

<Sysname> system-view

[Sysname] interface vlan-interface 10

[Sysname-Vlan-interface10] rip version 2 broadcast

Related commands

version

silent-interface

Use silent-interface to disable an interface from sending RIP messages. The interface can still receive RIP messages.

Use undo silent-interface to restore the default.

Syntax

silent-interface { interface-type interface-number | all }

undo silent-interface { interface-type interface-number | all }

Default

All RIP interfaces can send RIP messages.

Views

RIP view

Predefined user roles

network-admin

mdc-admin

Parameters

interface-type interface-number: Disables a specified interface from sending RIP messages.

all: Disables all interfaces from sending RIP messages.

Examples

# Configure all VLAN interfaces to operate in silent mode except VLAN-interface 10.

<Sysname> system-view

[Sysname] rip 100

[Sysname-rip-100] silent-interface all

[Sysname-rip-100] undo silent-interface vlan-interface 10

[Sysname-rip-100] network 131.108.0.0

summary

Use summary to enable automatic RIPv2 route summarization. Natural masks are used to advertise summary routes to reduce the size of routing tables.

Use undo summary to disable automatic RIPv2 route summarization to advertise all subnet routes.

Syntax

summary

undo summary

Default

Automatic RIPv2 route summarization is enabled.

Views

RIP view

Predefined user roles

network-admin

mdc-admin

Usage guidelines

Automatic RIPv2 route summarization can reduce the routing table size to enhance the scalability and efficiency for large networks.

Examples

# Disable automatic RIPv2 route summarization.

<Sysname> system-view

[Sysname] rip

[Sysname-rip-1] undo summary

Related commands

·     rip summary-address

·     rip version

timers

Use timers to configure RIP timers.

Use undo timers to restore the default.

Syntax

timers { garbage-collect garbage-collect-value | suppress suppress-value | timeout timeout-value | update update-value } *

undo timers { garbage-collect | suppress | timeout | update } *

Default

The garbage-collect timer is 120 seconds, the suppress timer is 120 seconds, the timeout timer is 180 seconds, and the update timer is 30 seconds.

Views

RIP view

Predefined user roles

network-admin

mdc-admin

Parameters

garbage-collect-value: Specifies the garbage-collect timer in the range of 1 to 3600 seconds.

suppress-value: Specifies the suppress timer in the range of 0 to 3600 seconds.

timeout-value: Specifies the timeout timer in the range of 1 to 3600 seconds.

update-value: Specifies the update timer in the range of 1 to 3600 seconds.

Usage guidelines

RIP uses the following timers:

·     Update timerSpecifies the interval between routing updates.

·     Timeout timerSpecifies the route aging time. If no update for a route is received before the timer expires, RIP sets the metric of the route to 16.

·     Suppress timerSpecifies how long a RIP route stays in suppressed state. When the metric of a route becomes 16, the route enters the suppressed state. If RIP receives an update for the route from the same neighbor and the route in the update has a metric less than 16, RIP uses the route to replace the suppressed route.

·     Garbage-collect timer—Specifies the interval from when the metric of a route becomes 16 to when it is deleted from the routing table. During the garbage-collect timer length, RIP advertises the route with a metric of 16. If no update is announced for that route before the garbage-collect timer expires, RIP deletes the route from the routing table.

As a best practice, do not change the default values of these timers.

The timer lengths must be consistent on all routers on the network.

The timeout timer must be greater than the update timer.

Examples

# Configure the update, timeout, suppress, and garbage-collect timers as 5, 15, 15, and 30 seconds.

<Sysname> system-view

[Sysname] rip 100

[Sysname-rip-100] timers update 5 timeout 15 suppress 15 garbage-collect 30

validate-source-address

Use validate-source-address to enable source IP address check on inbound RIP routing updates.

Use undo validate-source-address to disable source IP address check.

Syntax

validate-source-address

undo validate-source-address

Default

Source IP address check on inbound RIP routing updates is enabled.

Views

RIP view

Predefined user roles

network-admin

mdc-admin

Examples

# Disable source IP address check on inbound RIP routing updates.

<Sysname> system-view

[Sysname-rip] rip 100

[Sysname-rip-100] undo validate-source-address

version

Use version to specify a global RIP version.

Use undo version to restore the default.

Syntax

version { 1 | 2 }

undo version

Default

No global RIP version is configured. An RIP interface can send RIPv1 broadcasts and receive RIPv1 broadcasts and unicasts, and RIPv2 broadcasts, multicasts, and unicasts.

Views

RIP view

Predefined user roles

network-admin

mdc-admin

Parameters

1: Specifies the RIP version as RIPv1.

2: Specifies the RIP version as RIPv2. RIPv2 messages are multicast.

Usage guidelines

An interface prefers the RIP version configured on it over the global RIP version. If no RIP version is specified for the interface and the global version is RIPv1, the interface uses RIPv1, and it can send RIPv1 broadcasts, and receive RIPv1 broadcasts and unicasts. If no RIP version is specified for the interface and the global version is RIPv2, the interface uses RIPv2 multicast mode, and it can send RIPv2 multicasts, and receive RIPv2 broadcasts, multicasts, and unicasts.

Examples

# Specify the global RIP version as RIPv2.

<Sysname> system-view

[Sysname] rip 100

[Sysname-rip-100] version 2

Related commands

rip version

 


OSPF commands

abr-summary (OSPF area view)

Use abr-summary to configure a summary route on an area border router (ABR).

Use undo abr-summary to remove a summary route.

Syntax

abr-summary ip-address { mask-length | mask } [ advertise | not-advertise ] [ cost cost ]

undo abr-summary ip-address { mask-length | mask }

Default

No route summarization is configured on an ABR.

Views

OSPF area view

Predefined user roles

network-admin

mdc-admin

Parameters

ip-address: Specifies the destination IP address of the summary route in dotted decimal notation.

mask-length: Specifies the mask length in the range of 0 to 32.

mask: Specifies the mask of the IP address, in dotted decimal notation.

advertise | not-advertise: Advertises the summary route or not. By default, the command advertises the summary route.

cost cost: Specifies the cost of the summary route, in the range of 1 to 16777215. The default cost is the largest cost value among routes that are summarized.

Usage guidelines

This command is available only on an ABR to summarize multiple contiguous networks into one network.

To enable ABR to advertise more-specific routes, issue the undo abr-summary command.

Examples

# Summarize networks 36.42.10.0/24 and 36.42.110.0/24 in Area 1 into 36.42.0.0/16.

<Sysname> system-view

[Sysname] ospf 100

[Sysname-ospf-100] area 1

[Sysname-ospf-100-area-0.0.0.1] network 36.42.10.0 0.0.0.255

[Sysname-ospf-100-area-0.0.0.1] network 36.42.110.0 0.0.0.255

[Sysname-ospf-100-area-0.0.0.1] abr-summary 36.42.0.0 255.255.0.0

area (OSPF view)

Use area to create an area and enter area view.

Use undo area to remove an area.

Syntax

area area-id

undo area area-id

Default

No OSPF area is created.

Views

OSPF view

Predefined user roles

network-admin

mdc-admin

Parameters

area-id: Specifies an area by its ID, an IP address or a decimal integer in the range of 0 to 4294967295 that is translated into the IP address format by the system.

Examples

# Create area 0 and enter area 0 view.

<Sysname> system-view

[Sysname] ospf 100

[Sysname-ospf-100] area 0

[Sysname-ospf-100-area-0.0.0.0]

asbr-summary

Use asbr-summary to configure a summary route on an ASBR.

Use undo asbr-summary to remove a summary route on an ASBR.

Syntax

asbr-summary ip-address { mask-length | mask } [ cost cost | not-advertise | nssa-only | tag tag ] *

undo asbr-summary ip-address { mask-length | mask }

Default

No route summarization is configured on an ASBR.

Views

OSPF view

Predefined user roles

network-admin

mdc-admin

Parameters

ip-address: Specifies the destination IP address of the summary route.

mask-length: Specifies the mask length in the range of 0 to 32.

mask: Specifies the mask in dotted decimal notation.

cost cost: Specifies the cost of the summary route, in the range of 1 to 16777214. If you do not specify this option, the largest cost among the summarized routes applies. If the routes in Type-5 LSAs translated from Type-7 LSAs are Type-2 external routes, the largest cost among the summarized routes plus 1 applies.

not-advertise: Disables advertising the summary route. If you do not specify this keyword, the command advertises the route.

nssa-only: Limits the route advertisement to the NSSA area by setting the P-bit of Type-7 LSAs to 0. By default, the P-bit of Type-7 LSAs is set to 1. If the ASBR is also an ABR and FULL state neighbors exist in the backbone area, the P-bit of Type-7 LSAs originated by the ASBR is set to 0. This keyword applies to the NSSA ASBR.

tag tag: Specifies a tag for marking the summary route, in the range of 0 to 4294967295. The default is 1. The tag can be used by a routing policy to control summary route advertisement.

Usage guidelines

With the asbr-summary command configured, an ASBR summarizes redistributed routes within the specified address range into a single route and advertises the summary route in a Type-5 LSA to neighbors. If the ASBR resides in an NSSA area, it advertises the summary route in a Type-7 LSA.

With the asbr-summary command configured, an NSSA ABR summarizes matching routes described by Type-7 LSAs, and advertises the summary route to neighbors in Type-5 LSAs. This command does not take effect on non NSSA ABRs.

To enable ASBR to advertise more-specific routes, issue the undo asbr-summary command.

Examples

# Summarize redistributed static routes into a single route, and specify a tag value of 2 and a cost of 100 for the summary route.

<Sysname> system-view

[Sysname] ip route-static 10.2.1.0 24 null 0

[Sysname] ip route-static 10.2.2.0 24 null 0

[Sysname] ospf 100

[Sysname-ospf-100] import-route static

[Sysname-ospf-100] asbr-summary 10.2.0.0 255.255.0.0 tag 2 cost 100

Related commands

display ospf asbr-summary

authentication-mode

Use authentication-mode to specify an authentication mode for the OSPF area.

Use undo authentication-mode to restore the default.

Syntax

For MD5/HMAC-MD5 authentication:

authentication-mode { hmac-md5 | md5 } key-id { cipher | plain } password

undo authentication-mode [ { hmac-md5 | md5 } key-id ]

For simple authentication:

authentication-mode simple { cipher | plain } password

undo authentication-mode

Default

No authentication is performed for an area.

Views

OSPF area view

Predefined user roles

network-admin

mdc-admin

Parameters

hmac-md5: Specifies the HMAC-MD5 authentication mode.

md5: Specifies the MD5 authentication mode.

simple: Specifies the simple authentication mode.

key-id: Specifies a key by its ID in the range of 0 to 255.

cipher: Sets a ciphertext key.

plain: Sets a plaintext key.

password: Specifies a password. In simple authentication mode, a plaintext password is a case-sensitive string of 1 to 8 characters, and a ciphertext password is a case-sensitive string of 33 to 41 characters. In MD5/HMAC-MD5 authentication mode, a plaintext password is a case-sensitive string of 1 to 16 characters, and a ciphertext password is a case-sensitive string of 33 to 53 characters.

Usage guidelines

Routers that reside in the same area must have the same authentication mode and password.

For security purposes, all keys, including keys configured in plain text, are saved in cipher text.

You can specify either MD5/HMAC-MD5 authentication or simple authentication for an OSPF area. For MD5/HMAC-MD5 authentication, you can configure multiple keys by executing this command multiple times, and each command must have a unique key ID and key string.

To modify the key of an OSPF area, perform the following key rollover configurations:

1.     Configure a new MD5/HMAC-MD5 authentication key for the area on the local device. If the new key is not configured on neighbor devices, MD5/HMAC-MD5 authentication key rollover is triggered. During key rollover, OSPF sends multiple packets that contain both the new and old MD5/HMAC-MD5 authentication keys to make sure all neighbor devices can pass the authentication.

2.     Configure the new MD5/HMAC-MD5 authentication key on all neighbor devices. When the local device receives packets with the new key from all neighbor devices, it exits MD5 key rollover.

3.     Delete the old MD5/HMAC-MD5 authentication key from the local device and all its neighbors. This operation helps prevent attacks from devices that use the old key for communication and reduces system resources and bandwidth consumption caused by key rollover.

Examples

# Configure OSPF Area 0 to use the MD5 authentication mode, and set the key ID to 15 and plaintext authentication password to abc.

<Sysname> system-view

[Sysname] ospf 100

[Sysname-ospf-100] area 0

[Sysname-ospf-100-area-0.0.0.0] authentication-mode md5 15 plain abc

Related commands

ospf authentication-mode

bandwidth-reference (OSPF view)

Use bandwidth-reference to specify a reference bandwidth value for link cost calculation.

Use undo bandwidth-reference to restore the default value.

Syntax

bandwidth-reference value

undo bandwidth-reference

Default

The default value is 100 Mbps.

Views

OSPF view

Predefined user roles

network-admin

mdc-admin

Parameters

value: Specifies the bandwidth reference value for link cost calculation, in the range of 1 to 4294967 Mbps.

Usage guidelines

If no cost values are configured for links, OSPF calculates their cost values by using the formula: Cost = Reference bandwidth value / Expected interface bandwidth. The expected bandwidth of an interface is configured with the bandwidth command (see Interface Command Reference). If the calculated cost is greater than 65535, the value of 65535 is used. If the calculated cost is less than 1, the value of 1 is used. The default cost values of common interfaces are as follows:

·     For a 56 kbps serial interface, the value is 1785.

·     For a 64 kbps serial interface, the value is 1562.

·     For an E1 (2.048 Mbps) interface, the value is 48.

·     For an Ethernet (100 Mbps) interface, the value is 1.

·     For a loopback interface, the value is 0.

Examples

# Specify the reference bandwidth value as 1000 Mbps.

<Sysname> system-view

[Sysname] ospf 100

[Sysname-ospf-100] bandwidth-reference 1000

Related commands

ospf cost

default

Use default to configure default parameters for redistributed routes.

Use undo default to remove the configuration.

Syntax

default { cost cost | tag tag | type type } *

undo default { cost | tag | type } *

Default

The cost is 1, the tag is 1, and the route type is 2.

Views

OSPF view

Predefined user roles

network-admin

mdc-admin

Parameters

cost cost: Specifies the default cost for redistributed routes, in the range of 0 to 16777214.

tag tag: Specifies the tag for marking redistributed routes, in the range of 0 to 4294967295.

type type: Specifies the type for redistributed routes: 1 or 2.

Examples

# Configure the default cost, tag, and type as 10, 100, and 2 for redistributed external routes.

<Sysname> system-view

[Sysname] ospf 100

[Sysname-ospf-100] default cost 10 tag 100 type 2

Related commands

import-route

default-cost (OSPF area view)

Use default-cost to configure a cost for the default route advertised to the stub or NSSA area.

Use undo default-cost to restore the default value.

Syntax

default-cost cost

undo default-cost

Default

The cost is 1.

Views

OSPF area view

Predefined user roles

network-admin

mdc-admin

Parameters

cost: Specifies a cost for the default route advertised to the Stub or NSSA area, in the range of 0 to 16777214.

Usage guidelines

This command takes effect only on the ABR of a stub area or the ABR/ASBR of an NSSA area.

Examples

# Configure Area 1 as a stub area, and specify the cost of the default route advertised to the stub area as 20.

<Sysname> system-view

[Sysname] ospf 100

[Sysname-ospf-100] area 1

[Sysname-ospf-100-area-0.0.0.1] stub

[Sysname-ospf-100-area-0.0.0.1] default-cost 20

Related commands

·     nssa

·     stub

default-route-advertise (OSPF view)

Use default-route-advertise to redistribute a default route into the OSPF routing domain.

Use undo default-route-advertise to restore the default.

Syntax

default-route-advertise [ [ always | permit-calculate-other ] | cost cost | route-policy route-policy-name | type type ] *

undo default-route-advertise

Default

No default route is redistributed into the OSPF routing domain.

Views

OSPF view

Predefined user roles

network-admin

mdc-admin

Parameters

always: Generates a default route in a Type-5 LSA into the OSPF routing domain regardless of whether or not there is a default route in the routing table. If this keyword is not specified, the router generates a default route in a Type-5 LSA into the OSPF routing domain only when an active default route that does not belong to the current OSPF process exists in the IP routing table.

permit-calculate-other: Enables OSPF to calculate default routes received from other routers. If you do not specify this keyword, OSPF does not calculate default routes from other routers. If the router does not generate any default route in a Type-5 LSA into the OSPF routing domain, the router calculates default routes from other routers regardless of whether this keyword is specified.

cost cost: Specifies a cost for the default route, in the range of 0 to 16777214. If no cost is specified, the default cost specified by the default cost command applies.

route-policy route-policy-name: Specifies a routing policy by its name, a case-sensitive string of 1 to 63 characters. When a default route exists in the routing table and the specified routing policy is matched, the command distributes a default route in a Type-5 LSA into the OSPF routing domain, and the routing policy modifies some values in the Type-5 LSA. If the always keyword is specified at the same time, the command can distribute a default route in a Type-5 LSA into the OSPF routing domain when the specified routing policy is matched, regardless of whether a default route exists in the routing table, and the routing policy modifies some values in the Type-5 LSA.

type type: Specifies a type for the Type-5 LSA: 1 or 2. If no type is specified, the default type for the Type-5 LSA specified by the default type command applies.

Usage guidelines

This command redistributes a default route in a Type-5 LSA, which cannot be redistributed with the import-route command. If the local routing table has no default route, you must provide the always keyword for the command.

Examples

# Generate a default route into the OSPF routing domain, regardless of whether the default route exists in the local routing table.

<Sysname> system-view

[Sysname] ospf 100

[Sysname-ospf-100] default-route-advertise always

Related commands

·     default

·     import-route

description (OSPF/OSPF area view)

Use description to configure a description for an OSPF process or area.

Use undo description to restore the default.

Syntax

description description

undo description

Default

No description is configured for an OSPF process or area.

Views

OSPF view, OSPF area view

Predefined user roles

network-admin

mdc-admin

Parameters

description: Configures a description for the OSPF process in OSPF view, or for the OSPF area in OSPF area view. The description argument specifies a string of 1 to 80 characters.

Usage guidelines

The description specified by this command is used to identify an OSPF process or area.

Examples

# Describe OSPF process 100 as abc.

<Sysname> system-view

[Sysname] ospf 100

[Sysname-ospf-100] description abc

# Describe OSPF area 0 as bone area.

<Sysname> system-view

[Sysname] ospf 100

[Sysname-ospf-100] area 0

[Sysname-ospf-100-area-0.0.0.0] description bone area

discard-route

Use discard-route to configure discard routes for summary networks.

Use undo discard-route to restore the default.

Syntax

discard-route { external { external-preference | suppression } | internal { internal-preference | suppression } } *

undo discard-route [ external | internal ]

Default

A device generates discard routes with preference 255 for summary networks.

Views

OSPF view

Predefined user roles

network-admin

mdc-admin

Parameters

external: Specifies discard routes for redistributed summary networks on the ASBR. These discard routes are external discard routes.

external-preference: Specifies a preference for external discard routes, in the range of 1 to 255.

suppression: Disables the ASBR from generating external discard routes for summary networks.

internal: Specifies discard routes for summary networks on the ABR. These discard routes are internal discard routes.

internal-preference: Specifies a preference for internal discard routes, in the range of 1 to 255.

suppression: Disables the ABR from generating internal discard routes for summary networks.

Examples

# Configure the device to generate external and internal discard routes with preferences 100 and 200, respectively.

<Sysname> system-view

[Sysname] ospf 100

[Sysname-ospf-100] discard-route external 100 internal 200

display ospf

Use display ospf to display OSPF process information.

Syntax

In standalone mode:

display ospf [ process-id ] [ verbose ] [ standby slot slot-number ]

In IRF mode:

display ospf [ process-id ] [ verbose ] [ standby chassis chassis-number slot slot-number ]

Views

Any view

Predefined user roles

network-admin

network-operator

mdc-admin

mdc-operator

Parameters

process-id: Specifies an OSPF process by its ID in the range of 1 to 65535. If you do not specify this argument, the command displays information about all OSPF processes.

verbose: Displays detailed OSPF process information. If you do not specify this keyword, the command displays brief OSPF process information.

standby slot slot-number: Displays backup OSPF process information for a card. If you do not specify this option, the command displays OSPF process information. (In standalone mode.)

standby chassis chassis-number slot slot-number: Displays backup OSPF process information for a card on an IRF member device. The chassis-number argument specifies the ID of the IRF member device. The slot-number argument specifies the slot number of the card. If you do not specify this option, the command displays OSPF process information. (In IRF mode.)

Examples

# Display detailed OSPF process information.

<Sysname> display ospf verbose

 

          OSPF Process 1 with Router ID 192.168.1.2

                  OSPF Protocol Information

 

 RouterID: 192.168.1.2      Router type:  NSSA

 Route tag: 0

 Multi-VPN-Instance is not enabled

 Opaque capable

 Originating router-LSAs with maximum metric

    Condition: On startup while BGP is converging, State: Inactive

    Advertise stub links with maximum metric in router-LSAs

    Advertise summary-LSAs with metric 16711680

    Advertise external-LSAs with metric 16711680

 ISPF is enabled

 SPF-schedule-interval: 5 50 200

 LSA generation interval: 5

 LSA arrival interval: 1000

 Transmit pacing: Interval: 20 Count: 3

 Default ASE parameters: Metric: 1 Tag: 1 Type: 2

 Route preference: 10

 ASE route preference: 150

 SPF computation count: 22

 RFC 1583 compatible

 Graceful restart interval: 120

 SNMP trap rate limit interval: 2  Count: 300

 This process is currently bound to MIB

 Area count: 1   NSSA area count: 1

 External areas with up interfaces: 0

 NSSA areas with up interfaces: 1

 Up interfaces: 1

 ExChange/Loading neighbors: 0

 Full neighbors:3

 Calculation trigger flag: Full

 Current calculation type: SPF calculation

 Current calculation phase: Calculation area topology

 Process reset state: N/A

 Current reset type: N/A

 Next reset type: N/A

 Reset prepare message replied: -/-/-/-

 Reset process message replied: -/-/-/-

 Reset phase of module:

   M-N/A, P-N/A, L-N/A, C-N/A, R-N/A

 

 

 Area: 0.0.0.1          (MPLS TE  not enabled)

 Authtype: None Area flag: NSSA

 7/5 translator state: Disabled

 7/5 translate stability timer interval: 0

 SPF scheduled count: 5

 ExChange/Loading neighbors: 0

 Up interfaces: 1

 

 Interface: 192.168.1.2 (Vlan-interface1)

 Cost: 1       State: DR        Type: Broadcast    MTU: 1500

 Priority: 1

 Designated router: 192.168.1.2

 Backup designated router: 192.168.1.1

 Timers: Hello 10 , Dead 40 , Poll  40 , Retransmit 5 , Transmit Delay 1

 FRR backup: Enabled

 Enabled by network configuration

Table 18 Command output

Field

Description

OSPF Process 1 with Router ID 192.168.1.2

OSPF process ID and OSPF router ID.

RouterID

Router ID.

Router type

Router type:

·     ABR.

·     ASBR.

·     NSSA.

·     Null.

Route tag

Tag of redistributed routes.

Multi-VPN-Instance is not enabled

The OSPF process does not support multi-VPN-instance.

Opaque capable

Opaque LSA advertisement and reception capability is enabled.

Originating router-LSAs with maximum metric

The maximum cost value for router LSAs (excluding stub links) is used.

Condition

Status of the stub router:

·     Always.

·     On startup while BGP is converging.

·     On startup while BGP is converging for XXX seconds.

·     On startup for XXX seconds.

State

Indicates whether the stub router is active.

SPF-schedule-interval

Interval for SPF calculations.

LSA generation interval

LSA generation interval.

LSA arrival interval

LSA arrival interval.

Transmit pacing

LSU packet transmit rate of the interface:

·     Interval—LSU transmit interval of the interface.

·     Count—Maximum number of LSU packets sent each time.

Default ASE Parameter

Default ASE Parameters: metric, tag, route type.

Route preference

Internal route preference.

ASE route preference

External route preference.

SPF computation count

SPF computation count of the OSPF process.

RFC1583 compatible

Compatible with RFC 1583.

SNMP trap rate limit interval

SNMP notification sending interval.

Count

Number of sent SNMP notifications.

ExChange/Loading neighbors

Neighbors in ExChange/Loading state.

Full neighbors

Neighbors in Full state.

Calculation trigger type

Route calculation trigger type:

·     Full—Calculation of all routes is triggered.

·     Area topology change—Topology change in an area.

·     Intra router change—Incremental intra-area route change.

·     ASBR change—Incremental ASBR route change.

·     7to5 translator—Type-7-to-Type-5 LSA translator role change.

·     Full IP prefix—Calculation of all IP prefixes is triggered.

·     Full intra AS—Calculation of all intra-AS prefixes is triggered.

·     Inc intra AS—Calculation of incremental intra-AS prefixes is triggered.

·     Full inter AS—Calculation of all AS-external prefixes is triggered.

·     Inc inter AS—Calculation of incremental AS-external prefixes is triggered.

·     N/A—Route calculation is not triggered.

Current calculation type

Current route calculation type:

·     SPF calculation.

·     Intra router calculationIntra-area route calculation.

·     ASBR calculationInter-area ASBR route calculation.

·     Inc intra routerIncremental intra-area route calculation.

·     Inc ASBR calculationIncremental inter-area ASBR route calculation.

·     7to5 translatorType-7-to-Type-5 LSA calculation.

·     Full intra ASCalculation of all intra-AS prefixes.

·     Inc intra ASCalculation of incremental intra-AS prefixes.

·     Full inter ASCalculation of all AS-external prefixes.

·     Inc inter ASCalculation of incremental AS-external prefixes.

·     Forward addressForwarding address calculation.

·     N/ARoute calculation is not triggered.

Current calculation phase

Current route calculation phase:

·     Calculation area topologyCalculating area topology.

·     Calculation router—Calculating routes on routers.

·     Calculation intra AS—Calculating intra-AS routes.

·     7to5 translator—Calculating Type-7-to-Type-5 LSAs.

·     Forward address—Calculating forwarding addresses.

·     Calculation inter AS—Calculating AS-external routes.

·     Calculation end—Ending phase of calculation.

·     N/A—Route calculation is not triggered.

Process reset state

Process reset state:

·     N/A—The process is not reset.

·     Under reset—The process is in the reset progress.

·     Under RIB smoothThe process is synchronizing the RIB.

Current reset type

Current process reset type:

·     N/A—The process is not reset.

·     Normal—Normal reset.

·     GR quit—Normal reset when GR quits abnormally.

·     Delete—Delete OSPF process.

·     VPN deleteDelete VPN.

Next reset type

Next process reset type:

·     N/AThe process is not reset.

·     Normal—Normal reset.

·     GR quitNormal reset when GR quits abnormally.

·     DeleteDelete OSPF process.

·     VPN deleteDelete VPN.

Reset prepare message replied

Modules that reply reset prepare messages:

·     PNeighbor maintenance module.

·     L—LSDB synchronization module.

·     C—Route calculation module.

·     R—Route redistribution module.

Reset process message replied

Modules that reply reset process messages:

·     PNeighbor maintenance module.

·     LLSDB synchronization module.

·     C—Route calculation module.

·     R—Route redistribution module.

Reset phase of module

Reset phase of each module:

·     Main control module:

¡     N/ANot reset.

¡     Delete area.

¡     Delete process.

·     Neighbor maintenance (P) module:

¡     N/A—Not reset.

¡     Delete neighbor.

¡     Delete interface.

¡     Delete vlink—Delete virtual link.

¡     Delete shamlink—Delete sham link.

·     LSDB synchronization (L) module:

¡     N/A—Not reset.

¡     Stop timer.

¡     Delete ASE—Delete all ASE LSAs.

¡     Delete ASE maps—Delete ASE LSA maps.

¡     Clear process data.

¡     Delete area LSA—Delete LSAs and maps from an area.

¡     Delete area interface—Delete interfaces from an area.

¡     Delete process—Delete process-related resources.

¡     Restart—Restart process-related resources.

·     Route calculation (C) module:

¡     N/A—Not reset.

¡     Delete topology—Delete area topology.

¡     Delete router—Delete routes of routers.

¡     Delete intra AS—Delete intra-AS routes

¡     Delete inter AS—Delete AS-external routes.

¡     Delete forward address—Delete forwarding address list.

¡     Delete advertise—Delete advertising router list.

·     Route redistribution (R) module:

¡     N/A—Not reset.

¡     Delete ABR summary—Delete summary routes of the ABR.

¡     Delete ASBR summary—Delete summary routes of the ASBR.

¡     Delete import—Delete redistributed routes.

7/5 translator state

State of the translator that translates Type-7 LSAs to Type-5 LSAs. The value can be one of the following:

·     Enabled—The translator is specified through commands.

·     Elected—The translator is designated through election.

·     Disabled—The device is not a translator.

7/5 translate stability timer interval

Stability interval for Type-7 LSA-to-Type-5 LSA translation.

ExChange/Loading Neighbors

Neighbors in ExChange/Loading state.

Area

Area ID in the IP address format.

Authtype

Authentication type of the area:

·     None—No authentication.

·     Simple—Simple authentication.

·     MD5—MD5 authentication.

Area flag

Type of the area:

·     Normal.

·     Stub.

·     StubNoSummary (totally stub area).

·     NSSA.

·     NSSANoSummary (totally NSSA area).

SPF scheduled Count

SPF calculation count in the OSPF area.

Interface

Interface in the area.

Cost

Interface cost.

State

Interface state.

Type

Interface network type.

MTU

Interface MTU.

Priority

Router priority.

Timers

OSPF timers:

·     Hello—Interval for sending hello packets.

·     Dead—Interval within which the neighbor is down.

·     Poll—Interval for sending hello packets.

·     Retransmit—Interval for retransmitting LSAs.

FRR backup

Indicates whether Loop Free Alternate (LFA) calculation is enabled on an interface.

 

display ospf abr-asbr

Use display ospf abr-asbr to display routes to the ABR or ASBR.

Syntax

display ospf [ process-id ] abr-asbr [ verbose ]

Views

Any view

Predefined user roles

network-admin

network-operator

mdc-admin

mdc-operator

Parameters

process-id: Specifies an OSPF process by its ID in the range of 1 to 65535. If you do not specify this argument, the command displays routes to the ABR and ASBR for all OSPF processes.

verbose: Displays detailed information. If you do not specify this keyword, the command displays brief information.

Usage guidelines

If you use this command on routers in a stub area, the commands displays no ASBR information.

Examples

# Display brief information about routes to the ABR or ASBR.

<Sysname> display ospf abr-asbr

 

          OSPF Process 1 with Router ID 192.168.1.2

                  Routing Table to ABR and ASBR

 

 Type        Destination       Area       Cost  Nexthop         RtType

 Inter       3.3.3.3           0.0.0.0    3124  10.1.1.2        ASBR

 Intra       2.2.2.2           0.0.0.0    1562  10.1.1.2        ABR

# Display detailed information about routes to the ABR or ASBR.

<Sysname> display ospf abr-asbr verbose

 

          OSPF Process 10 with Router ID 101.1.1.11

                  Routing Table to ABR and ASBR

 

 Destination: 1.1.1.1             RtType   : ASBR

 Area       : 0.0.0.1             Type     : Intra

 Nexthop    : 150.0.1.12          BkNexthop: 0.0.0.0

 Cost       : 1000

Table 19 Command output

Field

Description

Type

Type of the route to the ABR or ASBR:

·     IntraIntra-area route.

·     InterInter-area route.

Destination

Router ID of an ABR/ASBR.

Area

ID of the area of the next hop.

Cost

Cost from the router to the ABR/ASBR.

Nexthop

Next hop address.

BkNexthop

Backup next hop address.

RtType

Router type: ABR or ASBR.

 

display ospf abr-summary

Use display ospf abr-summary to display information about summary routes on the ABR.

Syntax

display ospf [ process-id ] [ area area-id ] abr-summary [ ip-address { mask-length | mask } ] [ verbose ]

Views

Any view

Predefined user roles

network-admin

network-operator

mdc-admin

mdc-operator

Parameters

process-id: Specifies an OSPF process by its ID in the range of 1 to 65535. If you do not specify this argument, the command displays information about ABR summary routes for all OSPF processes.

area area-id: Specifies an OSPF area by its ID, which is an IP address or a decimal integer in the range of 0 to 4294967295 that is translated into the IP address format. If you do not specify this option, the command displays information about ABR summary routes for all OSPF areas.

ip-address: Specifies a summary route by its IP address.

mask-length: Specifies the mask length in the range of 0 to 32.

mask: Specifies the mask in dotted decimal notation.

verbose: Displays detailed ABR summary route information. If you do not specify this keyword, the command displays brief ABR summary route information.

Usage guidelines

If no IP address is specified, this command displays information about all summary routes on the ABR.

Examples

# Display brief information about summary routes on the ABR.

<Sysname> display ospf abr-summary

 

          OSPF Process 1 with Router ID 2.2.2.2

                  ABR Summary Addresses

 

                          Area: 0.0.0.1

 Total summary addresses: 1

 Net             Mask            Status        Count      Cost

 100.0.0.0       255.0.0.0       Advertise     1          (Not Configured)

Table 20 Command output

Field

Description

Area

Area to which the summary routes belong.

Total summary addresses

Total number of summary routes.

Net

Address of the summary route.

Mask

Mask of the summary route address.

Status

Advertisement status of the summary route.

Count

Number of summarized routes.

Cost

Cost to the summary network.

 

# Display detailed information about summary routes on the ABR.

<Sysname> display ospf abr-summary verbose

 

          OSPF Process 1 with Router ID 2.2.2.2

                  ABR Summary Addresses

 

 Total summary address count: 1

 

                          Area: 0.0.0.1

Total summary addresses: 1

 

 Net         : 100.0.0.0

 Mask        : 255.0.0.0

 Status      : Advertise

 Cost        : (Not Configured)

 Routes count: 1

   Destination            NetMask                 Metric

   100.1.1.0              255.255.255.0           1000

Table 21 Command output

Field

Description

Destination

Destination address of a summarized route.

NetMask

Network mask of a summarized route.

Metric

Metric of a summarized route.

 

display ospf asbr-summary

Use display ospf asbr-summary to display information about the redistributed routes that are summarized.

Syntax

display ospf [ process-id ] asbr-summary [ ip-address { mask-length | mask } ]

Views

Any view

Predefined user roles

network-admin

network-operator

mdc-admin

mdc-operator

Parameters

process-id: Specifies an OSPF process by its ID in the range of 1 to 65535. If you do not specify this argument, the command displays the summarized redistributed routes for all OSPF processes.

ip-address: Specifies an IP address in dotted decimal notation.

mask-length: Specifies the mask length in the range of 0 to 32.

mask: Specifies the mask in dotted decimal notation.

Usage guidelines

If no IP address is specified, this command displays all summarized redistributed routes.

Examples

# Display information about all summarized redistributed routes for OSPF process 1.

<Sysname> display ospf 1 asbr-summary

 

          OSPF Process 1 with Router ID 2.2.2.2

                  Summary Addresses

 

 Total Summary Address Count: 1

 

                  Summary Address

 

 Net         : 30.1.0.0

 Mask        : 255.255.0.0

 Tag         : 20

 Status      : Advertise

 Cost        : 10 (Configured)

 The Count of Route is : 2

 

 Destination     Net Mask        Proto      Process   Type     Metric

 

 30.1.2.0        255.255.255.0   OSPF       2         2        1

 30.1.1.0        255.255.255.0   OSPF       2         2        1

Table 22 Command output

Field

Description

Total Summary Address Count

Total number of summary routes.

Net

Address of the summary route.

Mask

Mask of the summary route address.

Tag

Tag of the summary route.

Status

Advertisement status of the summary route.

Cost

Cost to the summary network.

The Count of Route

Number of summarized routes.

Destination

Destination address of a summarized route.

Net Mask

Network mask of a summarized route.

Proto

Routing protocol from which the route was redistributed.

Process

Process ID of the routing protocol from which the route was redistributed.

Type

Type of a summarized route.

Metric

Metric of a summarized route.

 

Related commands

asbr-summary

display ospf event-log

Use display ospf event-log to display OSPF route calculation log information for a process.

Syntax

display ospf [ process-id ] event-log { lsa-flush | peer | spf }

Views

Any view

Predefined user roles

network-admin

network-operator

mdc-admin

mdc-operator

Parameters

process-id: Specifies an OSPF process by its ID in the range of 1 to 65535. If you do not specify this argument, the command displays OSPF log information for all processes.

lsa-flush: Specifies LSA aging log information.

peer: Specifies neighbor log information.

spf: Specifies route calculation log information.

Usage guidelines

The route statistics are the number of routes newly installed in the IP routing table.

Neighbor logs include information about the following events:

·     The OSPF neighbor state goes down.

·     The OSPF neighbor state goes backward because the local end receives BadLSReq, SeqNumberMismatch, and 1-Way events.

Examples

# Display OSPF LSA aging log information for all processes.

<Sysname> display ospf event-log lsa-flush

 

          OSPF Process 1 with Router ID 1.1.1.1

                  LSA Flush Log

 

 Date: 2013-09-22 Time: 14:47:33 Received MaxAge LSA from 10.1.1.1

 Type: 1   LSID: 2.2.2.2         AdvRtr: 2.2.2.2           Seq#: 80000001

 

 Date: 2013-09-22 Time: 14:47:33 Flushed MaxAge LSA by the self

 Type: 1   LSID: 1.1.1.1         AdvRtr: 1.1.1.1           Seq#: 80000001

 

 Date: 2013-09-22 Time: 14:47:33 Received MaxAge LSA from 10.1.2.2

 Type: 1   LSID: 2.2.2.2         AdvRtr: 2.2.2.2           Seq#: 80000001

 

 Date: 2013-09-22 Time: 14:47:33 Flushed MaxAge LSA by the self

 Type: 1   LSID: 1.1.1.1         AdvRtr: 1.1.1.1           Seq#: 80000001

Table 23 Command output

Field

Description

Date/Time

Time when the device receives an LSA that has reached the maximum age.

Received MaxAge LSA from X.X.X.X

The device received an LSA that has reached the maximum age from X.X.X.X.

Flushed MaxAge LSA by the self

The device flushed the LSA that has reached the maximum age.

Type

LSA type.

LSID

LSA link state ID.

AdvRtr

Advertising router.

Seq#

LSA sequence number.

 

# Display OSPF route calculation log information for all processes.

<Sysname> display ospf event-log spf

 

          OSPF Process 1 with Router ID 1.1.1.2

                  SPF log

 

Date       Time     Duration   Intra Inter External Reason

2012-06-27 15:28:26 0.95       1     1     10000    Intra-area LSA

2012-06-27 15:28:23 0.2        0     0     0        Area 0 full neighbor number

2012-06-27 15:28:19 0          0     0     0        Intra-area LSA

2012-06-27 15:28:19 0          0     0     0        external LSA

2012-06-27 15:28:19 0.3        0     0     0        Intra-area LSA

2012-06-27 15:28:12 0          1     0     0        Intra-area LSA

2012-06-27 15:28:11 0          0     0     0        Routing policy

2012-06-27 15:28:11 0          0     0     0        Intra-area LSA

Table 24 Command output

Field

Description

Date/Time

Time when the route calculation starts.

Duration

Duration of the route calculation, in seconds.

Intra

Number of intra-area routes newly installed in the IP routing table.

Inter

Number of inter-area routes newly installed in the IP routing table.

External

Number of external routes newly installed in the IP routing table.

Reason

Reasons why the route calculation is performed:

·     Intra-area LSAIntra-area LSA changes.

·     Inter-area LSAInter-area LSA changes.

·     External LSAExternal LSA changes.

·     Configuration—Configuration changes.

·     Area 0 full neighbor numberNumber of FULL-state neighbors in Area 0 changes.

·     Area 0 up interface numberNumber of interfaces in up state in Area 0 changes.

·     LSDB overflow stateOverflow status changes.

·     AS numberAS number changes.

·     ABR summarizationABR summarization changes.

·     GR endGR ends.

·     Routing policyRouting policy changes.

·     OthersOther reasons.

 

# Display OSPF neighbor log information for OSPF process 1.

<Sysname> display ospf 1 event-log peer

 

          OSPF Process 1 with Router ID 1.1.1.1

                  Neighbors log

 

Date       Time     Local Address   Remote Address  Router ID       Reason

2012-12-31 12:35:45 197.168.1.1     197.168.1.2     2.2.2.2         IntPhyChange

2012-12-31 12:35:19 197.168.1.1     197.168.1.2     2.2.2.2         ConfNssaArea

2012-12-31 12:34:59 197.168.1.1     197.168.1.2     2.2.2.2         SilentInt

Table 25 Command output

Field

Description

Date/Time

Time when the neighbor state changes.

Local Address

Local address of the neighbor relationship.

Remote Address

Peer address of the neighbor relationship.

Router ID

Neighbor router ID.

Reason

Reasons for neighbor state changes:

·     ResetConnectThe connection is lost due to insufficient memory.

·     IntChangeThe interface parameter has changed.

·     VlinkChangeThe virtual link parameter has changed.

·     ShamlinkChangeThe sham link parameter has changed.

·     ResetOspfThe OSPF process is reset.

·     UndoOspfThe OSPF process is deleted.

·     UndoAreaThe OSPF area is deleted.

·     UndoNetworkThe interface is disabled.

·     SilentIntThe interface is configured as a silent interface.

·     IntLogChangeThe logical attribute of the interface has changed.

·     IntPhyChangeThe physical attribute of the interface has changed.

·     IntVliChangeThe virtual link attribute of the interface has changed.

·     VlinkDownThe virtual link goes down.

·     ShamlinkDownThe sham link goes down.

·     DeadExpiredThe dead timer expires.

·     ConfStubArea—The interface is configured with stub area parameters.

·     ConfNssaArea—The interface is configured with NSSA area parameters.

·     AuthChangeThe authentication type has changed.

·     OpaqueChangeThe Opaque capability has changed.

·     Retrans—Excessive retransmissions.

·     LLSChangeThe LLS capability has changed.

·     OOBChangeThe OOB capability has changed.

·     GRChangeThe GR capability has changed.

·     BFDDown—The interface is shut down by BFD.

·     BadLSReq—The interface receives BadLSReq events.

·     SeqMismatch—The interface receives SeqNumberMismatch events.

·     1-Way—The interface receives 1-Way events.

 

display ospf fast-reroute lfa-candidate

Use display ospf fast-reroute lfa-candidate to display OSPF FRR backup next hop information.

Syntax

display ospf [ process-id ] [ area area-id ] fast-reroute lfa-candidate

Views

Any view

Predefined user roles

network-admin

network-operator

mdc-admin

mdc-operator

Parameters

process-id: Specifies an OSPF process by its ID in the range of 1 to 65535. If you do not specify this argument, the command displays FRR backup next hop information for all processes.

area area-id: Specifies an OSPF area by its ID, which is an IP address or a decimal integer in the range of 0 to 4294967295 that is translated into the IP address format. If you do not specify this option, the command displays FRR backup next hop information for all OSPF areas.

Examples

# Display OSPF FRR backup next hop information.

<Sysname> display ospf 1 area 0 fast-reroute lfa-candidate

 

          OSPF Process 1 with Router ID 2.2.2.2

                  LFA Candidate List

 

 Area: 0.0.0.0

 Candidate nexthop count: 2

 NextHop          IntIP            Interface

 10.0.1.1         10.0.1.2         Vlan10

 10.0.11.1        10.0.11.2        Vlan20

Table 26 Command output

Field

Description

Area

Area to which the backup next hops belong.

Candidate nexthop count

Number of backup next hops.

NextHop

Backup next hop address.

IntIP

IP address of the output interface.

Interface

Output interface.

 

display ospf graceful-restart

Use display ospf graceful-restart to display GR information for an OSPF process.

Syntax

display ospf [ process-id ] graceful-restart [ verbose ]

Views

Any view

Predefined user roles

network-admin

network-operator

mdc-admin

mdc-operator

Parameters

process-id: Specifies an OSPF process by its ID in the range of 1 to 65535. If you do not specify this argument, the command displays GR information for all processes.

verbose: Displays detailed GR information. If you do not specify this keyword, the command displays brief GR information.

Examples

# Display detailed GR information.

<Sysname> display ospf graceful-restart verbose

 

          OSPF Process 1 with Router ID 1.1.1.1

              Graceful Restart information

 

Graceful Restart capability     : Enable(IETF)

Graceful Restart support        : Planned and un-planned,Partial

Helper capability               : Enable(IETF)

Helper support                  : Planned and un-planned(IETF),Strict LSA check

Current GR state                : Normal

Graceful Restart period         : 40 seconds

Number of neighbors under Helper: 0

Number of restarting neighbors  : 0

Last exit reason:

  Restarter  : None

  Helper     : None

 

Area: 0.0.0.0

Authtype: None Area flag: Normal

Area up Interface count: 2

 

Interface: 40.4.0.1 (Vlan-interface40)

Restarter state: Normal  State: P-2-P     Type: PTP

Last exit reason:

  Restarter  : None

  Helper     : None

Neighbor count of this interface: 1

Number of neighbors under Helper: 0

Neighbor        IP address      GR state     Last Helper exit reason

3.3.3.3         40.4.0.3        Normal       None

 

Virtual-link Neighbor-ID  -> 4.4.4.4, Neighbor-State: Full

Restarter state: Normal

Interface: 20.2.0.1 (Vlink)

Transit Area: 0.0.0.1

Last exit reason:

  Restarter  : None

  Helper     : None

Neighbor        IP address      GR state     Last Helper exit reason

4.4.4.4         20.2.0.4        Normal       Reset neighbor

Table 27 Command output

Field

Description

OSPF Process 1 with Router ID 1.1.1.1

Graceful Restart information

GR information for OSPF process 1 with router ID 1.1.1.1.

Graceful Restart capability

Indicates whether GR is enabled:

·     Enable(IETF)—IETF GR is enabled.

·     Enable(Nonstandard)—Non-IETF GR is enabled.

·     Disable—GR is disabled.

Graceful Restart support

GR modes that the process supports (the modes are displayed only when GR is enabled):

·     Planned and un-planned—Supports both planned and unplanned GR.

·     Planned only—Supports only planned GR.

·     Partial—Supports partial GR.

·     Global—Supports global GR.

Helper capability

Helper capability that the process supports:

·     Enable (IETF)—Supports IETF GR helper capability.

·     Enable (Nonstandard)—Supports non IETF GR helper capability.

·     Enable (IETF and nonstandard)—Supports both IETF GR helper capability and non IETF GR helper capability.

·     Disable—Does not support GR helper capability.

Helper support

Displays policies that the helper supports (the policies are displayed only when GR helper is enabled):

·     Strict lsa check—The helper supports strict LSA checking.

·     Planned and un-planned—The helper supports planned and unplanned GR.

·     Planned only—The helper supports only planned GR.

Current GR state

GR state:

·     Normal—Normal state.

·     Under GR—GR is in process.

·     Under Helper—The process is acting as GR helper.

Last exit reason

Last exit reason:

·     Restarter—Reason that the restarter exited last time.

·     Helper—Reason that the helper exited last time.

Area

Area ID in IP address format.

Authtype

Authentication type of the area:

·     None—No authentication.

·     Simple—Simple authentication.

·     MD5—MD5 authentication.

Area flag

Type of the area:

·     Normal.

·     Stub.

·     StubNoSummary (totally stub area).

·     NSSA.

·     NSSANoSummary (totally NSSA area).

Area up Interface count

Number of up interfaces in the area.

Interface

Interface in the area.

Restarter state

Restarter state on the interface.

State

Interface state.

Type

Interface network type.

Neighbor count of this interface

Neighbors of an interface.

Neighbor

Neighbor router ID.

IP address

Neighbor IP address.

GR state

Neighbor GR state:

·     Normal—Normal state.

·     Under GR—GR is in process.

·     Under Helper—The process is acting as GR helper.

Last Helper exit reason

Reason that the helper exited last time.

Virtual-link Neighbor-ID

Router ID of the virtual link's neighbor.

Neighbor-State

Neighbor state: Down, Init, 2-Way, ExStart, Exchange, Loading, and Full.

Interface

Output interface of the virtual link.

 

display ospf interface

Use display ospf interface to display OSPF interface information.

Syntax

In standalone mode:

display ospf [ process-id ] interface [ interface-type interface-number | verbose ] [ standby slot slot-number ]

In IRF mode:

display ospf [ process-id ] interface [ interface-type interface-number | verbose ] [ standby chassis chassis-number slot slot-number ]

Views

Any view

Predefined user roles

network-admin

network-operator

mdc-admin

mdc-operator

Parameters

process-id: Specifies an OSPF process ID in the range of 1 to 65535. If you do not specify this argument, the command displays the OSPF interface information for all OSPF processes.

interface-type interface-number: Specifies an interface by its type and number.

verbose: Displays detailed OSPF information for all interfaces.

standby slot slot-number: Displays backup OSPF interface information for a card. If you do not specify this option, the command displays OSPF interface information. (In standalone mode.)

standby chassis chassis-number slot slot-number: Displays backup OSPF interface information for a card on an IRF member device. The chassis-number argument specifies the ID of the IRF member device. The slot-number argument specifies the slot number of the card. If you do not specify this option, the command displays OSPF interface information. (In IRF mode.)

Usage guidelines

If you do not provide the interface or the verbose keyword, this command displays OSPF brief information for all interfaces.

Examples

# Display all OSPF interface brief information.

<Sysname> display ospf interface

 

          OSPF Process 1 with Router ID 192.168.1.1

                  Interfaces

 

 Area: 0.0.0.0

 IP Address      Type         State    Cost  Pri   DR              BDR

 192.168.1.1     PTP          P-2-P    1562  1     0.0.0.0         0.0.0.0

 

 Area: 0.0.0.1

 IP Address      Type         State    Cost  Pri   DR              BDR

 172.16.0.1      Broadcast    DR       1     1     172.16.0.1      0.0.0.0

Table 28 Command output

Field

Description

Area

Area ID of the interface.

IP address

Interface IP address (regardless of whether TE is enabled or not).

Type

Interface network type: PTP, PTMP, Broadcast, or NBMA.

State

Interface state:

·     DOWNNo protocol traffic can be sent or received on the interface.

·     WaitingThe interface starts sending and receiving Hello packets and the router is trying to determine the identity of the (Backup) designated router for the network.

·     P-2-PThe interface will send Hello packets at the interval of HelloInterval, and try to establish an adjacency with the neighbor.

·     DRThe router is the designated router on the network.

·     BDRThe router is the backup designated router on the network.

·     DROtherThe router is a DROther router on the attached network.

Cost

Interface cost.

Pri

Router priority.

DR

DR on the interface's network segment.

BDR

BDR on the interface's network segment.

 

# Display detailed information about VLAN-interface 1.

<Sysname> display ospf interface Vlan-interface 1

 

 

          OSPF Process 1 with Router ID 192.168.1.1

                  Interfaces

 

 

 Interface: 172.16.0.1 (Vlan-interface1)

 Cost: 1       State: DR        Type: Broadcast    MTU: 1500

 Priority: 1

 Designated router: 172.16.0.1

 Backup designated router: 0.0.0.0

 Timers: Hello 10, Dead 40, Poll  40, Retransmit 5, Transmit Delay 1

 FRR backup: Enabled

 Enabled by interface configuration (including secondary IP addresses)

 MD5 authentication enabled.

    The last key is 3.

    The rollover is in progress, 2 neighbor(s) left.

Table 29 Command output

Field

Description

Interface

Information about the interface, such as the IP address.

Timers

OSPF timers: hello, dead, poll, retransmit, and transmit delay.

FRR backup

Indicates whether LFA calculation is enabled on an interface.

Enabled by interface configuration (including secondary IP addresses)

OSPF is enabled on the interface (including secondary IP addresses).

MD5 authentication enabled

Authentication mode.

The last key

Current MD5 authentication key ID.

neighbor(s)

Number of neighbors that have not completed key rollover.

 

display ospf lsdb

Use display ospf lsdb to display OSPF LSDB information.

Syntax

In standalone mode:

display ospf [ process-id ] lsdb [ area area-id | brief | [ { asbr | ase | network | nssa | opaque-area | opaque-as | opaque-link | router | summary } [ link-state-id ] ] [ originate-router advertising-router-id | self-originate ] ] [ standby slot slot-number ]

In IRF mode:

display ospf [ process-id ] lsdb [ area area-id | brief | [ { asbr | ase | network | nssa | opaque-area | opaque-as | opaque-link | router | summary } [ link-state-id ] ] [ originate-router advertising-router-id | self-originate ] ] [ standby chassis chassis-number slot slot-number ]

Views

Any view

Predefined user roles

network-admin

network-operator

mdc-admin

mdc-operator

Parameters

process-id: Specifies an OSPF process by its ID in the range of 1 to 65535. If you do not specify this argument, the command displays LSDB information for all OSPF processes.

area area-id: Specifies an OSPF area by its ID, which is an IP address or a decimal integer in the range of 0 to 4294967295 that is translated into the IP address format. If you do not specify this option, the command displays LSDB information for all OSPF areas.

brief: Displays brief LSDB information.

asbr: Displays Type-4 LSA (ASBR Summary LSA) information in the LSDB.

ase: Displays Type-5 LSA (AS External LSA) information in the LSDB.

network: Displays Type-2 LSA (Network LSA) information in the LSDB.

nssa: Displays Type-7 LSA (NSSA External LSA) information in the LSDB.

opaque-area: Displays Type-10 LSA (Opaque-area LSA) information in the LSDB.

opaque-as: Displays Type-11 LSA (Opaque-AS LSA) information in the LSDB.

opaque-link: Displays Type-9 LSA (Opaque-link LSA) information in the LSDB.

router: Displays Type-1 LSA (Router LSA) information in the LSDB.

summary: Displays Type-3 LSA (Network Summary LSA) information in the LSDB.

link-state-id: Specifies a link state ID in the IP address format.

originate-router advertising-router-id: Specifies an advertising router by its ID.

self-originate: Displays information about self-originated LSAs.

standby slot slot-number: Display backup OSPF LSDB information for a card. If you do not specify this option, the command displays OSPF LSDB information. (In standalone mode.)

standby chassis chassis-number slot slot-number: Displays backup OSPF LSDB information for a card on an IRF member device. The chassis-number argument specifies the ID of the IRF member device. The slot-number argument specifies the slot number of the card. If you do not specify this option, the command displays OSPF LSDB information. (In IRF mode.)

Examples

# Display OSPF LSDB information.

<Sysname> display ospf lsdb

         OSPF Process 1 with Router ID 192.168.0.1

                 Link State Database

 

                         Area: 0.0.0.0

 Type      LinkState ID    AdvRouter          Age  Len   Sequence   Metric

 Router    192.168.0.2     192.168.0.2        474  36    80000004   0

 Router    192.168.0.1     192.168.0.1        21   36    80000009   0

 Network   192.168.0.1     192.168.0.1        321  32    80000003   0

 Sum-Net   192.168.1.0     192.168.0.1        321  28    80000002   1

 Sum-Net   192.168.2.0     192.168.0.2        474  28    80000002   1

                         Area: 0.0.0.1

 Type      LinkState ID    AdvRouter          Age  Len   Sequence   Metric

 Router    192.168.0.1     192.168.0.1        21   36    80000005   0

 Sum-Net   192.168.2.0     192.168.0.1        321  28    80000002   2

 Sum-Net   192.168.0.0     192.168.0.1        321  28    80000002   1

Type 9 Opaque (Link-Local Scope) Database

 Flags: * -Vlink interface LSA

 Type      LinkState ID    AdvRouter          Age  Len   Sequence   Interfaces

*Opq-Link  3.0.0.0         7.2.2.1            8    14    80000001   10.1.1.2

*Opq-Link  3.0.0.0         7.2.2.2            8    14    80000001   20.1.1.2

Table 30 Command output

Field

Description

Area

LSDB information of the area.

Type

LSA type.

LinkState ID

Link state ID.

AdvRouter

Advertising router.

Age

Age of the LSA.

Len

Length of the LSA.

Sequence

Sequence number of the LSA.

Metric

Cost of the LSA.

*Opq-Link

Opaque LSA generated by a virtual link.

 

# Display Type-2 LSA (Network LSA) information in the LSDB.

<Sysname> display ospf 1 lsdb network

                    

          OSPF Process 1 with Router ID 192.168.1.1

                          Area: 0.0.0.0

                  Link State Database

 

    Type      : Network

    LS ID     : 192.168.0.2

    Adv Rtr   : 192.168.2.1

    LS Age    : 922

    Len       : 32

    Options   :  E

    Seq#      : 80000003

    Checksum    : 0x8d1b

    Net Mask  : 255.255.255.0

       Attached Router    192.168.1.1

       Attached Router    192.168.2.1

                          Area: 0.0.0.1

                  Link State Database

    Type      : Network

    LS ID     : 192.168.1.2

    Adv Rtr   : 192.168.1.2

    LS Age    : 782

    Len       : 32

    Options   :  NP

    Seq#      : 80000003

    Checksum    : 0x2a77

    Net Mask  : 255.255.255.0

       Attached Router    192.168.1.1

       Attached Router    192.168.1.2

Table 31 Command output

Field

Description

Type

LSA type.

LS ID

DR IP address.

Adv Rtr

Router that advertised the LSA.

LS Age

LSA age time.

Len

LSA length.

Options

LSA options:

·     O—Opaque LSA advertisement capability.

·     E—AS External LSA reception capability.

·     EA—External extended LSA reception capability.

·     DC—On-demand link support.

·     N—NSSA external LSA support.

·     P—Capability of an NSSA ABR to translate Type-7 LSAs into Type-5 LSAs.

Seq#

LSA sequence number.

Checksum

LSA checksum.

Net Mask

Network mask.

Attached Router

ID of the router that established adjacency with the DR, and ID of the DR itself.

 

display ospf nexthop

Use display ospf nexthop to display OSPF next hop information.

Syntax

display ospf [ process-id ] nexthop

Views

Any view

Predefined user roles

network-admin

network-operator

mdc-admin

mdc-operator

Parameters

process-id: Specifies an OSPF process by its ID in the range of 1 to 65535. If you do not specify this argument, the command displays next hop information for all OSPF processes.

Examples

# Display OSPF next hop information.

<Sysname> display ospf nexthop

 

          OSPF Process 1 with Router ID 1.1.1.2

                  Neighbor Nexthop Information

 

 NbrID           Nexthop         Interface                RefCount   Status

 1.1.1.2         4.4.4.4         Loop1                    1          Valid

 1.1.1.1         1.1.1.1         Vlan1                    3          Valid

 1.1.1.2         1.1.1.2         Vlan1                    4          Valid

Table 32 Command output

Field

Description

NbrId

Neighbor router ID.

Nexthop

Next hop address.

Interface

Output interface.

RefCount

Reference count (routes that reference the next hop).

Status

Next hop status: valid or invalid.

 

display ospf peer

Use display ospf peer to display information about OSPF neighbors.

Syntax

In standalone mode:

display ospf [ process-id ] peer [ verbose ] [ interface-type interface-number ] [ neighbor-id ] [ standby slot slot-number ]

In IRF mode:

display ospf [ process-id ] peer [ verbose ] [ interface-type interface-number ] [ neighbor-id ] [ standby chassis chassis-number slot slot-number ]

Views

Any view

Predefined user roles

network-admin

network-operator

mdc-admin

mdc-operator

Parameters

process-id: Specifies an OSPF process by ID in the range of 1 to 65535. If you do not specify this argument, the command displays OSPF neighbor information for all OSPF processes.

verbose: Displays detailed neighbor information. If you do not specify this keyword, the command displays brief OSPF neighbor information.

interface-type interface-number: Specifies an interface by its type and number. If you do not specify this argument, the command displays the neighbor information for all interfaces.

neighbor-id: Specifies a neighbor router ID. If you do not specify this argument, the command displays all neighbor information.

standby slot slot-number: Displays backup OSPF neighbor information for a card. If you do not specify this option, the command displays OSPF neighbor information. (In standalone mode.)

standby chassis chassis-number slot slot-number: Displays backup OSPF neighbor information for a card on an IRF member device. The chassis-number argument specifies the ID of the IRF member device. The slot-number argument specifies the slot number of the card. If you do not specify this option, the command displays OSPF neighbor information. (In IRF mode.)

Examples

# Display detailed OSPF neighbor information.

<Sysname> display ospf peer verbose

 

          OSPF Process 1 with Router ID 1.1.1.1

                  Neighbors

 

 Area 0.0.0.0 interface 1.1.1.1(Vlan-interface1)'s neighbors

 Router ID: 1.1.1.2          Address: 1.1.1.2          GR state: Normal

   State: Full  Mode: Nbr is master  Priority: 1

   DR: 1.1.1.2  BDR: 1.1.1.1  MTU: 0

   Options is 0x02 (-|-|-|-|-|-|E|-)

   Dead timer due in 33  sec

   Neighbor is up for 02:03:35

   Authentication Sequence: [ 0 ]

   Neighbor state change count: 6

   BFD status: Disabled

 

                  Neighbors

 

 Sham link 11.11.11.11 -> 22.22.22.22's neighbor in area 0.0.0.1

 Router ID: 22.22.22.22      Address: 22.22.22.22

   State: Full  Mode: Nbr is master  Priority: 1

   BFD status: Disabled

Table 33 Command output

Field

Description

Area areaID interface IPAddress(InterfaceName)'s neighbors

Neighbor information of the interface in the specified area:

·     areaID—Area to which the neighbor belongs.

·     IPAddress—Interface IP address.

·     InterfaceName—Interface name.

Router ID

Neighbor router ID.

Address

Neighbor router address.

GR State

GR state:

·     Normal.

·     Restarter.

·     Complete.

·     Helper.

State

Neighbor state:

·     Down—Initial state of a neighbor conversation.

·     Init—The router has seen a Hello packet from the neighbor. However, the router has not established bidirectional communication with the neighbor (the router itself did not appear in the neighbor's hello packet).

·     Attempt—Available only in an NBMA network, Under this state, the OSPF router has not received any information from a neighbor for a period but can send Hello packets at a longer interval to keep neighbor relationship.

·     2-Way—Communication between the two routers is bidirectional. The router itself appears in the neighbor's Hello packet.

·     Exstart—The goal of this state is to decide which router is the master, and to decide upon the initial Database Description (DD) sequence number.

·     Exchange—The router is sending DD packets to the neighbor, describing its entire link-state database.

·     Loading—The router sends LSRs packets to the neighbor, requesting more recent LSAs.

·     Full—The neighboring routers are fully adjacent.

Mode

Neighbor mode for LSDB synchronization.

Priority

Neighboring router priority.

DR

DR on the interface's network segment.

BDR

BDR on the interface's network segment.

MTU

Interface MTU.

Options

LSA options:

·     O—Opaque LSA advertisement capability.

·     E—AS External LSA reception capability.

·     EA—External extended LSA reception capability.

·     DC—On-demand link support.

·     N—NSSA external LSA support.

·     P—Capability of an NSSA ABR to translate Type-7 LSAs into Type-5 LSAs.

Dead timer due in 33 sec

This dead timer will expire in 33 seconds.

Neighbor is up for 02:03:35

The neighbor has been up for 02:03:35.

Authentication Sequence

Authentication sequence number.

Neighbor state change count

Count of neighbor state changes.

Sham link 11.11.11.11 -> 22.22.22.22's neighbor in area 0.0.0.1

Sham link (from 11.11.11.11 to 22.22.22.22) neighbor in Area 1.

BFD status

BFD status:

·     Disabled.

·     Enabled (Control mode).

·     Enabled (Echo mode).

 

# Display brief OSPF neighbor information.

<Sysname> display ospf peer

 

                   OSPF Process 1 with Router ID 1.1.1.1

                        Neighbor Brief Information

 

 Area: 0.0.0.0

 Router ID       Address         Pri Dead-Time Interface       State

 1.1.1.2         1.1.1.2         1   40        Vlan1           Full/DR

 

 Sham link: 11.11.11.11 -> 22.22.22.22

 Router ID       Address         Pri  Dead-Time  State

 22.22.22.22     22.22.22.22     1    36         Full

Table 34 Command output

Field

Description

Area

Neighbor area.

Router ID

Neighbor router ID.

Address

Neighbor interface address.

Pri

Neighboring router priority.

Dead-Time

Dead interval remained.

Interface

Interface connected to the neighbor.

State

Neighbor state: Down, Init, Attempt, 2-Way, Exstart, Exchange, Loading, or Full.

Sham link 11.11.11.11 -> 22.22.22.22

Sham link from 11.11.11.11 to 22.22.22.22.

 

display ospf peer statistics

Use display ospf peer statistics to display OSPF neighbor statistics.

Syntax

In standalone mode:

display ospf [ process-id ] peer statistics [ standby slot slot-number ]

In IRF mode:

display ospf [ process-id ] peer statistics [ standby chassis chassis-number slot slot-number ]

Views

Any view

Predefined user roles

network-admin

network-operator

mdc-admin

mdc-operator

Parameters

process-id: Specifies an OSPF process by its ID in the range of 1 to 65535. If you do not specify this argument, the command displays OSPF neighbor statistics for all OSPF processes.

standby slot slot-number: Displays backup OSPF neighbor statistics of a card. If you do not specify this option, the command displays OSPF neighbor statistics. (In standalone mode.)

standby chassis chassis-number slot slot-number: Displays backup OSPF neighbor statistics of a card on an IRF member device. The chassis-number argument specifies the ID of the IRF member device. The slot-number argument specifies the slot number of the card. If you do not specify this option, the command displays OSPF neighbor statistics. (In IRF mode.)

Examples

# Display OSPF neighbor statistics.

<Sysname> display ospf peer statistics

          OSPF Process 1 with Router ID 10.3.1.1

                    Neighbor Statistics

  Area ID         Down Attempt Init 2-Way ExStart Exchange Loading Full Total

  0.0.0.0         0    0       0    0     0       0        0       1    1

  0.0.0.2         0    0       0    0     0       0        0       1    1

  Total           0    0       0    0     0       0        0       2    2

 

  Sham links' neighbors (Total: 1):

    Down: 0, Init: 0, 2-Way: 0, ExStart: 0, Exchange: 0, Loading: 0, Full: 1

Table 35 Command output

Field

Description

Area ID

The state statistics information of all the routers in the area to which the router belongs is displayed.

Down

Number of neighboring routers in Down state in the same area.

Attempt

Number of neighboring routers in Attempt state in the same area.

Init

Number of neighboring routers in Init state in the same area.

2-Way

Number of neighboring routers in 2-Way state in the same area.

ExStart

Number of neighboring routers in ExStart state in the same area.

Exchange

Number of neighboring routers in Exchange state in the same area.

Loading

Number of neighboring routers in Loading state in the same area.

Full

Number of neighboring routers in Full state in the same area.

Total

Total number of neighbors under the same state: Down, Attempt, Init, 2-Way, ExStart, Exchange, Loading, or Full.

Sham links' neighbors

Statistics of sham links' neighbors.

 

display ospf request-queue

Use display ospf request-queue to display OSPF request queue information.

Syntax

display ospf [ process-id ] request-queue [ interface-type interface-number ] [ neighbor-id ]

Views

Any view

Predefined user roles

network-admin

network-operator

mdc-admin

mdc-operator

Parameters

process-id: Specifies an OSPF process by its ID in the range of 1 to 65535. If you do not specify this argument, the command displays the OSPF request queue information for all OSPF processes.

interface-type interface-number: Specifies an interface by its type and number. If you do not specify this argument, the command displays the OSPF request queue information for all interfaces.

neighbor-id: Specifies a neighbor's router ID. If you do not specify this argument, the command displays the OSPF request queue information for all OSPF neighbors.

Examples

# Display OSPF request queue information.

<Sysname> display ospf request-queue

 

  The Router's Neighbor is Router ID 2.2.2.2         Address 10.1.1.2

  Interface 10.1.1.1         Area 0.0.0.0

  Request list:

       Type       LinkState ID      AdvRouter         Sequence   Age

       Router     2.2.2.2           1.1.1.1           80000004   1

       Network    192.168.0.1       1.1.1.1           80000003   1

       Sum-Net    192.168.1.0       1.1.1.1           80000002   2

Table 36 Command output

Field

Description

The Router's Neighbor is Router ID

Neighbor router ID.

Address

Neighbor interface IP address.

Interface

Local interface IP address.

Area

Area ID.

Request list

Request list information.

Type

LSA type.

LinkState ID

Link state ID.

AdvRouter

Advertising router.

Sequence

LSA sequence number.

Age

LSA age.

 

display ospf retrans-queue

Use display ospf retrans-queue to display retransmission queue information.

Syntax

display ospf [ process-id ] retrans-queue [ interface-type interface-number ] [ neighbor-id ]

Views

Any view

Predefined user roles

network-admin

network-operator

mdc-admin

mdc-operator

Parameters

process-id: Specifies an OSPF process by its ID in the range of 1 to 65535. If you do not specify this argument, the command displays retransmission queue information for all OSPF processes.

interface-type interface-number: Specifies an interface by its type and number. If you do not specify this argument, the command displays retransmission queue information for all interfaces.

neighbor-id: Specifies a neighbor's router ID. If you do not specify this argument, the command displays retransmission queue information for all neighbors.

Examples

# Display OSPF retransmission queue information.

<Sysname> display ospf retrans-queue

 

  The Router's Neighbor is Router ID 2.2.2.2         Address 10.1.1.2

  Interface 10.1.1.1         Area 0.0.0.0

  Retransmit list:

       Type       LinkState ID      AdvRouter         Sequence   Age

       Router     2.2.2.2           2.2.2.2           80000004   1

       Network    12.18.0.1         2.2.2.2           80000003   1

       Sum-Net    12.18.1.0         2.2.2.2           80000002   2

Table 37 Command output

Field

Description

The Router's Neighbor is Router ID

Neighbor router ID.

Address

Neighbor interface IP address.

Interface

Interface address of the router.

Area

Area ID.

Retrans List

Retransmission list.

Type

LSA type.

LinkState ID

Link state ID.

AdvRouter

Advertising router.

Sequence

LSA sequence number.

Age

LSA age.

 

display ospf routing

Use display ospf routing to display OSPF routing information.

Syntax

display ospf [ process-id ] routing [ ip-address { mask-length | mask } ] [ interface interface-type interface-number ] [ nexthop nexthop-address ] [ verbose ]

Views

Any view

Predefined user roles

network-admin

network-operator

mdc-admin

mdc-operator

Parameters

process-id: Specifies an OSPF process by its ID in the range of 1 to 65535. If you do not specify this argument, the command displays the routing information for all OSPF processes.

ip-address: Specifies a destination IP address.

mask-length: Specifies mask length in the range of 0 to 32.

mask: Specifies the mask in dotted decimal notation.

interface interface-type interface-number: Displays routes passing the specified output interface. If you do not specify this option, the command displays OSPF routing information for all interfaces.

nexthop nexthop-address: Displays routes passing the specified next hop. If you do not specify this option, the command displays all OSPF routing information.

verbose: Displays detailed OSPF routing information. If you do not specify this keyword, the command displays brief OSPF routing information.

Usage guidelines

If no OSPF process is specified, this command displays the routing information for all OSPF processes.

If no interface is specified, this command displays OSPF routing information for all interfaces.

If no next hop is specified, this command displays all OSPF routing information.

Examples

# Display OSPF routing information.

<Sysname> display ospf routing

 

          OSPF Process 1 with Router ID 192.168.1.2

                   Routing Tables

 

 Routing for Network

 Destination        Cost  Type       NextHop         AdvRouter     Area

 192.168.1.0/24     1562  Stub       192.168.1.2     192.168.1.2   0.0.0.0

 172.16.0.0/16      1563  Inter      192.168.1.1     192.168.1.1   0.0.0.0

 

 Total Nets: 2

 Intra Area: 1  Inter Area: 1  ASE: 0  NSSA: 0

Table 38 Command output

Field

Description

Destination

Destination network.

Cost

Cost to destination.

Type

Route type: intra-area, transit, stub, inter-area, Type-1 external, Type-2 external.

NextHop

Next hop address.

AdvRouter

Advertising router.

Area

Area ID.

Total Nets

Total networks.

Intra Area

Total intra-area routes.

Inter Area

Total inter-area routes.

ASE

Total ASE routes.

NSSA

Total NSSA routes.

 

# Display detailed OSPF routing information.

<Sysname> display ospf routing verbose

 

          OSPF Process 2 with Router ID 192.168.1.112

                   Routing Tables

 

 Routing for Network

 

 Destination: 192.168.1.0/24

        Cost: 1562                    Type: Stub

   AdvRouter: 192.168.1.2             Area: 0.0.0.0

  SubProtoID: 0x1               Preference: 10

     NextHop: 192.168.1.2        BkNextHop: N/A

      IfType: Broadcast           BkIfType: N/A

   Interface: Vlan10           BkInterface: N/A

       NibID: 0x0                   Status: Local

 

 Destination: 172.16.0.0/16

        Cost: 1563                    Type: Inter

   AdvRouter: 192.168.1.1             Area: 0.0.0.0

  SubProtoID: 0x1               Preference: 10

     NextHop: 192.168.1.1        BkNextHop: N/A

      IfType: Broadcast           BkIfType: N/A

   Interface: Vlan20           BkInterface: N/A

       NibID: 0x0                   Status: Local

 

 Total Nets: 2

 Intra Area: 2  Inter Area: 0  ASE: 0  NSSA: 0

Table 39 Command output

Field

Description

SubProtoID

Sub protocol ID.

Preference

OSPF route preference.

NbrId

Neighbor router ID.

NextHop

Primary next hop IP address.

BkNextHop

Backup next hop IP address.

IfType

Type of the network to which the primary next hop belongs.

BkIfType

Type of the network to which the backup next hop belongs.

Interface

Output interface.

BkInterface

Backup output interface.

NibID

Next hop ID.

Status

Route status:

·     Local—The route is on the local end and is not sent to the route management module.

·     Invalid—The next hop is invalid.

·     Stale—The next hop is stale.

·     Normal—The route is available.

·     Delete—The route is deleted.

·     Host-Adv—The route is a host route.

·     Rely—The route is a recursive route.

 

display ospf spf-tree

Use display ospf spf-tree to display OSPF topology information.

Syntax

display ospf [ process-id ] [ area area-id ] spf-tree [ verbose ]

Views

Any view

Predefined user roles

network-admin

network-operator

mdc-admin

mdc-operator

Parameters

process-id: Specifies an OSPF process by its ID in the range of 1 to 65535. If you do not specify this argument, the command displays topology information for all OSPF processes.

area area-id: Specifies an OSPF area by its ID, which is an IP address or a decimal integer in the range of 0 to 4294967295 that is translated into the IP address format. If you do not specify this option, the command displays topology information for all OSPF areas.

verbose: Displays detailed OSPF topology information. If you do not specify this keyword, the command displays brief OSPF topology information.

Examples

# Display brief topology information for area 0 in OSPF process 1.

<Sysname> display ospf 1 area 0 spf-tree

 

          OSPF Process 1 with Router ID 100.0.0.4

 

        Flags: S-Node is on SPF tree       R-Node is directly reachable

               I-Node or Link is init      D-Node or Link is to be deleted

               P-Neighbor is parent        A-Node is in candidate list

               C-Neighbor is child         G-Link is in change list

               H-Nexthop changed           N-Link is a new path

               V-Link is involved

 

                  Area: 0.0.0.0  Shortest Path Tree

 

 SpfNode         Type    Flag      SpfLink         Type   Cost  Flag

>192.168.119.130 Network S R

                                -->114.114.114.111 NET2RT 0     C

                                -->100.0.0.4       NET2RT 0     P

>114.114.114.111 Router  S

                                -->192.168.119.130 RT2NET 65535 P

>100.0.0.4       Router  S

                                -->192.168.119.130 RT2NET 10    C

Table 40 Command output

Field

Description

SpfNode

SPF node, represented by a router ID when the node type is Router, or the IP address of the DR when the node type is Network.

Node flag:

·     I—The node is in initialization state.

·     A—The node is on the candidate list.

·     S—The node is on the SPF tree.

·     R—The node is directly connected to the root node.

·     D—The node is to be deleted.

SpfLink

SPF link, representing the peer node.

Link type:

·     RT2RT—Router to router.

·     NET2RT—Network to router.

·     RT2NET—Router to network.

Link flag:

·     IThe link is in initialization state.

·     PThe peer is the parent node.

·     CThe peer is the child node.

·     DThe link is to be deleted.

·     HThe next hop is changed.

·     VWhen the peer node is deleted or added, the peer node is not on the SPF tree or is deleted.

·     NThe link is newly added, and both end nodes are on the SPF tree.

·     G—The link is on the area change list.

 

# Display detailed topology information for area 0 in OSPF process 1.

<Sysname> display ospf 1 area 0 spf-tree verbose

 

          OSPF Process 1 with Router ID 100.0.0.4

 

        Flags: S-Node is on SPF tree       R-Node is directly reachable

               I-Node or Link is init      D-Node or Link is to be deleted

               P-Neighbor is parent        A-Node is in candidate list

               C-Neighbor is child         G-Link is in change list

               H-Nexthop changed           N-Link is a new path

               V-Link is involved

 

                  Area: 0.0.0.0  Shortest Path Tree

 

>LsId(192.168.119.130)

 AdvId    : 100.0.0.4       NodeType     : Network

 Mask     : 255.255.255.0   SPFLinkCnt   : 2           Distance: 10

 VlinkData: 0.0.0.0         ParentLinkCnt: 1           NodeFlag: S R

 NextHop  : 1

   192.168.119.130    Interface: Vlan1

 BkNextHop: 1

   0.0.0.0            Interface: Vlan2

 -->LinkId(114.114.114.111)

    AdvId   : 100.0.0.4       LinkType   : NET2RT

    LsId    : 192.168.119.130 LinkCost   : 0           NextHopCnt: 1

    LinkData: 0.0.0.0         LinkNewCost: 0           LinkFlag  : C

 -->LinkId(100.0.0.4)

    AdvId   : 100.0.0.4       LinkType   : NET2RT

    LsId    : 192.168.119.130 LinkCost   : 0           NextHopCnt: 1

    LinkData: 0.0.0.0         LinkNewCost: 0           LinkFlag  : P

Table 41 Command output

Field

Description

LsId

Link state ID.

AdvId

ID of the advertising router.

NodeType

Node type:

·     NetworkNetwork node.

·     Router—Router node.

Mask

Network mask. Its value is 0 for a router node.

SPFLinkCnt

Number of SPF links.

Distance

Cost to the root node.

VlinkData

Destination address of virtual link packets.

ParentLinkCnt

Number of parent links.

NodeFlag

Node flag:

·     IThe node is in initialization state.

·     AThe node is on the candidate list.

·     SThe node is on the SPF tree.

·     RThe node is directly connected to the root node.

·     DThe node is to be deleted.

NextHop

Next hop.

Interface

Output interface.

BkNextHop

Backup next hop.

LinkId

Link ID

LinkType

Link type:

·     RT2RTRouter to router.

·     NET2RTNetwork to router.

·     RT2NET—Router to network.

LinkCost

Link cost.

NextHopCnt

Number of next hops.

LinkData

Link data.

LinkNewCost

New link cost.

LinkFlag

Link flag:

·     IThe link is in initialization state.

·     PThe peer is the parent node.

·     CThe peer is the child node.

·     DThe link is to be deleted.

·     HThe next hop is changed.

·     VWhen the peer node is deleted or added, the peer node is not on the SPF tree or is deleted.

·     NThe link is newly added, and both end nodes are on the SPF tree.

·     GThe link is on the area change list.

 

display ospf statistics

Use display ospf statistics to display OSPF statistics.

Syntax

display ospf [ process-id ] statistics [ error | packet [ interface-type interface-number ] ]

Views

Any view

Predefined user roles

network-admin

network-operator

mdc-admin

mdc-operator

Parameters

process-id: Specifies an OSPF process by its ID in the range of 1 to 65535. If you do not specify this argument, the command displays OSPF statistics for all OSPF processes.

error: Displays error statistics. If you do not specify this keyword, the command displays OSPF packet, LSA, and route statistics.

packet: Displays OSPF packet statistics.

interface-type interface-number: Specifies an interface by its type and number. If you do not specify this argument, the command displays statistics for all interfaces.

Examples

# Display OSPF statistics.

<Sysname> display ospf statistics

 

          OSPF Process 1 with Router ID 2.2.2.2

                  Statistics

 

 I/O statistics

  Type                      Input     Output

  Hello                     61        122

  DB Description            2          3

  Link-State Req            1          1

  Link-State Update         3          3

  Link-State Ack            3          2

 

 LSAs originated by this router

  Router  : 4

  Network : 0

  Sum-Net : 0

  Sum-Asbr: 0

  External: 0

  NSSA    : 0

  Opq-Link: 0

  Opq-Area: 0

  Opq-As  : 0

 

 LSAs originated: 4  LSAs received: 7

 

 Routing table:

   Intra area: 2  Inter area: 3  ASE/NSSA: 0

Table 42 Command output

Field

Description

I/O statistics

Statistics about input/output packets and LSAs.

Type

OSPF packet type.

Input

Packets received.

Output

Packets sent.

Hello

Hell packet.

DB Description

Database Description packet.

Link-State Req

Link-State Request packet.

Link-State Update

Link-State Update packet.

Link-State Ack

Link-State Acknowledge packet.

LSAs originated by this router

LSAs originated by this router.

Router

Number of Type-1 LSAs originated.

Network

Number of Type-2 LSAs originated.

Sum-Net

Number of Type-3 LSAs originated.

Sum-Asbr

Number of Type-4 LSAs originated.

External

Number of Type-5 LSAs originated.

NSSA

Number of Type-7 LSAs originated.

Opq-Link

Number of Type-9 LSAs originated.

Opq-Area

Number of Type-10 LSAs originated.

Opq-As

Number of Type-11 LSAs originated.

LSA originated

Number of LSAs originated.

LSA received

Number of LSAs received.

Routing table

Routing table information.

Intra area

Number of intra-area routes.

Inter area

Number of inter-area routes.

ASE

Number of ASE routes.

 

# Display OSPF error statistics.

<Sysname> display ospf statistics error

 

          OSPF Process 1 with Router ID 192.168.1.112

                  OSPF Packet Error Statistics

 

 0         : Router ID confusion        0         : Bad packet

 0         : Bad version                0         : Bad checksum

 0         : Bad area ID                0         : Drop on unnumbered link

 0         : Bad virtual link           0         : Bad authentication type

 0         : Bad authentication key     0         : Packet too small

 0         : Neighbor state low         0         : Transmit error

 0         : Interface down             0         : Unknown neighbor

 0         : HELLO: Netmask mismatch    0         : HELLO: Hello-time mismatch

 0         : HELLO: Dead-time mismatch  0         : HELLO: Ebit option mismatch

 0         : DD: MTU option mismatch    0         : DD: Unknown LSA type

 0         : DD: Ebit option mismatch   0         : ACK: Bad ack

 0         : ACK: Unknown LSA type      0         : REQ: Empty request

 0         : REQ: Bad request           0         : UPD: LSA checksum bad

 0         : UPD: Unknown LSA type      0         : UPD: Less recent LSA

Table 43 Command output

Field

Description

Router ID confusion

Packets with duplicate router ID.

Bad packet

Packets illegal.

Bad version

Packets with wrong version.

Bad checksum

Packets with wrong checksum.

Bad area ID

Packets with invalid area ID.

Drop on unnumbered link

Packets dropped on the unnumbered interface.

Bad virtual link

Packets on wrong virtual links.

Bad authentication type

Packets with invalid authentication type.

Bad authentication key

Packets with invalid authentication key.

Packet too small

Packets too small in length.

Neighbor state low

Packets received in low neighbor state.

Transmit error

Packets with error when being transmitted.

Interface down

Shutdown times of the interface.

Unknown neighbor

Packets received from unknown neighbors.

HELLO: Netmask mismatch

Hello packets with mismatched mask.

HELLO: Hello-time mismatch

Hello packets with mismatched hello timer.

HELLO: Dead-time mismatch

Hello packets with mismatched dead timer.

HELLO: Ebit option mismatch

Hello packets with mismatched E-bit in the option field.

DD: MTU option mismatch

DD packets with mismatched MTU.

DD: Unknown LSA type

DD packets with unknown LSA type.

DD: Ebit option mismatch

DD packets with mismatched E-bit in the option field.

ACK: Bad ack

Bad LSAck packets for LSU packets.

ACK: Unknown LSA type

LSAck packets with unknown LSA type.

REQ: Empty request

LSR packets with no request information.

REQ: Bad request

Bad LSR packets.

UPD: LSA checksum bad

LSU packets with wrong LSA checksum.

UPD: Unknown LSA type

LSU packets with unknown LSA type.

UPD: Less recent LSA

LSU packets without the most recent LSA.

 

# Display OSPF packet statistics for all processes and interfaces.

<Sysname> display ospf statistics packet

 

          OSPF Process 100 with Router ID 192.168.1.59

                  Packet Statistics

 

 Waiting to send packet count: 0

         Hello      DD         LSR        LSU        ACK        Total

 Input : 489        6          2          44         40         581

 Output: 492        8          2          45         40         587

 

 Area: 0.0.0.1

 Interface: 20.1.1.1 (GigabitEthernet1/0/1)

         DD         LSR        LSU        ACK        Total

 Input : 0          0          0          0          0

 Output: 0          0          0          0          0

 

 Interface: 100.1.1.1 (GigabitEthernet1/0/9)

         DD         LSR        LSU        ACK        Total

 Input : 3          1          22         16         42

 Output: 2          1          19         20         42

Table 44 Command output

Field

Description

Waiting to send packet count

Number of packets waiting to be sent.

Total

Total number of packets.

Input

Number of received packets.

Output

Number of sent packets.

Area

Area ID.

Interface

Interface address and interface name.

 

display ospf vlink

Use display ospf vlink to display OSPF virtual link information.

Syntax

In standalone mode:

display ospf [ process-id ] vlink [ standby slot slot-number ]

In IRF mode:

display ospf [ process-id ] vlink [ standby chassis chassis-number slot slot-number ]

Views

Any view

Predefined user roles

network-admin

network-operator

mdc-admin

mdc-operator

Parameters

process-id: Specifies an OSPF process by its ID in the range of 1 to 65535. If you do not specify this argument, the command displays the OSPF virtual link information for all OSPF processes.

standby slot slot-number: Displays backup OSPF virtual link information for a card. If you do not specify this option, the command displays OSPF virtual link information. (In standalone mode.)

standby chassis chassis-number slot slot-number: Displays backup OSPF virtual link information for a card on an IRF member device. The chassis-number argument specifies the ID of the IRF member device. The slot-number argument specifies the slot number of the card. If you do not specify this option, the command displays OSPF virtual link information. (In IRF mode.)

Examples

# Display OSPF virtual link information.

<Sysname> display ospf vlink

          OSPF Process 1 with Router ID 3.3.3.3

                  Virtual Links

 

 Virtual-link Neighbor-ID  -> 2.2.2.2, Neighbor-State: Full

 Interface: 10.1.2.1 (Vlan-interface1)

 Cost: 1562  State: P-2-P  Type: Virtual

 Transit Area: 0.0.0.1

 Timers: Hello 10 , Dead 40 , Retransmit 5 , Transmit Delay 1

 MD5 authentication enabled.

    The last key is 3.

    The rollover is in progress, 2 neighbor(s) left.

Table 45 Command output

Field

Description

Virtual-link Neighbor-ID

ID of the neighbor on the virtual link.

Neighbor-State

Neighbor state: Down, Init, 2-Way, ExStart, Exchange, Loading, Full.

Interface

IP address and name of the local interface on the virtual link.

Cost

Interface route cost.

State

Interface state.

Type

Virtual link.

Transit Area

Transit area ID.

Timers

Values of timers: hello, dead, retransmit, and interface transmission delay.

MD5 authentication enabled

Authentication mode.

The last key

Most recent MD5 authentication key ID.

neighbor(s)

Number of neighbors that have not completed key rollover.

 

display router id

Use display router id to display the global router ID.

Syntax

display router id

Views

Any view

Predefined user roles

network-admin

network-operator

mdc-admin

mdc-operator

Examples

# Display the global router ID.

<Sysname> display router id

         Configured router ID is 1.1.1.1

dscp

Use dscp to configure a DSCP value for outgoing OSPF packets.

Use undo dscp to restore the default.

Syntax

dscp dscp-value

undo dscp

Default

The DSCP value for outgoing OSPF packets is 48.

Views

OSPF view

Predefined user roles

network-admin

mdc-admin

Parameters

dscp-value: Specifies a DSCP value in the range of 0 to 63 for outgoing OSPF packets.

Examples

# Set the DSCP value for outgoing OSPF packets to 63 in OSPF process 1.

<Sysname> system-view

[Sysname] ospf 1

[Sysname-ospf-1] dscp 63

enable link-local-signaling

Use enable link-local-signaling to enable the OSPF link-local signaling (LLS) capability.

Use undo enable link-local-signaling to disable the OSPF LLS capability.

Syntax

enable link-local-signaling

undo enable link-local-signaling

Default

OSPF link-local signaling capability is disabled.

Views

OSPF view

Predefined user roles

network-admin

mdc-admin

Examples

# Enable link-local signaling for OSPF process 1.

<Sysname> system-view

[Sysname] ospf 1

[Sysname-ospf-1] enable link-local-signaling

enable out-of-band-resynchronization

Use enable out-of-band-resynchronization to enable the OSPF out-of-band resynchronization (OOB-Resynch) capability.

Use undo enable out-of-band-resynchronization to disable the OSPF out-of-band resynchronization capability.

Syntax

enable out-of-band-resynchronization

undo enable out-of-band-resynchronization

Default

The OSPF out-of-band resynchronization capability is disabled.

Views

OSPF view

Predefined user roles

network-admin

mdc-admin

Usage guidelines

Before you configure this command, enable the link-local signaling capability.

Examples

# Enable the out-of-band resynchronization capability for OSPF process 1.

<Sysname> system-view

[Sysname] ospf 1

[Sysname-ospf-1] enable link-local-signaling

[Sysname-ospf-1] enable out-of-band-resynchronization

Related commands

enable link-local-signaling

event-log

Use event-log to specify the number of OSPF logs.

Use undo event-log to restore the default.

Syntax

event-log { lsa-flush | peer | spf } size count

undo event-log { lsa-flush | peer | spf } size

Default

The number of LSA aging logs, neighbor logs, or route calculation logs is 10.

Views

OSPF view

Predefined user roles

network-admin

mdc-admin

Parameters

lsa-flush: Specifies the number of LSA aging logs.

peer: Specifies the number of neighbor logs.

spf: Specifies the number of route calculation logs.

count: Specifies the number of OSPF logs, in the range of 0 to 65535.

Examples

# Specify the number of route calculation logs as 50 in OSPF process 100.

<Sysname> system-view

[Sysname] ospf 100

[Sysname-ospf-100] event-log spf size 50

fast-reroute (OSPF view)

Use fast-reroute to configure OSPF FRR.

Use undo fast-reroute to restore the default.

Syntax

fast-reroute { lfa [ abr-only ] | route-policy route-policy-name }

undo fast-reroute

Default

OSPF FRR is disabled.

Views

OSPF view

Predefined user roles

network-admin

mdc-admin

Parameters

lfa: Uses the LFA algorithm to calculate a backup next hop for all routes.

abr-only: Uses the next hop of the route to the ABR as the backup next hop.

route-policy route-policy-name: Uses a routing policy to designate a backup next hop. The route-policy-name argument is a case-sensitive string of 1 to 63 characters.

Usage guidelines

Do not use OSPF FRR and BFD for OSPF at the same time. Otherwise, OSPF FRR might fail to work.

Do not use the fast-reroute lfa command together with the vlink-peer command.

When both OSPF FRR and PIC are configured, OSPF FRR takes effect.

Examples

# Enable FRR to calculate a backup next hop for all routes by using LFA algorithm in OSPF process 1.

<Sysname> system-view

[Sysname] ospf 1

[Sysname-ospf-1] fast-reroute lfa

filter (OSPF area view)

 

NOTE:

This command is available only on an ABR.

 

Use filter to configure OSPF to filter inbound/outbound Type-3 LSAs on an ABR.

Use undo filter to disable Type-3 LSA filtering.

Syntax

filter { acl-number | prefix-list prefix-list-name | route-policy route-policy-name } { export | import }

undo filter { export | import }

Default

Type-3 LSAs are not filtered.

Views

OSPF area view

Predefined user roles

network-admin

mdc-admin

Parameters

acl-number: Specifies an ACL by its number in the range of 2000 to 3999 to filter inbound/outbound Type-3 LSAs.

prefix-list-name: Specifies an IP prefix list by its name, a case-sensitive string of 1 to 63 characters, to filter inbound/outbound Type-3 LSAs.

route-policy-name: Specifies a routing policy by its name, a case-sensitive string of 1 to 63 characters, to filter inbound/outbound Type-3 LSAs.

export: Filters Type-3 LSAs advertised to other areas.

import: Filters Type-3 LSAs advertised into the local area.

Examples

# Use IP prefix list my-prefix-list to filter inbound Type-3 LSAs, and use ACL 2000 to filter outbound Type-3 LSAs in OSPF Area 1.

<Sysname> system-view

[Sysname] ospf 100

[Sysname-ospf-100] area 1

[Sysname-ospf-100-area-0.0.0.1] filter prefix-list my-prefix-list import

[Sysname-ospf-100-area-0.0.0.1] filter 2000 export

filter-policy export (OSPF view)

Use filter-policy export to configure OSPF to filter redistributed routes.

Use undo filter-policy export to remove the configuration.

Syntax

filter-policy { acl-number | prefix-list prefix-list-name } export [ protocol [ process-id ] ]

undo filter-policy export [ protocol [ process-id ] ]

Default

Redistributed routes are not filtered.

Views

OSPF view

Predefined user roles

network-admin

mdc-admin

Parameters

acl-number: Specifies an ACL by its number in the range of 2000 to 3999 to filter redistributed routes by destination address.

prefix-list-name: Specifies an IP prefix list by its name, a case-sensitive string of 1 to 63 characters, to filter redistributed routes by destination address.

protocol: Filters routes redistributed from the specified routing protocol, which can be bgp, direct, isis, ospf, rip, or static. If no protocol is specified, this command filters all redistributed routes.

process-id: Specifies a process by its ID in the range of 1 to 65535. This argument is available only when the protocol is rip, ospf or isis.

Usage guidelines

To reference an advanced ACL (with a number from 3000 to 3999) in the command, configure the ACL using one of the following methods:

·     To deny/permit a route with the specified destination, use the rule [ rule-id ] { deny | permit } ip source sour-addr sour-wildcard command.

·     To deny/permit a route with the specified destination and mask, use the rule [ rule-id ] { deny | permit } ip source sour-addr sour-wildcard destination dest-addr dest-wildcard command.

The source keyword specifies the destination address of a route and the destination keyword specifies the subnet mask of the route. The specified subnet mask must be contiguous. Otherwise, the mask configuration does not take effect.

Examples

# Use ACL 2000 to filter redistributed routes.

<Sysname> system-view

[Sysname] acl number 2000

[Sysname-acl-basic-2000] rule deny source 192.168.10.0 0.0.0.255

[Sysname-acl-basic-2000] quit

[Sysname] ospf 100

[Sysname-ospf-100] filter-policy 2000 export

# Configure ACL 3000 to permit only route 113.0.0.0/16. Use ACL 3000 to filter redistributed routes.

<Sysname> system-view

[Sysname] acl number 3000

[Sysname-acl-adv-3000] rule 10 permit ip source 113.0.0.0 0 destination 255.255.0.0 0

[Sysname-acl-adv-3000] rule 100 deny ip

[Sysname-acl-adv-3000] quit

[Sysname] ospf 100

[Sysname-ospf-100] filter-policy 3000 export

Related commands

import-route

filter-policy import (OSPF view)

Use filter-policy import to configure OSPF to filter routes calculated using received LSAs.

Use undo filter-policy import to restore the default.

Syntax

filter-policy { acl-number [ gateway prefix-list-name ] | gateway prefix-list-name | prefix-list prefix-list-name [ gateway prefix-list-name ] | route-policy route-policy-name } import

undo filter-policy import

Default

Routes calculated using received LSAs are not filtered.

Views

OSPF view

Predefined user roles

network-admin

mdc-admin

Parameters

acl-number: Specifies an ACL by its number in the range of 2000 to 3999 to filter received routes by destination.

gateway prefix-list-name: Specifies an IP prefix list by its name, a case-sensitive string of 1 to 63 characters, to filter received routes by next hop.

prefix-list prefix-list-name: Specifies an IP prefix list by its name, a case-sensitive string of 1 to 63 characters, to filter received routes by destination.

route-policy route-policy-name: Specifies a routing policy by its name, a case-sensitive string of 1 to 63 characters, to filter received routes.

Usage guidelines

To reference an advanced ACL (with a number from 3000 to 3999) in the command or in the specified routing policy, configure the ACL in one of the following ways:

·     To deny/permit a route with the specified destination, use the rule [ rule-id ] { deny | permit } ip source sour-addr sour-wildcard command.

·     To deny/permit a route with the specified destination and mask, use the rule [ rule-id ] { deny | permit } ip source sour-addr sour-wildcard destination dest-addr dest-wildcard command.

The source keyword specifies the destination address of a route and the destination keyword specifies the subnet mask of the destination address. The specified subnet mask must be contiguous. Otherwise, the mask configuration does not take effect.

Examples

# Use ACL 2000 to filter received routes.

<Sysname> system-view

[Sysname] acl number 2000

[Sysname-acl-basic-2000] rule deny source 192.168.10.0 0.0.0.255

[Sysname-acl-basic-2000] quit

[Sysname] ospf 100

[Sysname-ospf-100] filter-policy 2000 import

# Configure ACL 3000 to permit only route 113.0.0.0/16. Use ACL 3000 to filter received routes.

<Sysname> system-view

[Sysname] acl number 3000

[Sysname-acl-adv-3000] rule 10 permit ip source 113.0.0.0 0 destination 255.255.0.0 0

[Sysname-acl-adv-3000] rule 100 deny ip

[Sysname-acl-adv-3000] quit

[Sysname] ospf 100

[Sysname-ospf-100] filter-policy 3000 import

graceful-restart (OSPF view)

Use graceful-restart to enable OSPF GR.

Use undo graceful-restart to disable OSPF GR.

Syntax

graceful-restart [ ietf | nonstandard ] [ global | planned-only ] *

undo graceful-restart

Default

OSPF GR is disabled.

Views

OSPF view

Predefined user roles

network-admin

mdc-admin

Parameters

ietf: Enables IETF GR.

nonstandard: Enables non-IETF GR.

global: Enables global GR. In global GR mode, a GR process can be completed only when all GR helpers exist. A GR process fails if a GR helper fails (for example, the interface connected to the GR helper goes down). If you do not specify this keyword, this command enables partial GR. In partial GR mode, a GR process can be completed if a GR helper exists.

planned-only: Enables planned only GR. If you do not specify this keyword, this command enables both planned GR and unplanned GR.

Usage guidelines

GR includes planned GR and unplanned GR:

·     Planned GRManually restart OSPF or perform an active/standby switchover. Before OSPF restart or active/standby switchover, the GR restarter sends Grace-LSAs to GR helpers.

·     Non-planned GR—OSPF restarts or an active/standby switchover occurs because of device failure. Before OSPF restart or active/standby switchover, the GR restarter does not send Grace-LSAs to GR helpers.

Before enabling IETF GR for OSPF, enable Opaque LSA advertisement and reception with the opaque-capability enable command.

Before enabling non-IETF GR for OSPF, enable OSPF LLS with the enable link-local-signaling command and OOB-Resynch with the enable out-of-band-resynchronization command.

If you do not provide the nonstandard or ietf keyword, the command enables non-IETF GR for OSPF.

Examples

# Enable IETF GR for OSPF process 1.

<Sysname> system-view

[Sysname] ospf 1

[Sysname-ospf-1] opaque-capability enable

[Sysname-ospf-1] graceful-restart ietf

# Enable non-IETF GR for OSPF process 1.

<Sysname> system-view

[Sysname] ospf 1

[Sysname-ospf-1] enable link-local-signaling

[Sysname-ospf-1] enable out-of-band-resynchronization

[Sysname-ospf-1] graceful-restart nonstandard

Related commands

·     enable link-local-signaling

·     enable out-of-band-resynchronization

·     opaque-capability enable

graceful-restart helper enable

Use graceful-restart helper enable to enable OSPF GR helper capability.

Use undo graceful-restart helper enable to disable OSPF GR helper capability.

Syntax

graceful-restart helper enable [ planned-only ]

undo graceful-restart helper enable

Default

OSPF GR helper capability is enabled.

Views

OSPF view

Predefined user roles

network-admin

mdc-admin

Parameters

planned-only: Enable only planned GR for the GR helper. If you do not specify this keyword, this command enables both planned GR and unplanned GR for the GR helper.

Usage guidelines

The planned-only keyword is available only for the IETF GR helper.

Examples

# Enable GR helper capability for OSPF process 1.

<Sysname> system-view

[Sysname] ospf 1

[Sysname-ospf-1] graceful-restart helper enable

graceful-restart helper strict-lsa-checking

Use graceful-restart helper strict-lsa-checking to enable strict LSA checking capability for GR helper.

Use undo graceful-restart helper strict-lsa-checking to disable strict LSA checking capability for GR helper.

Syntax

graceful-restart helper strict-lsa-checking

undo graceful-restart helper strict-lsa-checking

Default

Strict LSA checking capability for GR helper is disabled.

Views

OSPF view

Predefined user roles

network-admin

mdc-admin

Usage guidelines

When an LSA change on the GR helper is detected, the GR helper device exits the GR helper mode.

Examples

# Enable strict LSA checking capability for GR helper in OSPF process 1.

<Sysname> system-view

[Sysname] ospf 1

[Sysname-ospf-1] graceful-restart helper strict-lsa-checking

graceful-restart interval (OSPF view)

Use graceful-restart interval to configure the GR interval.

Use undo graceful-restart interval to restore the default GR interval.

Syntax

graceful-restart interval interval-value

undo graceful-restart interval

Default

The GR interval is 120 seconds.

Views

OSPF view

Predefined user roles

network-admin

mdc-admin

Parameters

interval-value: Specifies the GR interval in the range of 40 to 1800 seconds.

Usage guidelines

The value of the GR restart interval cannot be smaller than the maximum OSPF neighbor dead time of all the OSPF interfaces. Otherwise, GR restart might fail.

Examples

# Configure the GR interval for OSPF process 1 as 100 seconds.

<Sysname> system-view

[Sysname] ospf 1

[Sysname-ospf-1] graceful-restart interval 100

Related commands

ospf timer dead

host-advertise

Use host-advertise to advertise a host route.

Use undo host-advertise to remove a host route.

Syntax

host-advertise ip-address cost

undo host-advertise ip-address

Default

No host route is advertised.

Views

OSPF area view

Predefined user roles

network-admin

mdc-admin

Parameters

ip-address: Specifies the IP address of a host.

cost: Specifies a cost for the route, in the range of 1 to 65535.

Examples

# Advertise host route 1.1.1.1 with a cost of 100.

<Sysname> system-view

[Sysname] ospf 100

[Sysname-ospf-100] area 0

[Sysname-ospf-100-area-0.0.0.0] host-advertise 1.1.1.1 100

import-route (OSPF view)

Use import-route to redistribute AS-external routes from another routing protocol.

Use undo import-route to disable route redistribution from another routing protocol.

Syntax

import-route protocol [ process-id | all-processes | allow-ibgp ] [ cost cost | [ cost cost | nssa-only | route-policy route-policy-name | tag tag | type type ] *

undo import-route protocol [ process-id | all-processes ]

Default

OSPF does not redistribute AS-external routes from any other routing protocol.

Views

OSPF view

Predefined user roles

network-admin

mdc-admin

Parameters

protocol: Redistributes routes from the specified protocol, which can be bgp, direct, isis, ospf, rip, or static.

process-id: Specifies a process by its ID in the range of 1 to 65535. The default is 1. It is available only when the protocol is rip, ospf, or isis.

all-processes: Redistributes routes from all the processes of the specified routing protocol. This keyword takes effect only when the protocol is rip, ospf, or isis.

allow-ibgp: Allows redistribution of IBGP routes. It is available only when the protocol is bgp.

cost cost: Specifies a route cost in the range of 0 to 16777214. The default is 1.

nssa-only: Limits the route advertisement to the NSSA area by setting the P-bit of Type-7 LSAs to 0. By default, the P-bit of Type-7 LSAs is set to 1. If the router acts as both an ASBR and an ABR and FULL state neighbors exist in the backbone area, the P-bit of Type-7 LSAs originated by the router is set to 0. This keyword applies to NSSA routers.

route-policy route-policy-name: Uses the specified routing policy to filter redistributed routes. The route-policy-name argument is a case-sensitive string of 1 to 63 characters.

tag tag: Specifies a tag for marking external LSAs, in the range of 0 to 4294967295. The default is 1.

type type: Specifies a cost type, 1 or 2. The default is 2.

Usage guidelines

This command redistributes routes destined for other ASs from another protocol. AS external routes include the following types:

·     Type-1 external route

·     Type-2 external route

A Type-1 external route has high reliability. Its cost is comparable with the cost of OSPF internal routes. The cost from an OSPF router to a Type-1 external route's destination equals the cost from the router to the ASBR plus the cost from the ASBR to the external route's destination.

A Type-2 external route has low credibility. OSPF considers the cost from the ASBR to the destination of a Type-2 external route is much bigger than the cost from the ASBR to an OSPF internal router. The cost from an internal router to a Type-2 external route's destination equals the cost from the ASBR to the Type-2 external route's destination.

The import-route command cannot redistribute default external routes.

The import-route bgp command redistributes only EBGP routes. Because the import-route bgp allow-ibgp command redistributes both EBGP and IBGP routes and might cause routing loops, use it with caution.

Only active routes can be redistributed. To view information about active routes, use the display ip routing-table protocol command.

The undo import-route protocol all-processes command removes only the configuration made by the import-route protocol all-processes command, instead of the configuration made by the import-route protocol process-id command.

The import-route nssa-only command redistributes AS-external routes in Type-7 LSAs only into the NSSA area.

Examples

# Redistribute routes from RIP process 40 and specify the type, tag, and cost as 2, 33, and 50 for redistributed routes.

<Sysname> system-view

[Sysname] ospf 100

[Sysname-ospf-100] import-route rip 40 type 2 tag 33 cost 50

Related commands

default-route-advertise (OSPF view)

ispf enable

Use ispf enable to enable OSPF incremental SPF (ISPF).

Use undo ispf enable to disable OSPF ISPF.

Syntax

ispf enable

undo ispf enable

Default

OSPF ISPF is enabled.

Views

OSPF view

Predefined user roles

network-admin

mdc-admin

Usage guidelines

Upon topology changes, ISPF recomputes only the affected part of the SPT, instead of the entire SPT.

Examples

# Enable ISPF for OSPF process 100.

<Sysname> system-view

[Sysname] ospf 100

[Sysname-ospf-100] ispf enable

log-peer-change

Use log-peer-change to enable the logging of OSPF neighbor state changes.

Use undo log-peer-change to disable the logging of OSPF neighbor state changes.

Syntax

log-peer-change

undo log-peer-change

Default

The logging of OSPF neighbor state changes is enabled.

Views

OSPF view

Predefined user roles

network-admin

mdc-admin

Usage guidelines

This command enables output of OSPF neighbor state changes to the information center. The information center processes the logs according to user-defined output rules (whether to output logs and where to output). For more information about the information center, see Network Management and Monitoring Configuration Guide.

Examples

# Disable the logging of neighbor state changes for OSPF process 100.

<Sysname> system-view

[Sysname] ospf 100

[Sysname-ospf-100] undo log-peer-change

lsa-arrival-interval

Use lsa-arrival-interval to specify the LSA arrival interval.

Use undo lsa-arrival-interval to restore the default.

Syntax

lsa-arrival-interval interval

undo lsa-arrival-interval

Default

The LSA arrival interval is 1000 milliseconds.

Views

OSPF view

Predefined user roles

network-admin

mdc-admin

Parameters

interval: Specifies the LSA arrival interval in the range of 0 to 60000 milliseconds.

Usage guidelines

If an LSA that has the same LSA type, LS ID, originating router ID as the previous LSA is received within the interval, OSPF discards the LSA. This feature helps protect resources from being over consumed due to frequent network changes.

As a best practice, set the interval with the lsa-arrival-interval command to be smaller than or equal to the initial interval set with the lsa-generation-interval command.

Examples

# Set the LSA arrival interval to 200 milliseconds.

<Sysname> system-view

[Sysname] ospf 100

[Sysname-ospf-100] lsa-arrival-interval 200

Related commands

lsa-generation-interval

lsdb-overflow-interval

Use lsdb-overflow-interval to configure the interval that OSPF exits overflow state.

Use undo lsdb-overflow-interval to restore the default.

Syntax

lsdb-overflow-interval interval

undo lsdb-overflow-interval

Default

The OSPF exit overflow interval is 300 seconds.

Views

OSPF view

Predefined user roles

network-admin

mdc-admin

Parameters

interval: Specifies the interval that OSPF exits overflow state, in the range of 0 to 2147483647 seconds.

Usage guidelines

When the number of LSAs in the LSDB exceeds the upper limit, the LSDB is in an overflow state. In this state, OSPF does not receive any external LSAs and deletes the external LSAs generated by itself to save system resources.

You can configure the interval that OSPF exits overflow state. An interval of 0 indicates that the timer is not started and OSPF does not exit overflow state.

Examples

# Configure the OSPF exit overflow interval as 10 seconds.

<Sysname> system-view

[Sysname] ospf 100

[Sysname-ospf-100] lsdb-overflow-interval 10

lsa-generation-interval

Use lsa-generation-interval to configure the OSPF LSA generation interval.

Use undo lsa-generation-interval to restore the default.

Syntax

lsa-generation-interval maximum-interval [ minimum-interval [ incremental-interval ] ]

undo lsa-generation-interval

Default

The maximum interval is 5 seconds, the minimum interval is 50 milliseconds, and the incremental interval is 200 milliseconds.

Views

OSPF view

Predefined user roles

network-admin

mdc-admin

Parameters

maximum-interval: Specifies the maximum LSA generation interval in the range of 1 to 60 seconds.

minimum-interval: Specifies the minimum LSA generation interval in the range of 10 to 60000 milliseconds.

incremental-interval: Specifies the LSA generation incremental interval in the range of 10 to 60000 milliseconds.

Usage guidelines

When network changes are not frequent, LSAs are generated at the minimum-interval. If network changes become frequent, the LSA generation interval is incremented by incremental-interval × 2n-2 (n is the number of generation times) each time a LSA generation occurs until the maximum-interval is reached.

The minimum interval and the incremental interval cannot be greater than the maximum interval.

Examples

# Configure the maximum LSA generation interval as 2 seconds, minimum interval as 100 milliseconds and incremental interval as 100 milliseconds.

<Sysname> system-view

[Sysname] ospf 100

[Sysname-ospf-100] lsa-generation-interval 2 100 100

Related commands

lsa-arrival-interval

lsdb-overflow-limit

Use lsdb-overflow-limit to specify the upper limit of external LSAs in the LSDB.

Use undo lsdb-overflow-limit to restore the default.

Syntax

lsdb-overflow-limit number

undo lsdb-overflow-limit

Default

The number of external LSAs is not limited.

Views

OSPF view

Predefined user roles

network-admin

mdc-admin

Parameters

number: Specifies the upper limit of external LSAs in the LSDB, in the range of 1 to 1000000.

Examples

# Specify the upper limit of external LSAs as 400000.

<Sysname> system-view

[Sysname] ospf 100

[Sysname-ospf-100] lsdb-overflow-limit 400000

maximum load-balancing (OSPF view)

Use maximum load-balancing to specify the maximum number of equal-cost multi-path (ECMP) routes for load balancing.

Use undo maximum load-balancing to restore the default.

Syntax

maximum load-balancing maximum

undo maximum load-balancing

Default

The maximum number of ECMP routes is 128.

Views

OSPF view

Predefined user roles

network-admin

mdc-admin

Parameters

maximum: Specifies the maximum number of ECMP routes, in the range of 1 to 128. No ECMP load balancing is available when the number is set to 1.

Examples

# Specify the maximum number of ECMP routes as 2.

<Sysname> system-view

[Sysname] ospf 100

[Sysname-ospf-100] maximum load-balancing 2

network (OSPF area view)

Use network to enable OSPF on the interface attached to the specified network in the area.

Use undo network to disable OSPF for the interface attached to the specified network in the area.

Syntax

network ip-address wildcard-mask

undo network ip-address wildcard-mask

Default

OSPF is not enabled for any interface.

Views

OSPF area view

Predefined user roles

network-admin

mdc-admin

Parameters

ip-address: Specifies the IP address of a network.

wildcard-mask: Specifies the wildcard mask of the IP address. For example, the wildcard mask of mask 255.0.0.0 is 0.255.255.255.

Usage guidelines

This command enables OSPF on the interface attached to the specified network. The interface's primary IP address must be in the specified network. If only the interface's secondary IP address is in the network, the interface cannot run OSPF.

Examples

# Specify the interface whose primary IP address is on network 131.108.20.0/24 to run OSPF in Area 2.

<Sysname> system-view

[Sysname] ospf 100

[Sysname-ospf-100] area 2

[Sysname-ospf-100-area-0.0.0.2] network 131.108.20.0 0.0.0.255

Related commands

ospf

nssa

Use nssa to configure the current area as an NSSA area.

Use undo nssa to restore the default.

Syntax

nssa [ default-route-advertise [ cost cost | nssa-only | route-policy route-policy-name | type type ] * | no-import-route | no-summary | suppress-fa | [ translate-always | translate-never ] | translator-stability-interval value ] *

undo nssa

Default

No area is configured as an NSSA area.

Views

OSPF area view

Predefined user roles

network-admin

mdc-admin

Parameters

default-route-advertise: Used on an NSSA ABR or an ASBR only. If it is configured on an NSSA ABR, the ABR generates a default route in a Type-7 LSA into the NSSA area regardless of whether a default route is available in the routing table. If it is configured on an ASBR, the ASBR generates a default route in a Type-7 LSA only when the default route is available in the routing table.

cost cost: Specifies a cost for the default route, in the range of 0 to 16777214. If no cost is specified, the default cost specified by the default cost command applies.

nssa-only: Limits the default route advertisement to the NSSA area by setting the P-bit of Type-7 LSAs to 0. By default, the P-bit of Type-7 LSAs is set to 1. If the router acts as both an ASBR and an ABR and FULL state neighbors exist in the backbone area, the P-bit of Type-7 LSAs originated by the router is set to 0.

route-policy route-policy-name: Specifies a routing policy by its name, a case-sensitive string of 1 to 63 characters. When a default route exists in the routing table and the specified routing policy is matched, the command distributes a default route in a Type-7 LSA into the OSPF routing domain, and the routing policy modifies some values in the Type-7 LSA.

type type: Specifies a type for the Type-7 LSA: 1 or 2. If no type is specified, the default type specified by the default type command applies.

no-import-route: Used on an NSSA ABR to control the import-route command to not redistribute routes into the NSSA area.

no-summary: Used only on an ABR to advertise a default route in a Type-3 summary LSA into the NSSA area and to not advertise other summary LSAs into the area. Such an area is a totally NSSA area.

suppress-fa: Suppresses the forwarding address in the Type-7 LSAs from being placed in the Type-5 LSAs.

translate-always: Always translates Type-7 LSAs to Type-5 LSAs. This keyword takes effect only on an NSSA ABR.

translate-never: Never translates Type-7 LSAs to Type-5 LSAs. This keyword takes effect only on an NSSA ABR.

translator-stability-interval value: Specifies the stability interval of the translator, during which the translator can maintain its translating capability after a device with a higher priority becomes the new translator. The value argument is the stability interval in the range of 0 to 900 seconds and defaults to 0 (which means the translator does not maintain its translating capability when a new translator arises).

Usage guidelines

All routers attached to an NSSA area must be configured with the nssa command in area view.

Examples

# Configure Area 1 as an NSSA area.

<Sysname> system-view

[Sysname] ospf 100

[Sysname-ospf-100] area 1

[Sysname-ospf-100-area-0.0.0.1] nssa

Related commands

default-cost (OSPF view)

opaque-capability enable

Use opaque-capability enable to enable opaque LSA advertisement and reception.

Use undo opaque-capability to disable opaque LSA advertisement and reception.

Syntax

opaque-capability enable

undo opaque-capability

Default

The feature is enabled.

Views

OSPF view

Predefined user roles

network-admin

mdc-admin

Usage guidelines

After the opaque LSA advertisement and reception is enabled, OSPF can receive and advertise Type-9, Type-10, and Type-11 opaque LSAs.

Examples

# Disable opaque LSA advertisement and reception.

<Sysname> system-view

[Sysname] ospf 100

[Sysname-ospf-100] undo opaque-capability

ospf

Use ospf to enable OSPF and enter OSPF view.

Use undo ospf to disable OSPF.

Syntax

ospf [ process-id | router-id router-id | vpn-instance vpn-instance-name ] *

undo ospf [ process-id ]

Default

OSPF is disabled.

Views

System view

Predefined user roles

network-admin

mdc-admin

Parameters

process-id: Specifies an OSPF process by its ID in the range of 1 to 65535.

router-id router-id: Specifies an OSPF router ID in dotted decimal notation.

vpn-instance vpn-instance-name: Specifies an MPLS L3VPN instance by its name, a case-sensitive string of 1 to 31 characters. If no VPN is specified, the OSPF process runs on the public network.

Usage guidelines

You can enable multiple OSPF processes on a router and specify different router IDs for them.

Enable an OSPF process before performing other tasks.

Examples

# Enable OSPF process 100 and specify router ID 10.10.10.1.

<Sysname> system-view

[Sysname] ospf 100 router-id 10.10.10.1

[Sysname-ospf-100]

ospf area

Use ospf area to enable OSPF on an interface.

Use undo ospf area to remove the configuration.

Syntax

ospf process-id area area-id [ exclude-subip ]

undo ospf process-id area [ exclude-subip ]

Default

OSPF is not enabled on an interface.

Views

Interface view

Predefined user roles

network-admin

mdc-admin

Parameters

process-id: Specifies an OSPF process by its ID in the range of 1 to 65535.

area-id: Specifies an area by its ID, an IP address or a decimal integer in the range of 0 to 4294967295 that is translated into the IP address format by the system.

exclude-subip: Excludes secondary IP addresses. If you do not specify this keyword, the command enables OSPF also on secondary IP addresses.

Usage guidelines

The ospf area command has a higher priority than the network command.

If the specified process and area do not exist, the command creates the process and area. Disabling an OSPF process on an interface does not delete the OSPF process or the area.

Examples

# Enable OSPF process 1 on VLAN-interface 10 that is in Area 2 and exclude secondary IP addresses.

<Sysname> system-view

[Sysname] interface vlan-interface 10

[Sysname-Vlan-interface10] ospf 1 area 2 exclude-subip

ospf authentication-mode

Use ospf authentication-mode to set the authentication mode and key on an interface.

Use undo ospf authentication-mode to remove specified configuration.

Syntax

For MD5/HMAC-MD5 authentication:

ospf authentication-mode { hmac-md5 | md5 } key-id { cipher cipher-string | plain plain-string }

undo ospf authentication-mode { hmac-md5 | md5 } key-id

For simple authentication:

ospf authentication-mode simple { cipher cipher-string | plain plain-string }

undo ospf authentication-mode simple

Default

No authentication is performed.

Views

Interface view

Predefined user roles

network-admin

mdc-admin

Parameters

hmac-md5: Specifies HMAC-MD5 authentication.

md5: Specifies MD5 authentication.

simple: Specifies simple authentication.

key-id: Specifies a key by its ID in the range of 1 to 255.

cipher: Sets a ciphertext key.

cipher-string: Specifies a ciphertext key. This argument is case sensitive. If simple is specified, the key must be a string of 33 to 41 characters. If md5 or hmac-md5 is specified, the key must be a string of 33 to 53 characters.

plain: Sets a plaintext key.

plain-string: Specifies a plaintext key. This argument is case sensitive. If simple is specified, the key must be a string of 1 to 8 characters. If md5 or hmac-md5 is specified, the key must be a string of 1 to 16 characters.

Usage guidelines

For security purposes, all keys, including keys configured in plain text, are saved in cipher text.

The interfaces attached to the same network segment must have the same key. You can specify either MD5/HMAC-MD5 authentication or simple authentication for an OSPF interface. For MD5/HMAC-MD5 authentication, you can configure multiple keys by executing this command multiple times, and each command must have a unique key ID and key string.

To modify the key of an OSPF interface, perform the following key rollover configurations:

1.     Configure a new MD5/HMAC-MD5 authentication key for the interface. If the new key is not configured on neighbor devices, MD5/HMAC-MD5 authentication key rollover is triggered. During key rollover, OSPF sends multiple packets that contain both the new and old MD5/HMAC-MD5 authentication keys to make sure all neighbor devices can pass the authentication.

2.     Configure the new MD5/HMAC-MD5 authentication key on all neighbor devices. When the local device receives packets with the new key from all neighbor devices, it exits MD5 key rollover.

3.     Delete the old MD5/HMAC-MD5 authentication key from the local device and all its neighbors. This operation helps prevent attacks from devices that use the old key for communication and reduce system resources and bandwidth consumption caused by key rollover.

Examples

# Enable MD5 authentication for the network 131.119.0.0/16 in Area 1. Set the interface key ID to 15, and plaintext key to 123456.

<Sysname> system-view

[Sysname] ospf 100

[Sysname-ospf-100] area 1

[Sysname-ospf-100-area-0.0.0.1] network 131.119.0.0 0.0.255.255

[Sysname-ospf-100-area-0.0.0.1] authentication-mode md5

[Sysname-ospf-100-area-0.0.0.1] quit

[Sysname-ospf-100] quit

[Sysname] interface vlan-interface 10

[Sysname-Vlan-interface10] ospf authentication-mode md5 15 plain 123456

# Enable simple authentication for the network 131.119.0.0/16 in Area 1. Set the plaintext key to 123456 on VLAN-interface 10.

<Sysname> system-view

[Sysname] ospf 100

[Sysname-ospf-100] area 1

[Sysname-ospf-100-area-0.0.0.1] network 131.119.0.0 0.0.255.255

[Sysname-ospf-100-area-0.0.0.1] authentication-mode simple

[Sysname-ospf-100-area-0.0.0.1] quit

[Sysname-ospf-100] quit

[Sysname] interface vlan-interface 10

[Sysname-Vlan-interface10] ospf authentication-mode simple plain 123456

Related commands

authentication-mode

ospf bfd enable

Use ospf bfd enable to enable BFD on an OSPF interface.

Use undo ospf bfd enable to disable BFD on an OSPF interface.

Syntax

ospf bfd enable [ echo ]

undo ospf bfd enable

Default

BFD for OSPF is disabled.

Views

Interface view

Predefined user roles

network-admin

mdc-admin

Parameters

echo: Enables BFD single-hop echo detection. If you do not specify this keyword, this command enables BFD bidirectional control detection.

Usage guidelines

Do not use OSPF FRR and BFD for OSPF at the same time. Otherwise, OSPF FRR might fail to take effect.

Examples

# Enable BFD for OSPF on VLAN-interface 11.

<Sysname> system-view

[Sysname] ospf

[Sysname-ospf-1] area 0

[Sysname-ospf-1-area-0.0.0.0] network 192.168.0.0 0.0.255.255

[Sysname] interface vlan-interface 11

[Sysname-Vlan-interface11] ospf bfd enable

ospf cost

Use ospf cost to set an OSPF cost for an interface.

Use undo ospf cost to restore the default.

Syntax

ospf cost value

undo ospf cost

Default

An interface computes its OSPF cost according to the interface bandwidth.

Views

Interface view

Predefined user roles

network-admin

mdc-admin

Parameters

value: Specifies an OSPF cost in the range of 0 to 65535 for a loopback interface and in the range of 1 to 65535 for other interfaces.

Usage guidelines

The ospf cost command sets an OSPF cost for an interface. If you do not use this command, the interface automatically computes its OSPF cost.

Examples

# Set the OSPF cost on VLAN-interface 10 to 65.

<Sysname> system-view

[Sysname] interface vlan-interface 10

[Sysname-Vlan-interface10] ospf cost 65

Related commands

bandwidth-reference

ospf dr-priority

Use ospf dr-priority to set the router priority for DR/BDR election on an interface.

Use undo ospf dr-priority to restore the default value.

Syntax

ospf dr-priority priority

undo ospf dr-priority

Default

The router priority is 1.

Views

Interface view

Predefined user roles

network-admin

mdc-admin

Parameters

priority: Specifies the router priority for the interface, in the range of 0 to 255.

Usage guidelines

The greater the value, the higher the priority for DR/BDR election. If a device has a priority of 0, it will not be elected as a DR or BDR.

Examples

# Set the router priority on VLAN-interface 10 to 8.

<Sysname> system-view

[Sysname] interface vlan-interface 10

[Sysname-Vlan-interface10] ospf dr-priority 8

ospf fast-reroute lfa-backup

Use ospf fast-reroute lfa-backup to enable LFA on the interface.

Use undo ospf fast-reroute lfa-backup to disable LFA on the interface.

Syntax

ospf fast-reroute lfa-backup

undo ospf fast-reroute lfa-backup

Default

LFA is enabled on the interface.

Predefined user roles

network-admin

mdc-admin

Usage guidelines

If you enable LFA on an interface, it can be selected as a backup interface. After you disable LFA on the interface, it cannot be selected as a backup.

Examples

# Disable VLAN-interface 11 from calculating a backup next hop by using the LFA algorithm.

<Sysname> system-view

[Sysname] interface vlan-interface 11

[Sysname-Vlan-interface11] undo ospf fast-reroute lfa-backup

ospf mib-binding

Use ospf mib-binding to bind an OSPF process to MIB.

Use undo ospf mib-binding to restore the default.

Syntax

ospf mib-binding process-id

undo ospf mib-binding

Default

MIB is bound to the OSPF process with the smallest process ID.

Views

System view

Predefined user roles

network-admin

mdc-admin

Parameters

process-id: Specifies an OSPF process by its ID in the range of 1 to 65535.

Usage guidelines

If the specified process ID does not exist, a notification is displayed to report that the MIB binding configuration has failed.

Deleting an OSPF process that has been bound to MIB also unbinds the OSPF process from MIB, and re-binds MIB to the OSPF process with the smallest process ID.

Examples

# Bind MIB operation to OSPF process 100.

<Sysname> system-view

[Sysname] ospf mib-binding 100

ospf mtu-enable

Use ospf mtu-enable to enable an interface to add the interface MTU into DD packets.

Use undo ospf mtu-enable to restore the default.

Syntax

ospf mtu-enable

undo ospf mtu-enable

Default

The MTU in DD packets is 0.

Views

Interface view

Predefined user roles

network-admin

mdc-admin

Usage guidelines

After a virtual link is established through a Virtual-Template or Tunnel, two devices on the link from different vendors might have different MTU values. To make them consistent, restore the interfaces' MTU to the default value 0.

After you configure this command, the interface checks whether the MTU in a received DD packet is greater than its own MTU. If yes, the interface discards the packet.

Examples

# Enable VLAN-interface 10 to add the interface MTU value into DD packets.

<Sysname> system-view

[Sysname] interface vlan-interface 10

[Sysname-Vlan-interface10] ospf mtu-enable

ospf network-type

Use ospf network-type to set the network type for an interface.

Use undo ospf network-type to restore the default network type for an interface.

Syntax

ospf network-type { broadcast | nbma | p2mp [ unicast ] | p2p [ peer-address-check ] }

undo ospf network-type

Default

By default, the network type of an interface depends on its link layer protocol:

·     For Ethernet and FDDI, the network type is broadcast.

·     For ATM, FR, and X.25, the network type is NBMA.

·     For PPP, LAPB, HDLC, and POS, the network type is P2P.

Views

Interface view

Predefined user roles

network-admin

mdc-admin

Parameters

broadcast: Specifies the network type as broadcast.

nbma: Specifies the network type as NBMA.

p2mp: Specifies the network type as P2MP.

unicast: Specifies the P2MP interface to unicast OSPF packets. By default, a P2MP interface multicasts OSPF packets.

p2p: Specifies the network type as P2P.

peer-address-check: Checks whether the peer interface and the local interface are on the same network segment. Two P2P interfaces can establish a neighbor relationship only when they are on the same network segment.

Usage guidelines

If a router on a broadcast network does not support multicast, configure the network type for the connected interfaces as NBMA.

If any two routers on an NBMA network are directly connected through a virtual link, the network is fully meshed, and you can configure the network type for the connected interfaces as NBMA. If two routers are not directly connected, configure the P2MP network type so that the two routers can exchange routing information through another router.

When the network type of an interface is NBMA or P2MP unicast, you must use the peer command to specify the neighbor.

If only two routers run OSPF on a network, you can configure the network type for the connected interfaces as P2P.

When the network type of an interface is P2MP unicast, all OSPF packets are unicast by the interface.

Examples

# Configure the OSPF network type for VLAN-interface 10 as NBMA.

<Sysname> system-view

[Sysname] interface vlan-interface 10

[Sysname-Vlan-interface10] ospf network-type nbma

Related commands

ospf dr-priority

ospf prefix-suppression

Use ospf prefix-suppression to disable an OSPF interface from advertising all its IP prefixes, except for the prefixes of secondary IP addresses.

Use undo ospf prefix-suppression to restore the default.

Syntax

ospf prefix-suppression [ disable ]

undo ospf prefix-suppression

Default

Prefix suppression is disabled.

Views

Interface view

Predefined user roles

network-admin

mdc-admin

Parameters

disable: Disables prefix suppression on an interface.

Usage guidelines

To disable prefix suppression on an interface associated with an OSPF process that has been enabled with prefix suppression, execute the ospf prefix-suppression disable command on that interface.

For more information, see "prefix-suppression."

Examples

# Enable prefix suppression on VLAN-interface 10.

<Sysname> system-view

[Sysname] interface vlan-interface 10

[Sysname-Vlan-interface10] ospf prefix-suppression

Related commands

prefix-suppression

ospf primary-path-detect bfd echo

Use ospf primary-path-detect bfd echo to enable BFD single-hop echo detection for OSPF FRR or OSPF PIC.

Use undo ospf primary-path-detect bfd to restore the default.

Syntax

ospf primary-path-detect bfd echo

undo ospf primary-path-detect bfd

Default

BFD single-hop echo detection is disabled for OSPF FRR or OSPF PIC.

Views

Interface view

Predefined user roles

network-admin

mdc-admin

Usage guidelines

This command enables OSPF PIC or OSPF FRR to use BFD single-hop echo detection to detect primary link failures.

Examples

# On VLAN-interface 10, enable BFD single-hop echo detection for OSPF FRR.

<Sysname> system-view

[Sysname] ospf 1

[Sysname-ospf-1] fast-reroute lfa

[Sysname-ospf-1] quit

[Sysname] bfd echo-source-ip 1.1.1.1

[Sysname] interface vlan-interface 10

[Sysname-Vlan-interface10] ospf primary-path-detect bfd echo

# On VLAN-interface 11, enable BFD single-hop echo detection for OSPF PIC.

<Sysname> system-view

[Sysname] ospf 1

[Sysname-ospf-1] pic additional-path-always

[Sysname-ospf-1] quit

[Sysname] bfd echo-source-ip 1.1.1.1

[Sysname] interface vlan-interface 11

[Sysname-Vlan-interface11] ospf primary-path-detect bfd echo

ospf timer dead

Use ospf timer dead to set the neighbor dead interval.

Use undo ospf timer dead to restore the default.

Syntax

ospf timer dead seconds

undo ospf timer dead

Default

The dead interval is 40 seconds for broadcast and P2P interfaces. The dead interval is 120 seconds for P2MP and NBMA interfaces.

Views

Interface view

Predefined user roles

network-admin

mdc-admin

Parameters

seconds: Specifies the dead interval in the range of 1 to 2147483647 seconds.

Usage guidelines

If an interface receives no hello packet from a neighbor within the dead interval, the interface considers the neighbor down. The dead interval on an interface is at least four times the hello interval. Routers attached to the same segment must have the same dead interval.

Examples

# Configure the dead interval for VLAN-interface 10 as 60 seconds.

<Sysname> system-view

[Sysname] interface vlan-interface 10

[Sysname-Vlan-interface10] ospf timer dead 60

Related commands

ospf timer hello

ospf timer hello

Use ospf timer hello to set the hello interval on an interface.

Use undo ospf timer hello to restore the default.

Syntax

ospf timer hello seconds

undo ospf timer hello

Default

The hello interval is 10 seconds for P2P and broadcast interfaces, and is 30 seconds for P2MP and NBMA interfaces.

Views

Interface view

Predefined user roles

network-admin

mdc-admin

Parameters

seconds: Specifies the hello interval in the range of 1 to 65535 seconds.

Usage guidelines

The shorter the hello interval, the faster the topology converges, and the more resources are consumed. Make sure the hello interval on two neighboring interfaces is the same.

Examples

# Configure the hello interval on VLAN-interface as 20 seconds.

<Sysname> system-view

[Sysname] interface vlan-interface 10

[Sysname-Vlan-interface10] ospf timer hello 20

Related commands

ospf timer dead

ospf timer poll

Use ospf timer poll to set the poll interval on an NBMA interface.

Use undo ospf timer poll to restore the default.

Syntax

ospf timer poll seconds

undo ospf timer poll

Default

The poll interval is 120 seconds on an interface.

Views

Interface view

Predefined user roles

network-admin

mdc-admin

Parameters

seconds: Specifies the poll interval in the range of 1 to 2147483647 seconds.

Usage guidelines

When an NBMA interface finds its neighbor is down, it sends hello packets at the poll interval.

The poll interval must be at least four times the hello interval.

Examples

# Set the poll timer interval on VLAN-interface 10 to 130 seconds.

<Sysname> system-view

[Sysname] interface vlan-interface 10

[Sysname-Vlan-interface10] ospf timer poll 130

Related commands

ospf timer hello

ospf timer retransmit

Use ospf timer retransmit to set the LSA retransmission interval on an interface.

Use undo ospf timer retransmit to restore the default.

Syntax

ospf timer retransmit interval

undo ospf timer retransmit

Default

The LSA retransmission interval is 5 seconds on an interface.

Views

Interface view

Predefined user roles

network-admin

mdc-admin

Parameters

interval: Specifies the LSA retransmission interval in the range of 1 to 3600 seconds.

Usage guidelines

After sending an LSA, an interface waits for an acknowledgement packet. If the interface receives no acknowledgement within the retransmission interval, it retransmits the LSA.

To avoid unnecessary retransmissions, set an appropriate retransmission interval. For example, you can set a large retransmission interval value on a low-speed link.

Examples

# Set the LSA retransmission interval to 8 seconds on VLAN-interface 10.

<Sysname> system-view

[Sysname] interface vlan-interface 10

[Sysname-Vlan-interface10] ospf timer retransmit 8

ospf trans-delay

Use ospf trans-delay to set the LSA transmission delay on an interface.

Use undo ospf trans-delay to restore the default.

Syntax

ospf trans-delay seconds

undo ospf trans-delay

Default

The LSA transmission delay is 1 second.

Views

Interface view

Predefined user roles

network-admin

mdc-admin

Parameters

seconds: Specifies the LSA transmission delay in the range of 1 to 3600 seconds.

Usage guidelines

Each LSA in the LSDB has an age that is incremented by 1 every second, but the age does not change during transmission. Adding a transmission delay into the age time is important in low speed networks.

Examples

# Set the LSA transmission delay to 3 seconds on VLAN-interface 10.

<Sysname> system-view

[Sysname] interface vlan-interface 10

[Sysname-Vlan-interface10] ospf trans-delay 3

peer

Use peer to specify a neighbor and a DR priority for the neighbor.

Use undo peer to remove the configuration.

Syntax

peer ip-address [ cost value | dr-priority dr-priority ]

undo peer ip-address

Default

No neighbor is specified.

Views

OSPF view

Predefined user roles

network-admin

mdc-admin

Parameters

ip-address: Specifies a neighbor by its IP address.

cost value: Specifies the cost to reach the neighbor, in the range of 1 to 65535.

dr-priority dr-priority: Specifies the DR priority for the neighbor, in the range of 0 to 255. The default neighbor DR priority is 1.

Usage guidelines

Because routers on an X.25 or Frame Relay network cannot locate neighbors by multicasting hello packets, you must use this command to specify neighbors.

At startup, a router sends a hello packet to neighbors with a nonzero priority. After the DR and BDR are elected, the DR sends hello packets to all neighbors to create adjacencies.

The cost set with the peer command applies only to P2MP neighbors. If no cost is specified, the cost to the neighbor equals the local interface's cost.

A router uses the priority set with the peer command to determine whether to send a hello packet to the neighbor rather than for DR election. The DR priority set with the ospf dr-priority command is used for DR election.

Examples

# Specify the neighbor 1.1.1.1.

<Sysname> system-view

[Sysname] ospf 100

[Sysname-ospf-100] peer 1.1.1.1

Related commands

ospf dr-priority

pic

Use pic to enable OSPF PIC.

Use undo pic to disable OSPF PIC.

Syntax

pic [ additional-path-always ]

undo pic

Default

OSPF PIC is enabled.

Views

OSPF view

Predefined user roles

network-admin

mdc-admin

Parameters

additional-path-always: Allows the indirect suboptimal route as the backup route.

Usage guidelines

Prefix Independent Convergence (PIC) enables the device to speed up network convergence by ignoring the number of prefixes. PIC applies to only inter-area routes and external routes.

When both OSPF PIC and OSPF FRR are configured, OSPF FRR takes effect.

Examples

# Configure OSPF PIC to support the suboptimal route as the backup route.

<Sysname> system-view

[Sysname] ospf 1

[Sysname-ospf-1] pic additional-path-always

preference

Use preference to set a preference for OSPF.

Use undo preference to restore the default.

Syntax

preference [ ase ] [ route-policy route-policy-name ] value

undo preference [ ase ]

Default

The preference is 10 for OSPF internal routes and 150 for OSPF external routes (or ASE routes).

Views

OSPF view

Predefined user roles

network-admin

mdc-admin

Parameters

ase: Sets a preference for OSPF external routes. If you do not specify this keyword, the command sets a preference for OSPF internal routes.

route-policy route-policy-name: Specifies a routing policy by its name, a case-sensitive string of 1 to 63 characters, to set a preference for the specified routes.

value: Specifies the preference value in the range of 1 to 255. The smaller the value, the higher the preference.

Usage guidelines

If multiple routing protocols find routes to the same destination, the router uses the route found by the protocol with the highest preference.

Examples

# Set a preference of 200 for OSPF external routes.

<Sysname> system-view

[Sysname] ospf 100

[Sysname-ospf-100] preference ase 200

# Use a routing policy to set a preference of 100.

<Sysname> system-view

[Sysname] ip prefix-list test index 10 permit 100.1.1.0 24

[Sysname] route-policy pre permit node 10

[Sysname-route-policy-pre-10] if-match ip address prefix-list test

[Sysname-route-policy-pre-10] quit

[Sysname] ospf 100

[Sysname-ospf-100] preference route-policy pre 100

prefix-priority

Use prefix-priority to enable prefix prioritization.

Use undo prefix-priority to disable prefix prioritization.

Syntax

prefix-priority route-policy route-policy-name

undo prefix-priority

Default

Prefix prioritization is disabled.

Views

OSPF view

Predefined user roles

network-admin

mdc-admin

Parameters

route-policy route-policy-name: Specifies a routing policy by its name, a case-sensitive string of 1 to 63 characters, to set a priority for the specified route prefixes.

Usage guidelines

Prefix prioritization enables the device to install prefixes in descending priority order: critical, high, medium, and low. The prefix priorities are assigned through routing policies. When a route is assigned multiple prefix priorities, it uses the highest priority.

By default, the 32-bit OSPF host routes have a medium priority and other routes have a low priority.

Examples

# Use a routing policy to assign the medium priority to the specified route prefixes.

<Sysname> system-view

[Sysname] ip prefix-list test index 10 permit 100.1.1.0 24

[Sysname] route-policy pre permit node 10

[Sysname-route-policy-pre-10] if-match ip address prefix-list test

[Sysname-route-policy-pre-10] apply prefix-priority medium

[Sysname-route-policy-pre-10] quit

[Sysname] ospf 100

[Sysname-ospf-100] prefix-priority route-policy pre

prefix-suppression

Use prefix-suppression to disable an OSPF process from advertising all IP prefixes except for the prefixes of loopback interfaces, secondary IP addresses, and passive interfaces.

Use undo prefix-suppression to restore the default.

Syntax

prefix-suppression

undo prefix-suppression

Default

An OSPF process advertises all prefixes.

Views

OSPF view

Predefined user roles

network-admin

mdc-admin

Usage guidelines

As a best practice, configure prefix suppression on all OSPF routers if you want to use prefix suppression.

To disable an OSPF process from advertising the prefixes of loopback interfaces and passive interfaces, configure prefix suppression on the interfaces by using the ospf prefix-suppression command.

When prefix suppression is enabled:

·     On P2P and P2MP networks, OSPF does not advertise Type-3 links in Router LSAs. Other routing information can still be advertised to ensure traffic forwarding.

·     On broadcast and NBMA networks, the DR generates Network LSAs with a mask length of 32 to suppress network routes. Other routing information can still be advertised to ensure traffic forwarding. If no neighbors exist, the DR also does not advertise the primary IP addresses of interfaces in Router LSAs.

Examples

# Enable prefix suppression for OSPF process 1.

<Sysname> system-view

[Sysname] ospf 1

[Sysname-ospf-1] prefix-suppression

Related commands

ospf prefix-suppression

reset ospf statistics

Use reset ospf statistics to clear OSPF statistics.

Syntax

reset ospf [ process-id ] statistics

Views

User view

Predefined user roles

network-admin

mdc-admin

Parameters

process-id: Clears the statistics for an OSPF process specified by its ID in the range of 1 to 65535.

Examples

# Clear OSPF statistics for all processes.

<Sysname> reset ospf statistics

reset ospf event-log

Use reset ospf event-log to clear OSPF log information.

Syntax

reset ospf [ process-id ] event-log [ lsa-flush | peer | spf ]

Views

User view

Predefined user roles

network-admin

mdc-admin

Parameters

process-id: Specifies an OSPF process by its ID in the range of 1 to 65535. If you do not specify this argument, the command clears OSPF log information for all OSPF processes.

lsa-flush: Clears LSA aging log information.

peer: Clears neighbor log information.

spf: Clears route calculation log information.

Usage guidelines

If no log type is specified, the command clears all log information.

Examples

# Clear OSPF route calculation log information for all OSPF processes.

<Sysname> reset ospf event-log spf

Related commands

display ospf event-log

reset ospf process

Use reset ospf process to restart all OSPF processes or a specified process.

Syntax

reset ospf [ process-id ] process [ graceful-restart ]

Views

User view

Predefined user roles

network-admin

mdc-admin

Parameters

process-id: Specifies an OSPF process by its ID in the range of 1 to 65535.

graceful-restart: Resets the OSPF process by using GR.

Usage guidelines

If no process is specified, this command restarts all OSPF processes.

The reset ospf process command performs the following actions:

·     Clears all invalid LSAs without waiting for their timeouts.

·     Makes a newly configured Router ID take effect.

·     Starts a new round of DR/BDR election.

·     Does not remove previous OSPF configurations.

The system prompts you to select whether to reset OSPF process upon execution of this command.

Examples

# Reset all OSPF processes.

<Sysname> reset ospf process

Reset OSPF process? [Y/N]:y

reset ospf redistribution

Use reset ospf redistribution to restart route redistribution.

Syntax

reset ospf [ process-id ] redistribution

Views

User view

Predefined user roles

network-admin

mdc-admin

Parameters

process-id: Specifies an OSPF process by its ID in the range of 1 to 65535.

Usage guidelines

If no process ID is specified, this command restarts route redistribution for all OSPF processes.

Examples

# Restart route redistribution.

<Sysname> reset ospf redistribution

rfc1583 compatible

Use rfc1583 compatible to enable compatibility with RFC 1583.

Use undo rfc1583 compatible to disable compatibility with RFC 1583.

Syntax

rfc1583 compatible

undo rfc1583 compatible

Default

Compatibility with RFC 1583 is enabled.

Views

OSPF view

Predefined user roles

network-admin

mdc-admin

Usage guidelines

RFC 1583 specifies a different method than RFC 2328 for selecting the optimal route to a destination in another AS. When multiple routes are available to the ASBR, OSPF selects the optimal route by using the following procedure:

1.     Selects the route with the highest preference:

¡     If RFC 2328 is compatible with RFC 1583, all these routes have equal preference.

¡     If RFC 2328 is not compatible with RFC 1583, the intra-area route in a non-backbone area is preferred to reduce the burden of the backbone area. The inter-area route and intra-area route in the backbone area have equal preference.

2.     Selects the route with lower cost if two routes have equal preference.

3.     Selects the route with larger originating area ID if two routes have equal cost.

To avoid routing loops, set identical RFC 1583-compatibility on all routers in a routing domain.

Examples

# Disable compatibility with RFC 1583.

<Sysname> system-view

[Sysname] ospf 100

[Sysname-ospf-100] undo rfc1583 compatible

router id

Use router id to configure a global router ID.

Use undo router id to restore the default.

Syntax

router id router-id

undo router id

Default

No global router ID is configured.

Views

System view

Predefined user roles

network-admin

mdc-admin

Parameters

router-id: Specifies the router ID, in the format of an IPv4 address.

Usage guidelines

OSPF uses a router ID to identify a device. If no router ID is specified, the global router ID is used.

If no global router ID is configured, the highest loopback interface IP address is used as the router ID. If no loopback interface IP address is available, the highest physical interface IP address is used, regardless of the interface status (up or down).

During an active/standby switchover, the new active main processing unit (MPU) checks whether the previously backed up router ID is valid. If not, it selects a new router ID.

A new router ID is selected only when the interface IP address used as the router ID is removed or changed. Other events will not trigger a router ID re-selection. For example, router ID re-selection is not triggered when the interface goes down, you change the router ID to the address of a loopback interface after a physical interface address is selected as the router ID, or a higher interface IP address is configured as the router ID.

After a router ID is changed, you must use the reset command to enable it.

Examples

# Configure a global router ID as 1.1.1.1.

<Sysname> system-view

[Sysname] router id 1.1.1.1

silent-interface (OSPF view)

Use silent-interface to disable an interface or all interfaces from receiving and sending OSPF packets.

Use undo silent-interface to remove the configuration.

Syntax

silent-interface { interface-type interface-number | all }

undo silent-interface { interface-type interface-number | all }

Default

An interface can receive and send OSPF packets.

Views

OSPF view

Predefined user roles

network-admin

mdc-admin

Parameters

interface-type interface-number: Specifies an interface by its type and number.

all: Specifies all interfaces.

Usage guidelines

A disabled interface is a passive interface that cannot receive or send any hello packets.

To disable a network from receiving and sending OSPF routes, issue the command on the interface connected to the network.

Examples

# Disable VLAN-interface 10 from receiving and sending OSPF packets.

<Sysname> system-view

[Sysname] ospf 100

[Sysname-ospf-100] silent-interface vlan-interface 10

snmp-agent trap enable ospf

Use snmp-agent trap enable ospf to enable SNMP notifications for OSPF.

Use undo snmp-agent trap enable ospf to disable the feature.

Syntax

snmp-agent trap enable ospf [ authentication-failure | bad-packet | config-error | grhelper-status-change | grrestarter-status-change | if-state-change | lsa-maxage | lsa-originate | lsdb-approaching-overflow | lsdb-overflow | neighbor-state-change | nssatranslator-status-change | retransmit | virt-authentication-failure | virt-bad-packet | virt-config-error | virt-retransmit | virtgrhelper-status-change | virtif-state-change | virtneighbor-state-change ] *

undo snmp-agent trap enable ospf [ authentication-failure | bad-packet | config-error | grhelper-status-change | grrestarter-status-change | if-state-change | lsa-maxage | lsa-originate | lsdb-approaching-overflow | lsdb-overflow | neighbor-state-change | nssatranslator-status-change | retransmit | virt-authentication-failure | virt-bad-packet | virt-config-error | virt-retransmit | virtgrhelper-status-change | virtif-state-change | virtneighbor-state-change ] *

Default

SNMP notifications for OSPF is enabled.

Views

System view

Predefined user roles

network-admin

mdc-admin

Parameters

authentication-failure: Specifies notifications about authentication failures on an interface.

bad-packet: Specifies notifications about error messages received on an interface.

config-error: Specifies notifications about error configuration of an interface.

grhelper-status-change: Specifies notifications about GR helper state change.

grrestarter-status-change: Specifies notifications about GR restarter state change.

if-state-change: Specifies notifications about interface state change.

lsa-maxage: Specifies LSA max age notifications.

lsa-originate: Specifies notifications about locally generated LSAs.

lsdb-approaching-overflow: Specifies notifications about approaching LSDB overflows.

lsdb-overflow: Specifies LSDB overflow notifications.

neighbor-state-change: Specifies notifications about neighbor state change.

nssatranslator-status-change: Specifies notifications about NSSA translator state change.

retransmit: Specifies notifications about packets that are received and forwarded on an interface.

virt-authentication-failure: Specifies notifications about authentication failures on a virtual interface.

virt-bad-packet: Specifies notifications about error messages received on a virtual interface.

virt-config-error: Specifies notifications about error configuration of a virtual interface.

virt-retransmit: Specifies notifications about packets that are received and forwarded on a virtual interface.

virtgrhelper-status-change: Specifies notifications about neighbor GR helper state changes of a virtual interface.

virtif-state-change: Specifies notifications about virtual interface state change.

virtneighbor-state-change: Specifies notifications about the neighbor state change of a virtual interface.

Examples

# Disable SNMP notifications for OSPF.

<Sysname> system-view

[Sysname] undo snmp-agent trap enable ospf

snmp trap rate-limit

Use snmp trap rate-limit to configure the maximum number of output SNMP notifications within a specified time interval.

Use undo snmp trap rate-limit to restore the default.

Syntax

snmp trap rate-limit interval trap-interval count trap-number

undo snmp trap rate-limit

Default

OSPF outputs up to seven SNMP notifications within 10 seconds.

Views

OSPF view

Predefined user roles

network-admin

mdc-admin

Parameters

trap-interval: Specifies the SNMP notification output interval in the range of 1 to 60 seconds.

trap-number: Specifies the number of output SNMP notifications in a specific time, in the range of 0 to 300.

Examples

# Configure OSPF to output up to 10 SNMP notifications within 5 seconds.

<Sysname> system-view

[Sysname] ospf 100

[Sysname-ospf-100] snmp trap rate-limit interval 5 count 10

spf-schedule-interval

Use spf-schedule-interval to set the OSPF SPF calculation interval.

Use undo spf-schedule-interval to restore the default.

Syntax

spf-schedule-interval maximum-interval [ minimum-interval [ incremental-interval ] ]

undo spf-schedule-interval

Default

The maximum calculation interval is 5 seconds, the minimum interval is 50 milliseconds, and the incremental interval is 200 milliseconds.

Views

OSPF view

Predefined user roles

network-admin

mdc-admin

Parameters

maximum-interval: Specifies the maximum OSPF SPF calculation interval in the range of 1 to 60 seconds.

minimum-interval: Specifies the minimum OSPF SPF calculation interval in the range of 10 to 60000 milliseconds.

incremental-interval: Specifies the incremental OSPF SPF calculation interval in the range of 10 to 60000 milliseconds.

Usage guidelines

Based on the LSDB, an OSPF router uses SPF to calculate a shortest path tree with itself as the root. OSPF uses the shortest path tree to determine the next hop to a destination. By adjusting the SPF calculation interval, you can prevent bandwidth and router resources from being over-consumed due to frequent topology changes.

When network changes are not frequent, OSPF performs SPF calculations at the minimum-interval. If network changes become frequent, the SPF calculation interval is incremented by the incremental-interval each time a calculation happens until the maximum-interval is reached.

The minimum interval and the incremental interval cannot be greater than the maximum interval.

Examples

# Configure the maximum SPF calculation interval as 10 seconds, minimum interval as 500 milliseconds and incremental interval as 300 milliseconds.

<Sysname> system-view

[Sysname] ospf 100

[Sysname-ospf-100] spf-schedule-interval 10 500 300

stub (OSPF area view)

Use stub to configure an area as a stub area.

Use undo stub to restore the default.

Syntax

stub [ default-route-advertise-always | no-summary ] *

undo stub

Default

No area is a stub area.

Views

OSPF area view

Predefined user roles

network-admin

mdc-admin

Parameters

default-route-advertise-always: Used only on a stub ABR. With this keyword, the ABR advertises a default route in a Type-3 LSA into the stub area regardless of whether FULL-state neighbors exist in the backbone area. If you do not specify this keyword, the ABR advertises a default route in a Type-3 LSA into the stub area only when at least one FULL-state neighbor exists in the backbone area.

no-summary: Used only on a stub ABR. With this keyword, the ABR advertises only a default route in a Type-3 LSA into the stub area without advertising any other Type-3 LSAs (such a stub area is a totally stub area).

Usage guidelines

To remove the default-route-advertise-always or stub no-summary configuration on the ABR, execute the stub command again to overwrite it.

To configure an area as a stub area, issue the stub command on all routers attached to the area.

Examples

# Configure Area 1 as a stub area.

<Sysname> system-view

[Sysname] ospf 100

[Sysname-ospf-100] area 1

[Sysname-ospf-100-area-0.0.0.1] stub

Related commands

default-cost (OSPF area view)

stub-router

Use stub-router to configure a router as a stub router.

Use undo stub-router to restore the default.

Syntax

stub-router [ external-lsa [ max-metric-value ] | include-stub | on-startup { seconds | wait-for-bgp [ seconds ] } | summary-lsa [ max-metric-value ] ] *

undo stub-router

Default

No router is a stub router.

Views

OSPF view

Predefined user roles

network-admin

mdc-admin

Parameters

external-lsa max-metric-value: Specifies a cost for the external LSAs, in the range of 1 to 16777215. The default is 16711680.

include-stub: Sets the cost of the stub links (link type 3) in Router LSAs to the maximum value 65535.

on-startup seconds: Specifies the router as a stub router during reboot, and specifies the timeout time in the range of 5 to 86400 seconds.

wait-for-bgp seconds: Specifies the router as a stub router during BGP route convergence after reboot, and specifies the timeout time in the range of 5 to 86400 seconds. The default timeout time is 600 seconds.

summary-lsa max-metric-value: Specifies a cost for the Type-3 LSAs, in the range of 1 to 16777215. The default cost value is 16711680.

Usage guidelines

The router LSAs sent by the stub router over different links contain different link type values. A value of 3 represents a link to a stub network, and the cost of the link is not changed. A value of 1, 2, or 4 represents a point-to-point link, a link to a transit network, or a virtual link, and the cost of such links is set to 65535. Neighbors on such links will not send packets to the stub router as long as they have a route with a smaller cost.

Examples

# Configure a stub router.

<Sysname> system-view

[Sysname] ospf 100

[Sysname-ospf-100] stub-router

transmit-pacing

Use transmit-pacing to configure the maximum number of LSU packets that can be sent at the specified interval.

Use undo transmit-pacing to restore the default.

Syntax

transmit-pacing interval interval count count

undo transmit-pacing

Default

An OSPF interface sends a maximum of three LSU packets every 20 milliseconds.

Views

OSPF view

Predefined user roles

network-admin

mdc-admin

Parameters

interval interval: Specifies an interval at which an interface sends LSU packets, in the range of 10 to 1000 milliseconds. If the router has multiple OSPF interfaces, increase this interval to reduce the total number of LSU packets sent by the router every second.

count count: Specifies the maximum number of LSU packets sent by an interface at each interval, in the range of 1 to 200. If the router has multiple OSPF interfaces, decrease the maximum number to reduce the total number of LSU packets sent by the router every second.

Examples

# Configure all the interfaces running OSPF process 1 to send up to 10 LSU packets every 30 milliseconds.

<Sysname> system-view

[Sysname] ospf 1

[Sysname-ospf-1] transmit-pacing interval 30 count 10

vlink-peer (OSPF area view)

Use vlink-peer to configure a virtual link.

Use undo vlink-peer to remove a virtual link.

Syntax

vlink-peer router-id [ dead seconds | hello seconds | { { hmac-md5 | md5 } key-id { cipher cipher-string | plain plain-string } | simple { cipher cipher-string | plain plain-string } } | retransmit seconds | trans-delay seconds ] *

undo vlink-peer router-id [ dead | hello | { hmac-md5 | md5 } key-id | retransmit | simple | trans-delay ] *

Default

No virtual link is configured.

Views

OSPF area view

Predefined user roles

network-admin

mdc-admin

Parameters

router-id: Specifies the router ID of the neighbor on the virtual link.

dead seconds: Sets the dead interval in the range of 1 to 32768 seconds. The default is 40. The dead interval must be identical with that on the virtual link neighbor, and at least four times the hello interval.

hello seconds: Sets the hello interval in the range of 1 to 8192 seconds. The default is 10. It must be identical with the hello interval on the virtual link neighbor.

hmac-md5: Specifies the HMAC-MD5 authentication mode.

md5: Specifies the MD5 authentication mode.

simple: Specifies the simple authentication mode.

key-id: Specifies the key ID for MD5 or HMAC-MD5 authentication, in the range of 1 to 255.

cipher: Sets a ciphertext key.

cipher-string: Specifies a ciphertext key. If simple is specified, the key must be a string of 33 to 41 characters. If md5 or hmac-md5 is specified, the key must be a string of 33 to 53 characters.

plain: Sets a plaintext key.

plain-string: Specifies a plaintext key. If simple is specified, the key must be a string of 1 to 8 characters. If md5 or hmac-md5 is specified, the key must be a string of 1 to 16 characters.

retransmit seconds: Sets the retransmission interval in the range of 1 to 3600 seconds. The default is 5.

trans-delay seconds: Sets the transmission delay interval in the range of 1 to 3600 seconds. The default is 1.

Usage guidelines

As defined in RFC 2328, all non-backbone areas must maintain connectivity to the backbone. You can use the vlink-peer command to configure a virtual link to connect an area to the backbone.

When you configure this command, follow these guidelines:

·     The smaller the hello interval is, the faster the network converges, and the more network resources are consumed.

·     A retransmission interval that is too small can cause unnecessary retransmissions. A large value is appropriate for a low speed link.

·     Specify an appropriate transmission delay with the trans-delay keyword.

For security purposes, all keys, including keys configured in plain text, are saved in cipher text.

You can specify either MD5/HMAC-MD5 authentication or simple authentication for a virtual link. For MD5/HMAC-MD5 authentication, you can configure multiple keys by executing this command multiple times, and each command must have a unique key ID and key string.

To modify the key of a virtual link, perform the following key rollover configurations:

1.     Configure a new MD5/HMAC-MD5 authentication key for the virtual link on the local device. If the new key is not configured on the neighbor device, MD5/HMAC-MD5 authentication key rollover is triggered. During key rollover, OSPF sends multiple packets that contain both the new and old MD5/HMAC-MD5 authentication keys to make sure the neighbor device can pass the authentication.

2.     Configure the new MD5/HMAC-MD5 authentication key on the neighbor device. When the local device receives packets with the new key from the neighbor device, it exits MD5 key rollover.

3.     Delete the old MD5/HMAC-MD5 authentication key from the local device and the neighbor. This step helps prevent attacks from devices that use the old key for communication and reduces system resources and bandwidth consumption caused by key rollover.

Examples

# Configure a virtual link to the neighbor with router ID 1.1.1.1.

<Sysname> system-view

[Sysname] ospf 100

[Sysname-ospf-100] area 2

[Sysname-ospf-100-area-0.0.0.2] vlink-peer 1.1.1.1

Related commands

·     authentication-mode

·     display ospf vlink

 


IS-IS commands

area-authentication-mode

Use area-authentication-mode to specify an area authentication mode and a password.

Use undo area-authentication-mode to restore the default.

Syntax

area-authentication-mode { md5 | simple } { cipher cipher-string | plain plain-string } [ ip | osi ]

undo area-authentication-mode

Default

No area authentication or password is configured.

Views

IS-IS view

Predefined user roles

network-admin

mdc-admin

Parameters

md5: Specifies the MD5 authentication mode.

simple: Specifies the simple authentication mode.

cipher: Sets a ciphertext password.

cipher-string: Specifies a ciphertext password, a case-sensitive string of 33 to 53 characters.

plain: Sets a plaintext password.

plain-string: Specifies a plaintext password, a case-sensitive string of 1 to 16 characters.

ip: Checks IP-related fields in LSPs.

osi: Checks OSI-related fields in LSPs.

Usage guidelines

The password in the specified mode is inserted into all outbound Level-1 packets (LSP, CSNP, and PSNP) and is used to authenticate inbound Level-1 packets.

Area authentication enables IS-IS to discard routes from untrusted routers.

Routers in an area must have the same authentication mode and password.

If neither ip nor osi is specified, OSI-related fields are checked.

For security purposes, all passwords, including passwords configured in plain text, are saved in cipher text.

Examples

# Configure the area authentication mode as simple, and set the plaintext password to 123456.

<Sysname> system-view

[Sysname] isis 1

[Sysname-isis-1] area-authentication-mode simple plain 123456

Related commands

·     domain-authentication-mode

·     isis authentication-mode

auto-cost enable

Use auto-cost enable to enable automatic link cost calculation.

Use undo auto-cost enable to disable the function.

Syntax

auto-cost enable

undo auto-cost enable

Default

This function is disabled.

Views

IS-IS view

Predefined user roles

network-admin

mdc-admin

Usage guidelines

After automatic link cost calculation is enabled, the link cost is automatically calculated based on the bandwidth reference value of an interface. When the cost-style is wide or wide-compatible, the cost value of an interface is calculated by using the formula: Cost = (reference bandwidth value / link bandwidth) × 10. For other cost styles, Table 46 applies.

Table 46 Automatic cost calculation scheme for cost styles other than wide and wide-compatible

Interface bandwidth

Cost

≤10 Mbps

60

≤100 Mbps

50

≤155 Mbps

40

≤622 Mbps

30

≤2500 Mbps

20

>2500 Mbps

10

 

Examples

# Enable automatic link cost calculation for IS-IS process 1.

<Sysname> system-view

[Sysname] isis 1

[Sysname-isis-1] auto-cost enable

Related commands

·     bandwidth-reference

·     cost-style

·     isis cost

bandwidth-reference (IS-IS view)

Use bandwidth-reference to set the bandwidth reference value for automatic link cost calculation.

Use undo bandwidth-reference to restore the default.

Syntax

bandwidth-reference value

undo bandwidth-reference

Default

The bandwidth reference value is 100 Mbps.

Views

IS-IS view

Predefined user roles

network-admin

mdc-admin

Parameters

value: Specifies the bandwidth reference value in the range of 1 to 2147483648 Mbps.

Examples

# Configure the bandwidth reference of IS-IS process 1 as 200 Mbps.

<Sysname> system-view

[Sysname] isis 1

[Sysname-isis-1] bandwidth-reference 200

Related commands

·     auto-cost enable

·     isis cost

circuit-cost

Use circuit-cost to set a global IS-IS link cost.

Use undo circuit-cost to remove the configuration.

Syntax

circuit-cost value [ level-1 | level-2 ]

undo circuit-cost [ level-1 | level-2 ]

Default

No global link cost is configured.

Views

IS-IS view

Predefined user roles

network-admin

mdc-admin

Parameters

value: Specifies the link cost value. The value range varies by cost style.

·     For styles narrow, narrow-compatible, and compatible, the cost value is in the range of 0 to 63.

·     For styles wide and wide-compatible, the cost value is in the range of 0 to 16777215.

level-1: Applies the link cost to Level-1.

level-2: Applies the link cost to Level-2.

Usage guidelines

If no level is specified, the specified cost applies to both Level-1 and Level-2.

Examples

# Set the global Level-1 link cost of IS-IS process 1 to 11.

<Sysname> system-view

[Sysname] isis 1

[Sysname-isis-1] circuit-cost 11 level-1

Related commands

·     cost-style

·     isis cost

cost-style

Use cost-style to set a cost style.

Use undo cost-style to restore the default.

Syntax

cost-style { narrow | wide | wide-compatible | { compatible | narrow-compatible } [ relax-spf-limit ] }

undo cost-style

Default

Only narrow cost style packets can be received and sent.

Views

IS-IS view

Predefined user roles

network-admin

mdc-admin

Parameters

narrow: Receives and sends only narrow cost style packets. (The narrow cost is in the range of 0 to 63.)

wide: Receives and sends only wide cost style packets. (The wide cost is in the range of 0 to 16777215.)

compatible: Receives and sends both wide and narrow cost style packets.

narrow-compatible: Receives both narrow and wide cost style packets, but sends only narrow cost style packets.

wide-compatible: Receives both narrow and wide cost style packets, but sends only wide cost style packets.

relax-spf-limit: Allows receiving routes with a cost greater than 1023. If this keyword is not specified, any route with a cost bigger than 1023 will be discarded. This keyword is only available when compatible or narrow-compatible is included.

Examples

# Configure the router to send only narrow cost style packets, but receive both narrow and wide cost style packets.

<Sysname> system-view

[Sysname] isis 1

[Sysname-isis-1] cost-style narrow-compatible

Related commands

·     circuit-cost

·     isis cost

default-route-advertise (IS-IS view)

Use default-route-advertise to advertise a default route of 0.0.0.0/0.

Use undo default-route-advertise to restore the default.

Syntax

default-route-advertise [ [ level-1 | level-1-2 | level-2 ] | route-policy route-policy-name ] *

undo default-route-advertise

Default

Default route advertisement is disabled.

Views

IS-IS view

Predefined user roles

network-admin

mdc-admin

Parameters

level-1: Advertises a Level-1 default route.

level-1-2: Advertises both Level-1 and Level-2 default routes.

level-2: Advertises a Level-2 default route.

route-policy route-policy-name: Specifies a routing policy by its name, a case-sensitive string of 1 to 63 characters.

Usage guidelines

If no level is specified, a Level-2 default route is advertised.

The Level-1 default route is advertised to other routers in the same area, and the Level-2 default route is advertised to all the Level-2 and Level-1-2 routers.

You can use a routing policy to specify a level for the default route. The apply isis level-1 command in routing policy view can generate a Level-1 default route. The apply isis level-2 command in routing policy view can generate a Level-2 default route. The apply isis level-1-2 command in routing policy view can generate both a Level-1 default route and Level-2 default route.

Examples

# Configure IS-IS process 1 to advertise a Level-2 default route.

<Sysname> system-view

[Sysname] isis 1

[Sysname-isis-1] default-route-advertise

display isis brief

Use display isis brief to display brief configuration information for an IS-IS process.

Syntax

In standalone mode:

display isis brief [ process-id ] [ standby slot slot-number ]

In IRF mode:

display isis brief [ process-id ] [ standby chassis chassis-number slot slot-number ]

Views

Any view

Predefined user roles

network-admin

network-operator

mdc-admin

mdc-operator

Parameters

process-id: Specifies a process by its ID in the range of 1 to 65535. Without this argument, the command displays brief configuration information for all IS-IS processes.

standby slot slot-number: Displays backup brief IS-IS configuration information for a card. Without this option, the command displays brief IS-IS configuration information. (In standalone mode.)

standby chassis chassis-number slot slot-number: Displays backup brief IS-IS configuration information for a card on an IRF member device. The chassis-number argument specifies the ID of the IRF member device. The slot-number argument specifies the slot number of the card. Without this option, the command displays brief IS-IS configuration information. (In IRF mode.)

Examples

# Display brief IS-IS configuration information.

<Sysname> display isis brief

 

        IS-IS(1) Protocol Brief Information

 

network-entity              : 10.0000.0000.0001.00

is-level                    : level-1-2

cost-style                  : narrow

fast-reroute                : disable

preference                  : 15

lsp-length receive          : 1497

lsp-length originate

    level-1                 : 1497

    level-2                 : 1497

maximum imported routes     : 1000000

timers

    lsp-max-age             : 1200

    lsp-refresh             : 900

    SPF intervals           : 5 50 200

IPv6 enable

    preference              : 15

    maximum imported routes : 1000000

Table 47 Command output

Field

Description

network-entity

Network entity name.

is-level

IS-IS routing level.

cost-style

Cost style.

fast-reroute

Whether FRR is enabled:

·     disable—FRR is disabled.

·     enable—FRR is enabled.

preference

IS-IS route preference.

Lsp-length receive

Maximum LSP that can be received.

Lsp-length originate

Maximum LSP that can be generated.

maximum imported routes

Maximum number of redistributed Level-1/Level-2 IPv4.

Timers

Timers:

·     lsp-max-age—Maximum life period of LSP.

·     lsp-refresh—Refresh interval of LSPs.

·     Interval between SPFs—Interval between SPF calculations.

 

display isis graceful-restart event-log

Use display isis graceful-restart event-log to display IS-IS GR log information.

Syntax

In standalone mode:

display isis graceful-restart event-log slot slot-number

In IRF mode:

display isis graceful-restart event-log chassis chassis-number slot slot-number

Views

Any view

Predefined user roles

network-admin

network-operator

mdc-admin

mdc-operator

Parameters

slot slot-number: Specifies a card by its slot number. (In standalone mode.)

chassis chassis-number slot slot-number: Specifies a card on an IRF member device. The chassis-number argument specifies the ID of the IRF member device. The slot-number argument specifies the slot number of the card. (In IRF mode.)

Examples

# Display IS-IS GR log information about card 1.

<Sysname> display isis graceful-restart event-log slot 1

IS-IS loginfo :

Jul 18 20:44:33 2012 -Slot=0 Enter HA Block status

Jul 18 10:44:33 2012 -Slot=0 Exit HA Block status

Jul 18 20:46:13 2012 -Slot=0 Process 1 enter GR restarting phase(Initialization).

Jul 18 20:46:13 2012 -Slot=0 Prcoess 1 enter GR phase (LSDB synchronization).

Jul 18 20:46:40 2012 -Slot=0 Process 1 enter GR phase (First SPF computation).

Jul 18 20:46:40 2012 -Slot=0 Process 1 enter GR phase (Redistribution).

Jul 18 20:46:40 2012 -Slot=0 Process 1 enter GR phase (Second SPF computation).

Jul 18 20:46:40 2012 -Slot=0 Process 1 enter GR phase (LSP stability).

Jul 18 20:46:40 2012 -Slot=0 Process 1 enter GR phase (LSP generation).

Jul 18 20:46:40 2012 -Slot=0 Process 1 enter GR phase (Finish).

Jul 18 20:46:40 2012 -Slot=0 Process 1 GR complete.

Table 48 Command output

Field

Description

GR phase

GR phase:

·     Initialization.

·     LSDB synchronization.

·     First SPF computation.

·     Redistribution.

·     Second SPF computation.

·     LSP stabilityReady to generate LSPs.

·     LSP generation.

·     Finish.

 

display isis graceful-restart status

Use display isis graceful-restart status to display IS-IS GR state.

Syntax

display isis graceful-restart status [ level-1 | level-2 ] [ process-id ]

Views

Any view

Predefined user roles

network-admin

network-operator

mdc-admin

mdc-operator

Parameters

level-1: Displays the IS-IS Level-1 GR state.

level-2: Displays the IS-IS Level-2 GR state.

process-id: Specifies a process by its ID in the range of 1 to 65535. Without this argument, the command displays GR state of all IS-IS processes.

Examples

# Display IS-IS GR state.

<Sysname> display isis graceful-restart status

 

                        Restart information for IS-IS(1)

                        --------------------------------

Restart status: COMPLETE

Restart phase: Finish

Restart t1: 3, count 10; Restart t2: 60; Restart t3: 300

SA Bit: supported

 

                          Level-1 restart information

                          ---------------------------

Total number of interfaces: 1

Number of waiting LSPs: 0

 

                          Level-2 restart information

                          ---------------------------

Total number of interfaces: 1

Number of waiting LSPs: 0

Table 49 Command output

Field

Description

Restart status

Current GR state:

·     RESTARTINGIn this state, forwarding can be ensured.

·     STARTINGIn this state, forwarding cannot be ensured.

·     COMPLETE—GR is completed.

Restart phase

Current Restart phase:

·     Initialization.

·     LSDB synchronization.

·     First SPF computation.

·     Redistribution.

·     Second SPF computation.

·     LSP stabilityReady to generate LSPs.

·     LSP generation.

·     Finish.

Restart t1

T1 timer, in seconds.

count

Number of T1 timer expirations.

Restart t2

T2 timer, in seconds.

Restart t3

T3 timer, in seconds.

SA Bit

Whether SA is supported:

·     Supported.

·     Not supported.

Total number of interfaces

Total number of IS-IS interfaces.

Number of waiting LSPs

Number of LSPs not obtained by the GR restarter from GR helpers during LSDB synchronization.

 

display isis interface

Use display isis interface to display IS-IS interface information.

Syntax

In standalone mode:

display isis interface [ interface-type interface-number ] [ verbose ] [ process-id ] [ standby slot slot-number ]

In IRF mode:

display isis interface [ interface-type interface-number ] [ verbose ] [ process-id ] [ standby chassis chassis-number slot slot-number ]

Views

Any view

Predefined user roles

network-admin

network-operator

mdc-admin

mdc-operator

Parameters

interface-type interface-number: Displays statistics of a specified IS-IS interface. Without this argument, the command displays information about all interfaces.

verbose: Displays detailed information about an interface. Without this keyword, the command displays brief information about an interface.

statistics: Displays IS-IS interface statistics.

process-id: Displays IS-IS interface information for an IS-IS process specified by its ID in the range of 1 to 65535. Without this argument, the command displays interface information for all IS-IS processes.

standby slot slot-number: Displays backup IS-IS interface information for a card. Without this option, the command displays IS-IS interface information. (In standalone mode.)

standby chassis chassis-number slot slot-number: Displays backup IS-IS interface information for a card on an IRF member device. The chassis-number argument specifies the ID of the IRF member device. The slot-number argument specifies the slot number of the card. Without this option, the command displays IS-IS interface information. (In IRF mode.)

Examples

# Display brief IS-IS interface information.

<Sysname> display isis interface

 

                       Interface information for IS-IS(1)

                       ----------------------------------

 

  Interface:  Vlan-interface2

  Id      IPv4.State      IPv6.State     MTU   Type   DIS

  001         Up             Down        547   L1/L2  Yes/No

# Display detailed IS-IS interface information.

<Sysname> display isis interface verbose

 

                       Interface information for IS-IS(1)

                       ----------------------------------

 

  Interface:  Vlan-interface2

  Id      IPv4.State      IPv6.State     MTU   Type   DIS

  001         Up             Down        547   L1/L2  Yes/No

  SNPA Address                 :  000c-29b2-a5e3

  IP Address                   :  8.8.8.7

  Secondary IP Address(es)     :

  IPv6 Link Local Address      :

  Csnp Timer Value             :  L1    10   L2    10

  Hello Timer Value            :  L1     3   L2    10

  Hello Multiplier Value       :  L1     3   L2     3

  Lsp Timer Value              :  L12   33

  Lsp Transmit-Throttle Count  :  L12    5

  Cost                         :  L1    10   L2    10

  Priority                     :  L1    64   L2    64

  IPv4 BFD                     :  Disabled

  IPv6 BFD                     :  Disabled

Table 50 Command output

Field

Description

Interface

Interface type and number.

Id

Circuit ID.

IPv4.State

IPv4 state.

MTU

Interface MTU.

Type

Interface link adjacency type.

DIS

Whether the interface is elected as the DIS or not.

SNPA Address

Subnet access point address.

IP Address

Primary IP address.

Secondary IP Address(es)

Secondary IP addresses.

Csnp Timer Value

Interval for sending CSNP packets.

Hello Timer Value

Interval for sending Hello packets.

Hello Multiplier Value

Number of invalid Hello packets.

Lsp Timer Value

Minimum interval for sending LSP packets.

Lsp Transmit-Throttle Count

Number of LSP packets sent each time.

Cost

Cost of the interface.

Priority

DIS priority.

IPv4 BFD

Whether BFD for IS-IS is enabled:

·     Disabled.

·     Enabled.

 

# Display IS-IS interface statistics.

<Sysname> display isis interface statistics

 

                  Interface Statistics information for ISIS(1)

                  --------------------------------------------

  Type            IPv4 Up/Down           IPv6 Up/Down

  LAN                   1/0                    0/0

  P2P                   0/0                    0/0

Table 51 Command output

Field

Description

Type

Network type of the interface:

·     LAN for broadcast network.

·     P2P for point-to-point network.

IPv4 UP

Number of IS-IS interfaces in up state.

IPv4 Down

Number of IS-IS interfaces in down state.

 

display isis lsdb

Use display isis lsdb to display IS-IS LSDB information.

Syntax

In standalone mode:

display isis lsdb [ [ level-1 | level-2 ] | local | [ lsp-id lspid | lsp-name lspname ] | verbose ] * [ process-id ] [ standby slot slot-number ]

In IRF mode:

display isis lsdb [ [ level-1 | level-2 ] | local | [ lsp-id lspid | lsp-name lspname ] | verbose ] * [ process-id ] [ standby chassis chassis-number slot slot-number ]

Views

Any view

Predefined user roles

network-admin

network-operator

mdc-admin

mdc-operator

Parameters

level-1: Displays the level-1 LSDB.

level-2: Displays the level-2 LSDB.

local: Displays LSP information generated locally.

lsp-id lspid: Specifies an LSP ID, in the form of sysID. Pseudo ID-fragment num, where sysID represents the originating node or pseudo node, and Pseudo ID is separated by a dot from sysID and by a hyphen from fragment num.

lspname: Specifies the LSP name, in the form of Symbolic name.Pseudo ID-fragment num, where Pseudo ID is separated by a dot from Symbolic name and by a hyphen from fragment num. If the Pseudo ID is 0, specify the LSP name in the form Symbolic name-fragment num.

verbose: Displays LSDB detailed information. Without this keyword, the command displays brief information about LSDB.

process-id: Specifies an IS-IS process by its ID in the range of 1 to 65535 to display the LSDB of the IS-IS process. Without this argument, the command displays LSDBs for all IS-IS processes.

standby slot slot-number: Displays backup IS-IS LSDB information for a card. Without this option, the command displays IS-IS LSDB information. (In standalone mode.)

standby chassis chassis-number slot slot-number: Displays backup IS-IS LSDB information for a card on an IRF member device. The chassis-number argument specifies the ID of the IRF member device. The slot-number argument specifies the slot number of the card. Without this option, the command displays IS-IS LSDB information. (In IRF mode.)

Usage guidelines

If no level is specified, the command displays both Level-1 and Level-2 LSDB information.

Examples

# Display brief Level-1 LSDB information.

<Sysname> display isis lsdb level-1

 

                        Database information for ISIS(1)

                        --------------------------------

 

                          Level-1 Link State Database

                          ---------------------------

 

LSPID                 Seq Num      Checksum      Holdtime      Length  ATT/P/OL

-------------------------------------------------------------------------------

5555.1111.1111.00-00  0x00000006   0x8519        1150          75      0/0/0

5555.1111.1111.00-01  0x00000001   0x4995        1139          41      0/0/0

7777.8888.1111.00-00* 0x00000020   0xceeb        1159          68      0/0/0

7777.8888.1111.01-00* 0x00000004   0xb4a4        1150          55      0/0/0

 

    *-Self LSP, +-Self LSP(Extended), ATT-Attached, P-Partition, OL-Overload

# Display detailed Level-1 LSDB information.

<Sysname> display isis lsdb level-1 verbose

 

                        Database information for ISIS(1)

                        --------------------------------

 

                          Level-1 Link State Database

                          ---------------------------

 

LSPID                 Seq Num      Checksum      Holdtime      Length  ATT/P/OL

-------------------------------------------------------------------------------

5555.1111.1111.00-00  0x00000006   0x8519        1124          75      0/0/0

 Source       5555.1111.1111.00

 NLPID        IPv4

 Area address 18

 IPv4 address 8.8.8.5

 NBR  ID

         5555.5555.5555.00                COST: 0

 NBR  ID

         7777.8888.1111.01                COST: 10

 

5555.1111.1111.00-01  0x00000001   0x4995        1113          41      0/0/0

 Source       5555.1111.1111.00

 IP-Internal

         8.8.8.0         255.255.255.0    COST: 10

 

7777.8888.1111.00-00* 0x00000020   0xceeb        1133          68      0/0/0

 Source       7777.8888.1111.00

 NLPID        IPv4

 Area address 18

 IPv4 address 8.8.8.7

 NBR  ID

         7777.8888.1111.01                COST: 10

 IP-Internal

         8.8.8.0         255.255.255.0    COST: 10

 

7777.8888.1111.01-00* 0x00000004   0xb4a4        1124          55      0/0/0

 Source       7777.8888.1111.01

 NLPID        IPv4

 NBR  ID

         5555.1111.1111.00                COST: 0

 NBR  ID

         7777.8888.1111.00                COST: 0

 

 

    *-Self LSP, +-Self LSP(Extended), ATT-Attached, P-Partition, OL-Overload

Table 52 Command output

Field

Description

LSPID

LSP ID.

Seq Num

LSP sequence number.

Checksum

LSP checksum.

Holdtime

LSP lifetime, which decreases as time elapses.

Length

LSP length.

ATT/P/OL

·     ATT—Attach bit.

·     P—Partition bit.

·     OL—Overload bit.

1 means the LSP bit is set and 0 means the LSP bit is not set.

Source

System ID of the originating router.

NLPID

Network layer protocol the originating router runs.

Area address

Area address of the originating router.

IPv4 address

IP address of the originating router's IS-IS interface.

NBR ID

Neighbor ID of the originating router.

IP-Internal

Internal IP address and mask of the originating router.

IP-External

External IP address and mask of the originating router.

IP-Extended

Extended IP address and mask of the originating router.

COST

Cost.

Auth

Authentication information of the originating router.

 

display isis name-table

Use display isis name-table to display the host name to system ID mapping table.

Syntax

display isis name-table [ process-id ]

Views

Any view

Predefined user roles

network-admin

network-operator

mdc-admin

mdc-operator

Parameters

process-id: Displays the host name to system ID mapping table for an IS-IS process specified by its ID in the range of 1 to 65535. Without this argument, the command displays the host name to system ID mapping table for all IS-IS processes.

Examples

# Configure a name RUTA for the local IS system.

<Sysname> system-view

[Sysname] isis 1

[Sysname-isis-1] is-name RUTA

# Map the host name RUTB to the system ID 0000.0000.0041 of a remote IS.

[Sysname-isis-1] is-name map 0000.0000.0041 RUTB

# Display the IS-IS host name to system ID mapping table.

[Sysname-isis-1] display isis name-table

              Name table information for ISIS(1)

---------------------------------------------------------------

 System ID            Hostname                            Type

6789.0000.0001       RUTA                                DYNAMIC

0000.0000.0041       RUTB                                STATIC

Table 53 Command output

Field

Description

System ID

System ID.

Hostname

Host name.

Type

Mapping type:

·     Static.

·     Dynamic.

 

display isis peer

Use display isis peer to display IS-IS neighbor information.

Syntax

In standalone mode:

display isis peer [ statistics | verbose ] [ process-id ] [ standby slot slot-number ]

In IRF mode:

display isis peer [ statistics | verbose ] [ process-id ] [ standby chassis chassis-number slot slot-number ]

Views

Any view

Predefined user roles

network-admin

network-operator

mdc-admin

mdc-operator

Parameters

statistics: Displays IS-IS neighbor statistics.

verbose: Displays detailed IS-IS neighbor information. Without this keyword, the command displays brief IS-IS neighbor information.

process-id: Displays IS-IS neighbor information for an IS-IS process specified by its ID in the range of 1 to 65535. Without this argument, the command displays neighbor information for all IS-IS processes.

standby slot slot-number: Displays backup IS-IS neighbor information for a card. Without this option, the command displays IS-IS neighbor information. (In standalone mode.)

standby chassis chassis-number slot slot-number: Displays backup IS-IS neighbor information for a card on an IRF member device. The chassis-number argument specifies the ID of the IRF member device. The slot-number argument specifies the slot number of the card. Without this option, the command displays IS-IS neighbor information. (In IRF mode.)

Examples

# Display brief IS-IS neighbor information.

<Sysname> display isis peer

 

                         Peer information for IS-IS(1)

                         -----------------------------

 

 System Id: 0000.0000.0001

 Interface: Vlan2                   Circuit Id:  ---

 State: Up     HoldTime:  27s       Type: L1(L1L2)     PRI: 64

 

 System Id: 0000.0000.0001

 Interface: Vlan2                   Circuit Id:  ---

 State: Up     HoldTime:  27s       Type: L2(L1L2)     PRI: 64

# Display detailed IS-IS neighbor information.

<Sysname> display isis peer verbose

 

                         Peer information for ISIS(1)

                         ----------------------------

 

 System ID: 0000.1111.2222

 Interface: Vlan2                   Circuit Id:  0000.1111.2222.01

 State: Up     Holdtime:   6s       Type: L1(L1L2)     PRI: 64

 Area address(es): 49

 Peer IP address(es): 12.0.0.2

 Peer local circuit ID: 1

 Peer circuit SNPA address: 000c-293b-c4be

 Uptime: 00:05:07

 Adj protocol:  IPv4

 Graceful Restart capable

   Restarting signal: No

   Suppress adjacency advertisement: No

 

 System ID: 0000.1111.2222

 Interface: Vlan2                   Circuit Id:  0000.1111.2222.01

 State: Up     Holdtime:  7s        Type: L2(L1L2)     PRI: 64

 Area address(es): 49

 Peer IP address(es): 12.0.0.2

 Peer local circuit ID: 1

 Peer circuit SNPA address: 000c-293b-c4be

 Uptime: 00:05:07

 Adj protocol:  IPv4

 Graceful Restart capable

   Restarting signal: No

   Suppress adjacency advertisement: No

Table 54 Command output

Field

Description

System Id

System ID of the neighbor.

Interface

Interface connecting to the neighbor.

Circuit Id

Circuit ID.

State

Circuit state.

HoldTime

Within the holdtime, if no hellos are received from the neighbor, the neighbor is considered down. If a hello is received, the holdtime is reset to the initial value.

Type

Circuit type:

·     L1—Means the circuit type is Level-1 and the neighbor is a Level-1 router.

·     L2—Means the circuit type is Level-2 and the neighbor is a Level-2 router.

·     L1(L1L2)—Means the circuit type is Level-1 and the neighbor is a Level-1-2 router.

·     L2(L1L2)—Means the circuit type is Level-2 and the neighbor is a Level-1-2 router.

PRI

DIS priority of the neighbor.

Area Address(es)

Area address of the neighbor.

Peer IP Address(es)

IP address of the neighbor.

Uptime

Time elapsed since the neighbor relationship was formed.

Adj Protocol

Adjacency protocol.

Peer local circuit ID

Circuit ID of the neighbor.

Peer circuit SNPA address

SNPA address of the neighbor.

Graceful Restart capable

The neighbor has the GR helper capability.

Restarting signal

RR flag.

Suppress adjacency advertisement

SA flag.

 

# Display IS-IS neighbor statistics.

<Sysname> display isis peer statistics

 

                    Peer Statistics information for ISIS(1)

                    ---------------------------------------

  Type              IPv4 Up/Init              IPv6 Up/Init

  LAN Level-1             1/0                       0/0

  LAN Level-2             1/0                       0/0

  P2P                     0/0                       0/0

Table 55 Command output

Field

Description

Type

Neighbor type:

·     LAN Level-1Number of Level-1 neighbors whose network type is broadcast.

·     LAN Level-2Number of Level-2 neighbors whose network type is broadcast.

·     P2PNumber of neighbors whose network type is P2P.

IPv4 Up

Number of IPv4 neighbors in up state.

IPv4 Init

Number of IPv4 neighbors in init state.

 

display isis redistribute

Use display isis redistribute to display the redistributed IS-IS routing information.

Syntax

display isis redistribute [ ipv4 [ ip-address mask-length ] ] [ level-1 | level-2 ] [ process-id ]

Views

Any view

Predefined user roles

network-admin

network-operator

mdc-admin

mdc-operator

Parameters

ipv4: Displays the redistributed IPv4 routing information (the default).

ip-address mask-length: Specifies the destination IP address and mask length.

process-id: Specifies the IS-IS process by its ID in the range of 1 to 65535.

level-1: Displays the IS-IS Level-1 routing information.

level-2: Displays the IS-IS Level-2 routing information.

Usage guidelines

If no IS-IS level is specified, this command displays both Level-1 and Level-2 routing information.

Examples

# Display redistributed IPv4 routing information.

<Sysname> display isis redistribute 1

 

                         Route information for IS-IS(1)

                         ------------------------------

 

                        Level-1 IPv4 Redistribute Table

                        --------------------------------

 Type IPv4 Destination     IntCost    ExtCost    Tag        State

--------------------------------------------------------------------------------

 D    192.168.30.0/24      0          0                     Active

 D    11.11.11.11/32       0          0

 D    10.10.10.0/24        0          0

Table 56 Command output

Field

Description

Route information for IS-IS(1)

IS-IS process of the redistributed routing information.

Level-1 IPv4 Redistribute Table

Redistributed IPv4 routing information of IS-IS Level-1.

Level-2 IPv4 Redistribute Table

Redistributed IPv4 routing information of IS-IS Level-2.

Type

Redistributed route type:

·     Direct.

·     IS-IS.

·     Static.

·     OSPF.

·     BGP.

·     RIP.

IPV4 Destination

IPv4 destination address.

IntCost

Internal cost of the route.

ExtCost

External cost of the route.

Tag

Tag value.

State

Indicates whether the route is valid.

 

display isis route

Use display isis route to display IS-IS IPv4 routing information.

Syntax

display isis route [ ipv4 [ ip-address mask-length ] ] [ [ level-1 | level-2 ] | verbose ] * [ process-id ]

Views

Any view

Predefined user roles

network-admin

network-operator

mdc-admin

mdc-operator

Parameters

ipv4: Displays IS-IS IPv4 routing information (the default).

ip-address mask-length: Displays IS-IS IPv4 routing information for the specified IP address. The mask-length argument is in the range of 0 to 32.

verbose: Displays detailed IS-IS IPv4 routing information. Without this keyword, the command displays brief IS-IS IPv4 routing information

process-id: Displays IS-IS IPv4 routing information for an IS-IS process specified by its ID in the range of 1 to 65535.

level-1: Displays Level-1 IS-IS routes.

level-2: Displays Level-2 IS-IS routes.

Usage guidelines

If no level is specified, this command displays both Level-1 and Level-2 routing information.

If no IS-IS process ID is specified, this command displays routing information for all IS-IS process IDs.

Examples

# Display brief IS-IS IPv4 routing information.

<Sysname> display isis route

 

                         Route information for ISIS(1)

                         -----------------------------

 

                         Level-1 IPv4 Forwarding Table

                         -----------------------------

 

 IPv4 Destination     IntCost    ExtCost ExitInterface   NextHop         Flags

-------------------------------------------------------------------------------

 8.8.8.0/24           10         NULL    Vlan2           Direct          D/L/-

 9.9.9.0/24           20         NULL    Vlan2           8.8.8.5         R/L/-

 

      Flags: D-Direct, R-Added to Rib, L-Advertised in LSPs, U-Up/Down Bit Set

 

                         Level-2 IPv4 Forwarding Table

                         -----------------------------

 

 IPv4 Destination     IntCost    ExtCost ExitInterface   NextHop         Flags

-------------------------------------------------------------------------------

 8.8.8.0/24           10         NULL    Vlan2           Direct          D/L/-

 9.9.9.0/24           20         NULL

 

      Flags: D-Direct, R-Added to Rib, L-Advertised in LSPs, U-Up/Down Bit Set

Table 57 Command output

Field

Description

Route information for ISIS(1)

Route information for IS-IS process 1.

ISIS(1) IPv4 Level-1 Forwarding Table

IS-IS IPv4 routing information for Level-1.

ISIS(1) IPv4 Level-2 Forwarding Table

IS-IS IPv4 routing information for Level-2.

IPv4 Destination

IPv4 destination address.

IntCost

Internal cost.

ExtCost

External cost.

ExitInterface

Exit interface.

NextHop

Next hop.

Flags

Routing state flag:

·     D—Direct route.

·     R—The route has been added into the routing table.

·     L—The route has been advertised in an LSP.

·     U—Penetration flag. Setting it to UP can prevent an LSP sent from L2 to L1 from being sent back to L2.

 

# Display detailed IS-IS IPv4 routing information.

<Sysname> display isis route verbose

 

                         Route information for ISIS(1)

                         -----------------------------

 

                         Level-1 IPv4 Forwarding Table

                         -----------------------------

 

 IPV4 Dest : 8.8.8.0/24          Int. Cost : 10               Ext. Cost : NULL

 Admin Tag : -                   Src Count : 2                Flag      : D/L/-

 NextHop   :                     Interface :                  ExitIndex :

    Direct                             Vlan2                     0x00000000

 

 IPV4 Dest : 9.9.9.0/24          Int. Cost : 20               Ext. Cost : NULL

 Admin Tag : -                   Src Count : 1                Flag      : R/L/-

 NextHop   :                     Interface :                  ExitIndex :

    8.8.8.5                            Vlan2                     0x00000003

 

      Flags: D-Direct, R-Added to Rib, L-Advertised in LSPs, U-Up/Down Bit Set

 

                         Level-2 IPv4 Forwarding Table

                         -----------------------------

 

 IPV4 Dest : 8.8.8.0/24          Int. Cost : 10               Ext. Cost : NULL

 Admin Tag : -                   Src Count : 2                Flag      : D/L/-

 NextHop   :                     Interface :                  ExitIndex :

    Direct                             Vlan2                     0x00000000

 

 IPV4 Dest : 9.9.9.0/24          Int. Cost : 20               Ext. Cost : NULL

 Admin Tag : -                   Src Count : 1                Flag      : -/-/-

 

      Flags: D-Direct, R-Added to Rib, L-Advertised in LSPs, U-Up/Down Bit Set

Table 58 Command output

Field

Description

Route information for ISIS(1)

Route information for IS-IS process 1.

ISIS(1) IPv4 Level-1 Forwarding Table

IS-IS IPv4 routing information for Level-1.

ISIS(1) IPv4 Level-2 Forwarding Table

IS-IS IPv4 routing information for Level-2.

IPV4 Dest

IPv4 destination.

Int. Cost

Internal cost.

Ext. Cost

External cost.

Admin Tag

Tag.

Src Count

Count of advertising sources.

Flag

Route state flag:

·     RThe route has been installed into the routing table.

·     LThe route has been flooded in an LSP.

·     URoute leaking flag. Setting it to UP can prevent an LSP sent from L2 to L1 from being sent back to L2.

Next Hop

Next hop.

Interface

Output interface.

ExitIndex

Index of the output interface.

 

display isis spf-tree

Use display isis spf-tree to display IS-IS IPv4 topology information.

Syntax

display isis spf-tree [ ipv4 ] [ [ level-1 | level-2 ] | verbose ] * [ process-id ]

Views

Any view

Predefined user roles

network-admin

network-operator

mdc-admin

mdc-operator

Parameters

ipv4: Displays IS-IS IPv4 topology information. Without this keyword, the command displays IS-IS IPv4 topology information.

level-1: Displays Level-1 IS-IS topology information. If no level is specified, the command displays both Level-1 and Level 2 topology information.

level-2: Displays Level-2 IS-IS topology information. If no level is specified, the command displays both Level-1 and Level 2 topology information.

verbose: Displays detailed IS-IS topology information. Without this keyword, the command displays brief topology information.

process-id: Specifies an IS-IS process by its ID in the range of 1 to 65535. Without this argument, the command displays topology information for all IS-IS processes.

Examples

# Display brief IS-IS IPv4 topology information.

<Sysname> display isis spf-tree

 

                        Shortest Path Tree for IS-IS(1)

                        -------------------------------

 

      Flags: S-Node is on SPF tree       T-Node is on tent list

             O-Node is overload          R-Node is directly reachable

             I-Node or Link is isolated  D-Node or Link is to be deleted

             C-Neighbor is child         P-Neighbor is parent

             V-Link is involved          N-Link is a new path

             L-Link is on change list    U-Protocol usage is changed

             H-Nexthop is changed

 

                           Level-1 Shortest Path Tree

                           --------------------------

 

SpfNode            NodeFlag       SpfLink            LinkCost LinkFlag

-------------------------------------------------------------------------------

0000.0000.0032.00  S/-/-/-/-/-

                               -->0000.0000.0032.01  10       -/-/C/-/-/-/-/-/-

                               -->0000.0000.0064.00  10       -/-/C/-/-/-/-/-/-

0000.0000.0032.01  S/-/-/R/-/-

                               -->0000.0000.0064.00  0        -/-/C/-/-/-/-/-/-

                               -->0000.0000.0032.00  0        -/-/-/P/-/-/-/-/-

0000.0000.0064.00  S/-/-/R/-/-

                               -->0000.0000.0032.00  10       -/-/-/P/-/-/-/-/-

                               -->0000.0000.0032.01  10       -/-/-/P/-/-/-/-/-

 

                           Level-2 Shortest Path Tree

                           --------------------------

 

SpfNode            NodeFlag       SpfLink            LinkCost LinkFlag

-------------------------------------------------------------------------------

0000.0000.0032.00  S/-/-/-/-/-

                               -->0000.0000.0032.01  10       -/-/C/-/-/-/-/-/-

                               -->0000.0000.0064.00  10       -/-/C/-/-/-/-/-/-

0000.0000.0032.01  S/-/-/R/-/-

                               -->0000.0000.0064.00  0        -/-/C/-/-/-/-/-/-

                               -->0000.0000.0032.00  0        -/-/-/P/-/-/-/-/-

0000.0000.0064.00  S/-/-/R/-/-

                               -->0000.0000.0032.00  10       -/-/-/P/-/-/-/-/-

                               -->0000.0000.0032.01  10       -/-/-/P/-/-/-/-/-

# Display detailed IS-IS IPv4 topology information.

<Sysname> display isis spf-tree verbose

 

                        Shortest Path Tree for IS-IS(1)

                        -------------------------------

 

      Flags: S-Node is on SPF tree       T-Node is on tent list

             O-Node is overload          R-Node is directly reachable

             I-Node or Link is isolated  D-Node or Link is to be deleted

             C-Neighbor is child         P-Neighbor is parent

             V-Link is involved          N-Link is a new path

             L-Link is on change list    U-Protocol usage is changed

             H-Nexthop is changed

 

                           Level-1 Shortest Path Tree

                           --------------------------

 

 SpfNode   : 0000.0000.0032.00

 Distance  : 0

 NodeFlag  : S/-/-/-/-/-

 NextHopCnt: 0

 SpfLinkCnt: 2

 -->0000.0000.0032.01

    LinkCost   : 10

    LinkNewCost: 10

    LinkFlag   : -/-/C/-/-/-/-/-/-

    LinkSrcCnt : 1

        Type: Adjacent       Interface: N/A

        Cost: 10             Nexthop  : N/A

 -->0000.0000.0064.00

    LinkCost   : 10

    LinkNewCost: 10

    LinkFlag   : -/-/C/-/-/-/-/-/-

    LinkSrcCnt : 1

        Type: Adjacent       Interface: Tun1

        Cost: 10             Nexthop  : 20.20.20.64

 

 SpfNode   : 0000.0000.0032.01

 Distance  : 10

 NodeFlag  : S/-/-/R/-/-

 NextHopCnt: 0

 SpfLinkCnt: 2

 -->0000.0000.0064.00

    LinkCost   : 0

    LinkNewCost: 0

    LinkFlag   : -/-/C/-/-/-/-/-/-

    LinkSrcCnt : 1

        Type: Adjacent       Interface: Vlan2

        Cost: 0              Nexthop  : 10.10.10.64

 -->0000.0000.0032.00

    LinkCost   : 0

    LinkNewCost: 0

    LinkFlag   : -/-/-/P/-/-/-/-/-

    LinkSrcCnt : 1

        Type: Adjacent       Interface: N/A

        Cost: 0              Nexthop  : N/A

 

 SpfNode   : 0000.0000.0064.00

 Distance  : 10

 NodeFlag  : S/-/-/R/-/-

 NextHopCnt: 2

     Neighbor  : 0000.0000.0064.00        Interface  : Vlan2

     NextHop   : 10.10.10.64

     BkNeighbor: N/A                      BkInterface: N/A

     BkNextHop : N/A

     Neighbor  : 0000.0000.0064.00        Interface  : Tun1

     NextHop   : 20.20.20.64

     BkNeighbor: N/A                      BkInterface: N/A

     BkNextHop : N/A

 SpfLinkCnt: 2

 -->0000.0000.0032.00

    LinkCost   : 10

    LinkNewCost: 10

    LinkFlag   : -/-/-/P/-/-/-/-/-

    LinkSrcCnt : 1

        Type: Remote         Interface: N/A

        Cost: 10             Nexthop  : N/A

 -->0000.0000.0032.01

    LinkCost   : 10

    LinkNewCost: 10

    LinkFlag   : -/-/-/P/-/-/-/-/-

    LinkSrcCnt : 1

        Type: Remote         Interface: N/A

        Cost: 10             Nexthop  : N/A

 

                           Level-2 Shortest Path Tree

                           --------------------------

 

 SpfNode   : 0000.0000.0032.00

 Distance  : 0

 NodeFlag  : S/-/-/-/-/-

 NextHopCnt: 0

 SpfLinkCnt: 2

 -->0000.0000.0032.01

    LinkCost   : 10

    LinkNewCost: 10

    LinkFlag   : -/-/C/-/-/-/-/-/-

    LinkSrcCnt : 1

        Type: Adjacent       Interface: N/A

        Cost: 10             Nexthop  : N/A

 -->0000.0000.0064.00

    LinkCost   : 10

    LinkNewCost: 10

    LinkFlag   : -/-/C/-/-/-/-/-/-

    LinkSrcCnt : 1

        Type: Adjacent       Interface: Tun1

        Cost: 10             Nexthop  : 20.20.20.64

 

 SpfNode   : 0000.0000.0032.01

 Distance  : 10

 NodeFlag  : S/-/-/R/-/-

 NextHopCnt: 0

 SpfLinkCnt: 2

 -->0000.0000.0064.00

    LinkCost   : 0

    LinkNewCost: 0

    LinkFlag   : -/-/C/-/-/-/-/-/-

    LinkSrcCnt : 1

        Type: Adjacent       Interface: Vlan2

        Cost: 0              Nexthop  : 10.10.10.64

 -->0000.0000.0032.00

    LinkCost   : 0

    LinkNewCost: 0

    LinkFlag   : -/-/-/P/-/-/-/-/-

    LinkSrcCnt : 1

        Type: Adjacent       Interface: N/A

        Cost: 0              Nexthop  : N/A

 

 SpfNode   : 0000.0000.0064.00

 Distance  : 10

 NodeFlag  : S/-/-/R/-/-

 NextHopCnt: 2

     Neighbor  : 0000.0000.0064.00        Interface  : Vlan2

     NextHop   : 10.10.10.64

     BkNeighbor: N/A                      BkInterface: N/A

     BkNextHop : N/A

     Neighbor  : 0000.0000.0064.00        Interface  : Tun1

     NextHop   : 20.20.20.64

     BkNeighbor: N/A                      BkInterface: N/A

     BkNextHop : N/A

 SpfLinkCnt: 2

 -->0000.0000.0032.00

    LinkCost   : 10

    LinkNewCost: 10

    LinkFlag   : -/-/-/P/-/-/-/-/-

    LinkSrcCnt : 1

        Type: Remote         Interface: N/A

        Cost: 10             Nexthop  : N/A

 -->0000.0000.0032.01

    LinkCost   : 10

    LinkNewCost: 10

    LinkFlag   : -/-/-/P/-/-/-/-/-

    LinkSrcCnt : 1

        Type: Remote         Interface: N/A

        Cost: 10             Nexthop  : N/A

Table 59 Command output

Field

Description

SpfNode

ID of the topology node.

Distance

Shortest distance from the root node to the local node.

NodeFlag

Node flag:

·     S—The node is on the SPF tree.

·     T—The node is on the tent list.

·     O—The node is overloaded.

·     R—The node is directly connected.

·     I—The node is isolated.

·     D—The node is to be deleted.

NextHopCnt

Next hop count.

NextHop

Primary next hop of the node or the link advertising source.

Interface

Primary output interface of the node or the link advertising source.

BkNextHop

Backup next hop.

BkInterface

Backup output interface.

Neighbor

ID of the primary next hop neighbor.

BkNeighbor

ID of the backup next hop neighbor.

SpfLink

Topology link.

SpfLinkCnt

Number of topology links.

LinkCost

Link cost.

LinkNewCost

New link cost.

LinkFlag

Link flag:

·     IThe link is isolated.

·     D—The link is to be deleted.

·     C—The neighbor is a child node.

·     PThe neighbor is the parent node.

·     VThe link is involved.

·     NThe link is a new path.

·     LThe link is on the change list.

·     UThe protocol usage of the link is changed.

·     HThe next hop of the link is changed.

LinkSrcCnt

Number of link advertising sources.

Type

Type of the link advertising source:

·     AdjacentThe link advertising source is a local neighbor.

·     RemoteThe link advertising source is advertised by a remote node in an LSP.

Cost

Cost of the link advertising source.

 

display isis statistics

Use display isis statistics to display IS-IS statistics.

Syntax

display isis statistics [ level-1 | level-1-2 | level-2 ] [ process-id ]

Views

Any view

Predefined user roles

network-admin

network-operator

mdc-admin

mdc-operator

Parameters

level-1: Displays IS-IS Level-1 statistics.

level-1-2: Displays IS-IS Level-1-2 statistics.

level-2: Displays IS-IS Level-2 statistics.

process-id: Displays statistics for an IS-IS process specified by its ID in the range of 1 to 65535.

Usage guidelines

If no level is specified, this command displays both Level-1 and Level-2 routing information.

If no IS-IS process ID is specified, this command displays the statistics for all IS-IS processes.

Examples

# Display IS-IS statistics.

<Sysname> display isis statistics

 

                       Statistics information for ISIS(1)

                       ----------------------------------

 

                               Level-1 Statistics

                               ------------------

 

MTR(Basic-V4)

 

Learnt routes information:

         Total IPv4 Learnt Routes in IPv4 Routing Table: 1

         Total IPv6 Learnt Routes in IPv6 Routing Table: 0

 

Imported routes information:

         IPv4 Imported Routes:

                         Static: 0       Direct: 0

                         ISIS:   0       BGP:    0

                         RIP:    0       OSPF:   0

                         Total Number:   0

         IPv6 Imported Routes:

                         Static: 0       Direct: 0

                         ISISv6: 0       BGP4+:  0

                         RIPng:  0       OSPFv3: 0

                         Total Number:   0

 

Lsp information:

                  LSP Source ID:          No. of used LSPs

                  7777.8888.1111                  001

 

                               Level-2 Statistics

                               ------------------

 

MTR(Basic-V4)

 

Learnt routes information:

         Total IPv4 Learnt Routes in IPv4 Routing Table: 0

         Total IPv6 Learnt Routes in IPv6 Routing Table: 0

 

Imported routes information:

         IPv4 Imported Routes:

                         Static: 0       Direct: 0

                         ISIS:   0       BGP:    0

                         RIP:    0       OSPF:   0

                         Total Number:   0

         IPv6 Imported Routes:

                         Static: 0       Direct: 0

                         ISISv6: 0       BGP4+:  0

                         RIPng:  0       OSPFv3: 0

                         Total Number:   0

 

Lsp information:

                  LSP Source ID:          No. of used LSPs

                  7777.8888.1111                  001

Table 60 Command output

Field

Description

Statistics information for ISIS(processid)

Statistics for the IS-IS process.

Level-1 Statistics

Level-1 statistics.

Level-2 Statistics

Level-2 statistics.

Learnt routes information

Number of learned IPv4 routes.

Number of learned IPv6 routes.

Imported routes information

IPv4 Imported RoutesNumbers of different types of redistributed IPv4 routes.

Lsp information

LSP information:

·     LSP Source IDID of the source system.

·     No. of used LSPsNumber of used LSPs.

 

display osi

Use display osi to display OSI connection information, including the socket status, options, input interfaces, and matched multicast MAC addresses.

Syntax

In standalone mode:

display osi [ slot slot-number ]

In IRF mode:

display osi [ chassis chassis-number slot slot-number ]

Views

Any view

Predefined user roles

network-admin

network-operator

mdc-admin

mdc-operator

Parameters

slot slot-number: Specifies a card by its slot number. Without this option, the command displays OSI connection information about all cards. (In standalone mode.)

chassis chassis-number slot slot-number: Specifies a card on an IRF member device. The chassis-number argument specifies the ID of the IRF member device. The slot-number argument specifies the slot number of the card. Without these two options, the command displays OSI connection information about all cards on all IRF member devices. (In IRF mode.)

Examples

# Display OSI connection information.

<Sysname> display osi

Total OSI socket number: 1

 

 Chassis: 1

 Slot: 1

 Creator: IS-IS[1007]

 State: N/A

 Options: SO_FILTER

 Error: 0

 Receiving buffer(cc/hiwat/lowat/state): 0 / 41600 / 1 / N/A

 Sending buffer(cc/hiwat/lowat/state): 0 / 9216 / 512 / N/A

 Type: 2

 Enabled interfaces:

  Vlan-interface1

   MAC address: 0100-1111-1111 0100-2222-2222

  Vlan-interface2

   MAC address: 0100-1111-1111 0100-2222-2222 0100-3333-3333

Table 61 Command output

Field

Description

Total OSI socket number

Total number of OSI sockets.

Chassis

ID of the IRF member device.

Slot

Slot number of the card.

Creator

Name of the socket creator. The process ID of the creator is displayed in the square brackets.

State

This field always displays N/A.

Options

Socket options:

·     SO_FILTERFilter option is configured.

·     N/ANo option is configured.

Error

Number of errors that affect the socket session.

Receiving buffer(cc/hiwat/lowat/state)

Receiving buffer information, including the current used space, maximum space, minimum space, and status.

Sending buffer(cc/hiwat/lowat/state)

Sending buffer information, including the current used space, maximum space, minimum space, and status.

Type

Type 2 socket, corresponding to unreliable connectionless-oriented transport layer protocols.

Enabled interfaces

Input interfaces and matched multicast MAC addresses. Only packets received from Ethernet link-layer interfaces need to match the multicast MAC addresses.

 

display osi statistics

Use display osi statistics to display OSI packet statistics, including received packets, relayed packets, discarded packets, and sent packets.

Syntax

In standalone mode:

display osi statistics [ slot slot-number ]

In IRF mode:

display osi statistics [ chassis chassis-number slot slot-number ]

Views

Any view

Predefined user roles

network-admin

network-operator

mdc-admin

mdc-operator

Parameters

slot slot-number: Specifies a card by its slot number. Without this option, the command displays OSI packet statistics for all cards. (In standalone mode.)

chassis chassis-number slot slot-number: Specifies a card on an IRF member device. The chassis-number argument specifies the ID of the IRF member device. The slot-number argument specifies the slot number of the card. Without these two options, the command displays OSI packet statistics for all cards on all IRF member devices. (In IRF mode.)

Examples

# Display OSI packet statistics.

<Sysname> display osi statistics

Received packets:

     Total: 35

     Relay received: 35

     Relay forwarded: 35

     Invalid service slot: 0

     No matched socket: 0

     Not delivered, input socket full: 0

Sent packets:

     Total: 19

     Relay forwarded: 19

     Relay received: 19

     Failed: 0

Table 62 Command output

Field

Description

Received packets

Total

Total number of received link layer packets.

Relay received

Number of inbound packets on LPUs relayed from other cards. This count is not included in the total count of received packets.

Relay forwarded

Number of inbound packets relayed to LPUs.

Invalid service slot

Number of discarded packets due to unavailable LPUs.

No matched socket

Number of discarded packets due to mismatches in input interfaces, MAC addresses, or connection filter criteria.

Not delivered, input socket full

Number of undelivered packets due to a socket receiving buffer overflow.

Sent packets

Total

Total number of packets that IS-IS sent over OSI connections.

Relay forwarded

Number of outbound packets relayed to the cards that hosts the output interfaces. This count is not included in the total count of sent packets.

Relay received

Number of outbound packets on the cards that hosts the output interfaces. These packets are relayed from other cards.

Failed

Number of packets failed to be sent.

 

Related commands

reset osi statistics

domain-authentication-mode

Use domain-authentication-mode to specify the routing domain authentication mode and a password.

Use undo domain-authentication-mode to restore the default.

Syntax

domain-authentication-mode { md5 | simple } { cipher cipher-string | plain plain-string } [ ip | osi ]

undo domain-authentication-mode

Default

No routing domain authentication or password is configured.

Views

IS-IS view

Predefined user roles

network-admin

mdc-admin

Parameters

md5: Specifies the MD5 authentication mode.

simple: Specifies the simple authentication mode.

cipher: Sets a ciphertext password.

cipher-string: Specifies a ciphertext password of 33 to 53 characters.

plain: Sets a plaintext password.

plain-string: Specifies a plaintext password of 1 to 16 characters.

ip: Checks IP-related fields in LSPs.

osi: Checks OSI-related fields in LSPs.

Usage guidelines

The configured password in the specified mode is inserted into all outgoing Level-2 packets (LSP, CSNP, and PSNP) and is used for authenticating the incoming Level-2 packets.

All the backbone routers must have the same authentication mode and password.

If neither ip nor osi is specified, the OSI-related fields in LSPs are checked.

For security purposes, all passwords, including passwords configured in plain text, are saved in cipher text.

Examples

# Configure the routing domain authentication mode as simple, and set the plaintext password to 123456.

<Sysname> system-view

[Sysname] isis 1

[Sysname-isis-1] domain-authentication-mode plain 123456

Related commands

·     area-authentication-mode

·     isis authentication-mode

fast-reroute

Use fast-reroute to configure IS-IS FRR.

Use undo fast-reroute to restore the default.

Syntax

fast-reroute { auto | route-policy route-policy-name }

undo fast-reroute

Default

IS-IS FRR is disabled.

Views

IS-IS view

Predefined user roles

network-admin

mdc-admin

Parameters

auto: Calculates a backup next hop automatically for all routes.

route-policy route-policy-name: Uses the specified routing policy to designate a backup next hop. The route-policy-name argument is a case-sensitive string of 1 to 63 characters.

Usage guidelines

Do not use FRR and BFD at the same time. Otherwise, FRR might fail to take effect.

Example

# Enable IS-IS FRR to automatically calculate a backup next hop for all routes.

<Sysname> system-view

[Sysname] isis

[Sysname-isis-1] fast-reroute auto

filter-policy export

Use filter-policy export to configure IS-IS to filter redistributed routes.

Use undo filter-policy export to remove the configuration.

Syntax

filter-policy { acl-number | prefix-list prefix-list-name | route-policy route-policy-name } export [ protocol [ process-id ] ]

undo filter-policy export [ protocol [ process-id ] ]

Default

IS-IS does not filter redistributed routes.

Views

IS-IS view

Predefined user roles

network-admin

mdc-admin

Parameters

acl-number: Specifies an ACL by its number in the range of 2000 to 3999 to filter redistributed routes.

prefix-list prefix-list-name: Specifies an IPv4 prefix list by its name, a case-sensitive string of 1 to 63 characters, to filter redistributed routes by destination address.

route-policy route-policy-name: Specifies a routing policy by its name, a case-sensitive string of 1 to 63 characters, to filter redistributed routes.

protocol: Filters routes redistributed from the specified routing protocol, which can be bgp, direct, isis, ospf, rip, or static. If no protocol is specified, the command filters all redistributed routes.

process-id: Specifies a process by its ID in the range of 1 to 65535. This argument is available only when the protocol is isis, ospf, or rip. The default process ID is 1.

Usage guidelines

To use an advanced ACL (with a number from 3000 to 3999) in the command, configure the ACL using one of the following methods:

·     To deny/permit a route with the specified destination, use the rule [ rule-id ] { deny | permit } ip source sour-addr sour-wildcard command.

·     To deny/permit a route with the specified destination and mask, use the rule [ rule-id ] { deny | permit } ip source sour-addr sour-wildcard destination dest-addr dest-wildcard command.

The source keyword specifies the destination address of a route and the destination keyword specifies the subnet mask of the route. The specified subnet mask must be contiguous. Otherwise, the configuration does not take effect.

Examples

# Use ACL 2000 to filter redistributed routes.

<Sysname> system-view

[Sysname] acl number 2000

[Sysname-acl-basic-2000] rule deny source 192.168.10.0 0.0.0.255

[Sysname-acl-basic-2000] quit

[Sysname] isis 1

[Sysname-isis-1] filter-policy 2000 export

# Configure ACL 3000 to permit only route 113.0.0.0/16 to pass. Use ACL 3000 to filter redistributed routes.

<Sysname> system-view

[Sysname] acl number 3000

[Sysname-acl-adv-3000] rule 10 permit ip source 113.0.0.0 0 destination 255.255.0.0 0

[Sysname-acl-adv-3000] rule 100 deny ip

[Sysname-acl-adv-3000] quit

[Sysname] isis 1

[Sysname-isis 1] filter-policy 3000 export

Related commands

display isis route

filter-policy import

Use filter-policy import to configure IS-IS to filter routes calculated using received LSPs.

Use undo filter-policy import to restore the default.

Syntax

filter-policy { acl-number | prefix-list prefix-list-name | route-policy route-policy-name } import

undo filter-policy import

Default

IS-IS does not filter routes calculated using received LSPs.

Views

IS-IS view

Predefined user roles

network-admin

mdc-admin

Parameters

acl-number: Specifies an ACL by its number in the range of 2000 to 3999 to filter routes calculated using received LSPs.

prefix-list prefix-list-name: Specifies an IPv4 prefix list by its name, a case-sensitive string of 1 to 63 characters, to filter routes calculated using received LSPs by destination address.

route-policy route-policy-name: Specifies a routing policy by its name, a case-sensitive string of 1 to 63 characters, to filter received routes.

Usage guidelines

To use an advanced ACL (with a number from 3000 to 3999) in the command, configure the ACL using one of the following methods:

·     To deny/permit a route with the specified destination, use the rule [ rule-id ] { deny | permit } ip source sour-addr sour-wildcard command.

·     To deny/permit a route with the specified destination and mask, use the rule [ rule-id ] { deny | permit } ip source sour-addr sour-wildcard destination dest-addr dest-wildcard command.

The source keyword specifies the destination address of a route and the destination keyword specifies the subnet mask of the route. The subnet mask must be contiguous. Otherwise, the configuration does not take effect.

Examples

# Use ACL 2000 to filter routes calculated using received LSPs.

<Sysname> system-view

[Sysname] acl number 2000

[Sysname-acl-basic-2000] rule deny source 192.168.10.0 0.0.0.255

[Sysname-acl-basic-2000] quit

[Sysname] isis 1

[Sysname-isis-1] filter-policy 2000 import

# Use ACL 3000 to filter routes calculated using received LSPs and install only route 113.0.0.0/16 to the IP routing table.

<Sysname> system-view

[Sysname] acl number 3000

[Sysname-acl-adv-3000] rule 10 permit ip source 113.0.0.0 0 destination 255.255.0.0 0

[Sysname-acl-adv-3000] rule 100 deny ip

[Sysname-acl-adv-3000] quit

[Sysname] isis 1

[Sysname-isis 1] filter-policy 3000 import

Related commands

display ip routing-table

flash-flood

Use flash-flood to enable IS-IS LSP flash flooding.

Use undo flash-flood to disable IS-IS LSP flash flooding.

Syntax

flash-flood [ flood-count flooding-count | max-timer-interval flooding-interval | [ level-1 | level-2 ] ] *

undo flash-flood [ level-1 | level-2 ]

Default

IS-IS LSP flash flooding is disabled.

Views

IS-IS view

Predefined user roles

network-admin

mdc-admin

Parameters

flood-count flooding-count: Specifies the maximum number of LSPs to be flooded before the next SPF calculation, in the range of 1 to 15. The default is 5.

max-timer-interval flooding-interval: Specifies the delay of the flash flooding, in the range of 10 to 50000 milliseconds. The default is 10.

level-1: Enables flash flooding for level-1.

level-2: Enables flash flooding for level-2.

Usage guidelines

If no level is specified, the command enables IS-IS LSP flash flooding for both Level-1 and Level-2.

Examples

# Enable fast flooding and specify the maximum LSPs to be sent as 10 and the delay time as 100 milliseconds.

<Sysname> system-view

[Sysname] isis 1

[Sysname-isis-1] flash-flood flood-count 10 max-timer-interval 100

graceful-restart

Use graceful-restart to enable IS-IS GR.

Use undo graceful-restart to disable IS-IS GR.

Syntax

graceful-restart

undo graceful-restart

Default

IS-IS GR is disabled.

Views

IS-IS view

Predefined user roles

network-admin

mdc-admin

Examples

# Enable GR for IS-IS process 1.

<Sysname> system-view

[Sysname] isis 1

[Sysname-isis-1] graceful-restart

Related commands

graceful-restart suppress-sa

graceful-restart suppress-sa

Use graceful-restart suppress-sa to suppress the Suppress-Advertisement (SA) bit during restart.

Use undo graceful-restart suppress-sa to set the SA bit.

Syntax

graceful-restart suppress-sa

undo graceful-restart suppress-sa

Default

The SA bit is set during restart.

Views

IS-IS view

Predefined user roles

network-admin

mdc-admin

Usage guidelines

Suppressing the SA bit is mainly for avoiding black hole route. If a router starts or reboots without keeping the local forwarding table, sending packets to the router might result in a severe packet loss. To avoid this, you can set the SA bit of the hello packet sent by the GR restarter to 1. Upon receiving such hello packets, the GR helpers will not advertise the GR restarter through LSP.

Examples

# Suppress the SA bit during graceful restart.

<Sysname> system-view

[Sysname] isis 1

[Sysname-isis-1] graceful-restart suppress-sa

Related commands

graceful-restart

graceful-restart t1

Use graceful-restart t1 to configure the T1 timer.

Use undo graceful-restart t1 to restore the default.

Syntax

graceful-restart t1 seconds count count

undo graceful-restart t1

Default

The T1 timer is 3 seconds and can expire 10 times.

Views

IS-IS view

Predefined user roles

network-admin

mdc-admin

Parameters

seconds: Specifies the T1 timer in the range of 3 to 10 seconds.

count: Specifies the number of times that the T1 timer can expire, in the range of 1 to 20.

Usage guidelines

The T1 timer specifies the number of times that GR restarter can send a Restart TLV with the RR bit set. After restart, the GR restarter sends a Restart TLV with the RR bit set to its neighbor. If the restarting router receives a Restart TLV with the RA set from its neighbor before the T1 timer expires, the GR process starts. Otherwise, the GR process fails.

Examples

# Configure the T1 timer of IS-IS process 1 as 5 seconds, and the expiration times as 5.

<Sysname> system-view

[Sysname] isis 1

[Sysname-isis-1] graceful-restart t1 5 count 5

Related commands

·     graceful-restart

·     graceful-restart t2

·     graceful-restart t3

graceful-restart t2

Use graceful-restart t2 to configure the T2 timer.

Use undo graceful-restart t2 to restore the default.

Syntax

graceful-restart t2 seconds

undo graceful-restart t2

Default

The T2 timer is 60 seconds.

Views

IS-IS view

Predefined user roles

network-admin

mdc-admin

Parameters

seconds: Specifies the T2 timer in the range of 30 to 65535 seconds.

Usage guidelines

The T2 timer specifies the LSDB synchronization interval. Each LSDB has a T2 timer. The Level-1-2 router has two T2 timers: a Level-1 timer and a Level-2 timer. If the LSDBs have not achieved synchronization before the two timers expire, the GR process fails.

Examples

# Configure the T2 timer of IS-IS process 1 as 50 seconds.

<Sysname> system-view

[Sysname] isis 1

[Sysname-isis-1] graceful-restart t2 50

Related commands

·     graceful-restart

·     graceful-restart t1

·     graceful-restart t3

graceful-restart t3

Use graceful-restart t3 to configure the T3 timer.

Use undo graceful-restart t3 to restore the default.

Syntax

graceful-restart t3 seconds

undo graceful-restart t3

Default

The T3 timer is 300 seconds.

Views

IS-IS view

Predefined user roles

network-admin

mdc-admin

Parameters

seconds: Specifies the T3 timer in the range of 300 to 65535 seconds.

Usage guidelines

The T3 timer specifies the GR interval. The GR interval is set as the holdtime in hello PDUs. Within the interval, the neighbors maintain their adjacency with the GR restarter. If the GR process has not completed within the holdtime, the neighbors tear down the neighbor relationship and the GR process fails.

Examples

# Configure the T3 timer of IS-IS process 1 as 500 seconds.

<Sysname> system-view

[Sysname] isis 1

[Sysname-isis-1] graceful-restart t3 500

Related commands

·     graceful-restart

·     graceful-restart t1

·     graceful-restart t2

import-route

Use import-route to redistribute routes from another routing protocol or another IS-IS process.

Use undo import-route to remove the redistribution.

Syntax

import-route protocol [ process-id | all-processes | allow-ibgp ] [ cost cost | cost-type { external | internal } | [ level-1 | level-1-2 | level-2 ] | route-policy route-policy-name | tag tag ] *

undo import-route protocol [ process-id | all-processes ]

Default

No route redistribution is configured.

Views

IS-IS view

Predefined user roles

network-admin

mdc-admin

Parameters

protocol: Redistributes routes from a routing protocol, which can be BGP, direct, IS-IS, OSPF, RIP, or static.

process-id: Specifies a process by its ID in the range of 1 to 65535. It is available only when the protocol is isis, ospf, or rip.

all-processes: Redistributes routes from all the processes of the specified routing protocol. This keyword takes effect only when the protocol is rip, ospf, or isis.

allow-ibgp: Allows redistribution of IBGP routes. It is available when the protocol is BGP.

cost: Specifies a cost for redistributed routes, which is in the range of 0 to 4261412864.

·     For the styles of narrow, narrow-compatible, and compatible, the cost is in the range of 0 to 63.

·     For the styles of wide and wide-compatible, the cost is in the range of 0 to 4261412864.

cost-type { external | internal }: Specifies the cost type. The internal type indicates internal routes, and the external type indicates external routes. If external is specified, the cost of a redistributed route is added by 64 to make internal routes take priority over external routes. The type is external by default. The keywords are available only when the cost type is narrow, narrow-compatible, or compatible.

level-1: Redistributes routes into the Level-1 routing table.

level-1-2: Redistributes routes into both Level-1 and Level-2 routing tables.

level-2: Redistributes routes into the Level-2 routing table. If no level is specified, the routes are redistributed into the Level-2 routing table by default.

route-policy route-policy-name: Redistributes only routes matching the specified routing policy. The route-policy-name argument is a case-sensitive string of 1 to 63 characters.

tag tag: Specifies a tag value for marking redistributed routes, in the range of 1 to 4294967295.

Usage guidelines

IS-IS takes all the redistributed routes as external routes to destinations outside the IS-IS routing domain.

The effective cost depends on the cost style. For the styles of narrow, narrow-compatible, and compatible, the cost is in the range of 0 to 63. If the cost is more than 63, 63 is used. For the style of wide or wide-compatible, the configured value is the effective value.

This import-route command cannot redistribute default routes. The command redistributes only active routes. To display route state information, use the display ip routing-table protocol command.

The import-route bgp command redistributes only EBGP routes.

The import-route bgp allow-ibgp command redistributes both EBGP and IBGP routes. Because this command might cause routing loops, use it with caution.

The undo import-route protocol all-processes command removes only the configuration made by the import-route protocol all-processes command, instead of the configuration made by the import-route protocol process-id command.

Examples

# Redistribute static routes into IS-IS, and set the cost for redistributed routes to 15.

<Sysname> system-view

[Sysname] isis 1

[Sysname-isis-1] import-route static cost 15

Related commands

import-route limit

import-route isis level-1 into level-2

Use import-route isis level-1 into level-2 to enable route advertisement from Level-1 to Level-2.

Use undo import-route isis level-1 into level-2 to disable route advertisement from Level-1 to Level-2.

Syntax

import-route isis level-1 into level-2 [ filter-policy { acl-number | prefix-list prefix-list-name | route-policy route-policy-name } | tag tag ] *

undo import-route isis level-1 into level-2

Default

Route advertisement from Level-1 to Level-2 is enabled.

Views

IS-IS view

Predefined user roles

network-admin

mdc-admin

Parameters

filter-policy: Specifies a filtering policy.

acl-number: Specifies an ACL by its number in the range of 2000 to 3999 to filter routes from Level-1 to Level-2.

prefix-list prefix-list-name: Specifies an IPv4 prefix list by its name, a case-sensitive string of 1 to 63 characters, to filter routes from Level-1 to Level-2 by destination address.

route-policy route-policy-name: Specifies a routing policy by its name, a case-sensitive string of 1 to 63 characters, to filter routes from Level-1 to Level-2.

tag tag: Specifies a tag for marking redistributed routes, in the range of 1 to 4294967295.

Usage guidelines

If a routing policy is used, the routing policy must be specified in the import-route isis level-1 into level-2 command to filter routes from Level-1 to Level-2. Other routing policies specified for route reception and redistribution do not affect the route leaking.

If a filtering policy is configured, only Level-1 routes not filtered out can be advertised into the Level-2 area.

Examples

# Enable route advertisement from Level-1 to Level-2.

<Sysname> system-view

[Sysname] isis 1

[Sysname-isis-1] import-route isis level-1 into level-2

Related commands

·     import-route

·     import-route isis level-1 into level-2

import-route isis level-2 into level-1

Use import-route isis level-2 into level-1 to enable route advertisement from Level-2 to Level-1.

Use undo import-route isis level-2 into level-1 to disable route advertisement from Level-2 to Level-1.

Syntax

import-route isis level-2 into level-1 [ filter-policy { acl-number | prefix-list prefix-list-name | route-policy route-policy-name } | tag tag ] *

undo import-route isis level-2 into level-1

Default

Route advertisement is not enabled.

Views

IS-IS view

Predefined user roles

network-admin

mdc-admin

Parameters

filter-policy: Specifies a filtering policy.

acl-number: Specifies an ACL by its number in the range of 2000 to 3999 to filter routes from Level-2 to Level-1.

prefix-list prefix-list-name: Specifies an IPv4 prefix list by its name, a case-sensitive string of 1 to 63 characters, to filter routes from Level-2 to Level-1 by destination address.

route-policy route-policy-name: Uses the specified routing policy to filter routes from Level-2 to Level-1. The route-policy-name argument is a case-sensitive string of 1 to 63 characters.

tag tag: Specifies a tag for marking redistributed routes, in the range of 1 to 4294967295.

Usage guidelines

If a routing policy is used, the routing policy must be specified in the import-route isis level-2 into level-1 command to filter routes from Level-2 to Level-1. Other routing policies specified for route reception and redistribution does not affect the route leaking.

If a filtering policy is configured, only Level-2 routes not filtered out can be advertised into the Level-1 area.

Examples

# Enable route advertisement from Level-2 to Level-1.

<Sysname> system-view

[Sysname] isis 1

[Sysname-isis-1] import-route isis level-2 into level-1

Related commands

·     import-route

·     import-route isis level-1 into level-2

import-route limit

Use import-route limit to configure the maximum number of redistributed Level 1/Level 2 IPv4 routes.

Use undo import-route limit to restore the default.

Syntax

import-route limit number

undo import-route limit

Default

The maximum number of redistributed Level 1/Level 2 IPv4 routes is not configured.

Views

IS-IS view

Predefined user roles

network-admin

mdc-admin

Parameters

number: Specifies the maximum number of redistributed Level 1/Level 2 IPv4 routes, in the range of 1 to 1048576.

Examples

# Configure IS-IS process 1 to redistribute up to 1000 Level 1/Level 2 IPv4 routes.

<Sysname> system-view

[Sysname] isis 1

[Sysname-isis-1] import-route limit 1000

Related commands

import-route

isis

Use isis to enable an IS-IS process and enter IS-IS view.

Use undo isis to disable an IS-IS process.

Syntax

isis [ process-id ] [ vpn-instance vpn-instance-name ]

undo isis [ process-id ]

Default

The system does not run any IS-IS process.

Views

System view

Predefined user roles

network-admin

mdc-admin

Parameters

process-id: Specifies an IS-IS process by its ID in the range of 1 to 65535. The default is 1.

vpn-instance vpn-instance-name: Specifies an MPLS L3VPN instance by its name, a case-sensitive string of 1 to 31 characters. If no VPN is specified, the IS-IS process runs on the public network.

Examples

# Enable IS-IS process 1 and specify the system ID as 0000.0000.0002 and area ID as 01.0001.

<Sysname> system-view

[Sysname] isis 1

[Sysname-isis-1] network-entity 01.0001.0000.0000.0002.00

Related commands

·     isis enable

·     network-entity

isis authentication-mode

Use isis authentication-mode to set the IS-IS authentication mode and password for an interface.

Use undo isis authentication-mode to remove the configuration.

Syntax

isis authentication-mode { md5 | simple } { cipher cipher-string | plain plain-string } [ level-1 | level-2 ] [ ip | osi ]

undo isis authentication-mode [ level-1 | level-2 ]

Default

No neighbor relationship authentication is configured.

Views

Interface view

Predefined user roles

network-admin

mdc-admin

Parameters

md5: Specifies the MD5 authentication mode.

simple: Specifies the simple authentication mode.

cipher: Sets a ciphertext password.

cipher-string: Specifies a ciphertext password, a case-sensitive string of 33 to 53 characters.

plain: Sets a plaintext password.

plain-string: Specifies a plaintext password, a case-sensitive string of 1 to 16 characters.

level-1: Configures the password for Level-1.

level-2: Configures the password for Level-2.

ip: Checks IP-related fields in LSPs and SNPs.

osi: Checks OSI-related fields in LSPs and SNPs.

Usage guidelines

The password in the specified mode is inserted into all outbound hello packets and is used for authenticating inbound hello packets. Only if the authentication succeeds can the neighbor relationship be formed.

For two routers to become neighbors, the authentication mode and password at both ends must be identical.

For security purposes, all passwords, including passwords configured in plain text, are saved in cipher text.

If you configure a password without specifying a level, the password applies to both Level-1 and Level-2.

If neither ip nor osi is specified, the OSI-related fields in LSPs are checked.

The level-1 and level-2 keywords are configurable on an interface that has had IS-IS enabled with the isis enable command.

Examples

# On VLAN-interface 10, configure the authentication mode as simple, and set the plaintext password to 123456.

<Sysname> system-view

[Sysname] interface vlan-interface 10

[Sysname-Vlan-interface10] isis authentication-mode simple plain 123456

Related commands

·     area-authentication-mode

·     domain authentication-mode

isis bfd enable

Use isis bfd enable to enable BFD.

Use undo isis bfd enable to disable BFD.

Syntax

isis bfd enable

undo isis bfd enable

Default

IS-IS BFD is disabled.

Views

Interface view

Predefined user roles

network-admin

mdc-admin

Examples

# Enable BFD for IS-IS on VLAN-interface 11.

<Sysname> system-view

[Sysname] interface vlan-interface 11

[Sysname-Vlan-interface11] isis enable

[Sysname-Vlan-interface11] isis bfd enable

isis circuit-level

Use isis circuit-level to set the circuit level for the interface.

Use undo isis circuit-level to restore the default.

Syntax

isis circuit-level [ level-1 | level-1-2 | level-2 ]

undo isis circuit-level

Default

An interface can establish either the Level-1 or Level-2 adjacency.

Views

Interface view

Predefined user roles

network-admin

mdc-admin

Parameters

level-1: Sets the circuit level to Level-1.

level-1-2: Sets the circuit level to Level-1-2.

level-2: Sets the circuit level to Level-2.

Usage guidelines

For a Level-1 (Level-2) router, the circuit level can only be Level-1 (Level-2). For a Level-1-2 router, you must specify a circuit level for a specific interface to form only the specified level neighbor relationship.

Examples

# VLAN-interface 10 is connected to a non-backbone router in the same area. Configure the circuit level of VLAN-interface 10 as Level-1 to prevent sending and receiving Level-2 Hello packets.

<Sysname> system-view

[Sysname] interface vlan-interface 10

[Sysname-Vlan-interface10] isis enable

[Sysname-Vlan-interface10] isis circuit-level level-1

Related commands

is-level

isis circuit-type p2p

Use isis circuit-type p2p to configure the network type of an interface as P2P.

Use undo isis circuit-type to remove the configuration.

Syntax

isis circuit-type p2p

undo isis circuit-type

Default

The network type of an interface depends on the physical media. (The network type of a VLAN interface is broadcast.)

Views

Interface view

Predefined user roles

network-admin

mdc-admin

Usage guidelines

Perform this configuration only for a broadcast network with only two attached routers.

Interfaces with different network types operate differently. For example, broadcast interfaces must elect a DIS and flood CSNP packets to synchronize the LSDBs, and P2P interfaces do not need to elect a DIS, and use a different LSDB synchronization mechanism.

If only two routers exist on a broadcast network, configure the network type of attached interfaces as P2P to avoid DIS election and CSNP flooding, saving network bandwidth and speeding up network convergence.

Examples

# Configure the network type of VLAN-interface 10 as P2P.

<Sysname> system-view

[Sysname] interface vlan-interface 10

[Sysname-Vlan-interface10] isis enable

[Sysname-Vlan-interface10] isis circuit-type p2p

isis cost

Use isis cost to set the IS-IS cost for an interface.

Use undo isis cost to remove the configuration.

Syntax

isis cost value [ level-1 | level-2 ]

undo isis cost [ level-1 | level-2 ]

Default

No IS-IS cost is configured for an interface.

Views

Interface view

Predefined user roles

network-admin

mdc-admin

Parameters

value: Specifies an IS-IS cost in the range of 1 to 16777215.

level-1: Applies the cost to Level-1.

level-2: Applies the cost to Level-2.

Usage guidelines

If neither level-1 nor level-2 is included, the cost applies to both level-1 and level-2.

Examples

# Configure the Level-2 IS-IS cost as 5 for VLAN-interface 10.

<Sysname> system-view

[Sysname] interface vlan-interface 10

[Sysname-Vlan-interface10] isis cost 5 level-2

Related commands

·     auto-cost enable

·     bandwidth-reference

isis dis-name

 

NOTE:

This command does not take effect on a Point-to-Point interface.

 

Use isis dis-name to configure a name for a DIS to represent the pseudo node on a broadcast network.

Use undo isis dis-name to restore the default.

Syntax

isis dis-name symbolic-name

undo isis dis-name

Default

No name is configured for the DIS.

Views

Interface view

Predefined user roles

network-admin

mdc-admin

Parameters

symbolic-name: Specifies a DIS name, a case-insensitive string of 1 to 64 characters.

Usage guidelines

This command takes effect only on routers that have dynamic system ID to host name mapping enabled.

Examples

# Configure the DIS name as LOCALAREA.

<Sysname> system-view

[Sysname] interface vlan-interface 10

[Sysname-Vlan-interface10] isis dis-name LOCALAREA

Related commands

·     display isis name-table

·     is-name

isis dis-priority

Use isis dis-priority to specify a DIS priority at a specified level for an interface.

Use undo isis dis-priority to remove the configuration.

Syntax

isis dis-priority value [ level-1 | level-2 ]

undo isis dis-priority [ level-1 | level-2 ]

Default

The priority of Level-1 and Level-2 is 64.

Views

Interface view

Predefined user roles

network-admin

mdc-admin

Parameters

value: Specifies a DIS priority in the range of 0 to 127.

level-1: Applies the DIS priority to Level-1.

level-2: Applies the DIS priority to Level-2.

Usage guidelines

If neither level-1 nor level-2 is specified, the DIS priority applies to both Level-1 and Level-2.

On an IS-IS broadcast network, a router must be elected as the DIS at each routing level. Specify a DIS priority at a level for an interface. The greater the interface's priority is, the more likelihood it becomes the DIS. If multiple routers in the broadcast network have the same highest DIS priority, the router with the highest Subnetwork Point of Attachment (SNPA) address (SNPA addresses are MAC addresses on a broadcast network) becomes the DIS.

IS-IS has no backup DIS. The router with a priority of 0 can also participate in DIS election.

Examples

# Configure the Level-2 DIS priority as 127 for VLAN-interface 10.

<Sysname> system-view

[Sysname] interface vlan-interface 10

[Sysname-Vlan-interface10] isis dis-priority 127 level-2

isis enable

Use isis enable to enable an IS-IS process on an interface.

Use undo isis enable to disable IS-IS.

Syntax

isis enable [ process-id ]

undo isis enable

Default

No IS-IS process is enabled on an interface.

Views

Interface view

Predefined user roles

network-admin

mdc-admin

Parameters

process-id: Specifies an IS-IS process by its ID in the range of 1 to 65535. The default is 1.

Examples

# Enable IS-IS process 1 globally and enable it on VLAN-interface 10.

<Sysname> system-view

[Sysname] isis 1

[Sysname-isis-1] network-entity 10.0001.1010.1020.1030.00

[Sysname-isis-1] quit

[Sysname] interface vlan-interface 10

[Sysname-Vlan-interface10] isis enable 1

Related commands

·     isis

·     network-entity

isis mib-binding

Use isis mib-binding to bind an IS-IS process to MIB operation.

Use undo  isis mib-binding to restore the default.

Syntax

isis mib-binding process-id

undo isis mib-binding

Default

MIB operation is bound to the IS-IS process with the smallest process ID.

Views

System view

Predefined user roles

network-admin

mdc-admin

Parameters

process-id: Specifies an IS-IS process by its ID in the range of 1 to 65535.

Usage guidelines

If the specified the process ID does not exist, the MIB binding configuration fails.

Deleting an IS-IS process bound to MIB operation deletes the MIB binding configuration. MIB operation is bound to the IS-IS process with the smallest process ID.

Examples

# Bind MIB operation to IS-IS process 100.

<Sysname> system-view

[Sysname] isis mib-binding 100

isis primary-path-detect bfd echo

Use isis primary-path-detect bfd echo to enable BFD single-hop echo detection for IS-IS FRR or IS-IS PIC.

Use undo isis primary-path-detect bfd to restore the default.

Syntax

isis primary-path-detect bfd echo

undo isis primary-path-detect bfd

Default

BFD single-hop echo detection is disabled for IS-IS FRR or IS-IS PIC.

Views

Interface view

Predefined user roles

network-admin

mdc-admin

Usage guidelines

This command enables IS-IS FRR or IS-IS PIC to use BFD single-hop echo detection to detect primary link failures.

Examples

# Enable BFD single-hop echo detection for IS-IS FRR on interface VLAN-interface 10.

<Sysname> system-view

[Sysname] isis 1

[Sysname-isis-1] address-family ipv4

[Sysname-isis-1-ipv4] fast-reroute lfa

[Sysname-isis-1-ipv4] quit

[Sysname-isis-1] quit

[Sysname] bfd echo-source-ip 1.1.1.1

[Sysname] interface vlan-interface 10

[Sysname-Vlan-interface10] isis primary-path-detect bfd echo

isis silent

Use isis silent to disable the interface from sending and receiving IS-IS packets.

Use undo isis silent to restore the default.

Syntax

isis silent

undo isis silent

Default

An interface is not disabled from sending and receiving IS-IS packets.

Views

Interface view

Predefined user roles

network-admin

mdc-admin

Usage guidelines

The feature is not supported on the loopback interface.

Examples

# Disable VLAN-interface 10 from sending and receiving IS-IS packets.

<Sysname> system-view

[Sysname] interface vlan-interface 10

[Sysname-Vlan-interface10] isis silent

isis small-hello

 

NOTE:

This command is not available in loopback interface view.

 

Use isis small-hello to configure the interface to send small hello packets without CLVs.

Use undo isis small-hello to restore the default.

Syntax

isis small-hello

undo isis small-hello

Default

An interface sends standard hello packets.

Views

Interface view

Predefined user roles

network-admin

mdc-admin

Examples

# Configure VLAN-interface 10 to send small Hello packets.

<Sysname> system-view

[Sysname] interface vlan-interface 10

[Sysname-Vlan-interface10] isis small-hello

isis timer csnp

Use isis timer csnp to specify on the DIS of a broadcast network the interval for sending CSNP packets.

Use undo isis timer csnp to remove the configuration.

Syntax

isis timer csnp seconds [ level-1 | level-2 ]

undo isis timer csnp [ level-1 | level-2 ]

Default

The default CSNP interval is 10 seconds.

Views

Interface view

Predefined user roles

network-admin

mdc-admin

Parameters

seconds: Specifies on the DIS of a broadcast network the interval in seconds for sending CSNP packets. The value range is 1 to 600.

level-1: Applies the interval to Level-1.

level-2: Applies the interval to Level-2.

Usage guidelines

If no level is specified, the CSNP interval applies to both Level-1 and Level-2.

This command only applies to the DIS of a broadcast network, which sends CSNP packets periodically for LSDB synchronization.

Examples

# Configure Level-2 CSNP packets to be sent every 15 seconds over VLAN-interface 10.

<Sysname> system-view

[Sysname] interface vlan-interface 10

[Sysname-Vlan-interface10] isis timer csnp 15 level-2

isis timer hello

Use isis timer hello to specify the interval for sending hello packets.

Use undo isis timer hello to remove the configuration.

Syntax

isis timer hello seconds [ level-1 | level-2 ]

undo isis timer hello [ level-1 | level-2 ]

Default

The default hello interval is 10 seconds.

Views

Interface view

Predefined user roles

network-admin

mdc-admin

Parameters

seconds: Specifies the interval in seconds for sending hello packets, in the range of 3 to 255.

level-1: Specifies the interval for sending Level-1 hello packets.

level-2: Specifies the interval for sending Level-2 hello packets.

Usage guidelines

If a neighbor does not receive any hello packets from the router within the advertised hold time, it considers the router down and recalculates the routes. The hold time is the hello multiplier multiplied by the hello interval.

Level-1 and Level-2 hello packets are sent independently on a broadcast network, so you need to specify an interval for each level. On a P2P link, Level-1 and Level-2 packets are both sent in P2P hello packets, and you need not specify an interval for each level.

You can configure keywords level-1 and level-2 only on broadcast interfaces. Before you do that, enable IS-IS on the interface.

The shorter the interval, the more system resources will be occupied. Configure a proper interval as needed.

If no level is specified, the hello interval applies to both Level-1 and Level-2.

Examples

# Configure Level-2 hello packets to be sent every 20 seconds over VLAN-interface 10.

<Sysname> system-view

[Sysname] interface vlan-interface 10

[Sysname-Vlan-interface10] isis timer hello 20 level-2

Related commands

isis timer holding-multiplier

isis timer holding-multiplier

Use isis timer holding-multiplier to specify the IS-IS hello multiplier.

Use undo isis timer holding-multiplier to remove the configuration.

Syntax

isis timer holding-multiplier value [ level-1 | level-2 ]

undo isis timer holding-multiplier [ level-1 | level-2 ]

Default

The default IS-IS hello multiplier is 3.

Views

Interface view

Predefined user roles

network-admin

mdc-admin

Parameters

value: Specifies the number of hello intervals, in the range of 3 to 1000.

level-1: Applies the number to the Level-1 IS-IS neighbor.

level-2: Applies the number to the Level-2 IS-IS neighbor.

Usage guidelines

The hello multiplier is the number of hello packets a neighbor must miss before declaring the router is down.

If a neighbor does not receive any hello packets from the router within the advertised hold time, it considers the router down and recalculates the routes. The hold time is the hello multiplier multiplied by the hello interval.

Level-1 and Level-2 hello packets are sent independently on a broadcast network, so you need to specify a hello multiplier for each level. On a P2P link, Level-1 and Level-2 packets are both sent in P2P hello packets, and you need not specify Level-1 or Level-2.

You can configure keywords level-1 and level-2 only on broadcast interfaces. Before doing that, enable IS-IS on the interface.

If no level is specified, the hello multiplier applies to the current level.

The value of hello multiplier multiplied by hello interval cannot be more than 65535.

Examples

# Configure the hello multiplier as 6 for VLAN-interface 10.

<Sysname> system-view

[Sysname] interface vlan-interface 10

[Sysname-Vlan-interface10] isis timer holding-multiplier 6

Related commands

isis timer hello

isis timer lsp

 

NOTE:

This command is not available in loopback interface view.

 

Use isis timer lsp to configure the minimum interval for sending LSPs on the interface and specify the maximum number of LSPs that can be sent per time.

Use undo isis timer lsp to restore the default.

Syntax

isis timer lsp time [ count count ]

undo isis timer lsp

Default

The minimum interval for sending LSPs on the interface is 33 milliseconds, and the maximum number of LSPs that can be sent at a time is 5.

Views

Interface view

Predefined user roles

network-admin

mdc-admin

Parameters

time: Specifies the minimum interval in milliseconds for sending link-state packets, in the range of 1 to 1000.

count: Specifies the maximum number of link-state packets to be sent at one time, in the range of 1 to 1000.

Usage guidelines

If a change occurs in the LSDB, IS-IS advertises the changed LSP to neighbors. You can specify the minimum interval for sending these LSPs.

Configure a proper LSP retransmission interval to avoid unnecessary retransmissions.

Examples

# Configure the interval as 500 milliseconds for sending LSPs on interface VLAN-interface 10.

<Sysname> system-view

[Sysname] interface vlan-interface 10

[Sysname-Vlan-interface10] isis timer lsp 500

Related commands

isis timer retransmit

isis timer retransmit

Use isis timer retransmit to configure the interval for retransmitting LSP packets over a point-to-point link.

Use undo isis timer retransmit to restore the default.

Syntax

isis timer retransmit seconds

undo isis timer retransmit

Default

The retransmission interval on a P2P link is 5 seconds.

Views

Interface view

Predefined user roles

network-admin

mdc-admin

Parameters

seconds: Specifies the interval for retransmitting LSP packets, in the range of 1 to 300 seconds.

Usage guidelines

On a P2P link, IS-IS requires an advertised LSP be acknowledged. If no acknowledgement is received within a configurable interval, IS-IS will retransmit the LSP.

You do not need to use this command over a broadcast link where CSNPs are periodically broadcast to implement LSDB synchronization.

Examples

# Configure the LSP retransmission interval on a P2P link as 50 seconds for VLAN-interface 10.

<Sysname> system-view

[Sysname] interface vlan-interface 10

[Sysname-Vlan-interface10] isis circuit-type p2p

[Sysname-Vlan-interface10] isis timer retransmit 50

Related commands

·     isis circuit-type p2p

·     isis timer lsp

ispf enable

Use ispf enable to enable IS-IS incremental SPF (ISPF).

Use undo ispf enable to disable IS-IS ISPF.

Syntax

ispf enable

undo ispf enable

Default

IS-IS ISPF is enabled.

Views

OSPF view

Predefined user roles

network-admin

mdc-admin

Usage guidelines

When a network topology is changed, ISPF recomputes only the affected part of the SPT, instead of the entire SPT.

Examples

# Enable IS-IS ISPF.

<Sysname> system-view

[Sysname] isis 1

[Sysname-isis-1] ispf enable

is-level

Use is-level to specify the IS level.

Use undo is-level to restore the default.

Syntax

is-level { level-1 | level-1-2 | level-2 }

undo is-level

Default

The IS level is level-1-2.

Views

IS-IS view

Predefined user roles

network-admin

mdc-admin

Parameters

level-1: Specifies Level-1, which means IS-IS only calculates intra-area routes and maintains the Level-1 LSDB.

level-1-2: Specifies Level-1-2, which means IS-IS calculates routes and maintains the LSDBs for both Level-1 and Level-2.

level-2: Specifies Level-2, which means IS-IS calculates routes and maintains the LSDB for Level-2 only.

Usage guidelines

If only one area exists, configure all the routers as either Level-1 or Level-2, because the routers do not need to maintain two identical LSDBs at the same time.

If the only area is an IP network, configure all the routers as Level-2 for scalability.

Examples

# Specify the IS level as Level-1 for the IS-IS process 1.

<Sysname> system-view

[Sysname] isis 1

[Sysname-isis-1] is-level level-1

is-name

Use is-name to specify a host name for the IS and enable dynamic system ID to hostname mapping.

Use undo is-name to disable dynamic system ID to hostname mapping.

Syntax

is-name sys-name

undo is-name

Default

Dynamic system ID to hostname mapping is not enabled.

Views

IS-IS view

Predefined user roles

network-admin

mdc-admin

Parameters

sys-name: Specifies a host name for the local IS, a case-insensitive string of 1 to 64 characters.

Usage guidelines

To display the host name rather than the system ID of an IS by using the display isis lsdb command, first enable dynamic system ID to hostname mapping.

Examples

# Configure a host name for the local IS.

<Sysname> system-view

[Sysname] isis 1

[Sysname-isis-1] is-name RUTA

Related commands

display isis name-table

is-name map

Use is-name map to configure a system ID to host name mapping for a remote IS.

Use undo is-name map to remove the mapping.

Syntax

is-name map sys-id map-sys-name

undo is-name map sys-id

Views

IS-IS view

Predefined user roles

network-admin

mdc-admin

Parameters

sys-id: Specifies the system ID or pseudonode ID of a remote IS.

map-sys-name: Specifies a host name for the remote IS, a case-insensitive string of 1 to 64 characters.

Usage guidelines

Each remote IS system ID corresponds to only one name.

Examples

# Map the host name RUTB to the system ID 0000.0000.0041 of the remote IS.

<Sysname> system-view

[Sysname] isis 1

[Sysname-isis-1] is-name map 0000.0000.0041 RUTB

Related commands

display isis name-table

log-peer-change

Use log-peer-change to enable the logging of neighbor state changes.

Use undo log-peer-change to disable the logging.

Syntax

log-peer-change

undo log-peer-change

Default

The logging of IS-IS neighbor state changes is enabled.

Views

IS-IS view

Predefined user roles

network-admin

mdc-admin

Usage guidelines

This command enables sending logs about IS-IS neighbor state changes to the information center. The information center processes the logs according to user-defined output rules (whether to output logs and where to output). For more information about the information center, see Network Management and Monitoring Configuration Guide.

Examples

# Disable the logging of IS-IS neighbor state changes.

<Sysname> system-view

[Sysname] isis 1

[Sysname-isis-1] undo log-peer-change

lsp-fragments-extend

Use lsp-fragments–extend to enable LSP fragment extension for a level.

Use undo lsp-fragments–extend to disable LSP fragment extension.

Syntax

lsp-fragments-extend [ level-1 | level-1-2 | level-2 ]

undo lsp-fragments-extend

Default

LSP fragment extension is disabled.

Views

IS-IS view

Predefined user roles

network-admin

mdc-admin

Parameters

level-1: Applies the fragment extension to Level-1 LSPs.

level-1-2: Applies the fragment extension to both Level-1 and Level-2 LSPs.

level-2: Applies the fragment extension to Level-2 LSPs.

Usage guidelines

If no level is specified, the command enables LSP fragment extension for both Level-1 and Level-2.

Examples

# Enable LSP fragment extension for Level-2.

<Sysname> system-view

[Sysname] isis 1

[Sysname-isis-1] lsp-fragments-extend level-2

lsp-length originate

Use lsp-length originate to configure the maximum size of generated Level-1 or Level-2 LSPs.

Use undo lsp-length originate to remove the configuration.

Syntax

lsp-length originate size [ level-1 | level-2 ]

undo lsp-length originate [ level-1 | level-2 ]

Default

The maximum size of generated Level-1 and Level-2 LSPs is 1497 bytes.

Views

IS-IS view

Predefined user roles

network-admin

mdc-admin

Parameters

size: Specifies the maximum size of LSP packets, in the range of 512 to 16384 bytes.

level-1: Applies the size to Level-1 LSP packets.

level-2: Applies the size to Level-2 LSP packets.

Usage guidelines

If neither Level-1 nor Level-2 is specified in the command, the configured maximum size applies to the current IS-IS level.

Examples

# Configure the maximum size of the generated Level-2 LSPs as 1024 bytes.

<Sysname> system-view

[Sysname] isis 1

[Sysname-isis-1] lsp-length originate 1024 level-2

lsp-length receive

Use lsp-length receive to configure the maximum size of received LSPs.

Use undo lsp-length receive to restore the default.

Syntax

lsp-length receive size

undo lsp-length receive

Default

The maximum size of received LSPs is 1497 bytes.

Views

IS-IS view

Predefined user roles

network-admin

mdc-admin

Parameters

size: Specifies the maximum size of received LSPs, in the range of 512 to 16384 bytes.

Examples

# Configure the maximum size of received LSPs.

<Sysname> system-view

[Sysname] isis 1

[Sysname-isis-1] lsp-length receive 1024

maximum load-balancing (IS-IS view)

Use maximum load-balancing to configure the maximum number of ECMP routes for load balancing.

Use undo maximum load-balancing to restore the default.

Syntax

maximum load-balancing number

undo maximum load-balancing

Default

The maximum number of ECMP routes is 128.

Views

IS-IS view

Predefined user roles

network-admin

mdc-admin

Parameters

number: Specifies the maximum number of ECMP routes, in the range of 1 to 128.

Examples

# Configure the maximum number of ECMP routes as 2.

<Sysname> system-view

[Sysname] isis 100

[Sysname-isis-100] maximum load-balancing 2

network-entity

Use network-entity to configure the Network Entity Title (NET) for an IS-IS process.

Use undo network-entity to delete a NET.

Syntax

network-entity net

undo network-entity net

Default

No NET is configured.

Views

IS-IS view

Predefined user roles

network-admin

mdc-admin

Parameters

net: Specifies a NET as a dotted hexadecimal string in the X…X.XXXX....XXXX.00 format. The X…X segment represents the area address, the XXXX....XXXX segment represents the system ID, and the 00 segment is the SEL.

Usage guidelines

A NET is a special NSAP address with the SEL being 0. The length of the NET is in the range of 8 bytes to 20 bytes.

A NET comprises the following parts:

·     Area IDWith a length of 1 to 13 bytes.

·     System IDA system ID uniquely identifies a host or router in the area and has a fixed 6-byte length.

·     SELIt has a value of 0 and a fixed 1-byte length.

For example, a NET of ab.cdef.1234.5678.9abc.00 specifies the area ID ab.cdef, the system ID 1234.5678.9abc, and the SEL 00.

Examples

# Specify the NET as 10.0001.1010.1020.1030.00, of which 10.0001 is the area ID and 1010.1020.1030 is the system ID.

<Sysname> system-view

[Sysname] isis 1

[Sysname-isis-1] network-entity 10.0001.1010.1020.1030.00

Related commands

·     isis

·     isis enable

preference

Use preference to configure the preference for IS-IS.

Use undo preference to restore the default.

Syntax

preference { preference | route-policy route-policy-name } *

undo preference

Default

IS-IS preference is 15.

Views

IS-IS view

Predefined user roles

network-admin

mdc-admin

Parameters

preference: Specifies an IS-IS protocol preference in the range of 1 to 255.

route-policy route-policy-name: Specifies a routing policy by its name, a case-sensitive string of 1 to 63 characters, to assign a priority to the matching routes.

Usage guidelines

If a routing policy is specified in this command, the preference set by the routing policy applies to the matching routes. Other routes use the preference set by the preference command.

If multiple routing protocols find routes to the same destination, the route found by the routing protocol with the highest preference is selected as the optimal route.

Examples

# Configure the preference for IS-IS as 25.

<Sysname> system-view

[Sysname] isis 1

[Sysname-isis-1] preference 25

priority

Use priority to assign convergence priorities to specific IS-IS routes.

Use undo priority to remove the configuration.

Syntax

priority { critical | high | medium } { prefix-list prefix-list-name | tag tag-value }

undo priority { critical | high | medium } [ prefix-list | tag ]

Default

IS-IS routes have the lowest convergence priority.

Views

IS-IS view

Predefined user roles

network-admin

mdc-admin

Parameters

critical: Specifies the highest convergence priority.

high: Specifies the high convergence priority.

medium: Specifies the medium convergence priority.

prefix-list prefix-list-name: Specifies an IP prefix list by its name, a case-sensitive string of 1 to 63 characters.

tag tag-value: Specifies a tag value in the range of 1 to 4294967295.

Usage guidelines

The higher the convergence priority, the faster the convergence speed.

IS-IS host routes have a medium convergence priority.

Examples

# Assign the high convergence priority to IS-IS routes permitted by IP prefix list standtest.

<Sysname> system-view

[Sysname] isis 1

[Sysname-isis-1] priority high prefix-list standtest

reset isis all

Use reset isis all to clear all IS-IS data structure information.

Syntax

reset isis all [ process-id ] [ graceful-restart ]

Views

User view

Predefined user roles

network-admin

mdc-admin

Parameters

process-id: Specifies an IS-IS process by its ID in the range of 1 to 65535 to clear the data structure information for an IS-IS process.

graceful-restart: Recovers the data through graceful restart after the data is cleared.

Usage guidelines

If no IS-IS process is specified, the command clears data structure information for all IS-IS processes.

Use this command when LSPs must be updated immediately.

Examples

# Clear all IS-IS data structure information.

<Sysname> reset isis all

reset isis graceful-restart event-log

Use reset isis graceful-restart event-log to clear IS-IS GR log information.

Syntax

In standalone mode:

reset isis graceful-restart event-log slot slot-number

In IRF mode:

reset isis graceful-restart event-log chassis chassis-number slot slot-number

Views

User view

Predefined user roles

network-admin

mdc-admin

Parameters

slot slot-number: Specifies a card by its slot number. (In standalone mode.)

chassis chassis-number slot slot-number: Specifies a card on an IRF member device. The chassis-number argument specifies the ID of the IRF member device. The slot-number argument specifies the slot number of the card. (In IRF mode.)

Examples

# Clear IS-IS GR log information about card 1.

<Sysname> reset isis graceful-restart event-log slot 1

reset isis peer

Use reset isis peer to clear data structure information for a specified IS-IS neighbor.

Syntax

reset isis peer system-id [ process-id ]

Views

User view

Predefined user roles

network-admin

mdc-admin

Parameters

system-id: Specifies an IS-IS neighbor by its system ID.

process-id: Specifies an IS-IS process by its ID in the range of 1 to 65535 to clear data structure information for the neighbor in the specified IS-IS process.

Usage guidelines

Use this command when you re-establish an IS-IS neighbor relationship.

Examples

# Clear the data structure information of the neighbor with the system ID 0000.0c11.1111.

<Sysname> reset isis peer 0000.0c11.1111

reset osi statistics

Use reset osi statistics to clear OSI packet statistics.

Syntax

reset osi statistics

Views

User view

Predefined user roles

network-admin

mdc-admin

Usage guidelines

To obtain OSI packet statistics from the specified time point, first clear the existing statistics.

Examples

# Clear OSI packet statistics.

<Sysname> reset osi statistics

Related commands

display osi statistics

set-overload

Use set-overload to set the overload bit.

Use undo set-overload to clear the overload bit.

Syntax

set-overload [ on-startup [ [ start-from-nbr system-id [ timeout1 [ nbr-timeout ] ] ] | timeout2 ] [ allow { external | interlevel } * ]

undo set-overload

Default

The overload bit is not set.

Views

IS-IS view

Predefined user roles

network-admin

mdc-admin

Parameters

on-startup: Sets the overload bit upon system startup.

start-from-nbr system-id [ timeout1 [ nbr-timeout ] ]: Starts the nbr-timeout timer when the router begins to establish the neighbor relationship with the neighbor after system startup. If the neighbor relationship is formed within the nbr-timeout interval, IS-IS keeps the overload bit set. If not, the bit is cleared. IS-IS keeps the overload bit set within the timeout1 interval after the neighbor relationship is formed within the nbr-timeout interval.

·     system-idSpecifies the neighbor.

·     timeout1The timeout1 interval is in the range of 5 to 86400 seconds and defaults to 600 seconds.

·     nbr-timeoutThe timer has an interval from 5 to 86400 seconds. The default is 1200 seconds.

timeout2: Sets the overload bit within the timeout2 interval after system startup. The interval is in the range of 5 to 86400 seconds and defaults to 600 seconds.

allow: Allows advertising address prefixes. By default, no address prefixes are allowed to be advertised when the overload bit is set.

external: Allows advertising IP address prefixes redistributed from other routing protocols with the allow keyword specified.

interlevel: Allows advertising IP address prefixes learned from different IS-IS levels with the allow keyword specified.

Usage guidelines

If the on-startup keyword is not specified, the command sets the overload bit immediately until the undo set-overload command is executed.

If the on-startup keyword is specified, IS-IS sets the overload bit upon system startup and keeps it set within the timeout2 interval.

Examples

# Set overload flag on the current router.

<Sysname> system-view

[Sysname] isis 1

[Sysname-isis-1] set-overload

snmp context-name

Use snmp context-name to set the context name for the SNMP object for managing IS-IS.

Use undo snmp context-name to restore the default.

Syntax

snmp context-name context-name

undo snmp context-name

Default

No context name is set for the SNMP object for managing IS-IS.

Views

IS-IS view

Predefined user roles

network-admin

mdc-admin

Parameters

context-name: Specifies a context name, a case-sensitive string of 1 to 32 characters.

Usage guidelines

TRILL uses the IS-IS MIB to provide the TRILL object management function for NMS. Because the MIB objects defined in the IS-IS MIB are single-instance management objects, NMS cannot manage IS-IS and TRILL at the same time. According to the management for multiple OSPF instances defined in RFC 4750, you can set a context name for the SNMP object for managing TRILL. In this way, the SNMP requests for managing IS-IS and the SNMP requests for managing TRILL from NMS can be distinguished. Because the context name is a concept specific to SNMPv3, the community names are mapped to context names for distinguishing different protocols in SNMPv1/v2c.

Examples

# Configure the context name as isis for the SNMP object for managing IS-IS process 1.

<Sysname> system-view

[Sysname] isis 1

[Sysname-isis-1] snmp context-name isis

snmp-agent trap enable isis

Use snmp-agent trap enable isis to enable the sending of SNMP notifications.

Use undo snmp-agent trap enable isis to disable the feature.

Syntax

snmp-agent trap enable isis [ adjacency-state-change | area-mismatch | authentication | authentication-type | buffsize-mismatch | id-length-mismatch | lsdboverload-state-change | lsp-corrupt | lsp-parse-error | lsp-size-exceeded | manual-address-drop | max-seq-exceeded | maxarea-mismatch | own-lsp-purge | protocol-support  | rejected-adjacency | skip-sequence-number | version-skew ] *

undo snmp-agent trap enable isis [ adjacency-state-change | area-mismatch | authentication | authentication-type | buffsize-mismatch | id-length-mismatch | lsdboverload-state-change | lsp-corrupt | lsp-parse-error | lsp-size-exceeded | manual-address-drop | max-seq-exceeded | maxarea-mismatch | own-lsp-purge | protocol-support  | rejected-adjacency | skip-sequence-number | version-skew ] *

Default

IS-IS notification sending is enabled.

Views

System view

Predefined user roles

network-admin

mdc-admin

Parameters

adjacency-state-change: Specifies notifications about adjacency state changes.

area-mismatch: Specifies notifications about mismatches in area addresses between Hello packets.

authentication: Specifies notifications about authentication failures of IS-IS packets.

authentication-type: Specifies notifications about authentication type errors of IS-IS packets.

buffsize-mismatch: Specifies notifications about buffer size mismatches for LSPs.

id-length-mismatch: Specifies notifications about mismatches in system ID lengths of IS-IS packets.

lsdboverload-state-change: Specifies notifications about LSDB overload state changes.

lsp-corrupt: Specifies notifications about LSP checksum errors in the LSDB.

lsp-parse-error: Specifies notifications about LSP packet parse errors.

lsp-size-exceeded: Specifies notifications about oversized LSPs that result in flooding failures.

manual-address-drop: Specifies notifications about manually configured area addresses that have been dropped.

max-seq-exceeded: Specifies notifications about LSPs with exceeded serial numbers.

maxarea-mismatch: Specifies notifications about mismatches in maximum area address values.

own-lsp-purge: Specifies notifications about attempts to purge local LSPs.

protocol-support: Specifies notifications about supported protocol mismatches.

rejected-adjacency: Specifies notifications about mismatched Hello adjacencies that have been rejected.

skip-sequence-number: Specifies notifications about system ID duplications.

version-skew: Specifies notifications about mismatches in Hello packet protocol versions.

Usage guidelines

If no parameters are specified, the command enables sending of all SNMP notifications.

If no IS-IS process exists, the configuration is not allowed.

This function does not take effect if all configured IS-IS processes are deleted.

Examples

# Disable IS-IS notification sending.

<Sysname> system-view

[Sysname] undo snmp-agent trap enable isis

summary (IS-IS view)

Use summary to configure a summary route.

Use undo summary to remove a summary route.

Syntax

summary ip-address { mask-length | mask } [ avoid-feedback | generate_null0_route | [ level-1 | level-1-2 | level-2 ] | tag tag ] *

undo summary ip-address { mask-length | mask } [ level-1 | level-1-2 | level-2 ]

Default

No summarization is configured.

Views

IS-IS view

Predefined user roles

network-admin

mdc-admin

Parameters

ip-address: Specifies the destination IP address of the summary route.

mask-length: Specifies the mask length of the summary route, in the range of 0 to 32.

mask: Specifies the mask of the destination IP address, in dotted decimal notation.

avoid-feedback: Avoids learning summary routes by route calculation.

generate_null0_route: Generates the Null 0 route to avoid routing loops.

level-1: Summarizes only the routes redistributed to Level-1.

level-1-2: Summarizes the routes redistributed to both Level-1 and Level-2.

level-2: Summarizes only the routes redistributed to Level-2.

tag tag: Specifies a management tag in the range of 1 to 4294967295.

Usage guidelines

If no level is specified, only level-2 routes are summarized.

If no topology is specified, routes for the base topology are summarized.

You can summarize multiple contiguous networks into a single network to reduce the size of the routing table, as well as the size of LSP and LSDB generated by the router. You can summarize native IS-IS routes and redistributed routes. After summarization, the cost of the summary route is the smallest cost of those summarized routes.

The router summarizes only routes generated from local LSPs.

Examples

# Configure a summary route of 202.0.0.0/8.

<Sysname> system-view

[Sysname] isis 1

[Sysname-isis-1] summary 202.0.0.0 255.0.0.0

timer lsp-generation

Use timer lsp-generation to configure LSP generation interval.

Use undo timer lsp-generation to remove the configuration.

Syntax

timer lsp-generation maximum-interval [ minimum-interval [ incremental-interval ] ] [ level-1 | level-2 ]

undo timer lsp-generation [ level-1 | level-2 ]

Default

The maximum interval is 5 seconds, the minimum interval is 50 milliseconds, and the incremental interval is 200 milliseconds.

Views

IS-IS view

Predefined user roles

network-admin

mdc-admin

Parameters

maximum-interval: Specifies the maximum interval in the range of 1 to 120 seconds.

minimum-interval: Specifies the minimum interval in the range of 10 to 60000 milliseconds.

incremental-interval: Specifies the incremental interval in the range of 10 to 60000 milliseconds.

level-1: Applies the intervals to Level-1.

level-2: Applies the intervals to Level-2. If no level is specified, the specified intervals apply to both Level-1 and Level-2.

Usage guidelines

By adjusting the LSP generation interval, you can prevent bandwidth and router resources from being over consumed due to frequent topology changes.

When network changes are not frequent, the minimum-interval is adopted. If network changes become frequent, the LSP generation interval is incremented by the incremental-interval each time a generation occurs until the maximum-interval is reached.

The minimum interval and the incremental interval cannot be greater than the maximum interval.

Examples

# Set the maximum interval, minimum interval, and incremental interval to 10 seconds, 100 milliseconds, and 200 milliseconds.

<Sysname> system-view

[Sysname] isis 1

[Sysname-isis-1]timer lsp-generation 10 100 200

timer lsp-max-age

Use timer lsp-max-age to set the LSP maximum age in the LSDB.

Use undo timer lsp-max-age to restore the default.

Syntax

timer lsp-max-age seconds

undo timer lsp-max-age

Default

The LSP maximum age is 1200 seconds.

Views

IS-IS view

Predefined user roles

network-admin

mdc-admin

Parameters

seconds: Specifies the LSP maximum aging time in the range of 1 to 65535 seconds.

Usage guidelines

Each LSP has an age that decreases in the LSDB. Any LSP with an age of 0 is deleted from the LSDB. You can adjust the age value based on the scale of a network.

Examples

# Set the maximum LSP age to 1500 seconds.

<Sysname> system-view

[Sysname] isis 1

[Sysname-isis-1] timer lsp-max-age 1500

Related commands

timer lsp-refresh

timer lsp-refresh

Use timer lsp-refresh to configure the LSP refresh interval.

Use undo timer lsp-refresh to restore the default.

Syntax

timer lsp-refresh seconds

undo timer lsp-refresh

Default

The default LSP refresh interval is 900 seconds.

Views

IS-IS view

Predefined user roles

network-admin

mdc-admin

Parameters

seconds: Specifies the LSP refresh interval in the range of 1 to 65534 seconds.

Usage guidelines

To prevent valid routes from aging out and to synchronize LSPs in the network, each router needs to refresh its LSPs at a configurable interval and send them to other routers. A smaller refresh interval speeds up network convergence but consumes more bandwidth.

To refresh LSPs before they are aged out, the interval configured by the timer lsp-refresh command must be smaller than that configured by the timer lsp-max-age command.

Examples

# Configure the LSP refresh interval as 1500 seconds.

<Sysname> system-view

[Sysname] isis 1

[Sysname-isis-1] timer lsp-refresh 1500

Related commands

timer lsp-max-age

timer spf

Use timer spf to set the SPF calculation interval.

Use undo timer spf to restore the default.

Syntax

timer spf maximum-interval [ minimum-interval [ incremental-interval ] ]

undo timer spf

Default

The maximum interval is 5 seconds, the minimum interval is 50 milliseconds, and the incremental interval is 200 milliseconds.

Views

IS-IS view

Predefined user roles

network-admin

mdc-admin

Parameters

maximum-interval: Specifies the maximum SPF calculation interval in the range of 1 to 120 seconds.

minimum-interval: Specifies the minimum SPF calculation interval in the range of 10 to 60000 milliseconds.

incremental-interval: Specifies the incremental SPF calculation interval in the range of 10 to 60000 milliseconds.

Usage guidelines

Based on the LSDB, an IS-IS router uses the SPF algorithm to calculate a shortest path tree with itself being the root, and uses the shortest path tree to determine the next hop to a destination network. By adjusting the SPF calculation interval, you can prevent bandwidth and router resources from being overused due to frequent topology changes.

When network changes are not frequent, the minimum-interval is adopted. If network changes become frequent, the SPF calculation interval is incremented by the incremental-interval each time a generation happens until the maximum-interval is reached.

The minimum interval and the incremental interval cannot be greater than the maximum interval.

Examples

# Configure the maximum interval as 10 seconds, the minimum interval as 100 milliseconds, and the incremental interval as 300 milliseconds.

<Sysname> system-view

[Sysname] isis 1

[Sysname-isis-1] timer spf 10 100 300

virtual-system

Use virtual-system to configure a virtual system ID for the IS-IS process.

Use undo virtual-system to remove a virtual system ID.

Syntax

virtual-system virtual-system-id

undo virtual-system virtual-system-id

Default

No virtual system ID is configured.

Views

IS-IS view

Predefined user roles

network-admin

mdc-admin

Parameters

virtual-system-id: Specifies a virtual system ID for the IS-IS process.

Examples

# Set a virtual system ID of 2222.2222.2222 for IS-IS process 1.

<Sysname> system-view

[Sysname] isis 1

[Sysname-isis-1] virtual-system 2222.2222.2222

 


BGP commands

address-family ipv4

Use address-family ipv4 to create and enter BGP IPv4 unicast address family view or BGP-VPN IPv4 unicast address family view.

Use undo address-family ipv4 to remove all configurations in BGP IPv4 unicast address family view or BGP-VPN IPv4 unicast address family view.

Syntax

address-family ipv4 [ unicast ]

undo address-family ipv4 [ unicast ]

Default

The BGP IPv4 unicast address family view or the BGP-VPN IPv4 unicast address family view is not created.

Views

BGP view, BGP-VPN instance view

Predefined user roles

network-admin

mdc-admin

Parameters

unicast: Specifies the IPv4 unicast address family view. The IPv4 unicast address family view is specified for the command regardless of whether the unicast keyword is specified.

Usage guidelines

Configurations made in BGP IPv4 unicast address family view apply only to the BGP IPv4 unicast routes and peers of the public network.

Configurations made in BGP-VPN IPv4 unicast address family view apply only to the BGP IPv4 unicast routes and peers of the specified VPN instance.

Examples

# In BGP view, create and enter BGP IPv4 unicast address family view.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] address-family ipv4 unicast

[Sysname-bgp-ipv4]

# In BGP-VPN instance view, create and enter BGP-VPN IPv4 unicast address family view.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] ip vpn-instance vpn1

[Sysname-bgp-vpn1] address-family ipv4 unicast

[Sysname-bgp-ipv4-vpn1]

advertise-rib-active

Use advertise-rib-active to enable BGP to advertise optimal routes in the IP routing table.

Use undo advertise-rib-active to restore the default.

Syntax

advertise-rib-active

undo advertise-rib-active

Default

BGP advertises optimal routes in the BGP routing table, regardless of whether they are optimal in the IP routing table.

Views

BGP view

Predefined user roles

network-admin

mdc-admin

Usage guidelines

The advertise-rib-active command does not apply to the following routes:

·     Routes redistributed by the import-route command.

·     Routes advertised by the network command.

·     Default routes redistributed by the default-route imported command.

·     VPNv4 routes. VPNv4 routes are supported in Release 1138P01 and later versions.

This command takes effect only for the routes generated after you execute this command. To make this command take effect for the routes generated before you execute this command, use the reset bgp command to reset BGP sessions.

Examples

# Enable BGP to advertise optimal routes in the IP routing table.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] advertise-rib-active

aggregate

Use aggregate to create a summary route in the BGP routing table.

Use undo aggregate to remove a summary route.

Syntax

aggregate ip-address { mask | mask-length } [ as-set | attribute-policy route-policy-name | detail-suppressed | origin-policy route-policy-name | suppress-policy route-policy-name ] *

undo aggregate ip-address { mask | mask-length }

Default

No summary route is configured.

Views

BGP IPv4 unicast address family view, BGP-VPN IPv4 unicast address family view

Predefined user roles

network-admin

mdc-admin

Parameters

ip-address: Specifies a summary address.

mask: Specifies a mask for the summary address, in dotted decimal notation.

mask-length: Specifies a mask length for the summary address, in the range of 0 to 32.

as-set: Enables the AS_PATH attribute of the summary route to contain the AS path information of all summarized routes. The AS_PATH attribute is of the AS_SET type that requires no sequence when arranging AS numbers. If this keyword is not specified, the AS_PATH attribute of the summary route contains only the AS number of the local router.

attribute-policy route-policy-name: Specifies a routing policy by its name, a case-sensitive string of 1 to 63 characters, to set attributes for the summary route.

detail-suppressed: Advertises only the summary route. If this keyword is not specified, BGP advertises both the summary route and the more specific routes.

origin-policy route-policy-name: Specifies a routing policy by its name, a case-sensitive string of 1 to 63 characters, to select routes to be summarized.

suppress-policy route-policy-name: Specifies a routing policy by its name, a case-sensitive string of 1 to 63 characters, to filter more specific routes to be advertised. Routes permitted by the specified routing policy are not advertised. Routes denied by the specified routing policy are advertised.

Usage guidelines

This command creates a summary route. If the BGP routing table has routes whose destination addresses fall within the specified network, the summary route is added to the BGP routing table. For example, if two routes 10.1.1.0/24 and 10.1.2.0/24 exist in the BGP routing table, configuring the aggregate 10.1.0.0 16 command creates a summary route 10.1.0.0/16.

If the summarized routes have different ORIGIN attributes, the summary route selects the ORIGIN attribute in the sequence of INCOMPLETE, EGP, and IGP. For example, if the ORIGIN attributes of the summarized routes include INCOMPLETE and IGP, the ORIGIN attribute of the summary route is INCOMPLETE.

If the summarized routes have different COMMUNITY (or extended community) attribute values and the summary route does not have the ATOMIC_AGGREGATE attribute, the COMMUNITY attribute of the summary route carries all the COMMUNITY (or extended community) attribute values.

Table 63 Functions of the keywords

Keywords

Function

as-set

Enables the summary route to carry the AS path information of all summarized routes. This feature can help avoid routing loops. However, if many routes are summarized and are changed frequently, do not specify this keyword because this configuration causes the summary route to flap with the more specific routes.

attribute-policy

Sets attributes except the AS-PATH attribute for the summary route. The peer route-policy command can achieve the same purpose.

detail-suppressed

Disables advertisement of all more specific routes. To disable advertisement of some more specific routes, use the suppress-policy keyword or the peer filter-policy command.

origin-policy

Summarizes only routes matching a routing policy.

If the destination address of a route falls within the summary network but does not match the routing policy, the route is not summarized, and is not controlled by the detail-suppressed and suppress-policy keywords.

There is no need to configure apply clauses for the routing policy referenced by the origin-policy keyword because they do not take effect.

suppress-policy

Disables advertisement of some more specific routes filtered by a routing policy. The routing policy uses if-match clauses to filter routes.

There is no need to configure apply clauses for the routing policy referenced by the suppress-policy keyword because they do not take effect.

 

Examples

# In BGP IPv4 unicast address family view, create a summary route 1.1.0.0/16 in the BGP routing table.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] address-family ipv4 unicast

[Sysname-bgp-ipv4] aggregate 1.1.0.0 255.255.0.0

# In BGP IPv4 unicast address family view, create a summary route 1.1.0.0/16 in the BGP routing table. Specify the AS_PATH attribute for the summary route to contain the AS path information of all summarized routes, and advertise only the summary route.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] address-family ipv4 unicast

[Sysname-bgp-ipv4] aggregate 1.1.0.0 255.255.0.0 as-set detail-suppressed

# In BGP IPv4 unicast address family view, create a summary route 1.1.0.0/16 in the BGP routing table, and set the COMMUNITY attribute of the summary route to INTERNET.

<Sysname> system-view

[Sysname] route-policy commu permit node 0

[Sysname-route-policy-commu-0] apply community internet

[Sysname-route-policy-commu-0] quit

[Sysname] bgp 100

[Sysname-bgp] address-family ipv4 unicast

[Sysname-bgp-ipv4] aggregate 1.1.0.0 255.255.0.0 attribute-policy commu

# In BGP IPv4 unicast address family view, create a summary route 1.1.0.0/16 in the BGP routing table, and configure BGP to not summarize route 1.1.1.0/24.

<Sysname> system-view

[Sysname] ip prefix-list spert deny 1.1.1.0 24

[Sysname] ip prefix-list spert permit 0.0.0.0 0 less-equal 32

[Sysname] route-policy srcrt permit node 0

[Sysname-route-policy-srcrt-0] if-match ip address prefix-list spert

[Sysname-route-policy-srcrt-0] quit

[Sysname] bgp 100

[Sysname-bgp] address-family ipv4 unicast

[Sysname-bgp-ipv4] aggregate 1.1.0.0 255.255.0.0 origin-policy srcrt

# In BGP IPv4 unicast address family view, create a summary route 1.1.0.0/16 in the BGP routing table, and disable BGP to advertise the specific route 1.1.1.0/24.

<Sysname> system-view

[Sysname] ip prefix-list spert permit 1.1.1.0 24

[Sysname] ip prefix-list spert deny 0.0.0.0 0 less-equal 32

[Sysname] route-policy suprt permit node 0

[Sysname-route-policy-suprt-0] if-match ip address prefix-list spert

[Sysname-route-policy-suprt-0] quit

[Sysname] bgp 100

[Sysname-bgp] address-family ipv4 unicast

[Sysname-bgp-ipv4] aggregate 1.1.0.0 255.255.0.0 suppress-policy suprt

# In BGP-VPN IPv4 unicast address family view, create a summary route 1.1.0.0/16 in BGP routing table.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] ip vpn-instance vpn1

[Sysname-bgp-vpn1] address-family ipv4 unicast

[Sysname-bgp-ipv4-vpn1] aggregate 1.1.0.0 255.255.0.0

Related commands

·     display bgp routing-table ipv4 unicast

·     summary automatic

balance

Use balance to enable load balancing and specify the maximum number of BGP ECMP routes for load balancing.

Use undo balance to disable load balancing.

Syntax

balance [ ebgp | eibgp | ibgp ] number

undo balance [ ebgp | eibgp | ibgp ]

Default

Load balancing is not enabled.

Views

BGP IPv4 unicast address family view, BGP-VPN IPv4 unicast address family view

Predefined user roles

network-admin

mdc-admin

Parameters

ebgp: Enables load balancing over EBGP routes.

eibgp: Enables load balancing between EBGP and IBGP routes.

ibgp: Enables load balancing over IBGP routes.

number: Specifies the maximum number of BGP ECMP routes for load balancing, in the range of 1 to 128. When it is set to 1, load balancing is disabled.

Usage guidelines

Unlike IGP, BGP has no explicit metric for making load balancing decision. Instead, it implements load balancing by modifying route selection rules. If multiple BGP routes destined for a network have the same AS_PATH, ORIGIN, LOCAL_PREF, and MED attributes, the device selects the specified number of routes for load balancing.

If you do not specify the ibgp, eibgp, or ebgp keyword, this command enables load balancing over EBGP routes and IBGP routes, but not between EBGP and IBGP routes.

After you execute the balance eibgp number command, the balance [ ebgp | ibgp ] number and undo balance [ ebgp | ibgp ] commands cannot be executed; and vice versa.

Examples

# In BGP IPv4 unicast address family view, enable load balancing and specify the maximum number of BGP ECMP routes used for load balancing as 2.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] address-family ipv4 unicast

[Sysname-bgp-ipv4] balance 2

balance as-path-neglect

Use balance as-path-neglect to enable load balancing over routes with different AS_PATH attributes.

Use undo balance as-path-neglect to disable load balancing over routes with different AS_PATH attributes.

Syntax

balance as-path-neglect

undo balance as-path-neglect

Default

Load balancing is not enabled over routes with different AS_PATH attributes.

Views

BGP IPv4 unicast address family view

Predefined user roles

network-admin

mdc-admin

Usage guidelines

Before using this command, ensure that it does not cause any routing loops.

Examples

# Enable load balancing over routes with different AS_PATH attributes.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] address-family ipv4 unicast

[Sysname-bgp-ipv4] balance as-path-neglect

Related commands

balance

bestroute as-path-neglect

Use bestroute as-path-neglect to configure BGP to not consider the AS_PATH during best route selection.

Use undo bestroute as-path-neglect to configure BGP to consider the AS_PATH during best route selection.

Syntax

bestroute as-path-neglect

undo bestroute as-path-neglect

Default

BGP considers the AS_PATH during best route selection.

Views

BGP IPv4 unicast address family view, BGP-VPN IPv4 unicast address family view

Predefined user roles

network-admin

mdc-admin

Examples

# In BGP IPv4 unicast address family view, ignore AS_PATH in route selection.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] address-family ipv4 unicast

[Sysname-bgp-ipv4] bestroute as-path-neglect

bestroute compare-med

Use bestroute compare-med to enable MED comparison for routes on a per-AS basis.

Use undo bestroute compare-med to restore the default.

Syntax

bestroute compare-med

undo bestroute compare-med

Default

MED comparison for routes on a per-AS basis is disabled.

Views

BGP IPv4 unicast address family view, BGP-VPN IPv4 unicast address family view

Predefined user roles

network-admin

mdc-admin

Usage guidelines

By default, BGP does not compare MEDs for routes from the same AS. When a router learns a new route, it compares the route with the optimal route in its BGP routing table. If the new route is more optimal, it becomes the optimal route in the BGP routing table. In this way, route learning sequence might affect optimal route selection.

With the bestroute compare-med command configured, the router puts routes received from the same AS into a group. The router then selects the route with the lowest MED from the same group, and compares routes from different groups. This mechanism avoids the above-mentioned problem.

If the bestroute compare-med and balance commands are configured at the same time, the balance command does not take effect.

Examples

# In BGP IPv4 unicast address family view, enable MED comparison for routes on a per-AS basis.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] address-family ipv4 unicast

[Sysname-bgp-ipv4] bestroute compare-med

# In BGP-VPN IPv4 unicast address family view, enable MED comparison for routes on a per-AS basis.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] ip vpn-instance vpn1

[Sysname-bgp-vpn1] address-family ipv4 unicast

[Sysname-bgp-ipv4-vpn1] bestroute compare-med

bestroute med-confederation

Use bestroute med-confederation to enable MED comparison for routes received from confederation peers.

Use undo bestroute med-confederation to restore the default.

Syntax

bestroute med-confederation

undo bestroute med-confederation

Default

MED comparison is disabled for routes received from confederation peers.

Views

BGP IPv4 unicast address family view, BGP-VPN IPv4 unicast address family view

Predefined user roles

network-admin

mdc-admin

Usage guidelines

This command enables BGP to compare the MEDs of routes received from confederation peers. However, if a route received from a confederation peer has an AS number that does not belong to the confederation, BGP does not compare the route with other routes. For example, a confederation has three AS numbers 65006, 65007, and 65009. BGP receives three routes from different confederation peers. The AS_PATH attributes of these routes are 65006 65009, 65007 65009, and 65008 65009, and the MED values of them are 2, 3, and 1. Because the third route's AS_PATH attribute contains AS number 65008 that does not belong to the confederation, BGP does not compare it with other routes. As a result, the first route becomes the optimal route.

Examples

# In BGP IPv4 unicast address family view, enable MED comparison for routes received from confederation peers.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] address-family ipv4 unicast

[Sysname-bgp-ipv4] bestroute med-confederation

# In BGP-VPN IPv4 unicast address family view, enable MED comparison for routes received from confederation peers.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] ip vpn-instance vpn1

[Sysname-bgp-vpn1] address-family ipv4 unicast

[Sysname-bgp-ipv4-vpn1] bestroute med-confederation

bgp

Use bgp to enable BGP and enter BGP view.

Use undo bgp to disable BGP.

Syntax

bgp as-number

undo bgp [ as-number ]

Default

BGP is not enabled.

Views

System view

Predefined user roles

network-admin

mdc-admin

Parameters

as-number: Specifies a local AS by its number in the range of 1 to 4294967295.

Usage guidelines

A router can reside in only one AS, so the router can run only one BGP process.

A router supports 4-byte AS number.

Examples

# Enable BGP, set the local AS number to 100, and enter BGP view.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp]

bgp update-delay on-startup

Use bgp update-delay on-startup to configure the device to delay sending BGP updates on reboot.

Use undo bgp update-delay on-startup to restore the default.

Syntax

bgp update-delay on-startup { seconds | prefix-list prefix-list-name }

undo bgp update-delay on-startup

Default

The device immediately sends BGP updates on reboot.

Views

BGP view

Predefined user roles

network-admin

mdc-admin

Parameters

seconds: Specifies the delay time in the range of 1 to 3600 seconds. (In Release 1135.)

seconds: Specifies the delay time in the range of 0 to 3600 seconds. The value of 0 indicates that BGP does not send route updates after the device reboots. (In Release 1138P01 and later versions.)

prefix-list prefix-list-name: Specifies an IP prefix list to filter BGP updates. The prefix-list-name argument specifies the IP prefix list by its name, a case-sensitive string of 1 to 63 characters.

Usage guidelines

After this command is executed, BGP redistributes all routes from other neighbors on reboot, and then advertises the optimal route. This configuration reduces traffic loss due to the reboot.

Examples

# Configure the device to wait 100 seconds before sending BGP updates on reboot.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp-100] bgp update-delay on-startup 100

compare-different-as-med

Use compare-different-as-med to enable MED comparison for routes from peers in different ASs.

Use undo compare-different-as-med to disable the comparison.

Syntax

compare-different-as-med

undo compare-different-as-med

Default

The comparison is disabled.

Views

BGP IPv4 unicast address family view, BGP-VPN IPv4 unicast address family view

Predefined user roles

network-admin

mdc-admin

Usage guidelines

If multiple routes to a destination exist, the route with the smallest MED is selected.

Do not use this command unless relevant ASs adopt the same IGP protocol and routing selection method.

Examples

# In BGP IPv4 unicast address family view, enable MED comparison for routes from peers in different ASs.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] address-family ipv4 unicast

[Sysname-bgp-ipv4] compare-different-as-med

# In BGP-VPN IPv4 unicast address family view, enable MED comparison for routes from peers in different ASs.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] ip vpn-instance vpn1

[Sysname-bgp-vpn1] address-family ipv4 unicast

[Sysname-bgp-ipv4-vpn1] compare-different-as-med

confederation id

Use confederation id to configure a confederation ID.

Use undo confederation id to remove the specified confederation ID.

Syntax

confederation id as-number

undo confederation id

Default

No confederation ID is configured.

Views

BGP view

Predefined user roles

network-admin

mdc-admin

Parameters

as-number: Specifies an AS number that identifies the confederation, in the range of 1 to 4294967295.

Usage guidelines

You can split an AS into several sub-ASs, and each sub-AS remains fully meshed. These sub-ASs form a confederation. Key path attributes of a route, such as the Next_HOP, MED, and LOCAL_PREF, are not discarded when crossing each sub-AS. The sub-ASs still look like one AS from the perspective of other ASs. The AS number is the confederation ID.

Confederation can ensure the integrity of the former AS, and solve the problem of too many IBGP connections in the AS.

Configure the same confederation ID for all routers in one confederation.

On a member outside of a confederation, to establish a BGP connection to a specific router in that confederation, specify the AS number of the router as the confederation ID.

Examples

# Confederation 9 consists of four sub-ASs numbered 38, 39, 40 and 41. The peer 10.1.1.1 is a member of sub-AS 38. The peer 200.1.1.1 is a member outside of confederation 9, which belongs to AS 98. Confederation 9 looks like one AS (with AS number 9) from the perspective of the peer 200.1.1.1. This example uses a router in sub-AS 41.

<Sysname> system-view

[Sysname] bgp 41

[Sysname-bgp] confederation id 9

[Sysname-bgp] confederation peer-as 38 39 40

[Sysname-bgp] group Confed38 external

[Sysname-bgp] peer Confed38 as-number 38

[Sysname-bgp] peer 10.1.1.1 group Confed38

[Sysname-bgp] group Remote98 external

[Sysname-bgp] peer Remote98 as-number 98

[Sysname-bgp] peer 200.1.1.1 group Remote98

Related commands

·     confederation nonstandard

·     confederation peer-as

confederation nonstandard

Use confederation nonstandard to enable compatibility with routers not compliant with RFC 3065 in the confederation.

Use undo confederation nonstandard to restore the default.

Syntax

confederation nonstandard

undo confederation nonstandard

Default

The device is compatible only with routers compliant with RFC 3065 in the confederation.

Views

BGP view

Predefined user roles

network-admin

mdc-admin

Usage guidelines

Configure this command on all routers compliant with RFC 3065 to interact with those routers not compliant with RFC 3065 in the confederation.

Examples

# Confederation 100 comprises two sub-ASs, 64000 and 65000, and contains routers not compliant with RFC 3065. Enable compatibility with routers not compliant with RFC 3065 in the confederation.

<Sysname> system-view

[Sysname] bgp 64000

[Sysname-bgp] confederation id 100

[Sysname-bgp] confederation peer-as 65000

[Sysname-bgp] confederation nonstandard

Related commands

·     confederation id

·     confederation peer-as

confederation peer-as

Use confederation peer-as to specify confederation peer sub-ASs.

Use undo confederation peer-as to remove specified confederation peer sub-ASs.

Syntax

confederation peer-as as-number-list

undo confederation peer-as [ as-number-list ]

Default

No confederation peer sub-ASs are specified.

Views

BGP view

Predefined user roles

network-admin

mdc-admin

Parameters

as-number-list: Specifies a sub-AS number list. A maximum of 32 sub-ASs can be configured in one command line. The expression is as-number-list = as-number &<1-32>. The as-number argument specifies a sub-AS number in the range of 1 to 4294967295, and &<1-32> indicates a maximum of 32 numbers can be specified.

Usage guidelines

Before this configuration, use the confederation id command to specify the confederation for the sub-ASs.

If the undo confederation peer-as command without the as-number-list argument is used, all confederation peer sub-ASs are removed.

Examples

# Specify confederation peer sub-ASs 2000 and 2001.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] confederation id 10

[Sysname-bgp] confederation peer-as 2000 2001

Related commands

·     confederation id

·     confederation nonstandard

dampening

Use dampening to enable BGP route dampening.

Use undo dampening to disable route dampening.

Syntax

dampening [ half-life-reachable half-life-unreachable reuse suppress ceiling | route-policy route-policy-name ] *

undo dampening

Default

Route dampening is disabled.

Views

BGP IPv4 unicast address family view, BGP-VPN IPv4 unicast address family view

Predefined user roles

network-admin

mdc-admin

Parameters

half-life-reachable: Specifies a half-life for active routes, in the range of 1 to 45 minutes. The default value is 15 minutes.

half-life-unreachable: Specifies a half-life for suppressed routes, in the range of 1 to 45 minutes. The default value is 15 minutes.

reuse: Specifies a reuse threshold value for suppressed routes, in the range of 1 to 20000. The default reuse value is 750. A suppressed route whose penalty value decreases under the value is reused. The reuse threshold must be less than the suppression threshold.

suppress: Specifies a suppression threshold in the range of 1 to 20000. The default value is 2000. The route with a penalty value higher than the threshold is suppressed.

ceiling: Specifies a ceiling penalty value in the range of 1001 to 20000. The value must be bigger than the suppress value. The default value is 16000.

route-policy route-policy-name: Specifies a routing policy by its name, a case-sensitive string of 1 to 63 characters.

Usage guidelines

The command dampens only EBGP routes.

Examples

# In BGP IPv4 unicast address family view, configure BGP route dampening.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] address-family ipv4 unicast

[Sysname-bgp-ipv4] dampening 10 10 1000 2000 10000

# In BGP-VPN IPv4 unicast address family view, configure BGP route dampening.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] ip vpn-instance vpn1

[Sysname-bgp-vpn1] address-family ipv4 unicast

[Sysname-bgp-ipv4-vpn1] dampening 10 10 1000 2000 10000

Related commands

display bgp dampening parameter ipv4 unicast

default local-preference

Use default local-preference to configure a default local preference.

Use undo default local-preference to restore the default.

Syntax

default local-preference value

undo default local-preference

Default

The default local preference is 100.

Views

BGP IPv4 unicast address family view, BGP-VPN IPv4 unicast address family view

Predefined user roles

network-admin

mdc-admin

Parameters

value: Specifies a default local preference in the range of 0 to 4294967295. A larger value represents a higher preference.

Usage guidelines

You can also use the apply local-preference command in a routing policy to configure the local preference for BGP routes. If no routing policy is configured, all BGP routes use the local preference set by the default local-preference command. If a routing policy is configured, BGP routes matching the routing policy use the local preference set by the apply local-preference command, and other BGP routes use the local preference set by the default local-preference command.

Examples

# In BGP IPv4 unicast address family view, set the default local preference to 180.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] address-family ipv4 unicast

[Sysname-bgp-ipv4] default local-preference 180

Related commands

·     apply local-preference

·     route-policy

default med

Use default med to specify a default MED value.

Use undo default med to restore the default.

Syntax

default med med-value

undo default med

Default

The default med-value is 0.

Views

BGP IPv4 unicast address family view, BGP-VPN IPv4 unicast address family view

Predefined user roles

network-admin

mdc-admin

Parameters

med-value: Specifies the default MED value in the range of 0 to 4294967295.

Usage guidelines

BGP selects a MED value in the following order:

1.     MED set by the apply cost command.

2.     MED set by the med keyword in the import-route command.

3.     MED set by the default med command.

4.     Original MED of a BGP route, or MED changed from the metric of a redistributed IGP route.

Examples

# In BGP IPv4 unicast address family view, configure the default MED as 25.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] address-family ipv4 unicast

[Sysname-bgp-ipv4] default med 25

Related commands

·     apply cost

·     import-route

·     route-policy

default-route imported

Use default-route imported to enable default route redistribution into the BGP routing table.

Use undo default-route imported to restore the default.

Syntax

default-route imported

undo default-route imported

Default

Default route redistribution is not enabled.

Views

BGP IPv4 unicast address family view, BGP-VPN IPv4 unicast address family view

Predefined user roles

network-admin

mdc-admin

Usage guidelines

Typically, BGP does not redistribute default IGP routes. To redistribute default IGP routes into the BGP routing table, use the default-route imported command together with the import-route command.

Examples

# In BGP IPv4 unicast address family view, enable default route redistribution from OSPF process 1 into the BGP routing table.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] address-family ipv4 unicast

[Sysname-bgp-ipv4] default-route imported

[Sysname-bgp-ipv4] import-route ospf 1

# In BGP-VPN IPv4 unicast address family view, enable default route redistribution from OSPF process 1 into the BGP routing table.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] ip vpn-instance vpn1

[Sysname-bgp-vpn1] address-family ipv4 unicast

[Sysname-bgp-ipv4-vpn1] default-route imported

[Sysname-bgp-ipv4-vpn1] import-route ospf 1

Related commands

import-route

display bgp dampening parameter ipv4 unicast

Use display bgp dampening parameter ipv4 unicast to display BGP IPv4 unicast route dampening parameters.

Syntax

display bgp dampening parameter ipv4 [ unicast ] [ vpn-instance vpn-instance-name ]

Views

Any view

Predefined user roles

network-admin

network-operator

mdc-admin

mdc-operator

Parameters

vpn-instance vpn-instance-name: Specifies an MPLS L3VPN instance by its name, a case-sensitive string of 1 to 31 characters. If you do not specify a VPN instance, this command displays BGP IPv4 unicast route dampening parameters for the public network.

Usage guidelines

This command displays BGP IPv4 unicast route dampening parameters regardless of whether the unicast keyword is specified or not.

Examples

# Display BGP IPv4 unicast route dampening parameters for the public network.

<Sysname> display bgp dampening parameter ipv4

Maximum suppression time (in seconds)              : 3973

Ceiling value                                      : 16000

Reuse value                                        : 750

Half-life time for reachable routes (in seconds)   : 900

Half-life time for unreachable routes (in seconds) : 900

Suppression threshold                              : 2000

Table 64 Command output

Field

Description

Maximum suppression time

Maximum time (in seconds) for the penalty value to decrease from the ceiling value to the reuse value.

Ceiling value

Penalty ceiling value.

Reuse value

Reuse threshold.

 

Related commands

dampening

display bgp group

Use display bgp group to display BGP peer group information.

Syntax

display bgp group ipv4 [ unicast ] [ vpn-instance vpn-instance-name ] [ group-name group-name ]

display bgp group vpnv4 [ vpn-instance vpn-instance-name ] [ group-name group-name ]

Views

Any view

Predefined user roles

network-admin

network-operator

mdc-admin

mdc-operator

Parameters

ipv4: Displays IPv4 BGP peer group information.

unicast: Displays BGP unicast peer group information. If you do not specify this keyword, the command also displays BGP unicast peer group information.

vpnv4: Displays BGP VPNv4 peer group information. This keyword is available in Release 1138P01 and later versions.

vpn-instance vpn-instance-name: Specifies an MPLS L3VPN instance by its name, a case-sensitive string of 1 to 31 characters. If you do not specify a VPN instance, this command displays BGP IPv4 unicast peer group information for the public network.

group-name group-name: Specifies a BGP IPv4 unicast peer group by its name, a case-sensitive string of 1 to 47 characters. If you do not specify a group, this command displays brief information about all BGP IPv4 unicast peer groups.

Usage guidelines

This command displays BGP IPv4 unicast peer group information regardless of whether the unicast keyword is specified or not.

Examples

# Display brief information about all BGP IPv4 unicast peer groups for the public network.

 BGP peer group: group1

 Remote AS: 600

 Type: external

 Members:

  1.1.1.10

 

 BGP peer group: group2

 Remote AS number: not specified

 Type: external

 Members:

  2.2.2.2

# Display detailed information about BGP IPv4 unicast peer group group1 for the public network.

<Sysname> display bgp group ipv4 group1

 BGP peer group: group1

 Remote AS: 600

 Type: external

 Maximum number of prefixes allowed: 4294967295

 Threshold: 75%

 Configured hold time: 180 seconds

 Keepalive time: 60 seconds

 Minimum time between advertisements: 30 seconds

 Peer preferred value: 0

 

 Routing policy configured:

 No routing policy is configured

 

 Members:

  Peer                    AS  MsgRcvd  MsgSent OutQ PrefRcv Up/Down  State

 

  1.1.1.10               600        0        0    0       0 00:00:55 Established

Table 65 Command output

Field

Description

BGP peer group

Name of the BGP peer group.

Remote AS

AS number of the peer group.

Type

Type of the peer groups:

·     external—EBGP peer group.

·     internal—IBGP peer group.

Maximum number of prefixes allowed

Maximum number of routes allowed to learn from the peer.

Threshold

Percentage of received routes from the peer to maximum routes allowed to learn from the peer. If the percentage is reached, the system generates alarm messages.

Configured hold time

Configured Hold Interval in seconds.

Keepalive time

Keepalive interval in seconds.

Minimum time between advertisements

Minimum route advertisement interval in seconds.

Peer preferred value

Preferred value specified for routes from the peer.

Routing policy configured

Routing policy configured for the peer group.

If no routing policy is specified, this field displays No routing policy is configured.

Members

Information about peers included in the peer group.

Peer

IP address of the peer.

AS

AS number of the peer.

MsgRcvd

Number of messages received.

MsgSent

Number of messages sent.

OutQ

Number of messages to be sent.

PrefRcv

Number of prefixes received.

Up/Down

Lasting time of the current BGP session state.

State

Current state of the BGP session between the local router and the peer.

 

display bgp network

Use display bgp network to display information about routes advertised by the network command and shortcut routes configured by the network short-cut command.

Syntax

display bgp network ipv4 [ unicast ]

Views

Any view

Predefined user roles

network-admin

network-operator

mdc-admin

mdc-operator

Parameters

ipv4: Displays IPv4 address family information.

unicast: Displays IPv4 unicast address family information regardless of whether this keyword is specified or not.

vpn-instance vpn-instance-name: Specifies an MPLS L3VPN instance by its name, a case-sensitive string of 1 to 31 characters. If you do not specify a VPN instance, this command displays routing information for the public network.

Examples

# Display information about routes advertised by the network command and shortcut routes configured by the network short-cut command in the IPv4 unicast address family for the public network.

<Sysname> display bgp network ipv4

 

  BGP local router ID: 192.168.1.135

  Local AS number: 100

 

  Network           Mask            Route-policy        Short-cut

  20.1.1.0          255.255.255.0                       No

  40.1.1.0          255.255.255.0   abc                 No

  30.1.1.0          255.255.255.0                       Yes

# Display information about routes advertised by the network command and shortcut routes configured by the network short-cut command in the IPv4 unicast address family in VPN instance vpn1.

<Sysname> display bgp network ipv4 vpn-instance vpn1

 

  BGP local router ID: 192.168.1.135

  Local AS number: 100

 

  Network           Mask            Route-policy        Short-cut

  50.1.1.0          255.255.255.0                       No

  40.1.1.0          255.255.255.0                       Yes

Table 66 Command output

Field

Description

Network

Destination network address of the routes advertised by the network command and the shortcut routes.

Mask

Mask of the destination network address.

PrefixLen

Prefix length of the destination network address.

Route-policy

Routing policy that is applied to the route.

Short-cut

Whether the route is a shortcut route:

·     Yes.

·     No.

 

display bgp non-stop-routing status

Use display bgp non-stop-routing status to display BGP NSR status information.

Syntax

display bgp non-stop-routing status

Views

Any view

Predefined user roles

network-admin

network-operator

mdc-admin

mdc-operator

Examples

# Display BGP NSR status information.

<Sysname> display bgp non-stop-routing status

 

BGP NSR status: Ready

 Location of preferred standby process: Chassiss 0 slot 1

 TCP NSR status: Ready

Table 67 Command output

Field

Description

BGP NSR status

BGP NSR status:

·     Ready—BGP NSR has backed up BGP neighbor and routing information from the active process to the standby process. In this state, BGP NSR can ensure continuous routing when an active/standby process switchover occurs.

·     Not ready—BGP NSR is backing up BGP neighbor and routing information from the active process to the standby process. If an active/standby process switchover occurs in this state, traffic is interrupted and the BGP session will be re-established.

Location of preferred standby process

ID of the slot where the preferred standby process resides (in standalone mode).

IRF member device ID and slot ID where the preferred standby process resides (in IRF mode).

TCP NSR status

TCP NSR status:

·     Ready—TCP NSR has backed up TCP connection information from the active process to the standby process.

·     Not ready—TCP NSR is backing up TCP connection information from the active process to the standby process.

 

display bgp paths

Use display bgp paths to display BGP path attribute information.

Syntax

display bgp paths [ as-regular-expression ]

Views

Any view

Predefined user roles

network-admin

network-operator

mdc-admin

mdc-operator

Parameters

as-regular-expression: Displays information about BGP path attributes whose AS_PATH attribute matches the specified regular expression. The as-regular-expression argument is a string of 1 to 256 characters. If you do not specify this argument, the command displays information about all BGP path attributes.

Examples

# Display information about all BGP path attributes.

<Sysname> display bgp paths

 

  RefCount    MED         Path/Origin

  3           0           ?

  2           0           100i

  3           0           100i

  1           0           ?

  1           0           ?

  1           0           ?

Table 68 Command output

Field

Description

RefCount

Number of BGP routes with these path attributes.

MED

MULTI_EXIT_DISC attribute.

Path/Origin

AS_PATH and ORIGIN attributes of the route:

·     AS_PATH attributeRecords the ASs the route has passed to avoid routing loops.

·     ORIGIN attribute—Identifies the origin of the route:

¡     i—Originated in the AS. The origin of summary routes and routes advertised with the network command is IGP.

¡     e—Learned through EGP.

¡     ?—Unknown origin. The origin of routes redistributed from IGP protocols is INCOMPLETE.

 

display bgp peer

Use display bgp peer to display BGP peer or peer group information.

Syntax

In standalone mode:

display bgp peer ipv4 [ unicast ] [ vpn-instance vpn-instance-name ] [ ip-address mask-length | { ip-address | group-name group-name } log-info | [ [ ip-address ] verbose ] [ standby slot slot-number ] ]

display bgp peer vpnv4 [ vpn-instance vpn-instance-name ] [ ip-address mask-length | { ip-address | group-name group-name } log-info | [ [ ip-address ] verbose ] [ standby slot slot-number ] ]

In IRF mode:

display bgp peer ipv4 [ unicast ] [ vpn-instance vpn-instance-name ] [ ip-address mask-length | { ip-address | group-name group-name } log-info | [ [ ip-address ] verbose ] [ standby chassis chassis-number slot slot-number ] ]

display bgp peer vpnv4 [ vpn-instance vpn-instance-name ] [ ip-address mask-length | { ip-address | group-name group-name } log-info | [ [ ip-address ] verbose ] [ standby chassis chassis-number slot slot-number ] ]

Views

Any view

Predefined user roles

network-admin

network-operator

mdc-admin

mdc-operator

Parameters

ipv4: Displays IPv4 BGP peer or peer group information.

unicast: Displays BGP unicast peer or peer group information. If you do not specify this keyword, the command also displays BGP unicast peer or peer group information.

vpnv4: Displays BGP VPNv4 peer or peer group information. This keyword is available in Release 1138P01 and later versions.

vpn-instance vpn-instance-name: Specifies an MPLS L3VPN instance by its name, a case-sensitive string of 1 to 31 characters. If you do not specify a VPN instance, this command displays BGP IPv4 unicast peer or peer group information for the public network.

group-name group-name: Specifies a peer group by its name, a case-sensitive string of 1 to 47 characters.

ip-address: Specifies a peer by its IP address.

ip-address mask-length: Specifies a subnet. The value range for the mask length is 0 to 32. If you specify a subnet, this command displays information about all dynamic peers in the subnet.

log-info: Displays log information.

verbose: Displays detailed information.

slot slot-number: Specifies the slot number of the card where the standby process resides. (In standalone mode.)

chassis chassis-number slot slot-number: Specifies the card where the standby process resides. The chassis-number argument represents the IRF member ID of the device. The slot-number argument represents the slot number of the card. (In IRF mode.)

Usage guidelines

If you do not specify any parameters, this command displays brief information about all BGP IPv4 unicast peers.

This command displays BGP IPv4 unicast peer or peer group information regardless of whether the unicast keyword is specified or not.

Examples

# Display brief information about all BGP IPv4 unicast peers for the public network.

<Sysname> display bgp peer ipv4

 

 BGP local router ID: 192.168.100.1

 Local AS number: 100

 Total number of peers: 1                  Peers in established state: 1

 

  Peer                    AS  MsgRcvd  MsgSent OutQ PrefRcv Up/Down  State

 

  10.2.1.2               200       13       16    0       0 00:10:34 Established

Table 69 Command output

Field

Description

Peer

IP address of the peer.

AS

AS number of the peer.

MsgRcvd

Number of messages received.

MsgSent

Number of messages sent.

OutQ

Number of messages to be sent.

PrefRcv

Number of prefixes received.

Up/Down

Lasting time of the current BGP session state.

State

Current state of the BGP session between the local router and the peer.

 

# Display detailed information about BGP IPv4 unicast peer 10.2.1.2 for the public network.

<Sysname> display bgp peer ipv4 10.2.1.2 verbose

 

         Peer: 10.2.1.2  Local: 192.168.100.1

         Type: EBGP link

         BGP version 4, remote router ID 192.168.100.2

         BGP current state: Established, Up for 00h11m10s

         BGP current event: RecvKeepalive

         BGP last state: OpenConfirm

         Port:  Local - 179      Remote - 60672

         Configured: Active Hold Time: 180 sec   Keepalive Time: 60 sec

         Received  : Active Hold Time: 180 sec

         Negotiated: Active Hold Time: 180 sec   Keepalive Time: 60 sec

         Peer optional capabilities:

         Peer support BGP multi-protocol extended

         Peer support BGP route refresh capability

         Peer support BGP route AS4 capability

         Address family IPv4 Unicast: advertised and received

 

 Received: Total 13 messages, Update messages 0

 Sent: Total 16 messages, Update messages 0

 Maximum allowed prefix number: 4294967295

 Threshold: 75%

 Minimum time between advertisements is 30 seconds

 Optional capabilities:

  Multi-protocol extended capability has been enabled

  Route refresh capability has been enabled

 Peer Preferred Value: 0

 GTSM has been enabled, and the maximum number of hops is 10

 BFD: Enabled

 

 Routing policy configured:

 No routing policy is configured

Table 70 Command output

Field

Description

 

Peer

IP address of the peer.

 

Local

Local router ID.

 

Type

BGP connection type between the local router and the peer:

·     IBGP linkIBGP connection.

·     EBGP linkEBGP connection.

 

remote router ID

Router ID of the peer.

 

BGP current state

Current state of the BGP session between the local router and the peer.

 

Up for

Lasting time of the BGP session.

 

BGP current event

Current event of the BGP session between the local router and the peer.

 

BGP last state

Previous state of the BGP session.

 

Port

TCP port numbers of the local router and its peer.

 

Configured

Timers configured on the local router in seconds, including the holdtime (Active Hold Time) and keepalive interval (Keepalive Time).

 

Received

Received timer (configured on the peer) in seconds, including the holdtime (Active Hold Time).

 

Negotiated

Negotiated timers in seconds, including the holdtime (Active Hold Time) and keepalive interval (Keepalive Time).

 

Peer optional capabilities

Optional capabilities supported by the peer.

 

Peer support BGP route AS4 capability

The peer supports 4-byte AS number.

 

Address family IPv4 Unicast

IPv4 unicast address family capability: Routes of the address family can be advertised and received.

 

Received

Total numbers of received messages and updates.

 

Sent

Total numbers of sent messages and updates.

 

Maximum allowed prefix number

Maximum number of routes allowed to learn from the peer.

 

Threshold

Percentage of received routes from the peer to maximum routes allowed to learn from the peer. If the percentage is reached, the system generates alarm messages.

 

Minimum time between advertisements

Minimum route advertisement interval in seconds.

 

Optional capabilities

Optional capabilities supported by the local end.

 

Peer Preferred Value

Preferred value specified for the routes from the peer.

 

GTSM has been enabled

GTSM is enabled for the local end.

the maximum number of hops

The maximum number of hops to the specified peer.

BFD

Whether BFD is enabled to detect the link to the BGP peer.

 

Routing policy configured

Routing policy configured for the peer.

If no routing policy is specified, this field displays No routing policy is configured.

 

 

# Display log information about BGP IPv4 unicast peer 1.1.1.1 for the public network.

<Sysname> display bgp peer ipv4 1.1.1.1 log-info

 

 Peer : 1.1.1.1

 

     Date      Time    State Notification

                             Error/SubError

 

  10-Jul-2008 15:46:17 Down  Send Notification with Error 1/1

                             Message Header Error/Connection Not Synchronized

  10-Jul-2008 09:23:00 Up   

  10-Jul-2008 07:46:17 Down  Receive Notification with Error 3/2

                             UPDATE Message Error/Unsupported optional Parameter

  10-Jul-2008 06:23:00 Up

  10-Jul-2008 05:46:17 Down  Send Notification with Error 6/4

                             Cease/Administrative Reset

Table 71 Command output

Field

Description

Peer

IP address of the peer.

Date

Date on which the Notification was sent or received.

Time

Time at which the Notification was sent or received.

State

BGP session state:

·     UpThe BGP session is in Established state.

·     DownThe BGP session is down.

Notification Error/SubError

Error code of the Notification, indicating the cause of why the BGP session is down.

·     Error—Refers to the error code, which identifies the type of the Notification.

·     SubError—Refers to the error subcode of the Notification, which identifies the specific information about the reported error.

 

display bgp routing-table dampened ipv4 unicast

Use display bgp routing-table dampened ipv4 unicast to display dampened BGP IPv4 unicast routes.

Syntax

display bgp routing-table dampened ipv4 [ unicast ] [ vpn-instance vpn-instance-name ]

Views

Any view

Predefined user roles

network-admin

network-operator

mdc-admin

mdc-operator

Parameters

vpn-instance vpn-instance-name: Specifies an MPLS L3VPN instance by its name, a case-sensitive string of 1 to 31 characters. If you do not specify a VPN instance, this command displays dampened BGP IPv4 unicast routes for the public network.

Usage guidelines

This command displays dampened BGP IPv4 unicast routes regardless of whether the unicast keyword is specified or not.

Examples

# Display dampened BGP IPv4 unicast routes.

<Sysname> display bgp routing-table dampened ipv4

 

 Total number of routes: 1

 

 BGP local router ID is 192.168.1.135

 Status codes: * - valid, > - best, d - dampened, h - history,

               s - suppressed, S - stale, i - internal, e - external

               Origin: i - IGP, e - EGP, ? - incomplete

 

     Network            From            Reuse                         Path/Ogn

 

  de 20.1.1.0/24        10.1.1.2        00:56:27                      100i

Table 72 Command output

Field

Description

Status codes

Status codes:

·     * – valid—Valid route.

·     > – best—Best route.

·     d – damped—Dampened route.

·     h – history—History route.

·     s – suppressed—Suppressed route.

·     S – Stale—Stale route.

·     i – internal—Internal route.

·     e – external—External route.

Origin

Origin of the route:

·     i – IGP—Originated in the AS. The origin of summary routes and routes advertised with the network command is IGP.

·     e – EGP—Learned through EGP.

·     ?– incomplete—Unknown origin. The origin of routes redistributed from IGP protocols is INCOMPLETE.

Network

Destination network address.

From

IP address from which the route was received.

Reuse

Reuse time of the route.

Path/Ogn

AS_PATH and ORIGIN attributes of the route:

·     AS_PATH attributeRecords the ASs the route has passed to avoid routing loops.

·     ORIGIN attribute—Identifies the origin of the route.

 

Related commands

·     dampening

·     reset bgp dampening ipv4 unicast

display bgp routing-table flap-info ipv4 unicast

Use display bgp routing-table flap-info ipv4 unicast to display BGP IPv4 unicast route flap statistics.

Syntax

display bgp routing-table flap-info ipv4 [ unicast ] [ vpn-instance vpn-instance-name ] [ network-address [ { mask | mask-length } [ longest-match ] ] | as-path-acl as-path-acl-number ]

Views

Any view

Predefined user roles

network-admin

network-operator

mdc-admin

mdc-operator

Parameters

vpn-instance vpn-instance-name: Specifies an MPLS L3VPN instance by its name, a case-sensitive string of 1 to 31 characters. If you do not specify a VPN instance, this command displays BGP IPv4 unicast route flap statistics for the public.

network-address: Specifies a destination network address.

mask: Specifies a network mask, in dotted decimal notation.

mask-length: Specifies a mask length in the range of 0 to 32.

longest-match: Displays the routing entries selected through the following steps:

1.     AND the specified network address with the specified mask.

2.     Display the route with the longest mask among the matching routes that have a mask shorter than or equal to the specified mask.

as-path-acl as-path-acl-number: Specifies an AS path list by its number in the range of 1 to 256 to filter BGP IPv4 unicast route flap statistics.

Usage guidelines

If the network-address, mask, and mask-length arguments are not specified, the command displays flap statistics of all BGP IPv4 unicast routes for the public network or the specified VPN.

If only the network-address argument is specified, the system ANDs the network address with the mask of a route. If the result matches the network address of the route, the command displays flap statistics of the route.

If the network-address mask or network-address mask-length argument is specified, and the longest-match keyword is not specified, the command displays flap statistics of the BGP IPv4 unicast route that matches both the specified destination network address and the mask (or mask length).

This command displays BGP IPv4 unicast route flap statistics regardless of whether the unicast keyword is specified or not.

Examples

# Display BGP IPv4 unicast route flap statistics for the public network.

<Sysname> display bgp routing-table flap-info ipv4

 

 Total number of routes: 1

 

 BGP local router ID is 192.168.1.135

 Status codes: * - valid, > - best, d - dampened, h - history,

               s - suppressed, S - stale, i - internal, e - external

               Origin: i - IGP, e - EGP, ? - incomplete

 

     Network            From            Flaps  Duration  Reuse        Path/Ogn

 

  de 20.1.1.0/24        10.1.1.2        1      00:02:36  00:53:58     100i

Table 73 Command output

Field

Description

Status codes

Status codes:

·     * – valid—Valid route.

·     > – best—Best route.

·     d – damped—Dampened route.

·     h – history—History route.

·     s – suppressed—Suppressed route.

·     S – Stale—Stale route.

·     i – internal—Internal route.

·     e – external—External route.

Origin

Origin of the route:

·     i – IGP—Originated in the AS. The origin of summary routes and routes advertised with the network command is IGP.

·     e – EGP—Learned through EGP.

·     ?– incomplete—Unknown origin. The origin of routes redistributed from IGP protocols is INCOMPLETE.

Network

Destination network address.

From

Source IP address of the route.

Flaps

Number of routing flaps.

Duration

Duration time of the flap route.

Reuse

Reuse time of the route.

Path/Ogn

AS_PATH and ORIGIN attributes of the route:

·     AS_PATH attribute—Records the ASs the route has passed to avoid routing loops.

·     ORIGIN attribute—Identifies the origin of the route.

 

Related commands

·     dampening

·     reset bgp flap-info ipv4 unicast

display bgp routing-table ipv4 unicast

Use display bgp routing-table ipv4 unicast to display BGP IPv4 unicast routing information.

Syntax

In standalone mode:

display bgp routing-table ipv4 [ unicast ] [ vpn-instance vpn-instance-name ] [ network-address [ { mask | mask-length } [ longest-match ] ] ] [ standby slot slot-number ]

In IRF mode:

display bgp routing-table ipv4 [ unicast ] [ vpn-instance vpn-instance-name ] [ network-address [ { mask | mask-length } [ longest-match ] ] ] [ standby chassis chassis-number slot slot-number ]

Views

Any view

Predefined user roles

network-admin

network-operator

mdc-admin

mdc-operator

Parameters

vpn-instance vpn-instance-name: Specifies an MPLS L3VPN instance by its name, a case-sensitive string of 1 to 31 characters. If you do not specify a VPN instance, this command displays the BGP IPv4 unicast routing information for the public network.

network-address: Specifies a destination network address.

mask: Specifies a network mask, in dotted decimal notation.

mask-length: Specifies a mask length in the range of 0 to 32.

slot slot-number: Specifies the slot number of the card where the standby process resides. (In standalone mode.)

chassis chassis-number slot slot-number: Specifies the card where the standby process resides. The chassis-number argument represents the IRF member ID of the device. The slot-number argument represents the slot number of the card. (In IRF mode.)

longest-match: Displays the routing entries selected through the following steps:

1.     AND the specified network address with the specified mask.

2.     Display the route with the longest mask among the matching routes that have a mask shorter than or equal to the specified mask.

Usage guidelines

If the network-address, mask, and mask-length arguments are not specified, the command displays brief information about all BGP IPv4 unicast routes.

If only the network-address argument is specified, the system ANDs the network address with the mask of a route. If the result matches the network address of the route, the command displays detailed information about the route.

If the network-address mask or network-address mask-length argument is specified and the longest-match keyword is not specified, the command displays detailed information about the BGP IPv4 unicast route that matches both the specified destination network address and the mask (or mask length).

This command displays BGP IPv4 unicast routing information regardless of whether the unicast keyword is specified or not.

Examples

# Display brief information about all BGP IPv4 unicast routes for the public network.

<Sysname> display bgp routing-table ipv4

 

 Total number of routes: 4

 

 BGP local router ID is 192.168.100.1

 Status codes: * - valid, > - best, d - damped, h - history,

               s - suppressed, S - Stale, i - internal, e - external

               Origin: i - IGP, e - EGP, ? - incomplete

 

     Network            NextHop         MED        LocPrf     PrefVal Path/Ogn

 

* >  10.2.1.0/24        10.2.1.1        0                     0       i

   e                    10.2.1.2        0                     0       200i

* >  192.168.1.0        192.168.1.135   0                     0       i

*  e                    10.2.1.2        0                     0       200i

Table 74 Command output

Field

Description

Status codes

Status codes:

·     * – valid—Valid route.

·     > – best—Best route.

·     d – damped—Dampened route.

·     h – history—History route.

·     s – suppressed—Suppressed route.

·     S – Stale—Stale route.

·     i – internal—Internal route.

·     e – external—External route.

Origin

Origin of the route:

·     i – IGP—Originated in the AS. The origin of summary routes and routes advertised with the network command is IGP.

·     e – EGP—Learned through EGP.

·     ?– incomplete—Unknown origin. The origin of routes redistributed from IGP protocols is INCOMPLETE.

Network

Destination network address.

NextHop

Next hop IP address.

MED

MULTI_EXIT_DISC attribute.

LocPrf

Local preference value.

PrefVal

Preferred value of the route.

Path/Ogn

AS_PATH and ORIGIN attributes of the route:

·     AS_PATHRecords the ASs the route has passed to avoid routing loops.

·     ORIGIN—Identifies the origin of the route.

 

# Display detailed information about BGP IPv4 unicast routes destined to network 10.2.1.0/24 for the public network.

<Sysname> display bgp routing-table ipv4 10.2.1.0 24

 

 BGP local router ID: 192.168.100.1

 Local AS number: 100

 

 Paths:   2 available, 1 best

 

 BGP routing table information of 10.2.1.0/24:

 Imported route.

 Original nexthop: 10.2.1.1

 OutLabel        : NULL

 AS-path         : (null)

 Origin          : igp

 Attribute value : MED 0, pref-val 0, pre 0

 State           : valid, local, best,

 

 From            : 10.2.1.2 (192.168.100.2)

 Relay nexthop   : not resolved

 Original nexthop: 10.2.1.2

 OutLabel        : NULL

 AS-path         : 200

 Origin          : igp

 Attribute value : MED 0, pref-val 0, pre 255

 State           : external,

Table 75 Command output

Field

Description

Paths

Number of routes:

·     available—Number of valid routes.

·     best—Number of optimal routes.

Original nexthop

Original next hop of the route. If the route is received from a BGP update message, the original next hop is the next hop IP address in the message.

OutLabel

Outgoing label of the route.

AS-path

AS_PATH attribute of the route, which records the ASs the route has passed to avoid routing loops.

Origin

Origin of the route:

·     igp—Originated in the AS. The origin of summary routes and routes advertised with the network command is IGP.

·     egp—Learned through EGP.

·     incomplete—Unknown origin. The origin of routes redistributed from IGP protocols is INCOMPLETE.

Attribute value

BGP path attributes:

·     MED—MED value.

·     localprefLocal preference value.

·     pref-valPreferred value.

·     pre—Route preference.

State

Current state of the route:

·     valid.

·     internal.

·     external.

·     local.

·     synchronize.

·     best.

From

IP address of BGP peer that advertised the route.

Relay Nexthop

Next hop found by route recursion. If no next hop is found, this field displays not resolved.

 

display bgp routing-table ipv4 unicast advertise-info

Use display bgp routing-table ipv4 unicast advertise-info to display advertisement information for BGP IPv4 unicast routes.

Syntax

In standalone mode:

display bgp routing-table ipv4 [ unicast ] [ vpn-instance vpn-instance-name ] network-address [ mask | mask-length ] advertise-info [ standby slot slot-number ]

In IRF mode:

display bgp routing-table ipv4 [ unicast ] [ vpn-instance vpn-instance-name ] network-address [ mask | mask-length ] advertise-info [ standby chassis chassis-number slot slot-number ]

Views

Any view

Predefined user roles

network-admin

network-operator

mdc-admin

mdc-operator

Parameters

vpn-instance vpn-instance-name: Specifies an MPLS L3VPN instance by its name, a case-sensitive string of 1 to 31 characters. If you do not specify a VPN instance, this command displays advertisement information of BGP IPv4 unicast routes for the public network.

network-address: Specifies a destination network address.

mask: Specifies a network mask, in dotted decimal notation.

mask-length: Specifies a mask length in the range of 0 to 32.

slot slot-number: Specifies the slot number of the card where the standby process resides. (In standalone mode.)

chassis chassis-number slot slot-number: Specifies the card where the standby process resides. The chassis-number argument represents the IRF member ID of the device. The slot-number argument represents the slot number of the card. (In IRF mode.)

Usage guidelines

If the mask and mask-length arguments are not specified, the system ANDs the specified network address with the mask of a route. If the result matches the network address of the route, the command displays advertisement information for the route.

If the mask or mask-length argument is specified, the command displays advertisement information for the BGP IPv4 unicast route that matches both the specified destination network address and the mask (or mask length).

This command displays advertisement information for BGP IPv4 unicast routes regardless of whether the unicast keyword is specified or not.

Examples

# Display advertisement information of BGP IPv4 unicast routes destined to network 10.2.1.0/24 for the public network.

<Sysname> display bgp routing-table ipv4 10.2.1.0 24 advertise-info

 

 BGP local router ID: 192.168.100.1

 Local AS number: 100

 

 Paths:   1 best

 

 BGP routing table information of 10.2.1.0/24:

 Advertised to peers (1 in total):

    10.2.1.2

Table 76 Command output

Field

Description

Paths

Number of optimal routes destined to the specified network.

BGP routing table information of 10.2.1.0/24

Advertisement information of BGP routes destined to network 10.2.1.0/24.

Advertised to peers (1 in total)

Peers to which the route has been advertised and the number of peers.

 

display bgp routing-table ipv4 unicast as-path-acl

Use display bgp routing-table ipv4 unicast as-path-acl to display BGP IPv4 unicast routes permitted by an AS path list.

Syntax

In standalone mode:

display bgp routing-table ipv4 [ unicast ] [ vpn-instance vpn-instance-name ] as-path-acl as-path-acl-number [ standby slot slot-number ]

In IRF mode:

display bgp routing-table ipv4 [ unicast ] [ vpn-instance vpn-instance-name ] as-path-acl as-path-acl-number [ standby chassis chassis-number slot slot-number ]

Views

Any view

Predefined user roles

network-admin

network-operator

mdc-admin

mdc-operator

Parameters

vpn-instance vpn-instance-name: Specifies an MPLS L3VPN instance by its name, a case-sensitive string of 1 to 31 characters. If you do not specify a VPN instance, this command displays BGP IPv4 unicast routes permitted by an AS path list for the public network.

as-path-acl-number: Specifies an AS path list by its number in the range of 1 to 256.

slot slot-number: Specifies the slot number of the card where the standby process resides. (In standalone mode.)

chassis chassis-number slot slot-number: Specifies the card where the standby process resides. The chassis-number argument represents the IRF member ID of the device. The slot-number argument represents the slot number of the card. (In IRF mode.)

Usage guidelines

This command displays BGP IPv4 unicast routes permitted by an AS path list regardless of whether the unicast keyword is specified or not.

Examples

# Display BGP routes permitted by AS path list 1.

<Sysname> display bgp routing-table ipv4 as-path-acl 1

 

 Total number of routes: 1

 

 BGP local router ID is 2.2.2.2

 Status codes: * - valid, > - best, d - dampened, h - history,

               s - suppressed, S - stale, i - internal, e - external

               Origin: i - IGP, e - EGP, ? - incomplete

 

     Network            NextHop         MED        LocPrf     PrefVal Path/Ogn

 

* >e 30.1.1.0/24        20.1.1.1                              0       200i

For command output, see Table 74.

Related commands

ip as-path

display bgp routing-table ipv4 unicast community-list

Use display bgp routing-table ipv4 unicast community-list to display BGP IPv4 unicast routing information matching the specified BGP community list.

Syntax

In standalone mode:

display bgp routing-table ipv4 [ unicast ] [ vpn-instance vpn-instance-name ] community-list { { basic-community-list-number | comm-list-name } [ whole-match ] | adv-community-list-number } [ standby slot slot-number ]

In IRF mode:

display bgp routing-table ipv4 [ unicast ] [ vpn-instance vpn-instance-name ] community-list { { basic-community-list-number | comm-list-name } [ whole-match ] | adv-community-list-number } [ standby chassis chassis-number slot slot-number ]

Views

Any view

Predefined user roles

network-admin

network-operator

mdc-admin

mdc-operator

Parameters

vpn-instance vpn-instance-name: Specifies an MPLS L3VPN instance by its name, a case-sensitive string of 1 to 31 characters. If you do not specify a VPN instance, this command displays BGP IPv4 unicast routing information matching the specified BGP community list for the public network.

basic-community-list-number: Specifies a basic community list by its number in the range of 1 to 99.

comm-list-name: Specifies a community list by its name, a string of 1 to 63 characters.

whole-match: Displays routes exactly matching the specified community list. Without this keyword, the command displays routes whose COMMUNITY attributes comprise the specified community list.

adv-community-list-number: Specifies an advanced community list by its number in the range of 100 to 199.

slot slot-number: Specifies the slot number of the card where the standby process resides. (In standalone mode.)

chassis chassis-number slot slot-number: Specifies the card where the standby process resides. The chassis-number argument represents the IRF member ID of the device. The slot-number argument represents the slot number of the card. (In IRF mode.)

Usage guidelines

This command displays BGP IPv4 unicast routing information matching the specified BGP community list regardless of whether the unicast keyword is specified or not.

Examples

# Display BGP routing information matching BGP community list 100.

<Sysname> display bgp routing-table ipv4 community-list 100

 

 Total number of routes: 1

 

 BGP local router ID is 2.2.2.2

 Status codes: * - valid, > - best, d - dampened, h - history,

               s - suppressed, S - stale, i - internal, e - external

               Origin: i - IGP, e - EGP, ? - incomplete

 

     Network            NextHop         MED        LocPrf     PrefVal Path/Ogn

 

* >e 30.1.1.0/24        20.1.1.1                              0       200i

For command output, see Table 74.

Related commands

ip community-list

display bgp routing-table ipv4 unicast peer

Use display bgp routing-table ipv4 unicast peer to display BGP IPv4 unicast routing information advertised to or received from a BGP peer.

Syntax

In standalone mode:

display bgp routing-table ipv4 [ unicast ] [ vpn-instance vpn-instance-name ] peer ip-address { advertised-routes | received-routes } [ network-address [ mask | mask-length ] | statistic ] [ standby slot slot-number ]

In IRF mode:

display bgp routing-table ipv4 [ unicast ] [ vpn-instance vpn-instance-name ] peer ip-address { advertised-routes | received-routes } [ network-address [ mask | mask-length ] | statistic ] [ standby chassis chassis-number slot slot-number ]

Views

Any view

Predefined user roles

network-admin

network-operator

mdc-admin

mdc-operator

Parameters

vpn-instance vpn-instance-name: Specifies an MPLS L3VPN instance by its name, a case-sensitive string of 1 to 31 characters. If you do not specify a VPN instance, this command displays BGP IPv4 unicast routing information advertised to or received from the specified BGP peer for the public network.

ip-address: Specifies a peer by its IP address.

advertised-routes: Displays routing information advertised to the specified peer.

received-routes: Displays routing information received from the specified peer.

network-address: Specifies the IP address of the destination network.

mask: Specifies the mask of the destination network, in dotted decimal notation.

mask-length: Specifies a mask length in the range of 0 to 32.

statistics: Displays route statistics.

slot slot-number: Specifies the slot number of the card where the standby process resides. (In standalone mode.)

chassis chassis-number slot slot-number: Specifies the card where the standby process resides. The chassis-number argument represents the IRF member ID of the device. The slot-number argument represents the slot number of the card. (In IRF mode.)

Usage guidelines

If the network-address, mask, and mask-length arguments are not specified, the command displays all BGP IPv4 unicast routing information advertised to or received from the specified BGP peer.

If only the network-address argument is specified, the system ANDs the network address with the mask of a route. If the result matches the network address of the route, the command displays information about the route.

If the network-address mask or network-address mask-length argument is specified, the command displays information about the route that matches both the specified destination network address and the mask (or mask length).

This command displays BGP IPv4 unicast routing information advertised to or received from a BGP peer regardless of whether the unicast keyword is specified or not.

Examples

# Display all BGP IPv4 unicast routing information advertised to BGP peer 10.2.1.2 for the public network.

<Sysname> display bgp routing-table ipv4 peer 10.2.1.2 advertised-routes

 

 Total number of routes: 2

 

 BGP local router ID is 192.168.100.1

 Status codes: * - valid, > - best, d - damped, h - history,

               s - suppressed, S - Stale, i - internal, e - external

               Origin: i - IGP, e - EGP, ? - incomplete

 

     Network            NextHop         MED        LocPrf     PrefVal Path/Ogn

 

* >  10.2.1.0/24        10.2.1.1        0                     0       i

* >  192.168.1.0        192.168.1.135   0                     0       i

# Display all BGP IPv4 unicast routing information received from BGP peer 10.2.1.2 for the public network.

<Sysname> display bgp routing-table ipv4 peer 10.2.1.2 received-routes

 

 Total number of routes: 2

 

 BGP local router ID is 192.168.100.1

 Status codes: * - valid, > - best, d - damped, h - history,

               s - suppressed, S - Stale, i - internal, e - external

               Origin: i - IGP, e - EGP, ? - incomplete

 

     Network            NextHop         MED        LocPrf     PrefVal Path/Ogn

 

   e 10.2.1.0/24        10.2.1.2        0                     0       200i

*  e 192.168.1.0        10.2.1.2        0                     0       200i

For command output, see Table 74.

# Display statistics of BGP IPv4 unicast routes advertised to BGP peer 10.2.1.2 for the public network.

<Sysname> display bgp routing-table ipv4 peer 10.2.1.2 advertised-routes statistics

 

 Advertised routes total: 2

# Display statistics of BGP IPv4 unicast routes received from BGP peer 10.2.1.2 for the public network.

<Sysname> display bgp routing-table ipv4 peer 10.2.1.2 received-routes statistics

 

 Received routes total: 2

Table 77 Command output

Field

Description

Advertised routes total

Total number of routes advertised to the specified peer.

Received routes total

Total number of routes received from the specified peer.

 

display bgp routing-table ipv4 unicast statistics

Use display bgp routing-table ipv4 unicast statistics to display BGP IPv4 unicast route statistics.

Syntax

In standalone mode:

display bgp routing-table ipv4 [ unicast ] [ vpn-instance vpn-instance-name ] statistic [ standby slot slot-number ]

In IRF mode:

display bgp routing-table ipv4 [ unicast ] [ vpn-instance vpn-instance-name ] statistic [ standby chassis chassis-number slot slot-number ]

Views

Any view

Predefined user roles

network-admin

network-operator

mdc-admin

mdc-operator

Parameters

vpn-instance vpn-instance-name: Specifies an MPLS L3VPN instance by its name, a case-sensitive string of 1 to 31 characters. If you do not specify a VPN instance, this command displays the BGP IPv4 unicast route statistics for the public network.

slot slot-number: Specifies the slot number of the card where the standby process resides. (In standalone mode.)

chassis chassis-number slot slot-number: Specifies the card where the standby process resides. The chassis-number argument represents the IRF member ID of the device. The slot-number argument represents the slot number of the card. (In IRF mode.)

Usage guidelines

This command displays BGP IPv4 unicast route statistics regardless of whether the unicast keyword is specified or not.

Examples

# Display statistics of BGP IPv4 unicast routes for the public network.

<Sysname> display bgp routing-table ipv4 statistics

 

 Total number of routes: 4

display bgp update-group

Use display bgp update-group to display BGP update group information.

Syntax

display bgp update-group ipv4 [ unicast ] [ vpn-instance vpn-instance-name ] [ ip-address ]

display bgp update-group vpnv4 [ vpn-instance vpn-instance-name ] [ ip-address ]

Views

Any view

Predefined user roles

network-admin

network-operator

mdc-admin

mdc-operator

Parameters

ipv4: Displays BGP update group information for IPv4 address family.

unicast: Displays BGP update group information for unicast address family. If you do not specify this keyword, the command also displays BGP update group information for unicast address family.

vpnv4: Displays BGP update group information for VPNv4 address family. This keyword is available in Release 1138P01 and later versions.

vpn-instance vpn-instance-name: Displays BGP update group information for the MPLS L3VPN instance specified by its name, a case-sensitive string of 1 to 31 characters. If you do not specify a VPN instance, this command displays BGP IPv4 unicast address family update group information for the public network.

ip-address: Displays BGP update group information for the specified BGP peer.

Usage guidelines

The update group feature classifies BGP peers that have the same export policy into an update group. When BGP advertises routes to the peers in the update group, it uses the export policy to filter the routes and generates route updates for all the peers only once.

With this feature, BGP performs one-time policy filtering and encapsulation for a prefix before advertising the prefix to all the peers in the update group. For example, BGP advertises 1000 prefixes to 1000 peers that have the same export policy (in data centers for example). Without the update group feature, BGP matches the export policy 1000 × 1000 times. With the update group feature, BGP matches the export policy only 1000 × 1 times, improving encapsulation efficiency 1000 times.

If no parameters are specified, this command displays all update groups for the public network.

This command displays information about BGP update groups for the BGP IPv4 unicast address family regardless of whether the unicast keyword is specified or not.

Examples

# Display information about all BGP update groups for the public network.

<Sysname> display bgp update-group ipv4

 

  Update-group ID: 0

  Type: EBGP link

  4-byte AS number: Supported

  Minimum time between advertisements: 30 seconds

  OutQ: 0

  Members: 1

    99.1.1.1

# Display update group information for the peer 1.1.1.2 in the public network.

<Sysname> display bgp update-group ipv4 1.1.1.2

 

  Update-group ID: 0

  Type: EBGP link

  4-byte AS number: Supported

  Minimum time between advertisements: 30 seconds

  OutQ: 0

  Members: 2

    1.1.1.2

    1.1.1.3

Table 78 Command output

Field

Description

Update-group ID

ID of the update group.

Type

BGP link type:

·     IBGP link.

·     EBGP link.

·     Confed IBGP linkConfederation IBGP link.

·     Confed EBGP link—Confederation EBGP link.

Label capability: Supported

The peers in the update group support labeled routes.

4-byte AS number: Supported

4-byte AS number suppression is disabled for the peers in the update group. The peers in the update group support 4-byte AS numbers.

4-byte AS number: Suppressed

4-byte AS number suppression is enabled for the peers in the update group.

Fake AS: number

A fake local AS number is configured for the peers in the update group.

Public-AS-Only: Yes

BGP route updates advertised to the peers in the update group only carry the public AS number without the private AS number. 

Substitute-AS: Yes

AS number substitution is enabled.

Minimum time between advertisements: number seconds

Minimum time between advertisements.

Advertising community: Yes

Community advertisement to peers in the update group is enabled.

Route-reflect client: Yes

The peer is a client of the route reflector.

Advertising extended community: Yes

Extended community advertisement to peers in the update group is enabled.

Export AS-path-ACL: as-path-acl-number

AS path ACL used to filter BGP routes advertised to peers in the update group.

Export prefix list: prefix-list-name

Prefix list used to filter BGP routes advertised to peers in the update group.

Export route policy: route-policy-name

Routing policy used to filter BGP routes advertised to peers in the update group.

Export filter-policy: ACL acl-number

ACL used to filter BGP routes advertised to peers in the update group.

OutQ

Number of prefixes to be advertised to peers in the update group.

Members

Number and IP addresses of peers in the update group.

 

ebgp-interface-sensitive

Use ebgp-interface-sensitive to enable quick re-establishment of direct EBGP sessions.

Use undo ebgp-interface-sensitive to disable the function.

Syntax

ebgp-interface-sensitive

undo ebgp-interface-sensitive

Default

Quick re-establishment of direct EBGP sessions is enabled.

Views

BGP view

Predefined user roles

network-admin

mdc-admin

Usage guidelines

This command enables BGP to quickly handle direct EBGP link failures. When a direct link to an EBGP peer fails, BGP tears down the session and re-establishes a session to the peer immediately. If the function is not enabled, the router does not tear down the session until the holdtime expires. However, disabling this function can prevent routing flaps from affecting EBGP session state.

This command applies only to direct EBGP sessions.

Examples

# Enable quick re-establishment of direct EBGP sessions.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] ebgp-interface-sensitive

fast-reroute route-policy

Use fast-reroute route-policy to reference a routing policy to specify a backup next hop for fast reroute (FRR) in BGP address family view.

Use undo fast-reroute route-policy to restore the default.

Syntax

fast-reroute route-policy route-policy-name

undo fast-reroute route-policy

Default

No routing policy is referenced for FRR.

Views

BGP IPv4 unicast address family view

Predefined user roles

network-admin

mdc-admin

Parameters

route-policy-name: Specifies a routing policy by its name, a case-sensitive string of 1 to 63 characters.

Usage guidelines

You can use the following methods to configure BGP FRR:

·     Method 1Execute the pic command in BGP address family view. BGP calculates a backup next hop for each BGP route in the address family if there are two or more unequal-cost routes to reach the destination.

·     Method 2Execute the fast-reroute route-policy command to reference a routing policy in which a backup next hop is specified by using the apply fast-reroute backup-nexthop command. The backup next hop calculated by BGP must be the same as the specified backup next hop. Otherwise, BGP does not generate a backup next hop for the primary route. You can also configure if-match clauses in the routing policy to identify the routes protected by FRR.

If both methods are configured, Method 2 takes precedence over Method 1.

Examples

# Reference the routing policy frr-policy to specify a backup next hop for FRR.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] address-family ipv4

[Sysname-bgp-ipv4] fast-reroute route-policy frr-policy

Related commands

·     apply fast-reroute

·     pic

·     route-policy

filter-policy export

Use filter-policy export to filter advertised BGP routes.

Use undo filter-policy export to remove the route filter.

Syntax

filter-policy { acl-number | prefix-list prefix-list-name } export [ protocol process-id ]

undo filter-policy export [ protocol process-id ]

Default

Advertised BGP routes are not filtered.

Views

BGP IPv4 unicast address family view, BGP-VPN IPv4 unicast address family view, BGP VPNv4 address family view

Predefined user roles

network-admin

mdc-admin

Parameters

acl-number: Specifies an IPv4 ACL by its number in the range of 2000 to 3999 to match routes by destination.

prefix-list prefix-list-name: Specifies an IPv4 prefix list by its name, a case-sensitive string of 1 to 63 characters, to match routes by destination.

protocol: Filters routes redistributed from the routing protocol.

process-id: Specifies a routing protocol by its ID in the range of 1 to 65535. In BGP IPv4 unicast address family view/BGP-VPN IPv4 unicast address family view, it is available only when the protocol is isis, ospf, or rip.

Usage guidelines

The BGP VPNv4 address family view is available in Release 1138P01 and later versions.

If a protocol is specified, this command filters only routes redistributed from the specified protocol. If no protocol is specified, this command filters all advertised routes, including routes redistributed from IGP, injected by the network command, and learned from BGP peers.

The following guidelines apply when you use an ACL in the command:

·     To filter routes with a specific destination address, use a basic ACL (2000 to 2999) or an advanced ACL that contain rules defined with the rule [ rule-id ] { deny | permit } ip source sour-addr sour-wildcard command.

·     To filter routes with a specific destination address and mask, use an advanced ACL that contains rules defined with the rule [ rule-id ] { deny | permit } ip source sour-addr sour-wildcard destination dest-addr dest-wildcard command.

·     If an ACL is used, BGP advertises only routes that match a permit rule in the ACL.

The sour-addr sour-wildcard argument combination matches the destination address of a route without matching the mask in the route.

The dest-addr dest-wildcard argument combination matches the subnet mask of the route without matching the destination address in the route. The dest-wildcard must be contiguous. Otherwise, the ACL rule does not take effect.

Examples

# In BGP IPv4 unicast address family view, use ACL 2000 to filter advertised BGP IPv4 routes.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] address-family ipv4 unicast

[Sysname-bgp-ipv4] filter-policy 2000 export

Related commands

·     filter-policy import

·     peer as-path-acl

·     peer filter-policy

·     peer prefix-list

·     peer route-policy

filter-policy import

Use filter-policy import to filter received BGP routes.

Use undo filter-policy import to remove the filter.

Syntax

filter-policy { acl-number | prefix-list prefix-list-name } import

undo filter-policy import

Default

Received BGP routes are not filtered.

Views

BGP IPv4 unicast address family view, BGP-VPN IPv4 unicast address family view, BGP VPNv4 address family view

Predefined user roles

network-admin

mdc-admin

Parameters

acl-number: Specifies an ACL by its number in the range of 2000 to 3999 to match routes by destination.

acl6-number: Specifies an ACL6 by its number in the range of 2000 to 3999 to match routes by destination.

prefix-list prefix-list-name: Specifies an IPv4 prefix list by its name, a case-sensitive string of 1 to 63 characters, to match routes by destination.

Usage guidelines

The BGP VPNv4 address family view is available in Release 1138P01 and later versions.

If you use a basic ACL (with a number from 2000 to 2999) configured with the rule [ rule-id ] { deny | permit } source source-address source-wildcard command, the command matches routes whose destination network addresses match the source-address source-wildcard argument without matching the masks of the destination addresses.

To use an advanced ACL (with a number from 3000 to 3999) in the command, configure the ACL using one of the following steps:

·     To deny/permit a route with the specified destination, use the rule [ rule-id ] { deny | permit } ip source sour-addr sour-wildcard command.

·     To deny/permit a route with the specified destination and mask, use the rule [ rule-id ] { deny | permit } ip source sour-addr sour-wildcard destination dest-addr dest-wildcard command.

The source keyword specifies the destination address of a route and the destination keyword specifies the subnet mask of the destination. The subnet mask must be contiguous. Otherwise, the configuration does not take effect.

Examples

# In BGP IPv4 unicast address family view, use ACL 2000 to filter received BGP routes.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] address-family ipv4 unicast

[Sysname-bgp-ipv4] filter-policy 2000 import

# Configure ACL 3000 to permit only route 113.0.0.0/16 to pass, and use ACL 3000 to filter received BGP routes.

<Sysname> system-view

[Sysname] acl number 3000

[Sysname-acl-adv-3000] rule 10 permit ip source 113.0.0.0 0 destination 255.255.0.0 0

[Sysname-acl-adv-3000] rule 100 deny ip

[Sysname-acl-adv-3000] quit

[Sysname] bgp 100

[Sysname-bgp] address-family ipv4 unicast

[Sysname-bgp-ipv4] filter-policy 3000 import

Related commands

·     filter-policy export

·     peer as-path-acl

·     peer filter-policy

·     peer prefix-list

·     peer route-policy

graceful-restart

Use graceful-restart to enable BGP Graceful Restart (GR) capability.

Use undo graceful-restart to disable BGP GR capability.

Syntax

graceful-restart

undo graceful-restart

Default

BGP GR capability is disabled.

Views

BGP view

Predefined user roles

network-admin

mdc-admin

Usage guidelines

GR ensures continuous forwarding when BGP restarts or an active/standby switchover occurs.

BGP peers exchange Open messages containing GR information. If both parties have GR capability, they establish a GR-capable session.

After you execute this command, the device re-establishes BGP sessions.

Examples

# Enable GR capability for BGP process 100.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] graceful-restart

Related commands

·     graceful-restart timer restart

·     graceful-restart timer wait-for-rib

graceful-restart timer purge-time

Use graceful-restart timer purge-time to set the Routing Information Base (RIB) purge timer.

Use undo graceful-restart timer purge-time to restore the default.

Syntax

graceful-restart timer purge-time timer

undo graceful-restart timer purge-time

Default

The RIB purge timer is 480 seconds.

Views

BGP view

Predefined user roles

network-admin

mdc-admin

Parameters

timer: Sets the RIB purge timer in the range of 1 to 6000 seconds.

Usage guidelines

BGP starts the RIB purge timer when an active/standby switchover occurs or BGP restarts. If BGP route exchange is not completed before the RIB purge timer expires, the GR restarter quits the GR process. It updates the RIB with the BGP routes already learned, and removes the stale routes from RIB.

Enable BGP GR before you execute this command.

Set the RIB purge timer to be long enough to complete GR, especially when large numbers of BGP routes exist.

As a best practice, set the RIB purge timer to be greater than the timer set by the graceful-restart timer wait-for-rib command and smaller than the timer set by the protocol lifetime command.

Examples

# Set the RIB purge timer to 300 seconds.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] graceful-restart

[Sysname-bgp] graceful-restart timer purge-time 300

Related commands

·     graceful-restart

·     graceful-restart timer restart

·     graceful-restart timer wait-for-rib

·     protocol lifetime

graceful-restart timer restart

Use graceful-restart timer restart to configure the GR timer.

Use undo graceful-restart timer restart to restore the default.

Syntax

graceful-restart timer restart timer

undo graceful-restart timer restart

Default

The GR timer is 150 seconds.

Views

BGP view

Predefined user roles

network-admin

mdc-admin

Parameters

timer: Specifies the GR time in the range of 3 to 600 seconds.

Usage guidelines

The GR restarter sends the GR timer to the GR helper in an Open message. When the GR helper detects that an active/standby switchover or a BGP restart occurs on the GR restarter, the GR helper marks all routes learned from the GR restarter as stale and starts the GR timer. If no BGP session is established before the GR timer expires, the GR helper removes the stale routes.

Before you configure this command, enable the BGP GR capability.

To apply a new GR timer, you must re-establish BGP sessions.

Examples

# Configure the GR timer as 300 seconds.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] graceful-restart

[Sysname-bgp] graceful-restart timer restart 300

Related commands

·     graceful-restart

·     graceful-restart timer purge-time

·     graceful-restart timer wait-for-rib

graceful-restart timer wait-for-rib

Use graceful-restart timer wait-for-rib to configure the time to wait for the End-of-RIB marker.

Use undo graceful-restart timer wait-for-rib to restore the default.

Syntax

graceful-restart timer wait-for-rib timer

undo graceful-restart timer wait-for-rib

Default

The time to wait for the End-of-RIB marker is 180 seconds.

Views

BGP view

Predefined user roles

network-admin

mdc-admin

Parameters

timer: Specifies the time to wait for the End-of-RIB marker, in the range of 3 to 3600 seconds.

Usage guidelines

BGP uses this timer to control the time to receive updates from the peer. The timer is not advertised to the peer.

After the GR restarter and GR helper re-establish a BGP session, they start this timer. If they do not complete route exchange before the timer expires, the GR restarter does not receive new routes but updates its routing table and forwarding table with learned BGP routes, and the GR helper removes the stale routes.

This command controls the routing convergence speed. A smaller timer value means faster routing convergence but possibly results in incomplete routing information.

Before configuring this command, you must enable the BGP GR capability.

Examples

# Set the time to wait for the End-of-RIB marker on the local end to 100 seconds.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] graceful-restart

[Sysname-bgp] graceful-restart timer wait-for-rib 100

Related commands

·     graceful-restart

·     graceful-restart timer purge-time

·     graceful-restart timer restart

group

Use group to create a peer group.

Use undo group to delete a peer group.

Syntax

group group-name [ external | internal ]

undo group group-name

Default

No peer group is created.

Views

BGP view, BGP-VPN instance view

Predefined user roles

network-admin

mdc-admin

Parameters

group-name: Specifies a name for the peer group, a case-sensitive string of 1 to 47 characters.

external: Creates an EBGP peer group.

internal: Creates an IBGP peer group.

Usage guidelines

In a large-scale network, many peers can use the same route selection policy. You can configure a peer group and add these peers into this group. In this way, peers can share the same policy as the peer group. When the policy of the group is modified, the modification also applies to peers in it.

If the internal or external keyword is not specified, the command creates an IBGP peer group.

If you perform configurations on a peer group and peers of the peer group, the last configuration takes effect.

After you create a peer group, you must use the peer enable command to enable BGP to exchange routing information with the specified peer group.

Examples

# In BGP view, create an EBGP peer group test with AS number 200, and add EBGP peers 10.1.1.1 and 10.1.2.1 into the group.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] group test external

[Sysname-bgp] peer test as-number 200

[Sysname-bgp] peer 10.1.1.1 group test

[Sysname-bgp] peer 10.1.2.1 group test

# In BGP-VPN instance view, create an EBGP peer group test with AS number 200, and add EBGP peers 10.1.1.1 and 10.1.2.1 into the group.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] ip vpn-instance vpn1

[Sysname-bgp-vpn1] group test external

[Sysname-bgp-vpn1] peer test as-number 200

[Sysname-bgp-vpn1] peer 10.1.1.1 group test

[Sysname-bgp-vpn1] peer 10.1.2.1 group test

# In BGP view, create an EBGP peer group test with AS number 200, and add EBGP peers 1::1 and 1::2 into the group.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] group test external

[Sysname-bgp] peer test as-number 200

[Sysname-bgp] peer 1::1 group test

[Sysname-bgp] peer 1::2 group test

# In BGP-VPN instance view, create an EBGP peer group test with AS number 200, and add EBGP peers 1::1 and 1::2 into the group.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] ip vpn-instance vpn1

[Sysname-bgp-vpn1] group test external

[Sysname-bgp-vpn1] peer test as-number 200

[Sysname-bgp-vpn1] peer 1::1 group test

[Sysname-bgp-vpn1] peer 1::2 group test

Related commands

·     display bgp group ipv4 unicast

·     peer enable

ignore-first-as

Use ignore-first-as to configure BGP to ignore the first AS number of EBGP route updates.

Use undo ignore-first-as to restore the default.

Syntax

ignore-first-as

undo ignore-first-as

Default

BGP checks the first AS number of a received EBGP route update. If the first AS number is not that of the BGP peer, the BGP router discards the route update.

Views

BGP view

Predefined user roles

network-admin

mdc-admin

Examples

# Configure BGP to ignore the first AS number of EBGP route updates.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] ignore-first-as

import-route

Use import-route to enable BGP to redistribute routes from an IGP protocol.

Use undo import-route to disable route redistribution from an IGP protocol.

Syntax

import-route protocol [ { process-id | all-processes } [ med med-value | route-policy route-policy-name ] * ]

undo import-route protocol [ process-id | all-processes ]

Default

BGP does not redistribute IGP routes.

Views

BGP IPv4 unicast address family view, BGP-VPN IPv4 unicast address family view

Predefined user roles

network-admin

mdc-admin

Parameters

protocol: Redistributes routes from an IGP protocol. In BGP IPv4 unicast address family view/BGP-VPN IPv4 unicast address family view, it can be direct, isis, ospf, rip, or static.

process-id: Specifies a process by its ID in the range of 1 to 65535. The default is 1. In BGP IPv4 unicast address family view/BGP-VPN IPv4 unicast address family view, it is available only when the protocol is isis, ospf, or rip.

all-processes: Redistributes routes from all the processes of the specified IGP protocol. This keyword takes effect only when the protocol is isis, ospf, or rip.

med med-value: Specifies a MED value for redistributed routes, in the range of 0 to 4294967295. If no MED is specified, the metric of a redistributed route is used as its MED.

route-policy route-policy-name: Specifies a routing policy by its name, a case-sensitive string of 1 to 63 characters, to filter redistributed routes or set route attributes for redistributed routes.

Usage guidelines

The import-route command cannot redistribute default IGP routes. To redistribute default IGP routes, use the default-route imported command together with the import-route command.

Only active routes can be redistributed. You can use the display ip routing-table protocol command to view route state information.

The ORIGIN attribute of routes redistributed by the import-route command is INCOMPLETE.

Examples

# In BGP IPv4 unicast address family view, redistribute routes from RIP process 1, and set the MED value for redistributed routes to 100.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] address-family ipv4 unicast

[Sysname-bgp-ipv4] import-route rip 1 med 100

# In BGP-VPN IPv4 unicast address family view, redistribute routes from RIP process 1, and reference a routing policy imprt to exclude route 1.1.1.0/24 from route redistribution.

<Sysname> system-view

[Sysname] ip prefix-list imprt deny 1.1.1.0 24

[Sysname] ip prefix-list imprt permit 0.0.0.0 0 less-equal 32

[Sysname] route-policy imprt permit node 0

[Sysname-route-policy-imprt-0] if-match ip address prefix-list imprt

[Sysname-route-policy-imprt-0] quit

[Sysname] bgp 100

[Sysname-bgp] ip vpn-instance vpn1

[Sysname-bgp-vpn1] address-family ipv4 unicast

[Sysname-bgp-ipv4-vpn1] import-route rip 1 route-policy imprt

Related commands

display ip routing-table protocol

ip vpn-instance (BGP view)

Use ip vpn-instance to enter BGP-VPN instance view.

Use undo ip vpn-instance to remove all configurations in BGP-VPN instance view.

Syntax

ip vpn-instance vpn-instance-name

undo ip vpn-instance vpn-instance-name

Views

BGP view

Predefined user roles

network-admin

mdc-admin

Parameters

vpn-instance-name: Specifies a VPN instance by its name, a case-sensitive string of 1 to 31 characters.

Usage guidelines

After you create a BGP peer in BGP-VPN instance view, the BGP routes learned from the peer are added into the routing table of the specified VPN instance.

This command and all commands in BGP-VPN instance view are typically executed on provider edge (PE) or Multi-VPN-Instance CE (MCE) devices to add routes learned from different sites into different VPN instances.

Before you execute this command, use the ip vpn-instance command to create the VPN instance in system view, and use the route-distinguisher command to configure a route distinguisher (RD) for the VPN instance.

Examples

# Enter BGP-VPN instance view of VPN instance vpn1.

<Sysname> system-view

[Sysname] ip vpn-instance vpn1

[Sysname-vpn-instance-vpn1] route-distinguisher 100:1

[Sysname-vpn-instance-vpn1] quit

[Sysname] bgp 100

[Sysname-bgp] ip vpn-instance vpn1

[Sysname-bgp-vpn1]

Related commands

·     ip vpn-instance (system-view) (MPLS Command Reference)

·     route-distinguisher (MPLS Command Reference)

log-peer-change

Use log-peer-change to enable logging for BGP session state changes.

Use undo log-peer-change to disable logging for BGP session state changes.

Syntax

log-peer-change

undo log-peer-change

Default

Logging for BGP session state changes is enabled.

Views

BGP view

Predefined user roles

network-admin

mdc-admin

Usage guidelines

After you execute the log-peer-change command, BGP logs session establishment and disconnection events. To view the log information, use the display bgp peer ipv4 unicast log-info command. The logs are sent to the information center of the device. The output rules of the logs (whether to output the logs and where to output) are determined by the information center configuration. For more information about information center configuration, see Network Management and Monitoring Configuration Guide.

If you disable the logging of BGP session state changes, BGP does not generate logs for session establishments and disconnections.

Examples

# Enable logging for session state changes globally.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] log-peer-change

Related commands

display bgp peer ipv4 unicast

log-route-flap

Use log-route-flap to enable logging for BGP route flapping.

Use undo log-route-flap to disable logging for BGP route flapping.

Syntax

log-route-flap monitor-time monitor-count [ log-count-limit | route-policy route-policy-name ] *

undo log-route-flap

Default

Logging for BGP route flapping is disabled.

Views

BGP IPv4 unicast address family view, BGP-VPN IPv4 unicast address family view, BGP VPNv4 address family view, BGP-VPN VPNv4 address family view

Predefined user roles

network-admin

mdc-admin

Parameters

monitor-time: Specifies the monitoring interval for route flapping, in the range of 1 to 600 minutes.

monitor-count: Specifies the number of route flaps for triggering a log, in the range of 2 to 8.

log-count-limit: Specifies the maximum number of logs allowed to be generated in a minute. The value range for this argument is 1 to 600, and the default value is 200.

route-policy route-policy-name: Specifies a routing policy by its name, a case-sensitive string of 1 to 63 characters.

Usage guidelines

This command is available in Release 1138P01 and later versions.

This feature enables BGP to generate logs for BGP route flappings that trigger log generation. The generated logs are sent to the information center. For the logs to be output correctly, you must also configure information center on the device. For more information about information center, see Network Management and Monitoring Configuration Guide.

This command is applicable only to incoming routes of the specified address family.

Examples

# In BGP IPv4 unicast address family view, enable logging for BGP route flapping. Set the monitoring interval to 10 minutes, the number of route flaps for triggering a log to 5, and the maximum number of allowed logs in a minute to 100.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] address-family ipv4 unicast

[Sysname-bgp-ipv4] log-route-flap 10 5 100

network

Use network to inject a network to the BGP routing table.

Use undo network to remove the configuration.

Syntax

network ip-address [ mask | mask-length ] [ route-policy route-policy-name ]

undo network ip-address [ mask | mask-length ]

Default

BGP does not advertise any local network.

Views

BGP IPv4 unicast address family view, BGP-VPN IPv4 unicast address family view

Predefined user roles

network-admin

mdc-admin

Parameters

ip-address: Specifies an IPv4 network address. If the mask or mask-length is not specified, natural mask is used.

mask: Specifies a mask in dotted decimal notation.

mask-length: Specifies a mask length in the range of 0 to 32.

prefix-length: Specifies a prefix length in the range of 0 to 128.

route-policy route-policy-name: Specifies a routing policy by its name, a case-sensitive string of 1 to 63 characters, to filter routes or set the route attributes.

Usage guidelines

The network to be injected must be available and active in the local IP routing table.

The ORIGIN attribute of the route injected with the network command is IGP.

When you execute the undo network command, you must specify the same mask or mask length/prefix length that you specified for the network command. Otherwise, the configuration cannot be removed.

Examples

# In BGP IPv4 unicast address family view, inject local network 10.0.0.0/16 to the BGP routing table.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] address-family ipv4 unicast

[Sysname-bgp-ipv4] network 10.0.0.0 255.255.0.0

# In BGP-VPN IPv4 unicast address family view, inject local network 10.0.0.0/16 to the BGP routing table.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] ip vpn-instance vpn1

[Sysname-bgp-vpn1] address-family ipv4 unicast

[Sysname-bgp-ipv4-vpn1] network 10.0.0.0 255.255.0.0

network short-cut

Use network short-cut to increase the preference for a received EBGP route. This EBGP route is called shortcut route.

Use undo network short-cut to cancel the configuration.

Syntax

network ip-address [ mask | mask-length ] short-cut

undo network ip-address [ mask | mask-length ] short-cut

Default

A received EBGP route has a preference of 255.

Views

BGP IPv4 unicast address family view, BGP-VPN IPv4 unicast address family view

Predefined user roles

network-admin

mdc-admin

Parameters

ip-address: Specifies an IPv4 network address. If the mask or mask-length is not specified, natural mask is used.

mask: Specifies a mask of the network address in dotted decimal notation.

mask-length: Specifies a mask length in the range of 0 to 32.

Usage guidelines

Different routing protocols might find different routes to the same destination. However, not all of those routes are optimal. For route selection, routing protocols, direct routes, and static routes are assigned different preferences. The route with the highest preference is preferred.

By default, the preference of an EBGP route is lower than a local route. If a device has an EBGP route and a local route to reach the same destination, the device does not select the EBGP route. You can use the network shortcut command to configure the EBGP route to have the same preference as the local route so the EBGP route is more likely to become the optimal route.

You can use the preference command to modify the preferences for external and local BGP routes.

Examples

# In BGP IPv4 unicast address family view, increase the preference of EBGP route 10.0.0.0/16.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] address-family ipv4 unicast

[Sysname-bgp-ipv4] network 10.0.0.0 255.255.0.0 short-cut

Related commands

preference

non-stop-routing

Use non-stop-routing to enable BGP nonstop routing (NSR).

Use undo non-stop-routing to disable BGP NSR.

Syntax

non-stop-routing

undo non-stop-routing

Default

BGP NSR is disabled.

Views

BGP view

Predefined user roles

network-admin

mdc-admin

Usage guidelines

BGP NSR ensures continuous routing by synchronizing BGP state and data information from the active BGP process to the standby BGP process. The standby BGP process can seamlessly take over all services when the active process fails.

Examples

# Enable BGP NSR.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] non-stop-routing

Related commands

display bgp non-stop-routing status

peer advertise-community

Use peer advertise-community to advertise the COMMUNITY attribute to a peer or peer group.

Use undo peer advertise-community to disable the COMMUNITY attribute advertisement to a peer or peer group.

Syntax

peer { group-name | ip-address [ mask-length ] } advertise-community

undo peer { group-name | ip-address [ mask-length ] } advertise-community

Default

No COMMUNITY attribute is advertised to any peer or peer group.

Views

BGP IPv4 unicast address family view, BGP-VPN IPv4 unicast address family view, BGP VPNv4 address family view

Predefined user roles

network-admin

mdc-admin

Parameters

group-name: Specifies a peer group by its name, a case-sensitive string of 1 to 47 characters. The peer group must have been created.

ip-address: Specifies a peer by its IP address. The peer must have been created.

mask-length: Specifies a mask length in the range of 0 to 32. You can use the ip-address and mask-length arguments together to specify a network. If you specify a network, this command advertises the COMMUNITY attribute to all dynamic peers in the network.

Usage guidelines

The BGP VPNv4 address family view is available in Release 1138P01 and later versions.

The COMMUNITY attribute is a group of specific data carried in update messages. A route can carry one or more COMMUNITY attribute values (each is represented by a 4-byte integer). The receiving router processes the route (for example, determining whether to advertise the route and the scope for advertising the route) based on the COMMUNITY attribute values.

After you execute the peer advertise-community command, routing updates advertised to the peer carry the COMMUNITY attribute.

After you execute the undo peer advertise-community command, BGP, upon receiving a route with the COMMUNITY attribute, removes the COMMUNITY attribute before sending the route to the peer or peer group.

Examples

# In BGP IPv4 unicast address family view, advertise the COMMUNITY attribute to peer group test.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] address-family ipv4 unicast

[Sysname-bgp-ipv4] peer test advertise-community

# In BGP-VPN IPv4 unicast address family view, advertise the COMMUNITY attribute to peer group test.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] ip vpn-instance vpn1

[Sysname-bgp-vpn1] address-family ipv4 unicast

[Sysname-bgp-ipv4-vpn1] peer test advertise-community

Related commands

·     apply community

·     if-match community

·     ip community-list

peer advertise-ext-community

Use peer advertise-ext-community to advertise the extended community attribute to a peer or peer group.

Use undo peer advertise-ext-community to disable the extended community attribute advertisement to a peer or peer group.

Syntax

peer { group-name | ip-address [ mask-length ] } advertise-ext-community

undo peer { group-name | ip-address [ mask-length ] } advertise-ext-community

Default

No extended community attribute is advertised to a peer or peer group.

Views

BGP IPv4 unicast address family view, BGP-VPN IPv4 unicast address family view

Predefined user roles

network-admin

mdc-admin

Parameters

group-name: Specifies a peer group by its name, a case-sensitive string of 1 to 47 characters. The peer group must have been created.

ip-address: Specifies a peer by its IP address. The peer must have been created.

mask-length: Specifies a mask length in the range of 0 to 32. You can use the ip-address and mask-length arguments together to specify a network. If you specify a network, this command advertises the extended community attribute to all dynamic peers in the network.

Usage guidelines

To meet increasing user demands, BGP defines a new attribute—extended community attribute. The extended community attribute has the following advantages over the COMMUNITY attribute:

·     The extended community attribute has an 8-byte length.

·     The extended community attribute supports various types. You can select an extended community attribute type as needed to implement route filtering and control. This simplifies configuration and management.

After you execute the peer advertise-ext-community command, route updates sent to the peer or peer group carry the extended community attribute.

After you execute the undo peer advertise-ext-community command, BGP, upon receiving a route with the extended community attribute, removes the extended community attribute before sending the route to the peer or peer group.

Examples

# In BGP IPv4 unicast address family view, advertise the extended community attribute to peer group test.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] address-family ipv4 unicast

[Sysname-bgp-ipv4] peer test advertise-ext-community

# In BGP-VPN IPv4 unicast address family view, advertise the extended community attribute to peer group test.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] ip vpn-instance vpn1

[Sysname-bgp-vpn1] address-family ipv4 unicast

[Sysname-bgp-ipv4-vpn1] peer test advertise-ext-community

Related commands

·     apply extcommunity

·     if-match extcommunity

·     ip extcommunity-list

peer allow-as-loop

Use peer allow-as-loop to allow a local AS number to exist in the AS_PATH attribute of routes from a peer or peer group, and to configure the number of times the local AS number can appear.

Use undo peer allow-as-loop to restore the default.

Syntax

peer { group-name | ip-address [ mask-length ] } allow-as-loop [ number ]

undo peer { group-name | ip-address [ mask-length ] } allow-as-loop

Default

The local AS number is not allowed to exist in the AS_PATH attribute of routes from a peer or peer group.

Views

BGP IPv4 unicast address family view, BGP-VPN IPv4 unicast address family view, BGP VPNv4 address family view

Predefined user roles

network-admin

mdc-admin

Parameters

group-name: Specifies a peer group by its name, a case-sensitive string of 1 to 47 characters. The peer group must have been created.

ip-address: Specifies a peer by its IP address. The peer must have been created.

mask-length: Specifies a mask length in the range of 0 to 32. You can use the ip-address and mask-length arguments together to specify a network. If you specify a network in this command, BGP allows a local AS number to exist in the AS_PATH attribute of routes from all dynamic peers in the network.

number: Specifies the number of times for which the local AS number can appear, in the range of 1 to 10. The default number is 1. If the number of times for which the local AS number appears in a route is more than the specified number, BGP considers that a routing loop occurs and discards the route.

Usage guidelines

The BGP VPNv4 address family view is available in Release 1138P01 and later versions.

By default, BGP does not receive routes that contain the local AS number in the AS_PATH attribute to avoid routing loops. However, in certain network environments , the AS_PATH attribute of a route from a peer must be allowed to contain the local AS number. Otherwise, the route cannot be advertised correctly.

Examples

# In BGP IPv4 unicast address family view, configure the number of times the local AS number can appear in AS_PATH attribute of routes from peer group test as 2.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] address-family ipv4 unicast

[Sysname-bgp-ipv4] peer test allow-as-loop 2

peer as-number (for a BGP peer group)

Use peer as-number to specify an AS number for a peer group.

Use undo peer as-number to delete the AS number of a peer group.

Syntax

peer group-name as-number as-number

undo peer group-name as-number

Default

No AS number is specified for a peer group.

Views

BGP view, BGP-VPN instance view

Predefined user roles

network-admin

mdc-admin

Parameters

group-name: Specifies a name for a peer group, a case-sensitive string of 1 to 47 characters. The peer group must have been created.

as-number: Specifies an AS number for a peer group, in the range of 1 to 4294967295.

Usage guidelines

This command applies only to a peer group with no peers in it.

When you specify an AS number for a peer group and want to add peers to it, make sure the AS number of the peers is the same as the peer group.

If you have specified no AS number for a peer group, peers added to it can use their own AS numbers.

Examples

# In BGP view, specify the AS number for peer group test as 100.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] peer test as-number 100

# In BGP-VPN instance view, specify the AS number for peer group test as 100.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] ip vpn-instance vpn1

[Sysname-bgp-vpn1] peer test as-number 100

Related commands

peer group

peer as-number (for a BGP peer)

Use peer as-number to create a BGP peer and specify its AS number.

Use undo peer to delete a BGP peer.

Syntax

peer ip-address [ mask-length ] as-number as-number

undo peer ip-address

Default

No BGP peer is created.

Views

BGP view, BGP-VPN instance view

Predefined user roles

network-admin

mdc-admin

Parameters

ip-address: Specifies the IP address of a peer.

mask-length: Specifies a mask length in the range of 0 to 32. You can use the ip-address and mask-length arguments together to specify a network. If you specify a network, this command enables BGP to establish dynamic peer relationships with all devices in the network.

as-number: Specifies an AS number for the peer, in the range of 1 to 4294967295. If the AS numbers of the peer and the local router are the same, the peer is an IBGP peer. If they are different, the peer is an EBGP peer.

Usage guidelines

You can also create a peer and add it to a peer group by using the peer group command.

To modify the AS number of a peer, do not execute the peer as-number command repeatedly. Instead, you must first delete the peer and configure it again.

After you create a peer, you must use the peer enable command to enable BGP to exchange routing information with the specified peer.

Examples

# In BGP view, create BGP peer 1.1.1.1 and specify its AS number as 100.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] peer 1.1.1.1 as-number 100

# In BGP-VPN instance view, create BGP peer 1::1 and specify its AS number as 100.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] ip vpn-instance vpn1

[Sysname-bgp-vpn1] peer 1::1 as-number 100

Related commands

·     display bgp peer ipv4 unicast

·     peer enable

·     peer group

peer as-path-acl

Use peer as-path-acl to specify an AS path list to filter routes incoming from or outgoing to a peer/peer group.

Use undo peer as-path-acl to remove the configuration.

Syntax

peer { group-name | ip-address [ mask-length ] } as-path-acl as-path-acl-number { export | import }

undo peer { group-name | ip-address [ mask-length ] } as-path-acl { export | import }

Default

No AS path list is specified for filtering.

Views

BGP IPv4 unicast address family view, BGP-VPN IPv4 unicast address family view, BGP VPNv4 address family view

Predefined user roles

network-admin

mdc-admin

Parameters

group-name: Specifies a peer group by its name, a case-sensitive string of 1 to 47 characters. The peer group must have been created.

ip-address: Specifies a peer by its IPv4 address. The peer must have been created.

mask-length: Specifies a mask length in the range of 0 to 32. You can use the ip-address and mask-length arguments together to specify a network. If you specify a network, this command specifies an AS path list to filter routes incoming from or outgoing to all dynamic peers in the network.

as-path-acl-number: Specifies an AS path list by its number in the range of 1 to 256.

export: Filters outgoing routes.

import: Filters incoming routes.

Usage guidelines

The BGP VPNv4 address family view is available in Release 1138P01 and later versions.

The specified AS path list must have been created with the ip as-path command in system view. Otherwise, all routes can pass the AS path list.

Examples

# In BGP IPv4 unicast address family view, specify the AS path list 1 to filter routes outgoing to the peer group test.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] address-family ipv4 unicast

[Sysname-bgp-ipv4] peer test as-path-acl 1 export

# In BGP-VPN IPv4 unicast address family view, specify the AS path list 1 to filter routes outgoing to the peer group test.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] ip vpn-instance vpn1

[Sysname-bgp-vpn1] address-family ipv4 unicast

[Sysname-bgp-ipv4-vpn1] peer test as-path-acl 1 export

Related commands

·     filter-policy export

·     filter-policy import

·     ip as-path

·     peer filter-policy

·     peer prefix-list

·     peer route-policy

peer bfd

Use peer bfd to enable BFD for the link to a BGP peer.

Use undo peer bfd to restore the default.

Syntax

peer ip-address [ mask-length ] bfd [ multi-hop | single-hop ]

undo peer ip-address bfd

Default

BFD is disabled.

Views

BGP view, BGP-VPN instance view

Predefined user roles

network-admin

mdc-admin

Parameters

ip-address: Specifies a peer by its IP address. The peer must have been created.

mask-length: Specifies a mask length in the range of 0 to 32. You can use the ip-address and mask-length arguments together to specify a network. If you specify a network, this command enables BFD for links to all dynamic peers in the network.

multi-hop: Enables multi-hop BFD.

single-hop: Enables single-hop BFD.

Usage guidelines

When neither the multi-hop keyword nor the single-hop keyword is specified:

·     If an IBGP peer is specified, this command enables multi-hop BFD for the IBGP peer.

·     If a directly connected EBGP peer is specified and the peer ebgp-max-hop command is not configured, this command enables single-hop BFD for the EBGP peer. If the EBGP peer is not directly connected or the peer ebgp-max-hop command is configured, this command enables multi-hop BFD for the EBGP peer.

For more information about multi-hop and single-hop BFD, see High Availability Configuration Guide.

BFD helps speed up BGP routing convergence upon link failures. However, if you have enabled GR, use BFD with caution because BFD might detect a failure before the system performs GR, resulting in GR failure. If you have enabled both BFD and GR for BGP, do not disable BFD during a GR process to avoid GR failure.

To establish a BFD session to a BGP peer, you must configure the same BFD detection mode multi-hop or single-hop on the local router and the BGP peer.

Examples

# In BGP view, enable BFD for the link to BGP peer 1.1.1.1.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] peer 1.1.1.1 bfd

# In BGP view, enable BFD for the link to BGP peer 1::1.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] peer 1::1 bfd

# In BGP-VPN instance view, enable BFD for the link to BGP peer 2.2.2.2.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] ip vpn-instance vpn1

[Sysname-bgp-vpn1] peer 2.2.2.2 bfd

# In BGP-VPN instance view, enable BFD for the link to BGP peer 2::2.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] ip vpn-instance vpn1

[Sysname-bgp-vpn1] peer 2::2 bfd

Related commands

·     display bgp peer ipv4 unicast

·     display bfd session (High Availability Command Reference)

peer capability-advertise conventional

Use peer capability-advertise conventional to disable BGP multi-protocol extension and route refresh for a peer or peer group.

Use undo peer capability-advertise conventional to enable BGP multi-protocol extension and route refresh for a peer or peer group.

Syntax

peer { group-name | ip-address [ mask-length ] } capability-advertise conventional

undo peer { group-name | ip-address [ mask-length ] } capability-advertise conventional

Default

BGP multi-protocol extension and route refresh are enabled.

Views

BGP view, BGP-VPN instance view

Predefined user roles

network-admin

mdc-admin

Parameters

group-name: Specifies a peer group by its name, a case-sensitive string of 1 to 47 characters. The peer group must have been created.

ip-address: Specifies a peer by its IP address. The peer must have been created.

mask-length: Specifies a mask length in the range of 0 to 32. You can use the ip-address and mask-length arguments together to specify a network. If you specify a network, this command disables BGP multi-protocol extension and route refresh for all dynamic peers in the network.

Usage guidelines

The route refresh function enables BGP to send and receive Route-refresh messages and implement BGP session soft-reset.

The multi-protocol extension function enables BGP to advertise and receive routing information for various protocols.

If both the peer capability-advertise conventional and peer capability-advertise route-refresh commands are executed, the last configuration takes effect.

Examples

# In BGP view, disable multi-protocol extension and route refresh for peer 1.1.1.1.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] peer 1.1.1.1 as-number 100

[Sysname-bgp] peer 1.1.1.1 capability-advertise conventional

# In BGP-VPN instance view, disable multi-protocol extension and route refresh for peer 1::1.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] ip vpn-instance vpn1

[Sysname-bgp-vpn1] peer 1::1 as-number 100

[Sysname-bgp-vpn1] peer 1::1 capability-advertise conventional

Related commands

·     display bgp peer ipv4 unicast

·     peer capability-advertise route-refresh

peer capability-advertise route-refresh

Use peer capability-advertise route-refresh to enable BGP route refresh for a peer or peer group.

Use undo peer capability-advertise route-refresh to disable the function.

Syntax

peer { group-name | ip-address [ mask-length ] } capability-advertise route-refresh

undo peer { group-name | ip-address [ mask-length ] } capability-advertise route-refresh

Default

BGP route refresh is enabled.

Views

BGP view, BGP-VPN instance view

Predefined user roles

network-admin

mdc-admin

Parameters

group-name: Specifies a peer group by its name, a case-sensitive string of 1 to 47 characters. The peer group must have been created.

ip-address: Specifies a peer by its IP address. The peer must have been created.

mask-length: Specifies a mask length in the range of 0 to 32. You can use the ip-address and mask-length arguments together to specify a network. If you specify a network, this command enables BGP route refresh for all dynamic peers in the network.

Usage guidelines

The route refresh function enables BGP to send and receive Route-refresh messages.

BGP uses the route refresh function to implement BGP session soft-reset. After a policy is modified, the router advertises a Route-refresh message to the peers. The peers resend their routing information to the router. After receiving the routing information, the router filters the routing information by using the new policy. This method allows you to refresh the BGP routing table and apply the new route selection policy without tearing down BGP sessions.

BGP route refresh requires that both the local router and the peer support route refresh.

If both the peer capability-advertise route-refresh and peer capability-advertise conventional commands are executed, the last configuration takes effect.

Examples

# In BGP view, enable BGP route refresh for peer 1.1.1.1.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] peer 1.1.1.1 as-number 100

[Sysname-bgp] peer 1.1.1.1 capability-advertise route-refresh

# In BGP-VPN instance view, enable BGP route refresh for peer 1::1.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] ip vpn-instance vpn1

[Sysname-bgp-vpn1] peer 1::1 as-number 200

[Sysname-bgp-vpn1] peer 1::1 capability-advertise route-refresh

Related commands

·     display bgp peer ipv4 unicast

·     peer capability-advertise conventional

·     peer keep-all-routes

·     refresh bgp ipv4 unicast

peer capability-advertise suppress-4-byte-as

Use peer capability-advertise suppress-4-byte-as to enable 4-byte AS number suppression.

Use undo peer capability-advertise suppress-4-byte-as to disable the function.

Syntax

peer { group-name | ip-address [ mask-length ] } capability-advertise suppress-4-byte-as

undo peer { group-name | ip-address [ mask-length ] } capability-advertise suppress-4-byte-as

Default

The 4-byte AS number suppression function is disabled.

Views

BGP view, BGP-VPN instance view

Predefined user roles

network-admin

mdc-admin

Parameters

group-name: Specifies a peer group by its name, a case-sensitive string of 1 to 47 characters. The peer group must have been created.

ip-address: Specifies a peer by its IP address. The peer must have been created.

mask-length: Specifies a mask length in the range of 0 to 32. You can use the ip-address and mask-length arguments together to specify a network. If you specify a network, this command enables 4-byte AS number suppression for all dynamic peers in the network.

Usage guidelines

BGP supports 4-byte AS numbers. The 4-byte AS number occupies four bytes, in the range of 1 to 4294967295. By default, a device sends an Open message to the peer device for session establishment. The Open message indicates that the device supports 4-byte AS numbers. If the peer device supports 2-byte AS numbers instead of 4-byte AS numbers, the session cannot be established. To resolve this issue, enable the 4-byte AS number suppression function. The device then sends an Open message to inform the peer that it does not support 4-byte AS numbers, so the BGP session can be established.

If the peer device supports 4-byte AS numbers, do not enable the 4-byte AS number suppression function. Otherwise, the BGP session cannot be established.

Examples

# In BGP view, enable 4-byte AS number suppression for peer 1.1.1.1.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] peer 1.1.1.1 as-number 100

[Sysname-bgp] peer 1.1.1.1 capability-advertise suppress-4-byte-as

# In BGP-VPN instance view, enable 4-byte AS number suppression for peer 1.1.1.1.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] ip vpn-instance vpn1

[Sysname-bgp-vpn1] peer 1.1.1.1 as-number 200

[Sysname-bgp-vpn1] peer 1.1.1.1 capability-advertise suppress-4-byte-as

Related commands

display bgp peer ipv4 unicast

peer connect-interface

Use peer connect-interface to specify a source interface (IP address) for establishing TCP connections to a peer or peer group.

Use undo peer connect-interface to restore the default.

Syntax

peer { group-name | ip-address [ mask-length ] } connect-interface interface-type interface-number

undo peer { group-name | ip-address [ mask-length ] } connect-interface

Default

BGP uses the output interface (IP address) of the best route destined for the BGP peer or peer group as the source interface for establishing a TCP connection to the peer or peer group.

Views

BGP view, BGP-VPN instance view

Predefined user roles

network-admin

mdc-admin

Parameters

group-name: Specifies a peer group by its name, a case-sensitive string of 1 to 47 characters. The peer group must have been created.

ip-address: Specifies a peer by its IP address. The peer must have been created.

mask-length: Specifies a mask length in the range of 0 to 32. You can use the ip-address and mask-length arguments together to specify a network. If you specify a network, this command specifies a source interface for establishing TCP connections to all dynamic peers in the network.

interface-type interface-number: Specifies an interface by its type and number.

Usage guidelines

If the peer's IP address belongs to an interface indirectly connected to the local router, specify that interface as the source interface for TCP connections on the peer. For example, interface A on the local end is directly connected to interface B on the peer. When you execute the peer x.x.x.x as-number as-number command on the local end to specify the BGP peer, and x.x.x.x is not the IP address of interface B, use the peer connect-interface command on the peer to specify the interface whose IP address is x.x.x.x as the source interface for establishing a TCP connection.

If a BGP router has multiple links to a peer, and the source interface fails, BGP has to re-establish TCP connections, causing network oscillation. As a best practice to improve link availability, use a loopback interface as the source interface.

To establish multiple BGP sessions between two routers, specify the source interface for establishing TCP connections to each peer on the local router. Otherwise, the local BGP router might fail to establish TCP connections to a peer when using the outbound interface of the best route to the peer as the source interface.

The source interfaces on the local router and the peer must be reachable.

To specify an indirectly connected interface (including loopback interfaces) on an EBGP peer as the source interface, use the peer ebgp-max-hop command to allow the establishment of an EBGP session to the indirectly connected peer.

If an interface has multiple IP addresses, use the primary IP address for establishing TCP connections.

Examples

# In BGP view, specify loopback 0 as the source interface for TCP connections to the peer group test.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] peer test connect-interface loopback 0

# In BGP-VPN instance view, specify loopback 0 as the source interface for TCP connections to the peer group test.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] ip vpn-instance vpn1

[Sysname-bgp-vpn1] peer test connect-interface loopback 0

Related commands

peer ebgp-max-hop

peer default-route-advertise

Use peer default-route-advertise to advertise a default route to a peer or peer group.

Use undo peer default-route-advertise to disable default route advertisement to a peer or peer group.

Syntax

In BGP IPv4 unicast address family view/BGP-VPN IPv4 unicast address family view:

peer { group-name | ip-address [ mask-length ] } default-route-advertise [ route-policy route-policy-name ]

undo peer { group-name | ip-address [ mask-length ] } default-route-advertise

In BGP VPNv4 address family view:

peer { group-name | ip-address } default-route-advertise vpn-instance vpn-instance-name

undo peer { group-name | ip-address [ mask-length ] } default-route-advertise vpn-instance vpn-instance-name

Default

No default route is advertised to a peer or peer group.

Views

BGP IPv4 unicast address family view, BGP-VPN IPv4 unicast address family view, BGP VPNv4 address family view

Predefined user roles

network-admin

mdc-admin

Parameters

group-name: Specifies a peer group by its name, a case-sensitive string of 1 to 47 characters. The peer group must have been created.

ip-address: Specifies a peer by its IP address. The peer must have been created.

mask-length: Specifies a mask length in the range of 0 to 32. You can use the ip-address and mask-length arguments together to specify a network. If you specify a network, this command advertises a default route to all dynamic peers in the network.

route-policy route-policy-name: Specifies a routing policy by its name, a case-sensitive string of 1 to 63 characters, to modify the route attribute.

vpn-instance vpn-instance-name: Specifies an MPLS L3VPN instance by its name, a case-sensitive string of 1 to 31 characters.

Usage guidelines

The BGP VPNv4 address family view is available in Release 1138P01 and later versions.

The peer default-route-advertise command enables the router to send a default route with the next hop being itself to the peer or peer group regardless of whether the default route exists in the routing table.

Examples

# In BGP IPv4 unicast address family view, advertise a default route to peer group test.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] address-family ipv4 unicast

[Sysname-bgp-ipv4] peer test default-route-advertise

# In BGP-VPN IPv4 unicast address family view, advertise a default route to peer group test.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] ip vpn-instance vpn1

[Sysname-bgp-vpn1] address-family ipv4 unicast

[Sysname-bgp-ipv4-vpn1] peer test default-route-advertise

peer description

Use peer description to configure a description for a peer or peer group.

Use undo peer description to remove the description for a peer or peer group.

Syntax

peer { group-name | ip-address [ mask-length ] } description description-text

undo peer { group-name | ip-address [ mask-length ] } description

Default

No description information is configured for a peer or peer group.

Views

BGP view, BGP-VPN instance view

Predefined user roles

network-admin

mdc-admin

Parameters

group-name: Specifies a peer group by its name, a case-sensitive string of 1 to 47 characters. The peer group must have been created.

ip-address: Specifies a peer by its IP address. The peer must have been created.

mask-length: Specifies a mask length in the range of 0 to 32. You can use the ip-address and mask-length arguments together to specify a network. If you specify a network, this command configures a description for all dynamic peers in the network.

description-text: Specifies a description for a peer or peer group, a case-sensitive string of 1 to 79 characters.

Examples

# In BGP view, configure a description for the peer group test as ISP1.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] peer test description ISP1

# In BGP-VPN instance view, configure a description for the peer group test as ISP1.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] ip vpn-instance vpn1

[Sysname-bgp-vpn1] peer test description ISP1

peer ebgp-max-hop

Use peer ebgp-max-hop to enable BGP to establish an EBGP session to an indirectly connected peer or peer group and specify the maximum hop count.

Use undo peer ebgp-max-hop to restore the default.

Syntax

peer { group-name | ip-address [ mask-length ] } ebgp-max-hop [ hop-count ]

undo peer { group-name | ip-address [ mask-length ] } ebgp-max-hop

Default

BGP does not establish an EBGP session to an indirectly connected peer or peer group.

Views

BGP view, BGP-VPN instance view

Predefined user roles

network-admin

mdc-admin

Parameters

group-name: Specifies a peer group by its name, a case-sensitive string of 1 to 47 characters. The peer group must have been created.

ip-address: Specifies a peer by its IP address. The peer must have been created.

mask-length: Specifies a mask length in the range of 0 to 32. You can use the ip-address and mask-length arguments together to specify a network. If you specify a network in this command, BGP establishes EBGP sessions to all indirectly connected dynamic peers in the network.

hop-count: Specifies the maximum number of hop counts, in the range of 1 to 255. The default is 64.

Usage guidelines

EBGP peers must be directly connected. If not, use the peer ebgp-max-hop command to establish an EBGP session over multiple hops between two peers.

If direct EBGP peers use indirectly connected interfaces (including loopback interfaces) to establish an EBGP session, you must perform the following tasks:

·     Configure a routing protocol to ensure that a route exists between the two interfaces.

·     Configure the peer ebgp-max-hop command to establish the session over multiple hops.

Examples

# In BGP view, enable BGP to establish EBGP sessions to an indirectly connected EBGP peer group test, and specify the maximum hop count as 64 (default).

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] peer test ebgp-max-hop

# In BGP-VPN instance view, enable BGP to establish EBGP sessions to an indirectly connected EBGP peer group test, and specify the maximum hop count as 64 (default).

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] ip vpn-instance vpn1

[Sysname-bgp-vpn1] peer test ebgp-max-hop

peer enable

Use peer enable to enable BGP to exchange routing information for an address family with a peer or peer group.

Use undo peer enable to disable BGP from exchanging routing information for an address family with a peer or peer group.

Syntax

peer { group-name | ip-address [ mask-length ] } enable

undo peer { group-name | ip-address [ mask-length ] } enable

Default

BGP cannot exchange routing information with a peer or peer group.

Views

BGP IPv4 unicast address family view, BGP-VPN IPv4 unicast address family view, BGP VPNv4 address family view, BGP-VPN VPNv4 address family view

Predefined user roles

network-admin

mdc-admin

Parameters

group-name: Specifies a peer group by its name, a case-sensitive string of 1 to 47 characters. The peer group must have been created.

ip-address: Specifies a peer by its IP address. The peer must have been created.

mask-length: Specifies a mask length in the range of 0 to 32. You can use the ip-address and mask-length arguments together to specify a network. If you specify a network in this command, BGP exchanges routing information for an address family with all dynamic peers in the network.

Usage guidelines

The BGP VPNv4 address family view and BGP-VPN VPNv4 address family view are available in Release 1138P01 and later versions.

Executing the peer enable command in different views enables BGP to exchange routing information for the corresponding address families with the specified peer.

·     In BGP IPv4 unicast address family view, the command enables the capability to exchange IPv4 unicast routing information, and adds the learned routes to the BGP routing table of the public network.

·     In BGP-VPN IPv4 unicast address family view, the command enables the capability to exchange IPv4 unicast routing information, and adds the learned routes to the BGP routing table of the specified VPN instance.

·     In BGP VPNv4 address family view, the command enables the capability to exchange VPNv4 routing information. In an MPLS L3VPN network, execute the command on PE devices in BGP VPNv4 address family view.

·     In BGP-VPN VPNv4 address family view, the command enables the capability to exchange VPNv4 routing information. In a nested VPN network, execute this command on ISP PE devices in BGP-VPN VPNv4 address family view to do the following:

¡     Enable the PE devices to exchange BGP VPNv4 routing information with ISP CEs.

¡     Add the VPNv4 routes learned by the PE devices to the routing table of the specified VPN instance.

The undo peer enable command disables BGP to exchange routing information for the corresponding address family with the peer.

Examples

# In BGP IPv4 unicast address family view, enable BGP to exchange IPv4 unicast routing information with peer 1.1.1.1.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] address-family ipv4 unicast

[Sysname-bgp-ipv4] peer 1.1.1.1 enable

# In BGP-VPN IPv4 unicast address family view, enable BGP to exchange IPv4 unicast routing information with peer 1.1.1.1.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] ip vpn-instance vpn1

[Sysname-bgp-vpn1] address-family ipv4 unicast

[Sysname-bgp-ipv4-vpn1] peer 1.1.1.1 enable

Related commands

display bgp peer ipv4 unicast

peer fake-as

Use peer fake-as to advertise a fake AS number to a peer or peer group.

Use undo peer fake-as to restore the default.

Syntax

peer { group-name | ip-address [ mask-length ] } fake-as as-number

undo peer { group-name | ip-address [ mask-length ] } fake-as

Default

No fake local AS number is advertised to a peer or peer group.

Views

BGP view, BGP-VPN instance view

Predefined user roles

network-admin

mdc-admin

Parameters

group-name: Specifies a peer group by its name, a case-sensitive string of 1 to 47 characters. The peer group must have been created.

ip-address: Specifies a peer by its IP address. The peer must have been created.

mask-length: Specifies a mask length in the range of 0 to 32. You can use the ip-address and mask-length arguments together to specify a network. If you specify a network, this command advertises a fake AS number to all dynamic peers in the network.

as-number: Specifies a fake AS number in the range of 1 to 4294967295.

Usage guidelines

After you move a BGP router from an AS to another AS (from AS 2 to AS 3 for example), you have to modify the AS number of the router on all its EBGP peers. To avoid such modifications, you can configure the router to advertise a fake AS number 2 to its EBGP peers so that the EBGP peers still think that Router A is in AS 2.

The peer fake-as command is only applicable to EBGP peers or peer groups.

If you execute the peer fake-as command on the local router, specify the local router's AS number on the peer as the fake local AS number specified in the command.

Examples

# In BGP view, advertise a fake AS number of 200 to the peer group test.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] peer test fake-as 200

# In BGP-VPN instance view, advertise a fake AS number of 200 to the peer group test.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] ip vpn-instance vpn1

[Sysname-bgp-vpn1] peer test fake-as 200

peer filter-policy

Use peer filter-policy to filter routes advertised to or received from a peer or peer group by using an ACL.

Use undo peer filter-policy to remove the configuration.

Syntax

peer { group-name | ip-address [ mask-length ] } filter-policy acl-number { export | import }

undo peer { group-name | ip-address [ mask-length ] } filter-policy { export | import }

Default

No ACL-based filtering is configured.

Views

BGP IPv4 unicast address family view, BGP-VPN IPv4 unicast address family view, BGP VPNv4 address family view

Predefined user roles

network-admin

mdc-admin

Parameters

group-name: Specifies a peer group by its name, a case-sensitive string of 1 to 47 characters. The peer group must have been created.

ip-address: Specifies a peer by its IP address. The peer must have been created.

mask-length: Specifies a mask length in the range of 0 to 32. You can use the ip-address and mask-length arguments together to specify a network. If you specify a network, this command filters routes advertised to or received from all dynamic peers in the network by using an ACL.

acl-number: Specifies an ACL by its number in the range of 2000 to 3999.

export: Filters routes advertised to the peer/peer group.

import: Filters routes received from the peer/peer group.

Usage guidelines

The BGP VPNv4 address family view is available in Release 1138P01 and later versions.

The specified ACL referenced by the peer filter-policy command must have been created with the acl command in system view. Otherwise, all routes can pass the ACL.

If you use a basic ACL (with a number from 2000 to 2999) configured with the rule [ rule-id ] { deny | permit } source source-address source-wildcard command, the command matches whose destination network addresses match the source-address source-wildcard argument without matching the masks of the destination addresses.

If you want to use an advanced ACL (with a number from 3000 to 3999) in the command, the ACL should be configured with the rule [ rule-id ] { deny | permit } ip source sour-addr sour-wildcard command to deny/permit a route with the specified destination, or with the rule [ rule-id ] { deny | permit } ip source sour-addr sour-wildcard destination dest-addr dest-wildcard command to deny/permit a route with the specified destination and mask. The source keyword specifies the destination address of a route and the destination keyword specifies the subnet mask of the destination. The subnet mask must be contiguous. Otherwise, the configuration does not take effect.

Examples

# In BGP IPv4 unicast address family view, apply ACL 2000 to filter routes advertised to the peer group test.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] address-family ipv4 unicast

[Sysname-bgp-ipv4] peer test filter-policy 2000 export

Related commands

·     acl (ACL and QoS Command Reference)

·     filter-policy export

·     filter-policy import

·     peer as-path-acl

·     peer prefix-list

·     peer route-policy

peer group

Use peer group to add a peer to a peer group.

Use undo peer group to delete a peer from a peer group.

Syntax

peer { ip-address [ mask-length ] } group group-name [ as-number as-number ]

undo peer { ip-address [ mask-length ] } group group-name

Default

No peer exists in a peer group.

Views

BGP view, BGP-VPN instance view

Predefined user roles

network-admin

mdc-admin

Parameters

ip-address: Specifies a peer by its IP address.

mask-length: Specifies a mask length in the range of 0 to 32. You can use the ip-address and mask-length arguments together to specify a network. If you specify a network, this command adds all dynamic peers in the network to a peer group.

group-name: Specifies a peer group by its name, a case-sensitive string of 1 to 47 characters. The peer group must have been created.

as-number as-number: Specifies an AS for a peer by its number in the range of 1 to 4294967295.

Usage guidelines

You can add a peer to a peer group in the following ways:

·     Use the peer as-number command to create a peer and specify its AS number, and then use the peer group command to add the peer to the peer group.

¡     You can specify the as-number keyword for the peer group command. The AS number must be the same as the AS number specified in the peer as-number command.

¡     If you have specified the AS number of the peer group with the peer as-number command, the peer to be added must have the same AS number as the peer group.

¡     To add a peer to an IBGP peer group, the peer must be an IBGP peer.

·     Use the peer group command to create a peer and add it to the peer group.

¡     If you have specified the AS number of the peer group with the peer as-number command, you do not need to specify the as-number keyword when you execute the peer group command, because the AS number of the peer is the same as the peer group. To specify the as-number keyword for the peer group command, make sure that the AS number is the same as the peer group.

¡     If no AS number is specified for an EBGP peer group, specify the as-number keyword when you execute the peer group command.

¡     If no AS number is specified for an IBGP peer group, you do not need to specify the as-number keyword when you execute the peer group command, because the AS number of the IBGP peer group is the local AS number. To specify the as-number keyword for the peer group command, make sure that the AS number is the same as the local AS number.

If you have specified the AS number of a peer group with the peer as-number command, only the peers with the same AS number can be added to the peer group. All peers in the group share the same AS number. If you have not specified the AS number for a peer group, peers added to it can use their own AS numbers.

After you add a peer to a peer group, you must use the peer enable command to enable BGP to exchange routing information with the peer group.

Examples

# In BGP view, add peer 10.1.1.1 to the EBGP peer group test.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] group test external

[Sysname-bgp] peer 10.1.1.1 group test as-number 2004

# In BGP-VPN instance view, add peer 10.1.1.1 to the EBGP peer group test.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] ip vpn-instance vpn1

[Sysname-bgp-vpn1] group test external

[Sysname-bgp-vpn1] peer 10.1.1.1 group test as-number 2004

Related commands

·     group

·     peer as-number

·     peer enable

peer ignore

Use peer ignore to disable BGP session establishment with a peer or peer group.

Use undo peer ignore to restore the default.

Syntax

peer { group-name | ip-address [ mask-length ] } ignore

undo peer { group-name | ip-address [ mask-length ] } ignore

Default

BGP can establish a session to a peer or peer group.

Views

BGP view, BGP-VPN instance view

Predefined user roles

network-admin

mdc-admin

Parameters

group-name: Specifies a peer group by its name, a case-sensitive string of 1 to 47 characters. The peer group must have been created.

ip-address: Specifies a peer by its IP address. The peer must have been created.

mask-length: Specifies a mask length in the range of 0 to 32. You can use the ip-address and mask-length arguments together to specify a network. If you specify a network in this command, BGP tears down sessions to all dynamic peers in the network.

Usage guidelines

This command enables you to temporarily tear down the BGP session to a specific peer or peer group so that you can perform network upgrade and maintenance without needing to delete and reconfigure the peer or peer group. To recover the session, execute the undo peer ignore command.

If a session has been established to a peer, executing the peer ignore command for the peer tears down the session and clears all related routing information.

If sessions have been established to a peer group, executing the peer ignore command for the peer group disables the sessions to all peers in the group and clears all related routing information.

Examples

# In BGP view, disable session establishment with peer 1.1.1.1.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] peer 1.1.1.1 ignore

# In BGP-VPN instance view, disable session establishment with peer 1::1.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] ip vpn-instance vpn1

[Sysname-bgp-vpn1] peer 1::1 ignore

peer ignore-originatorid

Use peer ignore-originatorid to configure BGP to ignore the ORIGINATOR_ID attribute in BGP route updates.

Use undo peer ignore-originatorid to restore the default.

Syntax

peer { group-name | ip-address [ mask-length ] } ignore-originatorid

undo peer { group-name | ip-address [ mask-length ] } ignore-originatorid

Default

BGP does not ignore the ORIGINATOR_ID attribute in BGP route updates.

Views

BGP view, BGP-VPN instance view

Predefined user roles

network-admin

mdc-admin

Parameters

group-name: Specifies a peer group by its name, a case-sensitive string of 1 to 47 characters.

ip-address: Specifies a peer by its IP address.

mask-length: Specifies a mask length in the range of 0 to 32. You can use the ip-address and mask-length arguments together to specify a network. If you specify a network in this command, BGP ignores the ORIGINATOR_ID attribute in BGP route updates from all dynamic peers in the network.

Usage guidelines

A router is configured with a router ID. When a router receives a BGP route update, it compares the router ID with the ORIGINATOR_ID attribute in the route update. If they are the same, the router drops the route update to avoid routing loops. However, for some networks (such as firewall networks) to operate correctly, BGP must not drop but accept such route updates. For BGP to accept such route updates, you must configure BGP to ignore the ORIGINATOR_ID attribute in BGP route updates.

Ignoring the ORIGINATOR_ID attribute might introduce routing loops to the network. Do not use this command if you are not sure there are no routing loops.

After you execute this command, BGP also ignores the CLUSTER_LIST attribute.

Examples

# In BGP view, configure BGP to ignore the ORIGINATOR_ID attribute in BGP route updates from the peer 1.1.1.1.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] peer 1.1.1.1 ignore-originatorid

# In BGP VPN instance view, configure BGP to ignore the ORIGINATOR_ID attribute in BGP route updates from the peer 1.1.1.1.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] ip vpn-instance vpn1

[Sysname-bgp-vpn1] peer 1::1 ignore-originatorid

peer keep-all-routes

Use peer keep-all-routes to save all route updates from a peer or peer group, regardless of whether the routes have passed the configured routing policy.

Use undo peer keep-all-routes to restore the default.

Syntax

peer { group-name | ip-address [ mask-length ] } keep-all-routes

undo peer { group-name | ip-address [ mask-length ] } keep-all-routes

Default

Route updates from a peer or peer group are not saved.

Views

BGP IPv4 unicast address family view, BGP-VPN IPv4 unicast address family view, BGP VPNv4 address family view

Predefined user roles

network-admin

mdc-admin

Parameters

group-name: Specifies a peer group by its name, a case-sensitive string of 1 to 47 characters. The peer group must have been created.

ip-address: Specifies a peer by its IP address. The peer must have been created.

mask-length: Specifies a mask length in the range of 0 to 32. You can use the ip-address and mask-length arguments together to specify a network. If you specify a network, this command saves all route updates from all dynamic peers in the network, regardless of whether the routes have passed the configured routing policy.

Usage guidelines

The BGP VPNv4 address family view is available in Release 1138P01 and later versions.

To implement BGP session soft-reset when the local router and a peer or peer group do not support the route refresh function, use the peer keep-all-routes command to save all route updates received from the peer or peer group. After modifying the route selection policy, filter all saved routes with the new policy to refresh the routing table. This method avoids tearing down BGP sessions.

Examples

# In BGP IPv4 unicast address family view, save all route updates from peer 1.1.1.1.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] address-family ipv4 unicast

[Sysname-bgp-ipv4] peer 1.1.1.1 keep-all-routes

# In BGP-VPN IPv4 unicast address family view, save all route updates from peer 1.1.1.1.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] ip vpn-instance vpn1

[Sysname-bgp-vpn1] address-family ipv4 unicast

[Sysname-bgp-ipv4-vpn1] peer 1.1.1.1 keep-all-routes

Related commands

·     peer capability-advertise route-refresh

·     refresh bgp ipv4 unicast

peer low-memory-exempt

Use peer low-memory-exempt to configure BGP to protect EBGP peer or peer group when the memory usage reaches level 2 threshold.

Use undo peer low-memory-exempt to restore the default.

Syntax

peer { group-name | ip-address [ mask-length ] } low-memory-exempt

undo peer { group-name | ip-address [ mask-length ] } low-memory-exempt

Default

When the memory usage reaches level 2 threshold, BGP tears down an EBGP session to release memory resources periodically.

Views

BGP view, BGP-VPN instance view

Predefined user roles

network-admin

mdc-admin

Parameters

group-name: Specifies a peer group by its name, a case-sensitive string of 1 to 47 characters. The peer group must have been created.

ip-address: Specifies a peer by its IP address. The peer must have been created.

mask-length: Specifies a mask length in the range of 0 to 32. You can use the ip-address and mask-length arguments together to specify a network. If you specify a network in this command, BGP protects all dynamic peers in the network when the memory usage reaches level 2 threshold.

Usage guidelines

Memory usage includes the following levels of thresholds: normal, level 1, level 2, and level 3. When level 2 threshold is reached, BGP tears down an EBGP session to release memory resources periodically until the memory usage is exempt from level 2 threshold. You can use this command to avoid tearing down the BGP session with a specific EBGP peer when memory usage reaches level 2 threshold.

For more information about thresholds, see Fundamentals Configuration Guide.

Examples

# In BGP view, configure BGP to protect EBGP peer 1.1.1.1 when the memory usage reaches level 2 threshold.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] peer 1.1.1.1 as-number 200

[Sysname-bgp] peer 1.1.1.1 low-memory-exempt

# In BGP-VPN instance view, configure BGP to protect EBGP peer 1.1.1.1 when the memory usage reaches level 2 threshold.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] ip vpn-instance vpn1

[Sysname-bgp-vpn1] peer 1.1.1.1 as-number 200

[Sysname-bgp-vpn1] peer 1.1.1.1 low-memory-exempt

peer next-hop-local

Use peer next-hop-local to set the local router as the next hop for routes sent to a peer or peer group.

Use undo peer next-hop-local to restore the default.

Syntax

peer { group-name | ip-address [ mask-length ] } next-hop-local

undo peer { group-name | ip-address [ mask-length ] } next-hop-local

Default

BGP sets the local router as the next hop for all routes sent to an EBGP peer or peer group.

BGP does not set the local router as the next hop for EBGP routes sent to an IBGP peer or peer group.

Views

BGP IPv4 unicast address family view, BGP-VPN IPv4 unicast address family view, BGP VPNv4 address family view

Predefined user roles

network-admin

mdc-admin

Parameters

group-name: Specifies a peer group by its name, a case-sensitive string of 1 to 47 characters. The peer group must have been created.

ip-address: Specifies a peer by its IP address. The peer must have been created.

mask-length: Specifies a mask length in the range of 0 to 32. You can use the ip-address and mask-length arguments together to specify a network. If you specify a network, this command sets the local router as the next hop for routes sent to all dynamic peers in the network.

Usage guidelines

The BGP VPNv4 address family view is available in Release 1138P01 and later versions.

To ensure that an IBGP peer can find the next hop, use this command to specify the router as the next hop for routes sent to the IBGP peer.

Examples

# In BGP IPv4 unicast address family view, specify the router as the next hop for routes sent to peer group test.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] address-family ipv4 unicast

[Sysname-bgp-ipv4] peer test next-hop-local

# In BGP-VPN IPv4 unicast address family view, specify the router as the next hop for routes sent to peer group test.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] ip vpn-instance vpn1

[Sysname-bgp-vpn1] address-family ipv4 unicast

[Sysname-bgp-ipv4-vpn1] peer test next-hop-local

peer password

Use peer password to enable MD5 authentication for a BGP peer or peer group.

Use undo peer password to remove MD5 authentication for the BGP peer or peer group.

Syntax

peer { group-name | ip-address [ mask-length ] } password { cipher | simple } password

undo peer { group-name | ip-address [ mask-length ] } password

Default

MD5 authentication is disabled.

Views

BGP view, BGP-VPN instance view

Predefined user roles

network-admin

mdc-admin

Parameters

group-name: Specifies a peer group by its name, a case-sensitive string of 1 to 47 characters. The peer group must have been created.

ip-address: Specifies a peer by its IP address. The peer must have been created.

mask-length: Specifies a mask length in the range of 0 to 32. You can use the ip-address and mask-length arguments together to specify a network. If you specify a network, this command enables MD5 authentication for all dynamic peers in the network.

cipher: Sets a ciphertext password.

simple: Sets a plaintext password.

password: Specifies a password, a case-sensitive string of 33 to 137 characters in cipher text, or 1 to 80 characters in plain text.

Usage guidelines

You can enable MD5 authentication to enhance security using the following methods:

·     Perform MD5 authentication when establishing TCP connections. Only the two parties that have the same password configured can establish TCP connections.

·     Perform MD5 calculation on TCP segments to avoid modification to the encapsulated BGP packets.

For security purposes, all passwords, including passwords configured in plain text, are saved in cipher text.

Examples

# In BGP view, perform MD5 authentication on the TCP connection between the local router 10.1.100.1 and the peer router 10.1.100.2, and set the plaintext authentication password to aabbcc.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] peer 10.1.100.2 password simple aabbcc

# Perform similar configuration on the peer.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] peer 10.1.100.1 password simple aabbcc

# In BGP-VPN instance view, perform MD5 authentication on the TCP connection between the local router 10.1.100.1 and the peer router 10.1.100.2, and set the plaintext authentication password to aabbcc.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] ip vpn-instance vpn1

[Sysname-bgp-vpn1] peer 10.1.100.2 password simple aabbcc

# Perform similar configuration on the peer.

<Sysname> system-view

[Sysname] bgp 200

[Sysname-bgp] ip vpn-instance vpn1

[Sysname-bgp-vpn1] peer 10.1.100.1 password simple aabbcc

peer preferred-value

Use peer preferred-value to specify a preferred value for routes received from a peer or peer group.

Use undo peer preferred-value to restore the default.

Syntax

peer { group-name | ip-address [ mask-length ] } preferred-value value

undo peer { group-name | ip-address [ mask-length ] } preferred-value

Default

The preferred value is 0.

Views

BGP IPv4 unicast address family view, BGP-VPN IPv4 unicast address family view, BGP VPNv4 address family view

Predefined user roles

network-admin

mdc-admin

Parameters

group-name: Specifies a peer group by its name, a case-sensitive string of 1 to 47 characters. The peer group must have been created.

ip-address: Specifies a peer by its IP address. The peer must have been created.

mask-length: Specifies a mask length in the range of 0 to 32. You can use the ip-address and mask-length arguments together to specify a network. If you specify a network, this command specifies a preferred value for routes received from all dynamic peers in the network.

value: Specifies the preferred value in the range of 0 to 65535.

Usage guidelines

The BGP VPNv4 address family view is available in Release 1138P01 and later versions.

If multiple routes that have the same destination are learned from different peers, you can specify different preferred values for the routes as needed to control BGP path selection. The one with the greatest preferred value is selected as the optimal route to the destination.

The preferred value is used for route selection on the local router and is not advertised to the peer. It has only local significance.

You can also use the apply preferred-value command in a routing policy to configure the preferred value for BGP routes. If both the peer preferred-value and apply preferred-value commands are configured, the apply preferred-value command applies. If the preferred value is not set in the routing policy or no routing policy is configured, the peer preferred-value command applies.

Examples

# In BGP IPv4 unicast address family view, specify the preferred value as 50 for routes from peer 1.1.1.1.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] address-family ipv4 unicast

[Sysname-bgp-ipv4] peer 1.1.1.1 preferred-value 50

Related commands

·     apply preferred-value

·     route-policy

peer prefix-list

Use peer prefix-list to reference a prefix list to filter routes received from or advertised to a peer or peer group.

Use undo peer prefix-list to remove the configuration.

Syntax

peer { group-name | ip-address [ mask-length ] } prefix-list prefix-list-name { export | import }

undo peer { group-name | ip-address [ mask-length ] } prefix-list { export | import }

Default

No prefix list based filtering is configured.

Views

BGP IPv4 unicast address family view, BGP-VPN IPv4 unicast address family view, BGP VPNv4 address family view

Predefined user roles

network-admin

mdc-admin

Parameters

group-name: Specifies a peer group by its name, a case-sensitive string of 1 to 47 characters. The peer group must have been created.

ip-address: Specifies a peer by its IPv4 address. The peer must have been created.

mask-length: Specifies a mask length in the range of 0 to 32. You can use the ip-address and mask-length arguments together to specify a network. If you specify a network, this command references a prefix list to filter routes received from or advertised to all dynamic peers in the network.

prefix-list-name: Specifies an IPv4 prefix list by its name, a case-sensitive string of 1 to 63 characters.

export: Applies the filter to routes advertised to the specified peer/peer group.

import: Applies the filter to routes received from the specified peer/peer group.

Usage guidelines

The BGP VPNv4 address family view is available in Release 1138P01 and later versions.

The specified IPv4 prefix list must have been created with the ip prefix-list command in system view. Otherwise, all routes can pass the IPv4 prefix list.

Examples

# In BGP IPv4 unicast address family view, use the IPv4 prefix list list1 to filter routes advertised to the peer group test.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] address-family ipv4 unicast

[Sysname-bgp-ipv4] peer test prefix-list list1 export

Related commands

·     filter-policy export

·     filter-policy import

·     ip prefix-list

·     peer as-path-acl

·     peer filter-policy

·     peer route-policy

peer public-as-only

Use peer public-as-only to remove private AS numbers in BGP updates sent to an EBGP peer or peer group.

Use undo peer public-as-only to restore the default.

Syntax

peer { group-name | ip-address [ mask-length ] } public-as-only

undo peer { group-name | ip-address [ mask-length ] } public-as-only

Default

BGP updates sent to an EBGP peer or peer group can carry both public and private AS numbers.

Views

BGP IPv4 unicast address family view, BGP-VPN IPv4 unicast address family view, BGP VPNv4 address family view

Predefined user roles

network-admin

mdc-admin

Parameters

group-name: Specifies a peer group by its name, a case-sensitive string of 1 to 47 characters. The peer group must have been created.

ip-address: Specifies a peer by its IP address. The peer must have been created.

mask-length: Specifies a mask length in the range of 0 to 32. You can use the ip-address and mask-length arguments together to specify a network. If you specify a network, this command removes private AS numbers in BGP updates sent to all dynamic peers in the network.

Usage guidelines

The BGP VPNv4 address family view is available in Release 1138P01 and later versions.

Private AS numbers are typically used in test networks, and need not be transmitted in public networks. The range of private AS numbers is from 64512 to 65535.

After you execute the command, you can get the following results:

·     If the AS_PATH attribute of a BGP update carries only private AS numbers, the device removes the AS numbers before sending the update to the EBGP peer or peer group.

·     If the AS_PATH attribute carries both public and private AS numbers, the command does not take effect. The device sends the BGP update to the EBGP peer or peer group without removing the private AS numbers.

·     If the AS_PATH attribute carries AS numbers of the peer or peer group, the command does not take effect. The device sends the BGP update to the peer or peer group without removing the private AS numbers.

This command is only applicable to an EBGP peer or peer group.

Examples

# In BGP IPv4 unicast address family view, remove private AS numbers in BGP updates sent to EBGP peer group test.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] address-family ipv4 unicast

[Sysname-bgp-ipv4] peer test public-as-only

peer reflect-client

Use peer reflect-client to configure the device as a route reflector and specify a peer or peer group as a client.

Use undo peer reflect-client to restore the default.

Syntax

peer { group-name | ip-address [ mask-length ] } reflect-client

undo peer { group-name | ip-address [ mask-length ] } reflect-client

Default

Neither the route reflector nor the client is configured.

Views

BGP IPv4 unicast address family view, BGP-VPN IPv4 unicast address family view, BGP VPNv4 address family view

Predefined user roles

network-admin

mdc-admin

Parameters

group-name: Specifies a peer group by its name, a case-sensitive string of 1 to 47 characters. The peer group must have been created.

ip-address: Specifies a peer by its IP address. The peer must have been created.

mask-length: Specifies a mask length in the range of 0 to 32. You can use the ip-address and mask-length arguments together to specify a network. If you specify a network, this command configures the device as a route reflector and specifies all dynamic peers in the network as clients.

Usage guidelines

The BGP VPNv4 address family view is available in Release 1138P01 and later versions.

Using route reflectors can solve the issue brought by too many IBGP connections. In an AS, a router acts as a route reflector, and other routers act as clients connecting to the route reflector. The route reflector forwards the routing information received from a client to other clients. In this way, all clients can receive routing information from one another without establishing BGP sessions.

Examples

# In BGP IPv4 unicast address family view, configure the local device as a route reflector and specify the IBGP peer group test as a client.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] address-family ipv4 unicast

[Sysname-bgp-ipv4] peer test reflect-client

Related commands

·     reflect between-clients

·     reflector cluster-id

peer route-limit

Use peer route-limit to specify the maximum number of routes that can be received from a peer or peer group.

Use undo peer route-limit to restore the default.

Syntax

peer { group-name | ip-address [ mask-length ] } route-limit prefix-number [ { alert-only | discard | reconnect reconnect-time } | percentage-value ] *

undo peer { group-name | ip-address [ mask-length ] } route-limit

Default

The number of routes that can be received from a peer or peer group is not limited.

Views

BGP IPv4 unicast address family view, BGP-VPN IPv4 unicast address family view, BGP VPNv4 address family view

Predefined user roles

network-admin

mdc-admin

Parameters

group-name: Specifies a peer group by its name, a case-sensitive string of 1 to 47 characters. The peer group must have been created.

ip-address: Specifies a peer by its IP address. The peer must have been created.

mask-length: Specifies a mask length in the range of 0 to 32. You can use the ip-address and mask-length arguments together to specify a network. If you specify a network, this command specifies the maximum number of routes that can be received from all dynamic peers in the network.

prefix-number: Specifies the number of routes that can be received from the peer or peer group. The value range is 1 to 4294967295. If the alert-only and reconnect keywords are not specified, and the number of routes received from the peer or peer group reaches the prefix-number, the router will tear down the connection to the peer or peer group.

alert-only: If the number of routes received from the peer or peer group reaches the prefix-number, the router displays an alarm message instead of tearing down the connection to the peer or peer group.

discard: If the number of routes received from the peer or peer group reaches the prefix-number, the router retains the session to the peer or peer group. However, it discards excess routes and generates a log message. After the number of routes received from the peer or peer group falls below the prefix-number, the router can continue to receive routes from the peer or peer group. To restore the discarded routes, use the refresh bgp import command to request the peer or peer group to resend the routes.

reconnect reconnect-time: Specifies a reconnect time, after which, the router re-establishes a connection to the peer or peer group when the number of routes received from the peer or peer group reaches the prefix-number. The value range for the reconnect-time argument is 1 to 65535 seconds.

percentage-value: Specifies the threshold value for the router to display an alarm message (the router displays an alarm message when the ratio of the number of received routes to the prefix-number exceeds the percentage value). The value range of this argument is 1 to 100, and the default is 75.

Usage guidelines

The BGP VPNv4 address family view is available in Release 1138P01 and later versions.

Examples

# In BGP IPv4 unicast address family view, specify the maximum number of routes that can be received from peer 1.1.1.1 to 10000, and configure the router to tear down the connection to the peer if the number is exceeded.

<Sysname> system-view

[Sysname] bgp 109

[Sysname-bgp] address-family ipv4 unicast

[Sysname-bgp-ipv4] peer 1.1.1.1 route-limit 10000

# In BGP-VPN IPv4 unicast address family view, specify the maximum number of routes that can be received from peer 1.1.1.1 to 10000, and configure the router to tear down the connection to the peer if the number is exceeded.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] ip vpn-instance vpn1

[Sysname-bgp-vpn1] address-family ipv4 unicast

[Sysname-bgp-ipv4-vpn1] peer 1.1.1.1 route-limit 10000

peer route-policy

Use peer route-policy to apply a routing policy to routes incoming from or outgoing to a peer or peer group.

Use undo peer route-policy to remove the configuration.

Syntax

In BGP IPv4 unicast address family view/BGP-VPN IPv4 unicast address family view/BGP VPNv4 address family view:

peer { group-name | ip-address [ mask-length ] } route-policy route-policy-name { export | import }

undo peer { group-name | ip-address [ mask-length ] } route-policy { export | import }

In BGP-VPN VPNv4 address family view:

peer { group-name | ip-address [ mask-length ] } route-policy route-policy-name import

undo peer { group-name | ip-address [ mask-length ] } route-policy import

Default

No routing policy is applied to routes from/to the peer or peer group.

Views

BGP IPv4 unicast address family view, BGP-VPN IPv4 unicast address family view, BGP VPNv4 address family view, BGP-VPN VPNv4 address family view

Predefined user roles

network-admin

mdc-admin

Parameters

group-name: Specifies a peer group by its name, a case-sensitive string of 1 to 47 characters. The peer group must have been created.

ip-address: Specifies a peer by its IP address. The peer must have been created.

mask-length: Specifies a mask length in the range of 0 to 32. You can use the ip-address and mask-length arguments together to specify a network. If you specify a network, this command applies a routing policy to routes incoming from or outgoing to all dynamic peers in the network.

route-policy-name: Specifies a routing policy by its name, a case-sensitive string of 1 to 63 characters.

export: Applies the routing policy to routes outgoing to the peer or peer group.

import: Applies the routing policy to routes incoming from the peer or peer group.

Usage guidelines

The BGP VPNv4 address family view and BGP-VPN VPNv4 address family view are available in Release 1138P01 and later versions.

The specified routing policy must have been configured with the route-policy command in system view. Otherwise, all routes can pass the routing policy.

The if-match interface command, if configured for the referenced routing policy, does not take effect for routes.

Examples

# In BGP IPv4 unicast address family view, apply routing policy test-policy to routes outgoing to the peer group test.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] address-family ipv4 unicast

[Sysname-bgp-ipv4] peer test route-policy test-policy export

Related commands

·     filter-policy export

·     filter-policy import

·     peer as-path-acl

·     peer filter-policy

·     peer prefix-list

·     route-policy

peer route-update-interval

Use peer route-update-interval to specify an interval for sending the same update to a peer or peer group.

Use undo peer route-update-interval to restore the default.

Syntax

peer { group-name | ip-address [ mask-length ] } route-update-interval interval

undo peer { group-name | ip-address [ mask-length ] } route-update-interval

Default

The interval for sending the same update to an IBGP peer is 15 seconds and the interval for sending the same update to an EBGP peer is 30 seconds.

Views

BGP view, BGP-VPN instance view

Predefined user roles

network-admin

mdc-admin

Parameters

group-name: Specifies a peer group by its name, a case-sensitive string of 1 to 47 characters. The peer group must have been created.

ip-address: Specifies a peer by its IP address. The peer must have been created.

mask-length: Specifies a mask length in the range of 0 to 32. You can use the ip-address and mask-length arguments together to specify a network. If you specify a network, this command specifies an interval for sending the same update to all dynamic peers in the network.

interval: Specifies a minimum interval for sending the same update message. The range is 0 to 600 seconds.

Usage guidelines

A BGP router sends an update message to its peers when a route is changed. If the route changes frequently, the BGP router sends many updates for the route, resulting in routing flaps. By configuring the interval for sending the same update to a peer or peer group, you can avoid such routing flaps.

Examples

# In BGP view, specify the interval for sending the same update to peer group test as 10 seconds.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] peer test as-number 100

[Sysname-bgp] peer test route-update-interval 10

# In BGP-VPN instance view, specify the interval for sending the same update to peer group test as 10 seconds.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] ip vpn-instance vpn1

[Sysname-bgp-vpn1] peer test route-update-interval 10

peer source-address

Use peer source-address to specify a source IPv4 address for establishing TCP connections to a peer or peer group.

Use undo peer source-address to remove the configuration.

Syntax

peer ipv4-address [ mask-length ] source-address source-ipv4-address

undo peer ipv4-address [ mask-length ] source-address

peer group-name source-address source-ipv4-address

undo peer group-name source-address [ source-ipv4-address ]

Default

BGP uses the primary IPv4 address of the output interface in the optimal route destined for the BGP peer or peer group as the source address for TCP connection establishment.

Views

BGP view, BGP-VPN instance view.

Predefined user roles

network-admin

mdc-admin

Parameters

ipv4-address: Specifies a peer by its IPv4 address. The peer must have been created.

mask-length: Specifies a mask length in the range of 0 to 32. You can use the ipv4-address and mask-length arguments together to specify a subnet. If you specify a subnet, this command specifies a source IP address for establishing TCP connections to all dynamic peers in the subnet.

source-ipv4-address: Specifies a source IPv4 address.

group-name: Specifies a peer group by its name, a case-sensitive string of 1 to 47 characters. The peer group must have been created.

Usage guidelines

This command is available in Release 1138P01 and later versions.

The peer connect-interface command and the peer source-address command can both change the source address for establishing TCP connections. If you execute both commands, the most recent configuration takes effect.

You can change the source address in the following scenarios:

·     If the source interface fails on a BGP router that has multiple links to a peer, BGP has to re-establish TCP connections. To avoid this problem, use a loopback interface as the source interface or use the IP address of a loopback interface as the source address.

·     If the BGP sessions use the IP addresses of different interfaces, specify a source address or source interface for each peer to establish multiple BGP sessions to a router. Specify a source address for each peer if the BGP sessions use the different addresses of the same interface. Otherwise, the local BGP router might fail to establish a TCP connection to a peer when it uses the optimal route to determine the source address.

The source addresses on the local router and the peer must be reachable to each other.

To specify the address of an indirectly connected interface as the source address, use the peer ebgp-max-hop command. The command allows the establishment of an EBGP session to the indirectly connected peer.

Examples

# In BGP instance view of BGP instance default, specify the source IPv4 address 1.1.1.1 for the peer group test.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] peer test source-address 1.1.1.1

peer substitute-as

Use peer substitute-as to replace the AS number of a peer or peer group in the AS_PATH attribute with the local AS number.

Use undo peer substitute-as to restore the default.

Syntax

peer { group-name | ip-address [ mask-length ] } substitute-as

undo peer { group-name | ip-address [ mask-length ] } substitute-as

Default

The AS number of a peer or peer group in the AS_PATH attribute is not replaced.

Views

BGP view, BGP-VPN instance view

Predefined user roles

network-admin

mdc-admin

Parameters

group-name: Specifies a peer group by its name, a case-sensitive string of 1 to 47 characters. The peer group must have been created.

ip-address: Specifies a peer by its IP address. The peer must have been created.

mask-length: Specifies a mask length in the range of 0 to 32. You can use the ip-address and mask-length arguments together to specify a network. If you specify a network, this command replaces the AS number of all dynamic peers in the network in the AS_PATH attribute with the local AS number.

Examples

# In BGP view, substitute the local AS number for the AS number of peer 1.1.1.1.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] peer 1.1.1.1 substitute-as

# In BGP-VPN instance view, substitute the local AS number for the AS number of peer 1::1.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] ip vpn-instance vpn1

[Sysname-bgp-vpn1] peer 1::1 substitute-as

peer timer

Use peer timer to configure a keepalive interval and holdtime for a peer or peer group.

Use undo peer timer to restore the default.

Syntax

peer { group-name | ip-address [ mask-length ] } timer keepalive keepalive hold holdtime

undo peer { group-name | ip-address [ mask-length ] } timer

Default

The keepalive interval is 60 seconds, and the holdtime is 180 seconds.

Views

BGP view, BGP-VPN instance view

Predefined user roles

network-admin

mdc-admin

Parameters

group-name: Specifies a peer group by its name, a case-sensitive string of 1 to 47 characters. The peer group must have been created.

ip-address: Specifies a peer by its IP address. The peer must have been created.

mask-length: Specifies a mask length in the range of 0 to 32. You can use the ip-address and mask-length arguments together to specify a network. If you specify a network, this command configures a keepalive interval and holdtime for all dynamic peers in the network.

keepalive keepalive: Sets a keepalive interval in the range of 0 to 21845 seconds.

hold holdtime: Sets a holdtime in the range of 3 to 65535 seconds.

Usage guidelines

After establishing a BGP session, two routers send keepalive messages at the specified keepalive interval to each other to keep the session.

If a router receives no keepalive or update message from the peer within the holdtime, it tears down the session.

The timers configured with this command are preferred to the timers configured with the timer command.

If the holdtime settings on the local and peer routers are different, the smaller one is used.

If the holdtime is configured as 0, no keepalive message will be sent to the peer, and the peer session will never time out. If the keepalive interval is configured as 0 and the negotiated holdtime is not 0, one third of the holdtime is taken as the interval for sending keepalive messages. If neither the holdtime nor the keepalive interval is configured as 0, the actual keepalive interval is the smaller one between one third of the holdtime and the keepalive interval.

After this command is executed, the peer session is closed at once, and a new session to the peer is negotiated by using the configured holdtime.

Examples

# In BGP view, configure the keepalive interval and holdtime for peer group test as 60 seconds and 180 seconds.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] peer test timer keepalive 60 hold 180

# In BGP-VPN instance view, configure the keepalive interval and holdtime interval for peer group test as 60 seconds and 180 seconds.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] ip vpn-instance vpn1

[Sysname-bgp-vpn1] peer test timer keepalive 60 hold 180

# In BGP view, configure both the keepalive interval and holdtime for peer group test as 0 seconds, indicating the session will never time out.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] peer test timer keepalive 0 hold 0

# In BGP-VPN instance view, configure both the keepalive interval and holdtime for peer group test as 0 seconds, indicating the session will never time out.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] ip vpn-instance vpn1

[Sysname-bgp-vpn1] peer test timer keepalive 0 hold 0

Related commands

·     display bgp peer ipv4 unicast

·     timer

peer ttl-security

Use peer ttl-security to configure Generalized TTL Security Mechanism (GTSM) for a BGP peer or peer group.

Use undo peer ttl-security to restore the default.

Syntax

peer { group-name | ip-address [ mask-length ] } ttl-security hops hop-count

undo peer { group-name | ip-address [ mask-length ] } ttl-security hops

Default

GTSM is disabled for BGP.

Views

BGP view, BGP-VPN instance view

Predefined user roles

network-admin

mdc-admin

Parameters

group-name: Specifies a peer group by its name, a case-sensitive string of 1 to 47 characters. The peer group must have been created.

ip-address: Specifies a peer by its IP address. The peer must have been created.

mask-length: Specifies a mask length in the range of 0 to 32. You can use the ip-address and mask-length arguments together to specify a network. If you specify a network, this command configures GTSM for all dynamic peers in the network.

hops hop-count: Specifies the maximum number of hops to the specified peer, in the range of 1 to 254.

Usage guidelines

GTSM protects a BGP session by comparing the TTL value of an incoming IP packet against the valid TTL range. If the TTL value is within the valid TTL range, the packet is accepted. If not, the packet is discarded.

The valid TTL range is from 255 – the configured hop count + 1 to 255.

When GTSM is configured, the BGP packets sent by the device have a TTL of 255.

When GTSM is configured, the local device can establish an EBGP session to the peer after they pass GTSM check, regardless of whether the maximum number of hops is reached.

To use GTSM, you must configure GTSM on both the local and peer devices. You can specify different hop-count values for them.

Examples

# In BGP view, enable GTSM for BGP peer group test and specify the maximum number of hops to the specified peer in the peer group as 1.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] peer test ttl-security hops 1

# In BGP-VPN instance view, enable GTSM for BGP peer group test and specify the maximum number of hops to the specified peer in the peer group as 1.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] ip vpn-instance vpn1

[Sysname-bgp-vpn1] peer test ttl-security hops 1

Related commands

peer ebgp-max-hop

pic

Use pic to enable BGP FRR for a BGP address family.

Use undo pic to disable BGP FRR for a BGP address family.

Syntax

pic

undo pic

Default

BGP FRR is disabled.

Views

BGP IPv4 unicast address family view

Predefined user roles

network-admin

mdc-admin

Usage guidelines

FRR is used in a dual-homing network to protect a primary route with a backup route. It uses echo-mode BFD to detect the connectivity of the primary route. When the primary route fails, BGP directs packets to the backup route.

After you enable FRR, BGP calculates a backup route for each BGP route in the address family if there are two or more unequal-cost routes to reach the destination.

You can also configure BGP FRR by using the fast-reroute route-policy command, which takes precedence over the pic command. For more information about routing policies, see Layer 3—IP Routing Configuration Guide.

Use the pic command with caution because it might cause routing loops in specific scenarios.

Examples

# Enable BGP FRR.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] address-family ipv4 unicast

[Sysname-bgp-ipv4] pic

Related commands

fast-reroute route-policy

preference

Use preference to configure preferences for BGP routes.

Use undo preference to restore the default.

Syntax

preference { external-preference internal-preference local-preference | route-policy route-policy-name }

undo preference

Default

The preferences of external, internal, and local BGP routes are 255, 255, and 130.

Views

BGP IPv4 unicast address family view, BGP-VPN IPv4 unicast address family view

Predefined user roles

network-admin

mdc-admin

Parameters

external-preference: Specifies a preference for EBGP routes, in the range of 1 to 255.

internal-preference: Specifies a preference for IBGP routes, in the range of 1 to 255.

local-preference: Specifies a preference for local routes, in the range of 1 to 255.

route-policy route-policy-name: Specifies a routing policy by its name, a case-sensitive string of 1 to 63 characters, to set the route preference for matching routes. Routes not matching the routing policy use the default preference.

Usage guidelines

Different routing protocols might find different routes to the same destination. However, not all of those routes are optimal. For route selection, routing protocols, direct routes, and static routes are assigned different preferences. The route with the highest preference is preferred.

Configuring the preferences for BGP routes changes the possibility for the routes to become the optimal route.

To reference a routing policy to set the preference, you must configure the preference with the apply preference command in the routing policy in advance. Otherwise, all matching routes use the default preference.

Examples

# In BGP IPv4 unicast address family view, configure preferences for EBGP, IBGP, and local routes as 20, 20, and 200.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] address-family ipv4 unicast

[Sysname-bgp-ipv4] preference 20 20 200

# In BGP IPv4 unicast address family view, configure the preference for BGP route 1.1.1.0/24 as 200.

<Sysname> system-view

[Sysname] ip prefix-list route permit 1.1.1.0 24

[Sysname] route-policy prefer permit node 0

[Sysname-route-policy-prefer-0] if-match ip address prefix-list route

[Sysname-route-policy-prefer-0] apply preference 200

[Sysname-route-policy-prefer-0] quit

[Sysname] bgp 100

[Sysname-bgp] address-family ipv4 unicast

[Sysname-bgp-ipv4] preference route-policy prefer

primary-path-detect bfd

Use primary-path-detect bfd to configure BGP FRR to use BFD to detect next hop connectivity for the primary route.

Use undo primary-path-detect bfd to restore the default.

Syntax

primary-path-detect bfd echo

undo primary-path-detect bfd

Default

BGP FRR uses ARP to detect the connectivity to the next hop of the primary route.

Views

BGP view

Predefined user roles

network-admin

mdc-admin

Parameters

echo: Uses echo-mode BFD to detect the connectivity to the next hop of the primary route.

Examples

# Configure BGP FRR to use echo-mode BFD to detect next hop connectivity for the primary route.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] primary-path-detect bfd echo

Related commands

·     fast-reroute route-policy

·     pic

reflect between-clients

Use reflect between-clients to enable route reflection between clients.

Use undo reflect between-clients to disable this function.

Syntax

reflect between-clients

undo reflect between-clients

Default

Route reflection between clients is enabled.

Views

BGP IPv4 unicast address family view, BGP-VPN IPv4 unicast address family view, BGP VPNv4 address family view

Predefined user roles

network-admin

mdc-admin

Usage guidelines

The BGP VPNv4 address family view is available in Release 1138P01 and later versions.

When a route reflector is configured, and the clients of a route reflector are fully meshed, route reflection is unnecessary because it consumes more bandwidth resources. You can use the undo reflect between-clients command to disable route reflection instead of modifying network configuration or changing network topology.

After route reflection is disabled between clients, routes can still be reflected between a client and a non-client.

Examples

# In BGP IPv4 unicast address family view, disable route reflection between clients.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] address-family ipv4 unicast

[Sysname-bgp-ipv4] undo reflect between-clients

# In BGP-VPN IPv4 unicast address family view, disable route reflection between clients.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] ip vpn-instance vpn1

[Sysname-bgp-vpn1] address-family ipv4 unicast

[Sysname-bgp-ipv4-vpn1] undo reflect between-clients

Related commands

·     peer reflect-client

·     reflector cluster-id

reflector cluster-id

Use reflector cluster-id to configure the cluster ID for a route reflector.

Use undo reflector cluster-id to restore the default.

Syntax

reflector cluster-id { cluster-id | ip-address }

undo reflector cluster-id

Default

A route reflector uses its router ID as the cluster ID.

Views

BGP IPv4 unicast address family view, BGP-VPN IPv4 unicast address family view, BGP VPNv4 address family view

Predefined user roles

network-admin

mdc-admin

Parameters

cluster-id: Specifies the cluster ID in the format of an integer, in the range of 1 to 4294967295.

ip-address: Specifies the cluster ID in the format of an IPv4 address in dotted decimal notation.

Usage guidelines

The BGP VPNv4 address family view is available in Release 1138P01 and later versions.

The route reflector and clients form a cluster. Typically a cluster has one route reflector. The ID of the route reflector is the cluster ID.

You can configure more than one route reflector in a cluster to improve network reliability and prevent a single point of failure. Use this command to configure the same cluster ID for all route reflectors in the cluster to avoid routing loops.

Do not configure the router ID of a client as the cluster ID.

Examples

# In BGP IPv4 unicast address family view, configure the cluster ID on the local router (a reflector in the cluster) as 80.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] address-family ipv4 unicast

[Sysname-bgp-ipv4] reflector cluster-id 80

# In BGP-VPN IPv4 unicast address family view, configure the cluster ID on the local router (a reflector in the cluster) as 80.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] ip vpn-instance vpn1

[Sysname-bgp-vpn1] address-family ipv4 unicast

[Sysname-bgp-ipv4-vpn1] reflector cluster-id 80

Related commands

·     peer reflect-client

·     reflect between-clients

refresh bgp

Use refresh bgp to manually soft-reset BGP sessions for the specified address family.

Syntax

refresh bgp { ip-address | all | external | group group-name | internal } { export | import } ipv4 [ unicast ] [ vpn-instance vpn-instance-name ]

refresh bgp { ip-address [ mask-length ] | all | external | group group-name | internal } { export | import } vpnv4 [ vpn-instance vpn-instance-name ]

Views

User view

Predefined user roles

network-admin

mdc-admin

Parameters

ip-address: Soft-resets the BGP session to a peer specified by its IP address.

all: Soft-resets all BGP sessions.

external: Soft-resets all EBGP sessions.

group group-name: Soft-resets the BGP sessions to the peers of the specified peer group. The group-name argument specifies the name of a peer group, a case-sensitive string of 1 to 47 characters.

internal: Soft-resets all IBGP sessions.

export: Performs outbound soft-reset (filters routes advertised to the specified peer or peer group by using the new configuration).

import: Performs inbound soft-reset (filters routes received from the specified peer or peer group by using the new configuration).

ipv4: Soft-resets BGP sessions for IPv4 address family.

unicast: Soft-resets BGP sessions for unicast address family.

vpnv4: Soft-resets BGP sessions for VPNv4 address family. This keyword is available in Release 1138P01 and later versions.

vpn-instance vpn-instance-name: Specifies an MPLS L3VPN instance by its name, a case-sensitive string of 1 to 31 characters. If no VPN instance is specified, this command performs manual soft-reset on BGP sessions for the public network IPv4 unicast address family.

Usage guidelines

A soft-reset operation enables the router to apply a new route selection policy without tearing down BGP connections.

To apply a new policy to outbound BGP sessions, execute this command with the export keyword. The router uses the new policy to filter routing information and sends the routing information that passes the filtering to the BGP peers.

To apply a new policy to inbound sessions, execute this command with the import keyword. The router advertises a route-refresh message to the peer and the peer resends its routing information to the router. After receiving the routing information, the router uses the new policy to filter the routing information.

This command requires that both the local router and the peer support route refresh.

If the peer keep-all-routes command is configured, the refresh bgp ipv4 unicast import command does not take effect.

This command manually soft-resets BGP sessions for the IPv4 unicast address family regardless of whether the unicast keyword is specified or not.

Examples

# Manually soft-reset all BGP sessions for the IPv4 unicast address family.

<Sysname> refresh bgp ipv4 all

Related commands

·     peer capability-advertise route-refresh

·     peer keep-all-routes

reset bgp

Use reset bgp to reset BGP sessions for the specified address family.

Syntax

reset bgp { as-number | ip-address | all | external | group group-name | internal } ipv4 [ unicast ] [ vpn-instance vpn-instance-name ]

reset bgp { as-number | ip-address [ mask-length ] | all | external | group group-name | internal } vpnv4 [ vpn-instance vpn-instance-name ]

Views

User view

Predefined user roles

network-admin

mdc-admin

Parameters

as-number: Resets BGP sessions to peers in the AS.

ip-address: Specifies the IP address of a peer with which to reset the session.

all: Resets all BGP sessions.

external: Resets all EBGP sessions.

group group-name: Resets sessions with peers in the specified BGP peer group.

internal: Resets all IBGP sessions.

ipv4: Resets BGP sessions for IPv4 address family.

unicast: Resets BGP sessions for unicast address family.

vpnv4: Resets BGP sessions for VPNv4 address family. This keyword is available in Release 1138P01 and later versions.

vpn-instance vpn-instance-name: Specifies an MPLS L3VPN instance by its name, a case-sensitive string of 1 to 31 characters. If no VPN instance is specified, this command resets the BGP sessions for IPv4 unicast address family for the public network.

Usage guidelines

To apply a new route selection policy, use this command to reset BGP sessions. BGP re-establishes the BGP sessions, advertises routes, and applies the new policy to routes. This operation breaks down BGP sessions for a short while.

This command resets BGP sessions for the IPv4 unicast address family regardless of whether the unicast keyword is specified or not.

Examples

# Reset all BGP sessions for IPv4 unicast address family of the public network.

<Sysname> reset bgp all ipv4

reset bgp all

Use reset bgp all to reset all BGP sessions.

Syntax

reset bgp all

Views

User view

Predefined user roles

network-admin

mdc-admin

Usage guidelines

To apply a new route selection policy, use this command to reset BGP sessions. BGP re-establishes the BGP sessions, advertises routes, and applies the new policy to routes. This operation breaks down BGP sessions for a short while.

Examples

# Reset all BGP sessions.

<Sysname> reset bgp all

reset bgp dampening ipv4 unicast

Use reset bgp dampening ipv4 unicast to clear BGP IPv4 unicast route dampening information and release the suppressed BGP IPv4 unicast routes.

Syntax

reset bgp dampening ipv4 [ unicast ] [ vpn-instance vpn-instance-name ] [ network-address [ mask | mask-length ] ]

Views

User view

Predefined user roles

network-admin

mdc-admin

Parameters

vpn-instance vpn-instance-name: Specifies an MPLS L3VPN instance by its name, a case-sensitive string of 1 to 31 characters. If no VPN instance is specified, this command clears BGP IPv4 unicast route dampening information for the public network, and releases the suppressed BGP IPv4 unicast routes.

network-address: Specifies a destination network address.

mask: Specifies a network mask, in dotted decimal notation.

mask-length: Specifies a mask length in the range of 0 to 32.

Usage guidelines

If the network-address, mask, and mask-length arguments are not specified, the command clears all BGP IPv4 unicast route dampening information of the public network or the specified VPN, and releases all suppressed BGP IPv4 unicast routes.

If only the network-address argument is specified, the system ANDs the network address with the mask of a route. If the result matches the network address of the route, the command clears dampening information of the route, and releases the suppressed route.

If the network-address mask or network-address mask-length argument is specified, the command clears dampening information of the BGP IPv4 unicast route that matches both the specified destination network address and the mask (or mask length), and releases the suppressed route.

This command clears BGP IPv4 unicast route dampening information and releases the suppressed BGP IPv4 unicast routes regardless of whether the unicast keyword is specified or not.

Examples

# Clear damping information of BGP IPv4 unicast route 20.1.0.0/16 for the public network, and release the suppressed route.

<Sysname> reset bgp dampening ipv4 20.1.0.0 255.255.0.0

Related commands

·     dampening

·     display bgp routing-table dampened ipv4 unicast

reset bgp flap-info ipv4 unicast

Use reset bgp flap-info ipv4 unicast to clear the flap statistics of BGP IPv4 unicast routes.

Syntax

reset bgp flap-info ipv4 [ unicast ] [ vpn-instance vpn-instance-name ] [ network-address [ mask | mask-length ] | as-path-acl as-path-acl-number | peer peer-address ]

Views

User view

Predefined user roles

network-admin

mdc-admin

Parameters

vpn-instance vpn-instance-name: Specifies an MPLS L3VPN instance by its name, a case-sensitive string of 1 to 31 characters. If no VPN instance is specified, this command clears the flap statistics of the BGP IPv4 unicast routes for the public network.

network-address: Specifies a destination network address.

mask: Specifies a network mask, in dotted decimal notation.

mask-length: Specifies a mask length in the range of 0 to 32.

as-path-acl as-path-acl-number: Specifies an AS path list by its number in the range of 1 to 256, to filter BGP IPv4 unicast route flap statistics.

peer peer-address: Clears flap statistics of BGP IPv4 unicast routes learned from the specified BGP peer.

Usage guidelines

When you execute the reset bgp flap-info ipv4 unicast command:

·     If the network-address, mask, and mask-length arguments are not specified, the command clears the flap statistics of all BGP IPv4 unicast routes for the public network or the specified VPN.

·     If only the network-address argument is specified, the system ANDs the network address with the mask of a route. If the result matches the network address of the route, the command clears the flap statistics of the route.

·     If the network-address mask or network-address mask-length argument is specified, the command clears the flap statistics of the BGP IPv4 unicast route that matches both the specified destination network address and the mask (or mask length).

This command clears the flap statistics of BGP IPv4 unicast routes regardless of whether the unicast keyword is specified or not.

Examples

# Clear the flap statistics of BGP IPv4 unicast route 20.1.0.0/16 for the public network.

<Sysname> reset bgp flap-info ipv4 20.1.0.0 16

# Clear the flap statistics for the public network BGP IPv4 unicast routes learned from peer 1.1.1.1.

<Sysname> reset bgp flap-info ipv4 peer 1.1.1.1

Related commands

·     dampening

·     display bgp routing-table flap-info ipv4 unicast

router id (system view)

Use router id to configure a global router ID.

Use undo router id to remove the global router ID.

Syntax

router id router-id

undo router id

Default

No global router ID is configured.

Views

System view

Predefined user roles

network-admin

mdc-admin

Parameters

router-id: Specifies a router ID in IP address format.

Usage guidelines

Some routing protocols use a router ID to identify a device. You can configure a global router ID, which is used by routing protocols that have no router ID configured.

If no global router ID is configured, the highest loopback address, if any, is used as the router ID. If no loopback address is available, the highest physical interface IP address is used, regardless of the interface status. If no IP address is configured for any interface, the router ID is 0.0.0.0.

During an active/standby switchover, the standby main processing unit (MPU) checks whether the previous router ID that is backed up before switchover is valid. If not, it selects a new router ID.

If the interface IP address that is selected as the router ID is removed or modified, a new router ID is selected. Other events, (the interface goes down; after a physical interface address is selected as the router ID, an IP address is configured for a loopback interface; a higher interface IP address is configured) will not trigger a router ID re-selection.

After a router ID is changed, use the reset command to make it effective.

Examples

# Configure a global router ID as 1.1.1.1.

<Sysname> system-view

[Sysname] router id 1.1.1.1

Related commands

·     router-id (BGP view)

·     router id (BGP-VPN instance view)

router-id (BGP view)

Use router-id to configure a router ID for BGP.

Use undo router-id to remove the router ID for BGP.

Syntax

router-id router-id

undo router-id

Default

BGP uses the global router ID configured by router id in system view.

Views

BGP view

Predefined user roles

network-admin

mdc-admin

Parameters

router-id: Specifies a router ID for BGP, in IP address format.

Usage guidelines

To run BGP, a router must have a router ID, which is an unsigned 32-bit integer that uniquely identifies the router in the AS.

To modify a non-zero router ID for BGP, execute the router-id command in BGP view.

To improve availability, specify the IP address of a loopback interface as the router ID for BGP.

If you execute this command in the same BGP view multiple times, the most recent configuration takes effect.

Examples

# Configure the router ID for BGP as 1.1.1.1.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] router-id 1.1.1.1

Related commands

·     router-id (BGP-VPN instance view)

·     router id (system view)

router-id (BGP-VPN instance view)

Use router-id to configure a router ID for a BGP VPN instance.

Use undo router-id to remove the router ID for a BGP VPN instance.

Syntax

router-id { router-id | auto-select }

undo router-id

Default

A BGP VPN instance uses the router ID configured in BGP view. If no router ID is configured in BGP view, the BGP VPN instance uses the global router ID configured in system view.

Views

BGP-VPN instance view

Predefined user roles

network-admin

mdc-admin

Parameters

router-id: Specifies a router ID in IP address format.

auto-select: Automatically selects a router ID for the BGP VPN instance.

Usage guidelines

To run BGP, a VPN instance must have a router ID, which is an unsigned 32-bit integer that uniquely identifies the BGP VPN router in the AS.

To improve availability, specify the IP address of a loopback interface as the router ID.

You can specify a different router ID for each VPN instance on a device.

If you execute this command in the same BGP-VPN instance view multiple times, the most recent configuration takes effect.

If the auto-select keyword is specified, the system selects a router ID for the BGP VPN instance in the following order:

1.     The highest loopback address in the BGP VPN instance as the router ID.

2.     The highest physical interface address in the BGP VPN instance as the router ID, regardless of the interface status.

3.     0.0.0.0 as the router ID.

If a non-zero router ID is selected for the BGP VPN instance, the router ID will not change when a more preferable router ID is available in the BGP VPN instance.

Examples

# Configure the router ID as 1.1.1.1.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] ip vpn-instance vpn1

[Sysname-bgp-vpn1] router-id 1.1.1.1

Related commands

·     router-id (BGP view)

·     router-id (system view)

snmp-agent trap enable bgp

Use snmp-agent trap enable bgp to enable SNMP notifications for BGP.

Use undo snmp-agent trap enable bgp to disable SNMP notifications for BGP.

Syntax

snmp-agent trap enable bgp

undo snmp-agent trap enable bgp

Default

SNMP notifications for BGP are enabled.

Views

System view

Predefined user roles

network-admin

mdc-admin

Usage guidelines

This feature enables generating SNMP notifications for BGP as defined in RFC 4273 upon neighbor state changes. The generated SNMP notifications are sent to the SNMP module.

For more information about SNMP notifications, see Network Management and Monitoring Configuration Guide.

Examples

# Enable SNMP notifications for BGP.

<Sysname> system-view

[Sysname] snmp-agent trap enable bgp

summary automatic

Use summary automatic to configure automatic route summarization for redistributed IGP subnet routes.

Use undo summary automatic to remove the configuration.

Syntax

summary automatic

undo summary automatic

Default

Automatic route summarization is not performed for redistributed IGP subnet routes.

Views

BGP IPv4 unicast address family view, BGP-VPN IPv4 unicast address family view

Predefined user roles

network-admin

mdc-admin

Usage guidelines

After the summary automatic command is configured, BGP summarizes IGP subnets redistributed by the import-route command.

Automatic summary routes can be manually summarized, but cannot be added to the IP routing table.

Examples

# In BGP IPv4 unicast address family view, configure automatic route summarization for redistributed IGP subnet routes.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] address-family ipv4 unicast

[Sysname-bgp-ipv4] summary automatic

# In BGP-VPN IPv4 unicast address family view, configure automatic route summarization for redistributed IGP subnet routes.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] ip vpn-instance vpn1

[Sysname-bgp-vpn1] address-family ipv4 unicast

[Sysname-bgp-ipv4-vpn1] summary automatic

Related commands

·     aggregate

·     import-route

timer

Use timer to configure a BGP keepalive interval and holdtime.

Use undo timer to restore the default.

Syntax

timer keepalive keepalive hold holdtime

undo timer

Default

The BGP keepalive interval and the holdtime are 60 seconds and 180 seconds.

Views

BGP view, BGP-VPN instance view

Predefined user roles

network-admin

mdc-admin

Parameters

keepalive keepalive: Configures a keepalive interval in the range of 0 to 21845 seconds.

hold holdtime: Configures a holdtime in seconds, whose value is 0 or in the range of 3 to 65535.

Usage guidelines

After establishing a BGP session, two routers send keepalive messages at the specified keepalive interval to each other to keep the session.

If a router receives no keepalive or update message from the peer within the holdtime, it tears down the session.

Use the timer command to configure the keepalive interval and holdtime for all BGP peers. Use the peer timer command to configure the keepalive interval and holdtime for a peer or peer group. If both commands are configured, the intervals configured by the peer timer command have higher priority.

If the holdtime settings on the local and peer routers are different, the smaller one is used.

If the holdtime is configured as 0, no keepalive message will be sent to the peer, and the peer session will never time out. If the keepalive interval is configured as 0 and the negotiated holdtime is not 0, one third of the holdtime is taken as the interval for sending keepalive messages. If neither the holdtime nor the keepalive interval is configured as 0, the actual keepalive interval is the smaller one between one third of the holdtime and the keepalive interval.

The timer command affects only new BGP sessions.

After the timer command is executed, no peer session is closed at once. The configured holdtime is used for negotiation in session re-establishment (for example, when you reset the BGP session).

Examples

# In BGP view, configure the keepalive interval and holdtime as 60 seconds and 180 seconds.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] timer keepalive 60 hold 180

# In BGP-VPN instance view, configure the keepalive interval and holdtime as 60 seconds and 180 seconds.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] ip vpn-instance vpn1

[Sysname-bgp-vpn1] timer keepalive 60 hold 180

# In BGP view, configure both the keepalive interval and holdtime as 0 seconds, indicating the sessions will never time out.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] timer keepalive 0 hold 0

# In BGP-VPN instance view, configure both the keepalive interval and holdtime as 0 seconds for BGP sessions in vpn1, indicating the sessions will never time out.

<Sysname> system-view

[Sysname] bgp 100

[Sysname-bgp] ip vpn-instance vpn1

[Sysname-bgp-vpn1] timer keepalive 0 hold 0

Related commands

·     display bgp peer ipv4 unicast

·     peer timer


Policy-based routing commands

apply default-next-hop

Use apply default-next-hop to set a default next hop.

Use undo apply default-next-hop to remove the configuration.

Syntax

apply default-next-hop [ vpn-instance vpn-instance-name ] { ip-address [ direct ] [ track track-entry-number ] }&<1-n>

undo apply default-next-hop [ [ vpn-instance vpn-instance-name ] ip-address&<1-n> ]

Default

No default next hop is set.

Views

Policy node view

Predefined user roles

network-admin

mdc-admin

Parameters

vpn-instance vpn-instance-name: Specifies an MPLS L3VPN instance by its name, a case-sensitive string of 1 to 31 characters. The specified VPN must already exist.

ip-address: Specifies the IP address of the default next hop. If you do not specify the vpn-instance vpn-instance-name option, the default next hop belongs to the public network.

direct: Specifies a directly connected default next hop.

track track-entry-number: Specifies a track entry by its number in the range of 1 to 1024.

&<1-n>: Indicates that the argument before it can be entered up to n times. The value of n is 2.

Usage guidelines

You can specify a maximum of two default next hops for backup in one command line or by executing this command twice.

With a default next hop specified, the undo apply default-next-hop command removes the default next hop.

Without any default next hop specified, the undo apply default-next-hop command removes all default next hops.

Examples

# Set a directly-connected default next hop of 1.1.1.1.

<Sysname> system-view

[Sysname] policy-based-route aa permit node 11

[Sysname-pbr-aa-11] apply default-next-hop 1.1.1.1 direct

apply next-hop

Use apply next-hop to set a next hop.

Use undo apply next-hop to remove the configuration.

Syntax

apply next-hop [ vpn-instance vpn-instance-name ] { ip-address [ direct ] [ track track-entry-number ] }&<1-n>

undo apply next-hop [ [ vpn-instance vpn-instance-name ] ip-address&<1-n> ]

Default

No next hop is set.

Views

Policy node view

Predefined user roles

network-admin

mdc-admin

Parameters

vpn-instance vpn-instance-name: Specifies an MPLS L3VPN instance by its name, a case-sensitive string of 1 to 31 characters. The specified VPN must already exist.

ip-address: Specifies the next-hop IP address. Without the vpn-instance vpn-instance-name option, the next hop belongs to the public network.

direct: Specifies that the next hop must be directly connected to take effect.

track track-entry-number: Specifies a track entry by its number in the range of 1 to 1024.

&<1-n>: Indicates that the argument before it can be entered up to n times. The value of n is 2.

Usage guidelines

You can specify a maximum of two next hops for backup in one command line or by executing this command twice.

With a next hop specified, the undo apply next-hop command removes the next hop.

Without any next hop specified, the undo apply next-hop command removes all next hops.

Examples

# Set a directly-connected next hop of 1.1.1.1.

<Sysname> system-view

[Sysname] policy-based-route aa permit node 11

[Sysname-pbr-aa-11] apply next-hop 1.1.1.1 direct

Related commands

apply loadshare

apply output-interface NULL 0

Use apply output-interface NULL 0 to set the output interface to interface Null 0.

Use undo apply output-interface NULL 0 to remove the configuration.

Syntax

apply output-interface NULL 0 [ track track-entry-number ]

undo apply output-interface NULL 0

Default

The output interface is not set to Interface Null 0.

Views

Policy node view

Predefined user roles

network-admin

mdc-admin

Parameters

track track-entry-number: Specifies a track entry by its number in the range of 1 to 1024.

Examples

# Set the output interface to interface Null 0 for matching packets.

<Sysname> system-view

[Sysname] policy-based-route aa permit node 11

[Sysname-pbr-aa-11] apply output-interface NULL 0

display ip policy-based-route

Use display ip policy-based-route to display PBR policy information.

Syntax

display ip policy-based-route [ policy policy-name ]

Views

Any view

Predefined user roles

network-admin

network-operator

mdc-admin

mdc-operator

Parameters

policy policy-name: Specifies a policy by its name, a case-sensitive string of 1 to 19 characters.

Usage guidelines

If no policy is specified, this command displays information about all policies.

If a policy name is specified, this command displays information about the specified policy.

Examples

# Display all policy information.

<Sysname> display ip policy-based-route

Policy name: aaa

  node 1 permit:

    if-match acl 2000

    apply next-hop 1.1.1.1

Table 79 Command output

Field

Description

node 1 permit

The match mode of Node 1 is permit.

if-match acl

Matches packets against the ACL.

apply next-hop

Specify a next hop for permitted packets.

 

Related commands

policy-based-route

display ip policy-based-route interface

Use display ip policy-based-route interface to display interface PBR configuration and statistics.

Syntax

In standalone mode:

display ip policy-based-route interface interface-type interface-number [ slot slot-number ]

In IRF mode:

display ip policy-based-route interface interface-type interface-number [ chassis chassis-number slot slot-number ]

Views

Any view

Predefined user roles

network-admin

network-operator

mdc-admin

mdc-operator

Parameters

interface-type interface-number: Specifies an interface by its type and number.

slot slot-number: Displays the PBR configuration and statistics on a card. The slot-number argument is the number of the slot that holds the card. (In standalone mode.)

chassis chassis-number slot slot-number: Displays the PBR configuration and statistics of a card on an IRF member device. The chassis-number argument is the ID of the IRF member device, and the slot-number argument is the number of the slot that holds the card. (In IRF mode.)

Examples

# Display PBR configuration and statistics on VLAN-interface 1.

<Sysname> display ip policy-based-route interface Vlan-interface 1 slot 1

Policy based routing information for interface Vlan-interface1(failed):

Policy name: aaa

  node 0 deny:

  Matched: 0

  node 1 permit:

    if-match acl 3999

  Matched: 0

  node 2 permit:

    if-match acl 2000

    apply next-hop 2.2.2.2

  Matched: 0

  node 5 permit:

    if-match acl 3101

    apply next-hop 1.1.1.1

  Matched: 0

Total matched: 0

<Sysname> display ip policy-based-route interface Vlan-interface 1 slot 1

Policy based routing information for interface Vlan-interface1:

Policy name: aaa

  node 0 deny(not support):

  Matched: 0

  node 1 permit:

    if-match acl 3999

  Matched: 0

  node 2 permit(no resource):

    if-match acl 2000

    apply next-hop 2.2.2.2

  Matched: 0

  node 5 permit:

    if-match acl 3101

    apply next-hop 1.1.1.1

  Matched: 0 (no statistics resource)

Total matched: 0

Table 80 Command output

Field

Description

Policy based routing information for interface Vlan-interface1(failed)

PBR configuration and statistics on VLAN-interface 1.

failed indicates that the policy (including all its nodes) failed to be assigned to the driver.

For a global interface (with only a one-dimensional interface number, for example, VLAN-interface 1), failed can be displayed only when you specify the slot slot-number or chassis chassis-number slot slot-number option for the command.

node 0 deny(not support)

node 2 permit(no resource)

Match mode of the node, permit or deny.

not support means the device does not support match criteria configured on the node; no resource means the device has insufficient ACL resources, and failed to assign ACL resources to the node.

For a global interface (with only a one-dimensional interface number, for example, VLAN-interface 1), not support and no resource can be displayed only when you specify the slot slot-number or chassis chassis-number slot slot-number option for the command.

if-match acl

Matches packets against the ACL.

apply next-hop

Specify a next hop for permitted packets.

Matched: 0 (no statistics resource)

Number of successful matches on the node (no statistics resource indicates insufficient statistics resources).

For a global interface (with only a one-dimensional interface number, for example, VLAN-interface 1), no statistics resource can be displayed only when you specify the slot slot-number or chassis chassis-number slot slot-number option for the command.

Total matched

Total number of successful matches on all nodes.

 

Related commands

reset ip policy-based-route statistics

display ip policy-based-route local

Use display ip policy-based-route local to display local PBR configuration and statistics.

Syntax

In standalone mode:

display ip policy-based-route local [ slot slot-number ]

In IRF mode:

display ip policy-based-route local [ chassis chassis-number slot slot-number ]

Views

Any view

Predefined user roles

network-admin

network-operator

mdc-admin

mdc-operator

Parameters

slot slot-number: Displays the PBR configuration and statistics on a card. The slot-number argument is the number of the slot that holds the card. (In standalone mode.)

chassis chassis-number slot slot-number: Displays the PBR configuration and statistics of a card on an IRF member device. The chassis-number argument is the ID of the IRF member device, and the slot-number argument is the number of the slot that holds the card. (In IRF mode.)

Examples

# Display local PBR configuration and statistics.

<Sysname> display ip policy-based-route local

Policy based routing information for local:

Policy name: aaa

  node 0 deny:

  Matched: 0

  node 1 permit:

    if-match acl 3999

  Matched: 0

  node 2 permit:

    if-match acl 2000

    apply next-hop 2.2.2.2

  Matched: 0

  node 5 permit:

    if-match acl 3101

    apply next-hop 1.1.1.1

  Matched: 0

Total matched: 0

Table 81 Command output

Field

Description

Policy based routing information for local

Local PBR configuration and statistics.

node 0 deny/node 2 permit

Match mode of the node: permit or deny.

if-match acl

Match packets against the ACL.

apply next-hop

Specify a next hop for permitted packets.

Matched: 0

Number of successful matches on the node.

Total matched

Total number of successful matches on all nodes.

 

Related commands

reset ip policy-based-route statistics

display ip policy-based-route setup

Use display ip policy-based-route setup to display PBR configuration.

Syntax

display ip policy-based-route setup

Views

Any view

Predefined user roles

network-admin

network-operator

mdc-admin

mdc-operator

Examples

# Display PBR configuration.

<Sysname> display ip policy-based-route setup

Policy Name              Interface Name

pr01                     Vlan-interface1

Table 82 Command output

Field

Description

Interface Name

Interface where the policy is applied.

 

Related commands

ip policy-based-route

if-match acl

Use if-match acl to set an ACL match criterion.

Use undo if-match acl to remove the ACL match criterion.

Syntax

if-match acl { acl-number | name acl-name }

undo if-match acl

Default

No ACL match criterion is set.

Views

Policy node view

Predefined user roles

network-admin

mdc-admin

Parameters

acl-number: Specifies an ACL by its number in the range of 2000 to 2999 for a basic ACL, and in the range of 3000 to 3999 for an advanced ACL.

name acl-name: Specifies an ACL by its name, a case-insensitive string of 1 to 63 characters starting with letter a to z or A to Z. The ACL name cannot be all.

Examples

# Configure Node 11 of policy aa to permit the packets matching ACL 2011.

<Sysname> system-view

[Sysname] policy-based-route aa permit node 11

[Sysname-pbr-aa-11] if-match acl 2011

# Configure Node 11 of policy aa to permit the packets matching ACL aaa.

<Sysname> system-view

[Sysname] policy-based-route aa permit node 11

[Sysname-pbr-aa-11] if-match acl name aaa

if-match vxlan-id

Use if-match vxlan-id to configure a VXLAN match criterion.

Use undo if-match vxlan-id to restore the default.

Syntax

if-match vxlan-id vxlan-id

undo if-match vxlan-id

Default

No VXLAN match criterion is configured.

Views

Policy node view

Predefined user roles

network-admin

mdc-admin

Parameters

vxlan-id: Specifies a VXLAN ID in the range of 0 to 16777215.

Usage guidelines

This command is available in Release 1138P01 and later versions.

Examples

# Configure Node 11 of policy aaa to permit packets with the VXLAN ID 1000.

<Sysname> system-view

[Sysname] policy-based-route aaa permit node 11

[Sysname-pbr-aaa-11] if-match vxlan-id 1000

ip local policy-based-route

Use ip local policy-based-route to configure local PBR based on a policy.

Use undo ip local policy-based-route to remove the configuration.

Syntax

ip local policy-based-route policy-name

undo ip local policy-based-route

Default

No policy is referenced for local PBR.

Views

System view

Predefined user roles

network-admin

mdc-admin

Parameters

policy-name: Specifies a policy by its name, a case-sensitive string of 1 to 19 characters. The specified policy must already exist.

Usage guidelines

You can apply only one policy locally. Before you apply a new policy, you must first remove the current policy.

Local PBR is used to route locally generated packets. Do not configure local PBR unless required.

Examples

# Configure local PBR based on policy aaa.

<Sysname> system-view

[Sysname] ip local policy-based-route aaa

Related commands

·     display ip policy-based-route setup

·     policy-based-route

ip policy-based-route

Use ip policy-based-route to configure interface PBR by applying a policy to an interface.

Use undo ip policy-based-route to remove the configuration.

Syntax

ip policy-based-route policy-name

undo ip policy-based-route

Default

No policy is applied to an interface.

Views

Interface view

Predefined user roles

network-admin

mdc-admin

Parameters

policy-name: Specifies a policy by its name, a case-sensitive string of 1 to 19 characters. The specified policy must already exist.

Usage guidelines

You can apply only one policy to an interface. Before you apply a new policy, you must first remove the current policy from the interface.

Examples

# Apply policy aaa to VLAN-interface 2.

<Sysname> system-view

[Sysname] vlan 2

[Sysname-Vlan2] interface vlan-interface 2

[Sysname-Vlan-interface2] ip policy-based-route aaa

Related commands

·     display ip policy-based-route setup

·     policy-based-route

ip policy-based-route egress

Use ip policy-based-route egress to configure PBR for outgoing packets by applying a policy to an egress interface.

Use undo ip policy-based-route egress to restore the default.

Syntax

ip policy-based-route policy-name egress

undo ip policy-based-route egress

Default

No policy is applied to an egress interface for outgoing packets.

Views

VXLAN tunnel interface view

Predefined user roles

network-admin

mdc-admin

Parameters

policy-name: Specifies a policy by its name, a case-sensitive string of 1 to 19 characters. The specified policy must already exist.

Usage guidelines

This command is available in Release 1138P01 and later versions.

Examples

# Apply policy aaa to Tunnel 0.

<Sysname> system-view

[Sysname] interface Tunnel 0 mode vxlan

[Sysname-Tunnel0] ip policy-based-route aaa egress

ip policy-based-route vxlan-mode enable

Use ip policy-based-route vxlan-mode enable to enable VXLAN mode for PBR.

Use undo ip policy-based-route vxlan-mode enable to disable VXLAN mode for PBR.

Syntax

ip policy-based-route vxlan-mode enable

undo ip policy-based-route vxlan-mode enable

Default

VXLAN mode for PBR is disabled.

Views

System view

Predefined user roles

network-admin

mdc-admin

Usage guidelines

This command is available in Release 1138P01 and later versions.

This feature causes forwarding entries to be updated on all interfaces of a device. To prevent the following consequences, execute this command before you configure interface PBR:

·     The update is time-consuming because of too many forwarding entries.

·     If the update is not performed on interfaces in interface configuration order, the device cannot provide enough resources for some interfaces.

Examples

# Enable VXLAN mode for PBR.

<Sysname> system-view

[Sysname] ip policy-based-route vxlan-mode enable

policy-based-route

Use policy-based-route to create a policy node and enter policy node view.

Use undo policy-based-route to remove a policy or policy node.

Syntax

policy-based-route policy-name [ deny | permit ] node node-number

undo policy-based-route policy-name [ deny | node node-number | permit ]

Default

No policy node is created.

Views

System view

Predefined user roles

network-admin

mdc-admin

Parameters

policy-name: Specifies a policy by its name, a case-sensitive string of 1 to 19 characters.

deny: Specifies the match mode for the policy node as deny.

permit: Specifies the match mode for the policy node as permit (default mode).

node node-number: Specifies a policy node by its number. A smaller number has a higher priority. The value range for the node-number argument is 0 to 255.

Usage guidelines

A policy that has been applied to an interface or locally cannot be removed. To remove it, you must first cancel the application.

If a policy node is specified, the undo policy-based-route command removes the specified policy node; if a match mode is specified, the command removes all nodes configured with the match mode; if no policy node or match mode is specified, the command removes the whole policy.

Examples

# Create permit-mode of Node 10 for policy policy1 and enter policy node view.

<Sysname> system-view

[Sysname] policy-based-route policy1 permit node 10

[Sysname-pbr-policy1-10]

Related commands

display ip policy-based-route

reset ip policy-based-route statistics

Use reset ip policy-based-route statistics to clear PBR statistics.

Syntax

reset ip policy-based-route statistics [ policy policy-name ]

Views

User view

Predefined user roles

network-admin

mdc-admin

Parameters

policy policy-name: Specifies a policy by its name, a case-sensitive string of 1 to 19 characters.

Usage guidelines

If no policy is specified, the command clears all PBR statistics.

If a policy is specified, the command clears the PBR statistics for the specified policy.

To view PBR statistics, use the display ip policy-based-route interface command.

Examples

# Clear all PBR statistics.

<Sysname> reset ip policy-based-route statistics

Related commands

·     display ip policy-based-route interface

·     display ip policy-based-route local

 


Routing policy commands

Common routing policy commands

apply as-path

Use apply as-path to set the AS_PATH attribute for BGP routes.

Use undo apply as-path to restore the default.

Syntax

apply as-path as-number&<1-32> [ replace ]

undo apply as-path

Default

No AS_PATH attribute is set.

Views

Routing policy node view

Predefined user roles

network-admin

mdc-admin

Parameters

as-number&<1-32>: Specifies an AS by its number in the range of 1 to 4294967295. &<1-32> indicates that the argument before it can be entered up to 32 times.

replace: Replaces the original AS numbers. If this keyword is not specified, the command adds the specified AS numbers before the original AS_PATH attribute.

Examples

# Configure node 10 in permit mode for routing policy policy1 to add AS number 200 before the original AS_PATH attribute of BGP routes matching AS path list 1.

<Sysname> system-view

[Sysname] route-policy policy1 permit node 10

[Sysname-route-policy-policy1-10] if-match as-path 1

[Sysname-route-policy-policy1-10] apply as-path 200

Related commands

·     display ip as-path

·     if-match ip as-path

·     ip as-path

apply comm-list delete

Use apply comm-list delete to delete the COMMUNITY attributes from BGP routes.

Use undo apply comm-list to restore the default.

Syntax

apply comm-list { comm-list-number | comm-list-name } delete

undo apply comm-list

Default

No COMMUNITY attributes are deleted from BGP routes.

Views

Routing policy node view

Predefined user roles

network-admin

mdc-admin

Parameters

comm-list-number: Specifies a basic community list by its number in the range of 1 to 99 or an advanced community list by its number in the range of 100 to 199.

comm-list-name: Specifies a community list by its name, a case-sensitive string of 1 to 63 characters that cannot comprise only numbers.

Examples

# Configure node 10 in permit mode for routing policy policy1 to remove the COMMUNITY attributes specified in community list 1 from BGP routes.

<Sysname> system-view

[Sysname] route-policy policy1 permit node 10

[Sysname-route-policy-policy1-10] apply comm-list 1 delete

Related commands

ip community-list

apply community

Use apply community to set a specified COMMUNITY attribute for BGP routes.

Use undo apply community to remove the configuration.

Syntax

apply community { none | additive | { community-number&<1-32> | aa:nn&<1-32> | internet | no-advertise | no-export | no-export-subconfed } * [ additive ] }

undo apply community [ none | additive | { community-number&<1-32> | aa:nn&<1-32> | internet | no-advertise | no-export | no-export-subconfed } * [ additive ] ]

Default

No COMMUNITY attribute is set for BGP routes.

Views

Routing policy node view

Predefined user roles

network-admin

mdc-admin

Parameters

none: Removes the COMMUNITY attributes of BGP routes.

community-number&<1-32>: Specifies a community sequence number in the range of 1 to 4294967295. &<1-32> indicates that the argument before it can be entered up to 32 times.

aa:nn&<1-32>: Specifies a community number; both aa and nn are in the range of 0 to 65535. &<1-32> indicates that the argument before it can be entered up to 32 times.

internet: Sets the INTERNET community attribute for BGP routes. Routes with this attribute can be advertised to all BGP peers. By default, all routes have this attribute.

no-advertise: Sets the NO_ADVERTISE community attribute for BGP routes. Routes with this attribute cannot be advertised to any peers.

no-export: Sets the NO_EXPORT community attribute for BGP routes. Routes with this attribute cannot be advertised out of the AS or confederation, but can be advertised to other sub-ASs in the confederation.

no-export-subconfed: Sets the NO_EXPORT_SUBCONFED community attribute for BGP routes. Routes with this attribute cannot be advertised out of the local AS or to other sub-ASs in the confederation.

additive: Adds the specified COMMUNITY attribute to the original COMMUNITY attribute of BGP routes.

Examples

# Configure node 16 in permit mode for routing policy setcommunity to set the NO_EXPORT community attribute for BGP routes.

<Sysname> system-view

[Sysname] route-policy setcommunity permit node 16

[Sysname-route-policy-setcommunity-16] apply community no-export

Related commands

·     if-match community

·     ip community-list

apply cost

Use apply cost to set a cost for routing information.

Use undo apply cost to restore the default.

Syntax

apply cost [ + | - ] value

undo apply cost

Default

No cost is set for routing information.

Views

Routing policy node view

Predefined user roles

network-admin

mdc-admin

Parameters

+: Increases a cost value.

-: Decreases a cost value.

value: Specifies a cost in the range of 0 to 4294967295.

Examples

# Configure node 10 in permit mode for routing policy policy1 to set a cost of 120 for OSPF external routes.

<Sysname> system-view

[Sysname] route-policy policy1 permit node 10

[Sysname-route-policy-policy1-10] if-match route-type external-type1or2

[Sysname-route-policy-policy1-10] apply cost 120

apply cost-type

Use apply cost-type to set a cost type for routing information.

Use undo apply cost-type to restore the default.

Syntax

apply cost-type { external | internal | type-1 | type-2 }

undo apply cost-type

Default

No cost type is set for routing information.

Views

Routing policy node view

Predefined user roles

network-admin

mdc-admin

Parameters

external: Sets the cost type to IS-IS external route.

internal: Sets the cost type to IS-IS internal route, or sets the MED value for a matching BGP route to the IGP metric of the route's next hop.

type-1: Sets the cost type to OSPF Type-1 external route.

type-2: Sets the cost type to OSPF Type-2 external route.

Usage guidelines

Used for IS-IS, the apply cost-type internal command sets the cost type for a matching IS-IS route to IS-IS internal route.

Used for BGP, the apply cost-type internal command sets the MED for a matching BGP route learned from an IBGP peer to the IGP metric of the route's next hop before BGP advertises the route to an EBGP peer.

Examples

# Configure node 10 in permit mode for routing policy policy1 to set the cost type for routes that have a tag of 8 to IS-IS internal route.

<Sysname> system-view

[Sysname] route-policy policy1 permit node 10

[Sysname-route-policy-policy1-10] if-match tag 8

[Sysname-route-policy-policy1-10] apply cost-type internal

apply extcommunity

Use apply extcommunity to apply the specified extended community attribute.

Use undo apply extcommunity to restore the default.

Syntax

apply extcommunity { rt route-target }&<1-32> [ additive ]

undo apply extcommunity

Default

No extended community attribute is set for BGP routes.

Views

Routing policy node view

Predefined user roles

network-admin

mdc-admin

Parameters

{ rt route-target }&<1-32>: Sets the RT extended community attribute, a string of 3 to 21 characters. &<1-32> indicates that the argument before it can be entered up to 32 times.

A route-target has the following forms:

·     16-bit AS numberA 32-bit self-defined number, for example, 101:3. The AS number is in the range of 0 to 65535, and the self-defined number is in the range of 0 to 4294967295.

·     32-bit IP addressA 16-bit self-defined number, for example, 192.168.122.15:1. The self-defined number is in the range of 0 to 65535.

·     32-bit AS numberA 16-bit self-defined number, for example, 70000:3. The AS number is in the range of 65536 to 4294967295, and the self-defined number is in the range of 0 to 65535.

additive: Adds the specified attribute to the original extended community attribute.

Examples

# Configure node 10 in permit mode for routing policy policy1 to add the RT extended community attribute 100:2 to BGP routes matching AS path list 1.

<Sysname> system-view

[Sysname] route-policy policy1 permit node 10

[Sysname-route-policy-policy1-10] if-match as-path 1

[Sysname-route-policy-policy1-10] apply extcommunity rt 100:2 additive

apply isis

Use apply isis to redistribute routes into a specified ISIS level.

Use undo apply isis to restore the default.

Syntax

apply isis { level-1 | level-1-2 | level-2 }

undo apply isis

Default

No IS-IS level is set.

Views

Routing policy node view

Predefined user roles

network-admin

mdc-admin

Parameters

level-1: Redistributes routes into IS-IS Level-1.

level-1-2: Redistributes routes into both IS-IS Level-1 and Level-2.

level-2: Redistributes routes into IS-IS Level-2.

Examples

# Configure node 10 in permit mode for routing policy policy1 to redistribute routes that have a tag of 8 to IS-IS level-2.

<Sysname> system-view

[Sysname] route-policy policy1 permit node 10

[Sysname-route-policy-policy1-10] if-match tag 8

[Sysname-route-policy-policy1-10] apply isis level-2

apply local-preference

Use apply local-preference to set a local preference for BGP routes.

Use undo apply local-preference to restore the default.

Syntax

apply local-preference preference

undo apply local-preference

Default

No local preference is set for BGP routes.

Views

Routing policy node view

Predefined user roles

network-admin

mdc-admin

Parameters

preference: Specifies a local preference in the range of 0 to 4294967295.

Examples

# Configure node 10 in permit mode for routing policy policy1 to set a local preference of 130 for routes matching AS path list 1.

<Sysname> system-view

[Sysname] route-policy policy1 permit node 10

[Sysname-route-policy-policy1-10] if-match as-path 1

[Sysname-route-policy-policy1-10] apply local-preference 130

apply origin

Use apply origin to set an ORIGIN attribute for BGP routes.

Use undo apply origin to restore the default.

Syntax

apply origin { egp as-number | igp | incomplete }

undo apply origin

Default

No ORIGIN attribute is set for BGP routes.

Views

Routing policy node view

Predefined user roles

network-admin

mdc-admin

Parameters

egp as-number: Sets the ORIGIN attribute to EGP. The as-number argument specifies an AS number in the range 1 to 4294967295 for EGP routes.

igp: Sets the ORIGIN attribute to IGP.

incomplete: Sets the ORIGIN attribute to UNKNOWN.

Examples

# Configure node 10 in permit mode for routing policy policy1 to set the ORIGIN attribute for routes matching AS path list 1 to IGP.

<Sysname> system-view

[Sysname] route-policy policy1 permit node 10

[Sysname-route-policy-policy1-10] if-match as-path 1

[Sysname-route-policy-policy1-10] apply origin igp

apply preference

Use apply preference to set a preference for a routing protocol.

Use undo apply preference to restore the default.

Syntax

apply preference preference

undo apply preference

Default

No preference is set for a routing protocol.

Views

Routing policy node view

Predefined user roles

network-admin

mdc-admin

Parameters

preference: Specifies a preference in the range of 1 to 255.

Usage guidelines

If you have set preferences for routing protocols with the preference command, the apply preference command sets a new preference for the matching routing protocol. Non-matching routing protocols still use the preferences set by the preference command.

Examples

# Configure node 10 in permit mode for routing policy policy1 to set the preference for OSPF external routes to 90.

<Sysname> system-view

[Sysname] route-policy policy1 permit node 10

[Sysname-route-policy-policy1-10] if-match route-type external-type1or2

[Sysname-route-policy-policy1-10] apply preference 90

apply preferred-value

Use apply preferred-value to set a preferred value for BGP routes.

Use undo apply preferred-value to restore the default.

Syntax

apply preferred-value preferred-value

undo apply preferred-value

Default

No preferred value is set for BGP routes.

Views

Routing policy node view

Predefined user roles

network-admin

mdc-admin

Parameters

preferred-value: Specifies a preferred value in the range of 0 to 65535.

Examples

# Configure node 10 in permit mode for routing policy policy1 to set a preferred value of 66 for BGP routes matching AS path list 1.

<Sysname> system-view

[Sysname] route-policy policy1 permit node 10

[Sysname-route-policy-policy1-10] if-match as-path 1

[Sysname-route-policy-policy1-10] apply preferred-value 66

apply prefix-priority

Use apply prefix-priority to set a prefix priority for routes.

Use undo apply prefix-priority to restore the default.

Syntax

apply prefix-priority { critical | high | medium }

undo apply prefix-priority

Default

No prefix priority is set, which means the prefix priority is low.

Views

Routing policy node view

Predefined user roles

network-admin

mdc-admin

Parameters

critical: Sets the critical prefix priority for routes.

high: Sets the high prefix priority for routes.

medium: Sets the medium prefix priority for routes.

Examples

# Configure node 10 in permit mode for routing policy policy1 to set prefix priority critical for routes matching prefix list abc.

<Sysname> system-view

[Sysname] route-policy policy1 permit node 10

[Sysname-route-policy-policy1-10] if-match ip address prefix-list abc

[Sysname-route-policy-policy1-10] apply prefix-priority critical

apply tag

Use apply tag to set a specified tag for RIP, OSPF, or IS-IS routing information.

Use undo apply tag to restore the default.

Syntax

apply tag value

undo apply tag

Default

No routing tag is set for RIP, OSPF, or IS-IS routing information.

Views

Routing policy node view

Predefined user roles

network-admin

mdc-admin

Parameters

value: Specifies the tag value in the range of 0 to 4294967295.

Examples

# Configure node 10 in permit mode for routing policy policy1 to set a tag of 100.

<Sysname> system-view

[Sysname] route-policy policy1 permit node 10

[Sysname-route-policy-policy1-10] apply tag 100

continue

Use continue to specify the next node to be matched.

Use undo continue to restore the default.

Syntax

continue [ node-number ]

undo continue

Default

No next node is specified.

Views

Routing policy node view

Predefined user roles

network-admin

mdc-admin

Parameters

node-number: Specifies the routing policy node number in the range of 0 to 65535.

Usage guidelines

The specified next node must have a larger number than the current node.

Example

# Specify the next node 20 for node 10 of routing policy policy1.

<Sysname> system-view

[Sysname] route-policy policy1 permit node 10

[Sysname-route-policy-policy1-10] continue 20

display ip as-path

Use display ip as-path to display BGP AS path list information.

Syntax

display ip as-path [ as-path-number ]

Views

Any view

Predefined user roles

network-admin

network-operator

mdc-admin

mdc-operator

Parameters

as-path-number: Specifies an AS path list by its number in the range of 1 to 256. Without this argument, the command displays information about all BGP AS path lists.

Examples

# Display information about BGP AS path list 1.

<Sysname> display ip as-path 1

ListID    Mode      Expression

1         permit    2

Table 83 Command output

Field

Description

ListID

AS path list ID.

Mode

Match mode:

·     permit.

·     deny.

Expression

Regular expression used to match routes.

 

display ip community-list

Use display ip community-list to display BGP community list information.

Syntax

display ip community-list [ basic-community-list-number | adv-community-list-number | name comm-list-name ]

Views

Any view

Predefined user roles

network-admin

network-operator

mdc-admin

mdc-operator

Parameters

basic-community-list-number: Specifies a basic community list by its number in the range of 1 to 99.

adv-community-list-number: Specifies an advanced community list by its number in the range of 100 to 199.

name comm-list-name: Specifies a community list by its name, a case-sensitive string of 1 to 63 characters that cannot comprise only numbers.

Usage guidelines

If no community list is specified, this command displays information about all BGP community lists.

Examples

# Display information about all BGP community lists.

<Sysname> display ip community-list

Community List Basic aaa

        permit

Community List Advanced bbb

        permit  3333

Table 84 Command output

Field

Description

Community List Basic

Basic community list.

Community List Advanced

Advanced community list.

permit

Match mode:

·     permit.

·     deny.

 

display ip extcommunity-list

Use display ip extcommunity-list to display BGP extended community list information.

Syntax

display ip extcommunity-list [ ext-comm-list-number ]

Views

Any view

Predefined user roles

network-admin

network-operator

mdc-admin

mdc-operator

Parameters

ext-comm-list-number: Specifies an extended community list by its number in the range of 1 to 199. Without this argument, the command displays information about all BGP extended community lists.

Examples

# Display information about BGP extended community list 1.

<Sysname> display ip extcommunity-list 1

Extended Community List Number 1

         permit rt : 9:6

Table 85 Command output

Field

Description

Extended Community List Number

Extended community list.

permit

Match mode:

·     permit.

·     deny.

rt

Route Target (RT) extended community attribute.

 

display route-policy

Use display route-policy to display routing policy information.

Syntax

display route-policy [ name route-policy-name ]

Views

Any view

Predefined user roles

network-admin

network-operator

mdc-admin

mdc-operator

Parameters

name route-policy-name: Specifies a routing policy by its name, a case-sensitive string of 1 to 63 characters. Without this argument, this command displays information about all routing policies.

Examples

# Display information about routing policy 1.

<Sysname> display route-policy name policy1

Route-policy: policy1

  permit : 1

          if-match cost 10

          continue: next node 11

          apply comm-list a delete

Table 86 Command output

Field

Description

Route-policy

Routing policy name.

permit

Match mode:

·     permit.

·     deny.

if-match

Match criterion.

continue

Specify the next node to be matched.

apply

Action.

 

if-match as-path

Use if-match as-path to match BGP routes whose AS_PATH attribute matches a specified AS path list.

Use undo if-match as-path to remove the configuration.

Syntax

if-match as-path as-path-number&<1-32>

undo if-match as-path [ as-path-number&<1-32> ]

Default

No match criterion is configured.

Views

Routing policy node view

Predefined user roles

network-admin

mdc-admin

Parameters

as-path-number&<1-32>: Specifies an AS path list by its number in the range of 1 to 256. &<1-32> indicates that the argument before it can be entered up to 32 times.

Examples

# Define AS path list 2 to permit BGP routes containing AS number 200 or 300 to pass. Configure node 10 in permit mode for routing policy test to match AS path list 2.

<Sysname> system-view

[Sysname] ip as-path 2 permit _*200.*300

[Sysname] route-policy test permit node 10

[Sysname-route-policy-policy1-10] if-match as-path 2

Related commands

·     apply as-path

·     ip as-path-acl

if-match community

Use if-match community to match BGP routes whose COMMUNITY attribute matches a specified community list.

Use undo if-match community to remove the configuration.

Syntax

if-match community { { basic-community-list-number | name comm-list-name } [ whole-match ] | adv-community-list-number }&<1-32>

undo if-match community [ { basic-community-list-number | name comm-list-name } [ whole-match ] | adv-community-list-number ]&<1-32>

Default

No community list match criterion is configured.

Views

Routing policy node view

Predefined user roles

network-admin

mdc-admin

Parameters

basic-community-list-number: Specifies a basic community list by its number in the range of 1 to 99.

adv-community-list-number: Specifies an advanced community list by its number in the range of 100 to 199.

comm-list-name: Specifies a community list by its name, a case-sensitive string of 1 to 63 characters that cannot comprise only numbers.

whole-match: Exactly matches the specified community list.

&<1-32>: Indicates that the argument before it can be entered up to 32 times.

Examples

# Configure community list 1 to permit BGP routes with community number 100 or 200. Then configure node 10 in permit mode for routing policy test to use community list 1 to match BGP routes.

<Sysname> system-view

[Sysname] ip community-list 1 permit 100 200

[Sysname] route-policy test permit node 10

[Sysname-route-policy-test-10] if-match community 1

Related commands

·     apply community

·     ip community-list

if-match cost

Use if-match cost to match routing information having the specified cost.

Use undo if-match cost to restore the default.

Syntax

if-match cost value

undo if-match cost

Default

No cost match criterion is configured.

Views

Routing policy node view

Predefined user roles

network-admin

mdc-admin

Parameters

value: Specifies a cost in the range of 0 to 4294967295.

Examples

# Configure node 10 in permit mode for routing policy policy1 to permit routing information with a cost of 8.

<Sysname> system-view

[Sysname] route-policy policy1 permit node 10

[Sysname-route-policy-policy1-10] if-match cost 8

if-match extcommunity

Use if-match extcommunity to match BGP routes whose extended community attribute matches a specified extended community list.

Use undo if-match extcommunity to remove the configuration.

Syntax

if-match extcommunity ext-comm-list-number&<1-32>

undo if-match extcommunity [ ext-comm-list-number&<1-32> ]

Default

No match criterion is configured.

Views

Routing policy node view

Predefined user roles

network-admin

mdc-admin

Parameters

ext-comm-list-number&<1-32>: Specifies an extended community list by its number in the range of 1 to 199. &<1-32> indicates that the argument before it can be entered up to 32 times.

Examples

# Configure node 10 in permit mode for routing policy policy1 to match BGP routes whose extended community attribute matches extended community lists 100 and 150.

<Sysname> system-view

[Sysname] ip extcommunity-list 100 permit rt 100:100

[Sysname] ip extcommunity-list 150 permit rt 150:150

[Sysname] route-policy policy1 permit node 10

[Sysname-route-policy-policy1-10] if-match extcommunity 100 150

Related commands

·     apply extcommunity

·     ip extcommunity-list

if-match interface

Use if-match interface to match routes having the specified output interface.

Use undo if-match interface to remove the configuration.

Syntax

if-match interface { interface-type interface-number }&<1-16>

undo if-match interface [ interface-type interface-number ]&<1-16>

Default

No match criterion is configured.

Views

Routing policy node view

Predefined user roles

network-admin

mdc-admin

Parameters

interface-type interface-number: Specifies an interface by its type and number.

&<1-16>: Indicates that the argument before it can be entered up to 16 times.

Usage guidelines

BGP does not support criteria for matching against the output interface of routing information.

Examples

# Configure node 10 in permit mode for routing policy policy1 to permit routes with the output interface VLAN-interface 1.

<Sysname> system-view

[Sysname] route-policy policy1 permit node 10

[Sysname-route-policy-policy1-10] if-match interface vlan-interface 1

if-match local-preference

Use if-match local-preference to match BGP routes having the specified local preference.

Use undo if-match local-preference to restore the default.

Syntax

if-match local-preference preference

undo if-match local-preference

Default

No local preference match criterion is configured.

Views

Routing policy node view

Predefined user roles

network-admin

mdc-admin

Parameters

preference: Specifies a local preference in the range of 0 to 4294967295.

Examples

# Create node 10 in permit mode for routing policy policy1 to match BGP routes having a local preference of 2.

<Sysname> system-view

[Sysname] route-policy policy1 permit node 10

[Sysname-route-policy-policy1-10] if-match preference 2

if-match route-type

Use if-match route-type to configure a route-type match criterion.

Use undo if-match route-type to remove the configuration.

Syntax

if-match route-type { external-type1 | external-type1or2 | external-type2 | internal | is-is-level-1 | is-is-level-2 | nssa-external-type1 | nssa-external-type1or2 | nssa-external-type2 } *

undo if-match route-type [ external-type1 | external-type1or2 | external-type2 | internal | is-is-level-1 | is-is-level-2 | nssa-external-type1 | nssa-external-type1or2 | nssa-external-type2 ] *

Default

No route-type match criterion is configured.

Views

Routing policy node view

Predefined user roles

network-admin

mdc-admin

Parameters

external-type1: Matches OSPF Type 1 external routes.

external-type1or2: Matches OSPF Type 1 and Type 2 external routes.

external-type2: Matches OSPF Type 2 external routes.

internal: Matches OSPF internal routes (including OSPF intra-area and inter-area routes).

is-is-level-1: Matches IS-IS Level-1 routes.

is-is-level-2: Matches IS-IS Level-2 routes.

nssa-external-type1: Matches OSPF NSSA Type 1 external routes.

nssa-external-type1or2: Matches OSPF NSSA Type 1 and 2 external routes.

nssa-external-type2: Matches OSPF NSSA Type 2 external routes.

Examples

# Configure node 10 in permit mode for routing policy policy1 to match OSPF internal routes.

<Sysname> system-view

[Sysname] route-policy policy1 permit node 10

[Sysname-route-policy-policy1-10] if-match route-type internal

if-match tag

Use if-match tag to match routing information having the specified tag.

Use undo if-match tag to restore the default.

Syntax

if-match tag value

undo if-match tag

Default

No tag match criterion is configured.

Views

Routing policy node view

Predefined user roles

network-admin

mdc-admin

Parameters

value: Specifies a tag in the range of 0 to 4294967295.

Examples

# Configure node 10 in permit mode for routing policy policy1 to match RIP, OSPF, and IS-IS routing information having a tag of 8.

<Sysname> system-view

[Sysname] route-policy policy1 permit node 10

[Sysname-route-policy-policy1-10] if-match tag 8

ip as-path

Use ip as-path to create an AS path list.

Use undo ip as-path to remove an AS path list.

Syntax

ip as-path as-path-number { deny | permit } regular-expression

undo ip as-path as-path-number [ regular-expression | deny | permit ]

Default

No AS path list is created.

Views

System view

Predefined user roles

network-admin

mdc-admin

Parameters

as-path-number: Specifies a number for the AS path list, in the range of 1 to 256.

deny: Specifies the match mode for the AS path list as deny.

permit: Specifies the match mode for the AS path list as permit.

regular-expression: Specifies an AS path regular expression, a string of 1 to 63 characters.

Usage guidelines

BGP routing updates contain an AS_PATH attribute field that identifies the ASs through which the routes have passed. An AS path regular expression, for example, ^200. *100$, matches the AS_PATH attribute that starts with AS 200 and ends with AS 100. For the meanings of special characters used in regular expressions, see Fundamentals Configuration Guide.

Examples

# Create AS path list 1 to permit routes whose AS_PATH attribute starts with 10.

<Sysname> system-view

[Sysname] ip as-path 1 permit ^10

Related commands

·     apply as-path

·     display ip as-path

·     if-match ip as-path

ip community-list

Use ip community-list to configure a community list entry.

Use undo ip community-list to remove a community list or entry.

Syntax

ip community-list { basic-comm-list-num | basic basic-comm-list-name } { deny | permit } [ community-number&<1-32> | aa:nn&<1-32> ] [ internet | no-advertise | no-export | no-export-subconfed ] *

undo ip community-list { basic-comm-list-num | basic basic-comm-list-name } [ deny | permit ] [ community-number&<1-32> | aa:nn&<1-32> ] [ internet | no-advertise | no-export | no-export-subconfed ] *

ip community-list { adv-comm-list-num | advanced adv-comm-list-name } { deny | permit } regular-expression

undo ip community-list { adv-comm-list-num | advanced adv-comm-list-name } [ deny | permit ] [ regular-expression ]

Default

No community list is configured.

Views

System view

Predefined user roles

network-admin

mdc-admin

Parameters

basic-comm-list-num: Specifies a number for the basic community list, in the range of 1 to 99.

basic: Specifies a name for the basic community list.

advanced: Specifies a name for the advanced community list.

basic-comm-list-name: Specifies the basic community list name, a case-sensitive string of 1 to 63 characters that cannot comprise only letters.

adv-comm-list-name: Specifies the advanced community list name, a case-sensitive string of 1 to 63 characters that cannot comprise only letters.

adv-comm-list-num: Specifies the advanced community list number in the range of 100 to 199.

regular-expression: Specifies a regular expression for the advanced community list, a string of 1 to 63 characters. For more information about regular expressions, see Fundamentals Configuration Guide.

deny: Specifies the match mode for the community list as deny.

permit: Specifies the match mode for the community list as permit.

community-number&<1-32>: Specifies a community sequence number in the range of 1 to 4294967295. &<1-32> indicates that the argument before it can be entered up to 32 times.

aa:nn&<1-32>: Specifies a community number. Both aa and nn are in the range of 0 to 65535. &<1-32> indicates that the argument before it can be entered up to 32 times.

internet: Specifies the INTERNET community attribute. Routes with this attribute can be advertised to all BGP peers. By default, all routes have this attribute.

no-advertise: Specifies the NO_ADVERTISE community attribute. Routes with this attribute cannot be advertised to other BGP peers.

no-export: Specifies the NO_EXPORT community attribute. Routes with this attribute cannot be advertised out of the local AS or the local confederation but can be advertised to other ASs in the confederation.

no-export-subconfed: Specifies the NO_EXPORT_SUBCONFED community attribute. Routes with this attribute cannot be advertised out of the local AS, or to other sub-ASs in the local confederation.

Examples

# Configure basic community list 1 to permit routing information with the INTERNET community attribute.

<Sysname> system-view

[Sysname] ip community-list 1 permit internet

# Configure advanced community list 100 to permit routing information with the COMMUNITY attribute starting with 10.

<Sysname> system-view

[Sysname] ip community-list 100 permit ^10

Related commands

·     apply comm-list delete

·     apply community

·     display ip community-list

·     if-match community

ip extcommunity-list

Use ip extcommunity-list to define an extended community list entry.

Use undo ip extcommunity-list to remove an extended community list.

Syntax

ip extcommunity-list ext-comm-list-number { deny | permit } { rt route-target }&<1-32>

undo ip extcommunity-list ext-comm-list-number [ { deny | permit } [ rt route-target ]&<1-32> ]

Default

No extended community list is defined.

Views

System view

Predefined user roles

network-admin

mdc-admin

Parameters

ext-comm-list-number: Specifies a number for the extended community list, in the range of 1 to 199.

deny: Specifies the match mode for the extended community list as deny.

permit: Specifies the match mode for the extended community list as permit.

{ rt route-target }&<1-32>: Specifies the RT extended community attribute, a string of 3 to 21 characters. &<1-32> indicates that the argument before it can be entered up to 32 times.

A route-target has the following forms:

·     A 16-bit AS number—A 32-bit self-defined number, for example, 101:3. The AS number is in the range of 0 to 65535, and the self-defined number is in the range of 0 to 4294967295.

·     A 32-bit IP address—A 16-bit self-defined number, for example, 192.168.122.15:1. The self-defined number is in the range of 0 to 65535.

·     A 32-bit AS number—A 16-bit self-defined number, for example, 70000:3. The AS number is in the range of 65536 to 4294967295, and the self-defined number is in the range of 0 to 65535.

Examples

# Define extended community list 1 to permit routes with RT 200:200 to pass.

<Sysname> system-view

[Sysname] ip extcommunity-list 1 permit rt 200:200

Related commands

·     apply extcommunity

·     display ip extcommunity-list

·     if-match extcommunity

route-policy

Use route-policy to create a routing policy and a node, and enter routing policy node view.

Use undo route-policy to remove a routing policy or a node of it.

Syntax

route-policy route-policy-name { deny | permit } node node-number

undo route-policy route-policy-name [ deny | permit ] [ node node-number ]

Default

No routing policy is created.

Views

System view

Predefined user roles

network-admin

mdc-admin

Parameters

route-policy-name: Specifies a name for the routing policy, a case-sensitive string of 1 to 63 characters.

deny: Specifies the deny match mode for the routing policy node. If a route matches all the if-match clauses of the node, it is denied without matching against the next node. If not, it matches against the next node.

permit: Specifies the permit match mode for the routing policy node. If a route matches all the if-match clauses of the node, it is handled by the apply clauses of the node. If not, it matches against the next node.

node node-number: Specifies a number for the node, in the range of 0 to 65535. A node with a smaller number is matched first.

Usage guidelines

Use a routing policy to filter routing information. A routing policy can contain several nodes and each node comprises a set of if-match and apply clauses. The if-match clauses define the match criteria of the node and the apply clauses define the actions to be taken on packets matching the criteria. The relation between the if-match clauses of a node is logic AND: all the if-match clauses must be met. The relation between nodes is logic OR: a packet passing a node passes the routing policy.

Examples

# Create node 10 in permit mode for routing policy policy1 and enter routing policy node view.

<Sysname> system-view

[Sysname] route-policy policy1 permit node 10

[Sysname-route-policy-policy1-10]

Related commands

display route-policy

IPv4 routing policy commands

apply fast-reroute

Use apply fast-reroute to set a backup link for fast route (FRR).

Use undo apply fast-reroute to remove the configuration.

Syntax

apply fast-reroute { backup-interface interface-type interface-number [ backup-nexthop ip-address ] | backup-nexthop ip-address }

undo apply fast-reroute

Default

No backup link for FRR is configured.

Views

Routing policy node view

Predefined user roles

network-admin

mdc-admin

Parameters

backup-interface interface-type interface-number: Specifies a backup output interface. If the specified interface is a non-P2P interface (including NBMA and broadcast interfaces, such as an Ethernet interface or a VLAN interface), you must also specify a backup next hop.

backup-nexthop ip-address: Specifies a backup next hop.

Usage guidelines

This command sets a backup link in the routing policy for FRR.

Using the routing policy, a routing protocol can designate a backup link for specific routes to implement FRR. When the primary link fails, FRR immediately directs packets to the backup link to minimize interruption time.

Examples

# Configure node 10 of routing policy policy1 to set the backup output interface VLAN-interface 1 and backup next hop 193.1.1.8 for the route destined to 100.1.1.0/24.

<Sysname> system-view

[Sysname] ip prefix-list abc index 10 permit 100.1.1.0 24

[Sysname] route-policy policy1 permit node 10

[Sysname-route-policy-policy1-10] if-match ip address prefix-list abc

[Sysname-route-policy-policy1-10] apply fast-reroute backup-interface vlan-interface 1 backup-nexthop 193.1.1.8

apply ip-address next-hop

Use apply ip-address next-hop to set a next hop for IPv4 routes.

Use undo apply ip-address next-hop to restore the default.

Syntax

apply ip-address next-hop ip-address [ public | vpn-instance vpn-instance-name ]

undo apply ip-address next-hop

Default

No next hop is set for IPv4 routes.

Views

Routing policy node view

Predefined user roles

network-admin

mdc-admin

Parameters

ip-address: Specifies the next hop IP address.

public: Specifies the public network.

vpn-instance vpn-instance-name: Specifies an MPLS L3VPN instance by its name, a case-sensitive string of 1 to 31 characters.

Usage guidelines

This command cannot set a next hop for redistributed routes.

If you do not provide the public keyword or vpn-instance vpn-instance-name option for this command, the next hop belongs to the public network.

Examples

# Configure node 10 in permit mode for routing policy policy1 to set next hop 193.1.1.8 for routes matching AS path list 1.

<Sysname> system-view

[Sysname] route-policy policy1 permit node 10

[Sysname-route-policy-policy1-10] if-match as-path 1

[Sysname-route-policy-policy1-10] apply ip-address next-hop 193.1.1.8

display ip prefix-list

Use display ip prefix-list to display IPv4 prefix list statistics.

Syntax

display ip prefix-list [ name prefix-list-name ]

Views

Any view

Predefined user roles

network-admin

network-operator

mdc-admin

mdc-operator

Parameters

name prefix-list-name: Specifies an IP prefix list by its name, a case-sensitive string of 1 to 63 characters. Without this argument, this command displays statistics for all IPv4 prefix lists.

Examples

# Display the statistics for IPv4 prefix list abc.

<Sysname> display ip prefix-list name abc

Prefix-list: abc

 Permitted 0

 Denied 0

         index: 10        deny   6.6.6.0/24              ge  26  le  28

Table 87 Command output

Field

Description

Prefix-list

Name of the IPv4 prefix list.

Permitted

Number of routes matching the criterion.

Denied

Number of routes not matching the criterion.

index

Index of an item.

deny

Match mode of the item:

·     permit.

·     deny.

6.6.6.0/24

IP address and mask.

ge

Greater-equal, the lower mask length.

le

Less-equal, the upper mask length.

 

Related commands

·     ip prefix-list

·     reset ip prefix-list

if-match ip

Use if-match ip to match IPv4 routes whose destination, next hop, or source address matches the specified IPv4 prefix list.

Use undo if-match ip to remove the configuration.

Syntax

if-match ip { address | next-hop | route-source } { acl acl-number | prefix-list prefix-list-name }

undo if-match ip { address | next-hop | route-source } [ acl | prefix-list ]

Default

No IPv4 prefix list match criterion is configured.

Views

Routing policy node view

Predefined user roles

network-admin

mdc-admin

Parameters

address: Matches the destination address of IPv4 routes.

next-hop: Matches the next hop of IPv4 routes.

route-source: Matches the source address of IPv4 route information.

acl acl-number: Specifies an ACL by its number in the range of 2000 to 3999 for address, and in the range of 2000 to 2999 for next-hop and route-source.

prefix-list prefix-list-name: Specifies an IP prefix list by its name, a case-sensitive string of 1 to 63 characters.

Examples

# Configure node 10 of routing policy policy1 to match IPv4 routing information whose next hop matches IP prefix list p1.

<Sysname> system-view

[Sysname] route-policy policy1 permit node 10

[Sysname-route-policy-policy1-10] if-match ip next-hop prefix-list p1

ip prefix-list

Use ip prefix-list to configure an IPv4 prefix list or an item for the list.

Use undo ip prefix-list to remove an IPv4 prefix list or an item of it.

Syntax

ip prefix-list prefix-list-name [ index index-number ] { deny | permit } ip-address mask-length [ greater-equal min-mask-length ] [ less-equal max-mask-length ]

undo ip prefix-list prefix-list-name [ index index-number ]

Default

No IPv4 prefix list is configured.

Views

System view

Predefined user roles

network-admin

mdc-admin

Parameters

prefix-list-name: Specifies a name for the IPv4 prefix list, a case-sensitive string of 1 to 63 characters.

index-number: Specifies an index number for an IPv4 prefix list item, in the range of 1 to 65535. An item with a smaller number is matched first.

deny: Specifies the deny mode. If a route matches the item, the route is denied without matching against the next item; if not, the route matches against the next item (suppose the IPv4 prefix list has multiple items).

permit: Specifies the permit mode. If a route matches the item, it passes the IPv4 prefix list. If not, it matches against the next item (suppose the IPv4 prefix list has multiple items).

ip-address mask-length: Specifies an IPv4 prefix and mask length. The value range for the mask-length argument is 0 to 32.

min-mask-length, max-mask-length: Specifies a prefix length range. The greater-equal keyword means "greater than or equal to" and the less-equal keyword means "less than or equal to." The range relation is mask-length <= min-mask-length <= max-mask-length <= 32. If only the min-mask-length is specified, the prefix length range is [ min-mask-length, 32 ]. If only the max-mask-length is specified, the prefix length range is [ mask-length, max-mask-length ]. If both min-mask-length and max-mask-length are specified, the prefix length range is [ min-mask-length, max-mask-length ].

Usage guidelines

An IPv4 prefix list is used to filter IPv4 addresses. It can contain multiple items, each of which specifies a range of IPv4 prefixes. The relation between the items is logic OR. If an item is passed, the IPv4 prefix list is passed. If no item is passed, the IP prefix list cannot be passed.

If both ip-address and mask-length are specified as 0.0.0.0 0, only the default route will be matched.

To match all routes, use 0.0.0.0 0 less-equal 32.

Examples

# Configure IP prefix list p1 to permit routes destined for network 10.0.0.0/8 and with mask length 17 or 18.

<Sysname> system-view

[Sysname] ip prefix-list p1 permit 10.0.0.0 8 greater-equal 17 less-equal 18

Related commands

·     display ip prefix-list

·     reset ip prefix-list

reset ip prefix-list

Use reset ip prefix-list to clear IPv4 prefix list statistics.

Syntax

reset ip prefix-list [ prefix-list-name ]

Views

User view

Predefined user roles

network-admin

mdc-admin

Parameters

prefix-list-name: Specifies an IP prefix list by its name, a case-sensitive string of 1 to 63 characters. Without this argument, this command clears statistics for all IPv4 prefix lists.

Examples

# Clear the statistics for IPv4 prefix list abc.

<Sysname> reset ip prefix-list abc

Related commands

·     display ip prefix-list

·     ip prefix-list

 


Index

A B C D E F G H I L M N O P R S T V


A

abr-summary (OSPF area view),72

address-family ipv4,1

address-family ipv4,246

advertise-rib-active,246

aggregate,247

apply as-path,370

apply comm-list delete,370

apply community,371

apply cost,372

apply cost-type,373

apply default-next-hop,357

apply extcommunity,374

apply fast-reroute,392

apply ip-address next-hop,393

apply isis,374

apply local-preference,375

apply next-hop,357

apply origin,376

apply output-interface NULL 0,358

apply preference,376

apply preferred-value,377

apply prefix-priority,377

apply tag,378

area (OSPF view),72

area-authentication-mode,169

asbr-summary,73

authentication-mode,74

auto-cost enable,170

B

balance,250

balance as-path-neglect,251

bandwidth-reference (IS-IS view),171

bandwidth-reference (OSPF view),76

bestroute as-path-neglect,251

bestroute compare-med,252

bestroute med-confederation,253

bgp,254

bgp update-delay on-startup,254

C

checkzero,37

circuit-cost,171

compare-different-as-med,255

confederation id,256

confederation nonstandard,257

confederation peer-as,257

continue,379

cost-style,172

D

dampening,258

default,76

default cost,37

default local-preference,259

default med,260

default-cost (OSPF area view),77

default-route,38

default-route imported,261

default-route-advertise (IS-IS view),173

default-route-advertise (OSPF view),78

delete static-routes all,28

description (OSPF/OSPF area view),79

discard-route,80

display bgp dampening parameter ipv4 unicast,262

display bgp group,263

display bgp network,265

display bgp non-stop-routing status,266

display bgp paths,267

display bgp peer,268

display bgp routing-table dampened ipv4 unicast,272

display bgp routing-table flap-info ipv4 unicast,273

display bgp routing-table ipv4 unicast,275

display bgp routing-table ipv4 unicast advertise-info,278

display bgp routing-table ipv4 unicast as-path-acl,280

display bgp routing-table ipv4 unicast community-list,281

display bgp routing-table ipv4 unicast peer,282

display bgp routing-table ipv4 unicast statistics,284

display bgp update-group,285

display ecmp mode,1

display ip as-path,379

display ip community-list,380

display ip extcommunity-list,381

display ip policy-based-route,359

display ip policy-based-route interface,360

display ip policy-based-route local,362

display ip policy-based-route setup,363

display ip prefix-list,393

display ip routing-table,2

display ip routing-table acl,5

display ip routing-table ip-address,8

display ip routing-table prefix-list,10

display ip routing-table protocol,12

display ip routing-table statistics,13

display isis brief,174

display isis graceful-restart event-log,175

display isis graceful-restart status,176

display isis interface,178

display isis lsdb,180

display isis name-table,183

display isis peer,184

display isis redistribute,187

display isis route,188

display isis spf-tree,191

display isis statistics,197

display osi,199

display osi statistics,200

display ospf,80

display ospf abr-asbr,86

display ospf abr-summary,87

display ospf asbr-summary,89

display ospf event-log,91

display ospf fast-reroute lfa-candidate,94

display ospf graceful-restart,95

display ospf interface,98

display ospf lsdb,100

display ospf nexthop,103

display ospf peer,104

display ospf peer statistics,107

display ospf request-queue,108

display ospf retrans-queue,109

display ospf routing,110

display ospf spf-tree,113

display ospf statistics,116

display ospf vlink,120

display rib attribute,15

display rib graceful-restart,16

display rib nib,18

display rip,39

display rip database,40

display rip interface,41

display rip route,43

display route-direct nib,22

display route-policy,382

display router id,121

display route-static nib,28

display route-static routing-table,31

domain-authentication-mode,202

dscp,122

E

ebgp-interface-sensitive,287

ecmp mode enhanced,24

enable link-local-signaling,122

enable out-of-band-resynchronization,123

event-log,123

F

fast-reroute,45

fast-reroute,203

fast-reroute (OSPF view),124

fast-reroute route-policy,288

fib lifetime,25

filter (OSPF area view),125

filter-policy export,289

filter-policy export,46

filter-policy export,203

filter-policy export (OSPF view),126

filter-policy import,47

filter-policy import,204

filter-policy import,290

filter-policy import (OSPF view),127

flash-flood,206

G

graceful-restart,48

graceful-restart,206

graceful-restart,291

graceful-restart (OSPF view),128

graceful-restart helper enable,129

graceful-restart helper strict-lsa-checking,130

graceful-restart interval (OSPF view),130

graceful-restart suppress-sa,207

graceful-restart t1,208

graceful-restart t2,208

graceful-restart t3,209

graceful-restart timer purge-time,292

graceful-restart timer restart,293

graceful-restart timer wait-for-rib,294

group,295

H

host-advertise,131

host-route,49

I

if-match acl,364

if-match as-path,382

if-match community,383

if-match cost,384

if-match extcommunity,384

if-match interface,385

if-match ip,394

if-match local-preference,386

if-match route-type,386

if-match tag,387

if-match vxlan-id,364

ignore-first-as,296

import-route,297

import-route,50

import-route,210

import-route (OSPF view),132

import-route isis level-1 into level-2,211

import-route isis level-2 into level-1,212

import-route limit,213

ip as-path,388

ip community-list,389

ip extcommunity-list,390

ip local policy-based-route,365

ip policy-based-route,366

ip policy-based-route egress,366

ip policy-based-route vxlan-mode enable,367

ip prefix-list,395

ip route-static,33

ip route-static default-preference,35

ip route-static primary-path-detect bfd echo,36

ip vpn-instance (BGP view),298

isis,214

isis authentication-mode,214

isis bfd enable,216

isis circuit-level,216

isis circuit-type p2p,217

isis cost,218

isis dis-name,218

isis dis-priority,219

isis enable,220

isis mib-binding,221

isis primary-path-detect bfd echo,221

isis silent,222

isis small-hello,222

isis timer csnp,223

isis timer hello,224

isis timer holding-multiplier,225

isis timer lsp,226

isis timer retransmit,226

is-level,228

is-name,228

is-name map,229

ispf enable,133

ispf enable,227

L

log-peer-change,134

log-peer-change,230

log-peer-change,299

log-route-flap,300

lsa-arrival-interval,134

lsa-generation-interval,136

lsdb-overflow-interval,135

lsdb-overflow-limit,136

lsp-fragments-extend,230

lsp-length originate,231

lsp-length receive,232

M

maximum load-balancing,51

maximum load-balancing (IS-IS view),232

maximum load-balancing (OSPF view),137

N

network,51

network,300

network (OSPF area view),137

network short-cut,301

network-entity,233

non-stop-routing,302

nssa,138

O

opaque-capability enable,140

ospf,140

ospf area,141

ospf authentication-mode,142

ospf bfd enable,143

ospf cost,144

ospf dr-priority,145

ospf fast-reroute lfa-backup,145

ospf mib-binding,146

ospf mtu-enable,146

ospf network-type,147

ospf prefix-suppression,148

ospf primary-path-detect bfd echo,149

ospf timer dead,150

ospf timer hello,150

ospf timer poll,151

ospf timer retransmit,152

ospf trans-delay,152

output-delay,52

P

peer,53

peer,153

peer advertise-community,303

peer advertise-ext-community,304

peer allow-as-loop,305

peer as-number (for a BGP peer group),306

peer as-number (for a BGP peer),307

peer as-path-acl,308

peer bfd,309

peer capability-advertise conventional,311

peer capability-advertise route-refresh,312

peer capability-advertise suppress-4-byte-as,313

peer connect-interface,314

peer default-route-advertise,315

peer description,316

peer ebgp-max-hop,317

peer enable,318

peer fake-as,320

peer filter-policy,321

peer group,322

peer ignore,323

peer ignore-originatorid,324

peer keep-all-routes,325

peer low-memory-exempt,326

peer next-hop-local,327

peer password,328

peer preferred-value,330

peer prefix-list,331

peer public-as-only,332

peer reflect-client,333

peer route-limit,334

peer route-policy,335

peer route-update-interval,336

peer source-address,337

peer substitute-as,338

peer timer,339

peer ttl-security,341

pic,342

pic,154

policy-based-route,368

preference,234

preference,155

preference,343

preference,53

prefix-priority,155

prefix-suppression,156

primary-path-detect bfd,344

priority,234

protocol lifetime,25

R

reflect between-clients,344

reflector cluster-id,345

refresh bgp,346

reset bgp,347

reset bgp all,348

reset bgp dampening ipv4 unicast,349

reset bgp flap-info ipv4 unicast,350

reset ip policy-based-route statistics,368

reset ip prefix-list,396

reset ip routing-table statistics protocol,26

reset isis all,235

reset isis graceful-restart event-log,236

reset isis peer,236

reset osi statistics,237

reset ospf event-log,157

reset ospf process,158

reset ospf redistribution,159

reset ospf statistics,157

reset rip process,54

reset rip statistics,55

rfc1583 compatible,159

rib,27

rip,55

rip authentication-mode,56

rip bfd enable,57

rip bfd enable destination,57

rip default-route,58

rip enable,59

rip input,60

rip max-packet-length,60

rip metricin,61

rip metricout,62

rip mib-binding,63

rip output,63

rip poison-reverse,64

rip primary-path-detect bfd echo,64

rip split-horizon,65

rip summary-address,66

rip version,66

route-policy,391

router id,160

router id (system view),351

router-id (BGP view),352

router-id (BGP-VPN instance view),352

S

set-overload,237

silent-interface,67

silent-interface (OSPF view),161

snmp context-name,238

snmp trap rate-limit,163

snmp-agent trap enable bgp,353

snmp-agent trap enable isis,239

snmp-agent trap enable ospf,161

spf-schedule-interval,163

stub (OSPF area view),164

stub-router,165

summary,68

summary (IS-IS view),240

summary automatic,354

T

timer,355

timer lsp-generation,241

timer lsp-max-age,242

timer lsp-refresh,243

timer spf,243

timers,69

transmit-pacing,166

V

validate-source-address,70

version,70

virtual-system,244

vlink-peer (OSPF area view),167


 

  • Cloud & AI
  • InterConnect
  • Intelligent Computing
  • Security
  • SMB Products
  • Intelligent Terminal Products
  • Product Support Services
  • Technical Service Solutions
All Services
  • Resource Center
  • Policy
  • Online Help
All Support
  • Become a Partner
  • Partner Resources
  • Partner Business Management
All Partners
  • Profile
  • News & Events
  • Online Exhibition Center
  • Contact Us
All About Us
新华三官网