Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Bug]: Test Base DN, Shows error: Base DN appears to be wrong, An error occurred. Please check the Base DN, as well as connection settings and credentials. #30887

Closed
5 of 8 tasks
devent opened this issue Jan 27, 2022 · 8 comments
Labels
0. Needs triage Pending check for reproducibility or if it fits our roadmap bug needs info

Comments

@devent
Copy link

devent commented Jan 27, 2022

⚠️ This issue respects the following points: ⚠️

  • This is a bug, not a question or a configuration/webserver/proxy issue.
  • This issue is not already reported on Github (I've searched it).
  • Nextcloud Server is up to date. See Maintenance and Release Schedule for supported versions.
  • I agree to follow Nextcloud's Code of Conduct.

Bug description

Setup LDAP, Test Base DN, Shows error: Base DN appears to be wrong, An error occurred. Please check the Base DN, as well as connection settings and credentials.

Steps to reproduce

  1. Activate LDAP User
  2. Add LDAP Server openldap.kube-ldap.svc.cluster.local
  3. Port 1389
  4. Setup Admin DN CN=admin,dc=muellerpublic,dc=de
  5. Setup Password
  6. Set Base DN dc=muellerpublic,dc=de
  7. Click Test Base Dn
  8. Error Configuration incorrect and Base DN appears to be wrong

EDIT: Forget step set base DN

Expected behavior

Base DN is verified

Installation method

Official Docker image

Operating system

Debian/Ubuntu

PHP engine version

PHP 8.0

Web server

Nginx

Database engine version

PostgreSQL

Is this bug present after an update or on a fresh install?

Fresh Nextcloud Server install

Are you using the Nextcloud Server Encryption module?

Encryption is Enabled

What user-backends are you using?

  • Default user-backend (database)
  • LDAP/ Active Directory
  • SSO - SAML
  • Other

Configuration report

{
    "system": {
        "htaccess.RewriteBase": "\/",
        "memcache.local": "\\OC\\Memcache\\APCu",
        "apps_paths": [
            {
                "path": "\/var\/www\/html\/apps",
                "url": "\/apps",
                "writable": false
            },
            {
                "path": "\/var\/www\/html\/custom_apps",
                "url": "\/custom_apps",
                "writable": true
            }
        ],
        "memcache.distributed": "\\OC\\Memcache\\Redis",
        "memcache.locking": "\\OC\\Memcache\\Redis",
        "redis": {
            "host": "***REMOVED SENSITIVE VALUE***",
            "port": "6379",
            "password": "***REMOVED SENSITIVE VALUE***"
        },
        "mail_smtpmode": "smtp",
        "mail_smtphost": "***REMOVED SENSITIVE VALUE***",
        "mail_smtpport": "587",
        "mail_smtpsecure": "tls",
        "mail_smtpauth": true,
        "mail_smtpauthtype": "LOGIN",
        "mail_smtpname": "***REMOVED SENSITIVE VALUE***",
        "mail_from_address": "***REMOVED SENSITIVE VALUE***",
        "mail_domain": "***REMOVED SENSITIVE VALUE***",
        "mail_smtppassword": "***REMOVED SENSITIVE VALUE***",
        "passwordsalt": "***REMOVED SENSITIVE VALUE***",
        "secret": "***REMOVED SENSITIVE VALUE***",
        "trusted_domains": [
            "localhost",
            "nextcloud.muellerpublic-de-cloud.svc.cluster.local",   
            "nextcloud",
            "10.0.0.0\/8",
            "cloud.muellerpublic.de"
        ],
        "datadirectory": "***REMOVED SENSITIVE VALUE***",
        "dbtype": "pgsql",
        "version": "22.2.3.0",
        "overwrite.cli.url": "https:\/\/cloud.muellerpublic.de",
        "dbname": "***REMOVED SENSITIVE VALUE***",
        "dbhost": "***REMOVED SENSITIVE VALUE***",
        "dbport": "",
        "dbtableprefix": "oc_",
        "dbuser": "***REMOVED SENSITIVE VALUE***",
        "dbpassword": "***REMOVED SENSITIVE VALUE***",
        "installed": true,
        "instanceid": "***REMOVED SENSITIVE VALUE***",
        "log_type": "file",
        "loglevel": 0,
        "overwritehost": "cloud.muellerpublic.de",
        "overwriteprotocol": "https",
        "ldapProviderFactory": "OCA\\User_LDAP\\LDAPProviderFactory",
        "check_data_directory_permissions": false
    }
}

List of activated Apps

- accessibility: 1.8.0
  - activity: 2.15.0
  - circles: 22.1.1
  - cloud_federation_api: 1.5.0
  - comments: 1.12.0
  - contactsinteraction: 1.3.0
  - dashboard: 7.2.0
  - dav: 1.19.0
  - encryption: 2.10.0
  - federatedfilesharing: 1.12.0
  - federation: 1.12.0
  - files: 1.17.0
  - files_pdfviewer: 2.3.1
  - files_rightclick: 1.1.0
  - files_sharing: 1.14.0
  - files_trashbin: 1.12.0
  - files_versions: 1.15.0
  - files_videoplayer: 1.11.0
  - firstrunwizard: 2.11.0
  - logreader: 2.7.0
  - lookup_server_connector: 1.10.0
  - nextcloud_announcements: 1.11.0
  - notifications: 2.10.1
  - oauth2: 1.10.0
  - password_policy: 1.12.0
  - photos: 1.4.0
  - privacy: 1.6.0
  - provisioning_api: 1.12.0
  - recommendations: 1.1.0
  - serverinfo: 1.12.0
  - settings: 1.4.0
  - sharebymail: 1.12.0
  - support: 1.5.0
  - survey_client: 1.10.0
  - systemtags: 1.12.0
  - theming: 1.13.0
  - twofactor_backupcodes: 1.11.0
  - updatenotification: 1.12.0
  - user_ldap: 1.12.1
  - user_status: 1.2.0
  - viewer: 1.6.0
  - weather_status: 1.2.0
  - workflowengine: 2.4.0

Nextcloud Signing status

No errors have been found.

Nextcloud Logs

Debug   encryption      /appinfo/app.php is deprecated, use \OCP\AppFramework\Bootstrap\IBootstrap on the application class instead.   2022-01-27T15:46:01+00:00  
                                                                                                                                                                    
  Debug   files_sharing   /appinfo/app.php is deprecated, use \OCP\AppFramework\Bootstrap\IBootstrap on the application class instead.   2022-01-27T15:46:01+00:00  
                                                                                                                                                                    
  Debug   cron            Run OCA\DAV\BackgroundJob\CalendarRetentionJob job with ID 22                                                  2022-01-27T15:46:01+00:00  
                                                                                                                                                                    
  Debug   cron            Finished OCA\DAV\BackgroundJob\CalendarRetentionJob job with ID 22 in 0 seconds                                2022-01-27T15:46:01+00:00  
                                                                                                                                                                    
  Debug   encryption      /appinfo/app.php is deprecated, use \OCP\AppFramework\Bootstrap\IBootstrap on the application class instead.   2022-01-27T15:46:01+00:00  
                                                                                                                                                                    
  Debug   files_sharing   /appinfo/app.php is deprecated, use \OCP\AppFramework\Bootstrap\IBootstrap on the application class instead.   2022-01-27T15:46:01+00:00  
                                                                                                                                                                    
  Debug   encryption      /appinfo/app.php is deprecated, use \OCP\AppFramework\Bootstrap\IBootstrap on the application class instead.   2022-01-27T15:46:31+00:00  
                                                                                                                                                                    
  Debug   files_sharing   /appinfo/app.php is deprecated, use \OCP\AppFramework\Bootstrap\IBootstrap on the application class instead.   2022-01-27T15:46:31+00:00  
                                                                                                                                                                    
  Debug   encryption      /appinfo/app.php is deprecated, use \OCP\AppFramework\Bootstrap\IBootstrap on the application class instead.   2022-01-27T15:46:45+00:00  
                                                                                                                                                                    
  Debug   files_sharing   /appinfo/app.php is deprecated, use \OCP\AppFramework\Bootstrap\IBootstrap on the application class instead.   2022-01-27T15:46:45+00:00

Additional info

There is really no log entry at all that are relevant.

My config works with other apps like Gitea and Grafana.

Nextcloud and OpenLDAP run on a Kubernetes cluster. I don’t even know if the LDAP App is doing anything. There are no logs and no access is made to the OpenLDAP server.

@devent devent added 0. Needs triage Pending check for reproducibility or if it fits our roadmap bug labels Jan 27, 2022
@devent devent changed the title [Bug]: [Bug]: Test Base DN, Shows error: Base DN appears to be wrong, An error occurred. Please check the Base DN, as well as connection settings and credentials. Jan 27, 2022
@devent
Copy link
Author

devent commented Jan 27, 2022

Sorry, I somehow forgot about the title.

@Bueddl
Copy link

Bueddl commented Aug 25, 2022

I am experiencing the same issue, also without any indication in the logs. Version is 24.0.4.1.
Were you able to solve this?

@Bueddl
Copy link

Bueddl commented Aug 25, 2022

At least in my base this is related to #16194.
Applying the rewrites from nextcloud/documentation#2197 (comment) to my config fixed it for me.

@P8ntBal1551
Copy link

Were you ever able to find a solution to this? I'm experiencing the exact same thing on the official nextcloud docker image as well.

@Bueddl
Copy link

Bueddl commented Sep 29, 2022

Were you ever able to find a solution to this? I'm experiencing the exact same thing on the official nextcloud docker image as well.

Did you apply the changes from nextcloud/documentation#2197 (comment) ?

@P8ntBal1551
Copy link

I have no file in /var/www/html that contains "location ~ .php". My head is probably up my bottom, but where would I find this file?

@szaimen
Copy link
Contributor

szaimen commented Jan 23, 2023

Hi, please update to 24.0.9 or better 25.0.3 and report back if it fixes the issue. Thank you!

My goal is to add a label like e.g. 25-feedback to this ticket of an up-to-date major Nextcloud version where the bug could be reproduced. However this is not going to work without your help. So thanks for all your effort!

If you don't manage to reproduce the issue in time and the issue gets closed but you can reproduce the issue afterwards, feel free to create a new bug report with up-to-date information by following this link: https://github.com/nextcloud/server/issues/new?assignees=&labels=bug%2C0.+Needs+triage&template=BUG_REPORT.yml&title=%5BBug%5D%3A+

@P8ntBal1551
Copy link

I fixed it by nuking the database.

I tried to re-create the nextcloud server from scratch, but as soon as I connected it to the SQL database; LDAP killed itself again. The only solution was to re-create everything from scratch, including the database.

I didn't try other versions of nextcloud, but I wouldn't hold my breath.

@szaimen szaimen closed this as completed Mar 6, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
0. Needs triage Pending check for reproducibility or if it fits our roadmap bug needs info
Projects
None yet
Development

No branches or pull requests

4 participants