cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
5017
Views
3
Helpful
5
Replies

Modify an existing WLAN (SSID) Name and Password

RM
Level 1
Level 1

Hi the Discussion Community,

Recently we've been looking to leverage the PI's API for the WLAN SSID modification.   We'd like to find some right API calls to modify the existing SSID name and password. However, going through the WLAN Provisioning API, we've realized that either "Creates a WLAN template on the server" or "Modifies an existing WLAN template" offers the limited payload parameters to define the WLAN ID,SSID, or password.  Are these API calls still have limited functions or we just missed something.

Our systems are: PI v2.2, and migrating to 3.0 now.  WLC is 8510.

By Going through the CLI Template Configuration, can we customize a specific CLI Template instead of the WLAN Provisioning just to:

- Rename the SSID

- Change the password for the SSID

- Deploy the configuration

Thanks for your help, any response is appreciated.

-Raymond

5 Replies 5

RM
Level 1
Level 1

OK, I have to build a CLI Template over the PI3.0 first for the later API calls. The template works OK from the PI, I'm able to deploy it anytime. For example, if I'd like to change an OPEN SSID without a password I would use:

config wlan disable $wlan_id

config wlan ssid $wlan_id $ssid

config wlan enable $wlan_id

However, when I make the API call by the PUT cliTemplateConfiguration/deploy /webacs/api/v1/op/cliTemplateConfiguration/deploy

The error message is: Error in running XDE Procedure, Error Message::Error occured while communicating with the device. Check device credentials and SSH/telnet reachability.  Tried every possible device ID. controller ID, nothing works. Really frustrated.

TAC response suggested us to use the API document, this support forum and the paid ticket option, not much useful.

Anyway, just thought to have an update.

Thanks.

Yes, the WLAN Provisioning Service offers a limited subset of properties that can be set in a created or updated WLAN template (though it can deploy any WLAN template present on the appliance).

What type of controller are you using?

Just so I understand, you're able to deploy that template from the Prime Infrastructure UI to your controller, but it's failing when over the API?

When deploying a CLI template, the targetDeviceID should be the id attribute of the devicesDTO.  For example, with the following

<?xml version="1.0" ?>

<queryResponse type="Devices" count="1" first="0" last="0" rootUrl="https://szier/webacs/api/v1/data" requestUrl="https://szier/webacs/api/v1/data/Devices?.full=true" responseType="listEntityInstances">

<entity url="https://szier/webacs/api/v1/data/Devices/12345" type="Devices" dtoType="devicesDTO">

<devicesDTO id="12345" displayName="12345">

<deviceId>67890</deviceId>

<deviceName>Cisco_f6:4d:a4</deviceName>

<managementStatus>MANAGED_AND_SYNCHRONIZED</managementStatus>

<productFamily>Wireless Controller</productFamily>

<reachability>REACHABLE</reachability>

</devicesDTO>

</entity>

</queryResponse>

You should use 12345, not 67890 as the targetDeviceID.

Thanks.. Spencer!

I'm using the devicesDTO id just like"12345". My lab is WLC5508 Firmware

8.1 and PI3.0. Here is a summary about my test.

1. From PI v3.0 UI to create a CLI Template "ChangeSSID", deploy it to

the WLC5508 v8.1 from UI. When deploy, add the parameters such as a new

ssid. This is successful. The WLC5508 accepts the template and changed

the SSID and the password accordingly.

2. Get the device ID. in my case devicesDTO id="216216"

3. Deploy the template through a Job

/webacs/api/v1/op/cliTemplateConfiguration/deployTemplateThroughJob,

The response is that "An deploy job has been successfully created."

4. Check from PI's UI, a Job is scheduled but failed. No failure reason.

5. If use /webacs/api/v1/op/cliTemplateConfiguration/deploy, then "Error

in running XDE Procedure, Error Message::Error occured while communicating

with the device. Check device credentials and SSH/telnet reachability."

I've attached a text file just to give more information. I suspected that

my payload on Step 3 is not right to transfer the multiple parameters, but

I don't know the right way either.

Once again thank you for reading this and I do appreciate your help!

Best regards,

Raymond Meng, P.Eng

Though I should close this case just to make it completed.

After a WLC and PI reboot, we deleted the WLC from the PI and re-added it, the device ID changed but for some reasons the whole CLI template API call starts to work. I still don't know the root-cause but definitely there is authentication error between the WLC and PI. Anyway, we'll keep our eyes open. 


Thanks to Spencer again for his help!

Glad you got it sorted because we weren't able to reproduce this error internally.  If this happens again we'll probably request logs from you to figure out what's going on.

One note about the job that gets created by the template deployment service; you can use the job run history service (/webacs/api/v1/op/jobService/runhistory?jobName=name_from_deployment_service) to get the status of the job.  In the event deployment fails, the detailed error message should also be returned by the run history service.