Cisco Nexus 1000V Port Profile Configuration Guide, Release 4.2(1)SV2(2.1)
Configuring Port Profile Inheritance
Downloads: This chapterpdf (PDF - 1.16MB) The complete bookPDF (PDF - 2.84MB) | The complete bookePub (ePub - 497.0KB) | Feedback

Configuring Port Profile Inheritance

Configuring Port Profile Inheritance

This chapter contains the following sections:

Information About Port Profile Inheritance

You can apply the configuration from an existing port profile as the default configuration for another port profile. This is called inheritance. The configuration of the parent port profile is copied to and stored in the child port profile. You can also override the inheritance by configuring the attributes explicitly in the child port profile.

Table 1 Port Profile Inheritance Settings
 

Can it be inherited?

Port Profile Setting

Yes

No

acl

X

 

capability iscsi-multipath

X

 

capability l3 control

 

X

channel group

X

 

default (resets characteristic to its default)

X

 

description

 

X

inherit

X

 

interface state (shut/no shut)

X

 

mtu

 

X

name

X

 

netflow

X

 

pinning

X

 

port security

X

 

private vlan configuration

X

 

service-port

X

 

state (enabled or disabled)

 

X

switchport mode (access or trunk)

X

 

system vlan vlan list

 

X

virtual-service-domain

X

 

vlan configuration

X

 

VMware max-ports

 

X

VMware port-group name

 

X

Guidelines and Limitations for Configuring Port Profile Inheritance

  • Inherited port profiles cannot be changed or removed from an interface using the Cisco Nexus 1000V CLI. This can only be done through the VMware vCenter Server.
  • Inherited port profiles are automatically configured by the Cisco Nexus 1000V when the ports are attached on the hosts. This is done by matching up the VMware port group assigned by the system administrator with the port profile that created it.
  • You can change a setting directly on a port profile to override the inherited settings.
  • You can also explicitly remove port profile inheritance, so that a port profile returns to the default settings, except where there has been a direct configuration. For more information, see Removing Inherited Policies from a Port Profile.
  • The Cisco Nexus 1000V software must be initially configured. For information, see the Cisco Nexus 1000V Installation and Upgrade Guide.
  • The Cisco Nexus 1000V must be connected to the VMware vCenter Server.
  • Once a port profile is created, you cannot change its type (Ethernet or vEthernet).

Inheriting a Configuration from a Port Profile

You can use this procedure to apply the configuration from an existing port profile as the default configuration for another port profile.

You are familiar with the port profile characteristics shown in Table 1 and whether they can be inherited.


Tip


The port profile type cannot be inherited from another port profile.


Before You Begin
  • You are logged in to the CLI in EXEC mode.
  • To identify the port profile with a configuration you want to use, use the show port profiles command to view your existing port profiles.
SUMMARY STEPS

    1.    switch# configure terminal

    2.    switch(config)# port-profile [type {ethernet | vethernet}] name

    3.    switch(config-port-prof)# inherit port-profile name

    4.    (Optional) switch(config-port-prof)# show port-profile [brief | expand-interface | usage] [name profile-name]

    5.    (Optional) switch(config-port-prof)# copy running-config startup-config


DETAILED STEPS
      Command or Action Purpose
    Step 1 switch# configure terminal 

    Enters global configuration mode.

     
    Step 2 switch(config)# port-profile [type {ethernet | vethernet}] name 

    Enters port profile configuration mode for the named port profile. If the port profile does not already exist, it is created using the following characteristics:

    • name—The port profile name can be up to 80 characters and must be unique for each port profile on the Cisco Nexus 1000V.
    • type—(Optional) The port profile type can be Ethernet or vEthernet. Once configured, the type cannot be changed. The default is the vEthernet type. Defining a port profile type as Ethernet allows the port profile to be used for physical (Ethernet) ports. In the vCenter Server, the corresponding port group can be selected and assigned to physical ports (PNICs).
      Note   

      If a port profile is configured as an Ethernet type, then it cannot be used to configure VMware virtual ports.

     
    Step 3 switch(config-port-prof)# inherit port-profile name 

    Adds the inherited configuration of the named profile as a default configuration.

     
    Step 4 switch(config-port-prof)# show port-profile [brief | expand-interface | usage] [name profile-name]  (Optional)

    Displays the configuration for verification.

     
    Step 5 switch(config-port-prof)# copy running-config startup-config  (Optional)

    Saves the change persistently through reboots and restarts by copying the running configuration to the startup configuration.

     

    This example shows how to inherit the port profile configuration of another port profile:

    switch# configure terminal
    switch(config)# port-profile AllAccess2
    switch(config-port-prof)# inherit port-profile AllAccess1
    switch(config-port-prof)# show port-profile name AllAccess2
    port-profile AllAccess2
      description:
      type: vethernet
      status: disabled
      capability l3control: no
      pinning control-vlan: -
      pinning packet-vlan: -
      system vlans: none
      port-group:
      max ports: 32
      inherit: port-profile AllAccess1
      config attributes:
      evaluated config attributes:
      assigned interfaces:
    switch(config-port-prof)#

    Removing Inherited Policies from a Port Profile

    If you have configured policies independently of inheritance, then they will not be removed when you remove the inheritance. Only the policies that are configured solely through the inheritance are removed.

    Before You Begin

    You are logged in to the CLI in configuration mode.

    SUMMARY STEPS

      1.    switch# configure terminal

      2.    (Optional) switch(config)# show port-profile virtual usage name profile_name

      3.    switch(config)# port-profile name

      4.    switch(config-port-prof)# no inherit port-profile profile_name

      5.    (Optional) switch(config-port-prof)# show port-profile virtual usage name profile_name

      6.    (Optional) switch(config-port-prof)# copy running-config startup-config


    DETAILED STEPS
        Command or Action Purpose
      Step 1 switch# configure terminal 

      Enters global configuration mode.

       
      Step 2 switch(config)# show port-profile virtual usage name profile_name  (Optional)

      Displays the policies inherited in the named port profile.

       
      Step 3 switch(config)# port-profile name 

      Enters port profile configuration mode for the named port profile.

       
      Step 4 switch(config-port-prof)# no inherit port-profile profile_name 

      Removes the inherited policies from the named port-profile.

      The port profile settings are returned to the defaults, except for the port profile type and any settings that were explicitly configured independent of those inherited.

       
      Step 5 switch(config-port-prof)# show port-profile virtual usage name profile_name  (Optional)

      Displays the policies inherited for verification of the removal.

       
      Step 6 switch(config-port-prof)# copy running-config startup-config  (Optional)

      Saves the change persistently through reboots and restarts by copying the running configuration to the startup configuration.

       

      This example shows how to remove inherited policies from a port profile:

      switch# configure terminal
      switch(config)# show port-profile virtual usage name AccessProf
      switch(config)# port-profile Access4
      switch(config-port-prof)# no inherit port-profile AccessProf
      switch(config-port-prof)# show port-profile virtual usage name AccessProf
      switch(config-port-prof)# copy running-config startup-config