AR router is configured with default routes

19

The AR router is configured with default routes. If the preference of a static route is not set, the default preference of the static route is 60. When both the destination IP address and mask are 0.0.0.0, the configured route is the default route. If the routing table does not have matching routes, the default route is used to forward packets.
<Huawei> system-view
[Huawei] ip route-static 0.0.0.0 0.0.0.0 172.16.0.1 //Configure the default route and specify the next hop as 172.16.0.1.<

Other related questions:
What are priorities of static routes and default routes of the AR router
Default routes can be statically configured or dynamically generated through dynamic routing protocols. If the default route is dynamically generated through dynamic routing protocols, its priority is the same as corresponding protocol. If the default route is statically configured, the default priority is 60, which is similar to that of the static route. Routes comply with the longest mask bit match principle. Specific routes are matched first, and then default routes are matched if the specific routes are not matched.

Priorities of policy-based routing and default routing for an AR router
Policy-based routing has a higher priority than default routing. If policy-based routing and default routing coexist, only policy-based routing takes effect. After policy-based routing loses effect, default routing takes effect.

Differences between policy-based routing and default routing
The operation object of policy-based routing is packets. Even if a routing table is available, packets are not forwarded according to the routing table, and they are forwarded based on a policy according to requirements. According to the conventional routing and forwarding principle, packets are forwarded according to the destination addresses of the packets. Nowadays, more and more users expect that packets are forwarded and routed according to their defined policies on the basis of the conventional routing and forwarding. Policy-based routing enables the network administrator to formulate routing policies according to the source and destination addresses of packets, packet size, and link quality in order to change the forwarding paths of packets and meet user requirements.

Method used to configure a static route on the AR router
The procedure for configuring static route on the AR router is as follows: - Use command lines. [RouterA] ip route-static 0.0.0.0 0.0.0.0 1.1.4.2 //Configure a default route that is often used at the egress of a small-sized company. The address 1.1.4.2 is the gateway address of the carrier. When the specific route cannot be matched, data flows are forwarded to 1.1.4.2. If the device has only one default route, all the data packets are forwarded to 1.1.4.2 by default. [RouterB] ip route-static 1.1.3.0 255.255.255.0 1.1.4.6 //Configure the route to network segment 1.1.3.0/24. The next hop of the route is 1.1.4.6, which is the specific route but not the default route. Use the web platform. For details, see Example for Configuring IPv4 Static Routes .

Configure rules of local policy routing on an AR router
Run the system-view command to access the system view. Run the policy-based-routepolicy-name { deny | permit } nodenode-id command to create policy-based routing and policy points. If policy points have been created, access the local policy routing view. By default, no local policy routing or policy point has been created. Note: For packets that matches a rule, permit indicates a policy routing is applied; while deny indicates no policy routing is applied. Repeat the previous command to create multiple policy points for a local policy routing. The policy points are specified based on the node ID. The smaller the node ID, the higher the priority, and corresponding policy is implemented preferentially. Run the if-match aclacl-number command to set ACL rules of IP packets. The command can be implemented once or twice. By default, rules about IP addresses are not configured in local policy routing. Note: If an ACL rule is set to permit, the router implements an action for packets that match the rule. When a policy point is permit, packets that match the rule are routed based on a policy. When a policy point is deny, packets that match the rule are not routed based on a policy, and are forwarded according to the destination IP addresses. If an ACL is configured with rules, packets that do not match any rule are forwarded according to the destination IP addresses. If an ACL rule is set to deny or an ACL is not configured with rules, local policy routing that applies the ACL does not take effect. Therefore, packets are forwarded according to the destination IP addresses. Run the if-match packet-lengthmin-lengthmax-length command to set a length rule of IP packets. By default, length rules of IP packets are not configured in local policy routing.

If you have more questions, you can seek help from following ways:
To iKnow To Live Chat
Scroll to top