Creating a match rule

Creating a match rule that references an LB class

Step

Command

Remarks

1. Enter system view.

system-view

N/A

2. Enter LB class view.

loadbalance class class-name

N/A

3. Create a match rule that references an LB class.

match [ match-id ] class class-name

By default, an LB class does not have any match rules.

Creating a source IP address match rule

Step

Command

Remarks

1. Enter system view.

system-view

N/A

2. Enter LB class view.

loadbalance class class-name

N/A

3. Create a source IP address match rule.

match [ match-id ] source { ip address ipv4-address [ mask-length | mask ] | ipv6 address ipv6-address [ prefix-length ] }

By default, an LB class does not have any match rules.

Creating a destination IP address match rule

Step

Command

Remarks

1. Enter system view.

system-view

N/A

2. Enter LB class view.

loadbalance class class-name

N/A

3. Create a destination IP address match rule.

match [ match-id ] destination { ip address ipv4-address [ mask-length | mask ] | ipv6 address ipv6-address [ prefix-length ] }

By default, an LB class does not have any match rules.

Creating an ACL match rule

If the specified ACL does not exist, the ACL match rule does not take effect.

To create an ACL match rule:

Step

Command

Remarks

1. Enter system view.

system-view

N/A

2. Enter LB class view.

loadbalance class class-name

N/A

3. Create an ACL match rule.

match [ match-id ] acl [ ipv6 ] { acl-number | name acl-name }

By default, an LB class does not have any match rules.

Creating a domain name match rule

Step

Command

Remarks

1. Enter system view.

system-view

N/A

2. Enter LB class view.

loadbalance class class-name

N/A

3. Create a domain name match rule.

match [ match-id ] domain-name domain-name

By default, an LB class does not have any match rules.