bandwidth [kbps|percent n]
The bandwidth command in policy-map class configuration mode allocates a minimum bandwidth guarantee (in kbps or as a percentage) to a specific traffic class during congestion, ensuring QoS for critical applications.
bandwidth [kbps|percent n]When to Use This Command
- Guarantee 1 Mbps for VoIP traffic in a WAN link to prevent jitter and packet loss.
- Allocate 50% of interface bandwidth to mission-critical database replication traffic.
- Reserve 256 kbps for network management traffic (SNMP, syslog) to ensure reachability during congestion.
- Shape video streaming traffic to 2 Mbps to prevent starvation of other classes.
Command Examples
Allocate bandwidth in kbps for VoIP class
bandwidth 1000Router(config-pmap-c)# bandwidth 1000 Router(config-pmap-c)#
The command assigns a minimum of 1000 kbps (1 Mbps) to the traffic class. No output is shown if successful; the prompt returns without error.
Allocate bandwidth as a percentage of interface bandwidth
bandwidth percent 30Router(config-pmap-c)# bandwidth percent 30 Router(config-pmap-c)#
This reserves 30% of the interface bandwidth for the class. The percentage is relative to the interface bandwidth configured with the 'bandwidth' interface command.
Understanding the Output
The bandwidth command does not produce direct output; it silently configures the policy. To verify, use 'show policy-map [policy-name]' or 'show policy-map interface [interface]'. In the output of 'show policy-map interface', look for the 'Bandwidth' field under each class. For example: 'Bandwidth 1000 (kbps)' indicates a guaranteed 1000 kbps. If the value is lower than expected, check the interface bandwidth or total allocated bandwidth (cannot exceed interface bandwidth). A common issue is oversubscription: if the sum of bandwidths exceeds 100% (or interface bandwidth), the router will reject the policy-map with an error during attachment. Also, note that the 'bandwidth' command is only effective during congestion; if the link is not congested, classes can exceed their allocated bandwidth.
CCNA Exam Tips
CCNA exam tip: The 'bandwidth' command in policy-map class config is used for guaranteed bandwidth, not shaping or policing. Know the difference.
CCNA exam tip: When using 'bandwidth percent', the percentage is based on the interface bandwidth (set with 'bandwidth' interface command), not the actual link speed.
CCNA exam tip: You cannot mix 'bandwidth' and 'bandwidth percent' in the same policy-map; choose one method per class.
CCNA exam tip: The sum of all 'bandwidth' allocations in a policy-map must not exceed the interface bandwidth; otherwise, the policy-map will be rejected.
Common Mistakes
Mistake: Using 'bandwidth' without first configuring a class-map and policy-map. Consequence: The command is ignored or applied to the default class.
Mistake: Allocating more total bandwidth than available on the interface. Consequence: The policy-map will fail to attach with an 'exceeded bandwidth' error.
Mistake: Confusing 'bandwidth' (guarantee) with 'shape average' (traffic shaping). Consequence: Misconfigured QoS leading to incorrect traffic treatment.
Related Commands
class [class-map-name]
The class command in policy-map configuration mode associates a traffic class (defined via class-map) with a set of QoS actions (like policing, shaping, or marking) within a service policy.
show policy-map interface
Displays the current QoS policy applied to an interface, including per-class statistics such as packets matched, bytes, and actions taken, used to verify and troubleshoot QoS configurations.
Practice for the CCNA 200-301
Test your knowledge with hundreds of CCNA practice questions covering all exam domains.
Practice CCNA Questions