Closed roterschnee closed 5 years ago
You're totally right: the amount of memory used to store locally all IP addresses and process the delete routine is quite low. Doing one request per IP address is much more slower. Thank you so much for your contribution.
Instead of looping over every not found IP in the specified Network (could be quite a lot in a for e.g. /16 scenario) and checking with the netbox api for existence, download a complete list of all IP´s in netbox and check locally, thus minimising the API requests and speeding things up a lot. In my case a /16 net was causing an hour long delay and is now down to sub 1 second.