Skip to content

slow ldap user search  #912

Closed
Closed

Description

@jamoedv

Hello,

when searching Users to invite, it takes very long to find a user. (up to 10 min)
The user search in the file sharing app works very fast. Any tip on what I could check ? We are connected to a AD with several thousand users.. but as I said only in the polls invitation it is very slow.

thank you.

Activity

  1. changed the title [-]Ldap very slow[/-] [+]slow ldap user search [/+] on Apr 22, 2020
  2. dartcafe commented on Apr 23, 2020

    @dartcafe
    Collaborator

    Interesting. I'd say 9 min are acceptable. But 10? 😁
    To be serious. Seems, we have to refactor the sharing functions. maybe related to #881 or at least should be considered together.

    @scroom, @herrmannsdorfer, @BurtGummer, @phimeas, @PpaiSanchez
    As you seem to use (or did use) polls with LDAP: Do you recognize similar behavior?

  3. herrmannsdorfer commented on Apr 23, 2020

    @herrmannsdorfer

    No problems here (NC 18.0.4, polls 1.4.2). AD search delivers results within milliseconds. But our AD has < 1.000 usr. And NC usr subset is preselected by LDAP filter in settings.

    Considering a large userbase on AD I would ask @blizzz for advice. He is working on LDAP optimizations eg nextcloud/server#19919.

  4. blizzz commented on Apr 23, 2020

    @blizzz
    Member

    I don't know what the Polls app is doing there, but it suppose it is also just calling the user manager. Hopefully not to fetch all users at once. That would be indeed something to improve here. Someone else shall shed more light there.

    If this is all proper, then slow user search is a setup/config issue and rather to be followd up on in the forums, or with a subscription.

  5. jamoedv commented on Apr 23, 2020

    @jamoedv
    Author
  6. blizzz commented on Apr 23, 2020

    @blizzz
    Member

    If i try to invite users the search
    iterates through all users until it finds the right one. During this search
    it also tries to load and display the users foto.

    Ah… yes. This does not scale with many users of course. Someone would need to adjust the polls app to do it differently.

  7. dartcafe commented on Apr 23, 2020

    @dartcafe
    Collaborator

    Hopefully not to fetch all users at once.

    I think, that this maybe an issue. As I said, the search needs an overwork.

  8. dartcafe commented on Jun 11, 2020

    @dartcafe
    Collaborator

    @jamoedv I want to get in this issue now and need some information.

    During this search it also tries to load and display the users foto.

    Polls does not try to load fotos from the users, but from the contacts. Can you verify this?
    Did you connect the contacts app to the LDAP or have a big amount of contacts?

    Polls does three searches

    • groups -> via groupManager
    • users -> via userManager
    • contacts -> via contactsManager

    and it tries to identify, if an email address is entered.

  9. dartcafe commented on Jun 11, 2020

    @dartcafe
    Collaborator

    When getting contacts, the systemaddressbook is skipped and only user's address books should be scanned. Maybe the LDAP is also delivered via the contactsManager and scanned. I removed the scanning of the photo from the vcard.

  10. dartcafe commented on Jun 11, 2020

    @dartcafe
    Collaborator

    I hope, that helps. I cannot test this because I have no LDAP running.

  11. added a commit that references this issue on Jun 11, 2020
    a4a571a
  12. added a commit that references this issue on Jul 7, 2020
    93ef72a
  13. github-actions commented on Jun 7, 2024

    @github-actions

    This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

  14. locked as resolved and limited conversation to collaborators on Jun 7, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions