07-25-2021 02:06 AM
I am trying to get a list of all EPGs used in our fabric. Can someone assist with a script to use on postman or a moquery command to run.
Solved! Go to Solution.
07-25-2021 03:42 AM
Hi @tawa-ndafa ,
To see all EPGs, run the following command from an APIC:
apic1# moquery -c fvAEPg | egrep "^name\ "
However, if you have multiple tenants using he same EPG names, you might find filtering on distinguished name (dn) better than filtering on "name" - i.e:
apic1# moquery -c fvAEPg | egrep "^dn\ "
I hope this helps.
Don't forget to mark answers as correct if it solves your problem. This helps others find the correct answer if they search for the same problem.
07-25-2021 05:08 AM
Hi @tawa-ndafa
If all you are looking for is to get all EPGs configured in your fabric, then you can do a GET to this URL:
https://{{apic_ip}}/api/class/fvAEPg.json
Stay safe,
Sergiu
07-25-2021 03:42 AM
Hi @tawa-ndafa ,
To see all EPGs, run the following command from an APIC:
apic1# moquery -c fvAEPg | egrep "^name\ "
However, if you have multiple tenants using he same EPG names, you might find filtering on distinguished name (dn) better than filtering on "name" - i.e:
apic1# moquery -c fvAEPg | egrep "^dn\ "
I hope this helps.
Don't forget to mark answers as correct if it solves your problem. This helps others find the correct answer if they search for the same problem.
07-28-2021 11:34 AM
This worked well. Thank you
07-25-2021 05:08 AM
Hi @tawa-ndafa
If all you are looking for is to get all EPGs configured in your fabric, then you can do a GET to this URL:
https://{{apic_ip}}/api/class/fvAEPg.json
Stay safe,
Sergiu
07-28-2021 11:36 AM
I will test this with postman. Thank you.
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