Configuration example of voice entity selection priority rules
Figure 29 and the following describe the voice entity selection priority rule configuration on Router A and Router B.
Figure 29: Network diagram
Configure Router A:
<RouterA> system-view [RouterA] voice-setup [RouterA-voice] dial-program
# Configure POTS entity 1000.
[RouterA-voice-dial] entity 1000 pots [RouterA-voice-dial-entity1000] match-template 10001234$ [RouterA-voice-dial-entity1000] line 1/0 [RouterA-voice-dial-entity1000] quit
# Configure VoIP entity 2000, VoIP entity 2001, and VoIP entity 2002.
[RouterA-voice-dial] entity 2000 voip [RouterA-voice-dial-entity2000] match-template 20001234$ [RouterA-voice-dial-entity2000] address sip ip 1.1.1.2 [RouterA-voice-dial-entity2000] priority 10 [RouterA-voice-dial-entity2000] quit [RouterA-voice-dial] entity2001 voip [RouterA-voice-dial-entity2001] match-template 2000123.$ [RouterA-voice-dial-entity2001] address sip ip 1.1.1.2 [RouterA-voice-dial-entity2000] priority 5 [RouterA-voice-dial-entity2001] quit [RouterA-voice-dial] entity2002 voip [RouterA-voice-dial-entity2002] match-template 2000....$ [RouterA-voice-dial-entity2002] address sip ip 1.1.1.2 [RouterA-voice-dial-entity2002] quit
Configure Router B:
<RouterB> system-view [RouterB] voice-setup [RouterB-voice] dial-program
# Configure POTS entity 2000.
[RouterB-voice-dial] entity 2000 pots [RouterB-voice-dial-entity2000] match-template 20001234$ [RouterB-voice-dial-entity2000] line 1/0
Configure different voice entity selection priority rules:
Configure voice entities to be selected in sequence of exact match, priority, and random selection.
<RouterA> system-view [RouterA] voice-setup [RouterA-voice] dial-program [RouterA-voice-dial] select-rule rule-order 1 2 3
After Telephone dials 20001234, the number will match VoIP entity 2000.
Configure voice entities to be selected in sequence of priority, exact match, and random selection.
<RouterA> system-view [RouterA] voice-setup [RouterA-voice] dial-program [RouterA-voice-dial] select-rule rule-order 2 1 3
After Telephone A dials 20001234, the number will match VoIP entity 2002.
Configure voice entities to be selected at random.
<RouterA> system-view [RouterA] voice-setup [RouterA-voice] dial-program [RouterA-voice-dial] select-rule rule-order 3
After Telephone dials 20001234, the number will match VoIP entity 2000, 2001, or 2002 at random.