Marco: LDAP unter XAMPP installieren

Hallo zusammen

Habe eine kleine Frage und zwar läuft bei mir XAMP. Nun möchte ich gerne das ich LDAP nutzen kann um das AD abzufragen. Leider weiss ich nicht wie, ich die LDAP unterstüzung aktivieren kann.

Habe in der php.ini folgendes aktiviert:
extension=php_ldap.dll

Leider funktioniert es immer noch nicht.
Kann mir jemand helfen, was ich machen muss?

Danke für Eure Hilfe!

Marco

  1. hallo,

    Habe in der php.ini folgendes aktiviert:
    extension=php_ldap.dll
    Leider funktioniert es immer noch nicht.

    Kann es auch nicht sofort, weil du vermutlich im PHP-Handbuch die Aussage überlesen hast: "LDAP Unterstützung ist in PHP im Standard nicht aktiviert." Lies da mal noch ein Stückchen weiter.

    Grüße aus Berlin

    Christoph S.

    --
    Visitenkarte
    ss:| zu:) ls:& fo:) va:) sh:| rl:|
    1. Hallo Christoph

      Danke für Dein Feedback. Ich habe es durchgelesen d.h. habe diese Seite auch schon vorgängig gelesen. Auch die zwei Dateien libeay32.dll und ssleay.dll habe ich in das SYSTEM Verzeichnis kopiert.

      Was ich aber nicht verstehe ist dieser Abschnitt:

      ---------------
      LDAP Unterstützung ist in PHP im Standard nicht aktiviert. Sie müssen die Konfigurationsoption --with-ldap[=DIR] beim Übersetzen von PHP angeben. DIR bezeichnet das Installationsverzeichnis von LDAP.
      ---------------

      Was genau ist gemeint mit Übersetzen d.h. was genau muss ich da machen?

      Marco

      1. hallo,

        Was ich aber nicht verstehe ist dieser Abschnitt:
        LDAP Unterstützung ist in PHP im Standard nicht aktiviert. Sie müssen die Konfigurationsoption --with-ldap[=DIR] beim Übersetzen von PHP angeben
        Was genau ist gemeint mit Übersetzen d.h. was genau muss ich da machen?

        Du mußt da gar nichts machen. Diese Hinweise beziehen sich auf den Standard, daß nämlich PHP auf einem unix-basierten System (Linux, *BSD) kompiliert ("übersetzt") wird. Für Windows (das du ja benutzt) gibt es den entsprechenden "Hinweis für Win32 Benutzer".

        Grüße aus Berlin

        Christoph S.

        --
        Visitenkarte
        ss:| zu:) ls:& fo:) va:) sh:| rl:|
        1. Hallo Christoph

          Danke für Dein Feedback. Aber dann sollte es ja gehen mit dem LDAP aber leider funktioniert es nicht!

          Marco

          1. hallo,

            aber leider funktioniert es nicht!

            Dazu bitte die Fragen von Christian Seiler beantworten - ohne etwas genauere Informationen von dir kommen wir dann nicht weiter.
            Und dann gibt es nochwas: es gibt einige hier im Forum, die sowohl vom Apache wie auch von der Art, wie PHP funktioniert, ziemlich viel verstehen - in der Regel aber werden diese Programme einzeln installiert. Ich habe zum Beispiel zwar Apache, PHP und noch etliches mehr, aber ich habe kein XAMPP.

            Grüße aus Berlin

            Christoph S.

            --
            Visitenkarte
            ss:| zu:) ls:& fo:) va:) sh:| rl:|
            1. Hallo Christoph

              Habe die Antwort oben beanwortet.
              Evt. hast Du noch eine Idee?

              Gruss Marco

  2. Hallo Marco,

    Habe in der php.ini folgendes aktiviert:
    extension=php_ldap.dll

    Leider funktioniert es immer noch nicht.

    Das heißt konkret? Was sagt php_info()? Ist die LDAP-Erweiterung geladen? Wenn diese geladen ist, was heißt "funktioniert nicht"? "Function not found"? Obskure Fehlermeldung? Absturz? etc.? Falls sie nicht geladen ist: Webserver auch neu gestartet nach der Änderung der php.ini? Richtige php.ini bearbeitet (bei XAMPP gibt's da soweit ich's hier im Forum mitgelesen habe teilweise mehrere)?

    Viele Grüße,
    Christian

    1. Tach.

      Leider funktioniert es immer noch nicht.

      Das heißt konkret? Was sagt php_info()?

      Daß es Unterstriche nicht mag und lieber phpinfo() genannt werden möchte. ;)

      --
      Once is a mistake, twice is jazz.
      1. hallo,

        Was sagt php_info()?
        Daß es Unterstriche nicht mag und lieber phpinfo() genannt werden möchte. ;)

        Öhm ... Christian hat sich vermutlich grade nicht ans Archiv erinnert ;-)

        Grüße aus Berlin

        Christoph S.

        --
        Visitenkarte
        ss:| zu:) ls:& fo:) va:) sh:| rl:|
    2. Hallo Christian

      Danke für Deine Antwort. Also im php_info() zeigt es mir nichts an, dass LDAP geladen ist. Der einzige Eintrag von LDAP ist dieser hier:

      util_ldap

      Der Webserver (Apache) habe ich neu gestartet nachdem ich in der PHP.INI die Änderung gemacht habe.

      Was kann ich noch tun? Es sollte doch sicher mehr angezeigt werden in der php_info().

      Marco

      1. Hallo Marco,

        Danke für Deine Antwort. Also im php_info() zeigt es mir nichts an, dass LDAP geladen ist. Der einzige Eintrag von LDAP ist dieser hier:

        util_ldap

        Das taucht aber in der Apache-Modul-Liste auf, das hat mit PHP wenig zu tun.

        Was kann ich noch tun? Es sollte doch sicher mehr angezeigt werden in der php_info().

        Ja, in der phpinfo() müsste ein eigener Abschnitt "ldap" kommen in dem dan drin steht sowas wie "LDAP Support" ist "enabled" usw. usf.

        Schau doch mal ins Error-Log vom Apachen, PHP erzeugt beim Starten eine Warnung, wenn das Laden irgend einer Erweiterung fehlschlägt. Vielleicht gibt Dir das Log über den Grund aufschluss, mal ein Beispiel aus meinem Log, indem ich eine Fehlermeldung provoziert habe (nichtexistierende Erweiterung angegeben):

        PHP Warning:  PHP Startup: Unable to load dynamic library '/usr/lib/php5/lib/php/extensions/no-debug-non-zts-20050922/php_bla.so' - /usr/lib/php5/lib/php/extensions/no-debug-non-zts-20050922/php_bla.so: cannot open shared object file: No such file or directory in Unknown on line 0

        Wenn *nichts* im Log auftaucht, hast Du die falsche php.ini bearbeitet, denn *irgend* eine Meldung *muss* PHP ausgeben, wenn das Laden fehlschlägt (und wenn's funktionieren würde, würdest Du die Erweiterung ja in phpinfo() sehen).

        Viele Grüße,
        Christian

        1. Hallo Christian

          Danke für die prompte Antwort. Ich habe unter Apache einen Ordner mit Logs und dort habe ich das error.log mit folgendem inhalt:

          **************************************************

          [Fri Apr 27 14:25:05 2007] [crit] (22)Invalid argument: unable to replace stderr with error_log
          [Fri Apr 27 14:25:05 2007] [crit] (2)No such file or directory: unable to replace stderr with /dev/null
          [Fri Apr 27 14:25:05 2007] [crit] (22)Invalid argument: unable to replace stderr with error_log
          [Fri Apr 27 14:25:05 2007] [crit] (2)No such file or directory: unable to replace stderr with /dev/null
          [Fri Apr 27 14:25:09 2007] [notice] Apache/2.2.4 (Win32) DAV/2 mod_ssl/2.2.4 OpenSSL/0.9.8e mod_autoindex_color PHP/5.2.1 configured -- resuming normal operations
          [Fri Apr 27 14:25:09 2007] [notice] Server built: Mar  5 2007 11:23:00
          [Fri Apr 27 14:25:09 2007] [notice] Parent: Created child process 3280
          [Fri Apr 27 14:25:10 2007] [notice] Child 3280: Child process is running
          [Fri Apr 27 14:25:10 2007] [notice] Child 3280: Acquired the start mutex.
          [Fri Apr 27 14:25:10 2007] [notice] Child 3280: Starting 250 worker threads.
          [Fri Apr 27 14:25:10 2007] [notice] Child 3280: Starting thread to listen on port 443.
          [Fri Apr 27 14:25:10 2007] [notice] Child 3280: Starting thread to listen on port 80.
          [Fri Apr 27 14:29:28 2007] [error] [client 127.0.0.1] File does not exist: C:/Programme/xampp/htdocs/Galexis-Page/u0gem
          [Fri Apr 27 14:47:10 2007] [crit] (22)Invalid argument: unable to replace stderr with error_log
          [Fri Apr 27 14:47:10 2007] [crit] (2)No such file or directory: unable to replace stderr with /dev/null
          [Fri Apr 27 14:47:11 2007] [crit] (22)Invalid argument: unable to replace stderr with error_log
          [Fri Apr 27 14:47:11 2007] [crit] (2)No such file or directory: unable to replace stderr with /dev/null
          [Fri Apr 27 14:47:11 2007] [notice] Apache/2.2.4 (Win32) DAV/2 mod_ssl/2.2.4 OpenSSL/0.9.8e mod_autoindex_color PHP/5.2.1 configured -- resuming normal operations
          [Fri Apr 27 14:47:11 2007] [notice] Server built: Mar  5 2007 11:23:00
          [Fri Apr 27 14:47:11 2007] [notice] Parent: Created child process 2736
          [Fri Apr 27 14:47:13 2007] [notice] Child 2736: Child process is running
          [Fri Apr 27 14:47:13 2007] [notice] Child 2736: Acquired the start mutex.
          [Fri Apr 27 14:47:13 2007] [notice] Child 2736: Starting 250 worker threads.
          [Fri Apr 27 14:47:13 2007] [notice] Child 2736: Starting thread to listen on port 443.
          [Fri Apr 27 14:47:13 2007] [notice] Child 2736: Starting thread to listen on port 80.
          [Fri Apr 27 14:57:45 2007] [crit] (22)Invalid argument: unable to replace stderr with error_log
          [Fri Apr 27 14:57:45 2007] [crit] (2)No such file or directory: unable to replace stderr with /dev/null
          [Fri Apr 27 14:57:45 2007] [crit] (22)Invalid argument: unable to replace stderr with error_log
          [Fri Apr 27 14:57:45 2007] [crit] (2)No such file or directory: unable to replace stderr with /dev/null
          [Fri Apr 27 14:57:46 2007] [notice] Apache/2.2.4 (Win32) DAV/2 mod_ssl/2.2.4 OpenSSL/0.9.8e mod_autoindex_color PHP/5.2.1 configured -- resuming normal operations
          [Fri Apr 27 14:57:46 2007] [notice] Server built: Mar  5 2007 11:23:00
          [Fri Apr 27 14:57:46 2007] [notice] Parent: Created child process 2072
          [Fri Apr 27 14:57:48 2007] [notice] Child 2072: Child process is running
          [Fri Apr 27 14:57:48 2007] [notice] Child 2072: Acquired the start mutex.
          [Fri Apr 27 14:57:48 2007] [notice] Child 2072: Starting 250 worker threads.
          [Fri Apr 27 14:57:48 2007] [notice] Child 2072: Starting thread to listen on port 443.
          [Fri Apr 27 14:57:48 2007] [notice] Child 2072: Starting thread to listen on port 80.
          [Fri Apr 27 14:59:56 2007] [crit] (22)Invalid argument: unable to replace stderr with error_log
          [Fri Apr 27 14:59:56 2007] [crit] (2)No such file or directory: unable to replace stderr with /dev/null
          [Fri Apr 27 14:59:57 2007] [crit] (22)Invalid argument: unable to replace stderr with error_log
          [Fri Apr 27 14:59:57 2007] [crit] (2)No such file or directory: unable to replace stderr with /dev/null
          [Fri Apr 27 14:59:57 2007] [notice] Apache/2.2.4 (Win32) DAV/2 mod_ssl/2.2.4 OpenSSL/0.9.8e mod_autoindex_color PHP/5.2.1 configured -- resuming normal operations
          [Fri Apr 27 14:59:57 2007] [notice] Server built: Mar  5 2007 11:23:00
          [Fri Apr 27 14:59:57 2007] [notice] Parent: Created child process 2560
          [Fri Apr 27 14:59:59 2007] [notice] Child 2560: Child process is running
          [Fri Apr 27 14:59:59 2007] [notice] Child 2560: Acquired the start mutex.
          [Fri Apr 27 14:59:59 2007] [notice] Child 2560: Starting 250 worker threads.
          [Fri Apr 27 14:59:59 2007] [notice] Child 2560: Starting thread to listen on port 443.
          [Fri Apr 27 14:59:59 2007] [notice] Child 2560: Starting thread to listen on port 80.
          [Fri Apr 27 15:04:09 2007] [crit] (22)Invalid argument: unable to replace stderr with error_log
          [Fri Apr 27 15:04:09 2007] [crit] (2)No such file or directory: unable to replace stderr with /dev/null
          [Fri Apr 27 15:04:10 2007] [crit] (22)Invalid argument: unable to replace stderr with error_log
          [Fri Apr 27 15:04:10 2007] [crit] (2)No such file or directory: unable to replace stderr with /dev/null
          [Fri Apr 27 15:04:11 2007] [notice] Apache/2.2.4 (Win32) DAV/2 mod_ssl/2.2.4 OpenSSL/0.9.8e mod_autoindex_color PHP/5.2.1 configured -- resuming normal operations
          [Fri Apr 27 15:04:11 2007] [notice] Server built: Mar  5 2007 11:23:00
          [Fri Apr 27 15:04:11 2007] [notice] Parent: Created child process 3088

          usw.

          **************************************************

          Sieht aber nicht so aus, dass was nicht gestartet werden kann.
          Habe die richtige php.ini bearbeitet.

          Gruss Marco

        2. Hallo Christian

          Jupiiiii habe einmal alle php.ini auf dem System gesucht und bei allen LDAP aktiviert. Jetzt gehts. Habe wohl tatsächlich die falsche berbeitet. Komisch war die im PHP Ordner, welche es jedoch nicht war.

          Naja jetzt gehts. mal schauen welche PHP.INI es wirklich war wo da der Apache zurückgreift.

          Vielen Dank für den Tipp. Genial nun gehts! Jupiii

          Danke an alle für die Hilfe!

          Marco