11-21-2018 09:27 AM
Hi everyone.
I'm banging my head against the wall with this one.
I'm trying to find the best way to do a bulk delete (it's in reality a hostname change) and then add several (hundreds) of devices at a time.
The last thing I tried was to move the devices to a specific "Location" (with the import tool, of course), then search for them in ISE and delete them (and I ended up finding an inconsistency in the ISE UI in which "Export All" exports the filtered devices whereas "Delete All" deletes THE ENTIRE DATABASE - but that's not the question), but having to check the hundreds of checkboxes to use the "Delete Selected" option is impractical.
So, what is to be done here?
* Just change the hostname on the .csv import file doesn't work, it barks about the IP address already in use by the "original" device
* Deleting the individual devices is impractical as there's no "Select All" option to select all the filtered devices, and "Delete All" stupidly deletes everything.
Is there a practical option to do this?
Thanks for your time.
Solved! Go to Solution.
11-22-2018 08:21 AM
Please try this:
Use External restful service:
Below curl query will get all network device's ID.
curl --insecure --user username:password -X GET \
https://<PAN node ip address>:9060/ers/config/networkdevice \
-H 'Accept: application/xml' \
-H 'Content-Type: application/xml' \
-H 'X-CSRF-TOKEN: fetch' \
-H 'cache-control: no-cache'
Below query will delete the endpoint:
curl --insecure --user username:password -X DELETE \
https://<PAN node ip address>:9060/ers/config/networkdevice/<replace with id you got from above query> \
-H 'Accept: application/xml' \
-H 'Content-Type: application/xml' \
-H 'X-CSRF-TOKEN: fetch' \
-H 'cache-control: no-cache'
Note you need to replace text highlighted in red
The username and password you have to user should have proper permission. Please check below screenshot:
Hope this reduces your efforts
11-22-2018 08:21 AM
Please try this:
Use External restful service:
Below curl query will get all network device's ID.
curl --insecure --user username:password -X GET \
https://<PAN node ip address>:9060/ers/config/networkdevice \
-H 'Accept: application/xml' \
-H 'Content-Type: application/xml' \
-H 'X-CSRF-TOKEN: fetch' \
-H 'cache-control: no-cache'
Below query will delete the endpoint:
curl --insecure --user username:password -X DELETE \
https://<PAN node ip address>:9060/ers/config/networkdevice/<replace with id you got from above query> \
-H 'Accept: application/xml' \
-H 'Content-Type: application/xml' \
-H 'X-CSRF-TOKEN: fetch' \
-H 'cache-control: no-cache'
Note you need to replace text highlighted in red
The username and password you have to user should have proper permission. Please check below screenshot:
Hope this reduces your efforts
11-22-2018 10:50 AM
11-26-2018 12:23 PM
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