Fixing your LDAP service on Synology

Geplaatst
Reacties Geen

I had a bad week strugling with Synology support to get the LDAP service fixed on our RTV Hattem NAS.

In the end I had to solve the issue myself but I could not have done this without the article on https://gist.github.com/Shaltz/1d65a07a0901a36fb7f1 but the proper link is to checkcrc

The trick is to use ssh to login to your Synology NAS. Then run sudo -i to run as root to get to the proper logs.
Use tail -f /var/log/slapd.log and try to start the LDAP server.

The error that stood out was:
ldif_read_file: checksum error on "/var/packages/DirectoryServer/target/etc/data/slapd.d/cn=config/cn=schema/cn={9}ppolicy.ldif"

The article mentioned above helped me. I copied the LDIF file to another system where I had compiled the checkcrc tool and removed the first 2 lines. Then I created the CRC32 checksum and it was different.

So I made a backup copy of the LDIF file and corrected the checksum. And with a restart I did not get this error but I got he next one:
ldif_read_file: checksum error on "/var/packages/DirectoryServer/target/etc/data/slapd.d/cn=config/cn=schema/cn={9}ppolicy.ldif"

This one took me while until I did a complex search command in the tree:
find /var/packages/DirectoryServer/target/etc/data/slapd.d/ -type f -exec ls -l {} \; -exec head -5 {} \; > /var/log/ldifcheck.log

And in that log file I found an empty file. So I just moved it away to a temp directoy and gave the LDAP service another go and ……. it worked again.

Not sure if anyone ever needs this again … but it is now documented. Let me know if it saved you day as well.

Medewerker
Categorie ,

Reacties

Er zijn nog geen reacties op dit artikel.

Feedback

Schrijf je reactie hier. De met een * gemarkeerde velden zijn verplicht. Je ziet eerst een voorbeeld en daarna kun je de reactie definitief plaatsen.





← Ouder Nieuwer →