Cloud Managed Networks

 View Only
  • 1.  Renaming AP's

    Posted Sep 20, 2023 08:20 AM

    Hi,

    What's the fastest way to change AP names in Aruba Central AOS-8? In AOS10 you can select multiple AP's and rename them easilly.

    Is that possible on aos8?



  • 2.  RE: Renaming AP's

    Posted Sep 20, 2023 08:55 AM
    Edited by mkk Sep 20, 2023 09:13 AM

    I renamed 800 APs in Aruba Central AOS10 by using a API call like this with Python. But don't sure if this API call is working for ArubaOS8 where u have a virtual cluster (instant). 

    Check the API datatbase here:

    HPE GreenLake (deprecated)

    HPE GreenLake (current)

    Why don't upgrade your APs to AOS10?

    Note1: Your AP will reboot

    Note2: Check carefully the payload because not everybody have same config and other info will send in the API payload that can change your AP name.

    Note3: My script is just an example, customize if you want.

    Another handy link is the Central Automation Studio, created by an HPE employee. https://central.wifidownunder.com/settings.html

    ### Editable parameters ###
    central_url = https://eu-apigw.central.arubanetworks.com
    access_token = "keyhere"
    file_location = r"C:\test\import.txt"
    ###########################
    
    ### Note: The Aruba Cental API URL is based on the datacenter location.
    ### Note: The access_token must be created in Aruba Central first and is valid for 2 hours.
    ### Note: The file location is the fullpath incl. filename to the import.txt CSV. The "r" is needed to make the variable a raw format.
    
    ### HTML header in json code contains the access_token.
    header = {'Authorization': 'Bearer ' + access_token}
    
    ### Open the file_location CSV where "," is the delimter to devide the collums into two variables "serial" and "apname".
    with open(file_location) as importfile:
       for line in importfile:
          serial, apname = line.split(',')
          print(serial.strip(), apname.strip())
    
    ### Aruba Central API URL.
          url = central_url+"/configuration/v2/ap_settings/"+serial
    
    ### HTML body in raw json format contains the API payload.
          payload = {"hostname": apname,
                     "ip_address": "",
                     "zonename": "",
                     "achannel": "",
                     "atxpower": "",
                     "gchannel": "",
                     "gtxpower": "",
                     "dot11a_radio_disable": False,
                     "dot11g_radio_disable": False,
                     "usb_port_disable": False}
    
    ### Execute the API POST
          r = requests.post(url, json=payload, headers=header)
    
    ### Print the API Response code on screen
          response = r.text
          print (response)
    



    ------------------------------
    Marcel Koedijk | MVP Expert 2023 | ACEP | ACMP | ACCP | ACDP | Ekahau ECSE | Not an HPE Employee | Opinions are my own
    ------------------------------



  • 3.  RE: Renaming AP's

    Posted Sep 20, 2023 05:13 PM

    I always recommend using Central Automation Studio, it has many other features as well. check it out.

     https://central.wifidownunder.com/



    ------------------------------
    If my post was useful accept solution and/or give kudos.
    Any opinions expressed here are solely my own and not necessarily that of HPE or Aruba.
    ------------------------------



  • 4.  RE: Renaming AP's

    Posted Sep 21, 2023 02:37 AM

    I can only agree with Marcel and Ariyap. Central Automation Studio is easy to use and provides a lot of handy features to do a bulk updates and many other things. Really worth of testing it.

    Best, Gorazd



    ------------------------------
    Gorazd Kikelj
    MVP Expert 2023
    ------------------------------