Open Dome17 opened 5 years ago
This issue does not exist with Netbox 2.8 anymore, at least to my understanding. This script uses the default maximum of 1000 and makes subsequent requests if more than 1000 entries exist. I tested this by setting the script limit to 4. The exact same output is generated. All good. Also note that there are two settings: MAX_PAGE_SIZE
and PAGINATE_COUNT
.
This can be closed.
On line 281 in the netbox-joined inventory script the pagination limit is generally set to 256: api_url_params['limit'] = 256
When we updated Netbox to the latest version (v.2.5.13), the script didn't work anymore and hanged itself while reading the interfaces of a switch. As already mentioned, the source of the error was the too low limit of 256.
The reason was, that not all interfaces were read by the script as the limit seems to be too small after the upgrade. Missing interfaces lead to a "KEY-Error".
When we raised the limit to 1000, the script worked fine again. (Pagination Max 1000)
However, I am of the opinion that this error could also have occurred inconspicuously, which would have resulted in a misconfiguration of the interfaces. Could the limit of 1000 be exceeded at some point without immediately noticing this in order to avoid misconfiguration? Or can I rely on this limit being sufficient?
Would be great if you could take a look at this failure. Thank you very much.