野村と申します。 清野様、メールありがとうございます。
/etc/nsswitch.confですが、当方の環境だと、nisマーカをつけてもどうもうま くいかず、 passwd: files ldap passwd_compat: nis このようにしたままにしております。これでid test3とすると反応してくれます (test3はldapで作ったアカウント)。/etc/pam.dあたりをいじってとにかくログ インできるようにしようとしておりますが、パスワード入力後 su: pam_ldap: ldap_initialize Bad parameter to an ldap routine と表示されて、ログインできない状態です。なにかアドバイスを頂ければ幸いで す。 追伸:返事が遅れてもうしわけありません。 On Mon, 06 Apr 2009 21:12:58 +0900 Hiroyuki Seino <[email protected]> wrote: > 清野と申します. > > /etc/nsswitch.conf ですが, > > > passwd: files > > passwd_compat: nis ldap > > とした場合,passwd ファイルを以下の様に修正する必要があります. > > www:*:80:80::0:0:World Wide Web Owner:/nonexistent:/usr/sbin/nologin > nobody:*:65534:65534::0:0:Unprivileged user:/nonexistent:/usr/sbin/nologin > +:*:::::::: > ldap:*:389:389::0:0:OpenLDAP Server:/nonexistent:/sbin/nologin > > こういった挙動から,_compat 付きは,今まで NIS を使った時のような > 感じで運用する物だと個人的には思っています. > # man にも近いような事が書かれていたので,大きく外していないと > # 思います. > > と言う事で,LDAP 参照に行っていないから id で引けないだけかと > 思います. > > > nss_ldap の Couldn't search LDAP [server name] is unavailable ですが, > 自分も解決したいと思って友人に色々調べてもらっていたのですが, > nss_ldap というより libldap が返しているようです. > > とはいえ,nss_ldap が絡む部分以外にこのメッセージが出る事も無いので, > nss_ldap の挙動が怪しいのでは? と思うのですが… > > nss_ldap.conf に nss_connecy_policy oneshot を入れる事で軽減は出来た > のですが,完全に潰せてはいない状態です. > > > メッセージは出ても実害は出ていないので無視する事にしているのですが, > この辺りの解決が出来ている方がいらっしゃったら,助けて頂ければ… > と,便乗したいと思います. > > > On Mon, 06 Apr 2009 15:59:30 +0900 > 野村 <[email protected]> wrote: > > > 野村と申します。 > > > > 「nss_ldap Couldn't search LDAP server.Server is unavailable」 > > というメッセージは/etcのnsswitch.confにldapのエントリを追加して > > からでるようになったようです。 > > > > # > > # nsswitch.conf(5) - name service switch configuration file > > # $FreeBSD: src/etc/nsswitch.conf,v 1.1 2006/05/03 15:14:47 ume Exp $ > > # > > group: files ldap > > group_compat: nis > > hosts: files dns ldap > > networks: files > > passwd: files ldap > > passwd_compat: nis > > shells: files > > services: compat > > services_compat: nis > > protocols: files > > rpc: files > > > > 上記の > > passwd: files ldap > > passwd_compat: nis > > を > > passwd: files > > passwd_compat: nis ldap > > とするとnss-ldapのメッセージはでなくなりますが、今度は"id test3" > > 等として、ldapで追加したユーザをテストした時に"id: test3: no such > > user"といわれてしまいます。 > > > > また、test3ユーザでログインしようとした時に、パスワードの入力をして > > も受け付けてくれません。ユーザはphpldapadminで作っているのですが、 > > 何が悪いのでしょうか? > > > > よろしくお願いします。 > > > > On Mon, 06 Apr 2009 14:19:51 +0900 > > 野村 <[email protected]> wrote: > > > > > 返信ありがとうございます。 > > > > > > それぞれ下記のようになっております。 > > > > > > ###nss-ldap.conf### > > > host hagi.hoge > > > base dc=hoge > > > uri ldap://hagi.hoge/ > > > port 389 > > > bind_policy soft > > > nss_connect_policy oneshot > > > > > > ###ldap.conf### > > > BASE dc=hoge > > > URI ldap://hagi.hoge 389 > > > > > > SIZELIMIT 12 > > > TIMELIMIT 15 > > > DEREF never > > > > > > ###slapd.conf > > > include /usr/local/etc/openldap/schema/core.schema > > > include /usr/local/etc/openldap/schema/corba.schema > > > include /usr/local/etc/openldap/schema/cosine.schema > > > include /usr/local/etc/openldap/schema/inetorgperson.schema > > > include /usr/local/etc/openldap/schema/nis.schema > > > include /usr/local/etc/openldap/schema/openldap.schema > > > > > > pidfile /var/run/openldap/slapd.pid > > > argsfile /var/run/openldap/slapd.args > > > > > > modulepath /usr/local/libexec/openldap > > > moduleload back_bdb > > > > > > access to attrs=userPassword > > > by self write > > > by users read > > > by anonymous auth > > > > > > access to * > > > by self write > > > by users read > > > by anonymous read > > > > > > database bdb > > > suffix "dc=hoge" > > > rootdn "cn=ldaproot,dc=hoge" > > > rootpw {SSHA}password > > > > > > directory /var/db/openldap-data > > > > > > index objectClass eq > > > > > > 返事がおくれてすいません。よろしくお願いします。 > > > > > > On Fri, 3 Apr 2009 22:53:21 +0900 > > > Kouichiro Iwao <[email protected]> wrote: > > > > > > > 岩男です。 > > > > > > > > On Fri, Apr 03, 2009 at 05:23:44PM +0900, 野村 wrote: > > > > > 野村と申します。 > > > > > > > > > > ldapを導入しようとしてるのですが、slapd を起動する時に「nss_ldap > > > > > Couldn't search LDAP server.Server is unavailable」と出てしまい、困って > > > > > おります。 > > > > > > > > ひとまず、 > > > > /usr/local/etc/{nss_ldap.conf,ldap.conf,} > > > > /usr/local/etc/openldap/slapd.conf > > > > > > > > の設定内容を明かしてください。 > > > __________ NOD32 4003 (20090412) 情報 __________ > > このメールはNOD32によって検査済みです。 > http://canon-sol.jp > --------------------------------------------------------------------- gpg public key https://hagi.ir-alt.co.jp/home/nomura/public-nomura.asc 野村 <[email protected]> ---------------------------------------------------------------------
