Chapter 8 Data Models and Dynamic Templates

For diagrams, tables, or exact code formatting, .

JOHN W. CAPOBIANCOPRINTED PAGE 154
{%                  if platform_defaults.type == 3750 %} 
 srr-queue bandwidth share {{ platform_qos.platform_interface_values.srr_queue_share 
}} 
{%                      if platform_defaults.type == 2960 %} 
 srr-queue bandwidth shape {{ platform_qos.platform_interface_values.srr_queue_shape 
}} 
{%                      else %} 
 srr-queue bandwidth shape  {{ platform_qos.platform_interface_values.srr_queue_shape 
}} 
{%                      endif %} 
 priority-queue out 
{%                  endif %} 
 storm-control broadcast level 30.00 
 storm-control multicast level 30.00 
 no lldp transmit 
 no lldp receive 
 spanning-tree portfast 
 spanning-tree bpduguard enable 
 service-policy input PM-QoS-IN 
{%                  endif %} 
{%              endif %} 
{%          endfor %} 
{%  endif %}  
 
Security Ports 
 
Security ports are different in that they use port-security and mac-sticky instead of 802.1x as they are 
static IP cameras that do not move.
{%  if host_interfaces is defined %} 
{%      for host_interface in host_interfaces %} 
{%          if host_interfaces[host_interface].type is defined %} 
{%              if host_interfaces[host_interface].type == "SECURITY" %} 
interface {{ host_interface }} 
 switchport mode access 
 switchport nonegotiate 
 switchport access vlan {{ host_interfaces[host_interface].vlan }} 
{%                  if platform_defaults.type == 3750 %} 
 switchport port-security violation  restrict 
{%                  else %} 
{%                      if platform_defaults.type == 3850 %} 
 switchport port-security violation restrict 
{%                      endif %} 
{%                  endif %} 
 switchport port-security mac-address sticky 
 switchport port-security aging time 720 
 switchport port-security aging type inactivity 
 switchport port-security 
{%                  if host_interfaces[host_interface].port_security_maximum is 
defined %} 
 switchport port-security maximum {{ 
host_interfaces[host_interface].port_security_maximum }} 
{%                  endif %} 
 no cdp enable 
 no lldp transmit 
 no lldp receive