Solaris10:dovecot-1.1.11導入
提供:KinusatiWiki
目次 |
dovecot + LDAP
dovecot + ldapでシステムを構成する。 メールスプール形式はMaildirとし、NFS対応とする。
必要ソフトウェアは以下。
- dovecot
- openldap
ユーザ・グループ追加
# groupadd -g 143 dovecot # useradd -g dovecot -u 143 -d /dev/null -s /bin/false dovecot
コンパイル
# wget http://www.dovecot.org/releases/1.1/dovecot-1.1.11.tar.gz # gzip -dc dovecot-1.1.11.tar.gz | tar xvfp - # CPPFLAGS="-I/usr/local/include" LDFLAGS="-R/usr/local/lib -L/usr/local/lib" \ ./configure \ --prefix=/usr/local \ --mandir=/usr/local/man \ --infodir=/usr/local/info \ --enable-header-install \ --without-shadow \ --disable-ipv6 \ --without-gssapi \ --without-vpopmail \ --with-ldap \ --without-pgsql \ --without-mysql # gmake # gmake install
初期設定
1. ファイルディスクリプタの増加
# vi /etc/system set rlim_fd_cur = 4096 reboot
2. dovecot.confの編集
# vi /usr/local/etc/dovecot.conf protocols = imap pop3 disable_plaintext_auth = no mail_location = maildir:~/Maildir postmaster_address = postmaster@<ドメイン名> ssl_disable = yes
以下はNFS対応に必要
mmap_disable = yes mail_nfs_storage = yes mail_nfs_index = yes lock_method = fcntl
以下はコメントアウト
#passdb pam {
...中略
#}
#userdb passwd {
...中略
#}
以下はLDAP対応に必要
passdb ldap {
# Path for LDAP configuration file, see doc/dovecot-ldap-example.conf
args = /usr/local/etc/dovecot-ldap.conf
}
userdb ldap {
# Path for LDAP configuration file, see doc/dovecot-ldap-example.conf
args = /usr/local/etc/dovecot-ldap.conf
}
3. dovecot-ldap.confの編集
# vi /usr/local/etc/dovecot.conf hosts = 192.168.0.1 dn = cn=Manager,dc=my-domain,dc=com dnpass = <パスワード> ldap_version = 3 user_attrs = homeDirectory=home,uidNumber=uid,gidNumber=gid user_filter = (&(objectClass=posixAccount)(uid=%u)) pass_attrs = uid=user,userPassword=password pass_filter = (&(objectClass=posixAccount)(uid=%u)) default_pass_scheme = PLAIN
自動起動
後日後述