Populating End of Life data for Cisco devices


Device vendors regularly publish end of life (EOL) bulletins for an equipment they support. The bulletins indicate that you need to replace or upgrade that equipment within a reasonable time. TrueSight Network Automation can help remind you to do this by flagging such devices. You can import these EOL bulletins in advance of the EOL dates. 

Different vendors publish the EOL content in different formats, such as PDF, HTML, and XML that can be accessible through various means. Network Automation can read the EOL bulletins (XML) released by Cisco and convert this content in a form that can be used to alert customers about EOLs of various devices in the device inventory.

This topic describes the process of populating EOL data for Cisco devices and provides instructions for the same.

Process of populating EOL data

The process of populating EOL data comprises the following steps:

  1. Discover and store board models IDs and serial numbers of devices: A network device can have multiple boards and each board can have a different EOL date.Network Automation discovers and stores board models IDs and corresponding serial numbers in two multi-value device dynamic fields, Device Board Models and Device Board Serial Numbers, through a custom action, Get Board Models and their Serial Numbers.
  2. Fetch EOL data from Cisco Portal: Get EOL data of device board model IDs of the required Cisco devices from Cisco portal.
  3. Store EOL data: Store the data obtained in steps 1 and 2 in a new configuration trail, Device End of Life in JSON format. 
  4. Populate EOL dates: Populate EOL dates for device on the Devices page through a date type dynamic field, End of Life Date.

Depending on whether the Network Automation application server has the Internet connectivity in your network, you can choose from the following methods to populate the EOL data for your devices:

The following figure shows the steps you need to follow depending on whether application server has the Internet connectivity:

PopulateEOL.png

Populating EOL data when the application server has internet connectivity

To populate EOL data, you need to run the predefined job, Populate Cisco Device Board Models and their End of Life Date on the application server. This predefined job contains a custom action, Get Board Models and their Serial Numbers and an external script action, Populate End of Life Date.

In versions earlier than 21.08, the external script action runs on all Cisco devices in your network. Starting with version 21.08, you can run the action on a specific network span. However, you cannot choose the entire network as a span.

Important

After you upgrade to version 21.08 or later, you need to select the network span manually for any policies, jobs, or predefined jobs that were using this external script action before upgrade.

The external script action contains default values for runtime parameters. Change these values as per your environment. By default, you can enter upto 40 characters in a runtime parameter value. You can change this limit by adding the <maxSize> tag in the runtime parameter.

Network Automation is also shipped with a canned policy, Populate Cisco Device Board Models and their End of Life Date, which you can use to schedule for capturing and populating EOL data. The out of box policy is time based, which will run once in a month. Depending on your requirements, you can schedule this operation weekly, monthly, or yearly to capture hardware changes in your data center. After replacing or upgrading your hardware, BMC recommends to run the predefined job or policy to update EOL data. 

Before you begin

Ensure that you have obtained Client ID and Client Secret for the EOX API from the Cisco API Console.

Obtaining Client ID and Client Secret for the EOX API

  1. Access the Cisco portal.
  2. Create a user account on the Cisco portal if you do not have one. 

    Important

    Cisco Support APIs, such as EOX API, are available only to Cisco Smart Net Total Care (SNTC) customers and Cisco Partner Support Service (PSS) partner.

  3. Sign in with the user account you just created.
  4. Scroll down and click the My Apps & Keys link.
  5. Click the Applications tab.
    You see a list of all the available APIs and the keys you already have.
  6. Register for the EOX API:

    1. Click the Keys tab.
    2. Look for the EOX V5 API entry in the list of APIs.
    3. If you are able to see EOX V5 API in the list, click Get a Key for EOX V5. If not, skip to step e.
    4. Provide the application details, agree to the terms of the services, and click Register.
    5. Click Get a Key for.., for any other API. 
    6. Provide the application details. 
    7. Select the desired OAuth2.0 Grant Type

      Recommendation

      We recommend to select the Client Credentials option.

    8. Scroll down and select the EOX V5 API checkbox, agree to the terms of the services and click Register

      Important

      If you are still not able to see the EOX V5 API on the Cisco console for registration, contact Cisco customer support with a valid Support Contract ID.

    After registration, you should see the EOX V5 API entry with Client ID and Client Secret under the Keys tab (next to the EOX V5 API) and Applications tab.
    EOXAPI.png

Running the predefined job

  1. Navigate to Network > Actions > Predefined Jobs.
    The Predefined Jobs list page appears.
  2. For the Populate Cisco Device Board Models and their End of Life Date predefined job, in the Actions column, click Prepare Job Icon_PrepareJob.png.
  3.  Enter information for the following runtime parameters, which are required for the Populate End of Life Date external script action:

    Parameter

    Description

    TrueSight Network Automation Server URL

    Enter the URL of the application server in the following format: https://<hostName>:<portNumber>/bca-networks.

    TrueSight Network Automation Server User Name

    User name for the target application server

    TrueSight Network Automation Server Password

    Password for the user name

    End of Life Milestone Date Name

    Cisco publishes multiple EOL milestone dates such as:

    • EndOfSaleDate
    • EndOfSWMaintenanceReleases
    • EndOfSecurityVulSupportDate
    • EndOfRoutineFailureAnalysisDate
    • EndOfServiceContractRenewal
    • LastDateOfSupport
    • EndOfSvcAttachDate
    • EOXExternalAnnouncementDate

    Specify one or more date names separated by commas that you want to be populated. Network Automation follows that date to populate the EOL date.

    Name of Dynamic Field that will store the Dates

    Specify the comma separated list of dynamic fields corresponding to the End Of Life Milestone Date names to store the dates. 

    Cisco EoX API Registered Client ID

    Client ID that you obtained in the Obtaining Client ID and Client Secret for the EOX API section

    Cisco EOX API Client Secret

    Client Secret that you obtained in the Obtaining Client ID and Client Secret for the EOX API section

    Proxy Server Address

    IP address of the HTTP or HTTPS proxy server

    Proxy Server Port

    Port number for the HTTP or HTTPS proxy server
    If you have provided the proxy server address, you must provide its port number. Otherwise, the Populate End of Life Date action will fail.

    File Path of the End of Life Data

    Leave this field empty.

  4. Click Next.
  5. (Optional) In the Job Editor, edit the job parameters.
  6. Click Save And Submit.
    The job you have prepared is displayed on the Jobs list page.
  7. Click View Icon_View.pngin the Actions column to view the Job Details page. 
    The following figure shows the Job Details page for a sample job. The page shows two actions, custom action (Action #1) and external script action (Action #2).
    EOL_JobDetailsReport_Concurrent_221.png
    In the sample job, Action 1# was run on all Cisco devices in the Live devices realm. The result of this action is board models of devices. If this action fails on any of the devices, then the final job status is shown as Failed. You can click the Status link to check on the device models that were captured and on which the custom action failed. 
    Action #2 shows the results of the external script action. Clicking the link for a device in the Status column displays the transcript where you can see the detailed results for the device, as shown in the following figure:
    EOL_PopulateAction_Concurrent.png
    The transcript page shows the following information:
    Return Code: Shows a value of 0 if the external script action succeeded and 1 if it failed.
    Output: Provides the total number of models captured of all Cisco devices.
    Errors: Displays errors, warnings and INFO messages. A successful execution of the script might show warnings and INFO messages, which can be ignored.
  8. Upon successful execution of the job, the End of Life column on the Devices page is populated with the EOL dates for the Cisco devices. If a device has multiple boards, the EOL date shown is the earliest EOL date amongst all device board models. The following figure shows the Devices page for the sample job.
    EOL_DevicesConcurrent.png

  9. (Optional) Use the Device filter to search for the devices which has EOL dates within a specific time period.

Populating EOL data when application server does not have internet connectivity

When application server does not have internet connectivity, the Cisco portal is not accessible to the application server. In that case, to populate EOL data in an air-gapped environment, you can use one of the following methods:

Populating EOL data in an air-gapped environment

To populate data in an air-gapped environment, first you need generate Cisco EOL data XML using the Get Board Models and their Serial Numbers custom action. Then, you need to run the external script action, Populate Cisco End of Life Date on the application server. 

In versions earlier than 21.08, the external script action runs on all Cisco devices in your network. Starting with version 21.08, you can run the action on a specific network span. However, you cannot choose the entire network as a span.

Important

After you upgrade to version 21.08 or later, you need to select the network span manually for any policies, jobs, or predefined jobs that were using this external script action before upgrade.

Network Automation is also shipped with a canned policy, Populate Cisco Device Board Models and their End of Life Date, which you can use to schedule for capturing and populating EOL data. The out of box policy is time based, which will run once in a month. Depending on your requirements, you can schedule this operation weekly, monthly, or yearly to capture hardware changes in your data center. After replacing or upgrading your hardware, BMC recommends to run the predefined job or policy to update EOL data.

Before you begin

Ensure that you have obtained Client ID and Client Secret for the EOX API from the Cisco API Console.

To populate EOL data in an air-gapped environment

  1. Run the custom action: Run the Get Board Models and their Serial Numbers custom action for Cisco devices on the application server.
  2. Generate XML for TrueSight Network Automation device board models: To generate the XML, export the dynamic field, Device Board Models on the application server using the import/export utility. The export script is available in the bcan-import-export-v.r.mm.zip file, present in the BCAN_HOME\public\bmc\bca-networks\extras directory. When the file is unzipped, the script is in the bin subdirectory.

    export.[bat|sh] -url https://<hostName>:<portNumber> -user <userName> -password <password> -component DynamicTypes -name "Device Board Models" -file deviceBoardModel.xml

    The deviceBoardModel.xml file is generated in the BCAN_HOME\public\bmc\bca-networks\extras\bcan-import-export-<version>\bcan-import-export\bin directory. For information about import/export utility, see Exporting-and-importing-components-using-a-script.

  3. Generate Cisco EOL data XML as follows:
    1. Copy the following files from the application server and paste it on the computer which has internet connectivity (Linux/Windows):
      1. deviceBoardModel.xml that you generated in step 2
      2. BCA-Networks\public\bmc\bca-networks\extras\bcan-eol-external-utility-<version>.zip
    2. Extract the zip file that you copied in step a.
    3. Run the FetchCiscoEolData.bat script from the command line, as follows:

      FetchCiscoEolData.bat -ciscoClientID "<Cisco_Client_ID>" -ciscoClientSecret "<Cisco_Client_Secret>" -ciscoBoardModelInputFilePath "C:\deviceBoardModel.xml" -eolDataOutputFilePath "C:\EOL\CiscoEoL.xml"

      The output is an XML file, CiscoEol.xml, generated in the directory that you provided in the eolDataOutputFilePath argument.
  4. To populate EOL data on the application server, copy the XML file (CiscoEol.XML) generated in step 3 and paste it into the BCA-Networks-Data\endorsed directory.
  5. Run the Populate Cisco End of Life Date external script action on the application server with the following parameters:

    Parameter

    Description

    TrueSight Network Automation Server URL

    Enter the URL of the application server in the following format: https://<hostName>:<portNumber>/bca-networks.

    TrueSight Network Automation Server User Name

    User name for the target application server

    TrueSight Network Automation Server Password

    Password for the user name

    End of Life Milestone Date Name

    Cisco publishes multiple EOL milestone dates such as:

    • EndOfSaleDate
    • EndOfSWMaintenanceReleases
    • EndOfSecurityVulSupportDate
    • EndOfRoutineFailureAnalysisDate
    • EndOfServiceContractRenewal
    • LastDateOfSupport
    • EndOfSvcAttachDate
    • EOXExternalAnnouncementDate

    Specify the one you want to be populated. TrueSight Network Automation follows that date to populate the EOL date.

    Cisco EoX API Registered Client ID

    Client ID that you obtained in the Obtaining Client ID and Client Secret for the EOX API section

    Cisco EOX API Client Secret

    Client Secret that you obtained in the Obtaining Client ID and Client Secret for the EOX APIsection

    Proxy Server Address

    Leave this field empty.

    Proxy Server Port

    Leave this field empty.

    File Path of End of Life Data

    Name of the file that you copied in step 4 (CiscoEol.xml).

  6. Upon successful execution of the preceding steps, the End of Life column on the Devices page is populated with the EOL dates for the Cisco devices. If a device has multiple boards, the EOL date shown is the earliest EOL date amongst all device board models. To see the Devices page, navigate to Network > Spans > Devices.
  7. (Optional) Use the Device filter to search for the devices which has EOL dates within a specific time period.

Viewing EOL data using reports

You can generate various reports such as Device Inventory report and Configuration Search report to obtain the list of devices that are reaching their EOL.

To generate the Device Inventory report

  1. Open the Device Inventory Report wizard page by navigating to Reports > Status Reports > Device Inventory.
  2. Under User Assigned Dynamic Fields, select End of Life Date.

    EOL_DeviceInventoryInputs.png
  3. Click Filter Devices to display the Device Filter dialog box.
  4. Click the Dynamic Fields tab.
    EOL_DeviceFilter.png
  5. In End of Life Date, specify the date before which if a device EOL occurs that device should appear in the report, and click OK.
  6. Click Next to begin the report generation and to display its progress on the Report Activity page. 
    ReportActivity.png
  7. Click Refresh until the report is completed, or wait until you receive the notification email. If the report is aborted, the Progress column indicates so, to alert you that the report data is partial. You can view the partial report, but be aware it is partial. You should refine your selections (if you asked for too-large a report) or re-generate the report (if it was aborted due to a system shutdown) in order to obtain a complete report. Then delete the aborted report as soon as possible. For more information about the Report Activity page, see Viewing-report-activity.
  8. Click the Device Inventory link in the Report column to display the report. 
    DeviceInventoryReport.png

You can also generate the Configuration Search report to view a complete list of board model ID’s of Cisco devices and their EOL dates.

To generate the Configuration Search report

  1. Open the Configuration Search wizard page by navigating to Reports > Search Reports > Configuration Search.
  2. From Configuration, select Other Current or Other Historical
  3. Select Device End of Life from the next drop down list. 
  4. If you have chosen Other Historical in the previous step, specify the date before which historical trails need to be considered for generating EOL data.
  5. From Subject, select Pattern.
  6. In Pattern, enter .* as the pattern.
    EOL_ConfigSearchReportInputs.png
  7. Click Filter Devices to display the Device Filter dialog box.
  8. Click the Dynamic Fields tab.
  9. In End of Life Date, choose the time period before which if a device EOL occurs that device should appear in the report, and click Save.
    EOL_DeviceFilter.png
  10. Click Generate to begin the report generation and to display its progress on the Report Activity page.
  11. Click Refresh until the report is completed, or wait until you receive the notification email. If the report is aborted, the Progress column indicates so, to alert you that the report data is partial. You can view the partial report, but be aware it is partial. You should refine your selections (if you asked for too-large a report) or re-generate the report (if it was aborted due to a system shutdown) in order to obtain a complete report. Then delete the aborted report as soon as possible. For more information about the Report Activity page, see Viewing-report-activity.
  12. Click the Configuration Search link in the Report column to display the report. 
    The following figure shows a sample report.
    EOL_ConfigSearchReport.png


 

Tip: For faster searching, add an asterisk to the end of your partial query. Example: cert*