Need some help in upgrading Netbox v.2.6.2 to latest version.

311 views
Skip to first unread message

Alfie Chen

unread,
Oct 19, 2021, 6:59:31 AM10/19/21
to NetBox
The Netbox is version 2.6.2, installed in a Centos7. The Netbox suggested that I should upgrade the version to v2.11. 

I've upgrade the python to v3.7, and made some change in ./upgrade.sh. It seems like I've successfully upgrade to v2.11, but it doesn't. 

When I tried to run - systemctl restart netbox netbox-rq, it gave me below error.
netbox.service: main process exited, code=exited, status=217/USER

And when I ran, python3 manage.py runserver 0.0.0.0:8000 --insecure, it gave me below:

File "manage.py", line 8, in <module> from django.core.management import execute_from_command_line ModuleNotFoundError: No module named 'django'

Wondering what is the correct sequence to upgrade it to latest version. 

Thank you in advance. 

Jeremy Stretch

unread,
Oct 19, 2021, 8:43:39 AM10/19/21
to Alfie Chen, NetBox
> ModuleNotFoundError: No module named 'django'

This usually indicates that NetBox is being run outside of its Python virtual environment. See the ExecStart line in the reference service configuration file here for an example. The binary being executed should be located within the venv directory of your installation path.

Hope that helps!

Jeremy Stretch
Distinguished Engineer, NS1
Office of the CTO
 
website: ns1.com
email: jstretch@ns1.com
 
twitterlinkedin
 
banner


--
You received this message because you are subscribed to the Google Groups "NetBox" group.
To unsubscribe from this group and stop receiving emails from it, send an email to netbox-discus...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/netbox-discuss/7f12036c-22de-4c67-8eda-86f296be7fc8n%40googlegroups.com.

Alfie Chen

unread,
Oct 23, 2021, 2:00:38 AM10/23/21
to NetBox
Thank you Jeremy for your quick reply.

Finally got it work by following below method.

Install a 2.11.0 in fresh centos 8, set up a python3.7 environment and then migrate the database over, then upgrade to 3.0.0

Thank you all.
Reply all
Reply to author
Forward
0 new messages