Seafile 11.0.9 - Can't login with client

My YunoHost server

Hardware: VM on an Linux KVM host
YunoHost version: 11.2.21.2
I have access to my server : Through SSH and through the webadmin and direct access via keyboard / screen
Are you in a special context or did you perform some particular tweaking on your YunoHost instance ? : no

Description of my issue

I installed a new yunohost server and installed seafile with version 11.0.9~ynh1.

On the first look everything looks fine and I got no error messages during installation process.

But with the seafile client on my desktop a login is not possible.

I tried to find any error messages on the seafile web interface and found the following.

Inside the log-files I was searching for any ldap related messages and found the following.

/var/log/seafile# find . -type f | xargs grep ldap
./seafevents.log:[2024-07-20 18:59:43,663] [WARNING] LDAP info is not set completely in seahub_settings.py, stop ldap test.
./seafevents.log:[2024-07-20 18:59:43,673] [WARNING] Can not start ldap syncer: it is not enabled!
./seahub.log:2024-07-20 21:00:49,798 [ERROR] seahub.api2.endpoints.admin.users:942 get Failed to bind ldap server: {'result': -1, 'desc': "Can't contact LDAP server", 'errno': 107, 'ctrls': [], 'info': 'Transport endpoint is not connected'}
./seahub.log:2024-07-20 21:00:49,801 [ERROR] django.request:241 log_response Internal Server Error: /seafile/api/v2.1/admin/ldap-users/
./seahub.log:2024-07-20 21:00:57,435 [ERROR] seahub.api2.endpoints.admin.users:942 get Failed to bind ldap server: {'result': -1, 'desc': "Can't contact LDAP server", 'errno': 107, 'ctrls': [], 'info': 'Transport endpoint is not connected'}
./seahub.log:2024-07-20 21:00:57,437 [ERROR] django.request:241 log_response Internal Server Error: /seafile/api/v2.1/admin/ldap-users/
./seahub.log:2024-07-20 21:00:59,145 [ERROR] seahub.api2.endpoints.admin.users:942 get Failed to bind ldap server: {'result': -1, 'desc': "Can't contact LDAP server", 'errno': 107, 'ctrls': [], 'info': 'Transport endpoint is not connected'}
./seahub.log:2024-07-20 21:00:59,147 [ERROR] django.request:241 log_response Internal Server Error: /seafile/api/v2.1/admin/ldap-users/

Hello,

Would be interesting to know if this change solve your issue:

In /opt/yunohost/seafile/conf/seahub_settings.py replace

LDAP_SERVER_URL = 'ldap://localhost:389'
by
LDAP_SERVER_URL = 'ldap://127.0.0.1:389'

Than, run systemctl restart seafile.service seahub.service

And try again.

Hello Josue,

replacing localhost by 127.0.0.1 solved my issue.

Many thanks.

Just for information.

nslookup localhost
Server:		x.x.x.x
Address:	x.x.x.x#53

Name:	localhost
Address: 127.0.0.1
Name:	localhost
Address: ::1

I had the same problem and tried the same fix. Now at the seafile admin-page I see my ldap users. But when I try to login using an ldap-user I see the following message:

Error, new user registration is not allowed, please contact administrator

.
Is there a switch in the seafile config to allow using ldap users?

This topic was automatically closed 15 days after the last reply. New replies are no longer allowed.