完整CentOS-Postfix邮件服务器建设 - 图文(3)

2019-03-28 23:10

hac_ker@126.com

问题:

install_driver(mysql) failed: Can't locate DBD/mysql.pm in @INC (@INC contains: /data/www/extsuite/extmail/libs /usr/lib64/perl5/site_perl/5.8.8/x86_64-linux-thread-multi /usr/lib/perl5/site_perl/5.8.8 /usr/lib/perl5/site_perl /usr/lib64/perl5/vendor_perl/5.8.8/x86_64-linux-thread-multi /usr/lib/perl5/vendor_perl/5.8.8 /usr/lib/perl5/vendor_perl /usr/lib64/perl5/5.8.8/x86_64-linux-thread-multi /usr/lib/perl5/5.8.8) at (eval 15) line 3. Perhaps the DBD::mysql perl module hasn't been fully installed, or perhaps the capitalisation of 'mysql' isn't right. Available drivers: DBM, ExampleP, File, Proxy, Sponge.

at /data/www/extsuite/extmail/libs/Ext/Auth/MySQL.pm line 45

解决:

yum install perl-DBD-MySQL

问题: DBI

connect('database=extmail;host=localhost;mysql_socket=/tmp/mysql.sock','extmail',...) failed:

Can't connect to local MySQL server through socket '/tmp/mysql.sock' (2) at /data/www/extsuite/extmail/libs/Ext/Auth/MySQL.pm line 45 解决:

数据库连接有问题

问题:

[root@CentOSX64 extmail]# /usr/sbin/authtest -s login postmaster@extmail.org extmail

Authentication FAILED: Input/output error [root@CentOSX64 extmail]#

查看日志信息:

Aug 8 14:26:09 CentOSX64 authdaemond: failed to connect to mysql server (server=localhost, userid=extmail): Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock' (2)

Aug 8 14:26:37 CentOSX64 postfix/trivial-rewrite[18169]: warning: connect to mysql server localhost: Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock' (2)

Aug 8 14:26:37 CentOSX64 postfix/trivial-rewrite[18169]: fatal: mysql:/etc/postfix/mysql_virtual_alias_maps.cf(0,lock|fold_fix): table lookup problem Aug 8 14:26:38 CentOSX64 postfix/smtpd[18060]: warning: problem talking to service rewrite: Success

hac_ker@126.com

Aug 8 14:26:38 CentOSX64 postfix/master[18054]: warning: process /usr/libexec/postfix/trivial-rewrite pid 18169 exit status 1

Aug 8 14:26:38 CentOSX64 postfix/master[18054]: warning: /usr/libexec/postfix/trivial-rewrite: bad command startup -- throttling

修改:

vim /etc/authlib/authmysqlrc

MYSQL_SOCKET /tmp/mysql.sock # echo \start\>> /etc/rc.d/rc.local

# echo \-v -d\>> /etc/rc.d/rc.local perl -e 'use MIME::Base64; print encode_base64(\

perl -e 'use MIME::Base64; print encode_base64(\

问题:

Connection closed by foreign host.

[root@CentOSX64 ~]# telnet localhost 25 Trying 127.0.0.1...

Connected to localhost.localdomain (127.0.0.1). Escape character is '^]'.

220 mail.extmail.org ESMTP Postfix - by extmail.org ehlo demo.domain.tld 250-mail.extmail.org 250-PIPELINING 250-SIZE 5242880 250-VRFY 250-ETRN

250-AUTH LOGIN PLAIN 250-AUTH=LOGIN PLAIN 250-ENHANCEDSTATUSCODES 250-8BITMIME 250 DSN auth login

334 VXNlcm5hbWU6

cG9zdG1hc3RlckBleHRtYWlsLm9yZw== 334 UGFzc3dvcmQ6 ZXh0bWFpbA==

535 5.7.8 Error: authentication failed: generic failure

hac_ker@126.com

日志信息:

Aug 8 15:02:45 CentOSX64 postfix/smtpd[19406]: warning: SASL authentication failure: cannot connect to saslauthd server: No such file or directory

Aug 8 15:02:45 CentOSX64 postfix/smtpd[19406]: warning: CentOSX64[127.0.0.1]: SASL login authentication failed: generic failure

解决:

/usr/lib/sasl2/smtpd.conf 配置问题 文件的权限问题 /var/spool/authdaemon 文件的权限问题 /etc/authlib/authdaemon 配置问题

关于很多日志报拒绝情况下,检查权限的问题,多数情况 是SELinux搞的鬼,将SELinux关闭,重新启动机器再看一切运行正常

问题:

[root@CentOSX64 yum.repos.d]# yum install courier-imap Loaded plugins: fastestmirror

Loading mirror speeds from cached hostfile Setting up Install Process Resolving Dependencies

--> Running transaction check

---> Package courier-imap.x86_64 0:4.6.0-1 set to be updated

--> Processing Dependency: courier-authlib-devel >= 0.60.6.20080629 for package: courier-imap

--> Processing Dependency: libcourierauthsasl.so()(64bit) for package: courier-imap

--> Processing Dependency: libcourierauth.so()(64bit) for package: courier-imap

--> Finished Dependency Resolution

courier-imap-4.6.0-1.x86_64 from EMOS-base has depsolving problems --> Missing Dependency: libcourierauth.so()(64bit) is needed by package courier-imap-4.6.0-1.x86_64 (EMOS-base)

courier-imap-4.6.0-1.x86_64 from EMOS-base has depsolving problems --> Missing Dependency: courier-authlib-devel >= 0.60.6.20080629 is needed by package courier-imap-4.6.0-1.x86_64 (EMOS-base)

courier-imap-4.6.0-1.x86_64 from EMOS-base has depsolving problems --> Missing Dependency: libcourierauthsasl.so()(64bit) is needed by package courier-imap-4.6.0-1.x86_64 (EMOS-base)

Error: Missing Dependency: libcourierauth.so()(64bit) is needed by package courier-imap-4.6.0-1.x86_64 (EMOS-base)

Error: Missing Dependency: libcourierauthsasl.so()(64bit) is needed by

hac_ker@126.com

package courier-imap-4.6.0-1.x86_64 (EMOS-base)

Error: Missing Dependency: courier-authlib-devel >= 0.60.6.20080629 is needed by package courier-imap-4.6.0-1.x86_64 (EMOS-base) You could try using --skip-broken to work around the problem You could try running: package-cleanup --problems package-cleanup --dupes

rpm -Va --nofiles --nodigest

The program package-cleanup is found in the yum-utils package. [root@CentOSX64 yum.repos.d]#

解决:

不在使用courier-imap rpm 安装,尔使用tar.gz 安装

[root@CentOSX64 yum.repos.d]# find / -name libcourierauthsasl.so /usr/lib64/courier-authlib/libcourierauthsasl.so

[root@CentOSX64 yum.repos.d]# find / -name courier-authlib-devel [root@CentOSX64 yum.repos.d]# find / -name libcourierauth.so /usr/lib64/courier-authlib/libcourierauth.so [root@CentOSX64 yum.repos.d]#

http://download.chinaunix.net/do ... eID=1789&site=1 yum –y install courier-authlib-devel tar -jxvf courier-imap-4.1.2.tar.bz2 cd courier-imap-4.1.2 ./configure --prefix=/usr/local/courier-imap --with-redhat --enable-unicode --disable-root-check \\ --with-trashquota --without-ipv6 CPPFLAGS='-I/usr/courier-authlib/include' \\

COURIERAUTHCONFIG='/usr/bin/courierauthconfig' \\ CPPFLAGS='-I/usr/courier-authlib/include' make

make install cp /usr/local/courier-imap/etc/imapd.dist /usr/local/courier-imap/etc/imapd cp /usr/local/courier-imap/etc/imapd-ssl.dist /usr/local/courier-imap/etc/imapd-ssl cp /usr/local/courier-imap/etc/pop3d.dist /usr/local/courier-imap/etc/pop3d cp /usr/local/courier-imap/etc/pop3d-ssl.dist /usr/local/courier-imap/etc/pop3d-ssl 配置Courier-IMAP,为用户提供pop3服务: vi /usr/local/courier-imap/etc/pop3d POP3DSTART=yes

注:如果你想为用户提供IMAP服务,可以在\文件中设置\。

hac_ker@126.com

设置courier-imap开机自动运行:

cp courier-imap.sysvinit /etc/rc.d/init.d/imapd chmod 755 /etc/rc.d/init.d/imapd chkconfig --add imapd service imapd start


完整CentOS-Postfix邮件服务器建设 - 图文(3).doc 将本文的Word文档下载到电脑 下载失败或者文档不完整,请联系客服人员解决!

下一篇:2018-2024年中国铜矿行业发展前景预测研究报告(目录) - 图文

相关阅读
本类排行
× 注册会员免费下载(下载后可以自由复制和排版)

马上注册会员

注:下载文档有可能“只有目录或者内容不全”等情况,请下载之前注意辨别,如果您已付费且无法下载或内容有问题,请联系我们协助你处理。
微信: QQ: