07-24-2024 08:28 AM
Hi,
I have PhysDom and this already has vlansInstP object, example: uni/infra/vlanns-[SRV]-static
This vlansInstP object already has lots of fvnsEncapBlk object with from/to vlan IDs.
I have checked if vlan exists in any of the fvnsEncapBlk ranges and this would be new vlan.
So, how do I add new fvnsEncapBlk object (with new vlan) into vlansInstP object.
POST https://apic/api/mo/uni/infra/vlanns-[SRV]-static.xml with body
<fvnsEncapBlk status="" role="inherit" from="vlan-555" to="vlan-555">
Do I need to change any status values, because I don't want to delete existing vlans or change existing vlansInstP object, just add new vlan (fvnsEncapBlk)?
If I want to delete fvnsEncapBlk, is it just same operation and status="deleted" in fvnsEncapBlk object?
Thanks
Solved! Go to Solution.
07-26-2024 12:23 AM
To reply to myself:
POST https://apic/api/mo/uni/infra/vlanns-[SRV]-static.xml with body
<fvnsEncapBlk status="" role="inherit" from="vlan-555" to="vlan-555">
Will add VLAN 555 into vlanns.
I guess status="deleted" will remove VLAN from vlanns
07-26-2024 12:23 AM
To reply to myself:
POST https://apic/api/mo/uni/infra/vlanns-[SRV]-static.xml with body
<fvnsEncapBlk status="" role="inherit" from="vlan-555" to="vlan-555">
Will add VLAN 555 into vlanns.
I guess status="deleted" will remove VLAN from vlanns
07-26-2024 05:02 AM
You're trying to add a new VLAN to an existing vlansInstP object in Cisco APIC using REST API. The vlansInstP object already contains multiple fvnsEncapBlk objects defining VLAN ranges. You want to add a new fvnsEncapBlk with a single VLAN without affecting the existing configuration.
<config>
<fvnsEncapBlk status="created" role="inherit" from="vlan-555" to="vlan-555">
</fvnsEncapBlk>
</config>
Discover and save your favorite ideas. Come back to expert answers, step-by-step guides, recent topics, and more.
New here? Get started with these tips. How to use Community New member guide