NetBox Cross-Version Restore Schema Mismatch Between 3.x and 4.x
0 reputation · 26 Mar 2023, 19:07 UTC
NetBox’s backup and restore management commands produce and consume JSON exports that track all objects, but the JSON schema differs significantly between NetBox 3.x and 4.x. When restoring a 3.x export into a 4.x instance, the restore process may encounter validation failures if the target version lacks fields present in the backup, or if schema migration scripts have not been applied correctly.
The uncertainty centers on whether a direct restore is viable without pre-migration, and how to confirm that recovered infrastructure data—such as device inventories and object relationships—remains consistent after import. While the restore command attempts to preserve original object IDs, schema drift can complicate this guarantee.
What is the documented behavior when a NetBox 3.x backup is restored into a 4.x environment without explicit schema conversion, and what failure modes should be anticipated? How can administrators verify that restored device and object counts match the source without relying on post-restore API queries alone? Are there version-specific constraints on which fields or relationships survive a cross-version restore?