The Basics
- Nextcloud Server version (e.g., 29.x.x):
30.0.8
- Operating system and version (e.g., Ubuntu 24.04):
Ubuntu 24.04.2
- Web server and version (e.g, Apache 2.4.25):
Apache 2.4
- Reverse proxy and version _(e.g. nginx 1.27.2)
- N/A (running in a home lab, not open to the Internet)
- PHP version (e.g, 8.3):
8.3.19
- Is this the first time you’ve seen this error? (Yes / No):
- Yes
- When did this problem seem to first start?
- When joining to my Active Directory domain (tried on both Windows and Ubuntu domain controllers)
- Installation method (e.g. AlO, NCP, Bare Metal/Archive, etc.)
- Snap
- Are you using CloudfIare, mod_security, or similar? (Yes / No)
- No
Summary of the issue you are facing:
When I try to connect to my AD server using the LDAP/AD integration, Nextcloud is unable to establish a connection. When I check my log files, I see this PHP error:
ldap_search(): Search: Operations error at /snap/nextcloud/46970/htdocs/apps/user_ldap/lib/LDAP.php#282
Steps to replicate it (hint: details matter!):
- Set up a Windows server as an Active Directory domain controller (or use an existing domain)
- Enable the LDAP user and group backend
- Go to Administrative Settings > LDAP/AD integration
- Enter the details for your AD domain (hostname/IP and port for your domain controller, user DN, password, base DN)
- Click “Test Base DN”
Log entries
Nextcloud
Please provide the log entries from your Nextcloud log that are generated during the time of problem (via the Copy raw option from Administration settings->Logging screen or from your nextcloud.log
located in your data directory). Feel free to use a pastebin/gist service if necessary.