LDAP auf DS108j (später DS109) einrichten?

Status
Für weitere Antworten geschlossen.

Garfield

Benutzer
Mitglied seit
09. Jul 2008
Beiträge
193
Punkte für Reaktionen
0
Punkte
16
Hallo zusammen,

hat von Euch schon jemand den openLDAP auf der DiskStation installiert? Ich möchte LDAP gerne nutzen, um meine Outlook-Kontakte ins LDAP zu übertragen und dann überall nutzen zu können.

Leider habe ich absolut keine Ahnung, wie ich da was konfigurieren muss :(. Ist euch eine Anleitung bekannt (sehr gerne deutsch) die alles schön erklärt?

LG
Markus
 

jahlives

Benutzer
Mitglied seit
19. Aug 2008
Beiträge
18.275
Punkte für Reaktionen
4
Punkte
0

NASsie

Benutzer
Mitglied seit
17. Jan 2009
Beiträge
150
Punkte für Reaktionen
0
Punkte
16
...hat das schon jemand geschafft?

Ich habdas mal installiert und es scheint soweit, mit ein paar Fehlermeldungen, geklappt zu haben:

ipkg install openldap
Installing openldap (2.3.43-2) to root...
Downloading http://ipkg.nslu2-linux.org/feeds/optware/syno-e500/cross/unstable/openldap_2.3.43-2_powerpc.ipk
Installing cyrus-sasl (2.1.23-2) to root...
Downloading http://ipkg.nslu2-linux.org/feeds/optware/syno-e500/cross/unstable/cyrus-sasl_2.1.23-2_powerpc.ipk
Configuring cyrus-sasl

Please read the man page of saslauthd and
check settings in /opt/etc/init.d/S52saslauthd

If you dislike the link /usr/lib/sasl2 -> /opt/lib/sasl2
then you may want to set SASL_PATH instead

(re)starting service saslauthd
/opt/etc/init.d/S52saslauthd: /opt/etc/init.d/S52saslauthd: 7: /opt/bin/pidof: not found
Configuring openldap
Starting OpenLDAP
/opt/etc/init.d/S58slapd: /opt/etc/init.d/S58slapd: 5: /opt/bin/pidof: not found
Successfully terminated.
 
Zuletzt bearbeitet:

goetz

Super-Moderator
Teammitglied
Sehr erfahren
Mitglied seit
18. Mrz 2009
Beiträge
14.016
Punkte für Reaktionen
272
Punkte
393
Hallo,
pidof ist Bestandteil des Paketes psmisc.

Gruß Götz
 

NASsie

Benutzer
Mitglied seit
17. Jan 2009
Beiträge
150
Punkte für Reaktionen
0
Punkte
16
danke, psmisc ist auf jeden Fall notwendig gewesen, um LDAP ueberhaupt zum Laufen zu bringen...
Rich (BBCode):
# ipkg install psmisc
Installing psmisc (22.11-1) to root...
Downloading http://ipkg.nslu2-linux.org/feeds/optware/syno-e500/cross/unstable/psmisc_22.11-1_powerpc.ipk
Configuring psmisc
update-alternatives: Linking //opt/bin/killall to /opt/bin/psmisc-killall
update-alternatives: Linking //opt/bin/pidof to /opt/bin/psmisc-killall
Successfully terminated.
 

NASsie

Benutzer
Mitglied seit
17. Jan 2009
Beiträge
150
Punkte für Reaktionen
0
Punkte
16
So wird der LDAP-Server eingerichtet

So, also LDAP laeuft anscheinend, allerdings bekomme ich irgendwie noch keine Adressdaten in's Verzeichnis... :)

So bin ich vorgegangen:

Rich (BBCode):
# ipkg -force-depends install openldap

Folgende Zeilen in die Datei /opt/etc/openldap/slapd.conf per vi oben einfuegen (falls das core.schema schon drin steht, einfach weglassen)
Rich (BBCode):
include /opt/etc/openldap/schema/core.schema
include /opt/etc/openldap/schema/cosine.schema
include /opt/etc/openldap/schema/inetorgperson.schema
include /opt/etc/openldap/schema/misc.schema
include /opt/etc/openldap/schema/openldap.schema

Ein Zugangspassword generieren (die rote Zeile gut notieren, bzw. kopieren. Das ist der verschluesselte Hash-Wert des Passwortes)
Rich (BBCode):
# slappasswd
# New password:
# Re-enter new password:
{SSHA}xxxxxxxxxxxxxxxxxxxxxxx

Hash-Wert wieder in die Konfigurations-Datei /opt/etc/openldap/slapd.conf eintragen. Ich habe es in die Datenbank-Sektion eingetragen
Rich (BBCode):
suffix          "dc=mydomain,dc=com"
rootdn          "cn=[your ldap admin username],dc=mydomain,dc=com"
rootpw          {SSHA}xxxxxxxxxxxxxxxxxxxxxxx

ACL in die Konfigurations-Datei /opt/etc/openldap/slapd.conf eintragen
Rich (BBCode):
access to attrs=userPassword
 by dn="cn=[your ldap admin username],dc=mydomain,dc=com" write
 by anonymous auth
 by self write
 by * none

access to dn.regex=".*,dc=mydomain,dc=com"
 by dn="cn=[your ldap admin username],dc=mydomain,dc=com" write
 by users read
 by anonymous auth

OpenLDAP-Server manuell starten
Rich (BBCode):
# /opt/etc/init.d/S58slapd
Hier hatte ich eine Fehlermeldung zu pidof erhalten und erst einmal manuell das Paket "psmisc" (siehe vorheriges Posting) installiert.
Danach liess sich der LDAP-Server problemfrei starten...

Pruefen, ob LDAP-server laeuft. Hier sollte mindestens eine Instanz zu sehen sein.
# ps auxwww | grep slapd

So, der LDAP-Server laeuft und ich bekomme nun von den Clients auch andere Fehlermeldungen.
Der Fehlermeldung nach, scheint es ein Problem zu geben, mit dem LDAP Explorer auf den LDAP-Server zuzugreifen. Ich habe auf der DS auch eine Portfreigabe fuer Port 389 eingerichtet, allerdings klappt es immer noch nicht.
Evtl. liegt das auch daran, dass ich noch keinen Nutzer im Addressbuch habe...
Wie bekomme ich die da rein...? LDIF scheint hier die Magie zu sein, allerdings habe ich nichts gefunden, wie man eine LDIF-Datei anlegt...
 
Zuletzt bearbeitet:

mismo

Benutzer
Mitglied seit
05. Sep 2008
Beiträge
27
Punkte für Reaktionen
0
Punkte
1
@NASsie

wg. der LDIF Datei und Erstellung von Adressen, schau dir mal das Apache Directory Studio an, damit sollte man sowas anlegen können:
klick

Noch eine Frage zur Installation:
Ich habe das genauso installiert und konfiguriert wie du, allerdings bekomme ich folgende Fehlermeldung:

Rich (BBCode):
ipkg -force-depends install openldap
Package openldap (2.3.43-2) installed in root is up to date.
Configuring openldap
Starting OpenLDAP
postinst script returned status 255
ERROR: openldap.postinst returned 255
Nothing to be done
Successfully terminated.

psmisc ist bereits installiert.

Hier meine slapd.conf

Rich (BBCode):
#
# See slapd.conf(5) for details on configuration options.
# This file should NOT be world readable.
#
include         /opt/etc/openldap/schema/core.schema
include         /opt/etc/openldap/schema/cosine.schema
include         /opt/etc/openldap/schema/inetorgperson.schema
include         /opt/etc/openldap/schema/misc.schema
include         /opt/etc/openldap/schema/openldap.schema

# Define global ACLs to disable default read access.

# Do not enable referrals until AFTER you have a working directory
# service AND an understanding of referrals.
#referral       ldap://root.openldap.org

pidfile         /opt/var/run/slapd.pid
argsfile        /opt/var/run/slapd.args

# Load dynamic backend modules:
# modulepath    /opt/libexec/openldap
# moduleload    back_bdb.la
# moduleload    back_ldap.la
# moduleload    back_ldbm.la
# moduleload    back_passwd.la
# moduleload    back_shell.la

# Sample security restrictions
#       Require integrity protection (prevent hijacking)
#       Require 112-bit (3DES or better) encryption for updates
#       Require 63-bit encryption for simple bind
# security ssf=1 update_ssf=112 simple_bind=64

# Sample access control policy:
#       Root DSE: allow anyone to read it
#       Subschema (sub)entry DSE: allow anyone to read it
#       Other DSEs:
#               Allow self write access
#               Allow authenticated users read access
#               Allow anonymous users to authenticate
#       Directives needed to implement policy:
# access to dn.base="" by * read
# access to dn.base="cn=Subschema" by * read
# access to *
#       by self write
#       by users read
#       by anonymous auth
#
# if no access controls are present, the default policy
# allows anyone and everyone to read anything but restricts
# updates to rootdn.  (e.g., "access to * by * read")
#
# rootdn can always read and write EVERYTHING!

 access to attrs=userPassword
 by dn="cn=ldapadmin,dc=meinedomain,dc=de" write
 by anonymous auth
 by self write
 by * none

access to dn.regex=".*,dc=meinedomain,dc=de"
 by dn="cn=ldapadmin,dc=meinedomain,dc=de" write
 by users read
 by anonymous auth


#######################################################################
# BDB database definitions
#######################################################################

database        bdb
suffix          "dc=meinedomain,dc=de"
rootdn          "cn=Manager,dc=meinedomain,dc=de"
# Cleartext passwords, especially for the rootdn, should
# be avoid.  See slappasswd(8) and slapd.conf(5) for details.
# Use of strong authentication encouraged.
#rootpw         secret

rootpw   {SSHA}<hash meines Passworts>

# The database directory MUST exist prior to running slapd AND
# should only be accessible by the slapd and slap tools.
# Mode 700 recommended.
directory       /opt/var/openldap-data
# Indices to maintain
index   objectClass     eq
 
Zuletzt bearbeitet:

NASsie

Benutzer
Mitglied seit
17. Jan 2009
Beiträge
150
Punkte für Reaktionen
0
Punkte
16
ich warte jetzt noch auf den finalen DSM 3.2. Der soll ja endlich einen LDAP-Server beinhalten. Mal sehen, ob der meine Anforderungen erfuellt... :)
 
Status
Für weitere Antworten geschlossen.
 

Kaffeautomat

Wenn du das Forum hilfreich findest oder uns unterstützen möchtest, dann gib uns doch einfach einen Kaffee aus.

Als Dankeschön schalten wir deinen Account werbefrei.

:coffee:

Hier gehts zum Kaffeeautomat