cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
3826
Views
0
Helpful
5
Replies

Export ACI Config (JSON) for a specific tenant

ivanindic
Level 1
Level 1

Dear all,

I have created a standard ACI tenant with the corresponding VRFs, BD, ANPs, L3Outs etc.

I would like to export only this tenant configuration as JSON (for automation purposes). Is this possible?

I have exported the full config as JSON but it's a nightmare to find all the relevant objects which belong to the same tenant.

Thx a lot for your support.

Best regards

Ivan

1 Accepted Solution

Accepted Solutions

stcorry
Cisco Employee
Cisco Employee

Hello Ivan! There's a number of ways to do this.

 

First, from a full export, all of the Tenant objects should be under a single object, the fvTenant object with the attribute name="your-tenant-name". It shouldn't be hard to find and extract that object with your favorite JSON editor. 

 

The  other way would be to go to your Tenant and right click on the tenant name in the navigation pane on the left, then click 'Save As' and select the options 'Config Only' and 'JSON'. You should then get a download for a JSON file.

 

Another way is to create a DN based export by specifying the DN of the tenant, something like 'uni/tn-Tenant_Name'. This will export the JSON in a tar.gz file to the destination you specify.

 

Hopefully that works for you!

View solution in original post

5 Replies 5

stcorry
Cisco Employee
Cisco Employee

Hello Ivan! There's a number of ways to do this.

 

First, from a full export, all of the Tenant objects should be under a single object, the fvTenant object with the attribute name="your-tenant-name". It shouldn't be hard to find and extract that object with your favorite JSON editor. 

 

The  other way would be to go to your Tenant and right click on the tenant name in the navigation pane on the left, then click 'Save As' and select the options 'Config Only' and 'JSON'. You should then get a download for a JSON file.

 

Another way is to create a DN based export by specifying the DN of the tenant, something like 'uni/tn-Tenant_Name'. This will export the JSON in a tar.gz file to the destination you specify.

 

Hopefully that works for you!

Hi Corry,

 

Thx a lot. You are right, I recognized that asap as you mentioned it. :-).

 

The only thing not associated to the tenant are VLANs used for the L3Outs. That also includes touching the PDs, AAEPs during automation. But I guess those objects are more or less shared across multiple tenants as they are related to physical interfaces, so I will work through it.

 

Have a great day.

 

Br,

Ivan

Excellent! You will find most of the Access Policies under an object called uni/infraInfra. There you can find int policy groups, vlan pools, aaeps, and other things. Domains will be a top level object under uni/

Remi Astruc
Level 1
Level 1

Hi Ivan,

In the GUI, go in Tenants, right-click on your tenant and "Save as...", then download:

Capture.PNG

 

Remi Astruc

Hi Remi,

Thx a lot. You are right. :-)

Have a good day.

Br,
Ivan

Save 25% on Day-2 Operations Add-On License