Help us improve your experience.

Let us know what you think.

Do you have time for a two-minute survey?

Navigation
Guide That Contains This Content
[+] Expand All
[-] Collapse All

    Installing Licenses with the License Tool

    The license tool enables you to install and retrieve license information through a command line interface (CLI).

    The license installation tool uses the following syntax:

    python install_license.py -I license-id -p license-path -t tenant-name - -sitefile site-list-path - -install_all_devices - -get_license_info –service firewall | utm | nat

    Table 1 describes the arguments and variables for the tool.

    Table 1: Keywords and Variables for the License Tool

    Arguments and Variables

    Function

    Requirement

    -l license-id

    Specifies the identifier of the license.

    Mandatory for license installation

    -p license-path

    Specifies the path to the directory that contains the license file.

    Mandatory for license installation

    -t tenant-name

    Specifies the name of the customer in Contrail Service Orchestration.

    • Mandatory for license installation on a single device
    • Optional for installation of a license on all devices

    - -sitefile site-list-path

    Specifies the path to the directory that contains a text file with a list of comma- or newline- separated sites in Contrail Service Orchestration.

    • Mandatory if you update one or more specific sites or if you use the get_license_info option
    • Optional for installation of a license on all devices

    - -install_all_devices

    Specifies that the tool installs licenses on all devices in the deployment.

    Mandatory for license installation on all devices

    - -get_license_info

    Extracts license information for a list of sites.

    Requires the sitefile option

    - -service firewall | utm | nat

    Specifies the network function for the license.

    Mandatory if the site hosts multiple VNFs

    Setting Up the Environment Variables

    Before you use the license installation tool, you must specify the following environment variables:

    • OS_AUTH_URL—URL of the OpenStack Keystone that authorizes Contrail Service Orchestration, including the IP address of the OpenStack Keystone host, port 35357 and the OpenStack version
    • OS_USERNAME—Username for Contrail Service Orchestration
    • OS_PASSWORD—Password for Contrail Service Orchestration
    • OS_TENANT_NAME—OpenStack tenant name, admin
    • TSSM_IP—IP address of the central microservices host
    • Regional IP—IP address of the regional microservices host

    For example:

    root@host:~/#export OS_AUTH_URL=http://192.0.2.0:35357/v2.0
    root@host:~/#export OS_USERNAME=cspadmin
    root@host:~/#export OS_PASSWORD=passw0rd
    root@host:~/#export OS_TENANT_NAME=admin
    root@host:~/#export TSSM_IP=192.2.0.1
    root@host:~/#export REGION_IP=192.0.2.2

    Installing a License on One or More Specific Sites

    To install a license on one or more sites:

    1. Create a text file of site names, separated by commas or newline characters.
    2. Run the tool with the appropriate options (see Table 1).

      For example:

      root@host:~/#python install_license.py -i JUNOS000001 -p licenses/vsrx-utm-license.txt -t test-customer - - sitefile sites.txt - - service utm
      Total Sites: 2
      Site count f
      or successful license install: 2
      Site count for
      failed license install: 0
    3. (Optional) Review the license_install_results.log for detailed results.
      ***License Install Status ***
      
      Response:SUCCESS
      Site: jd8-site-1
      vSRX IP: 10.102.82.36
      License Info: license": [
      {
      "license_id": "JUNOS000001",
      "install_status": success
      }
      ]
      Response:SUCCESS
      Site: jd8-site-2
      vSRX IP: 10.102.82.2
      License Info: license": [
      {
      "license_id": "JUNOS000001",
      "install_status": success
      }
      ]
    4. If there is a problem with the license installation, review the license_install.log file for debugging information.

    Installing a License on a Specific Device at a Site

    To install a license on a specific device at a site:

    1. Create a text file of site names, separated by commas or newline characters.
    2. Run the tool with the appropriate options (see Table 1).

      For example:

      root@host:~/#python install_license.py -I JUNOS000001 -p licenses/vsrx-utm-license.txt -t test-customer - -sitefile sitelist.txt - -service utm
      Output:
      Total Sites: 1
      Site count for successful license install: 1
      Site count for failed license install: 0
      
    3. (Optional) Review the license_install_results.log for detailed results.
      ***License Install Status ***
      
      Response:SUCCESS
      Site: jd8-site-1
      vSRX IP: 10.102.82.36
      License Info: license": [
      {
      "license_id": "JUNOS000001",
      "install_status": success
      }
      ]
      
    4. If there is a problem with the license installation, review the license_install.log file for debugging information.

    Installing a License on All Sites

    To install a license on all sites:

    1. Run the tool with the appropriate options (see Table 1).

      For example:

      root@host:~/#python install_license.py -I JUNOS000001 -p licenses/vsrx-utm-license.txt -- install_all_devices
      License will be installed on all devices. Please confirm [Y/N](N):y
      ***License Install Status ***
      10
      Response:SUCCESS
      Refer license_install_results.log for detailed results, license_install.log for debug logs.
      
    2. (Optional) Review the license_install_results.log for detailed results.
    3. If there is a problem with the license installation, review the license_install.log file for debugging information.
    4. Log in to the device console for each device and run the show system license command.

      For example:

      root@NAT-1# run show system license
       
      License usage: Licenses     Licenses    Licenses    Expiry
      Feature name       used    installed      needed 
      appid-sig             0            1           0    2017-11-03 00:00:00 UTC
      Virtual Appliance     1            1           0    54 days
      Licenses installed: 
      License identifier: XXXXXXXX
      License version: 4
      Software Serial Number: XXXXXXXX
      Customer ID: vSRX-JuniperEval
      Features:
      Virtual Appliance -Virtual Appliance count-down, Original validity: 60 days
      License identifier: JUNOS00002
      License version: 4
      Software Serial Number: XXXXXXXXXXX
      Customer ID: test-tenant
      Features:
      appid-sig        -APPID Signature
      date-based, 2016-11-02 00:00:00 UTC - 2017-11-03 00:00:00 UTC
      root@NAT-2# run show system license
       
      License usage: Licenses     Licenses    Licenses    Expiry
      Feature name       used    installed      needed 
      appid-sig             0            1           0    2017-11-03 00:00:00 UTC
      Virtual Appliance     1            1           0    57 days
      Licenses installed: 
      License identifier: XXXXXXXX
      License version: 4
      Software Serial Number: XXXXXXXX
      Customer ID: vSRX-JuniperEval
      Features:
      Virtual Appliance -Virtual Appliance count-down, Original validity: 60 days
      License identifier: JUNOS00002
      License version: 4
      Software Serial Number: XXXXXXXXXXX
      Customer ID: test-tenant
      Features:
      appid-sig        -APPID Signature
      date-based, 2016-11-02 00:00:00 UTC - 2017-11-03 00:00:00 UTC

    Viewing License Information for Sites

    To view license information for one or more sites:

    1. Create a text file of site names, separated by commas or newline characters.
    2. Run the tool with the appropriate options (see Table 1).

      For example:

      root@host:~/#python install_license.py - -get_license_info - -sitefile sites.txt -t test-tenant
      Total Sites: 2
      Site count for successful license info retrieval: 2
      Site count for failed license info retrieval: 0
      Refer license_install_results.log for detailed results, license_install.log for debug logs.
    3. (Optional) Review the license_install_results.log for detailed results.
      ***License Information ***
      Site: jd8-site-1
      vSRX IP: 10.102.82.36
      License Info: license": [
      {
      "license_id": "
      JUNOS000001",
      "install_status": success
      }
      ]
      Site: jd8-site-2
      vSRX IP: 10.102.82.2
      License Info: license": [
      {
      "license_id": "
      JUNOS000001",
      "install_status": success
      }
      ]
    4. If there is a problem with operation, review the license_install.log file for debugging information.

    Modified: 2017-02-07