Automate F5OS license activation

Hi All,

Hope you are doing good. Do you have any idea to automate F5OS license. Appreciate if you can share details.

Thanks

Samir,

When you have the registration key and the F5OS device has access to the internet. You should be able to use the automatic reactivation process to automate the the licensing.

You can use an HTTP proxy when using the F5OS automatic licensing. F5OS licensing via a proxy server should use FQDN

You can create a system administration automation to use the automatic reactivation process.

I would create a python program to what’s listed below.

  1. SSH into the CLI on F5OS device.
  2. Enter configuration mode.
  3. Enter the command below.
    • “system licensing install registration-key”

The procure is from K000151705: Viewing and licensing or reactivating a license for F5OS rSeries

When the F5OS device does not have access to the internet. You have to use manual licensing. The manual licensing process could be automated by using web scraping.

I personally think it’s faster to manually install the license than automating a “manual” install via web scraping.

List of high level steps for web scraping.

  1. Login the F5OS WebUI.
  2. Install the registration-key.
  3. Download or scrap the Dossier from the WebUI.
  4. Go the F5 licensing web site.
  5. Past or upload the Dossier.
  6. Download or scrap the license file.
  7. Go back to the F5OS WebUI.
  8. import the license file.

I am not aware of my API that allows the A F5OS license to be installed.

Thank you so much for reply. I am looking for REST API option to automate the process. Below option i am stuck.
*Generate F5OS Dossier via restAPI or ansible module.
Download Dossier from F5OS & upload activate.f5.com
etc.

Appreciate if someone has already done it.*

Hi Samir

F5OS does have a RESTCONF API for licensing. The rSeries guide documents three endpoints:

  • install: automatic activation using the registration key, when the device has Internet access.
  • get-dossier: retrieves the dossier for offline activation.
  • manual-install: installs the license generated at activate.f5.com.

Automatic licensing

POST https://<f5os-mgmt-ip>:8888/restconf/data/openconfig-system:system/f5-system-licensing:licensing/f5-system-licensing-install:install

{
  "f5-system-licensing-install:input": [
    {
      "registration-key": "{{velos_or_serier_license_registration_key_chassis1}}"
    }
  ]
}

If it works you should get back:

{
    "f5-system-licensing-install:output": {
        "result": "License installed successfully."
    }
}

You will get the current licensing status API use the following API call.

GET https://{{rseries_appliance1_ip}}:8888/restconf/data/openconfig-system:system/f5-system-licensing:licensing

Inicial Setup of rserie

Hope this helps.

Quiroman