This configuration creates four virtual channels on the interface t3-1/0/0.0. Three of them (branch1-vc, branch2-vc, and branch3-vc) are shaped to 1.5 Mbps. The fourth virtual channel is the default (default-vc), and it is not shaped, so it can use the full interface bandwidth. The output filter on the interface sends all traffic with a destination address matching 192.168.10.0/24 to branch1-vc, and similar configurations are set for branch2-vc and branch3-vc. Traffic not matching any of the addresses goes to the default, unshaped virtual channel.
- class-of-service {
-
- interfaces {
-
- t3-1/0/0 {
-
- unit 0 {
- virtual-channel-group wan-vc-group;
- }
- }
- }
-
- virtual-channels {
- branch1-vc;
- branch2-vc;
- branch3-vc;
- default-vc;
- }
-
- virtual-channel-groups {
-
- wan-vc-group {
-
- branch1-vc {
- scheduler-map interface-global;
- shaping-rate 1.5m;
- }
-
- branch2-vc {
- scheduler-map interface-global;
- shaping-rate 1.5m;
- }
-
- branch3-vc {
- scheduler-map interface-global;
- shaping-rate 1.5m;
- }
-
- default-vc {
- scheduler-map interface-global;
- default;
- }
- }
- }
- }
- firewall {
-
- family inet {
-
- filter choose-vc {
-
- term branch1 {
-
- from {
- destination 192.168.10.0/24;
- }
-
- then {
- accept;
- virtual-channel branch1-vc;
- }
- }
-
- term branch2 {
-
- from {
- destination 192.168.11.0/24;
- }
-
- then {
- accept;
- virtual-channel branch2-vc;
- }
- }
-
- term branch3 {
-
- from {
- destination 192.168.12.0/24;
- }
-
- then {
- accept;
- virtual-channel branch3-vc;
- }
- }
-
- term default {
-
- then {
- accept;
- }
- }
- }
- }
- }
-
- interfaces {
-
- t3-1/0/0 {
- per-unit-scheduler;
-
- unit 0 {
-
- family inet {
- filter output choose-vc;
- }
- }
- }
- }