Netbox LDAP authentication class error - "LDAPbackend" attribute/class #14067
Replies: 5 comments 7 replies
-
|
Beta Was this translation helpful? Give feedback.
-
Thank you. Forgot about Linux capitalization. Still no joy. Now complaining about "No module named 'django_auth_ldap.backend'" Netbox Web interface output with debugging enabled: Do the OpenLDAP libraries need to be installed ? This document indicates they are required. https://django-auth-ldap.readthedocs.io/en/latest/install.html This site provides a method for Installing python-ldap. Does anybody have any experience installing this in the virtual environment. https://www.python-ldap.org/en/python-ldap-3.3.0/installing.html |
Beta Was this translation helpful? Give feedback.
-
The Exception Location references /opt/netbox/netbox/netbox/authentication.py, line 319, in new The following command returns the following: Why is LDAPBackend defined in both files ? Code Fragment of /opt/netbox/netbox/netbox/authentication.py Code Fragment of /opt/netbox-3.5.8/venv/lib/python3.9/site-packages/django_auth_ldap/backend.py |
Beta Was this translation helpful? Give feedback.
-
Thanks for the reply. Yes, django-auth-ldap has successfully been installed in the Python virtual environment. (venv) [root@scdl-ifipam-001 site-packages]# pip3 install django-auth-ldap Defined Classes in authentication.py and backend.py : (venv) [root@scdl-ifipam-001 site-packages]# egrep "^class" -n /opt/netbox/netbox/netbox/authentication.py (venv) [root@scdl-ifipam-001 site-packages]# egrep "^class" -n /opt/netbox-3.5.8/venv/lib/python3.9/site-packages/django_auth_ldap/backend.py Other steps that have been confirmed:
This is the offending command that's reported when debugging is enabled: 319 from django_auth_ldap.backend import LDAPSettings django_auth_ldap.backend appears to be defined but where is LDAPSettings defined ? debugging information: Server Components: Have compared the Pip freeze versions on the Netbox server to what is published Thanks in advance for any troubleshooting or guidance. |
Beta Was this translation helpful? Give feedback.
-
I've been trying to get Netbox running Redhat for approximately a year. Have not been able to get Secure LDAP working. I have heard that Netbox Binary images is a posibility. Where can I find this a binary netbox image ? |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Receiving the following error accessing the Netbox server after configuring configuration.py and ldap_config.py
configuration.py:
Installation of the django-auth-ldap was successful. Is there a particular folder the installation should be performed in ?
[root@scdl-ifipam-001 netbox]# pwd
/opt/netbox/netbox
[root@scdl-ifipam-001 netbox]# source /opt/netbox/venv/bin/activate
(venv) [root@scdl-ifipam-001 netbox]# pip3 install django-auth-ldap
Requirement already satisfied: django-auth-ldap in /opt/netbox-3.5.8/venv/lib/python3.9/site-packages (4.6.0)
Requirement already satisfied: Django>=3.2 in /opt/netbox-3.5.8/venv/lib/python3.9/site-packages (from django-auth-ldap) (4.1.10)
Requirement already satisfied: python-ldap>=3.1 in /opt/netbox-3.5.8/venv/lib/python3.9/site-packages (from django-auth-ldap) (3.4.3)
Requirement already satisfied: asgiref<4,>=3.5.2 in /opt/netbox-3.5.8/venv/lib/python3.9/site-packages (from Django>=3.2->django-auth-ldap) (3.7.2)
Requirement already satisfied: sqlparse>=0.2.2 in /opt/netbox-3.5.8/venv/lib/python3.9/site-packages (from Django>=3.2->django-auth-ldap) (0.4.4)
Requirement already satisfied: pyasn1>=0.3.7 in /opt/netbox-3.5.8/venv/lib/python3.9/site-packages (from python-ldap>=3.1->django-auth-ldap) (0.5.0)
Requirement already satisfied: pyasn1-modules>=0.1.5 in /opt/netbox-3.5.8/venv/lib/python3.9/site-packages (from python-ldap>=3.1->django-auth-ldap) (0.3.0)
Requirement already satisfied: typing-extensions>=4 in /opt/netbox-3.5.8/venv/lib/python3.9/site-packages (from asgiref<4,>=3.5.2->Django>=3.2->django-auth-ldap) (4.7.1)
[notice] A new release of pip is available: 23.2.1 -> 23.3
[notice] To update, run: pip install --upgrade pip
Beta Was this translation helpful? Give feedback.
All reactions