VLAN assignment in WiFi

ByronZ
Getting noticed

VLAN assignment in WiFi

Hi,

 

I am trying to use Powershell with Meraki API to create 300 WiFi in MX64W, and assign a specific VLAN to it. However, I am running into issues to assigning the new WiFi to a specific VLAN. Does anyone know how to assign a VLAN to a SSID?

 

Thanks for any help.

 

ByronZ

9 Replies 9
PhilipDAth
Kind of a big deal
Kind of a big deal

Check out:

https://dashboard.meraki.com/api_docs#update-the-attributes-of-an-ssid

 

And the parameters:

  • useVlanTagging
  • vlanId

@ByronZ The link provided by @PhilipDAth  is the one you will want. You can also apply the same from the GUI if it is less than 300 Obviously. The Google Sheets integration would work great for this as well! 

 

Let us know what you find out and if you need any other help! 

 

 

Thanks DillonofAnch17 . Do you have any samples of the json data for assigning a VLAN? I tried to follow the document, but just not able to make it work.

 

Thanks

 

ByronZ

Seshu
Meraki Employee
Meraki Employee

@ByronZ Try to use very basic setting and see if it works. 

 

curl -L -H 'X-Cisco-Meraki-API-Key: <key>' -H 'Content-Type: application/json' -X PUT --data-binary '{"name":"My SSID","enabled":true, "authMode": "open", "ipAssignmentMode": "Bridge mode", "useVlanTagging": true, "vlanId": 10}' 'https://api.meraki.com/api/v0/networks/{networkId}/ssids/{number}'

 

I'm not even sure if this is supposed to work on an MX--W model devices. This is for MRs.

Nash
Kind of a big deal

Can't tell you if it's supposed to work, but I can tell you it does work. The numbering doesn't work quite like I thought it would though.

 

I put ssidNum at 4, but it assigned my test settings to number 3. I think because number 3 was pure default settings. 

 

So I guess it's trying to use the next "empty"/default SSID, regardless of what number you put in?

Seshu
Meraki Employee
Meraki Employee

@Nash Generally, SSID 1 is probably numbered 0 on the Meraki Dashboard. It may be working fine for MR SSIDs but probably is not designed to configure SSID on an MX and hence may be configuring SSIDNum-1 on the dashboard.

ByronZ
Getting noticed

In my MX, the SSID number seems working correctly. It does have an hidden ssid 0 that is not avaialbe in the web page. When I ran PUT against ssid 2, the second SSID in the web page does get updates.

ByronZ
Getting noticed

I tried like you suggested in postman, and it didn't generate any error. It was able to update everything, except for the VLAN assignment field. I tried to include "defaultVlanId": 14, and I got the same result without any error, but it just won't update the VLAN assignment field. 

 

{
"name":"My SSID",
"enabled":true,
"authMode": "open",
"ipAssignmentMode": "Bridge mode",
"useVlanTagging": true,
"vlanId": 14
}

 

Thanks

 

ByronZ

Thanks PhilipDAth.

 

When I do a GET, it is this, with useVlanTagging as false. But in the web interface, I can confirm it is assigned to a non-default VLAN. 

 

{
"number": 2,
"name": "TestWiFi",
"enabled": true,
"splashPage": "None",
"ssidAdminAccessible": false,
"authMode": "psk",
"psk": "TestPassword",
"encryptionMode": "wpa",
"wpaEncryptionMode": "WPA2 only",
"ipAssignmentMode": "Bridge mode",
"useVlanTagging": false,
"minBitrate": null,
"bandSelection": "Dual band operation",
"perClientBandwidthLimitUp": 0,
"perClientBandwidthLimitDown": 0
}

 

I am really scratching my head on why it behaves like this. I have tried to use PUT to update with both useVlanTagging,vlanId, and defaultVlanId, but it won't update. Maybe I am put the attributes in the json file wrong? I don't know...

 

Thanks

 

ByronZ

Get notified when there are additional replies to this discussion.