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

openldap wont start #162

Open
psychomantys opened this issue Apr 4, 2024 · 3 comments
Open

openldap wont start #162

psychomantys opened this issue Apr 4, 2024 · 3 comments

Comments

@psychomantys
Copy link
Contributor

I'm trying to use the openldap helm chart with a seaweed volume, but the ldap server is not starting. I've checked the logs and seen that the helm chart is successfully installed and configured, but the ldap server is not being started. The strange thing is that when I use a volume that's not from seaweed, the LDAP server starts without any issues.

I'm starting to think that the issue might be related to the seaweedfs volume, perhaps with the way the mdb is being used on top of the volume. However, I can't seem to find any logs or references that point to the root cause of the problem.

Has anyone else encountered this issue? Any help would be greatly appreciated.

Here are the logs from the LDAP server:

660e3a1e.3ad9cf10 0x7fd057985740 >>> dnNormalize: <cn=Uptime>
660e3a1e.3ad9db22 0x7fd057985740 <<< dnNormalize: <cn=uptime>
660e3a1e.3ad9f698 0x7fd057985740 >>> dnNormalize: <cn=Read>
660e3a1e.3ada01e2 0x7fd057985740 <<< dnNormalize: <cn=read>
660e3a1e.3ada1538 0x7fd057985740 >>> dnNormalize: <cn=Write>
660e3a1e.3ada1e20 0x7fd057985740 <<< dnNormalize: <cn=write>
660e3a1e.3ada31f8 0x7fd057985740 backend_startup_one: starting "dc=my-domain,dc=com"
660e3a1e.3ada3a05 0x7fd057985740 mdb_db_open: "dc=my-domain,dc=com"
660e3a1e.3add4a58 0x7fd057985740 mdb_db_open: database "dc=my-domain,dc=com": dbenv_open(/bitnami/openldap/data).

And here are the kustomize with the values.yaml for the helm chart of ldap:

apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization

helmCharts:
  - releaseName: openldap-stack-ha
    name: openldap-stack-ha
    version: 4.2.2
    repo: 'https://jp-gouin.github.io/helm-openldap/'
    includeCRDs: true
    namespace: openldap
    valuesInline:
      global:
        existingSecret: openldap-secret
        adminUser: ldapadmin
        configUser: ldapadminconfig
      env:
        LDAP_LOGLEVEL: "-1"
      persistence:
        enabled: true
      podAntiAffinityPreset: soft
@chrislusf
Copy link
Contributor

could you make some docker compose file to reproduce this?

@psychomantys
Copy link
Contributor Author

I can certainly provide access to the Kubernetes logs if that would be helpful for troubleshooting. Just let me know if you require any specific logs and I can ensure you get the necessary access on kubernetes.

For the docker-compose example, I can generate one for you. If you could provide an initial example to get the CSI initialized? That would be a great starting point. Any specific requirements or configurations you have in mind would also be useful to know.

@psychomantys
Copy link
Contributor Author

I was trying to make a working example on a docker that demonstrates the integration of seaweed with openldap. The project's repository can be found here: poc-seaweedfs-openldap.

To get the proof of concept up and running, please refer to the init.sh script located at: init.sh.

In this setup, there are two different ldap containers being used:

  • osixia/openldap
  • bitnami/openldap

Each of these stacks features two services:

  • Success service: This service utilizes local container storage and should operate normally.
  • Fail service: This service is designed to use docker bind volume, which are mapped to a weed fuse mount volume. However, this configuration is not functioning properly at the moment.

I run some tests with strace and debug mode on ldap, and set ulimit -n 4000. As i can see, there is a great memory and CPU usage after a mmap, and some times a warning msg abount killed by SIGBUS (core dumped) Bus error (core dumped) and X ch_calloc of Y elems of Z bytes failed slapd: ch_malloc.c:107: ch_calloc: Assertion '0' failed..

I'd appreciate any insights or advice on resolving the issue with the fail service. If there's any additional information you require to assist me, please let me know, and I'd be more than happy to provide it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants