LDAP / AD integration Nextcloud 18.0.1

Hello everyone,

i installed Nextcloud 18 to my ubuntu server and i am not able to integrate users and groups from Active Directory.

Configuration:

It doesn’t show me if the configuration is ok or not and none of the buttons have any effect.
The Logs doesn’t show any information about the AD integration.
The continue button is greyed out and i am not able to get further in the wizard.
With the ldapsearch command in terminal i am able to connect to AD with a result of search.

My environment:

Ubuntu Server 18.04.4 LTS
NginX 1.14.0
MariaDB 10.1.44
PHP 7.2.24
Nextcloud 18 updated to 18.0.1

Anybody got any ideas?

Many thanks in advance,

1 Like

Hi Ngine

I did almost the same, nextcloud ova Appliance installed.
I have the AD connection but see only a part of the users in a OU from AD.

cheers … jr

He is still looking for the server (see the circle behind server?)
type in
ldaps://nextcloud.ngine.local:636
for the server

Hi hartmut,

i tried to type the way too. I have typed ldaps:// and ldap:// with the ports 636 and 389.
But no reaction.

Are you able to perform a Port detect or a Test Base DN ?

No i am not able. This is the main issue.

Yes, but then it is more like a network problem, because if you are not even able to do a Port test (which has nothing to do with login) then I would say you have to look in php ldap errorlogs.
What version is your php-ldap package?

The solution for this issue is:
I added the following line to all files under the folder /var/www/nextcloud/apps/user_ldap/ajax/*:

require_once($_SERVER['DOCUMENT_ROOT'].'/lib/base.php');

A example for the file wizard.php:

 * @license AGPL-3.0
 *
 * This code is free software: you can redistribute it and/or modify
 * it under the terms of the GNU Affero General Public License, version 3,
 * as published by the Free Software Foundation.
 *
 * This program is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
 * GNU Affero General Public License for more details.
 *
 * You should have received a copy of the GNU Affero General Public License, version 3,
 * along with this program. If not, see <http://www.gnu.org/licenses/>
 *
 */

require_once($_SERVER['DOCUMENT_ROOT'].'/lib/base.php');

// Check user and app status
\OC_JSON::checkAdminUser();
\OC_JSON::checkAppEnabled('user_ldap');
\OC_JSON::callCheck();
4 Likes

I can confirm that worked for me as well (Ubuntu 20.04, Nextcloud 20.0.0). Thanks @Ngine!

Sames sympthoms on freenas with nexcloud in jail , js files where not found. ldap scripts has been move from apps to apps-pkg

dirty fix :
#iocage console nextcloud
#cd /usr/local/www/nextcloud/apps
#ln -s …/apps-pkg/user_ldap user_ldap

1 Like

Thank you so much, man! You save my life!

Confirming that works. Should be reported to the development team.

i’m doing like that,but cannot fix my error
anyone can help?
/usr/local/www/nextcloud/apps-pkg/user_ldap/ajax/


Reported, see https://github.com/nextcloud/server/issues/24314

The current nginx configuration is broken: nextcloud/documentation#2197.

That’s the reason for this issue not a missing import or include.

Thank you so much! It worked for me on dockerized installation.

@Eric_Bxl there is a typo in your “ln”-command (or the forum messed it up): the two dots are represented as one character. If you copy&paste your command it seems to work but it doesnt :slight_smile:

cd /usr/local/www/nextcloud/apps
ln -s ../apps-pkg/user_ldap user_ldap

But thank you for the hint, creating the link made the LDAP-app work for me.

Good, I have a nextcloud version 22 and installed the integration plugin with ldap, it connects me well and synchronizes well, what nothing else gives me from my ldap 1000 user or 1000 something but is that in my ldapt I have 2000 and a peak of users and Other services that read it if they read it but the nextcloud only lends 1000 this is something that I must modify ren the code of the nextcloud or it has a limitation on the number of users greetings