Using PowerOn Auto Provisioning

This chapter describes how to deploy and use PowerOn Auto Provisioning (POAP) for the Cisco MDS 9148, 9148S, and 9396S Multilayer Fabric Switches.

This chapter contains the following sections:

Network Requirements for POAP

POAP requires the following network infrastructure:

  • A DHCP server to bootstrap the interface IP address, gateway address, and TFTP address.

  • A TFTP/SCP server that contains the configuration script used to automate the software image installation and configuration process.

  • One or more servers that contains the desired software images and configuration files.

Figure 1. POAP Network Infrastructure



Setting Up the Network Environment to Use POAP


    Step 1   Deploy a TFTP server to host the configuration script, software images, and configuration files.
    Step 2   Deploy a DHCP server.
    Step 3   Configure the following parameters in the DHCP server:
    • Interface address

    • Gateway address

    • TFTP server's IP address

    • Boot file name



    Example:

    An example of dhcpd.conf on linux with bootfile name, TFTP server, and script file name:

    option vlan-id code 132 = unsigned integer 32 ;
    subnet 10.105.188.0 netmask 255.255.255.0 {
    	max-lease-time 7200;
    	class "cisco MDS" {
    	  match if substring(option vendor-class-identifier, 0, 15) = "cisco MDS - tcl";
    	   option bootfile-name "poap_script.tcl";
               option subnet-mask 255.255.255.0;
    	   option domain-name "cisco.com";
    	}
    	option routers 10.105.188.1;
    	option tftp-server-name "10.105.188.159";
    }
    Step 4   Obtain the serial number of the switch by executing the show sprom backplane 1 command.
    Step 5   Create a separate directory for each switch in the base directory of the TFTP server. The name of each directory should be the same as the serial number of the switch. Creating separate directory for each switch permits to have separate software images or configuration files for different switches.
    Note   

    The base directory should contain the software images (kickstart and system) and the server-list.cfg. The file names of the software images should match the poap_script.tcl and device-recipe.cfg.

    In the newly created directory for each switch maintain the device-recipe.cfg and the conf_SN.cfg (Replace SN with the exact serial number of the corresponding switch.)



    Example:

    An example of device-recipe.cfg:

    {"serial-number":"JAF1735307V","kick-start-image":{"image-name":"MDS9148S_boot","download-server":
    "Default_SCP_Repository"},"system-image":{"image-name":"MDS9148S_isan","download-server":
    "Default_SCP_Repository"},"startup-config":{"config-name":"conf_JAF1735307V.cfg","download-server":
    "Default_SCP_Repository"}}


    Example:

    An example of server-list.cfg:

    {  "repositories": {"Default_SCP_Repository":{"url":"scp://server_IP/directory_path","username":
    "user","password": "password","last-modified-time":"Mon Mar 24 00:22:33 PDT 2014"}  },  "resources":{  }}
    Note   

    You can download all the sample files for POAP process from the following link:

    https:/​/​software.cisco.com/​download/​release.html?mdfid=283453013&softwareid=282088132&release=6.2(11)&relind=AVAILABLE&rellifecycle=&reltype=latest

    Ensure that you select the correct version of the Cisco MDS NX-OS Release before downloading the sample files.


    POAP Process

    The POAP process has the following phases:

    1. Power up

    2. DHCP discovery

    3. Script execution

    4. Post-installation reload

    Within these phases, other process and decision points occur. The following illustration shows a flow diagram of the POAP process.

    Figure 2. POAP Process



    Power-Up Phase

    When you power up a switch for the first time, it loads the software image that is installed at manufacturing and tries to find a configuration file from which to boot. When a configuration file is not found, POAP mode starts.

    During startup, a prompt appears asking if you want to abort POAP and continue with a normal setup. You can choose to exit or continue with POAP.


    Note


    No user intervention is required for POAP to continue. The prompt that asks if you want to abort POAP remains available until the POAP process is complete.


    If you exit POAP mode, you enter the normal interactive setup script. If you continue in POAP mode, all the front-panel interfaces are set up in the default configuration.

    DHCP Discovery Phase

    The switch sends out DHCP discover messages on the MGMT interface that solicits DHCP offers from the DHCP server or servers. (See the following figure.) The DHCP client on the Cisco MDS switch uses the switch serial number in the client-identifier option to identify itself to the DHCP server. The DHCP server can use this identifier to send information, such as the IP address and script filename, back to the DHCP client.

    POAP requires a minimum DHCP lease period of 3600 seconds (1 hour). POAP checks the DHCP lease period. If the DHCP lease period is set to less than 3600 seconds (1 hour), POAP does not complete the DHCP negotiation.

    The DHCP discover message also solicits the following options from the DHCP server.
    • TFTP server name or TFTP server address—The DHCP server relays the TFTP server name or TFTP server address to the DHCP client. The DHCP client uses this information to contact the TFTP server to obtain the script file.

    • Bootfile name—The DHCP server relays the bootfile name to the DHCP client. The bootfile name includes the complete path to the bootfile on the TFTP server. The DHCP client uses this information to download the script file.

    When multiple DHCP offers that meet the requirement are received, an offer is randomly chosen. The device completes the DHCP negotiation (request and acknowledgment) with the selected DHCP server, and the DHCP server assigns an IP address to the switch. If a failure occurs in any of the subsequent steps in the POAP process, the IP address is released back to the DHCP server.

    If no DHCP offers meet the requirements, the switch does not complete the DHCP negotiation (request and acknowledgment) and an IP address is not assigned.

    Figure 3. DHCP Discovery Process



    Script Execution Phase

    After the device bootstraps itself using the information in the DHCP acknowledgment, the script file is downloaded from the TFTP server.

    The switch runs the configuration script, which downloads and installs the software image and downloads a switch-specific configuration file.

    However, the configuration file is not applied to the switch at this point, because the software image that currently runs on the switch might not support all of the commands in the configuration file. After the switch reboots, it begins running the new software image, if an image was installed. At that point, the configuration is applied to the switch.


    Note


    If the script execution fails, the DHCP discovery starts again.


    Post-Installation Reload Phase

    The switch restarts and applies (replays) the configuration on the upgraded software image. Afterward, the switch copies the running configuration to the startup configuration.

    Configuring a Switch Using POAP

    Before You Begin

    Make sure that the network environment is set up to use POAP. For more information, see the Setting Up the Network Environment to Use POAP section immediately preceeding this section.

    SUMMARY STEPS

      1.    Install the switch in the network.

      2.    Power on the switch.

      3.    (Optional) If you want to exit POAP mode and enter the normal interactive setup script, enter y (yes).


    DETAILED STEPS
      Step 1   Install the switch in the network.
      Step 2   Power on the switch.

      If no configuration file is found, the switch boots in POAP mode and displays a prompt that asks if you want to abort POAP and continue with a normal setup.

      No entry is required to continue to boot in POAP mode.

      Step 3   (Optional) If you want to exit POAP mode and enter the normal interactive setup script, enter y (yes).

      The switch boots, and the POAP process begins. For more information, see the POAP Process section.


      What to Do Next

      Verify the configuration.

      Verifying the Device Configuration

      To verify the configuration after bootstrapping the device using POAP, use one of the following commands:

      Command

      Purpose

      show running-config

      Displays the running configuration.

      show startup-config

      Displays the startup configuration.

      For detailed information about the fields in the output from these commands, see the Cisco MDS 9000 Family Command Reference.

      Guidelines and Limitations for POAP

      The POAP configuration guidelines and limitations are as follows:

      • The software image for the Cisco MDS 9000 Series switches, including the Cisco MDS 9396S Multilayer Fabric Switch, must support POAP for this feature to function.

      • POAP does not support provisioning of the switch after it has been configured and is operational. Only auto-provisioning of a switch with no startup configuration is supported.

      • Important POAP updates are logged in the syslog and are available from the serial console.

      • Critical POAP errors are logged to the bootflash. The filename format is date-time_poap_PID_[init,1,2].log, where date-time is in the YYYYMMDD_hhmmss format and PID is the process ID.

      • Script logs are saved in the bootflash directory. The filename format is date-time_poap_PID_script.log, where date-time is in the YYYYMMDD_hhmmss format and PID is the process ID.

        You can configure the format of the script log file. Script file log formats are specified in the script. The template of the script log file has a default format; however, you can choose a different format for the script execution log file.

      • The POAP feature does not require a license and is enabled by default.


        Note


        POAP is not supported through DCNM (Data Center Network Management).