Upgrade from 3.3.7 to 4.4.2 fails;;; #11387
-
NetBox versionv3.4.7 Python version3.9 Steps to Reproduce
Expected Behaviorupgrade.sh returns no error. Observed BehaviorMigration error : Running migrations: Note :
|
Beta Was this translation helpful? Give feedback.
Replies: 5 comments 6 replies
-
(I think you mean 3.4.2, not 4.4.2)
Check the release notes:
What version of Postgres are you running?
Do you have two VMs with names like "foo" and "Foo"? |
Beta Was this translation helpful? Give feedback.
-
That shouldn't be possible, due to postgres-level uniqueness constraints:
How many do you have? Try:
|
Beta Was this translation helpful? Give feedback.
-
Well, I've not exactely the same : netbox=# \d virtualization_vminterface; But : netbox=# Before that, I manually removed all virtual machine names like "Device1" and "device1". There is still this error message in upgrade.sh : Christophe. |
Beta Was this translation helpful? Give feedback.
-
Yes, this one was missing : `ALTER TABLE ONLY public.virtualization_vminterface ` All is Ok now! Thank you very much, Christophe. |
Beta Was this translation helpful? Give feedback.
-
I have a similar but different issue. I'm getting an error upgrading from v3.3.10 to v3.4.0: ValueError: Found wrong number (0) of constraints for dcim_device(virtual_chassis_id, vc_position) Any ideas?
|
Beta Was this translation helpful? Give feedback.
Yes, this one was missing :
`ALTER TABLE ONLY public.virtualization_vminterface
ADD CONSTRAINT virtualization_vminterface_unique_virtual_machine_name UNIQUE (virtual_machine_id, name);
`
All is Ok now!
Thank you very much,
Christophe.