Is ~8 seconds normal for fetching ~1k devices via NetBox API? #20928
PeterKnotek
started this conversation in
General
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Body:
Hi everyone,
I’m working with a NetBox instance (https://netbox.domain/api/dcim/devices/) and I noticed that fetching around 1,077 devices takes roughly 8 seconds. I tried several variations:
Fetch all fields:
https://netbox.domain/api/dcim/devices/?limit=9999
real 0m7.805s
Fetch only selected fields:
https://netbox.domain/api/dcim/devices/?limit=9999&fields=site,location,role,name,primary_ip,device_type,custom_fields
real 0m7.886s
Explicit JSON format:
https://netbox.domain/api/dcim/devices/?limit=9999&format=json
real 0m8.077s
Even limiting the fields didn’t seem to reduce the response time significantly.
Additional context:
I’m running NetBox on a virtual machine with 4 CPU cores and 6 GB RAM. I noticed that during a GET request for all devices, one core spikes to 100% for a short period, while the others remain mostly idle.
Questions:
Thanks
Beta Was this translation helpful? Give feedback.
All reactions