原chinaunix.net论坛上的经典开源邮件系统架设和联调帖子

您的第一个版面的简单描述
回复
admin
网站管理员
帖子: 11
注册时间: 2025年 10月 2日 03:38

原chinaunix.net论坛上的经典开源邮件系统架设和联调帖子

帖子 admin »

代码: 全选

这是bbs.chinaunix.net最经典的一篇使用开源软件模块搭建一套完整的反垃圾防病毒邮件系统方法。由于chinaunix.net已经被美国黑客彻底破
坏,以前存留下来经典帖子和知识库全部被美国黑客删除掉了。这是几年前我从chinaunix.net备份下来的资料。虽然现在某些配置有所出入,但是对
于初学者来说,学习这篇帖子可以提升自己的动手能力——邮件系统涉及到数据库,域名服务,WEB服务,以及各个组件如何整合在一起。各个功能
模块如何进行联调和通过日志分析排查故障和异常等知识。有问题和想法欢迎大家进行交流。
ChinaUnix首页 > 精华文章 > Mail服务器 > 正文

[精华] RHEL4上安装基于postfix的全功能邮件服务器(全部使用目前最新源码包构建)
http://www.chinaunix.net 作者:marion 发表于:2008-08-06 12:27:24
【发表评论】【查看原文】【Mail服务器讨论区】【关闭】

本文凝聚了作者不少的安装经验,写出来供各位同仁参考指正,也为自己留一个“备份”,以便以后安装时作为参照!
安装过程中借鉴了不少google出来的文章,是你们先行的足迹为作者今天的成功打下了基础,在此先行谢过!
转载请注明出处:http://marion.cublog.cn

所用软件包:(本文中,以下软件包都将在/usr/local/src中存放)

Postfix-2.4.5
Mysql-5.0.45
Sasl-2.1.22
DB-4.5.20
Openssl-0.98e
httpd-2.2.4
Php-5.2.3
courier-authlib-0.59.3
courier-imap-4.1.3
Extmail-1.0.2
Extman-0.2.2
maildrop-2.0.4
clamav-0.91.2
amavisd-new
SpamAssassin-3.2.3

系统逻辑结构图如下:
开源邮件系统技术架构.jpg
开源邮件系统技术架构.jpg (62.75 KiB) 查看 876 次

前提:开始前请确保您已经配置好指向此邮件服务器MX记录及其它DNS设置;本示例中的域名为benet.org,邮件服务器FQDN为mail.benet.org,IP地址为192.168.1.6;同时,如果您的服务器事先已经安装了sendmail,请卸载之;

一、安装mysql-5.0.45

#groupadd mysql
#useradd -g mysql -s /bin/false -M mysql
#tar zxvf mysql-5.0.45.tar.gz
#cd mysql-5.0.45

#./configure
--prefix=/usr/local/mysql
--enable-thread-safe-client
--enable-local-infile
--with-charset=gbk
--with-extra-charset=all
--with-low-memory
#make
#make install
#cp support-files/my-medium.cnf /etc/my.cnf
#cd /usr/local/mysql
#chown -R mysql .
#chgrp -R mysql .
#bin/mysql_install_db --user=mysql
#chown -R root .
#chown -R mysql var
#bin/mysqld_safe --user=mysql &

#cd /usr/local/src/mysql-5.0.45 (这里的目录指的是原压缩包解压后的目录)
#cp support-files/mysql.server /etc/rc.d/init.d/mysqld
#chmod 700 /etc/rc.d/init.d/mysqld
加入自动启动服务队列:
#chkconfig --add mysqld
#chkconfig --level 345 mysqld on

测试
#/usr/local/mysql/bin/mysqladmin ping
#/usr/local/mysql/bin/mysqladmin version
#/usr/local/mysql/bin/mysql

添加root密码
#/usr/local/mysql/bin/mysqladmin -uroot -p 旧密码 password 新密码
说明:此时mysql的root用户的密码为空

配置库文件搜索路径
# echo "/usr/local/mysql/lib/mysql" >> /etc/ld.so.conf
# ldconfig -v

添加/usr/local/mysql/bin到环境变量PATH中
#export PATH=$PATH:/usr/local/mysql/bin


二、安装openssl-0.9.8e

# tar zxvf openssl-0.9.8e.tar.gz
# cd openssl-0.9.8e
# ./config shared zlib
# make
# make test
# make install
# mv /usr/bin/openssl /usr/bin/openssl.OFF
# mv /usr/include/openssl /usr/include/openssl.OFF
# rm /usr/lib/libssl.so
# ln -s /usr/local/ssl/bin/openssl /usr/bin/openssl
# ln -s /usr/local/ssl/include/openssl /usr/include/openssl
# ln -sv /usr/local/ssl/lib/libssl.so.0.9.8 /usr/lib/libssl.so

配置库文件搜索路径
# echo "/usr/local/ssl/lib" >> /etc/ld.so.conf
# ldconfig -v

检测安装结果
# openssl version
OpenSSL 0.9.8e 23 Feb 2007


三、安装sasl-2.1.22

#tar zxvf cyrus-sasl-2.1.22.tar.gz
#cd cyrus-sasl-2.1.22
#./configure --prefix=/usr/local/sasl2 (注意使用续行符)
--disable-gssapi
--disable-anon
--disable-sample
--disable-digest
--enable-plain
--enable-login
--enable-sql
--with-mysql=/usr/local/mysql
--with-mysql-includes=/usr/local/mysql/include/mysql --with-mysql-libs=/usr/local/mysql/lib/mysql --with-authdaemond=/usr/local/courier-authlib/var/spool/authdaemon/socket
#make
#make install

关闭原有的sasl:
# mv /usr/lib/libsasl2.a /usr/lib/libsasl2.a.OFF
# mv /usr/lib/libsasl2.la /usr/lib/libsasl2.la.OFF
# mv /usr/lib/libsasl2.so.2.0.19 /usr/lib/libsasl2.so.2.0.19.OFF
# mv /usr/lib/sasl2 /usr/lib/sasl2.OFF
# rm /usr/lib/libsasl2.so
# rm /usr/lib/libsasl2.so.2

# ln -sv /usr/local/sasl2/lib/* /usr/lib

postfix 2.3以后的版本会分别在/usr/local/lib和/usr/local/include中搜索sasl库文件及头文件,故还须将其链接至此目录中:
# ln -sv /usr/local/sasl2/lib/* /usr/local/lib
# ln -sv /usr/local/sasl2/include/sasl/* /usr/local/include

创建运行时需要的目录并调试启动
# mkdir -pv /var/state/saslauthd
# /usr/local/sasl2/sbin/saslauthd -a shadow pam -d

启动并测试
# /usr/local/sasl2/sbin/saslauthd -a shadow pam
# /usr/local/sasl2/sbin/testsaslauthd -u root -p root用户密码

配置库文件搜索路径
# echo "/usr/local/sasl2/lib" >> /etc/ld.so.conf
# echo "/usr/local/sasl2/lib/sasl2" >> /etc/ld.so.conf
# ldconfig -v

开机自动启动
# echo "/usr/local/sasl2/sbin/saslauthd -a shadow pam">>/etc/rc.local


四、安装BerkeleyDB

#tar zxvf db-4.5.20.tar.gz
#cd db-4.5.20/build_unix
#../dist/configure --prefix=/usr/local/BerkeleyDB
#make
#make install

修改相应的头文件指向
# mv /usr/include/db4 /usr/inculde/db4.OFF
# rm /usr/include/db_cxx.h
# rm /usr/include/db.h
# rm /usr/include/db_185.h
# ln -sv /usr/local/BerkeleyDB/include /usr/include/db4
# ln -sv /usr/local/BerkeleyDB/include/db.h /usr/include/db.h
# ln -sv /usr/local/BerkeleyDB/include/db_cxx.h /usr/include/db_cxx.h

配置库文件搜索路径
# echo "/usr/local/BerkeleyDB/lib" >> /etc/ld.so.conf
# ldconfig –v

五、安装httpd-2.2.4

#tar jxvf httpd-2.2.4.tar.bz2
#cd httpd-2.2.4
#./configure
--prefix=/usr/local/apache
--sysconfdir=/etc/httpd
--enable-so
--enable-ssl
--with-ssl=/usr/local/ssl
--enable-track-vars
--enable-rewrite
--with-zlib
--enable-mods-shared=most
--enable-suexec (后面extmail切换”运行时用户”时要用到)
--with-suexec-caller=daemon
#make
#make install

#echo "/usr/local/apache/bin/apachectl start" >> /etc/rc.local(系统启动时服务自动启动)

六、安装php-5.2.3

# tar -zvxf php-5.2.3.tar.gz
# mkdir -p /usr/local/php
# cd php-5.2.3
# ./configure --prefix=/usr/local/php
--with-apxs2=/usr/local/apache/bin/apxs
--with-mysql=/usr/local/mysql
--with-mysqli=/usr/local/mysql/bin/mysql_config
--with-xml
--with-png
--with-jpeg
--with-zlib
--with-freetype
--with-gd
--enable-track-vars
--enable-mbstring=all
# make
# make install
# cp php.ini-dist /usr/local/php/lib/php.ini

注:编辑apache配置文件httpd.conf,以apache支持php
# vi /etc/httpd/httpd.conf
1、添加如下二行
AddType application/x-httpd-php .php
AddType application/x-httpd-php-source .phps

2、定位至DirectoryIndex index.html
修改为:
DirectoryIndex index.php index.html

3、按照使用习惯,这里将网站根目录指定到/var/www:
找到DocumentRoot “/usr/local/apache/htdocs”
修改为:DocumentRoot “/var/www”(后文中我们还会注释掉此行,以启用虚拟主机)

找到<Directory “/usr/local/apache/htdocs”>
修改为:<Directory “/var/www”>

说明:这个对本文来说并非是不可少的。

七、安装Postfix-2.4.5

1.安装
#groupadd -g 2525 postfix
#useradd -g postfix -u 2525 -s /sbin/nologin -M postfix
#groupadd -g 2526 postdrop
#useradd -g postdrop -u 2526 -s /bin/false -M postdrop

#tar zxvf postfix-2.4.5.tar.gz
#cd postfix-2.4.5
#make makefiles 'CCARGS=-DHAS_MYSQL -I/usr/local/mysql/include/mysql -DUSE_SASL_AUTH -DUSE_CYRUS_SASL -I/usr/local/sasl2/include/sasl -I/usr/local/BerkeleyDB/include -DUSE_TLS -I/usr/local/ssl/include/openssl ' 'AUXLIBS=-L/usr/local/mysql/lib/mysql -lmysqlclient -lz -lm -L/usr/local/sasl2/lib -lsasl2 -L/usr/local/BerkeleyDB/lib -L/usr/local/ssl/lib -lssl -lcrypto'
#make
#make install

按照以下的提示输入相关的路径([]号中的是缺省值,”]”后的是输入值)

  install_root: [/] /
  tempdir: [/usr/local/src/ postfix-2.4.5] /tmp
  config_directory: [/etc/postfix] /etc/postfix
  daemon_directory: [/usr/libexec/postfix] /usr/local/postfix/libexec
  command_directory: [/usr/sbin] /usr/local/postfix/sbin
  queue_directory: [/var/spool/postfix]
  sendmail_path: [/usr/sbin/sendmail]
  newaliases_path: [/usr/bin/newaliases]
  mailq_path: [/usr/bin/mailq]
  mail_owner: [postfix]
  setgid_group: [postdrop]
html_directory: [no] /var/www/postfix_html
manpages: [/usr/local/man] /usr/local/postfix/man
readme_directory: [no]

说明:这里的postfix将安装在独立的目录/usr/local/postfix中,目的是为了方便管理;您亦可以采用默认安装的方式,可能这样使用起来会更为方便些;

生成别名二进制文件,这个步骤如果忽略,会造成postfix效率极低:
# newaliases

2.进行一些基本配置,测试启动postfix并进行发信
#vi /etc/postfix/main.cf
修改以下几项为您需要的配置
myhostname = mail.benet.org
myorigin = benet.org
mydomain = benet.org
mydestination = $myhostname, localhost.$mydomain, localhost, $mydomain
mynetworks = 192.168.1.0/24, 127.0.0.0/8

说明:
myorigin参数用来指明发件人所在的域名;
mydestination参数指定postfix接收邮件时收件人的域名,即您的postfix系统要接收到哪个域名的邮件;
myhostname 参数指定运行postfix邮件系统的主机的主机名,默认情况下,其值被设定为本地机器名;
mydomain参数指定您的域名,默认情况下,postfix将myhostname的第一部分删除而作为mydomain的值;
mynetworks 参数指定你所在的网络的网络地址,postfix系统根据其值来区别用户是远程的还是本地的,如果是本地网络用户则允许其访问;
inet_interfaces 参数指定postfix系统监听的网络接口;

注意:
1、在postfix的配置文件中,参数行和注释行是不能处在同一行中的;
2、任何一个参数的值都不需要加引号,否则,引号将会被当作参数值的一部分来使用;
3、每修改参数及其值后执行 postfix reload 即可令其生效;但若修改了inet_interfaces,则需重新启动postfix;
4、如果一个参数的值有多个,可以将它们放在不同的行中,只需要在其后的每个行前多置一个空格即可;postfix会把第一个字符为空格或tab的文本行视为上一行的延续;

启动postfix
/usr/local/postfix/sbin/postfix start

连接postfix,验正服务启动状况:
# telnet localhost 25
Trying 127.0.0.1...
Connected to localhost.localdomain (127.0.0.1).
Escape character is '^]'.
220 mail.benet.org ESMTP Postfix
ehlo mail.benet.org
250-mail.benet.org
250-PIPELINING
250-SIZE 10240000
250-VRFY
250-ETRN
250-ENHANCEDSTATUSCODES
250-8BITMIME
250 DSN
mail from:root@benet.org
250 2.1.0 Ok
rcpt to:redhat@benet.org
250 2.1.5 Ok
data
354 End data with <CR><LF>.<CR><LF>
subject:Mail test!
Mail test!!!
.
250 2.0.0 Ok: queued as AB94A1A561
quit
221 2.0.0 Bye
Connection closed by foreign host.

切换到redhat用户进行收信:
# su - redhat
$ mail
Mail version 8.1 6/6/93. Type ? for help.
"/var/spool/mail/redhat": 1 message 1 new
>N 1 root@benet.org Wed Sep 5 10:59 15/488 "Mail test!"
&

八、为postfix开启基于cyrus-sasl的认证功能

使用以下命令验正postfix是否支持cyrus风格的sasl认证,如果您的输出为以下结果,则是支持的:
# /usr/local/postfix/sbin/postconf -a
cyrus
dovecot

#vi /etc/postfix/main.cf
添加以下内容:
############################CYRUS-SASL############################
broken_sasl_auth_clients = yes
smtpd_recipient_restrictions=permit_mynetworks,permit_sasl_authenticated,reject_invalid_hostname,reject_non_fqdn_hostname,reject_unknown_sender_domain,reject_non_fqdn_sender,reject_non_fqdn_recipient,reject_unknown_recipient_domain,reject_unauth_pipelining,reject_unauth_destination
smtpd_sasl_auth_enable = yes
smtpd_sasl_local_domain = $myhostname
smtpd_sasl_security_options = noanonymous
smtpd_sasl_application_name = smtpd
smtpd_banner = Welcome to our $myhostname ESMTP,Warning: Version not Available!

#vi /usr/local/lib/sasl2/smtpd.conf
添加如下内容:
pwcheck_method: saslauthd
mech_list: PLAIN LOGIN

让postfix重新加载配置文件
#/usr/local/postfix/sbin/postfix reload

# telnet localhost 25
Trying 127.0.0.1...
Connected to localhost.localdomain (127.0.0.1).
Escape character is '^]'.
220 Welcome to our mail.benet.org ESMTP,Warning: Version not Available!
ehlo mail.benet.org
250-mail.benet.org
250-PIPELINING
250-SIZE 10240000
250-VRFY
250-ETRN
250-AUTH PLAIN LOGIN
250-AUTH=PLAIN LOGIN (请确保您的输出以类似两行)
250-ENHANCEDSTATUSCODES
250-8BITMIME
250 DSN


九、让postfix支持虚拟域和虚拟用户

1、编辑/etc/postfix/main.cf,添加如下内容:
########################Virtual Mailbox Settings########################
virtual_mailbox_base = /var/mailbox
virtual_mailbox_maps = mysql:/etc/postfix/mysql_virtual_mailbox_maps.cf
virtual_mailbox_domains = mysql:/etc/postfix/mysql_virtual_domains_maps.cf
virtual_alias_domains =
virtual_alias_maps = mysql:/etc/postfix/mysql_virtual_alias_maps.cf
virtual_uid_maps = static:2525
virtual_gid_maps = static:2525
virtual_transport = virtual
maildrop_destination_recipient_limit = 1
maildrop_destination_concurrency_limit = 1
##########################QUOTA Settings########################
message_size_limit = 14336000
virtual_mailbox_limit = 20971520
virtual_create_maildirsize = yes
virtual_mailbox_extended = yes
virtual_mailbox_limit_maps = mysql:/etc/postfix/mysql_virtual_mailbox_limit_maps.cf
virtual_mailbox_limit_override = yes
virtual_maildir_limit_message = Sorry, the user's maildir has overdrawn his diskspace quota, please Tidy your mailbox and try again later.
virtual_overquota_bounce = yes

2、添加为支持虚拟域和虚拟用户所用到的配置文件

编辑/etc/postfix/mysql_virtual_alias_maps.cf ,添加如下内容:
user = extmail
password = extmail
hosts = localhost
dbname = extmail
table = alias
select_field = goto
where_field = address

编辑/etc/postfix/mysql_virtual_domains_maps.cf ,添加如下内容:
user = extmail
password = extmail
hosts = localhost
dbname = extmail
table = domain
select_field = description
where_field = domain

编辑/etc/postfix/mysql_virtual_mailbox_limit_maps.cf ,添加如下内容:
user = extmail
password = extmail
hosts = localhost
dbname = extmail
table = mailbox
select_field = quota
where_field = username

编辑/etc/postfix/mysql_virtual_mailbox_maps.cf ,添加如下内容:
user = extmail
password = extmail
hosts = localhost
dbname = extmail
table = mailbox
select_field = maildir
where_field = username


说明:
1、这里用到的数据库及用户的建立可以后文中的extmail说明部分来实现,您可以参照那一部分来理解这里指定的数据库及其用户名等;
2、以上新建文件亦可以从extman安装文件中获得,您也可以由此不用手动输入;
3、虚拟用户邮箱目录我这里沿用了/var/mailbox,你可以指定为别的目录,比如常见到的/var/spool/mail,或者/home/domains等;但如果这里做了修改,请在后文中用到时作了相应的修改;

十、安装Courier authentication library

# tar jxvf courier-authlib-0.59.3.tar.bz2
# cd courier-authlib-0.59.3
#./configure
--prefix=/usr/local/courier-authlib
--sysconfdir=/etc
--without-authpam
--without-authldap
--without-authpwd
--without-authshadow
--without-authvchkpw
--without-authpgsql
--with-authmysql
--with-mysql-libs=/usr/local/mysql/lib/mysql
--with-mysql-includes=/usr/local/mysql/include/mysql
--with-redhat
--with-authmysqlrc=/etc/authmysqlrc
--with-authdaemonrc=/etc/authdaemonrc
CFLAGS="-march=i686 -O2 -fexpensive-optimizations"
CXXFLAGS="-march=i686 -O2 -fexpensive-optimizations"
# make
# make install

# chmod 755 /usr/local/courier-authlib/var/spool/authdaemon
# cp /etc/authdaemonrc.dist /etc/authdaemonrc
# cp /etc/authmysqlrc.dist /etc/authmysqlrc

修改/etc/authdaemonrc 文件
authmodulelist="authmysql"
authmodulelistorig="authmysql"
daemons=10

编辑/etc/authmysqlrc 为以下内容,其中2525,2525 为postfix 用户的UID和GID。
MYSQL_SERVER localhost
MYSQL_PORT 3306 (指定你的mysql监听的端口,这里使用默认的3306)
MYSQL_USERNAME extmail (这时为后文要用的数据库的所有者的用户名)
MYSQL_PASSWORD extmail (密码)
MYSQL_SOCKET /tmp/mysql.sock
MYSQL_DATABASE extmail
MYSQL_USER_TABLE mailbox
MYSQL_CRYPT_PWFIELD password
MYSQL_UID_FIELD '2525'
MYSQL_GID_FIELD '2525'
MYSQL_LOGIN_FIELD username
MYSQL_HOME_FIELD concat('/var/mailbox/',homedir)
MYSQL_NAME_FIELD name
MYSQL_MAILDIR_FIELD concat('/var/mailbox/',maildir)

# cp courier-authlib.sysvinit /etc/init.d/courier-authlib
# chmod 755 /etc/init.d/courier-authlib
# chkconfig --add courier-authlib
# chkconfig --level 2345 courier-authlib on

#echo "/usr/local/courier-authlib/lib/courier-authlib" >> /etc/ld.so.conf
# ldconfig -v
# service courier-authlib start (启动服务)

十一、安装Courier-IMAP

# tar jxvf courier-imap-4.1.3.tar.bz2
# cd courier-imap-4.1.3
./configure
--prefix=/usr/local/courier-imap
--with-redhat
--enable-unicode
--disable-root-check
--with-trashquota
--without-ipv6
CPPFLAGS='-I/usr/local/ssl/include/openssl -I/usr/local/courier-authlib/include'
LDFLAGS='-L/usr/local/courier-authlib/lib/courier-authlib'
COURIERAUTHCONFIG='/usr/local/courier-authlib/bin/courierauthconfig'
# 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服务,则需在"/usr/local/courier-imap/etc/imapd"文件中设置"IMAPDSTART=yes";其它类同;

新建虚拟用户邮箱所在的目录,并将其权限赋予postfix用户:
#mkdir –pv /var/mailbox
#chown –R postfix /var/mailbox

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

接下来重新配置SMTP 认证,编辑 /usr/local/lib/sasl2/smtpd.conf ,确保其为以下内容:
pwcheck_method: authdaemond
log_level: 3
mech_list:PLAIN LOGIN
authdaemond_path:/usr/local/courier-authlib/var/spool/authdaemon/socket
开源邮件系统技术架构.jpg
开源邮件系统技术架构.jpg (62.75 KiB) 查看 876 次
[ 本帖最后由 marion 于 2008-7-19 16:17 编辑 ]







marion 回复于:2007-09-06 18:32:15

2008年7月30号:更正笔误一处;

十二、安装Extmail-1.0.2

1、安装
# tar zxvf extmail-1.0.2.tar.gz
# mkdir -pv /var/www/extsuite
# mv extmail-1.0.2 /var/www/extsuite/extmail
# cp /var/www/extsuite/extmail/webmail.cf.default /var/www/extsuite/extmail/webmail.cf

2、修改主配置文件
#vi /var/www/extsuite/extmail/webmail.cf

部分修改选项的说明:

SYS_MESSAGE_SIZE_LIMIT = 5242880
用户可以发送的最大邮件

SYS_USER_LANG = en_US
语言选项,可改作:
SYS_USER_LANG = zh_CN

SYS_MAILDIR_BASE = /home/domains
此处即为您在前文所设置的用户邮件的存放目录,可改作:
SYS_MAILDIR_BASE = /var/mailbox

SYS_MYSQL_USER = db_user
SYS_MYSQL_PASS = db_pass
以上两句句用来设置连接数据库服务器所使用用户名、密码和邮件服务器用到的数据库,这里修改为:
SYS_MYSQL_USER = extmail
SYS_MYSQL_PASS = extmail


SYS_MYSQL_HOST = localhost
指明数据库服务器主机名,这里默认即可

SYS_MYSQL_SOCKET = /var/lib/mysql/mysql.sock
连接数据库的sock文件位置,这里修改为:
SYS_MYSQL_SOCKET = /tmp/mysql.sock


SYS_MYSQL_TABLE = mailbox
SYS_MYSQL_ATTR_USERNAME = username
SYS_MYSQL_ATTR_DOMAIN = domain
SYS_MYSQL_ATTR_PASSWD = password
以上用来指定验正用户登录里所用到的表,以及用户名、域名和用户密码分别对应的表中列的名称;这里默认即可

SYS_AUTHLIB_SOCKET = /var/spool/authdaemon/socket
此句用来指明authdaemo socket文件的位置,这里修改为:
SYS_AUTHLIB_SOCKET = /usr/local/courier-authlib/var/spool/authdaemon/socket


3、apache相关配置

由于extmail要进行本地邮件的投递操作,故必须将运行apache服务器用户的身份修改为您的邮件投递代理的用户;本例中打开了apache服务器的suexec功能,故使用以下方法来实现虚拟主机运行身份的指定。此例中的MDA为postfix自带,因此将指定为postfix用户:
<VirtualHost *:80>
ServerName mail.benet.org
DocumentRoot /var/www/extsuite/extmail/html/
ScriptAlias /extmail/cgi /var/www/extsuite/extmail/cgi
Alias /extmail /var/www/extsuite/extmail/html
SuexecUserGroup postfix postfix
</VirtualHost>

修改 cgi执行文件属主为apache运行身份用户:
# chown -R postfix.postfix /var/www/extsuite/extmail/cgi/

如果您没有打开apache服务器的suexec功能,也可以使用以下方法解决:
# vi /etc/httpd/httpd.conf
User postfix
Group postfix

<VirtualHost *:80>
ServerName mail.benet.org
DocumentRoot /var/www/extsuite/extmail/html/
ScriptAlias /extmail/cgi /var/www/extsuite/extmail/cgi
Alias /extmail /var/www/extsuite/extmail/html
</VirtualHost>

4、依赖关系的解决

extmail将会用到perl的DBD::Mysql和Unix::syslogd功能,您可以去http://search.cpan.org搜索下载原码包进行安装。
# tar zxvf Unix-Syslog-0.100.tar.gz
# cd Unix-Syslog-0.100
# perl Makefile.PL
# make
# make install

DBD-Mysql目前最新的版本为DBD-mysql-4.005,但它和系统中的perl结合使用时会造成extmail无法正常使用,因此我们采用3的版本:
# tar zxvf DBD-mysql-3.0002_4.tar.gz
# cd cd DBD-mysql-3.0002_4
# perl Makefile.PL (此步骤中如果出现类同Can't exec "mysql_config": No such file or directory at Makefile.PL line 76.的错误是因为您的mysql的bin目录没有输出至$PATH环境变量)
# make
# make install

十三、安装Extman-0.2.2

1、安装及基本配置

#tar zxvf extman-0.2.2.tar.gz
# mv extman-0.2.2 /var/www/extsuite/extman

修改配置文件以符合本例的需要:
# vi /var/www/extsuite/extman/webman.cf

SYS_MAILDIR_BASE = /home/domains
此处即为您在前文所设置的用户邮件的存放目录,可改作:
SYS_MAILDIR_BASE = /var/mailbox

SYS_MYSQL_SOCKET = /var/lib/mysql/mysql.sock
此处修改为:
SYS_MYSQL_SOCKET = /tmp/mysql.sock

使用extman源码目录下docs目录中的extmail.sql和init.sql建立数据库:

# cd /var/www/extsuite/extman/docs
# mysql -u root -p <extmail.sql
# mysql -u root -p <init.sql

修改cgi目录的属主:
# chown -R postfix.postfix /var/www/extsuite/extman/cgi/

如果extman访问数据库权限不足的话,可采用以下命令将新生成的数据库赋予webman用户具有所有权限:
mysql> GRANT all privileges on extmail.* TO webman@localhost IDENTIFIED BY 'webman';
mysql> GRANT all privileges on extmail.* TO [email]webman@127.0.0.1[/email] IDENTIFIED BY 'webman';

在apache的主配置文件中Extmail的虚拟主机部分,添加如下两行:
ScriptAlias /extman/cgi /var/www/extsuite/extman/cgi
Alias /extman /var/www/extsuite/extman/html

创建其运行时所需的临时目录,并修改其相应的权限:
#mkdir -pv /tmp/extman
#chown postfix.postfix /tmp/extman


好了,到此为止,重新启动apache服务器后,您的Webmail和Extman已经可以使用了,可以在浏览器中输入指定的虚拟主机的名称进行访问,如下:
http://mail.benet.org

选择管理即可登入extman进行后台管理了。默认管理帐号为:root@extmail.org 密码为:extmail*123*

说明:
(1) 如果您安装后无法正常显示校验码,安装perl-GD模块会解决这个问题。如果想简单,您可以到以下地址下载适合您的平台的rpm包,安装即可: http://dries.ulyssis.org/rpm/packages/perl-GD/info.html
(2) extman-0.2.2自带了图形化显示日志的功能;此功能需要rrdtool的支持,您需要安装此些模块才可能正常显示图形日志。

2、(新增2007.9.18)配置Mailgraph_ext,使用Extman的图形日志:

接下来安装图形日志的运行所需要的软件包Time::HiRes、File::Tail和rrdtool,其中前两个包您可以去http://search.cpan.org搜索并下载获得,后一个包您可以到 http://oss.oetiker.ch/rrdtool/pub/?M=D下载获得; 注意安装顺序不能改换。

安装Time::HiRes
#tar zxvf Time-HiRes-1.9707.tar.gz
#cd Time-HiRes-1.9707
#perl Makefile.PL
#make
#make test
#make install

安装File::Tail
#tar zxvf File-Tail-0.99.3.tar.gz
#cd File-Tail-0.99.3
#perl Makefile
#make
#make test
#make install

安装rrdtool-1.2.23
#tar zxvf rrdtool-1.2.23.tar.gz
#cd rrdtool-1.2.23
#./configure --prefix=/usr/local/rrdtool
#make
#make install

创建必要的符号链接(Extman会到这些路径下找相关的库文件)
#ln -sv /usr/local/rrdtool/lib/perl/5.8.5/i386-linux-thread-multi/auto/RRDs/RRDs.so /usr/lib/perl5/5.8.5/i386-linux-thread-multi/
#ln -sv /usr/local/rrdtool/lib/perl/5.8.5/RRDp.pm /usr/lib/perl5/5.8.5
#ln -sv /usr/local/rrdtool/lib/perl/5.8.5/i386-linux-thread-multi/RRDs.pm /usr/lib/perl5/5.8.5

复制mailgraph_ext到/usr/local,并启动之
# cp -r /var/www/extsuite/extman/addon/mailgraph_ext /usr/local
# / usr/local/mailgraph_ext/mailgraph-init start
# /usr/local/mailgraph_ext/qmonitor-init start

添加到自动启动队列
echo "/usr/local/mailgraph_ext/mailgraph-init start" >> /etc/rc.local
echo "/usr/local/mailgraph_ext/qmonitor-init start" >> /etc/rc.local

好了,接下来您就可以到extman的后台查看图表日志了。效果如下图:

[attach]213848[/attach]

注意:安装以上软件所之前,请确保您的系统已经安装了tcl、tcl-devel、libart和libart-devel等相关的软件包;

新续部分(2007.9.16)

十四、安装maildrop-2.0.4

maildrop是一个使用C++编写的用来代替本地MDA的带有过滤功能邮件投递代理,是courier邮件系统组件之一。它从标准输入接受信息并投递到用户邮箱;maildrop既可以将邮件投递到mailboxes格式邮箱,亦可以将其投递到maildirs格式邮箱。同时,maildrop可以从文件中读取入站邮件过滤指示,并由此决定是将邮件送入用户邮箱或者转发到其它地址等。和procmail不同的是,maildrop使用结构化的过滤语言,因此,邮件系统管理员可以开发自己的过滤规则并应用其中。

我们在此将使用maildrop来代替postfix自带的MDA,并以此为基础扩展后文的邮件杀毒和反垃圾邮件功能的调用;在此可能会修改前文中的许多设置,请确保您的设置也做了相应的修改。

1、安装

将courier-authlib的头文件及库文件链接至/usr目录(编译maildrop时会到此目录下找此些相关的文件):
# ln -sv /usr/local/courier-authlib/bin/courierauthconfig /usr/bin
# ln -sv /usr/local/courier-authlib/include/* /usr/include

maildrop需要pcre的支持,因此,接下来将首先安装pcre
# tar jxvf pcre-7.3.tar.bz2
# cd pcre-7.3
# ./configure
# make
# make check
# make install

# groupadd -g 1001 vmail
# useradd -g vmail -u 1001 -M -s /sbin/nologin vmail
# tar jxvf maildrop-2.0.4.tar.bz2
# cd maildrop-2.0.4
# ./configure
--enable-sendmail=/usr/sbin/sendmail
--enable-trusted-users='root vmail'
--enable-syslog=1 --enable-maildirquota
--enable-maildrop-uid=1001
--enable-maildrop-gid=1001
--with-trashquota --with-dirsync
# make
# make install

检查安装结果,请确保有"Courier Authentication Library extension enabled."一句出现:
# maildrop -v
maildrop 2.0.4 Copyright 1998-2005 Double Precision, Inc.
GDBM extensions enabled.
Courier Authentication Library extension enabled.
Maildir quota extension enabled.
This program is distributed under the terms of the GNU General Public
License. See COPYING for additional information.


2、新建其配置文件/etc/maildroprc文件,首先指定maildrop的日志记录位置:
# vi /etc/maildroprc
添加:
logfile "/var/log/maildrop.log"

# touch /var/log/maildrop.log
# chown vmail.vmail /var/log/maildrop.log

3、配置Postfix

编辑master.cf
# vi /etc/postfix/master.cf
启用如下两行
maildrop unix - n n - - pipe
flags=DRhu user=vmail argv=/usr/local/bin/maildrop -d ${recipient}

注意:定义transport的时候,即如上两行中的第二行,其参数行必须以空格开头,否则会出错。

编辑main.cf
# vi /etc/postfix/main.cf
virtual_transport = virtual
修改为:
virtual_transport = maildrop

将下面两项指定的UID和GID作相应的修改:
virtual_uid_maps = static:2525
virtual_gid_maps = static:2525
修改为:
virtual_uid_maps = static:1001
virtual_gid_maps = static:1001


4、编辑/etc/authmysqlrc

# vi /etc/authmysqrc
MYSQL_UID_FIELD '2525'
MYSQL_GID_FIELD '2525'
更改为:
MYSQL_UID_FIELD '1001'
MYSQL_GID_FIELD '1001'

注意:没有此处的修改,maildrop可能会报告 “signal 0x06”的错误报告。

5、编辑/etc/httpd/httpd.conf,修改运行用户:

如果启用了suexec的功能,则将虚拟主机中指定的
SuexecUserGroup postfix postfix
修改为:
SuexecUserGroup vmail vmail

如果没有使用上面的功能,则修改User和Group指令后的用户为vmail
将前文中的如下项
User postfix
Group postfix
修改为:
User vmail
Group vmail

6、将用户邮件所在的目录/var/mailbox和extman的临时目录/tmp/extman的属主和属组指定为vmail
#chown -R vmail.vmail /var/mailbox
#chown -R vmail.vmail /tmp/extman


接下来重新启动postfix和apache,进行发信测试后,如果日志中的记录类同以下项,则安装成功

Sep 16 12:04:43 Ixor postfix/pipe[14266]: 46B491A5CB: to=<marion@test.com>, relay=maildrop, delay=2306, delays=2306/0.04/0/0.07, dsn=2.0.0, status=sent (delivered via maildrop service)

[ 本帖最后由 marion 于 2008-7-30 11:21 编辑 ]
截图_2025-11-15_14-19-56.jpg
截图_2025-11-15_14-19-56.jpg (151.62 KiB) 查看 875 次
marion 回复于:2007-09-06 18:34:19

接下来安装反病毒和反垃圾邮件的相关组件clamav、amavisd和SpamAssassin

ClamAV是一个unix系统平台上的开源反病毒工具,它是特地为在邮件网关上进行邮件扫描而设计的。整套软件提供了许多的实用工具,包括一个可伸缩和可升级的多线程守护进程、一个命令行扫描工具和病毒库自动升级工具。

SpamAssassin 是目前最好的、最流行的开源反垃圾邮件软件之一。它是一个邮件过滤器,使用了多种反垃圾邮件技术,如:文本分析、贝叶斯过滤、DNS黑名单和分布式协同过滤数据库等。

amavisd-new是一个连接MTA和内容检测工具(诸如病毒扫描工具和SpamAssassin)的高性能接口程序,使用perl语言写成。它一般通过SMTP、ESMTP或者LMTP和MTA进行通讯,当然也可以借助于其它外部程序进行。同postfix(MTA)协同工作时表现尤佳。当它呼叫SpamAssassin进行内容过滤时,对于一封邮件只需要呼叫一次,而不管这封邮件将发往多少个收件人;同时,它亦会尽力保证实现每一位收件人的偏好设置,如接收/拒绝,检测/不检测,垃圾邮件级别等;它还会在邮件头部分插入spam相关信息。

十五、安装clamav-0.91.2

最新的clamav-0.91.2需要zlib-1.2.2以上的版本的支持,而RHEL4上的版本为zlib-1.2.1,因此您需要先升级zlib

1、安装zlib-1.2.3

#tar zvxf zlib-1.2.3.tar.gz
#cd zlib-1.2.3
#./configure --prefix=/usr --shared
#make
#make test

2、安装clamav-0.91.2

添加ClamAV运行所需的组和用户:
#groupadd clamav
#useradd -g clamav -s /sbin/nologin -M clamav

添加配合amavisd-new使用的用户amavis
#groupadd amavis
#useradd -g amavis -s /sbin/nologin -M amavis

#tar zxvf clamav-0.91.2.tar.gz
#cd clamav-0.91.2
#./configure --prefix=/usr/local/clamav --with-dbdir=/usr/local/clamav/share --sysconfdir=/etc/clamav
#make
#make check
#make install

3、配置Clam AntiVirus:

编辑主配置文件:
#vi /etc/clamav/clamd.conf

注释掉第八行的Example,如下:
# Example

找到如下行
#LogFile /tmp/clamd.log
#PidFile /var/run/clamd.pid
LocalSocket /tmp/clamd.socket
#DatabaseDirectory /var/lib/clamav
#User clamav
修改为:
LogFile /var/log/clamav/clamd.log
PidFile /var/run/clamav/clamd.pid
LocalSocket /var/run/clamav/clamd.socket
DatabaseDirectory /usr/local/clamav/share
User amavis

启用以下选项
LogSyslog yes
LogFacility LOG_MAIL
LogVerbose yes
StreamMaxLength 20M (后面的数值应该与邮件服务器允许的最大附件值相一致)


编辑更新进程的配置文件
#vi /etc/clamav/freshclam.conf

注释掉Example,如下:
# Example

找到如下行
#DatabaseDirectory /var/lib/clamav
#UpdateLogFile /var/log/freshclam.log
PidFile /var/run/freshclam.pid
分别修改为:
DatabaseDirectory /usr/local/clamav/share
UpdateLogFile /var/log/clamav/freshclam.log
PidFile /var/run/clamav/freshclam.pid

启用以下选项:
DatabaseMirror db.XY.clamav.net (这里也可以把XY改成您的国家代码来实现,比如,我们用cn来代替)
LogSyslog yes
LogFacility LOG_MAIL
LogVerbose yes

4、建立日志所在的目录、进程与socket所在的目录,并让它属于clamav用户:

# mkdir -v /var/log/clamav
# chown -R amavis.amavis /var/log/clamav
# mkdir -v /var/run/clamav
# chmod 700 /var/run/clamav
# chown -R amavis.amavis /var/run/clamav

建立freshlog的日志文件
#touch /var/log/clamav/freshclam.log
#chown clamav.clamav /var/log/clamav/freshclam.log

5、配置crontab,让Clam AntiVirus每小时检测一次新的病毒库:

# crontab -e
添加:
37 * * * * /usr/local/clamav/bin/freshclam

6、配置库文件搜索路径:

# echo “/usr/local/clamav/lib” >> /etc/ls.so.conf
# ldconfig -v

7、配置clamav开机自动启动

# cp contrib/init/RedHat/clamd /etc/rc.d/init.d/clamd
# cp contrib/init/RedHat/clamav-milter /etc/rc.d/init.d/clamav-milter
# chkconfig --add clamd
# chkconfig --add clamav-milter
# chkconfig --level 2345 clamd on
# chkconfig --level 2345 clamav-milter on

编辑/etc/rc.d/init.d/clamd,将服务进程的路径指向刚才的安装目录
#vi /etc/rc.d/init.d/clamd
找到如下行
progdir="/usr/local/sbin"
修改为:
progdir="/usr/local/clamav/sbin"

启动clamd
#service clamd start

十六、安装Spamassassin-3.2.3 (2007.9.19新增)

1、依赖关系的解决,安装Spamassassin需要很多perl模块的支持,以下是所需模块列表及安装方法;

必须的软件包:
Digest::SHA1
HTML::Parser
Net::DNS
LWP (aka libwww-perl)
HTTP::Date
IO::Zlib
Archive::Tar

可选的软件包,其中有些后面的amavisd也有可能会用到:
MIME::Base64
DB_File
Net::SMTP
Mail::SPF
IP::Country::Fast
Net::Ident
IO::Socket::INET6
IO::Socket::SSL
Compress::Zlib
Time::HiRes
Mail::DKIM
Mail::DomainKeys
DBI *and* DBD driver/modules
Encode::Detect
Apache::Test
Razor2

推荐使用CPAN自动安装(你的主机要能连上Internet),它能够自动下载安装,并能解决安装过程中的依赖关系。您可以使用类同的以下的命令来进行安装:
#perl -MCPAN -e shell
cpan> install Digest::SHA1
………………

如果您的主机无法直接连接到Internet,您也可以到http://search.cpan.org上搜索下载所需要的软件包,而后使用类同的下列命令安装:

#tar zxvf 软件包.tar.gz
#cd 软件包
#perl Makefile.PL
#make
#make test
#make install
说明:某些软件包安装的过程中可能需要已经列出的其它软件包的支持(可以先尝试安装Spamassassin,然后按提示补充所需软件包),请安照提示自行调整安装顺序。另外,其中有个软件包安装过程中可能要求声明环境变量LC_ALL,此时,可输入如下命令,并重新进行软件包的编译安装即可。
#export LC_ALL=C

2、安装Spamassassin-3.2.3

#tar jxvf Mail-SpamAssassin-3.2.3.tar.bz2
#cd Mail-SpamAssassin-3.2.3
#perl Makefile.PL
#make
#make check
#make istall

3、编辑主配置文件/etc/mail/spamassassin/local.cf

required_hits 10.0
rewrite_subject 1
required_score 5.0
rewrite_header Subject *****SPAM*****
report_safe 1
use_bayes 1
bayes_auto_learn 1
skip_rbl_checks 1
use_razor2 0
use_pyzor 0
ok_locales all


4、测试spamassassin

#spamassassin -t < sample-nonspam.txt > nonspam.out
#spamassassin -t < sample-spam.txt > spam.out

查看测试结果:

#less nonspam.out
#less spam.out

5、检查配置文件

#spamassassin -d --lint

6、启动进程,并将其加入到自动启动队列

#/usr/bin/spamd -d
#echo "/usr/bin/spamd -d" >> /etc/rc.local

十七、安装amavisd-new-2.5.2

1、依赖关系的解决

以下为官方声明所必须的软件包列表,你可以采用类同安装Spamassassin一节中的perl模块的安装方法进行安装

Archive::Zip (Archive-Zip-x.xx) (1.14 or later should be used!)
Compress::Zlib (Compress-Zlib-x.xx) (1.35 or later)
Convert::TNEF (Convert-TNEF-x.xx)
Convert::UUlib (Convert-UUlib-x.xxx) (1.08 or later, stick to new versions!)
MIME::Base64 (MIME-Base64-x.xx)
MIME::Parser (MIME-Tools-x.xxxx) (latest version from CPAN - currently 5.420)
Mail::Internet (MailTools-1.58 or later have workarounds for Perl 5.8.0 bugs)
Net::Server (Net-Server-x.xx) (version 0.88 finally does setuid right)
Digest::MD5 (Digest-MD5-x.xx) (2.22 or later)
IO::Stringy (IO-stringy-x.xxx)
Time::HiRes (Time-HiRes-x.xx) (use 1.49 or later, older can cause problems)
Unix::Syslog (Unix-Syslog-x.xxx)
BerkeleyDB with bdb library 3.2 or later (4.2 or later preferred)

2、安装amavisd-new-2.5.2

创建运行时目录,并赋予amavis用户(前文中所建)
# mkdir -pv /var/amavis/{tmp,var,db,home}
# chown -R amavis:amavis /var/amavis
#chmod -R 750 /var/amavis

#tar zxvf amavisd-new-2.5.2.tar.gz
#cd amavisd-new-2.5.2

拷贝服务端至$PATH中指定的目录,推荐拷贝至/usr/local/sbin:
#cp amavisd /usr/local/sbin/
#chown root /usr/local/sbin/amavisd
#chmod 755 /usr/local/sbin/amavisd

拷贝主配置文件至/etc,并修改相应的权限:
#cp amavisd.conf /etc
# chown root:amavis /etc/amavisd.conf
# chmod 640 /etc/amavisd.conf

创建amavisd运行中所需要的隔离区域:
# mkdir -v /var/virusmails
# chown amavis:amavis /var/virusmails/
# chmod 750 /var/virusmails/

3、编辑主配置文件
#vi /etc/amavisd.conf

确保您的如下选项的值如下文所示:
$daemon_user = 'amavis';
$daemon_group = 'amavis';
$mydomain = 'benet.org'; (此处可更改为您集体的域)

$virus_admin = "postmaster\@$mydomain";
$mailfrom_notify_admin = "postmaster\@$mydomain";
$mailfrom_notify_recip = "postmaster\@$mydomain";
$mailfrom_notify_spamadmin = "postmaster\@$mydomain";
$mailfrom_to_quarantine = '';

virus_admin_maps => ["postmaster\@$mydomain"] (指定报告病毒和垃圾邮件时发送系统邮件的用户身份)
spam_admin_maps => ["postmaster\@$mydomain"]

启用ClamAV,(大概在第355行)去掉如下行前的注释符:
#['ClamAV-clamd',
# \&ask_daemon, ["CONTSCAN {}\n", "/var/run/clamav/clamd"],
# qr/\bOK$/, qr/\bFOUND$/,
# qr/^.*?: (?!Infected Archive)(.*) FOUND$/ ],
# ['Mail::ClamAV', \&ask_clamav, "*", [0], [1], qr/^INFECTED: (.+)/],

并将如上行中的/var/run/clamav/clamd修改为:/var/run/clamav/clamd.socket

4、测试启动

#/usr/local/sbin/amavisd

您也可以按如下命令调试启动
#/usr/local/sbin/amavisd debug


5、修改postfix的配置,让它能调用amavisd,以实现病毒及垃圾邮件的过滤

#vi /etc/postfix/master.cf
在文末添加如下内容:

# ==========================================================================
# service type private unpriv chroot wakeup maxproc command + args
# (yes) (yes) (yes) (never) (100)
# ==========================================================================
#
amavisfeed unix - - n - 2 smtp
-o smtp_data_done_timeout=1200
-o smtp_send_xforward_command=yes
-o disable_dns_lookups=yes
-o max_use=20
#
127.0.0.1:10025 inet n - n - - smtpd
-o content_filter=
-o smtpd_delay_reject=no
-o smtpd_client_restrictions=permit_mynetworks,reject
-o smtpd_helo_restrictions=
-o smtpd_sender_restrictions=
-o smtpd_recipient_restrictions=permit_mynetworks,reject
-o smtpd_data_restrictions=reject_unauth_pipelining
-o smtpd_end_of_data_restrictions=
-o smtpd_restriction_classes=
-o mynetworks=127.0.0.0/8
-o smtpd_error_sleep_time=0
-o smtpd_soft_error_limit=1001
-o smtpd_hard_error_limit=1000
-o smtpd_client_connection_count_limit=0
-o smtpd_client_connection_rate_limit=0
-o receive_override_options=no_header_body_checks,no_unknown_recipient_checks,no_milters
-o local_header_rewrite_clients=

说明:注意每行“-o”前的空格;


#vi /etc/postifx/main.cf
在文末添加如下行:
content_filter=amavisfeed:[127.0.0.1]:10024

4、让postfix重新加载主配置文件,并查看启动情况

# postfix reload && tail -f /var/log/maillog

5、查看amavisd是否在监听10024端口,并测试服务启动情况:

# telnet localhost 10024
Trying 127.0.0.1...
Connected to localhost.localdomain (127.0.0.1).
Escape character is '^]'.
220 [127.0.0.1] ESMTP amavisd-new service ready
EHLO localhost
250-[127.0.0.1]
250-VRFY
250-PIPELINING
250-SIZE
250-ENHANCEDSTATUSCODES
250-8BITMIME
250-DSN
250 XFORWARD NAME ADDR PROTO HELO
Quit
221 2.0.0 [127.0.0.1] amavisd-new closing transmission channel
Connection closed by foreign host.

6、postfix重新加载配置文件后将授权并激活"127.0.0.1:10025"端口,一个正常的服务连接应该类同下面所示:

# telnet localhost 10025
Trying 127.0.0.1...
Connected to localhost.localdomain (127.0.0.1).
Escape character is '^]'.
220 Welcome to our mail.benet.org ESMTP,Warning: Version not Available
EHLO localhost
250-mail.benet.org
250-PIPELINING
250-SIZE 14336000
250-VRFY
250-ETRN
250-AUTH PLAIN LOGIN
250-AUTH=PLAIN LOGIN
250-ENHANCEDSTATUSCODES
250-8BITMIME
250 DSN
QUIT
221 2.0.0 Bye
Connection closed by foreign host.

7、通过amavisd测试发信

]# telnet localhost 10024
Trying 127.0.0.1...
Connected to localhost.localdomain (127.0.0.1).
Escape character is '^]'.
220 [127.0.0.1] ESMTP amavisd-new service ready
HELO localhost
250 [127.0.0.1]
MAIL FROM:<>
250 2.1.0 Sender <> OK
RCPT TO:<postmaster>
250 2.1.5 Recipient <postmaster> OK
DATA
354 End data with <CR><LF>.<CR><LF>
From:Anti-Virus tester
To: MailServer Admin
Subject:amavisd test!
amavisd test!!
.
250 2.0.0 Ok: queued as 263FC1A609
quit
221 2.0.0 [127.0.0.1] amavisd-new closing transmission channel
Connection closed by foreign host.

接下来使用root用户测试收信
# mail
Mail version 8.1 6/6/93. Type ? for help.
"/var/spool/mail/root": 1 message 1 new
>N 1 Anti-Virus tester Wed Sep 19 01:19 23/798 "amavisd test!"
& 1
Message 1:
From MAILER-DAEMON Wed Sep 19 01:19:16 2007
X-Original-To: postmaster
Delivered-To: postmaster@benet.org
X-Quarantine-ID: <3gmvpc8RxPtn>
X-Virus-Scanned: amavisd-new at benet.org
X-Amavis-Alert: BAD HEADER, MIME error: error: unexpected end of header
From:Anti-Virus tester
To: MailServer Admin
Subject:amavisd test!
Date: Wed, 19 Sep 2007 01:19:15 +0800 (CST)

amavisd test!!
&

十八、测试使用反病毒及反垃圾模块

1、病毒邮件发送测试

登录extmail,发送带有病毒附件的邮件(病毒样本文件后文附有),查看发送情况:

# tail -3 /var/log/clamav/clamd.log
Reading databases from /usr/local/clamav/share

Database correctly reloaded (148100 signatures)

/var/amavis/tmp/amavis-20070918T225935-28502/parts/p002: Trojan.Downloader.Delf-747 FOUN


#tail -15 /var/log/maillog
Sep 18 23:36:40 mail postfix/pickup[28925]: 8C1681A609: uid=1001 from=<marion@test.com>

Sep 18 23:36:40 mail postfix/cleanup[29002]: 8C1681A609: message-id=<20070918153640.8C1681A609@mail.benet.org>

Sep 18 23:36:40 mail postfix/qmgr[28924]: 8C1681A609: from=<marion@test.com>, size=83658, nrcpt=1 (queue active)

Sep 18 23:36:43 mail clamd[28473]: /var/amavis/tmp/amavis-20070918T225935-28502/parts/p002: Trojan.Downloader.Delf-747 FOUND

Sep 18 23:36:44 mail postfix/smtpd[29011]: connect from mail[127.0.0.1]

Sep 18 23:36:44 mail postfix/smtpd[29011]: CDF9B1A602: client=mail[127.0.0.1]

Sep 18 23:36:44 mail postfix/cleanup[29002]: CDF9B1A602: message-id=<VA7mnx1DHavOWC@mail.benet.org>

Sep 18 23:36:44 mail postfix/smtpd[29011]: disconnect from mail[127.0.0.1]

Sep 18 23:36:44 mail postfix/qmgr[28924]: CDF9B1A602: from=<postmaster@benet.org>, size=2230, nrcpt=1 (queue active)

Sep 18 23:36:44 mail amavis[28502]: (28502-05) Blocked INFECTED (Trojan.Downloader.Delf-747), <marion@test.com> -> <marion@test.com>, quarantine: virus-7mnx1DHavOWC, Message-ID: <20070918153640.8C1681A609@mail.benet.org>, mail_id: 7mnx1DHavOWC, Hits: -, size: 83658, 4203 ms

Sep 18 23:36:45 mail postfix/smtp[29006]: 8C1681A609: to=<marion@test.com>, relay=127.0.0.1[127.0.0.1]:10024, delay=4.7, delays=0.42/0.05/0.12/4.1, dsn=2.7.0, status=sent (250 2.7.0 Ok, discarded, id=28502-05 - VIRUS: Trojan.Downloader.Delf-747)

Sep 18 23:36:45 mail postfix/qmgr[28924]: 8C1681A609: removed

Sep 18 23:36:45 mail postfix/local[29014]: CDF9B1A602: to=<root@benet.org>, orig_to=<postmaster@benet.org>, relay=local, delay=0.28, delays=0.12/0.09/0/0.07, dsn=2.0.0, status=sent (delivered to mailbox)

Sep 18 23:36:45 mail postfix/qmgr[28924]: CDF9B1A602: removed


说明:此附件中带有特洛伊病毒,请不要作为危害别人之用,而对于您的操作不慎而给您带来的后果,作者不负任何责任;病毒样本如下:
[attach]213887[/attach]

2、垃圾邮件测试

登录extmail,新建一封邮件,拷贝以下内容作为邮件正文,并查看发送情况:

This is the GTUBE, the
Generic
Test for
Unsolicited
Bulk
Email

If your spam filter supports it, the GTUBE provides a test by which you
can verify that the filter is installed correctly and is detecting incoming
spam. You can send yourself a test mail containing the following string of
characters (in upper case and with no white spaces and line breaks):

XJS*C4JDBQADN1.NSBN3*2IDNEN*GTUBE-STANDARD-ANTI-UBE-TEST-EMAIL*C.34X

查看发送结果:
#tail -15 /var/log/maillog
Sep 19 00:04:07 mail spamd[29060]: logger: removing stderr method

Sep 19 00:04:11 mail spamd[29062]: rules: meta test FM_DDDD_TIMES_2 has dependency 'FH_HOST_EQ_D_D_D_D' with a zero score

Sep 19 00:04:11 mail spamd[29062]: rules: meta test FM_SEX_HOSTDDDD has dependency 'FH_HOST_EQ_D_D_D_D' with a zero score

Sep 19 00:04:11 mail spamd[29062]: rules: meta test HS_PHARMA_1 has dependency 'HS_SUBJ_ONLINE_PHARMACEUTICAL' with a zero score

Sep 19 00:04:11 mail spamd[29062]: spamd: server started on port 783/tcp (running version 3.2.3)

Sep 19 00:04:12 mail spamd[29062]: spamd: server pid: 29062

Sep 19 00:04:12 mail spamd[29062]: spamd: server successfully spawned child process, pid 29064

Sep 19 00:04:12 mail spamd[29062]: spamd: server successfully spawned child process, pid 29065

Sep 19 00:04:12 mail spamd[29062]: prefork: child states: II

Sep 19 00:06:44 mail postfix/pickup[28925]: E37651A60E: uid=1001 from=<marion@test.com>

Sep 19 00:06:44 mail postfix/cleanup[29073]: E37651A60E: message-id=<20070918160643.E37651A60E@mail.benet.org>

Sep 19 00:06:45 mail postfix/qmgr[28924]: E37651A60E: from=<marion@test.com>, size=1041, nrcpt=1 (queue active)

Sep 19 00:07:01 mail amavis[28502]: (28502-06) Blocked SPAM, <marion@test.com> -> <marion@test.com>, quarantine: spam-7ui+Zpn7-M00.gz, Message-ID: <20070918160643.E37651A60E@mail.benet.org>, mail_id: 7ui+Zpn7-M00, Hits: 1004.576, size: 1040, 12805 ms

Sep 19 00:07:01 mail postfix/smtp[29079]: E37651A60E: to=<marion@test.com>, relay=127.0.0.1[127.0.0.1]:10024, delay=18, delays=1.8/1.5/4.9/9.9, dsn=2.5.0, status=sent (250 2.5.0 Ok, id=28502-06, DISCARD(bounce.suppressed))

Sep 19 00:07:01 mail postfix/qmgr[28924]: E37651A60E: removed


待续……

:好消息:在518、519、520、523、524楼,柳拂风朋友对本文做了大量扩充,建议朋友们参照!

在701、702楼,zenglingping朋友对本文做了不少的扩充,建议朋友们参照。

[ 本帖最后由 marion 于 2008-7-23 10:13 编辑 ]

soe.rar

liwei6998 回复于:2007-09-07 16:00:34

高人,非常感谢,真诚期待未完的部分!!!

marion 回复于:2007-09-11 15:12:03

杀毒和防垃圾邮件的处理模块正测试添加中……

xiaoqi8866 回复于:2007-09-12 11:03:14

好 顶!!!

kexen 回复于:2007-09-12 14:58:17

嗯,是的,建议挂上Mcafee或者clamav 反垃圾邮件当然考虑用用hzq老大的spamlock啦

swh01 回复于:2007-09-12 15:33:49

顶起来

marion 回复于:2007-09-13 09:51:12

嗯,KEXEN兄,请教hzqbbc的spamlock您是否在使用?效果想来应该不错吧?

flash520 回复于:2007-09-13 13:23:12

以上的方法在CentOS5上面适用吗?

marion 回复于:2007-09-13 14:21:46

适用于CentOS5,我已经在上面搭建了一个出来……

liheng 回复于:2007-09-14 09:18:25

引用:SYS_MAILDIR_BASE = /home/domains
此处即为您在前文所设置的用户邮件的存放目录,可改作:
SYS_MAILDIR_BASE = /var/www/mail

这里是不是应该设置为 /var/spool/mail ?
引用:SYS_MYSQL_USER = db_user
SYS_MYSQL_PASS = db_pass
以上两句句用来设置连接数据库服务器所使用用户名、密码和邮件服务器用到的数据库,这里修改为:
SYS_MYSQL_USER = postfix
SYS_MYSQL_PASS = 123456

这个 user 与 pass 的值是不是随便设就可以的?

[ 本帖最后由 liheng 于 2007-9-14 09:23 编辑 ]

marion 回复于:2007-09-14 09:46:59

回楼上的兄弟,你提出的正是本文中的错误。谢了。
那个的确应该是/var/spool/mail

还有,那个用户名和密码应该分别是extmail和extmail,这是修改过程中的遗留问题!

liheng 回复于:2007-09-14 18:49:56

marion 老兄,能不能帮我看一下,我的是什么问题
http://bbs.chinaunix.net/viewthread.php?tid=991122&page=1&extra=page%3D1#pid7353077
为了这个问题,都弄了半个月啦,抓狂啊

marion 回复于:2007-09-14 23:31:42

MYSQL_USERNAME extamail
这个是你写文档时错的,还是本来就错了?

virtual_mailbox_limit_maps = mysql:/etc/postfix/mysql_virtual_mailbox_limit_maps.cf
这个好像跟你后文建立文件时指定的路径不同;

另外,我大略的看了一遍你的安装文档,也没有看出什么漏洞出来。建议你去看看:
1、本地域是否跟虚拟域重名了;
2、我不知道你的虚拟域是如何建立的,如果是通过extman的话,建议去看看postfix用户对/var/mailbox是否有完全访问权限;

希望对你有所帮助,也欢迎你再来帖子讨论修改后的结果。

liheng 回复于:2007-09-15 08:47:24

引用:MYSQL_USERNAME extamail
这个是你写文档时错的,还是本来就错了?

这个是输入时错误,后来改过来了

引用:virtual_mailbox_limit_maps = mysql:/etc/postfix/mysql_virtual_mailbox_limit_maps.cf
这个好像跟你后文建立文件时指定的路径不同;

这个问题我还真没有发现,谢谢 marion 兄为我指出来。
有个问题我不太明白
本地域是否是指 mydomain 所指定的参数?
我在 extman 中是新建了一个域名为 test.com 的,不会是这两个有冲突吧?还请 marion 为我解惑,谢谢啦

liheng 回复于:2007-09-15 09:53:39

引用:SYS_MYSQL_USER = webman
SYS_MYSQL_PASS = webman
SYS_MYSQL_SOCKET = /var/lib/mysql/mysql.sock
说明部分见Extmail安装部分,此处可修改为:
YS_MYSQL_USER = extmail
SYS_MYSQL_PASS = extmail
SYS_MYSQL_SOCKET = /tmp/mysql.sock

又是我的一点错误,这里我没有改成 extmail,刚刚又检查了一下,我将 /etc/postfix/main.cf 中的mydomain 和 myorigin 参数注释掉了,可以用 web 收发邮件,但在outlook 上依然不能收发邮件,而且很奇怪的是 telnet localhost 25 & telnet localhost 110 都不通过

dnnljexk 回复于:2007-09-15 11:24:27

可以说明一下每个包的作用吗???

marion 回复于:2007-09-15 18:17:16

引用:
……本地域是否是指 mydomain 所指定的参数?
我在 extman 中是新建了一个域名为 test.com 的, ...


你的猜测是正确的;当二者同时存在时,所有的信将被发往本地系统的相应的用户了……

marion 回复于:2007-09-15 18:20:03

引用:……我将 /etc/postfix/main.cf 中的mydomain 和 myorigin 参数注释掉了,可以用 web 收发邮件,但在outlook 上依然不能收发邮件,而且很奇怪的是 ...


不知道你是否为outlook启用了使用认证的功能,如果没有的话,我想,问题应该就在这里了;如果已经启用,仍不能发信,那你把使用outlook连接后不成功的日志部分发上来,我帮你看看。希望对你有所帮助……

liheng 回复于:2007-09-17 00:14:55

引用:Sep 16 23:23:04 redhat postfix/local[16201]: 2F5253F9B2: to=<postmaster@test.com>, orig_to=<postmaster>, relay=local, delay=301, delays=300/0.15/0/0.13, dsn=4.3.0, status=deferred (alias database unavailable)
Sep 16 23:28:04 redhat postfix/qmgr[16185]: 4C1DE3F565: from=<double-bounce@mail.test.com>, size=694, nrcpt=1 (queue active)

Sep 16 23:28:04 redhat postfix/qmgr[16185]: 2F5253F9B2: from=<double-bounce@mail.test.com>, size=721, nrcpt=1 (queue active)

Sep 16 23:28:04 redhat postfix/trivial-rewrite[16212]: warning: do not list domain test.com in BOTH mydestination and virtual_mailbox_domains
Sep 16 23:28:04 redhat postfix/local[16215]: warning: lookup owner-postmaster, NIS domain test, map mail.aliases: internal yp server or client error
Sep 16 23:28:04 redhat postfix/local[16214]: warning: lookup owner-postmaster, NIS domain test, map mail.aliases: internal yp server or client error
Sep 16 23:28:04 redhat postfix/local[16215]: 2F5253F9B2: to=<postmaster@test.com>, orig_to=<postmaster>, relay=local, delay=601, delays=600/0.1/0/0.1, dsn=4.3.0, status=deferred (alias database unavailable)
Sep 16 23:28:04 redhat postfix/local[16214]: 4C1DE3F565: to=<postmaster@mail.test.com>, orig_to=<postmaster>, relay=local, delay=1017, delays=1016/0.13/0/0.16, dsn=4.3.0, status=deferred (alias database unavailable)
Sep 16 23:28:38 redhat postfix/postfix-script[16225]: refreshing the Postfix mail system
Sep 16 23:28:38 redhat postfix/master[15903]: reload configuration /etc/postfix

telnet localhost 25 成功,
telnet localhost 110 失败,提示 chdir maildir failed
在 extmail 上不能可以发邮件,但不能收。
在 outlook 上不能收发邮件,在 outlook 上无论是开启认证和不开启 论证都不行

liheng 回复于:2007-09-17 00:15:52

还请 marion 兄帮小弟看一下,谢谢啦:)

liheng 回复于:2007-09-17 00:16:40

哦,对了,配置完全是按照你所提供的方法做的,所以配置文件我就不贴了。

liheng 回复于:2007-09-17 00:36:51

而且我用 mailq 命令查看邮件队列,可以看到队列里有邮件,就是没有发出去,郁闷。

marion 回复于:2007-09-17 10:18:22

Sep 16 23:28:04 redhat postfix/local[16214]: 4C1DE3F565: to=<postmaster@mail.test.com>, orig_to=<postmaster>, relay=local, delay=1017, delays=1016/0.13/0/0.16, dsn=4.3.0, status=deferred (alias database unavailable)
Sep 16 23:28:38 redhat postfix/postfix-script[16225]: refreshing the Postfix mail system
Sep 16 23:28:38 redhat postfix/master[15903]: reload configuration /etc/postfix

别名文件找不到,你是否执行了newaliases命令?
或者查看一下你指定的路径是否正确。

marion 回复于:2007-09-17 10:21:45

telnet localhost 110 失败,提示 chdir maildir failed
这个应该是你的设置没有权限访问邮箱所在的目录,请检查一下你指定的访问者,以及权限设置。

在 extmail 上不能可以发邮件,但不能收。
这个原因跟上述问题应该是同一个原因造成的。你应该把邮箱目录的所有者指定为httpd服务的运行者或者使用suexec,建议你再认真看一下文档,并渐次排查问题。

liheng 回复于:2007-09-17 14:27:39

newaliases 命令是执行了的,也产生了aliases.db 文件
邮箱所在的目录的属主是 用户 postfix

marion 回复于:2007-09-17 15:02:26

请确信邮箱目录内的文件也属于postfix用户,同时也应该再去检查一下你的别名文件的设置,包括用户别名和域别名文件。

liheng 回复于:2007-09-17 15:08:44

引用:Sep 17 14:22:49 redhat postfix/smtpd[3369]: connect from unknown[192.168.0.145]
Sep 17 14:22:49 redhat postfix/smtpd[3369]: warning: unknown[192.168.0.145]: SASL LOGIN authentication failed: authentication failure
Sep 17 14:22:49 redhat postfix/smtpd[3369]: lost connection after AUTH from unknown[192.168.0.145]
Sep 17 14:22:49 redhat postfix/smtpd[3369]: disconnect from unknown[192.168.0.145]
Sep 17 14:22:49 redhat postfix/smtpd[3369]: connect from unknown[192.168.0.145]
Sep 17 14:22:49 redhat postfix/smtpd[3369]: warning: unknown[192.168.0.145]: SASL LOGIN authentication failed: authentication failure
Sep 17 14:22:49 redhat postfix/smtpd[3369]: lost connection after AUTH from unknown[192.168.0.145]
Sep 17 14:22:49 redhat postfix/smtpd[3369]: disconnect from unknown[192.168.0.145]
Sep 17 14:22:49 redhat postfix/smtpd[3369]: connect from unknown[192.168.0.145]
Sep 17 14:22:49 redhat postfix/smtpd[3369]: warning: unknown[192.168.0.145]: SASL LOGIN authentication failed: authentication failure
Sep 17 14:22:49 redhat postfix/smtpd[3369]: lost connection after AUTH from unknown[192.168.0.145]
Sep 17 14:22:49 redhat postfix/smtpd[3369]: disconnect from unknown[192.168.0.145]
Sep 17 14:22:49 redhat postfix/smtpd[3369]: connect from unknown[192.168.0.145]
Sep 17 14:22:49 redhat postfix/smtpd[3369]: warning: unknown[192.168.0.145]: SASL LOGIN authentication failed: authentication failure
Sep 17 14:22:49 redhat postfix/smtpd[3369]: lost connection after AUTH from unknown[192.168.0.145]
Sep 17 14:22:49 redhat postfix/smtpd[3369]: disconnect from unknown[192.168.0.145]
Sep 17 14:24:40 redhat postfix/qmgr[3270]: 6A5613F588: from=<test@test.com>, size=506, nrcpt=1 (queue active)
Sep 17 14:24:40 redhat postfix/trivial-rewrite[3378]: warning: do not list domain test.com in BOTH mydestination and virtual_mailbox_domains
Sep 17 14:24:40 redhat postfix/local[3380]: warning: lookup bob, NIS domain test, map mail.aliases: internal yp server or client error
Sep 17 14:24:40 redhat postfix/local[3380]: 6A5613F588: to=<bob@test.com>, relay=local, delay=526, delays=526/0.1/0/0.06, dsn=4.3.0, status=deferred (alias database unavailable)

又仔细看了一下,还是没有发现什么问题?

liheng 回复于:2007-09-17 15:09:36

邮箱目录内的所有文件都属于 postfix

liheng 回复于:2007-09-17 15:30:11

marion 兄,已经可以实现 web 收发邮件,只是还不能够用 outlook 收发邮件

liheng 回复于:2007-09-17 15:46:36

marion 兄,我将 /etc/postfix/main.cf 文件内的 mydestination 和 mynetworks 两个参数注释掉后,瑞在可以用 outlook 发邮件,但是却不能收,outlook 错误提示:

[ 本帖最后由 liheng 于 2007-9-17 15:53 编辑 ]
截图_2025-11-15_14-36-37.jpg
截图_2025-11-15_14-36-37.jpg (74.95 KiB) 查看 872 次
liheng 回复于:2007-09-17 15:51:20

看来还是 chdir maildir failed 的问题。
但我的服务器上,邮件存放目录确实是存在 maildir 的,之前我用 postfixadmin 做的时候,怎么样都没法生成 maildir 格式的路径, postfixadmin 生成的路径格式是:/var/mailbox/test.com/test/ (注: /var/mailbox 是指定的邮箱存放目录)
我现在用 extmail 生成的 maildir 格式是:/var/mailbox/test.com/test/Maildir
之前用 postfixadmin 提示是 chdir maildir failed 错误,我就认了,因为确实没有生成指定的格式,但我现在用 extmail 生成了指定的格式,为什么还会提示这样的错误呢?郁闷,
而且 邮箱存放目录下的文件所有者都是 postfix ,权限都是600,有写的权限应该来说就可以了吧

[ 本帖最后由 liheng 于 2007-9-17 15:52 编辑 ]

marion 回复于:2007-09-17 16:01:53

do not list domain test.com in BOTH mydestination and virtual_mailbox_domains
这里说无论是本地域还是虚拟域都找不到你指向的test.com,请检查配置。

SASL LOGIN authentication failed: authentication failure
这里说你的SASL_LOGIN认证失败,请检查sasl的安装,以及postfix中指定的认证选项。

alias database unavailable
这里说找不到别名文件,请检查你的配置文件中别名文件的指向,以及它们是否存在。

这些都是问题……

marion 回复于:2007-09-17 16:10:21

再使用outlook发信一次,把相关日志发上来。

这里的问题不是认证没有通过的话,就应该还是权限的问题。再去看看courier-imap的相关设置。

liheng 回复于:2007-09-17 16:39:54

引用:do not list domain test.com in BOTH mydestination and virtual_mailbox_domains
这里说无论是本地域还是虚拟域都找不到你指向的test.com,请检查配置。

这个问题已经解决,将 mydestination 注释或设置为空即可,见:http://www.extmail.org/forum/viewthread.php?tid=5694&extra=page%3D1%26amp%3Bfilter%3Dtype%26amp%3Btypeid%3D1&page=1
引用:SASL LOGIN authentication failed: authentication failure
这里说你的SASL_LOGIN认证失败,请检查sasl的安装,以及postfix中指定的认证选项。
应该不存在 sasl 验证的问题,因为我 telnet localhost 25 成功,而且在 outlook 里发信成功,我是勾了我的服务器发送需要验证这一项的。
引用:alias database unavailable
这里说找不到别名文件,请检查你的配置文件中别名文件的指向,以及它们是否存在。

这个应该还是虚拟域与本地域相冲突导致,我的机器名与 /etc/postfix/main.cf 文件里的 myhostname 设置的不一样,可能是这个引起的。

liheng 回复于:2007-09-17 16:45:29

引用:Sep 17 16:04:56 redhat pop3d: chdir Maildir: No such file or directory
Sep 17 16:04:57 redhat pop3d: Connection, ip=[192.168.0.145]
Sep 17 16:04:57 redhat pop3d: chdir Maildir: No such file or directory
Sep 17 16:17:40 redhat postfix/smtpd[4481]: connect from unknown[192.168.0.145]
Sep 17 16:17:40 redhat postfix/smtpd[4481]: 434823F583: client=unknown[192.168.0.145], sasl_method=LOGIN, sasl_username=test@test.com
Sep 17 16:17:40 redhat postfix/cleanup[4488]: 434823F583: message-id=<007101c7f906$8135b890$9100a8c0@xp>
Sep 17 16:17:40 redhat postfix/qmgr[4275]: 434823F583: from=<test@test.com>, size=1395, nrcpt=1 (queue active)
Sep 17 16:17:40 redhat postfix/smtpd[4481]: disconnect from unknown[192.168.0.145]
Sep 17 16:17:40 redhat postfix/virtual[4490]: 434823F583: to=<test@test.com>, relay=virtual, delay=0.22, delays=0.15/0.05/0/0.02, dsn=2.0.0, status=sent (delivered to maildir)
Sep 17 16:17:40 redhat postfix/qmgr[4275]: 434823F583: removed

我刚刚在 outlook 发邮件的 maillog,
我在 outlook 收邮件的时候,就提示:
引用:Sep 17 16:04:56 redhat pop3d: chdir Maildir: No such file or directory
Sep 17 16:04:57 redhat pop3d: Connection, ip=[192.168.0.145]
Sep 17 16:04:57 redhat pop3d: chdir Maildir: No such file or directory
Sep 17 16:17:40 redhat postfix/smtpd[4481]: connect from unknown[192.168.0.145]



marion 回复于:2007-09-17 17:07:19

如果使用webmail可以收发邮件,但outlook就能发却不能收,这应该是没有道理的。
不知道有没有其他人遇到过这样的情况。我这里只能凭猜测了。

你把mydestination和myorigion的值启用并改为其它域名试试……

另外,如果你的系统中的确有test用户的话,也建议先关闭他。

liheng 回复于:2007-09-17 17:18:32

不行,在 outlook 里一接受邮件,就会弹出一个对话框,要输入用户名和密码
看来我还遇到了一个大问题,这很好

liheng 回复于:2007-09-17 17:19:06

另,我的系统中压根就不存在 test 这个用户

marion 回复于:2007-09-17 17:29:55

先说明,这不是什么大问题,可能仅仅是你某个设置的问题。这是一个有些繁杂的系统,中间可能会因为输入不慎等各种情况而出现许多难以预料的问题。希望你对整个安装过程以及所涉及到的操作是理解的。

建议认真查看一下认证模块是否正常,尤其是courier-imap能否正常使用认证功能。个人觉得问题应该在于SASL的认证模块。

liheng 回复于:2007-09-17 17:30:00

是啊,我也觉得很奇怪,为什么 web 收发没有任何问题,而 outlook 就是不行呢?

liheng 回复于:2007-09-17 22:33:19

marion 兄,我可能已经找到 chdri maildir failed 错误的原因啦
可能是我更改 /usr/local/courier-authlib/etc/authlib/authmysqlrc 文件有空格引起,我消除这个错误,再测试,现在的错误是:
引用:Sep 17 22:06:45 redhat pop3d: authentication error: Input/output error
Sep 17 22:06:47 redhat pop3d: Connection, ip=[192.168.0.145]
Sep 17 22:06:47 redhat pop3d: LOGIN FAILED, user=test@test.com, ip=[192.168.0.145]
Sep 17 22:06:47 redhat pop3d: authentication error: Input/output error
Sep 17 22:06:47 redhat pop3d: Connection, ip=[192.168.0.145]
Sep 17 22:06:47 redhat pop3d: LOGIN FAILED, user=test@test.com, ip=[192.168.0.145]
Sep 17 22:06:47 redhat pop3d: authentication error: Input/output error
Sep 17 22:06:48 redhat pop3d: Connection, ip=[192.168.0.145]
Sep 17 22:06:48 redhat pop3d: LOGIN FAILED, user=test@yoyo.com, ip=[192.168.0.145]
Sep 17 22:06:48 redhat pop3d: authentication error: Input/output error


liheng 回复于:2007-09-17 22:46:01

marion 老兄,我终于找到问题了,
成功啦,成功啦,现在终于可以在 outlook 上收发邮件了

marion 回复于:2007-09-17 22:54:30

祝贺你!

说出你的问题和解决办法,供后来者参考吧。

liheng 回复于:2007-09-17 23:19:51

其实问题的根源很简单,就是出在 authmysqlrc 文件里头,这个文件要求还真严格,一点空格都不能有,就因为有一个空格,导致无法识别 maildir,
1.出现authentication error: Input/output error错误的时候
估计是查询mysql时,authdaemond出错了。具体要打开authdaemonrc里的:

DEBUG_LOGIN=2 原来默认是0

然后看看/var/log/message或/var/log/maillog 在认证失败时有什么提示。根据提示去检查问题到底出在哪儿
后面的问题就好解决了

liheng 回复于:2007-09-18 00:20:20

非常感谢 marion 老兄一直以来对我的热心帮助,没有你的热心帮助,我想我没有这么快找到问题,谢谢:)

titus0719 回复于:2007-09-18 12:09:16

我安装的extman登录界面无法显示校验码,应该怎么处理呢?

marion 回复于:2007-09-18 12:50:51

校验码需要perl-GD模块的支持。

如果想简单,到这里下一个适合你的系统平台的perl-GD包,而后安装即可。
http://dries.ulyssis.org/rpm/packages/perl-GD/info.html

如下:

[ 本帖最后由 marion 于 2007-9-18 13:00 编辑 ]
截图_2025-11-15_14-40-34.jpg
截图_2025-11-15_14-40-34.jpg (86.46 KiB) 查看 871 次
liheng 回复于:2007-09-18 15:50:56

引用:Sep 18 15:39:55 test pop3d: Connection, ip=[192.168.101.224]
Sep 18 15:39:55 test authdaemond: received auth request, service=pop3, authtype=login

Sep 18 15:39:55 test authdaemond: authmysql: trying this module
Sep 18 15:39:55 test authdaemond: SQL query: SELECT username, password, "", '503', '503', '/var/mailbox/', concat('/var/mailbox/',Maildir), "", name, "" FROM mailbox WHERE username = "test"

Sep 18 15:39:55 test pop3d: LOGIN FAILED, user=test, ip=[192.168.101.224]
Sep 18 15:39:55 test authdaemond: zero rows returned
Sep 18 15:39:55 test authdaemond: no password available to compare
Sep 18 15:39:55 test authdaemond: authmysql: REJECT - try next module
Sep 18 15:39: authdaemond: FAIL, all modules rejected
Sep 18 15:40:00 test pop3d: Disconnected, ip=[192.168.101.224

这个问题怎么解决?不想重新装。

[ 本帖最后由 liheng 于 2007-9-18 15:55 编辑 ]

liheng 回复于:2007-09-18 15:54:04

引用:原帖由 titus0719 于 2007-9-18 12:09 发表
我安装的extman登录界面无法显示校验码,应该怎么处理呢?

最简单的方法,不要校验码,听说那个核验码还比较麻烦,我就将它去掉了,
在 webman.cf 将 SYS_CAPTCHA_ON=0 即可,记得要重启 Apache 哦

marion 回复于:2007-09-18 18:30:50

Sep 18 15:39:55 test pop3d: LOGIN FAILED, user=test, ip=[192.168.101.224]

恐怕是这儿的问题,你尝试指定全名,即形如“[email]user@domain.ltd[/email]”试试。

marion 回复于:2007-09-18 19:12:20

引用:原帖由 liheng 于 2007-9-18 15:54 发表 [url=http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=7367646&ptid=987344]

最简单的方法,不要校验码,听说那个核验码还比较麻烦,我就将它去掉了,
在 webman.cf 将 SYS_CAPTCHA_ON=0 即可,记得要重启 Apache 哦


如果在实际使用中,这个决非上策。其实,即便是修改这个,也用不着重启apache的,刷新一下页面就OK了。

[ 本帖最后由 marion 于 2007-9-18 21:04 编辑 ]

liheng 回复于:2007-09-18 23:11:31

引用:原帖由 marion 于 2007-9-18 18:30 发表 [url=http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=7368567&ptid=987344]
Sep 18 15:39:55 test pop3d: LOGIN FAILED, user=test, ip=[192.168.101.224]

恐怕是这儿的问题,你尝试指定全名,即形如“[email]user@domain.ltd[/email]”试试。

marion 兄,我猜想也是这里的问题,刚开始还没反映过来,还没想明白应该在哪里改。刚刚终于想通了。
事后经过确认确实也是这里的问题,
解决方法:
在 outlook 里的帐号名写全([email]test@test.com[/email])就OK了,marion 兄,你真棒:em02:

liheng 回复于:2007-09-18 23:13:08

顺便现问一下 marion 兄,那有没有办法,不用写全也行的呢?

marion 回复于:2007-09-19 01:15:57

终于写完了,可以长出一口气了!

我会不断的修正和完善此文,欢迎各位继续测试使用和点评!

loveflag 回复于:2007-09-19 16:10:20

楼主,什么也不说了。 潜心搜藏研究。

绝对是网络上最新,最全面的中文架设邮件服务器的笔记了。

赞楼主一个

loveflag 回复于:2007-09-20 12:34:34

[root@localhost init.d]# service postfix restart
关闭 postfix: [确定]
启动 postfix: [确定]
[root@localhost init.d]# telnet localhost 25
Trying 127.0.0.1...
Connected to localhost.localdomain (127.0.0.1).
Escape character is '^]'.
Connection closed by foreign host.
[root@localhost init.d]#
[root@localhost init.d]# vim /etc/postfix/main.cf

myhostname = mail.loveflag.cn
myorigin = loveflag.cn
mydomain = loveflag.cn
mydestination = $myhostname, localhost.$mydomain, localhost, $mydomain
mynetworks = 192.168.0.249/24, 127.0.0.0/8

为何?25端口没有连上呢?

marion 回复于:2007-09-20 13:24:45

mynetworks = 192.168.0.249/24

这一个写作这样,恐怕不太合适吧。

另,你应该把相关日志的内容发上来。

loveflag 回复于:2007-09-20 14:15:03

楼主,我是新手。能否告诉我下,把哪里的日志帖上来。 我的网络环境是内网。

marion 回复于:2007-09-20 14:18:26

引用:原帖由 loveflag 于 2007-9-20 14:15 发表 [url=http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=7378216&ptid=987344]http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=7378216&ptid=987344

楼主,我是新手。能否告诉我下,把哪里的日志帖上来。 我的网络环境是内网。


重新telnet 25号端口一次,而后把/var/log/maillog日志的最新出现的内容贴上来,可以借鉴以下命令:

#tail -20 /var/log/mail

loveflag 回复于:2007-09-20 14:26:39

[root@localhost ~]# telnet 127.0.0.1 25
Trying 127.0.0.1...
Connected to localhost.localdomain (127.0.0.1).
Escape character is '^]'.
220 mail.loveflag.cn ESMTP Postfix
ehlo mail.loveflag.cn
250-mail.loveflag.cn
250-PIPELINING
250-SIZE 10240000
250-VRFY
250-ETRN
250-ENHANCEDSTATUSCODES
250-8BITMIME
250 DSN
mail from:root@loveflag.cn
250 2.1.0 Ok
rcpt to:pieradmin@loveflag.cn
250 2.1.5 Ok
data
354 End data with <CR><LF>.<CR><LF>
subject:Mail test!
Mail test!@!!!
.
250 2.0.0 Ok: queued as 1F2E1145CA0
quit
221 2.0.0 Bye
Connection closed by foreign host.
[root@localhost ~]#

marion 回复于:2007-09-20 15:24:17

这个表示已经发送了,你再检查一下日志看一下结果

zhushuyun 回复于:2007-09-21 13:53:44

好全面的东西, 好呀 收下了 谢谢了!:em02: :em02: :em02: :em02: :em02: :em02: :em02: :em02: :em02:

marion 回复于:2007-09-24 21:35:11

本来近日想把SSL应用的部分加上,看来要等几天了,被snort的项目的耽搁了。仍然待续吧:mrgreen: ……

liwei6998 回复于:2007-09-25 16:09:11

marion ,高手,牛人,向marion 表示由衷的感谢!!!

marion 回复于:2007-09-26 22:12:55

楼上的兄弟,多承谬赞,共同学习吧……

惠繪洋 回复于:2007-09-27 13:55:59

請教樓主..
我跟著做暫時還沒有出現什麼大錯誤. 先謝過.
但現在我有一個問題想請問, 我這台機並沒有一個固定域名的. 如你的 benet.org, 我現在整個環境都是在內網完成的. 而在裝到 extmail, 我就把 extmail 的httpd.conf 設定如下:


<VirtualHost *:80>

ServerName mail.xxx.com

ServerAlias 192.168.0.191

DocumentRoot /var/www/extsuite/extmail/html/

ScriptAlias /webmail/cgi /var/www/extsuite/extmail/cgi

Alias /webmail /var/www/extsuite/extmail/html

</VirtualHost>



但當輸入 http://192.168.0.191/webmail/ 時, 就出現

403 Forbidden

You don't have permission to access / on this server.



這台服務器日後會在內網運行, 以port forward 在firewall 後運作的. 請指教.
謝謝.

[ 本帖最后由 惠繪洋 于 2007-9-27 13:59 编辑 ]

Intranet 回复于:2007-09-27 15:31:35

有没有这些软件打包下载?

CentOS 5 安装的时候都装哪些包?

fuleru 回复于:2007-09-27 16:03:35

我在编译courier-imap遇到了些问题,请问是什么原因?

Making all in tcpd
make[2]: Entering directory `/root/postfix/courier-imap-4.1.3/tcpd'
make all-am
make[3]: Entering directory `/root/postfix/courier-imap-4.1.3/tcpd'
Linking couriertls
./.libs/libcouriertls.a(libcouriertls.o)(.text+0xd52): In function `tls_create':
/root/postfix/courier-imap-4.1.3/tcpd/libcouriertls.c:590: undefined reference to `SSL_CTX_sess_set_new_cb'
./.libs/libcouriertls.a(libcouriertls.o)(.text+0xd63):/root/postfix/courier-imap-4.1.3/tcpd/libcouriertls.c:591: undefined reference to `SSL_CTX_sess_set_get_cb'
./.libs/libcouriertls.a(libcouriertls.o)(.text+0xd74):/root/postfix/courier-imap-4.1.3/tcpd/libcouriertls.c:592: undefined reference to `SSL_CTX_sess_set_remove_cb'
collect2: ld returned 1 exit status
make[3]: *** [couriertls] Error 1
make[3]: Leaving directory `/root/postfix/courier-imap-4.1.3/tcpd'
make[2]: *** [all] Error 2
make[2]: Leaving directory `/root/postfix/courier-imap-4.1.3/tcpd'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/root/postfix/courier-imap-4.1.3'
make: *** [all] Error 2

这与ssl有关么?

marion 回复于:2007-09-27 17:52:48

回fuleru,
你的问题应该是因为编译安装的openssl的头文件链接指定问题。默认情况下,courier-imap编译时到/usr/include下查找openssl的头文件,你检查一下并确保新装的openssl头文件的链接是指向的新版本应该可以解决这个问题。

[ 本帖最后由 marion 于 2007-9-27 17:58 编辑 ]

marion 回复于:2007-09-27 17:58:00

这个问题应该是apache目录访问权限的问题,请确保你的apache主配置文件中开放了对/var/www目录的访问权限。你可以通过更改DocumentRoot指令后,及<Directory "/var/www">来实现;

惠繪洋 回复于:2007-09-28 12:27:15

引用:原帖由 marion 于 2007-9-27 17:58 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=7411437&ptid=987344
这个问题应该是apache目录访问权限的问题,请确保你的apache主配置文件中开放了对/var/www目录的访问权限。你可以通过更改DocumentRoot指令后,及来实现;


謝謝.
對. apache 的設定我弄傻了... 現在可以了...

但又有一事想請教. 我在 extman 內新建了一個domain, 在內也加入了user
用extmail 登入, 再寄信給自己時, 就發現不能收信.

查了 maillog 如下:

Sep 28 12:34:54 mail extmail[1957]: user=<danny@mydomain.org>, client=192.168.80.182, module=login, status=loginok

Sep 28 12:37:04 mail extmail[1965]: user=<danny@mydomain.org>, client=192.168.80.182, module=login, status=loginok

Sep 28 12:38:27 mail postfix/pickup[1681]: D00A5FA12: uid=2525 from=<danny@mydomain.org>

Sep 28 12:38:27 mail postfix/cleanup[1994]: D00A5FA12: message-id=<20070928043827.D00A5FA12@mydomain.org>

Sep 28 12:38:28 mail postfix/qmgr[1682]: D00A5FA12: from=<danny@mydomain.org>, size=504, nrcpt=1 (queue active)

Sep 28 12:38:28 mail postfix/trivial-rewrite[1996]: warning: do not list domain mydomain.org in BOTH mydestination and virtual_mailbox_domains

Sep 28 12:38:28 mail postfix/local[1999]: warning: dict_nis_init: NIS domain name not set - NIS lookups disabled

Sep 28 12:38:30 mail postfix/local[1999]: D00A5FA12: to=<danny@mydomain.org>, relay=local, delay=2.5, delays=0.48/0.47/0/1.6, dsn=5.1.1, status=bounced (unknown user: "danny")

Sep 28 12:38:30 mail postfix/cleanup[1994]: 246CBFA17: message-id=<20070928043830.246CBFA17@mydomain.org>

Sep 28 12:38:30 mail postfix/qmgr[1682]: 246CBFA17: from=<>, size=2240, nrcpt=1 (queue active)

Sep 28 12:38:30 mail postfix/trivial-rewrite[1996]: warning: do not list domain mydomain.org in BOTH mydestination and virtual_mailbox_domains

Sep 28 12:38:30 mail postfix/bounce[2000]: D00A5FA12: sender non-delivery notification: 246CBFA17

Sep 28 12:38:30 mail postfix/qmgr[1682]: D00A5FA12: removed

Sep 28 12:38:30 mail postfix/local[1999]: 246CBFA17: to=<danny@mydomain.org>, relay=local, delay=0.02, delays=0.01/0/0/0.01, dsn=5.1.1, status=bounced (unknown user: "danny")

Sep 28 12:38:30 mail postfix/qmgr[1682]: 246CBFA17: removed

Sep 28 12:42:09 mail postfix/smtpd[2013]: warning: dict_nis_init: NIS domain name not set - NIS lookups disabled

Sep 28 12:42:09 mail postfix/smtpd[2013]: connect from localhost[127.0.0.1]

Sep 28 12:43:06 mail postfix/trivial-rewrite[2015]: warning: do not list domain mydomain.org in BOTH mydestination and virtual_mailbox_domains

Sep 28 12:43:14 mail postfix/smtpd[2013]: NOQUEUE: reject: RCPT from localhost[127.0.0.1]: 550 5.1.1 <danny@mydomain.org>: Recipient address rejected: User unknown in local recipient table; from=<danny@mydomain.org> to=<danny@mydomain.org> proto=ESMTP helo=<mydomain.org>

Sep 28 12:46:54 mail postfix/smtpd[2013]: disconnect from localhost[127.0.0.1]




再用 telnet localhost 25 查看

root@mail:/var/spool/mail# telnet localhost 25

Trying 127.0.0.1...

Connected to localhost.

Escape character is '^]'.

220 Welcome to our mydomain.org ESMTP,Warning: Version not Available!

ehlo mydomain.org

250-mydomain.org

250-PIPELINING

250-SIZE 14336000

250-VRFY

250-ETRN

250-AUTH LOGIN PLAIN

250-AUTH=LOGIN PLAIN

250-ENHANCEDSTATUSCODES

250-8BITMIME

250 DSN

mail from:danny@mydomain.org

250 2.1.0 Ok

rcpt to:danny@mydomain.org

550 5.1.1 <danny@mydomain.org>: Recipient address rejected: User unknown in local recipient table



請問這是什麼原因做成的呢. 請指教. 謝謝.

[ 本帖最后由 惠繪洋 于 2007-9-28 12:48 编辑 ]

marion 回复于:2007-09-28 14:59:44

Sep 28 12:38:30 mail postfix/trivial-rewrite[1996]: warning: do not list domain mydomain.org in BOTH mydestination and virtual_mailbox_domains
……
550 5.1.1 <danny@mydomain.org>: Recipient address rejected: User unknown in local recipient

以上这些应该表明错误的原因是你的postfix配置对于访问mysql数据库不正确而不能检索到相关域的信息造成的;或者你的extman建立的域名没能正确写入数据库也未可知,但前者的可能性更大,请检查一下main.cf文件中设定的对mysql访问的部分。

当然,做这些假设的前提是你的数据库本身配置是正确的。

[ 本帖最后由 marion 于 2007-9-28 15:00 编辑 ]

惠繪洋 回复于:2007-09-28 17:16:46

引用:
以上这些应该表明错误的原因是你的postfix配置对于访问mysql数据库不正确而不能检索到相关域的信息造成的;或者你的extman建立的域名没能正确写入数据库也未可知,但前者的可能性更大,请检查一下main.cf文件中设定的对mysql访问的部分。

当然,做这些假设的前提是你的数据库本身配置是正确的。



謝謝你的指示, 我檢查了 mysql, extmail 內已經有我所開啟的 email address, 所有東西都在, 應該extman 已經正確地和mysql 聯繫.
我也用 extmail 登入 mysql 也可以.
我再查看 postfix 的 /etc/postfix/main.cf 的設置. 由於網域不方便公開, 所以只好用 mydomain.org 代替.

queue_directory = /var/spool/postfix

command_directory = /usr/local/postfix/sbin

daemon_directory = /usr/local/postfix/libexec

mail_owner = postfix

myhostname = mail.mydomain.org

mydomain = mydomain.org

myorigin = mydomain.org

inet_interfaces = all

#mydestination = $myhostname, localhost.$mydomain, localhost, $mydomain

unknown_local_recipient_reject_code = 550

debug_peer_level = 2

debugger_command =

PATH=/bin:/usr/bin:/usr/local/bin:/usr/X11R6/bin

xxgdb $daemon_directory/$process_name $process_id & sleep 5

sendmail_path = /usr/sbin/sendmail

newaliases_path = /usr/bin/newaliases

mailq_path = /usr/bin/mailq

setgid_group = postdrop

html_directory = /var/www/html/postfix_html

manpage_directory = /usr/local/postfix/man

sample_directory = /etc/postfix

readme_directory = no

broken_sasl_auth_clients = yes

smtpd_recipient_restrictions=permit_mynetworks,permit_sasl_authenticated,reject_invalid_hostname,reject_non_fqdn_hostname,reject_unknown_sender_domain,reject_non_fqdn_sender,reject_non_fqdn_recipient,reject_unknown_recipient_domain,reject_unauth_pipelining,reject_unauth_destination

smtpd_sasl_auth_enable = yes

smtpd_sasl_local_domain = $myhostname

smtpd_sasl_security_options = noanonymous

smtpd_sasl_application_name = smtpd

smtpd_banner = Welcome to our $myhostname ESMTP,Warning: Version not Available!

virtual_mailbox_base = /var/mailbox

virtual_mailbox_maps = mysql:/etc/postfix/mysql_virtual_mailbox_maps.cf

virtual_mailbox_domains = mysql:/etc/postfix/mysql_virtual_domains_maps.cf

virtual_alias_domains =

virtual_alias_maps = mysql:/etc/postfix/mysql_virtual_alias_maps.cf

virtual_uid_maps = static:2525

virtual_gid_maps = static:2525

virtual_transport = virtual

maildrop_destination_recipient_limit = 1

maildrop_destination_concurrency_limit = 1

message_size_limit = 14336000

virtual_mailbox_limit = 20971520

virtual_create_maildirsize = yes

virtual_mailbox_extended = yes

virtual_mailbox_limit_maps = mysql:/etc/postfix/mysql_virtual_mailbox_limit_maps.cf

virtual_mailbox_limit_override = yes

virtual_maildir_limit_message = Sorry, the user's maildir has overdrawn his diskspace quota, please Tidy your mailbox and try again later.

virtual_overquota_bounce = yes



我也查看過

/etc/postfix/mysql_virtual_alias_maps.cf

/etc/postfix/mysql_virtual_domains_maps.cf

/etc/postfix/mysql_virtual_mailbox_limit_maps.cf

/etc/postfix/mysql_virtual_mailbox_maps.cf



入邊的 mysql user, pass, db, table 都正確呢...

但當中發現了一個問題. 在 main.cf 內 virtual_mailbox_base 是指向 /var/mailbox, 但真實的的是 /var/spool/mail 內呢... 這需要更正嗎??

查看了好幾編都找不出問題.. 請樓主幫忙幫忙.. 謝謝你.

marion 回复于:2007-09-28 21:25:42

嗯,应该就是这里的问题了;
让它们统一起来即可,改成哪个由你自己决定。

marion 回复于:2007-10-01 15:19:41

这里所提到的UID和GID,应该是MDA用户的;在前面使用的postfix自带的MDA,故此指定为2525;后面使用了maildrop这个MDA,因此,把其改为了VMAIL用户的UID和GID。

后面的那个确如你所料,第一个和第三个是MYSQL中的字段名;

MYSQLER 回复于:2007-10-02 14:17:55

如果有各个安装包的地址是不是更方便一些:em10:

Intranet 回复于:2007-10-03 13:01:31


[root@mail /]# cp support-files/my-medium.cnf /etc/my.cnf

cp: cannot stat `support-files/my-medium.cnf': No such file or directory




[root@mail mysql-5.0.45]# cp support/mysql.server /etc/rc.d/init.d/mysqld

cp: cannot stat `support/mysql.server': No such file or directory





是下的mysql版本不对吗?

目录下的文件就这些:


:shock: :shock:

[ 本帖最后由 Intranet 于 2007-10-3 13:05 编辑 ]
截图_2025-11-15_14-45-36.jpg
截图_2025-11-15_14-45-36.jpg (63.5 KiB) 查看 870 次
Intranet 回复于:2007-10-03 13:20:34

为什么出错。

停在那里就不动了。。

[ 本帖最后由 Intranet 于 2007-10-3 13:22 编辑 ]
截图_2025-11-15_14-47-56.jpg
截图_2025-11-15_14-47-56.jpg (53.92 KiB) 查看 869 次
marion 回复于:2007-10-03 22:26:28

这个不是什么错误,只是调试启动而已;你可以Ctrl+C退出后去掉"-d"选项后重新启动即可。

bigbomb 回复于:2007-10-05 16:02:21

不知道这个版本能不能在机器上真正实现得了,不管怎地,lz的辛勤劳动值得称颂,我顶:em03: :em03: :em03: :em03:

marion 回复于:2007-10-05 17:30:26

我这里有个服务器已经在Internet上用了……

willl32 回复于:2007-10-06 19:52:02

很详细啊! 我准备把sendmail改成postfix,正需要这个文章。谢谢楼主兄弟!

ypxns 回复于:2007-10-07 10:01:00

marion兄,我参照你的文档,在进行POSTFIX验证的时候出现了问题,你能不能帮我看一下!谢谢了!!
http://bbs.chinaunix.net/thread-998862-1-1.html

zdyldy 回复于:2007-10-08 09:31:07

courier-imap-4.1.3.tar.bz2



这个软件包在哪下载啊,

可以把其它的软件包地址都发到上面么?


在网上好多搜不到啊,谢谢了。

zdyldy 回复于:2007-10-08 09:46:41

十一、安装Courier-IMAP

# tar jxvf courier-imap-4.1.3.tar.bz2
# cd courier-imap-4.1.3
./configure
--prefix=/usr/local/courier-imap
--with-redhat
--enable-unicode
--disable-root-check
--with-trashquota
--without-ipv6


请问 --without-ipv6 是什么意思。现在我用的是IP-V4啊,我该怎么写。

marion 回复于:2007-10-08 10:48:37

那个选项是指示你的编译不使用ipv6,如果你没有使用ipv6,加上此选项就可以。

zdyldy 回复于:2007-10-08 12:28:49

courier-imap-4.1.3
Postfix-2.4.5
Mysql-5.0.45
Sasl-2.1.22
clamav-0.91.2
amavisd-new
SpamAssassin-3.2.3

按照你的帖子,可不可以只安装上面7个,下面8个不安装呢,如果可以是不是要做一些改动呢。还有麻烦告诉这些软件包的下载地址好么,我在网上搜不到啊。



DB-4.5.20
Openssl-0.98e
httpd-2.2.4
Php-5.2.3
courier-authlib-0.59.3
Extmail-1.0.2
Extman-0.2.2
maildrop-2.0.4

zdyldy 回复于:2007-10-08 13:06:44

[root@localhost servers]# cd courier-imap-4.1.0
[root@localhost courier-imap-4.1.0]# ./configure --prefix=/usr/local/courier-imap --with-redhat --enable-unicode --disable-root-check --with-trashquota --without-ipv6 CPPFLAGS='-I/usr/local/ssl/include/openssl -I/usr/local/courier-authlib/include' LDFLAGS='-L/usr/local/courier-authlib/lib/courier-authlib' COURIERAUTHCONFIG='/usr/local/courier-authlib/bin/courierauthconfig'
checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking for gawk... gawk
checking whether make sets $(MAKE)... yes
checking for gcc... gcc
checking for C compiler default output file name... a.out
checking whether the C compiler works... yes
checking whether we are cross compiling... no
checking for suffix of executables...
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether gcc accepts -g... yes
checking for gcc option to accept ANSI C... none needed
checking for style of include used by make... GNU
checking dependency style of gcc... gcc3
checking for gawk... (cached) gawk
checking for a BSD-compatible install... /usr/bin/install -c
checking whether ln -s works... yes
checking whether make sets $(MAKE)... (cached) yes
checking for perl5... no
checking for perl... /usr/bin/perl
checking for sysconftool...... ././sysconftool
checking build system type... i686-redhat-linux-gnu
checking host system type... i686-redhat-linux-gnu
checking for a sed that does not truncate output... /bin/sed
checking for egrep... grep -E
checking for ld used by gcc... /usr/bin/ld
checking if the linker (/usr/bin/ld) is GNU ld... yes
checking for /usr/bin/ld option to reload object files... -r
checking for BSD-compatible nm... /usr/bin/nm -B
checking how to recognise dependent libraries... pass_all
checking how to run the C preprocessor... gcc -E
checking for ANSI C header files... yes
checking for sys/types.h... yes
checking for sys/stat.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for memory.h... yes
checking for strings.h... yes
checking for inttypes.h... yes
checking for stdint.h... yes
checking for unistd.h... yes
checking dlfcn.h usability... yes
checking dlfcn.h presence... yes
checking for dlfcn.h... yes
checking for g++... g++
checking whether we are using the GNU C++ compiler... yes
checking whether g++ accepts -g... yes
checking dependency style of g++... gcc3
checking how to run the C++ preprocessor... g++ -E
checking for g77... g77
checking whether we are using the GNU Fortran 77 compiler... yes
checking whether g77 accepts -g... yes
checking the maximum length of command line arguments... 32768
checking command to parse /usr/bin/nm -B output from gcc object... ok
checking for objdir... .libs
checking for ar... ar
checking for ranlib... ranlib
checking for strip... strip
checking if gcc static flag works... yes
checking if gcc supports -fno-rtti -fno-exceptions... no
checking for gcc option to produce PIC... -fPIC
checking if gcc PIC flag -fPIC works... yes
checking if gcc supports -c -o file.o... yes
checking whether the gcc linker (/usr/bin/ld) supports shared libraries... yes
checking whether -lc should be explicitly linked in... no
checking dynamic linker characteristics... GNU/Linux ld.so
checking how to hardcode library paths into programs... immediate
checking whether stripping libraries is possible... yes
checking for shl_load... no
checking for shl_load in -ldld... no
checking for dlopen... no
checking for dlopen in -ldl... yes
checking whether a program can dlopen itself... yes
checking whether a statically linked program can dlopen itself... yes
checking if libtool supports shared libraries... yes
checking whether to build shared libraries... yes
checking whether to build static libraries... yes
configure: creating libtool
appending configuration tag "CXX" to libtool
checking for ld used by g++... /usr/bin/ld
checking if the linker (/usr/bin/ld) is GNU ld... yes
checking whether the g++ linker (/usr/bin/ld) supports shared libraries... yes
checking for g++ option to produce PIC... -fPIC
checking if g++ PIC flag -fPIC works... yes
checking if g++ supports -c -o file.o... yes
checking whether the g++ linker (/usr/bin/ld) supports shared libraries... yes
checking dynamic linker characteristics... GNU/Linux ld.so
checking how to hardcode library paths into programs... immediate
checking whether stripping libraries is possible... yes
checking for shl_load... (cached) no
checking for shl_load in -ldld... (cached) no
checking for dlopen... (cached) no
checking for dlopen in -ldl... (cached) yes
checking whether a program can dlopen itself... (cached) yes
checking whether a statically linked program can dlopen itself... (cached) yes
appending configuration tag "F77" to libtool
checking if libtool supports shared libraries... yes
checking whether to build shared libraries... yes
checking whether to build static libraries... yes
checking for g77 option to produce PIC... -fPIC
checking if g77 PIC flag -fPIC works... yes
checking if g77 supports -c -o file.o... yes
checking whether the g77 linker (/usr/bin/ld) supports shared libraries... yes
checking dynamic linker characteristics... GNU/Linux ld.so
checking how to hardcode library paths into programs... immediate
checking whether stripping libraries is possible... yes
checking for env... /bin/env
checking for courierauthconfig... /usr/local/courier-authlib/bin/courierauthconfig
./configure: line 20078: /usr/local/courier-authlib/bin/courierauthconfig: No such file or directory
./configure: line 20078: test: =: unary operator expected
./configure: line 20085: /usr/local/courier-authlib/bin/courierauthconfig: No such file or directory
[root@localhost courier-imap-4.1.0]# make
make: *** 没有指明目标并且找不到 makefile。 停止。
[root@localhost courier-imap-4.1.0]#

您好,我没找到4.1.3 ,只在网上找到了4.1.0,当我按照你的步骤执行 ./configure 后,再执行make 的时候出现上面的提示,是怎么回事啊。

fish007 回复于:2007-10-09 08:43:08

引用:原帖由 marion 于 2007-9-6 18:31 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=7317388&ptid=987344
本文凝聚了作者不少的安装经验,写出来供各位同仁参考指正,也为自己留一个“备份”,以便以后安装时作为参照!
安装过程中借鉴了不少google出来的文章,是你们先行的足迹为作者今天的成功打下了基础,在此先行 ...


你好,我在用以下命令对courier-authlib-0.5.93进行configure时,进入了循环,无休止地进行下去,不知是何原因,望解答.
./configure
--prefix=/usr/local/courier-authlib
--sysconfdir=/etc
--without-authpam
--without-authldap
--without-authpwd
--without-authshadow
--without-authvchkpw
--without-authpgsql
--with-authmysql
--with-mysql-libs=/usr/local/mysql/lib/mysql
--with-mysql-includes=/usr/local/mysql/inculde/mysql
--with-redhat
--with-authmysqlrc=/etc/authmysqlrc
--with-authdaemonrc=/etc/authdaemonrc
CFLAGS="-march=i686 -O2 -fexpensive-optimizations"
CXXFLAGS="-march=i686 -O2 -fexpensive-optimizations"

fish007 回复于:2007-10-09 08:49:35

引用:原帖由 fish007 于 2007-10-9 08:43 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=7441576&ptid=987344


你好,我在用以下命令对courier-authlib-0.5.93进行configure时,进入了循环,无休止地进行下去,不知是何原因,望解答.
./configure
--prefix=/usr/local/courier-authlib
--sysconfdir=/etc ...

是0.59.3

Intranet 回复于:2007-10-09 15:49:38

引用:DBD-Mysql目前最新的版本为DBD-mysql-4.005,但它和系统中的perl结合使用时会造成extmail无法正常使用,因此我们采用3的版本:
# tar zxvf DBD-mysql-3.0002_4.tar.gz
# cd cd DBD-mysql-3.0002_4
# perl Makefile.PL (此步骤中如果出现类同Can't exec "mysql_config": No such file or directory at Makefile.PL line 76.的错误是因为您的mysql的bin目录没有输出至$PATH环境变量)




...又出错了~~~

CentOS 5下面..

:shock: :shock:
截图_2025-11-15_14-51-06.jpg
截图_2025-11-15_14-51-06.jpg (87.88 KiB) 查看 868 次
Intranet 回复于:2007-10-09 16:17:12

引用:原帖由 zdyldy 于 2007-10-8 09:31 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=7437774&ptid=987344
courier-imap-4.1.3.tar.bz2



这个软件包在哪下载啊,

可以把其它的软件包地址都发到上面么?


在网上好多搜不到啊,谢谢了。



安装包我这里都有,,,但还是没有安装成功...在CentOS 5上.

ftp1.callleo.cn
user&passwd:cu

liheng 回复于:2007-10-09 17:59:24

marion 兄,我是在安装 maildrop 后发生这样的错误
引用:Oct 9 13:29:50 bv-diannao-004 maildrop[13037]: Temporary authentication failure.
Oct 9 13:29:50 bv-diannao-004 postfix/pipe[13036]: 45DFE11CEE5: to=<test@test.com>, relay=maildrop, delay=0.25, delays=0.1/0.05/0/0.1, dsn=4.3.0, status=deferred (temporary failure. Command output: ERR: authdaemon: s_connect() failed: Permission denied /usr/local/bin/maildrop: Temporary authentication failure.

邮件可以发出去,但却接受不了。
引用:Oct 9 17:23:36 bv-diannao-004 pop3d: authentication error: Input/output error
Oct 9 17:23:36 bv-diannao-004 authdaemond: failed to connect to mysql server (server=localhost, userid=extmail..): Access denied for user 'extmail..'@'localhost' (using password: YES)
Oct 9 17:23:36 bv-diannao-004 authdaemond: authmysql: TEMPFAIL - no more modules will be tried

不知道是哪里设置错误了,我也弄不清楚怎么会显示这个,操作步骤与你所写的相同
引用:(server=localhost, userid=extmail..): Access denied for user 'extmail..'@'localhost'

怎么会成这个样子?
还请 marion 指点一二

marion 回复于:2007-10-09 20:56:20

checking for courierauthconfig... /usr/local/courier-authlib/bin/courierauthconfig
./configure: line 20078: /usr/local/courier-authlib/bin/courierauthconfig: No such file or directory
./configure: line 20078: test: =: unary operator expected
./configure: line 20085: /usr/local/courier-authlib/bin/courierauthconfig: No such file or directory

以上几句表明你指向的/usr/local/courier-authlib/bin/courierauthconfig路径不对,或者是文件不存在。请确信你的courier-authlib已经正确安装,并将以下项的值改为其所在你的系统中的路径:
COURIERAUTHCONFIG='/usr/local/courier-authlib/bin/courierauthconfig'

marion 回复于:2007-10-09 21:00:21

不知道你所所谓的无休止大概run了多长时间,或者能不能提供更多的信息过来。不过,如果你的硬件体系不是i686的话,最好将如下两个选项去掉:
CFLAGS="-march=i686 -O2 -fexpensive-optimizations"
CXXFLAGS="-march=i686 -O2 -fexpensive-optimizations"

marion 回复于:2007-10-09 21:05:02

CentOS5的安装光盘上找到并安装 perl-DBI 这个rpm包应该可以解决这个问题……

marion 回复于:2007-10-09 21:11:07

Oct 9 17:23:36 bv-diannao-004 authdaemond: failed to connect to mysql server (server=localhost, userid=extmail..): Access denied for user 'extmail..'@'localhost' (using password: YES)

这里表明你所指定的extmail无法正常访问mysql数据库,你可以去查看一下authmysqlrc文件中的相关设置是否正确,即确保你的extmail用户以权限访问mysql;

如果仍然无法通过验正,你打开authdaemon的相关日志选项,并将登录后的报错信息发上来,我帮你排查一下。

marion 回复于:2007-10-09 21:16:59

引用:安装包我这里都有,,,但还是没有安装成功...在CentOS 5上.

ftp1.callleo.cn
user&passwd:cu


谢兄之高义,我正为难怎么把这些软件包共享出来呢,因为下地址我也没有记录,如果一个个的去重新找一遍也不是件小的工程……

liheng 回复于:2007-10-10 09:45:28

marion 兄,这个已是我将 authdaemonrc 中的 debug_login=2 的 maillog 了引用:Oct 9 17:23:36 bv-diannao-004 pop3d: authentication error: Input/output error
Oct 9 17:23:36 bv-diannao-004 authdaemond: failed to connect to mysql server (server=localhost, userid=extmail..): Access denied for user 'extmail..'@'localhost' (using password: YES)
Oct 9 17:23:36 bv-diannao-004 authdaemond: authmysql: TEMPFAIL - no more modules will be tried


liheng 回复于:2007-10-10 10:00:27

此问题已经解决,是 authmysqlrc 中的 MYSQL_USERNAEM 中的值输入错误:em16:

liheng 回复于:2007-10-10 10:38:56

引用:Oct 9 13:29:50 bv-diannao-004 maildrop[13037]: Temporary authentication failure.
Oct 9 13:29:50 bv-diannao-004 postfix/pipe[13036]: 45DFE11CEE5: to=<test@test.com>, relay=maildrop, delay=0.25, delays=0.1/0.05/0/0.1, dsn=4.3.0, status=deferred (temporary failure. Command output: ERR: authdaemon: s_connect() failed: Permission denied /usr/local/bin/maildrop: Temporary authentication failure.

marion 老兄,不知道这个是什么原因

liheng 回复于:2007-10-10 11:05:57

试过重新编译 authlib,在编译 authlib 时加上了 --with-mailuser & --with-mailgroup 参数,但还是不行.

xiangxiaobao 回复于:2007-10-10 11:07:15

Oct 10 11:02:36 linux-89 postfix/smtpd[12546]: warning: dict_nis_init: NIS domain name not set - NIS lookups disabled
Oct 10 11:02:36 linux-89 postfix/smtpd[12546]: connect from mail.3gpp.com.cn[59.151.37.12]
Oct 10 11:02:36 linux-89 postfix/smtpd[12546]: 18B901C1C5: client=mail.3gpp.com.cn[59.151.37.12]
Oct 10 11:02:36 linux-89 postfix/cleanup[12552]: 18B901C1C5: message-id=<011c01c80ae9$f862a050$ca01a8c0@96DA6A8BDAF141B>
Oct 10 11:02:36 linux-89 postfix/qmgr[12544]: 18B901C1C5: from=<xiangqian@3gpp.com.cn>, size=1620, nrcpt=1 (queue active)
Oct 10 11:02:36 linux-89 postfix/smtpd[12546]: disconnect from mail.3gpp.com.cn[59.151.37.12]
Oct 10 11:02:36 linux-89 postfix/virtual[12554]: 18B901C1C5: to=<t1@3gpp.net.cn>, relay=virtual, delay=0.13, delays=0.08/0/0/0.04, dsn=4.2.0, status=deferred (delivery failed to mailbox /var/mailbox/987/735/t1@3gpp.net.cn: cannot open file: Is a directory)

请问,这是什么原因,都有这些目录,权限也都对!

junger 回复于:2007-10-10 16:04:58

你好!我在你用postfix做的邮件服务器注册的账户,126、163可以向它发信,但不能向163、126发信,并返回
一封标题为Undelivered Mail Returned to Sender邮件,是由 [email]MAILER-DAEMON@mail.xxx.com[/email] (Mail Delivery System)发出,内容是This is the mail system at host mail.xxx.com.

I'm sorry to have to inform you that your message could not
be delivered to one or more recipients. It's attached below.

For further assistance, please send mail to postmaster.

If you do so, please include this problem report. You can
delete your own text from the attached returned message.

The mail system

<xxx@126.com>: connect to 127.0.0.1[127.0.0.1]: Connection refused

希望给解决一下,如果忙给我发邮件或Q我,也行。
我的QQ是648700854.

[ 本帖最后由 junger 于 2007-10-11 08:37 编辑 ]

marion 回复于:2007-10-10 20:39:21

delivery failed to mailbox /var/mailbox/987/735/t1@3gpp.net.cn: cannot open file: Is a directory

这个表明MDA期望t1@3gpp.net.cn应该为一个文件,但给出的却是目录。
建议再去检查一下有关/var/mailbox的设置。

marion 回复于:2007-10-10 20:44:52

引用:原帖由 liheng 于 2007-10-10 10:38 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=7446794&ptid=987344

marion 老兄,不知道这个是什么原因


把debug的级别指定为"1"吧,让信息再详细些,然后发上来日志。

marion 回复于:2007-10-10 20:48:13

我好久没去看过那个服务器了,那只是一个朋友测试性的服务器,关于你提到的问题我会抽时间去看看。不过,好像这会儿是不在线的。

:em02:

[ 本帖最后由 marion 于 2007-10-11 09:39 编辑 ]

cnhawk386 回复于:2007-10-11 08:17:05

1、编辑/etc/postfix/main.cf,添加如下内容:
########################Virtual Mailbox Settings########################
virtual_mailbox_base = /var/mailbox
virtual_mailbox_maps = mysql:/etc/postfix/mysql_virtual_mailbox_maps.cf
virtual_mailbox_domains = mysql:/etc/postfix/mysql_virtual_domains_maps.cf
virtual_alias_domains =
virtual_alias_maps = mysql:/etc/postfix/mysql_virtual_alias_maps.cf
virtual_uid_maps = static:2525
virtual_gid_maps = static:2525

我的问题:virtual_uid_maps为什么 要使用postfix uid 2525 ,由什么决定的,看另外一份资料好像不是使用的postfix uid,这里使用什么的uid到底由什么决定.谢谢

marion 回复于:2007-10-11 09:36:20

virtual mailbox的相关文件必须有相关的属主和属组;通常情况下,POP/IMAP 服务器使用自己的帐户,因此,所有mailbox的相关文件必须属于此用户;当然,如果需要,postfix允许管理员配置自己所需要的帐户。这可以通过多种途径来指定:每个邮箱可以分别属于不同的用户,一个域内所有的域也可以属于同一个用户。

vitrual_uid_maps和virtual_gid_maps就是用来指定虚拟邮箱投递邮件时用到的用户和组帐户。管理员可以指定所有的虚拟邮箱属于同一个系统用户,这时使用static map类型。因此,如果此时你使用postfix默认的MDA,并打算使用同一个系统用户来实现投递,那么就需要按文档中所示的来指定了。如果你配置了另外的MDA,并指定了不同于前面的系统用户,这里就需要将其指向这个新MDA的用户了。

[ 本帖最后由 marion 于 2007-10-11 09:37 编辑 ]

asia_ji 回复于:2007-10-11 12:27:18

按照您http://marion.cublog.cn的“RHEL4上搭建基于postfix的全功能邮件服务器”文章,我在redhat as4.0服务器上构建了postfix的邮件系统,现在已经进行到 maildrop 安装完毕。除了个别软件安装路径和SYS_MAILDIR_BASE设置的路径不同之外,完全按照您的步骤进行的。现在登陆web,添加了一个虚拟域(和实际的域名相同),并注册了用户后,可以给任何的邮箱发送邮件,对方也能正常接收到。但是始终无法接收别的邮箱发送过来的邮件。看了一下论坛上的回帖,我发现发过来的邮件被系统内的用户接收了。而不是虚拟域注册的邮箱。
现在注释掉/etc/postfix/main.cf下的mydestination项,依然无法收到邮件。
下面把配置文件和日志贴出来,请您帮忙找出问题的所在,谢谢!!!

日志:
[root@mail ~]# more /var/log/messages
Oct 11 11:27:35 mail postfix/smtpd[3457]: sql_select option missing
Oct 11 11:27:35 mail postfix/smtpd[3457]: auxpropfunc error no mechanism available
Oct 11 11:27:46 mail postfix/smtpd[3476]: sql_select option missing
Oct 11 11:27:46 mail postfix/smtpd[3476]: auxpropfunc error no mechanism available
Oct 11 11:30:22 mail postfix/smtpd[3480]: sql_select option missing
Oct 11 11:30:22 mail postfix/smtpd[3480]: auxpropfunc error no mechanism available
Oct 11 11:32:38 mail postfix/smtpd[3500]: sql_select option missing
Oct 11 11:32:38 mail postfix/smtpd[3500]: auxpropfunc error no mechanism available
Oct 11 11:36:17 mail postfix/smtpd[3515]: sql_select option missing
Oct 11 11:36:17 mail postfix/smtpd[3515]: auxpropfunc error no mechanism available
Oct 11 11:44:20 mail postfix/smtpd[3557]: sql_select option missing
Oct 11 11:44:20 mail postfix/smtpd[3557]: auxpropfunc error no mechanism available
Oct 11 11:47:16 mail postfix/smtpd[3571]: sql_select option missing
Oct 11 11:47:16 mail postfix/smtpd[3571]: auxpropfunc error no mechanism available
Oct 11 11:57:09 mail postfix/smtpd[3599]: sql_select option missing
Oct 11 11:57:09 mail postfix/smtpd[3599]: auxpropfunc error no mechanism available
Oct 11 12:01:01 mail crond(pam_unix)[3616]: session opened for user root by (uid=0)
Oct 11 12:01:01 mail crond(pam_unix)[3616]: session closed for user root
Oct 11 12:03:40 mail postfix/smtpd[3628]: sql_select option missing
Oct 11 12:03:40 mail postfix/smtpd[3628]: auxpropfunc error no mechanism available
Oct 11 12:05:32 mail postfix/smtpd[3633]: sql_select option missing
Oct 11 12:05:32 mail postfix/smtpd[3633]: auxpropfunc error no mechanism available
Oct 11 12:17:15 mail postfix/smtpd[3668]: sql_select option missing
Oct 11 12:17:15 mail postfix/smtpd[3668]: auxpropfunc error no mechanism available

[root@mail ~]# more /var/log/maillog
Oct 11 11:26:10 mail postfix/anvil[3446]: statistics: max connection rate 1/60s for (smtp:219.134.120.24
) at Oct 11 11:22:46
Oct 11 11:26:10 mail postfix/anvil[3446]: statistics: max connection count 1 for (smtp:219.134.120.24) a
t Oct 11 11:22:46
Oct 11 11:26:10 mail postfix/anvil[3446]: statistics: max cache size 1 at Oct 11 11:22:46
Oct 11 11:27:35 mail postfix/smtpd[3457]: warning: dict_nis_init: NIS domain name not set - NIS lookups
disabled
Oct 11 11:27:40 mail postfix/smtpd[3457]: warning: 59.36.111.108: hostname 108.111.36.59.broad.dg.gd.dyn
amic.163data.com.cn verification failed: Name or service not known
Oct 11 11:27:40 mail postfix/smtpd[3457]: connect from unknown[59.36.111.108]
Oct 11 11:27:41 mail postfix/qmgr[3259]: 75A3A26B1B: from=<asia_ji@yahoo.com.cn>, size=1320, nrcpt=1 (qu
eue active)
Oct 11 11:27:41 mail postfix/qmgr[3259]: 8230526B17: from=<asia_ji@yahoo.com.cn>, size=1307, nrcpt=1 (qu
eue active)
Oct 11 11:27:41 mail postfix/qmgr[3259]: 44A3D26B0E: from=<asia_ji@yahoo.com.cn>, size=1320, nrcpt=1 (qu
eue active)
Oct 11 11:27:41 mail maildrop[3465]: Temporary authentication failure.
Oct 11 11:27:41 mail maildrop[3467]: Temporary authentication failure.
Oct 11 11:27:41 mail postfix/pipe[3461]: 75A3A26B1B: to=<euro@dlfhw.cn>, relay=maildrop, delay=496, dela
ys=496/0.01/0/0.02, dsn=4.3.0, status=deferred (temporary failure. Command output: /usr/local/bin/maildr
op: Temporary authentication failure. )
Oct 11 11:27:41 mail postfix/pipe[3464]: 8230526B17: to=<asia@dlfhw.cn>, relay=maildrop, delay=1095, del
ays=1095/0.02/0/0.02, dsn=4.3.0, status=deferred (temporary failure. Command output: /usr/local/bin/mail
drop: Temporary authentication failure. )
Oct 11 11:27:41 mail maildrop[3473]: Temporary authentication failure.
Oct 11 11:27:41 mail postfix/pipe[3461]: 44A3D26B0E: to=<asia@dlfhw.cn>, relay=maildrop, delay=2379, del
ays=2379/0.02/0/0.01, dsn=4.3.0, status=deferred (temporary failure. Command output: /usr/local/bin/mail
drop: Temporary authentication failure. )
Oct 11 11:27:46 mail postfix/smtpd[3457]: warning: numeric domain name in resource data of MX record for
dlfhw.com: 61.189.86.45
Oct 11 11:27:46 mail postfix/smtpd[3457]: NOQUEUE: reject: RCPT from unknown[59.36.111.108]: 554 5.7.1 <
master@dlfhw.com>: Relay access denied; from=<d0769000@126.com> to=<master@dlfhw.com> proto=ESMTP helo=<
126.com>
Oct 11 11:27:46 mail postfix/smtpd[3476]: warning: dict_nis_init: NIS domain name not set - NIS lookups
disabled
Oct 11 11:27:46 mail postfix/smtpd[3476]: warning: 219.136.103.177: hostname 177.103.136.219.broad.gz.gd
.dynamic.163data.com.cn verification failed: Name or service not known
Oct 11 11:27:46 mail postfix/smtpd[3476]: connect from unknown[219.136.103.177]
Oct 11 11:27:46 mail postfix/smtpd[3457]: disconnect from unknown[59.36.111.108]
Oct 11 11:27:47 mail postfix/smtpd[3476]: NOQUEUE: reject: RCPT from unknown[219.136.103.177]: 450 4.1.8
<dv1re65h7@df486.com>: Sender address rejected: Domain not found; from=<dv1re65h7@df486.com> to=<master
@dlfhw.com> proto=ESMTP helo=<df486.com>
Oct 11 11:27:48 mail postfix/smtpd[3476]: disconnect from unknown[219.136.103.177]
Oct 11 11:30:22 mail postfix/smtpd[3480]: warning: dict_nis_init: NIS domain name not set - NIS lookups
disabled
Oct 11 11:30:22 mail postfix/smtpd[3480]: connect from web92013.mail.cnb.yahoo.com[203.209.230.60]
Oct 11 11:30:22 mail postfix/smtpd[3480]: C307326B1F: client=web92013.mail.cnb.yahoo.com[203.209.230.60]
Oct 11 11:30:22 mail postfix/cleanup[3486]: C307326B1F: message-id=<756667.1137.qm@web92013.mail.cnb.yah
oo.com>
Oct 11 11:30:22 mail postfix/qmgr[3259]: C307326B1F: from=<asia_ji@yahoo.com.cn>, size=1299, nrcpt=1 (qu
eue active)
Oct 11 11:30:22 mail maildrop[3489]: Temporary authentication failure.
Oct 11 11:30:22 mail postfix/pipe[3488]: C307326B1F: to=<euro@dlfhw.cn>, relay=maildrop, delay=0.22, del
ays=0.2/0.01/0/0.01, dsn=4.3.0, status=deferred (temporary failure. Command output: /usr/local/bin/maild
rop: Temporary authentication failure. )
Oct 11 11:30:22 mail postfix/smtpd[3480]: disconnect from web92013.mail.cnb.yahoo.com[203.209.230.60]
Oct 11 11:30:37 mail postfix/smtpd[3480]: connect from 133.201.204.121.board.xm.fj.dynamic.163data.com.c
n[121.204.201.133]
Oct 11 11:30:41 mail postfix/smtpd[3480]: warning: numeric domain name in resource data of MX record for
dlfhw.com: 61.189.86.45
Oct 11 11:30:41 mail postfix/smtpd[3480]: NOQUEUE: reject: RCPT from 133.201.204.121.board.xm.fj.dynamic
.163data.com.cn[121.204.201.133]: 554 5.7.1 <fhxx@dlfhw.com>: Relay access denied; from=<cchdxmj@yahoo.c
om.cn> to=<fhxx@dlfhw.com> proto=ESMTP helo=<hvixczce.gov>
Oct 11 11:30:41 mail postfix/smtpd[3480]: lost connection after RCPT from 133.201.204.121.board.xm.fj.dy
namic.163data.com.cn[121.204.201.133]
Oct 11 11:30:41 mail postfix/smtpd[3480]: disconnect from 133.201.204.121.board.xm.fj.dynamic.163data.co
m.cn[121.204.201.133]
Oct 11 11:32:38 mail postfix/smtpd[3500]: warning: dict_nis_init: NIS domain name not set - NIS lookups
disabled
Oct 11 11:32:41 mail postfix/smtpd[3500]: connect from web92003.mail.cnb.yahoo.com[203.209.230.50]
Oct 11 11:32:41 mail postfix/smtpd[3500]: 2F61226B23: client=web92003.mail.cnb.yahoo.com[203.209.230.50]
Oct 11 11:32:41 mail postfix/cleanup[3506]: 2F61226B23: message-id=<984579.99809.qm@web92003.mail.cnb.ya
hoo.com>
Oct 11 11:32:41 mail postfix/qmgr[3259]: 2F61226B23: from=<asia_ji@yahoo.com.cn>, size=1304, nrcpt=1 (qu
eue active)
Oct 11 11:32:41 mail maildrop[3509]: Temporary authentication failure.
Oct 11 11:32:41 mail postfix/pipe[3508]: 2F61226B23: to=<asia@dlfhw.cn>, relay=maildrop, delay=0.22, del
ays=0.2/0.01/0/0.02, dsn=4.3.0, status=deferred (temporary failure. Command output: /usr/local/bin/maild
rop: Temporary authentication failure. )
Oct 11 11:32:41 mail postfix/smtpd[3500]: disconnect from web92003.mail.cnb.yahoo.com[203.209.230.50]
Oct 11 11:33:22 mail postfix/smtpd[3500]: connect from 219-81-165-94.dynamic.tfn.net.tw[219.81.165.94]
Oct 11 11:33:24 mail postfix/smtpd[3500]: NOQUEUE: reject: RCPT from 219-81-165-94.dynamic.tfn.net.tw[21
9.81.165.94]: 504 5.5.2 <61.189.86.45>: Helo command rejected: need fully-qualified hostname; from=<hhuy
yuirw@msa.hinet.net> to=<all9988@gmail.com> proto=SMTP helo=<61.189.86.45>
Oct 11 11:33:27 mail postfix/smtpd[3500]: lost connection after RCPT from 219-81-165-94.dynamic.tfn.net.
tw[219.81.165.94]
Oct 11 11:33:27 mail postfix/smtpd[3500]: disconnect from 219-81-165-94.dynamic.tfn.net.tw[219.81.165.94
]
Oct 11 11:36:17 mail postfix/smtpd[3515]: warning: dict_nis_init: NIS domain name not set - NIS lookups
disabled
Oct 11 11:36:17 mail postfix/smtpd[3515]: connect from unknown[116.24.117.105]
Oct 11 11:36:24 mail postfix/smtpd[3515]: NOQUEUE: reject: RCPT from unknown[116.24.117.105]: 504 5.5.2
<admin888>: Helo command rejected: need fully-qualified hostname; from=<m5l7n8k4@microsoft.com> to=<mast
er@dlfhw.com> proto=SMTP helo=<admin888>
Oct 11 11:36:26 mail postfix/smtpd[3515]: disconnect from unknown[116.24.117.105]
Oct 11 11:36:42 mail postfix/smtpd[3515]: warning: 218.20.0.141: hostname 141.0.20.218.broad.gz.gd.dynam
ic.163data.com.cn verification failed: Name or service not known
Oct 11 11:36:42 mail postfix/smtpd[3515]: connect from unknown[218.20.0.141]
Oct 11 11:36:43 mail postfix/smtpd[3515]: NOQUEUE: reject: RCPT from unknown[218.20.0.141]: 504 5.5.2 <b
ee>: Helo command rejected: need fully-qualified hostname; from=<good.star.1@gmail.com> to=<fhxx@dlfhw.c
om> proto=ESMTP helo=<bee>
Oct 11 11:36:58 mail postfix/smtpd[3515]: lost connection after DATA from unknown[218.20.0.141]
Oct 11 11:36:58 mail postfix/smtpd[3515]: disconnect from unknown[218.20.0.141]
Oct 11 11:36:58 mail postfix/smtpd[3515]: warning: 218.20.0.141: hostname 141.0.20.218.broad.gz.gd.dynam
ic.163data.com.cn verification failed: Name or service not known
Oct 11 11:36:58 mail postfix/smtpd[3515]: connect from unknown[218.20.0.141]
Oct 11 11:36:59 mail postfix/smtpd[3515]: NOQUEUE: reject: RCPT from unknown[218.20.0.141]: 504 5.5.2 <b
ee>: Helo command rejected: need fully-qualified hostname; from=<good.star.1@gmail.com> to=<fhxx@dlfhw.c
om> proto=ESMTP helo=<bee>
Oct 11 11:37:14 mail postfix/smtpd[3515]: lost connection after DATA from unknown[218.20.0.141]
Oct 11 11:37:14 mail postfix/smtpd[3515]: disconnect from unknown[218.20.0.141]
Oct 11 11:37:40 mail postfix/anvil[3459]: statistics: max connection rate 2/60s for (smtp:218.20.0.141)
at Oct 11 11:36:58
Oct 11 11:37:40 mail postfix/anvil[3459]: statistics: max connection count 1 for (smtp:59.36.111.108) at
Oct 11 11:27:40
Oct 11 11:37:40 mail postfix/anvil[3459]: statistics: max cache size 2 at Oct 11 11:27:46
Oct 11 11:37:41 mail postfix/qmgr[3259]: 75A3A26B1B: from=<asia_ji@yahoo.com.cn>, size=1320, nrcpt=1 (qu
eue active)
Oct 11 11:37:41 mail postfix/qmgr[3259]: 2F61226B23: from=<asia_ji@yahoo.com.cn>, size=1304, nrcpt=1 (qu
eue active)
Oct 11 11:37:41 mail postfix/qmgr[3259]: DE8D826B13: from=<asia_ji@yahoo.com.cn>, size=1325, nrcpt=1 (qu
eue active)
Oct 11 11:37:41 mail postfix/qmgr[3259]: C307326B1F: from=<asia_ji@yahoo.com.cn>, size=1299, nrcpt=1 (qu
eue active)
Oct 11 11:37:41 mail maildrop[3529]: Temporary authentication failure.
Oct 11 11:37:41 mail postfix/pipe[3527]: 75A3A26B1B: to=<euro@dlfhw.cn>, relay=maildrop, delay=1096, del
ays=1096/0.02/0/0.01, dsn=4.3.0, status=deferred (temporary failure. Command output: /usr/local/bin/mail
drop: Temporary authentication failure. )
Oct 11 11:37:41 mail maildrop[3533]: Temporary authentication failure.
Oct 11 11:37:41 mail maildrop[3535]: Temporary authentication failure.
Oct 11 11:37:41 mail postfix/pipe[3528]: 2F61226B23: to=<asia@dlfhw.cn>, relay=maildrop, delay=300, dela
ys=300/0.01/0/0.01, dsn=4.3.0, status=deferred (temporary failure. Command output: /usr/local/bin/maildr
op: Temporary authentication failure. )
Oct 11 11:37:41 mail postfix/pipe[3527]: C307326B1F: to=<euro@dlfhw.cn>, relay=maildrop, delay=439, dela
ys=439/0.02/0/0.01, dsn=4.3.0, status=deferred (temporary failure. Command output: /usr/local/bin/maildr
op: Temporary authentication failure. )
Oct 11 11:37:41 mail maildrop[3539]: Temporary authentication failure.
Oct 11 11:37:41 mail postfix/pipe[3528]: DE8D826B13: to=<asia@dlfhw.cn>, relay=maildrop, delay=2346, del
ays=2345/0.03/0/0.01, dsn=4.3.0, status=deferred (temporary failure. Command output: /usr/local/bin/mail
drop: Temporary authentication failure. )
Oct 11 11:38:36 mail postfix/smtpd[3515]: connect from unknown[122.198.29.62]
Oct 11 11:38:39 mail postfix/smtpd[3515]: warning: numeric domain name in resource data of MX record for
dlfhw.com: 61.189.86.45
Oct 11 11:38:39 mail postfix/smtpd[3515]: NOQUEUE: reject: RCPT from unknown[122.198.29.62]: 554 5.7.1 <
master@dlfhw.com>: Relay access denied; from=<dgjkl@kld.com> to=<master@dlfhw.com> proto=ESMTP helo=<kld
.com>
Oct 11 11:38:39 mail postfix/smtpd[3515]: disconnect from unknown[122.198.29.62]
Oct 11 11:39:02 mail postfix/smtpd[3515]: connect from mx.mail.china.com[211.99.189.206]
Oct 11 11:39:02 mail postfix/smtpd[3515]: warning: numeric domain name in resource data of MX record for
dlfhw.com: 61.189.86.45
Oct 11 11:39:02 mail postfix/smtpd[3515]: NOQUEUE: reject: RCPT from mx.mail.china.com[211.99.189.206]:
554 5.7.1 <master@dlfhw.com>: Relay access denied; from=<iutyu67ht45r18010@mail.china.com> to=<master@dl
fhw.com> proto=SMTP helo=<mail.china.com>
Oct 11 11:39:03 mail postfix/smtpd[3515]: lost connection after RCPT from mx.mail.china.com[211.99.189.2
06]
Oct 11 11:39:03 mail postfix/smtpd[3515]: disconnect from mx.mail.china.com[211.99.189.206]
Oct 11 11:42:23 mail postfix/anvil[3459]: statistics: max connection rate 1/60s for (smtp:122.198.29.62)
at Oct 11 11:38:36
Oct 11 11:42:23 mail postfix/anvil[3459]: statistics: max connection count 1 for (smtp:122.198.29.62) at
Oct 11 11:38:36
Oct 11 11:42:23 mail postfix/anvil[3459]: statistics: max cache size 2 at Oct 11 11:39:02
Oct 11 11:42:41 mail postfix/qmgr[3259]: 2F61226B23: from=<asia_ji@yahoo.com.cn>, size=1304, nrcpt=1 (qu
eue active)
Oct 11 11:42:41 mail maildrop[3551]: Temporary authentication failure.
Oct 11 11:42:41 mail postfix/pipe[3550]: 2F61226B23: to=<asia@dlfhw.cn>, relay=maildrop, delay=600, dela
ys=600/0.02/0/0.01, dsn=4.3.0, status=deferred (temporary failure. Command output: /usr/local/bin/maildr
op: Temporary authentication failure. )
Oct 11 11:44:20 mail postfix/smtpd[3557]: warning: dict_nis_init: NIS domain name not set - NIS lookups
disabled
Oct 11 11:44:26 mail postfix/smtpd[3557]: connect from web92008.mail.cnb.yahoo.com[203.209.230.55]
Oct 11 11:44:26 mail postfix/smtpd[3557]: 2B9B026B27: client=web92008.mail.cnb.yahoo.com[203.209.230.55]
Oct 11 11:44:26 mail postfix/cleanup[3564]: 2B9B026B27: message-id=<213426.42753.qm@web92008.mail.cnb.ya
hoo.com>
Oct 11 11:44:26 mail postfix/qmgr[3259]: 2B9B026B27: from=<asia_ji@yahoo.com.cn>, size=1313, nrcpt=1 (qu
eue active)
Oct 11 11:44:26 mail maildrop[3567]: Temporary authentication failure.
Oct 11 11:44:26 mail postfix/pipe[3566]: 2B9B026B27: to=<asia@dlfhw.cn>, relay=maildrop, delay=0.23, del
ays=0.21/0.01/0/0.01, dsn=4.3.0, status=deferred (temporary failure. Command output: /usr/local/bin/mail
drop: Temporary authentication failure. )
Oct 11 11:44:26 mail postfix/smtpd[3557]: disconnect from web92008.mail.cnb.yahoo.com[203.209.230.55]
Oct 11 11:47:16 mail postfix/smtpd[3571]: warning: dict_nis_init: NIS domain name not set - NIS lookups
disabled
Oct 11 11:47:16 mail postfix/smtpd[3571]: connect from unknown[121.34.192.207]
Oct 11 11:47:34 mail postfix/smtpd[3571]: warning: numeric domain name in resource data of MX record for
dlfhw.com: 61.189.86.45
Oct 11 11:47:34 mail postfix/smtpd[3571]: NOQUEUE: reject: RCPT from unknown[121.34.192.207]: 554 5.7.1
<fhxx@dlfhw.com>: Relay access denied; from=<1234585@163.com> to=<fhxx@dlfhw.com> proto=ESMTP helo=<163.
com>
Oct 11 11:47:35 mail postfix/smtpd[3571]: disconnect from unknown[121.34.192.207]
Oct 11 11:47:41 mail postfix/qmgr[3259]: 8230526B17: from=<asia_ji@yahoo.com.cn>, size=1307, nrcpt=1 (qu
eue active)
Oct 11 11:47:41 mail postfix/qmgr[3259]: C307326B1F: from=<asia_ji@yahoo.com.cn>, size=1299, nrcpt=1 (qu
eue active)
Oct 11 11:47:41 mail maildrop[3579]: Temporary authentication failure.
Oct 11 11:47:41 mail maildrop[3582]: Temporary authentication failure.
Oct 11 11:47:41 mail postfix/pipe[3575]: 8230526B17: to=<asia@dlfhw.cn>, relay=maildrop, delay=2295, del
ays=2295/0.01/0/0.01, dsn=4.3.0, status=deferred (temporary failure. Command output: /usr/local/bin/mail
drop: Temporary authentication failure. )
Oct 11 11:47:41 mail postfix/pipe[3578]: C307326B1F: to=<euro@dlfhw.cn>, relay=maildrop, delay=1038, del
ays=1038/0.02/0/0.01, dsn=4.3.0, status=deferred (temporary failure. Command output: /usr/local/bin/mail
drop: Temporary authentication failure. )
Oct 11 11:50:55 mail postfix/anvil[3559]: statistics: max connection rate 1/60s for (smtp:203.209.230.55
) at Oct 11 11:44:26
Oct 11 11:50:55 mail postfix/anvil[3559]: statistics: max connection count 1 for (smtp:203.209.230.55) a
t Oct 11 11:44:26
Oct 11 11:50:55 mail postfix/anvil[3559]: statistics: max cache size 1 at Oct 11 11:44:26
Oct 11 11:52:41 mail postfix/qmgr[3259]: 2B9B026B27: from=<asia_ji@yahoo.com.cn>, size=1313, nrcpt=1 (qu
eue active)

asia_ji 回复于:2007-10-11 12:29:12

Oct 11 11:52:41 mail postfix/qmgr[3259]: 2F61226B23: from=<asia_ji@yahoo.com.cn>, size=1304, nrcpt=1 (qu
eue active)
Oct 11 11:52:41 mail maildrop[3590]: Temporary authentication failure.
Oct 11 11:52:41 mail postfix/pipe[3589]: 2B9B026B27: to=<asia@dlfhw.cn>, relay=maildrop, delay=495, dela
ys=495/0.02/0/0.01, dsn=4.3.0, status=deferred (temporary failure. Command output: /usr/local/bin/maildr
op: Temporary authentication failure. )
Oct 11 11:52:41 mail maildrop[3594]: Temporary authentication failure.
Oct 11 11:52:41 mail postfix/pipe[3589]: 2F61226B23: to=<asia@dlfhw.cn>, relay=maildrop, delay=1200, del
ays=1200/0.02/0/0.01, dsn=4.3.0, status=deferred (temporary failure. Command output: /usr/local/bin/mail
drop: Temporary authentication failure. )
Oct 11 11:57:09 mail postfix/smtpd[3599]: warning: dict_nis_init: NIS domain name not set - NIS lookups
disabled
Oct 11 11:57:14 mail postfix/smtpd[3599]: warning: 219.133.229.152: hostname 152.229.133.219.broad.sz.gd
.dynamic.163data.com.cn verification failed: Name or service not known
Oct 11 11:57:14 mail postfix/smtpd[3599]: connect from unknown[219.133.229.152]
Oct 11 11:57:16 mail postfix/smtpd[3599]: warning: numeric domain name in resource data of MX record for
dlfhw.com: 61.189.86.45
Oct 11 11:57:16 mail postfix/smtpd[3599]: NOQUEUE: reject: RCPT from unknown[219.133.229.152]: 554 5.7.1
<master@dlfhw.com>: Relay access denied; from=<yttdfbvutdtrtrd@avl.com.cn> to=<master@dlfhw.com> proto=
ESMTP helo=<avl.com.cn>
Oct 11 11:57:16 mail postfix/smtpd[3599]: disconnect from unknown[219.133.229.152]
Oct 11 11:57:41 mail postfix/qmgr[3259]: 75A3A26B1B: from=<asia_ji@yahoo.com.cn>, size=1320, nrcpt=1 (qu
eue active)
Oct 11 11:57:41 mail maildrop[3607]: Temporary authentication failure.
Oct 11 11:57:41 mail postfix/pipe[3606]: 75A3A26B1B: to=<euro@dlfhw.cn>, relay=maildrop, delay=2296, del
ays=2296/0.02/0/0.01, dsn=4.3.0, status=deferred (temporary failure. Command output: /usr/local/bin/mail
drop: Temporary authentication failure. )
Oct 11 11:58:20 mail postfix/smtpd[3599]: warning: 121.35.197.57: hostname 57.197.35.121.broad.sz.gd.dyn
amic.163data.com.cn verification failed: Name or service not known
Oct 11 11:58:20 mail postfix/smtpd[3599]: connect from unknown[121.35.197.57]
Oct 11 11:58:23 mail postfix/smtpd[3599]: warning: numeric domain name in resource data of MX record for
dlfhw.com: 61.189.86.45
Oct 11 11:58:23 mail postfix/smtpd[3599]: NOQUEUE: reject: RCPT from unknown[121.35.197.57]: 554 5.7.1 <
master@dlfhw.com>: Relay access denied; from=<uuo@163.com> to=<master@dlfhw.com> proto=ESMTP helo=<163.c
om>
Oct 11 11:58:23 mail postfix/smtpd[3599]: disconnect from unknown[121.35.197.57]
Oct 11 12:01:43 mail postfix/anvil[3601]: statistics: max connection rate 1/60s for (smtp:219.133.229.15
2) at Oct 11 11:57:14
Oct 11 12:01:43 mail postfix/anvil[3601]: statistics: max connection count 1 for (smtp:219.133.229.152)
at Oct 11 11:57:14
Oct 11 12:01:43 mail postfix/anvil[3601]: statistics: max cache size 1 at Oct 11 11:57:14
Oct 11 12:02:41 mail postfix/qmgr[3259]: 2B9B026B27: from=<asia_ji@yahoo.com.cn>, size=1313, nrcpt=1 (qu
eue active)
Oct 11 12:02:41 mail maildrop[3624]: Temporary authentication failure.
Oct 11 12:02:41 mail postfix/pipe[3623]: 2B9B026B27: to=<asia@dlfhw.cn>, relay=maildrop, delay=1095, del
ays=1095/0.02/0/0.01, dsn=4.3.0, status=deferred (temporary failure. Command output: /usr/local/bin/mail
drop: Temporary authentication failure. )
Oct 11 12:03:40 mail postfix/smtpd[3628]: warning: dict_nis_init: NIS domain name not set - NIS lookups
disabled
Oct 11 12:03:40 mail postfix/smtpd[3628]: warning: 121.34.157.187: hostname 187.157.34.121.broad.sz.gd.d
ynamic.163data.com.cn verification failed: Name or service not known
Oct 11 12:03:40 mail postfix/smtpd[3628]: connect from unknown[121.34.157.187]
Oct 11 12:03:47 mail postfix/smtpd[3628]: warning: numeric domain name in resource data of MX record for
dlfhw.com: 61.189.86.45
Oct 11 12:03:47 mail postfix/smtpd[3628]: NOQUEUE: reject: RCPT from unknown[121.34.157.187]: 554 5.7.1
<fhxx@dlfhw.com>: Relay access denied; from=<yuananxiang@tom.com> to=<fhxx@dlfhw.com> proto=ESMTP helo=<
tom.com>
Oct 11 12:03:47 mail postfix/smtpd[3628]: disconnect from unknown[121.34.157.187]
Oct 11 12:05:32 mail postfix/smtpd[3633]: warning: dict_nis_init: NIS domain name not set - NIS lookups
disabled
Oct 11 12:05:32 mail postfix/smtpd[3633]: connect from unknown[222.60.18.176]
Oct 11 12:05:33 mail postfix/smtpd[3633]: warning: numeric domain name in resource data of MX record for
dlfhw.com: 61.189.86.45
Oct 11 12:05:33 mail postfix/smtpd[3633]: NOQUEUE: reject: RCPT from unknown[222.60.18.176]: 554 5.7.1 <
master@dlfhw.com>: Relay access denied; from=<abc@99look.com> to=<master@dlfhw.com> proto=ESMTP helo=<99
look.com>
Oct 11 12:05:33 mail postfix/smtpd[3633]: disconnect from unknown[222.60.18.176]
Oct 11 12:07:41 mail postfix/qmgr[3259]: 44A3D26B0E: from=<asia_ji@yahoo.com.cn>, size=1320, nrcpt=1 (qu
eue active)
Oct 11 12:07:41 mail postfix/qmgr[3259]: C307326B1F: from=<asia_ji@yahoo.com.cn>, size=1299, nrcpt=1 (qu
eue active)
Oct 11 12:07:41 mail maildrop[3643]: Temporary authentication failure.
Oct 11 12:07:41 mail maildrop[3646]: Temporary authentication failure.
Oct 11 12:07:41 mail postfix/pipe[3639]: 44A3D26B0E: to=<asia@dlfhw.cn>, relay=maildrop, delay=4779, del
ays=4779/0.01/0/0.01, dsn=4.3.0, status=deferred (temporary failure. Command output: /usr/local/bin/mail
drop: Temporary authentication failure. )
Oct 11 12:07:41 mail postfix/pipe[3642]: C307326B1F: to=<euro@dlfhw.cn>, relay=maildrop, delay=2238, del
ays=2238/0.02/0/0.01, dsn=4.3.0, status=deferred (temporary failure. Command output: /usr/local/bin/mail
drop: Temporary authentication failure. )
Oct 11 12:08:53 mail postfix/anvil[3630]: statistics: max connection rate 1/60s for (smtp:121.34.157.187
) at Oct 11 12:03:40
Oct 11 12:08:53 mail postfix/anvil[3630]: statistics: max connection count 1 for (smtp:121.34.157.187) a
t Oct 11 12:03:40
Oct 11 12:08:53 mail postfix/anvil[3630]: statistics: max cache size 1 at Oct 11 12:03:40
Oct 11 12:12:41 mail postfix/qmgr[3259]: 2F61226B23: from=<asia_ji@yahoo.com.cn>, size=1304, nrcpt=1 (qu
eue active)
Oct 11 12:12:41 mail maildrop[3658]: Temporary authentication failure.
Oct 11 12:12:41 mail postfix/pipe[3657]: 2F61226B23: to=<asia@dlfhw.cn>, relay=maildrop, delay=2400, del
ays=2400/0.02/0/0.01, dsn=4.3.0, status=deferred (temporary failure. Command output: /usr/local/bin/mail
drop: Temporary authentication failure. )
Oct 11 12:17:15 mail postfix/smtpd[3668]: warning: dict_nis_init: NIS domain name not set - NIS lookups
disabled
Oct 11 12:17:15 mail postfix/smtpd[3668]: warning: 121.35.197.57: hostname 57.197.35.121.broad.sz.gd.dyn
amic.163data.com.cn verification failed: Name or service not known
Oct 11 12:17:15 mail postfix/smtpd[3668]: connect from unknown[121.35.197.57]
Oct 11 12:17:25 mail postfix/smtpd[3668]: warning: numeric domain name in resource data of MX record for
dlfhw.com: 61.189.86.45
Oct 11 12:17:25 mail postfix/smtpd[3668]: NOQUEUE: reject: RCPT from unknown[121.35.197.57]: 554 5.7.1 <
master@dlfhw.com>: Relay access denied; from=<uijl@126.com> to=<master@dlfhw.com> proto=ESMTP helo=<126.
com>
Oct 11 12:17:26 mail postfix/smtpd[3668]: disconnect from unknown[121.35.197.57]
Oct 11 12:17:41 mail postfix/qmgr[3259]: DE8D826B13: from=<asia_ji@yahoo.com.cn>, size=1325, nrcpt=1 (qu
eue active)
Oct 11 12:17:41 mail maildrop[3675]: Temporary authentication failure.
Oct 11 12:17:41 mail postfix/pipe[3674]: DE8D826B13: to=<asia@dlfhw.cn>, relay=maildrop, delay=4745, del
ays=4745/0.01/0/0.01, dsn=4.3.0, status=deferred (temporary failure. Command output: /usr/local/bin/mail
drop: Temporary authentication failure. )



配置文件:

main.cf:

broken_sasl_auth_clients = yes
command_directory = /usr/local/postfix/sbin
config_directory = /etc/postfix
daemon_directory = /usr/local/postfix/libexec
debug_peer_level = 2
html_directory = /chroot/www/postfix_html
mail_owner = postfix
mail_spool_directory = /chroot/mail
mailq_path = /usr/bin/mailq
manpage_directory = /usr/local/postfix/man
message_size_limit = 14336000
mydomain = dlfhw.cn
myhostname = mail.dlfhw.cn
mynetworks = 61.189.86.0/26, 127.0.0.0/8
myorigin = $mydomain
newaliases_path = /usr/bin/newaliases
queue_directory = /var/spool/postfix
readme_directory = no
sample_directory = /etc/postfix
sendmail_path = /usr/sbin/sendmail
setgid_group = postdrop
smtpd_banner = Welcome to our $myhostname ESMTP,Warning: Version not Available!
smtpd_recipient_restrictions = permit_mynetworks,permit_sasl_authenticated,reject_invalid_hostname,reject_non_fqdn_hostname,reject_unknown_sender_domain,reject_non_fqdn_sender,reject_non_fqdn_recipient,reject_unknown_recipient_domain,reject_unauth_pipelining,reject_unauth_destination
smtpd_sasl_auth_enable = yes
smtpd_sasl_local_domain = $myhostname
smtpd_sasl_security_options = noanonymous
unknown_local_recipient_reject_code = 550
virtual_alias_domains =
virtual_alias_maps = mysql:/etc/postfix/mysql_virtual_alias_maps.cf
virtual_gid_maps = static:2525
virtual_mailbox_base = /chroot/mail
virtual_mailbox_domains = mysql:/etc/postfix/mysql_virtual_domains_maps.cf
virtual_mailbox_limit = 20971520
virtual_mailbox_maps = mysql:/etc/postfix/mysql_virtual_mailbox_maps.cf
virtual_transport = maildrop
virtual_uid_maps = static:2525



/etc/postfix/mysql_virtual_alias_maps.cf
user = extmail
password = extmail
hosts = localhost
dbname = extmail
table = alias
select_field = goto
where_field = address


[root@mail ~]# more /etc/postfix/mysql_virtual_mailbox_limit_maps.cf
user = extmail
password = extmail
hosts = localhost
dbname = extmail
table = mailbox
select_field = quota
where_field = username


[root@mail ~]# more /etc/postfix/mysql_virtual_domains_maps.cf
user = extmail
password = extmail
hosts = localhost
dbname = extmail
table = domain
select_field = description
where_field = domain



[root@mail ~]# more /etc/postfix/mysql_virtual_mailbox_maps.cf
user = extmail
password = extmail
hosts = localhost
dbname = extmail
table = mailbox
select_field = maildir
where_field = username




[root@mail ~]# more /chroot/www/extsuite/extmail/webmail.cf
SYS_CONFIG = /chroot/www/extsuite/extmail/
SYS_LANGDIR = /chroot/www/extsuite/extmail/lang
SYS_TEMPLDIR = /chroot/www/extsuite/extmail/html
SYS_SHOW_WARN = 0
SYS_PERMIT_NOQUOTA = 1
SYS_SESS_DIR = /tmp/
SYS_LOG_ON = 1
SYS_LOG_TYPE = syslog
SYS_LOG_FILE = /var/log/extmail.log
SYS_CAPTCHA_ON = 1
SYS_CAPTCHA_KEY = r3s9b6a7
SYS_CAPTCHA_LEN = 6
SYS_SESS_TIMEOUT = 0
SYS_SESS_COOKIE_ONLY = 1
SYS_USER_PSIZE = 10
SYS_USER_SCREEN = auto
SYS_USER_LANG = zh_CN
SYS_USER_TEMPLATE = default
SYS_USER_CHARSET = utf-8
SYS_USER_TRYLOCAL = 1
SYS_USER_TIMEZONE = +0800
SYS_USER_CCSENT = 1
SYS_USER_SHOW_HTML = 1
SYS_USER_COMPOSE_HTML = 1
SYS_USER_CONV_LINK =1
SYS_USER_ADDR2ABOOK = 1
SYS_MESSAGE_SIZE_LIMIT = 20971520
SYS_MIN_PASS_LEN = 2
SYS_MFILTER_ON = 1
SYS_NETDISK_ON = 1
SYS_SHOW_SIGNUP = 1
SYS_DEBUG_ON = 1
SYS_AUTH_TYPE = mysql
SYS_MAILDIR_BASE = /chroot/mail
SYS_AUTH_SCHEMA = virtual
SYS_CRYPT_TYPE = md5crypt
SYS_MYSQL_USER = extmail
SYS_MYSQL_PASS = extmail
SYS_MYSQL_DB = extmail
SYS_MYSQL_HOST = localhost
SYS_MYSQL_SOCKET = /tmp/mysql.sock
SYS_MYSQL_TABLE = mailbox
SYS_MYSQL_ATTR_USERNAME = username
SYS_MYSQL_ATTR_DOMAIN = domain
SYS_MYSQL_ATTR_PASSWD = password
SYS_MYSQL_ATTR_CLEARPW = clearpwd
SYS_MYSQL_ATTR_QUOTA = quota
SYS_MYSQL_ATTR_NDQUOTA = netdiskquota
SYS_MYSQL_ATTR_HOME = homedir
SYS_MYSQL_ATTR_MAILDIR = maildir
SYS_MYSQL_ATTR_DISABLEWEBMAIL = disablewebmail
SYS_MYSQL_ATTR_DISABLENETDISK = disablenetdisk
SYS_MYSQL_ATTR_DISABLEPWDCHANGE = disablepwdchange
SYS_MYSQL_ATTR_ACTIVE = active
SYS_LDAP_BASE = o=extmailAccount,dc=example.com
SYS_LDAP_RDN = cn=Manager,dc=example.com
SYS_LDAP_PASS = secret
SYS_LDAP_HOST = localhost
SYS_LDAP_ATTR_USERNAME = mail
SYS_LDAP_ATTR_DOMAIN = virtualDomain
SYS_LDAP_ATTR_PASSWD = userPassword
SYS_LDAP_ATTR_CLEARPW = clearPassword
SYS_LDAP_ATTR_QUOTA = mailQuota
SYS_LDAP_ATTR_NDQUOTA = netdiskQuota
SYS_LDAP_ATTR_HOME = homeDirectory
SYS_LDAP_ATTR_MAILDIR = mailMessageStore
SYS_LDAP_ATTR_DISABLEWEBMAIL = disablewebmail
SYS_LDAP_ATTR_DISABLENETDISK = disablenetdisk
SYS_LDAP_ATTR_DISABLEPWDCHANGE = disablePasswdChange
SYS_LDAP_ATTR_ACTIVE = active
SYS_AUTHLIB_SOCKET = /chroot/courier-authlib/var/spool/authdaemon/socket
SYS_G_ABOOK_TYPE = file
SYS_G_ABOOK_LDAP_HOST = localhost
SYS_G_ABOOK_LDAP_BASE = ou=AddressBook,dc=example.com
SYS_G_ABOOK_LDAP_ROOTDN = cn=Manager,dc=example.com
SYS_G_ABOOK_LDAP_ROOTPW = secret
SYS_G_ABOOK_LDAP_FILTER = objectClass=OfficePerson
SYS_G_ABOOK_FILE_PATH = /chroot/www/extsuite/extmail/globabook.cf
SYS_G_ABOOK_FILE_LOCK = 1
SYS_G_ABOOK_FILE_CONVERT = 0
SYS_G_ABOOK_FILE_CHARSET = utf-8





[root@mail ~]# more /chroot/www/extsuite/extman/webman.cf
SYS_CONFIG = /chroot/www/extsuite/extman/
SYS_TEMPLDIR = /chroot/www/extsuite/extman/html
SYS_MAILDIR_BASE = /chroot/mail
SYS_SHOW_WARN = 0
SYS_SESS_DIR = /tmp/extman/
SYS_CAPTCHA_ON = 0
SYS_CAPTCHA_KEY = r3s9b6a7
SYS_CAPTCHA_LEN = 6
SYS_PSIZE = 10
SYS_TEMPLATE_NAME = default
SYS_DEFAULT_EXPIRE = 5y
SYS_GROUPMAIL_SENDER = postmaster@extmail.org
SYS_DEFAULT_SERVICES = webmail,smtpd,smtp,pop3,netdisk
SYS_ISP_MODE = no
SYS_DOMAIN_HASHDIR = yes
SYS_DOMAIN_HASHDIR_DEPTH = 2x2
SYS_USER_HASHDIR = yes
SYS_USER_HASHDIR_DEPTH = 2x2
SYS_MIN_UID = 500
SYS_MIN_GID = 100
SYS_DEFAULT_UID = 1000
SYS_DEFAULT_GID = 1000
SYS_QUOTA_MULTIPLIER = 1048576
SYS_QUOTA_TYPE = courier
SYS_DEFAULT_MAXQUOTA = 500
SYS_DEFAULT_MAXALIAS = 100
SYS_DEFAULT_MAXUSERS = 100
SYS_DEFAULT_MAXNDQUOTA = 500
SYS_USER_DEFAULT_QUOTA = 5
SYS_USER_DEFAULT_NDQUOTA = 5
SYS_USER_DEFAULT_EXPIRE = 1y
SYS_BACKEND_TYPE = mysql
SYS_CRYPT_TYPE = md5crypt
SYS_MYSQL_USER = webman
SYS_MYSQL_PASS = webman
SYS_MYSQL_DB = extmail
SYS_MYSQL_HOST = localhost
SYS_MYSQL_SOCKET = /tmp/mysql.sock
SYS_MYSQL_TABLE = manager
SYS_MYSQL_ATTR_USERNAME = username
SYS_MYSQL_ATTR_PASSWD = password
SYS_LDAP_BASE = dc=extmail.org
SYS_LDAP_RDN = cn=Manager,dc=extmail.org
SYS_LDAP_PASS = secret
SYS_LDAP_HOST = localhost
SYS_LDAP_ATTR_USERNAME = mail
SYS_LDAP_ATTR_PASSWD = userPassword
SYS_RRD_DATADIR = /var/lib
SYS_RRD_TMPDIR = /tmp/viewlog
SYS_RRD_QUEUE_ON = yes

asia_ji 回复于:2007-10-11 12:30:05

root@mail ~]# more /etc/authmysqlrc
##VERSION: $Id: authmysqlrc,v 1.19 2007/02/10 02:51:07 mrsam Exp $
#
# Copyright 2000-2007 Double Precision, Inc. See COPYING for
# distribution information.
#
# Do not alter lines that begin with ##, they are used when upgrading
# this configuration.
#
# authmysqlrc created from authmysqlrc.dist by sysconftool
#
# DO NOT INSTALL THIS FILE with world read permissions. This file
# might contain the MySQL admin password!
#
# Each line in this file must follow the following format:
#
# field[spaces|tabs]value
#
# That is, the name of the field, followed by spaces or tabs, followed by
# field value. Trailing spaces are prohibited.


##NAME: LOCATION:0
#
# The server name, userid, and password used to log in.

MYSQL_SERVER localhost
MYSQL_USERNAME extmail
MYSQL_PASSWORD extmail

##NAME: SSLINFO:0
#
# The SSL information.
#
# To use SSL-encrypted connections, define the following variables (available
# in MySQL 4.0, or higher):
#
#
# MYSQL_SSL_KEY /path/to/file
# MYSQL_SSL_CERT /path/to/file
# MYSQL_SSL_CACERT /path/to/file
# MYSQL_SSL_CAPATH /path/to/file
# MYSQL_SSL_CIPHERS ALL:!DES

##NAME: MYSQL_SOCKET:0
#
# MYSQL_SOCKET can be used with MySQL version 3.22 or later, it specifies the
# filesystem pipe used for the connection
#
MYSQL_SOCKET /tmp/mysql.sock

##NAME: MYSQL_PORT:0
#
# MYSQL_PORT can be used with MySQL version 3.22 or later to specify a port to
# connect to.

MYSQL_PORT 3306

##NAME: MYSQL_OPT:0
#
# Leave MYSQL_OPT as 0, unless you know what you're doing.

MYSQL_OPT 0

##NAME: MYSQL_DATABASE:0
#
# The name of the MySQL database we will open:

MYSQL_DATABASE extmail

##NAME: MYSQL_USER_TABLE:0
#
# The name of the table containing your user data. See README.authmysqlrc
# for the required fields in this table.

MYSQL_USER_TABLE mailbox

##NAME: MYSQL_CRYPT_PWFIELD:0
#
# Either MYSQL_CRYPT_PWFIELD or MYSQL_CLEAR_PWFIELD must be defined. Both
# are OK too. crypted passwords go into MYSQL_CRYPT_PWFIELD, cleartext
# passwords go into MYSQL_CLEAR_PWFIELD. Cleartext passwords allow
# CRAM-MD5 authentication to be implemented.

MYSQL_CRYPT_PWFIELD password

##NAME: MYSQL_CLEAR_PWFIELD:0
#
#
# MYSQL_CLEAR_PWFIELD clear

##NAME: MYSQL_DEFAULT_DOMAIN:0
#
# If DEFAULT_DOMAIN is defined, and someone tries to log in as 'user',
# we will look up 'user@DEFAULT_DOMAIN' instead.
#
#
# DEFAULT_DOMAIN example.com

##NAME: MYSQL_UID_FIELD:0
#
# Other fields in the mysql table:
#
# MYSQL_UID_FIELD - contains the numerical userid of the account
#
MYSQL_UID_FIELD '1001'

##NAME: MYSQL_GID_FIELD:0
#
# Numerical groupid of the account

MYSQL_GID_FIELD '1001'

##NAME: MYSQL_LOGIN_FIELD:0
#
# The login id, default is id. Basically the query is:
#
# SELECT MYSQL_UID_FIELD, MYSQL_GID_FIELD, ... WHERE id='loginid'
#

MYSQL_LOGIN_FIELD username

##NAME: MYSQL_HOME_FIELD:0
#

MYSQL_HOME_FIELD concat('/chroot/mail',maildir)

##NAME: MYSQL_NAME_FIELD:0
#
# The user's name (optional)

MYSQL_NAME_FIELD name

##NAME: MYSQL_MAILDIR_FIELD:0
#
# This is an optional field, and can be used to specify an arbitrary
# location of the maildir for the account, which normally defaults to
# $HOME/Maildir (where $HOME is read from MYSQL_HOME_FIELD).
#
# You still need to provide a MYSQL_HOME_FIELD, even if you uncomment this
# out.
#
MYSQL_MAILDIR_FIELD contcat('/chroot/mail',maildir)

##NAME: MYSQL_DEFAULTDELIVERY:0
#
# Courier mail server only: optional field specifies custom mail delivery
# instructions for this account (if defined) -- essentially overrides
# DEFAULTDELIVERY from ${sysconfdir}/courierd
#
# MYSQL_DEFAULTDELIVERY defaultdelivery

##NAME: MYSQL_QUOTA_FIELD:0
#
# Define MYSQL_QUOTA_FIELD to be the name of the field that can optionally
# specify a maildir quota. See README.maildirquota for more information
#
# MYSQL_QUOTA_FIELD quota

##NAME: MYSQL_AUXOPTIONS:0
#
# Auxiliary options. The MYSQL_AUXOPTIONS field should be a char field that
# contains a single string consisting of comma-separated "ATTRIBUTE=NAME"
# pairs. These names are additional attributes that define various per-account
# "options", as given in INSTALL's description of the "Account OPTIONS"
# setting.
#
# MYSQL_AUXOPTIONS_FIELD auxoptions
#
# You might want to try something like this, if you'd like to use a bunch
# of individual fields, instead of a single text blob:
#
# MYSQL_AUXOPTIONS_FIELD CONCAT("disableimap=",disableimap,",disablepop3=",disablepop3,",disablew
ebmail=",disablewebmail,",sharedgroup=",sharedgroup)
#
# This will let you define fields called "disableimap", etc, with the end result
# being something that the OPTIONS parser understands.


##NAME: MYSQL_WHERE_CLAUSE:0
#
# This is optional, MYSQL_WHERE_CLAUSE can be basically set to an arbitrary
# fixed string that is appended to the WHERE clause of our query
#
# MYSQL_WHERE_CLAUSE server='mailhost.example.com'

##NAME: MYSQL_SELECT_CLAUSE:0
#
# (EXPERIMENTAL)
# This is optional, MYSQL_SELECT_CLAUSE can be set when you have a database,
# which is structuraly different from proposed. The fixed string will
# be used to do a SELECT operation on database, which should return fields
# in order specified bellow:
#
# username, cryptpw, clearpw, uid, gid, home, maildir, quota, fullname, options
#
# The username field should include the domain (see example below).
#
# Enabling this option causes ignorance of any other field-related
# options, excluding default domain.
#
# There are two variables, which you can use. Substitution will be made
# for them, so you can put entered username (local part) and domain name
# in the right place of your query. These variables are:
# $(local_part), $(domain), $(service)
#
# If a $(domain) is empty (not given by the remote user) the default domain
# name is used in its place.
#
# $(service) will expand out to the service being authenticated: imap, imaps,
# pop3 or pop3s. Courier mail server only: service will also expand out to
# "courier", when searching for local mail account's location. In this case,
# if the "maildir" field is not empty it will be used in place of
# DEFAULTDELIVERY. Courier mail server will also use esmtp when doing
# authenticated ESMTP.
#
# This example is a little bit modified adaptation of vmail-sql
# database scheme:
#
# MYSQL_SELECT_CLAUSE SELECT CONCAT(popbox.local_part, '@', popbox.domain_name),
\
# CONCAT('{MD5}', popbox.password_hash), \
# popbox.clearpw, \
# domain.uid, \
# domain.gid, \
# CONCAT(domain.path, '/', popbox.mbox_name), \
# '', \
# domain.quota, \
# '', \
# CONCAT("disableimap=",disableimap,",disablepop3=", \
# disablepop3,",disablewebmail=",disablewebmail, \
# ",sharedgroup=",sharedgroup) \
# FROM popbox, domain \
# WHERE popbox.local_part = '$(local_part)' \
# AND popbox.domain_name = '$(domain)' \
# AND popbox.domain_name = domain.domain_name


##NAME: MYSQL_ENUMERATE_CLAUSE:1
#
# {EXPERIMENTAL}
# Optional custom SQL query used to enumerate accounts for authenumerate,
# in order to compile a list of accounts for shared folders. The query
# should return the following fields: name, uid, gid, homedir, maildir, options
#
# Example:
# MYSQL_ENUMERATE_CLAUSE SELECT CONCAT(popbox.local_part, '@', popbox.domain_name),
\
# domain.uid, \
# domain.gid, \
# CONCAT(domain.path, '/', popbox.mbox_name), \
# '', \
# CONCAT('sharedgroup=', sharedgroup) \
# FROM popbox, domain \
# WHERE popbox.local_part = '$(local_part)' \
# AND popbox.domain_name = '$(domain)' \
# AND popbox.domain_name = domain.domain_name



##NAME: MYSQL_CHPASS_CLAUSE:0
#
# (EXPERIMENTAL)
# This is optional, MYSQL_CHPASS_CLAUSE can be set when you have a database,
# which is structuraly different from proposed. The fixed string will
# be used to do an UPDATE operation on database. In other words, it is
# used, when changing password.
#
# There are four variables, which you can use. Substitution will be made
# for them, so you can put entered username (local part) and domain name
# in the right place of your query. There variables are:
# $(local_part) , $(domain) , $(newpass) , $(newpass_crypt)
#
# If a $(domain) is empty (not given by the remote user) the default domain
# name is used in its place.
# $(newpass) contains plain password
# $(newpass_crypt) contains its crypted form
#
# MYSQL_CHPASS_CLAUSE UPDATE popbox \
# SET clearpw='$(newpass)', \
# password_hash='$(newpass_crypt)' \
# WHERE local_part='$(local_part)' \
# AND domain_name='$(domain)'
#



这是通过extman新建的域
[root@mail ~]# ll /chroot/mail/
total 28
-rw------- 1 vmail vmail 16051 Oct 11 10:15 asia
drwx------ 4 vmail vmail 4096 Oct 10 17:04 dlfhw.cn


这是通过extman新建的两个邮箱用户
[root@mail ~]# ll /chroot/mail/dlfhw.cn/
total 16
drwx------ 3 vmail vmail 4096 Oct 10 16:34 asia
drwx------ 3 vmail vmail 4096 Oct 10 17:04 euro

asia_ji 回复于:2007-10-11 12:32:12

Oct 11 11:27:35 mail postfix/smtpd[3457]: warning: dict_nis_init: NIS domain name not set - NIS lookups
disabled

这个日志记录是什么意思?

marion 回复于:2007-10-11 19:44:46

引用:现在注释掉/etc/postfix/main.cf下的mydestination项,依然无法收到邮件。
下面把配置文件和日志贴出来,请您帮忙找出问题的所在,谢谢!!!


mydomain,myorigin这两个参数注释了吗?
注释掉不是解决这个问题的办法,建议给本地域指定一个别的域名或许可以解决此问题。

marion 回复于:2007-10-11 19:50:35

引用:原帖由 asia_ji 于 2007-10-11 12:32 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=7451899&ptid=987344
Oct 11 11:27:35 mail postfix/smtpd[3457]: warning: dict_nis_init: NIS domain name not set - NIS lookups
disabled

这个日志记录是什么意思?


找一下你的配置文件main.cf中是否有类同于如下行的项(也可能是被注释掉的),如果有并被注释了,启用它,并将后面关于nis的删除即可。
alias_maps = hash:/etc/aliases, nis:mail.aliases

2008zgh 回复于:2007-10-12 01:04:30


谢谢!!!

asia_ji 回复于:2007-10-12 09:40:35

引用:原帖由 marion 于 2007-10-11 19:44 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=7454285&ptid=987344


mydomain,myorigin这两个参数注释了吗?
注释掉不是解决这个问题的办法,建议给本地域指定一个别的域名或许可以解决此问题。




昨天弄了一天,中午饭都没有吃,还是没有找到具体的原因,但是问题肯定出在认证这块,后来干脆推倒了从来,今天终于能收发邮件了。
关于本地域和虚拟域同名的问题,我把main.cf里面mydomain,myorigin,myhostname等全给注释掉了,虚拟域就可以收到邮件了。

asia_ji 回复于:2007-10-12 10:19:03

(temporary failure. Command output: /usr/local/bin/maildrop: Unable to change to home directory. )
这是由于什么原因导致的??

Oct 12 10:05:26 mail postfix/pickup[11414]: 4112426B23: uid=1001 from=<asia@dlfhw.cn>
Oct 12 10:05:26 mail postfix/cleanup[11426]: 4112426B23: message-id=<20071012020526.4112426B23@mail.dlfh
w.cn>
Oct 12 10:05:26 mail postfix/qmgr[11413]: 4112426B23: from=<asia@dlfhw.cn>, size=482, nrcpt=1 (queue act
ive)
Oct 12 10:05:26 mail postfix/pipe[11446]: 4112426B23: to=<huanglin@dlfhw.cn>, relay=maildrop, delay=0.06
, delays=0.01/0.04/0/0.01, dsn=4.3.0, status=deferred (temporary failure. Command output: /usr/local/bin
/maildrop: Unable to change to home directory. )

marion 回复于:2007-10-12 10:24:36

"Unable to change to home directory"这个表明maildrop在访问用户邮箱目录时遇到了问题;你再重新检查一下用户邮箱目录的访问权限、属主属组、以及authmysqlrc等的设置是否完全正确。

marion 回复于:2007-10-12 10:28:11

兄弟精神可嘉!

同时那个注释掉相应的几个参数的确可以解决那个问题,但不建议以之为最终办法,这才是我回复你的原意。

asia_ji 回复于:2007-10-12 10:34:28

我看了一下邮箱目录的属主和属组都是vmail权限如下:
[root@mail chroot]# ll /chroot/mail/
total 12
-rw------- 1 vmail vmail 0 Oct 12 07:59 asia
drwx------ 4 vmail vmail 4096 Oct 12 09:41 dlfhw.cn

[root@mail dlfhw.cn]# ll /chroot/mail/dlfhw.cn/
total 16
drwx------ 3 vmail vmail 4096 Oct 12 09:20 asia
drwx------ 3 vmail vmail 4096 Oct 12 09:19 huanglin

/etc/authmysqlrc配置文件如下:
[root@mail dlfhw.cn]# more /etc/authmysqlrc
##VERSION: $Id: authmysqlrc,v 1.19 2007/02/10 02:51:07 mrsam Exp $
#
# Copyright 2000-2007 Double Precision, Inc. See COPYING for
# distribution information.
#
# Do not alter lines that begin with ##, they are used when upgrading
# this configuration.
#
# authmysqlrc created from authmysqlrc.dist by sysconftool
#
# DO NOT INSTALL THIS FILE with world read permissions. This file
# might contain the MySQL admin password!
#
# Each line in this file must follow the following format:
#
# field[spaces|tabs]value
#
# That is, the name of the field, followed by spaces or tabs, followed by
# field value. Trailing spaces are prohibited.


##NAME: LOCATION:0
#
# The server name, userid, and password used to log in.

MYSQL_SERVER localhost
MYSQL_USERNAME extmail
MYSQL_PASSWORD extmail

##NAME: SSLINFO:0
#
# The SSL information.
#
# To use SSL-encrypted connections, define the following variables (available
# in MySQL 4.0, or higher):
#
#
# MYSQL_SSL_KEY /path/to/file
# MYSQL_SSL_CERT /path/to/file
# MYSQL_SSL_CACERT /path/to/file
# MYSQL_SSL_CAPATH /path/to/file
# MYSQL_SSL_CIPHERS ALL:!DES

##NAME: MYSQL_SOCKET:0
#
# MYSQL_SOCKET can be used with MySQL version 3.22 or later, it specifies the
# filesystem pipe used for the connection
#
MYSQL_SOCKET /tmp/mysql.sock

##NAME: MYSQL_PORT:0
#
# MYSQL_PORT can be used with MySQL version 3.22 or later to specify a port to
# connect to.

MYSQL_PORT 3306

##NAME: MYSQL_OPT:0
#
# Leave MYSQL_OPT as 0, unless you know what you're doing.

MYSQL_OPT 0

##NAME: MYSQL_DATABASE:0
#
# The name of the MySQL database we will open:

MYSQL_DATABASE extmail

##NAME: MYSQL_USER_TABLE:0
#
# The name of the table containing your user data. See README.authmysqlrc
# for the required fields in this table.

MYSQL_USER_TABLE mailbox

##NAME: MYSQL_CRYPT_PWFIELD:0
#
# Either MYSQL_CRYPT_PWFIELD or MYSQL_CLEAR_PWFIELD must be defined. Both
# are OK too. crypted passwords go into MYSQL_CRYPT_PWFIELD, cleartext
# passwords go into MYSQL_CLEAR_PWFIELD. Cleartext passwords allow
# CRAM-MD5 authentication to be implemented.

MYSQL_CRYPT_PWFIELD password

##NAME: MYSQL_CLEAR_PWFIELD:0
#
#
# MYSQL_CLEAR_PWFIELD clear

##NAME: MYSQL_DEFAULT_DOMAIN:0
#
# If DEFAULT_DOMAIN is defined, and someone tries to log in as 'user',
# we will look up 'user@DEFAULT_DOMAIN' instead.
#
#
# DEFAULT_DOMAIN example.com

##NAME: MYSQL_UID_FIELD:0
#
# Other fields in the mysql table:
#
# MYSQL_UID_FIELD - contains the numerical userid of the account
#
MYSQL_UID_FIELD '1001'

##NAME: MYSQL_GID_FIELD:0
#
# Numerical groupid of the account

MYSQL_GID_FIELD '1001'

##NAME: MYSQL_LOGIN_FIELD:0
#
# The login id, default is id. Basically the query is:
#
# SELECT MYSQL_UID_FIELD, MYSQL_GID_FIELD, ... WHERE id='loginid'
#

MYSQL_LOGIN_FIELD username

##NAME: MYSQL_HOME_FIELD:0
#

MYSQL_HOME_FIELD concat('/chroot/mail',maildir)

##NAME: MYSQL_NAME_FIELD:0
#
# The user's name (optional)

MYSQL_NAME_FIELD name

##NAME: MYSQL_MAILDIR_FIELD:0
#
# This is an optional field, and can be used to specify an arbitrary
# location of the maildir for the account, which normally defaults to
# $HOME/Maildir (where $HOME is read from MYSQL_HOME_FIELD).
#
# You still need to provide a MYSQL_HOME_FIELD, even if you uncomment this
# out.
#
# MYSQL_MAILDIR_FIELD concat('/chroot/mail',maildir)

##NAME: MYSQL_DEFAULTDELIVERY:0
#
# Courier mail server only: optional field specifies custom mail delivery
# instructions for this account (if defined) -- essentially overrides
# DEFAULTDELIVERY from ${sysconfdir}/courierd
#
# MYSQL_DEFAULTDELIVERY defaultdelivery

##NAME: MYSQL_QUOTA_FIELD:0
#
# Define MYSQL_QUOTA_FIELD to be the name of the field that can optionally
# specify a maildir quota. See README.maildirquota for more information
#
# MYSQL_QUOTA_FIELD quota

##NAME: MYSQL_AUXOPTIONS:0
#
# Auxiliary options. The MYSQL_AUXOPTIONS field should be a char field that
# contains a single string consisting of comma-separated "ATTRIBUTE=NAME"
# pairs. These names are additional attributes that define various per-account
# "options", as given in INSTALL's description of the "Account OPTIONS"
# setting.
#
# MYSQL_AUXOPTIONS_FIELD auxoptions
#
# You might want to try something like this, if you'd like to use a bunch
# of individual fields, instead of a single text blob:
#
# MYSQL_AUXOPTIONS_FIELD CONCAT("disableimap=",disableimap,",disablepop3=",disablepop3,",disablew
ebmail=",disablewebmail,",sharedgroup=",sharedgroup)
#
# This will let you define fields called "disableimap", etc, with the end result
# being something that the OPTIONS parser understands.


##NAME: MYSQL_WHERE_CLAUSE:0
#
# This is optional, MYSQL_WHERE_CLAUSE can be basically set to an arbitrary
# fixed string that is appended to the WHERE clause of our query
#
# MYSQL_WHERE_CLAUSE server='mailhost.example.com'

##NAME: MYSQL_SELECT_CLAUSE:0
#
# (EXPERIMENTAL)
# This is optional, MYSQL_SELECT_CLAUSE can be set when you have a database,
# which is structuraly different from proposed. The fixed string will
# be used to do a SELECT operation on database, which should return fields
# in order specified bellow:
#
# username, cryptpw, clearpw, uid, gid, home, maildir, quota, fullname, options
#
# The username field should include the domain (see example below).
#
# Enabling this option causes ignorance of any other field-related
# options, excluding default domain.
#
# There are two variables, which you can use. Substitution will be made
# for them, so you can put entered username (local part) and domain name
# in the right place of your query. These variables are:
# $(local_part), $(domain), $(service)
#
# If a $(domain) is empty (not given by the remote user) the default domain
# name is used in its place.
#
# $(service) will expand out to the service being authenticated: imap, imaps,
# pop3 or pop3s. Courier mail server only: service will also expand out to
# "courier", when searching for local mail account's location. In this case,
# if the "maildir" field is not empty it will be used in place of
# DEFAULTDELIVERY. Courier mail server will also use esmtp when doing
# authenticated ESMTP.
#
# This example is a little bit modified adaptation of vmail-sql
# database scheme:
#
# MYSQL_SELECT_CLAUSE SELECT CONCAT(popbox.local_part, '@', popbox.domain_name),
\
# CONCAT('{MD5}', popbox.password_hash), \
# popbox.clearpw, \
# domain.uid, \
# domain.gid, \
# CONCAT(domain.path, '/', popbox.mbox_name), \
# '', \
# domain.quota, \
# '', \
# CONCAT("disableimap=",disableimap,",disablepop3=", \
# disablepop3,",disablewebmail=",disablewebmail, \
# ",sharedgroup=",sharedgroup) \
# FROM popbox, domain \
# WHERE popbox.local_part = '$(local_part)' \
# AND popbox.domain_name = '$(domain)' \
# AND popbox.domain_name = domain.domain_name


##NAME: MYSQL_ENUMERATE_CLAUSE:1
#
# {EXPERIMENTAL}
# Optional custom SQL query used to enumerate accounts for authenumerate,
# in order to compile a list of accounts for shared folders. The query
# should return the following fields: name, uid, gid, homedir, maildir, options
#
# Example:
# MYSQL_ENUMERATE_CLAUSE SELECT CONCAT(popbox.local_part, '@', popbox.domain_name),
\
# domain.uid, \
# domain.gid, \
# CONCAT(domain.path, '/', popbox.mbox_name), \
# '', \
# CONCAT('sharedgroup=', sharedgroup) \
# FROM popbox, domain \
# WHERE popbox.local_part = '$(local_part)' \
# AND popbox.domain_name = '$(domain)' \
# AND popbox.domain_name = domain.domain_name



##NAME: MYSQL_CHPASS_CLAUSE:0
#
# (EXPERIMENTAL)
# This is optional, MYSQL_CHPASS_CLAUSE can be set when you have a database,
# which is structuraly different from proposed. The fixed string will
# be used to do an UPDATE operation on database. In other words, it is
# used, when changing password.
#
# There are four variables, which you can use. Substitution will be made
# for them, so you can put entered username (local part) and domain name
# in the right place of your query. There variables are:
# $(local_part) , $(domain) , $(newpass) , $(newpass_crypt)
#
# If a $(domain) is empty (not given by the remote user) the default domain
# name is used in its place.
# $(newpass) contains plain password
# $(newpass_crypt) contains its crypted form
#
# MYSQL_CHPASS_CLAUSE UPDATE popbox \
# SET clearpw='$(newpass)', \
# password_hash='$(newpass_crypt)' \
# WHERE local_part='$(local_part)' \
# AND domain_name='$(domain)'
#

marion 回复于:2007-10-12 10:40:38

# MYSQL_MAILDIR_FIELD concat('/chroot/mail',maildir)

这个为什么注释掉了呢?

cnhawk386 回复于:2007-10-12 10:51:50

SYS_MYSQL_TABLE = mailbox
SYS_MYSQL_ATTR_USERNAME = username
SYS_MYSQL_ATTR_DOMAIN = domain
SYS_MYSQL_ATTR_PASSWD = password
以上用来指定验正用户登录里所用到的表,以及用户名、域名和用户密码分别对应的表中列的名称;这里默认即可


我的问题:
我的用户名、域名在mysql中是两个不同表中的字段 应该如何解决???必须放在一个表中 吗?????
谢谢??

asia_ji 回复于:2007-10-12 10:59:44

我要晕倒了!
marion,我把所有的配置文件贴出来,您帮我看看问题出在哪里?
现在还是老样子
/var/log/messages:有一个这样的日志
Oct 12 10:43:37 mail postfix/smtpd[2407]: sql_select option missing
Oct 12 10:43:37 mail postfix/smtpd[2407]: auxpropfunc error no mechanism available

/var/log/maillog:
Oct 12 10:47:09 mail postfix/pickup[2273]: E1A3A26B42: uid=1001 from=<asia@dlfhw.cn>
Oct 12 10:47:09 mail postfix/cleanup[2426]: E1A3A26B42: message-id=<20071012024709.E1A3A26B42@mail.dlfhw
.cn>
Oct 12 10:47:09 mail postfix/qmgr[2272]: E1A3A26B42: from=<asia@dlfhw.cn>, size=517, nrcpt=1 (queue acti
ve)
Oct 12 10:47:09 mail postfix/pipe[2431]: E1A3A26B42: to=<huanglin@dlfhw.cn>, relay=maildrop, delay=0.12,
delays=0.1/0.01/0/0.01, dsn=4.3.0, status=deferred (temporary failure. Command output: /usr/local/bin/m
aildrop: Unable to change to home directory. )


[root@mail ~]# more /etc/authmysqlrc
##VERSION: $Id: authmysqlrc,v 1.19 2007/02/10 02:51:07 mrsam Exp $
#
# Copyright 2000-2007 Double Precision, Inc. See COPYING for
# distribution information.
#
# Do not alter lines that begin with ##, they are used when upgrading
# this configuration.
#
# authmysqlrc created from authmysqlrc.dist by sysconftool
#
# DO NOT INSTALL THIS FILE with world read permissions. This file
# might contain the MySQL admin password!
#
# Each line in this file must follow the following format:
#
# field[spaces|tabs]value
#
# That is, the name of the field, followed by spaces or tabs, followed by
# field value. Trailing spaces are prohibited.


##NAME: LOCATION:0
#
# The server name, userid, and password used to log in.

MYSQL_SERVER localhost
MYSQL_USERNAME extmail
MYSQL_PASSWORD extmail

##NAME: SSLINFO:0
#
# The SSL information.
#
# To use SSL-encrypted connections, define the following variables (available
# in MySQL 4.0, or higher):
#
#
# MYSQL_SSL_KEY /path/to/file
# MYSQL_SSL_CERT /path/to/file
# MYSQL_SSL_CACERT /path/to/file
# MYSQL_SSL_CAPATH /path/to/file
# MYSQL_SSL_CIPHERS ALL:!DES

##NAME: MYSQL_SOCKET:0
#
# MYSQL_SOCKET can be used with MySQL version 3.22 or later, it specifies the
# filesystem pipe used for the connection
#
MYSQL_SOCKET /tmp/mysql.sock

##NAME: MYSQL_PORT:0
#
# MYSQL_PORT can be used with MySQL version 3.22 or later to specify a port to
# connect to.

MYSQL_PORT 3306

##NAME: MYSQL_OPT:0
#
# Leave MYSQL_OPT as 0, unless you know what you're doing.

MYSQL_OPT 0

##NAME: MYSQL_DATABASE:0
#
# The name of the MySQL database we will open:

MYSQL_DATABASE extmail

##NAME: MYSQL_USER_TABLE:0
#
# The name of the table containing your user data. See README.authmysqlrc
# for the required fields in this table.

MYSQL_USER_TABLE mailbox

##NAME: MYSQL_CRYPT_PWFIELD:0
#
# Either MYSQL_CRYPT_PWFIELD or MYSQL_CLEAR_PWFIELD must be defined. Both
# are OK too. crypted passwords go into MYSQL_CRYPT_PWFIELD, cleartext
# passwords go into MYSQL_CLEAR_PWFIELD. Cleartext passwords allow
# CRAM-MD5 authentication to be implemented.

MYSQL_CRYPT_PWFIELD password

##NAME: MYSQL_CLEAR_PWFIELD:0
#
#
# MYSQL_CLEAR_PWFIELD clear

##NAME: MYSQL_DEFAULT_DOMAIN:0
#
# If DEFAULT_DOMAIN is defined, and someone tries to log in as 'user',
# we will look up 'user@DEFAULT_DOMAIN' instead.
#
#
# DEFAULT_DOMAIN example.com

##NAME: MYSQL_UID_FIELD:0
#
# Other fields in the mysql table:
#
# MYSQL_UID_FIELD - contains the numerical userid of the account
#
MYSQL_UID_FIELD '1001'

##NAME: MYSQL_GID_FIELD:0
#
# Numerical groupid of the account

MYSQL_GID_FIELD '1001'

##NAME: MYSQL_LOGIN_FIELD:0
#
# The login id, default is id. Basically the query is:
#
# SELECT MYSQL_UID_FIELD, MYSQL_GID_FIELD, ... WHERE id='loginid'
#

MYSQL_LOGIN_FIELD username

##NAME: MYSQL_HOME_FIELD:0
#

MYSQL_HOME_FIELD concat('/chroot/mail',maildir)

##NAME: MYSQL_NAME_FIELD:0
#
# The user's name (optional)

MYSQL_NAME_FIELD name

##NAME: MYSQL_MAILDIR_FIELD:0
#
# This is an optional field, and can be used to specify an arbitrary
# location of the maildir for the account, which normally defaults to
# $HOME/Maildir (where $HOME is read from MYSQL_HOME_FIELD).
#
# You still need to provide a MYSQL_HOME_FIELD, even if you uncomment this
# out.
#
MYSQL_MAILDIR_FIELD concat('/chroot/mail',maildir)

##NAME: MYSQL_DEFAULTDELIVERY:0
#
# Courier mail server only: optional field specifies custom mail delivery
# instructions for this account (if defined) -- essentially overrides
# DEFAULTDELIVERY from ${sysconfdir}/courierd
#
# MYSQL_DEFAULTDELIVERY defaultdelivery

##NAME: MYSQL_QUOTA_FIELD:0
#
# Define MYSQL_QUOTA_FIELD to be the name of the field that can optionally
# specify a maildir quota. See README.maildirquota for more information
#
# MYSQL_QUOTA_FIELD quota

##NAME: MYSQL_AUXOPTIONS:0
#
# Auxiliary options. The MYSQL_AUXOPTIONS field should be a char field that
# contains a single string consisting of comma-separated "ATTRIBUTE=NAME"
# pairs. These names are additional attributes that define various per-account
# "options", as given in INSTALL's description of the "Account OPTIONS"
# setting.
#
# MYSQL_AUXOPTIONS_FIELD auxoptions
#
# You might want to try something like this, if you'd like to use a bunch
# of individual fields, instead of a single text blob:
#
# MYSQL_AUXOPTIONS_FIELD CONCAT("disableimap=",disableimap,",disablepop3=",disablepop3,",disablew
ebmail=",disablewebmail,",sharedgroup=",sharedgroup)
#
# This will let you define fields called "disableimap", etc, with the end result
# being something that the OPTIONS parser understands.


##NAME: MYSQL_WHERE_CLAUSE:0
#
# This is optional, MYSQL_WHERE_CLAUSE can be basically set to an arbitrary
# fixed string that is appended to the WHERE clause of our query
#
# MYSQL_WHERE_CLAUSE server='mailhost.example.com'

##NAME: MYSQL_SELECT_CLAUSE:0
#
# (EXPERIMENTAL)
# This is optional, MYSQL_SELECT_CLAUSE can be set when you have a database,
# which is structuraly different from proposed. The fixed string will
# be used to do a SELECT operation on database, which should return fields
# in order specified bellow:
#
# username, cryptpw, clearpw, uid, gid, home, maildir, quota, fullname, options
#
# The username field should include the domain (see example below).
#
# Enabling this option causes ignorance of any other field-related
# options, excluding default domain.
#
# There are two variables, which you can use. Substitution will be made
# for them, so you can put entered username (local part) and domain name
# in the right place of your query. These variables are:
# $(local_part), $(domain), $(service)
#
# If a $(domain) is empty (not given by the remote user) the default domain
# name is used in its place.
#
# $(service) will expand out to the service being authenticated: imap, imaps,
# pop3 or pop3s. Courier mail server only: service will also expand out to
# "courier", when searching for local mail account's location. In this case,
# if the "maildir" field is not empty it will be used in place of
# DEFAULTDELIVERY. Courier mail server will also use esmtp when doing
# authenticated ESMTP.
#
# This example is a little bit modified adaptation of vmail-sql
# database scheme:
#
# MYSQL_SELECT_CLAUSE SELECT CONCAT(popbox.local_part, '@', popbox.domain_name),
\
# CONCAT('{MD5}', popbox.password_hash), \
# popbox.clearpw, \
# domain.uid, \
# domain.gid, \
# CONCAT(domain.path, '/', popbox.mbox_name), \
# '', \
# domain.quota, \
# '', \
# CONCAT("disableimap=",disableimap,",disablepop3=", \
# disablepop3,",disablewebmail=",disablewebmail, \
# ",sharedgroup=",sharedgroup) \
# FROM popbox, domain \
# WHERE popbox.local_part = '$(local_part)' \
# AND popbox.domain_name = '$(domain)' \
# AND popbox.domain_name = domain.domain_name


##NAME: MYSQL_ENUMERATE_CLAUSE:1
#
# {EXPERIMENTAL}
# Optional custom SQL query used to enumerate accounts for authenumerate,
# in order to compile a list of accounts for shared folders. The query
# should return the following fields: name, uid, gid, homedir, maildir, options
#
# Example:
# MYSQL_ENUMERATE_CLAUSE SELECT CONCAT(popbox.local_part, '@', popbox.domain_name),
\
# domain.uid, \
# domain.gid, \
# CONCAT(domain.path, '/', popbox.mbox_name), \
# '', \
# CONCAT('sharedgroup=', sharedgroup) \
# FROM popbox, domain \
# WHERE popbox.local_part = '$(local_part)' \
# AND popbox.domain_name = '$(domain)' \
# AND popbox.domain_name = domain.domain_name



##NAME: MYSQL_CHPASS_CLAUSE:0
#
# (EXPERIMENTAL)
# This is optional, MYSQL_CHPASS_CLAUSE can be set when you have a database,
# which is structuraly different from proposed. The fixed string will
# be used to do an UPDATE operation on database. In other words, it is
# used, when changing password.
#
# There are four variables, which you can use. Substitution will be made
# for them, so you can put entered username (local part) and domain name
# in the right place of your query. There variables are:
# $(local_part) , $(domain) , $(newpass) , $(newpass_crypt)
#
# If a $(domain) is empty (not given by the remote user) the default domain
# name is used in its place.
# $(newpass) contains plain password
# $(newpass_crypt) contains its crypted form
#
# MYSQL_CHPASS_CLAUSE UPDATE popbox \
# SET clearpw='$(newpass)', \
# password_hash='$(newpass_crypt)' \
# WHERE local_part='$(local_part)' \
# AND domain_name='$(domain)'
#

asia_ji 回复于:2007-10-12 11:00:19

[root@mail ~]# more /etc/authdaemonrc
##VERSION: $Id: authdaemonrc.in,v 1.13 2005/10/05 00:07:32 mrsam Exp $
#
# Copyright 2000-2005 Double Precision, Inc. See COPYING for
# distribution information.
#
# authdaemonrc created from authdaemonrc.dist by sysconftool
#
# Do not alter lines that begin with ##, they are used when upgrading
# this configuration.
#
# This file configures authdaemond, the resident authentication daemon.
#
# Comments in this file are ignored. Although this file is intended to
# be sourced as a shell script, authdaemond parses it manually, so
# the acceptable syntax is a bit limited. Multiline variable contents,
# with the \ continuation character, are not allowed. Everything must
# fit on one line. Do not use any additional whitespace for indentation,
# or anything else.

##NAME: authmodulelist:2
#
# The authentication modules that are linked into authdaemond. The
# default list is installed. You may selectively disable modules simply
# by removing them from the following list. The available modules you
# can use are: authuserdb authmysql authcustom authpipe

authmodulelist="authmysql"

##NAME: authmodulelistorig:3
#
# This setting is used by Courier's webadmin module, and should be left
# alone

authmodulelistorig="authmysql"

##NAME: daemons:0
#
# The number of daemon processes that are started. authdaemon is typically
# installed where authentication modules are relatively expensive: such
# as authldap, or authmysql, so it's better to have a number of them running.
# PLEASE NOTE: Some platforms may experience a problem if there's more than
# one daemon. Specifically, SystemV derived platforms that use TLI with
# socket emulation. I'm suspicious of TLI's ability to handle multiple
# processes accepting connections on the same filesystem domain socket.
#
# You may need to increase daemons if as your system load increases. Symptoms
# include sporadic authentication failures. If you start getting
# authentication failures, increase daemons. However, the default of 5
# SHOULD be sufficient. Bumping up daemon count is only a short-term
# solution. The permanent solution is to add more resources: RAM, faster
# disks, faster CPUs...

daemons=10

##NAME: authdaemonvar:2
#
# authdaemonvar is here, but is not used directly by authdaemond. It's
# used by various configuration and build scripts, so don't touch it!

authdaemonvar=/usr/local/courier-authlib/var/spool/authdaemon

##NAME: DEBUG_LOGIN:0
#
# Dump additional diagnostics to syslog
#
# DEBUG_LOGIN=0 - turn off debugging
# DEBUG_LOGIN=1 - turn on debugging
# DEBUG_LOGIN=2 - turn on debugging + log passwords too
#
# ** YES ** - DEBUG_LOGIN=2 places passwords into syslog.
#
# Note that most information is sent to syslog at level 'debug', so
# you may need to modify your /etc/syslog.conf to be able to see it.

DEBUG_LOGIN=0

##NAME: DEFAULTOPTIONS:0
#
# A comma-separated list of option=value pairs. Each option is applied
# to an account if the account does not have its own specific value for
# that option. So for example, you can set
# DEFAULTOPTIONS="disablewebmail=1,disableimap=1"
# and then enable webmail and/or imap on individual accounts by setting
# disablewebmail=0 and/or disableimap=0 on the account.

DEFAULTOPTIONS=""

##NAME: LOGGEROPTS:0
#
# courierlogger(1) options, e.g. to set syslog facility
#

LOGGEROPTS=""

##NAME: LDAP_TLS_OPTIONS:0
#
# Options documented in ldap.conf(5) can be set here, prefixed with 'LDAP'.
# Examples:
#
#LDAPTLS_CACERT=/path/to/cacert.pem
#LDAPTLS_REQCERT=demand
#LDAPTLS_CERT=/path/to/clientcert.pem
#LDAPTLS_KEY=/path/to/clientkey.pem

asia_ji 回复于:2007-10-12 11:02:09

[root@mail ~]# more /etc/postfix/master.cf
#
# Postfix master process configuration file. For details on the format
# of the file, see the master(5) manual page (command: "man 5 master").
#
# ==========================================================================
# service type private unpriv chroot wakeup maxproc command + args
# (yes) (yes) (yes) (never) (100)
# ==========================================================================
smtp inet n - n - - smtpd
#submission inet n - n - - smtpd
# -o smtpd_enforce_tls=yes
# -o smtpd_sasl_auth_enable=yes
# -o smtpd_client_restrictions=permit_sasl_authenticated,reject
#smtps inet n - n - - smtpd
# -o smtpd_tls_wrappermode=yes
# -o smtpd_sasl_auth_enable=yes
# -o smtpd_client_restrictions=permit_sasl_authenticated,reject
#628 inet n - n - - qmqpd
pickup fifo n - n 60 1 pickup
cleanup unix n - n - 0 cleanup
qmgr fifo n - n 300 1 qmgr
#qmgr fifo n - n 300 1 oqmgr
tlsmgr unix - - n 1000? 1 tlsmgr
rewrite unix - - n - - trivial-rewrite
bounce unix - - n - 0 bounce
defer unix - - n - 0 bounce
trace unix - - n - 0 bounce
verify unix - - n - 1 verify
flush unix n - n 1000? 0 flush
proxymap unix - - n - - proxymap
smtp unix - - n - - smtp
# When relaying mail as backup MX, disable fallback_relay to avoid MX loops
relay unix - - n - - smtp
-o fallback_relay=
# -o smtp_helo_timeout=5 -o smtp_connect_timeout=5
showq unix n - n - - showq
error unix - - n - - error
retry unix - - n - - error
discard unix - - n - - discard
local unix - n n - - local
virtual unix - n n - - virtual
lmtp unix - - n - - lmtp
anvil unix - - n - 1 anvil
scache unix - - n - 1 scache
#
# ====================================================================
# Interfaces to non-Postfix software. Be sure to examine the manual
# pages of the non-Postfix software to find out what options it wants.
#
# Many of the following services use the Postfix pipe(8) delivery
# agent. See the pipe(8) man page for information about ${recipient}
# and other message envelope options.
# ====================================================================
#
# maildrop. See the Postfix MAILDROP_README file for details.
# Also specify in main.cf: maildrop_destination_recipient_limit=1
#
maildrop unix - n n - - pipe
flags=DRhu user=vmail argv=/usr/local/bin/maildrop -d ${recipient}
#
# ====================================================================
#
# The Cyrus deliver program has changed incompatibly, multiple times.
#
#old-cyrus unix - n n - - pipe
# flags=R user=cyrus argv=/cyrus/bin/deliver -e -m ${extension} ${user}
#
# ====================================================================
#
# Cyrus 2.1.5 (Amos Gouaux)
# Also specify in main.cf: cyrus_destination_recipient_limit=1
#
#cyrus unix - n n - - pipe
# user=cyrus argv=/cyrus/bin/deliver -e -r ${sender} -m ${extension} ${user}
#
# ====================================================================
#
# See the Postfix UUCP_README file for configuration details.
#
#uucp unix - n n - - pipe
# flags=Fqhu user=uucp argv=uux -r -n -z -a$sender - $nexthop!rmail ($recipient)
#
# ====================================================================
#
# Other external delivery methods.
#
#ifmail unix - n n - - pipe
# flags=F user=ftn argv=/usr/lib/ifmail/ifmail -r $nexthop ($recipient)
#
#bsmtp unix - n n - - pipe
# flags=Fq. user=bsmtp argv=/usr/local/sbin/bsmtp -f $sender $nexthop $recipient
#
#scalemail-backend unix - n n - 2 pipe
# flags=R user=scalemail argv=/usr/lib/scalemail/bin/scalemail-store
# ${nexthop} ${user} ${extension}
#
#mailman unix - n n - - pipe
# flags=FR user=list argv=/usr/lib/mailman/bin/postfix-to-mailman.py
# ${nexthop} ${user}

asia_ji 回复于:2007-10-12 11:04:09

[root@mail ~]# more /etc/postfix/main.cf
# Global Postfix configuration file. This file lists only a subset
# of all parameters. For the syntax, and for a complete parameter
# list, see the postconf(5) manual page (command: "man 5 postconf").
#
# For common configuration examples, see BASIC_CONFIGURATION_README
# and STANDARD_CONFIGURATION_README. To find these documents, use
# the command "postconf html_directory readme_directory", or go to
# http://www.postfix.org/.
#
# For best results, change no more than 2-3 parameters at a time,
# and test if Postfix still works after every change.

# SOFT BOUNCE
#
# The soft_bounce parameter provides a limited safety net for
# testing. When soft_bounce is enabled, mail will remain queued that
# would otherwise bounce. This parameter disables locally-generated
# bounces, and prevents the SMTP server from rejecting mail permanently
# (by changing 5xx replies into 4xx replies). However, soft_bounce
# is no cure for address rewriting mistakes or mail routing mistakes.
#
#soft_bounce = no

# LOCAL PATHNAME INFORMATION
#
# The queue_directory specifies the location of the Postfix queue.
# This is also the root directory of Postfix daemons that run chrooted.
# See the files in examples/chroot-setup for setting up Postfix chroot
# environments on different UNIX systems.
#
queue_directory = /var/spool/postfix

# The command_directory parameter specifies the location of all
# postXXX commands.
#
command_directory = /usr/local/postfix/sbin

# The daemon_directory parameter specifies the location of all Postfix
# daemon programs (i.e. programs listed in the master.cf file). This
# directory must be owned by root.
#
daemon_directory = /usr/local/postfix/libexec

# QUEUE AND PROCESS OWNERSHIP
#
# The mail_owner parameter specifies the owner of the Postfix queue
# and of most Postfix daemon processes. Specify the name of a user
# account THAT DOES NOT SHARE ITS USER OR GROUP ID WITH OTHER ACCOUNTS
# AND THAT OWNS NO OTHER FILES OR PROCESSES ON THE SYSTEM. In
# particular, don't specify nobody or daemon. PLEASE USE A DEDICATED
# USER.
#
mail_owner = postfix

# The default_privs parameter specifies the default rights used by
# the local delivery agent for delivery to external file or command.
# These rights are used in the absence of a recipient user context.
# DO NOT SPECIFY A PRIVILEGED USER OR THE POSTFIX OWNER.
#
#default_privs = nobody

# INTERNET HOST AND DOMAIN NAMES
#
# The myhostname parameter specifies the internet hostname of this
# mail system. The default is to use the fully-qualified domain name
# from gethostname(). $myhostname is used as a default value for many
# other configuration parameters.
#
#myhostname = host.domain.tld
#myhostname = virtual.domain.tld
#myhostname = mail.dlfhw.cn

# The mydomain parameter specifies the local internet domain name.
# The default is to use $myhostname minus the first component.
# $mydomain is used as a default value for many other configuration
# parameters.
#
#mydomain = domain.tld
#mydomain = dlfhw.cn

# SENDING MAIL
#
# The myorigin parameter specifies the domain that locally-posted
# mail appears to come from. The default is to append $myhostname,
# which is fine for small sites. If you run a domain with multiple
# machines, you should (1) change this to $mydomain and (2) set up
# a domain-wide alias database that aliases each user to
# user@that.users.mailhost.
#
# For the sake of consistency between sender and recipient addresses,
# myorigin also specifies the default domain name that is appended
# to recipient addresses that have no @domain part.
#
#myorigin = $myhostname
#myorigin = $mydomain

# RECEIVING MAIL

# The inet_interfaces parameter specifies the network interface
# addresses that this mail system receives mail on. By default,
# the software claims all active interfaces on the machine. The
# parameter also controls delivery of mail to user@[ip.address].
#
# See also the proxy_interfaces parameter, for network addresses that
# are forwarded to us via a proxy or network address translator.
#
# Note: you need to stop/start Postfix when this parameter changes.
#
#inet_interfaces = all
#inet_interfaces = $myhostname
#inet_interfaces = $myhostname, localhost

# The proxy_interfaces parameter specifies the network interface
# addresses that this mail system receives mail on by way of a
# proxy or network address translation unit. This setting extends
# the address list specified with the inet_interfaces parameter.
#
# You must specify your proxy/NAT addresses when your system is a
# backup MX host for other domains, otherwise mail delivery loops
# will happen when the primary MX host is down.
#
#proxy_interfaces =
#proxy_interfaces = 1.2.3.4

# The mydestination parameter specifies the list of domains that this
# machine considers itself the final destination for.
#
# These domains are routed to the delivery agent specified with the
# local_transport parameter setting. By default, that is the UNIX
# compatible delivery agent that lookups all recipients in /etc/passwd
# and /etc/aliases or their equivalent.
#
# The default is $myhostname + localhost.$mydomain. On a mail domain
# gateway, you should also include $mydomain.
#
# Do not specify the names of virtual domains - those domains are
# specified elsewhere (see VIRTUAL_README).
#
# Do not specify the names of domains that this machine is backup MX
# host for. Specify those names via the relay_domains settings for
# the SMTP server, or use permit_mx_backup if you are lazy (see
# STANDARD_CONFIGURATION_README).
#
# The local machine is always the final destination for mail addressed
# to user@[the.net.work.address] of an interface that the mail system
# receives mail on (see the inet_interfaces parameter).
#
# Specify a list of host or domain names, /file/name or type:table
# Specify a list of host or domain names, /file/name or type:table
# patterns, separated by commas and/or whitespace. A /file/name
# pattern is replaced by its contents; a type:table is matched when
# a name matches a lookup key (the right-hand side is ignored).
# Continue long lines by starting the next line with whitespace.
#
# See also below, section "REJECTING MAIL FOR UNKNOWN LOCAL USERS".
#
#mydestination = $myhostname, localhost.$mydomain, localhost
#mydestination = $myhostname, localhost.$mydomain, localhost, $mydomain
#mydestination = $myhostname, localhost.$mydomain, localhost, $mydomain,
# mail.$mydomain, www.$mydomain, ftp.$mydomain

# REJECTING MAIL FOR UNKNOWN LOCAL USERS
#
# The local_recipient_maps parameter specifies optional lookup tables
# with all names or addresses of users that are local with respect
# to $mydestination, $inet_interfaces or $proxy_interfaces.
#
# If this parameter is defined, then the SMTP server will reject
# mail for unknown local users. This parameter is defined by default.
#
# To turn off local recipient checking in the SMTP server, specify
# local_recipient_maps = (i.e. empty).
#
# The default setting assumes that you use the default Postfix local
# delivery agent for local delivery. You need to update the
# local_recipient_maps setting if:
#
# - You define $mydestination domain recipients in files other than
# /etc/passwd, /etc/aliases, or the $virtual_alias_maps files.
# For example, you define $mydestination domain recipients in
# the $virtual_mailbox_maps files.
#
# - You redefine the local delivery agent in master.cf.
#
# - You redefine the "local_transport" setting in main.cf.
#
# - You use the "luser_relay", "mailbox_transport", or "fallback_transport"
# feature of the Postfix local delivery agent (see local(8)).
#
# Details are described in the LOCAL_RECIPIENT_README file.
#
# Beware: if the Postfix SMTP server runs chrooted, you probably have
# to access the passwd file via the proxymap service, in order to
# overcome chroot restrictions. The alternative, having a copy of
# the system passwd file in the chroot jail is just not practical.
#
# The right-hand side of the lookup tables is conveniently ignored.
# In the left-hand side, specify a bare username, an @domain.tld
# wild-card, or specify a user@domain.tld address.
#
#local_recipient_maps = unix:passwd.byname $alias_maps
#local_recipient_maps = proxy:unix:passwd.byname $alias_maps
#local_recipient_maps =

# The unknown_local_recipient_reject_code specifies the SMTP server
# response code when a recipient domain matches $mydestination or
# ${proxy,inet}_interfaces, while $local_recipient_maps is non-empty
# and the recipient address or address local-part is not found.
#
# The default setting is 550 (reject mail) but it is safer to start
# with 450 (try again later) until you are certain that your
# local_recipient_maps settings are OK.
#
unknown_local_recipient_reject_code = 550

# TRUST AND RELAY CONTROL

# The mynetworks parameter specifies the list of "trusted" SMTP
# clients that have more privileges than "strangers".
#
# In particular, "trusted" SMTP clients are allowed to relay mail
# through Postfix. See the smtpd_recipient_restrictions parameter
# in postconf(5).

asia_ji 回复于:2007-10-12 11:06:44

[root@mail ~]# /usr/local/postfix/sbin/postconf -a
cyrus
dovecot
[root@mail ~]# /usr/local/postfix/sbin/postconf -n
alias_maps = hash:/etc/aliases
broken_sasl_auth_clients = yes
command_directory = /usr/local/postfix/sbin
config_directory = /etc/postfix
daemon_directory = /usr/local/postfix/libexec
debug_peer_level = 2
html_directory = /chroot/www/postfix_html
mail_owner = postfix
mailq_path = /usr/bin/mailq
manpage_directory = /usr/local/postfix/man
message_size_limit = 14336000
mynetworks = 61.189.86.0/26, 127.0.0.0/8
newaliases_path = /usr/bin/newaliases
queue_directory = /var/spool/postfix
readme_directory = no
sample_directory = /etc/postfix
sendmail_path = /usr/sbin/sendmail
setgid_group = postdrop
smtpd_banner = Welcome to our $myhostname ESMTP,Warning: Version not Available!
smtpd_recipient_restrictions = permit_mynetworks,permit_sasl_authenticated,reject_invalid_hostname,reject_non_fqdn_hostname,reject_unknown_sender_domain,reject_non_fqdn_sender,reject_non_fqdn_recipient,reject_unknown_recipient_domain,reject_unauth_pipelining,reject_unauth_destination
smtpd_sasl_auth_enable = yes
smtpd_sasl_local_domain = $myhostname
smtpd_sasl_security_options = noanonymous
unknown_local_recipient_reject_code = 550
virtual_alias_domains =
virtual_alias_maps = mysql:/etc/postfix/mysql_virtual_alias_maps.cf
virtual_gid_maps = static:1001
virtual_mailbox_base = /chroot/mail
virtual_mailbox_domains = mysql:/etc/postfix/mysql_virtual_domains_maps.cf
virtual_mailbox_limit = 20971520
virtual_mailbox_maps = mysql:/etc/postfix/mysql_virtual_mailbox_maps.cf
virtual_transport = maildrop
virtual_uid_maps = static:1001

marion 回复于:2007-10-12 11:11:59

maildrop unix - n n - - pipe
flags=DRhu user=vmail argv=/usr/local/bin/maildrop -d ${recipient}

以上第二行前一定要有空格。

marion 回复于:2007-10-12 11:13:07

smtpd_recipient_restrictions = permit_mynetworks,permit_sasl_authenticated,reject_invalid_hostname,reject_non_fqdn_hostname,reject_unknown_sender_domain,reject_non_fqdn_sender,reject_non_fqdn_recipient,reject_unknown_recipient_domain,reject_unauth_pipelining,reject_unauth_destination

以上第二行起后面的行前一定要有空格。

marion 回复于:2007-10-12 11:15:24

引用:Oct 12 10:43:37 mail postfix/smtpd[2407]: sql_select option missing
Oct 12 10:43:37 mail postfix/smtpd[2407]: auxpropfunc error no mechanism available


检查一下sasl能否正常工作,并查看一下/usr/local/lib/sasl2/smtp.conf的内容是否正确。

改动过任何配置文件后可靠的做法是重启相关的服务,切记!

asia_ji 回复于:2007-10-12 12:56:41

引用:原帖由 marion 于 2007-10-12 11:15 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=7456319&ptid=987344


检查一下sasl能否正常工作,并查看一下/usr/local/lib/sasl2/smtp.conf的内容是否正确。

改动过任何配置文件后可靠的做法是重启相关的服务,切记!


空格是都有的,还是那个问题:temporary failure. Command output: /usr/local/bin/maildrop: Unable to change to home directory.

另外sasl服务正常,想求证一下:/usr/local/lib/sasl2/smtp.conf最终的内容应该是什么?

是这样:
pwcheck_method: authdaemond
log_level: 3
mech_list: PLAIN LOGIN
authdaemond_path:/usr/local/courier-authlib/var/spool/authdaemon/socket

还是这样:
pwcheck_method: saslauthd
mech_list: PLAIN LOGIN
pwcheck_method: authdaemond
log_level: 3
mech_list: PLAIN LOGIN
authdaemond_path:/usr/local/courier-authlib/var/spool/authdaemon/socket

marion 回复于:2007-10-12 13:51:44

引用:是这样:
pwcheck_method: authdaemond
log_level: 3
mech_list: PLAIN LOGIN
authdaemond_path:/usr/local/courier-authlib/var/spool/authdaemon/socket


如上

asia_ji 回复于:2007-10-12 14:00:50

marion,您好!有些具体的问题想和您请教!能否通过msn?

asia_ji 回复于:2007-10-12 14:03:55

我的msn:
asia_ji@msn.com

您的msn是:yongliang@live.com吗?

marion 回复于:2007-10-12 16:19:34

引用:原帖由 asia_ji 于 2007-10-12 10:19 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=7455856&ptid=987344
(temporary failure. Command output: /usr/local/bin/maildrop: Unable to change to home directory. )
这是由于什么原因导致的??

Oct 12 10:05:26 mail postfix/pickup[11414]: 4112426B23: uid=1001 ...


问题已经解决,原因是以下两行中在/chroot/mail后少了个"/"符号,修改为/choort/mail/ 即可。
MYSQL_HOME_FIELD concat('/chroot/mail',maildir)
MYSQL_MAILDIR_FIELD concat('/chroot/mail',maildir)

asia_ji 回复于:2007-10-12 16:50:12

两个 “/” 让我郁闷了两天,不过亦非常值得,非常感谢 marion ,认识你非常高兴。

天使别哭 回复于:2007-10-13 16:40:58

:wink: 太详细了,需要用一两天才能实践完成

cnhawk386 回复于:2007-10-13 17:13:00

引用:原帖由 cnhawk386 于 2007-10-12 10:51 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=7456116&ptid=987344
SYS_MYSQL_TABLE = mailbox
SYS_MYSQL_ATTR_USERNAME = username
SYS_MYSQL_ATTR_DOMAIN = domain
SYS_MYSQL_ATTR_PASSWD = password
以上用来指定验正用户登录里所用到的表,以及用户名、域名和用户密码分 ...



no answer????

zdyldy 回复于:2007-10-14 11:59:33

#/usr/local/postfix/sbin/postconf -a
cyrus
dovecot
#vi /etc/postfix/main.cf
############################CYRUS-SASL############################
broken_sasl_auth_clients = yes
smtpd_recipient_restrictions=permit_mynetworks,permit_sasl_authenticated,reject_invalid_hostname,reject_non_fqdn_hostname,reject_unknown_sender_domain,reject_non_fqdn_sender,reject_non_fqdn_recipient,reject_unknown_recipient_domain,reject_unauth_pipelining,reject_unauth_destination
smtpd_sasl_auth_enable = yes
smtpd_sasl_local_domain = $myhostname
smtpd_sasl_security_options = noanonymous
smtpd_sasl_application_name = smtpd
smtpd_banner = Welcome to our $myhostname ESMTP,Warning: Version not Available!

#vi /usr/local/lib/sasl2/smtpd.conf
pwcheck_method: saslauthd
mech_list: PLAIN LOGIN

#/usr/local/postfix/sbin/postfix reload


[root@localhost postfix]# telnet localhost 25
Trying 127.0.0.1...
Connected to localhost.localdomain (127.0.0.1).
Escape character is '^]'.
Connection closed by foreign host. (看看这里啊,为什么自己就把连接关闭了呢.)
#[root@localhost postfix]#


下面是贴子给出的正确的配置,可是我在执行 telnet localhost 25的时候就自动关闭了.帮我解决一下啊.

# telnet localhost 25
Trying 127.0.0.1...
Connected to localhost.localdomain (127.0.0.1).
Escape character is '^]'.
220 Welcome to our mail.benet.org ESMTP,Warning: Version not Available!
ehlo mail.benet.org
250-mail.benet.org
250-PIPELINING
250-SIZE 10240000
250-VRFY
250-ETRN
250-AUTH PLAIN LOGIN
250-AUTH=PLAIN LOGIN
250-ENHANCEDSTATUSCODES
250-8BITMIME
250 DSN





#/usr/local/postfix/sbin/postconf -a
cyrus
dovecot
#vi /etc/postfix/main.cf
############################CYRUS-SASL############################
broken_sasl_auth_clients = yes
smtpd_recipient_restrictions=permit_mynetworks,permit_sasl_authenticated,reject_invalid_hostname,reject_non_fqdn_hostname,reject_unknown_sender_domain,reject_non_fqdn_sender,reject_non_fqdn_recipient,reject_unknown_recipient_domain,reject_unauth_pipelining,reject_unauth_destination
smtpd_sasl_auth_enable = yes
smtpd_sasl_local_domain = $myhostname
smtpd_sasl_security_options = noanonymous
smtpd_sasl_application_name = smtpd
smtpd_banner = Welcome to our $myhostname ESMTP,Warning: Version not Available!

#vi /usr/local/lib/sasl2/smtpd.conf
pwcheck_method: saslauthd
mech_list: PLAIN LOGIN

#/usr/local/postfix/sbin/postfix reload

[root@localhost postfix]# telnet localhost 25
Trying 127.0.0.1...
Connected to localhost.localdomain (127.0.0.1).
Escape character is '^]'.
Connection closed by foreign host. 自动关闭了,是怎么回事啊?
[root@localhost postfix]#

下面是给出的正确的配置.


# telnet localhost 25
Trying 127.0.0.1...
Connected to localhost.localdomain (127.0.0.1).
Escape character is '^]'.
220 Welcome to our mail.benet.org ESMTP,Warning: Version not Available!
ehlo mail.benet.org
250-mail.benet.org
250-PIPELINING
250-SIZE 10240000
250-VRFY
250-ETRN
250-AUTH PLAIN LOGIN
250-AUTH=PLAIN LOGIN
250-ENHANCEDSTATUSCODES
250-8BITMIME
250 DSN



我的第二问题就是,我公司有100个用户,我怎么把用户添加进来呢.给我写一例子好么.例如其中一个用户是yuanll

公司的域名是test.org 机器名是mail.test.org

cndefu 回复于:2007-10-15 16:01:30

真的是超精华版呀

Weikey 回复于:2007-10-15 16:19:47

强烈建议楼主把安装过程做成一个HTML文档哦(顺便把一些常见问题也编辑进去)!这样最直观了!阅读也更方便!流芳百世啊!我代表党和人民感谢你!

[ 本帖最后由 Weikey 于 2007-10-15 16:27 编辑 ]

zdyldy 回复于:2007-10-15 18:36:35

[root@mail DBD-mysql-3.0002_4]# perl Makefile.PL
Can't locate DBI/DBD.pm in @INC (@INC contains: /usr/lib/perl5/site_perl/5.8.8/i386-linux-thread-multi /usr/lib/perl5/site_perl/5.8.7/i386-linux-thread-multi /usr/lib/perl5/site_perl/5.8.6/i386-linux-thread-multi /usr/lib/perl5/site_perl/5.8.5/i386-linux-thread-multi /usr/lib/perl5/site_perl/5.8.8 /usr/lib/perl5/site_perl/5.8.7 /usr/lib/perl5/site_perl/5.8.6 /usr/lib/perl5/site_perl/5.8.5 /usr/lib/perl5/site_perl /usr/lib/perl5/vendor_perl/5.8.8/i386-linux-thread-multi /usr/lib/perl5/vendor_perl/5.8.7/i386-linux-thread-multi /usr/lib/perl5/vendor_perl/5.8.6/i386-linux-thread-multi /usr/lib/perl5/vendor_perl/5.8.5/i386-linux-thread-multi /usr/lib/perl5/vendor_perl/5.8.8 /usr/lib/perl5/vendor_perl/5.8.7 /usr/lib/perl5/vendor_perl/5.8.6 /usr/lib/perl5/vendor_perl/5.8.5 /usr/lib/perl5/vendor_perl /usr/lib/perl5/5.8.8/i386-linux-thread-multi /usr/lib/perl5/5.8.8 .) at Makefile.PL line 23.
[root@mail DBD-mysql-3.0002_4]# make
make: *** 没有指明目标并且找不到makefile 停止
[root@mail DBD-mysql-3.0002_4]#


请问 marion 老大这是什么意思啊。

marion 回复于:2007-10-15 21:45:12

这个我还真的没有尝试过,不敢妄言。不知道其他朋友有没有解决办法?:em14:

我回头去查一查相关材料,如果你有了结果,也希望能共享出来。

[ 本帖最后由 marion 于 2007-10-15 21:46 编辑 ]

marion 回复于:2007-10-15 21:48:52

多承二位谬赞,如果对大家有所帮助,也算是没有白忙活了……

marion 回复于:2007-10-15 21:51:44

你的第一步“ perl Makefile.PL”由于依赖关系不满足而没有完成,错误提示“Can't locate DBI/DBD.pm ”已经指明缺乏DBI/DBD.pm ;若想省功夫,直接去发行版光盘上找到perl-DBI的rpm包安装应该可以解决此问题。

zdyldy 回复于:2007-10-16 17:58:28

回复 #146 zdyldy 的帖子


你的第一步“ perl Makefile.PL”由于依赖关系不满足而没有完成,错误提示“Can't locate DBI/DBD.pm ”已经指明缺乏DBI/DBD.pm ;若想省功夫,直接去发行版光盘上找到perl-DBI的rpm包安装应该可以解决此问题。



非常感谢,问题解决了。

zdyldy 回复于:2007-10-16 18:12:06

marion 老大,我现在除了病毒库那块,前面的都安装完了,有两个问题没有解决。

第一个问题是:

这是我运行的结果,系统自动关闭了。安装完postfix的时候是没有问题的,完全可用。可是安装完cyrus-sasl后,来启用这个认证,就这样了。

[root@mail Auth]# telnet localhost 25
Trying 127.0.0.1...
Connected to localhost.localdomain (127.0.0.1).
Escape character is '^]'.
Connection closed by foreign host.
[root@mail Auth]#


这是日志信息。

Oct 16 16:42:45 mail postfix/master[5292]: warning: process /usr/local/postfix/libexec/smtpd pid 5351 exit status 1
Oct 16 16:42:45 mail postfix/master[5292]: warning: /usr/local/postfix/libexec/smtpd: bad command startup -- throttling
Oct 16 16:43:45 mail postfix/smtpd[5376]: warning: dict_nis_init: NIS domain name not set - NIS lookups disabled
Oct 16 16:43:45 mail postfix/smtpd[5376]: warning: xsasl_cyrus_server_get_mechanism_list: no applicable SASL mechanisms
Oct 16 16:43:45 mail postfix/smtpd[5376]: fatal: no SASL authentication mechanisms
Oct 16 16:43:46 mail postfix/master[5292]: warning: process /usr/local/postfix/libexec/smtpd pid 5376 exit status 1
Oct 16 16:43:46 mail postfix/master[5292]: warning: /usr/local/postfix/libexec/smtpd: bad command startup -- throttling

第二个问题是:


我在流览器里输入http://mail.test.com 进入extmail页面。

我是不是该点击注册用户呢,来建立我公司的所有用户。还是该怎么把我公司的用户全添加到邮箱里呢。

当我点击注册用户时,跳转到了令外一个界面,提示 指定域名test.com域名不存在。

我把图截下来了,可是怎么发上去呢。

zdyldy 回复于:2007-10-16 18:13:32

第二个问题是:


我在流览器里输入http://mail.test.com 进入extmail页面。

我是不是该点击注册用户呢,来建立我公司的所有用户。还是该怎么把我公司的用户全添加到邮箱里呢。

当我点击注册用户时,跳转到了令外一个界面,提示 指定域名test.com域名不存在。

我把图截下来了,可是怎么发上去呢。


不好意思,打错了,不是注册用户,而是免费注册邮箱。

zdyldy 回复于:2007-10-16 18:19:02

你好这是我截的两个图片。

输入新建文件夹的名称.rar

ypxns 回复于:2007-10-16 18:50:01

背景:我的系统上存在两个域名,一个本地域名设为pp.com,一个虚拟域名设为test.com
marion兄 ,我已经按照你的做法把邮件系统搭建起来了,但是测试的时候发生以下问题:
问题一:当我使用OE登录邮件服务器时,发生如下情况:我用的是系统帐号登录的!我检查了POP3服务和认证模块,好像也没有什么问题!我以为帐号的密码错了,后来重新改了密码,但仍然是这样的情况!(见附图)后来我改用虚拟账号看看,可结果还是一样!
关于认证,我的后台认证服务如下:(支持login 和plain)
/usr/local/sasl2/sbin/saslauthd -a shadow pam


我的/var/log/maillog如下:
Oct 14 00:47:59 mail pop3d: Connection, ip=[192.168.1.10]
Oct 14 00:47:59 mail pop3d: LOGIN FAILED, user=test, ip=[192.168.1.10]
Oct 14 00:48:04 mail pop3d: Disconnected, ip=[192.168.1.10]
Oct 14 00:48:10 mail pop3d: Connection, ip=[192.168.1.10]
Oct 14 00:48:10 mail pop3d: LOGIN FAILED, user=test, ip=[192.168.1.10]
Oct 14 00:48:15 mail pop3d: Disconnected, ip=[192.168.1.10]
……………………………………………..
不知道各位做的时候有没有出现类似的问题?????

问题二:当我使用系统帐号登录邮件服务器,在邮件服务器上来给某个用户发邮件,该用户用Extmail来收邮件,发现以下问题:
来自: test@pp.com 将该来信人加到地址本中
发给: undisclosed-recipients:;
日期: Sun, 14 Oct 2007 00:29:43 +0800 (CST)
收件人的地址没有显示出来而是像上面的 情况!!不知道这是怎么回事???????

[ 本帖最后由 ypxns 于 2007-10-16 18:52 编辑 ]
截图_2025-11-15_14-56-54.jpg
截图_2025-11-15_14-56-54.jpg (69.94 KiB) 查看 867 次
ypxns 回复于:2007-10-16 18:55:16

你先进入EXTMAN邮件服务管理后台进行添加域名(记的要将允许用户注册这个勾打上),再进行添加用户就可以了!

ypxns 回复于:2007-10-16 19:04:34

Oct 16 16:43:45 mail postfix/smtpd[5376]: warning: xsasl_cyrus_server_get_mechanism_list: no applicable SASL mechanisms

从上面的日志来看, SASL mechanisms没有,检查一下smtpd.conf文件有没有声明:
mech_list:PLAIN LOGIN
或者是 在 编译时没有把上面的认证方式给添加进去!!

marion 回复于:2007-10-16 19:47:18

对于第一个问题,你可以开启authdaemon的日志,通过更为详细的认证信息可以很方便的定位错误所在。如果根据认证的详细信息仍无法定位错误,你可以把相关的日志发上来。

对于第二个问题,我没有看太明白你所要描述的问题:em14: ,不好意思,不过,你也应该通过相关的日志信息来排查错误原因。可以把相关的日志发上来帮你看看。

同时,很感谢你回答其他朋友的问题:em02:

zdyldy 回复于:2007-10-17 14:27:09

配置完后,在extmail中建立帐户后,可以收发邮件了。但是用客服端软件outlook配置连接提示:查找邮件服务器SMTP和POP3成功,登陆到接收邮件服务器(pop3)报错,信息为:因为POP3接收邮件服务器不接受您的用户名和密码,所以Outlook无法连接到该服务器。是不是我们配置的帐户有问题?

zdyldy 回复于:2007-10-17 15:48:36

Oct 17 14:05:55 mail pop3d: Connection, ip=[10.166.211.88]
Oct 17 14:05:55 mail pop3d: LOGIN FAILED, user=yuancj, ip=[10.166.211.88]
Oct 17 14:06:00 mail pop3d: Disconnected, ip=[10.166.211.88]
Oct 17 14:06:02 mail postfix/smtpd[7787]: connect from unknown[10.166.211.88]
Oct 17 14:06:03 mail postfix/smtpd[7787]: warning: mysql query failed: Table 'extmail.extmail' doesn't exist
Oct 17 14:06:03 mail postfix/smtpd[7787]: NOQUEUE: reject: RCPT from unknown[10.166.211.88]: 451 4.3.0 <yuancj@oli.cn>: Temporary lookup failure; from=<yuancj@oli.cn> to=<yuancj@oli.cn> proto=SMTP helo=<jsgl3>
Oct 17 14:06:03 mail postfix/cleanup[7794]: 07C462C4A6E: message-id=<20071017060603.07C462C4A6E@mail.oli.cn>
Oct 17 14:06:03 mail postfix/qmgr[6588]: 07C462C4A6E: from=<[email]double-bounce@mail.oli.cn[/email]>, size=687, nrcpt=1 (queue active)
Oct 17 14:06:03 mail postfix/smtpd[7787]: disconnect from unknown[10.166.211.88]
Oct 17 14:06:03 mail postfix/local[7796]: 07C462C4A6E: to=<root@mail.oli.cn>, orig_to=<postmaster>, relay=local, delay=0.04, delays=0.02/0.01/0/0.01, dsn=2.0.0, status=sent (delivered to mailbox)
Oct 17 14:06:03 mail postfix/qmgr[6588]: 07C462C4A6E: removed


这是我用outlook配置时的maillog信息。好像错误在"extmail.extmail"这是不是寻找extmail数据库下面的extmail表的意思,如果是那我该怎么改成mailbox表。

[ 本帖最后由 zdyldy 于 2007-10-17 15:52 编辑 ]

marion 回复于:2007-10-17 20:39:12

引用:……这是我用outlook配置时的maillog信息。好像错误在"extmail.extmail"这是不是寻找extmail数据库下面的extmail表的意思,如果是那我该怎么改成mailbox表。


这个应该是在authmysqlrc中修改。

[ 本帖最后由 marion 于 2007-11-2 11:33 编辑 ]

ypxns 回复于:2007-10-17 20:56:42

我在文件/etc/authdaemonrc中启用了调试,日志文件/var/log/maillog如下:
Oct 15 18:23:18 mail pop3d: Connection, ip=[192.168.1.10]
Oct 15 18:23:18 mail authdaemond: received auth request, service=pop3, authtype=login
Oct 15 18:23:18 mail authdaemond: authmysql: trying this module
Oct 15 18:23:18 mail authdaemond: SQL query: SELECT username, password, "", '1000', '1000', concat('/var/mailbox/',maildir), concat('/var/mailbox/',maildir), "", name, "" FROM mailbox WHERE username = "ypxns_98"
Oct 15 18:23:18 mail authdaemond: zero rows returned
Oct 15 18:23:18 mail authdaemond: no password available to compare
Oct 15 18:23:18 mail authdaemond: authmysql: REJECT - try next module
Oct 15 18:23:18 mail authdaemond: FAIL, all modules rejected
Oct 15 18:23:18 mail pop3d: LOGIN FAILED, user=ypxns_98, ip=[192.168.1.10]
Oct1518:23:23mailpop3d:Disconnected,ip=[192.168.1.10]……………………………………………..
从提示的信息来看,说mysql中没有可以对比的密码,难道是我的数据库中没有存储用户密码吗??我查看了一下Mysql,其结果如下所示:用户密码是存在的!

mysql> select * from mailbox;
+-------------------+----------+------------------------------------+----------+------+----------+----------------------------+-------------------+----------+--------------+----------+-----------+-----------+---------------------+---------------------+--------+------------------+--------------+-------------+----------------+----------------+-------------+-------------+
| username | uid | password | clearpwd | name | mailhost | maildir | homedir | quota | netdiskquota | domain | uidnumber | gidnumber | createdate | expiredate | active | disablepwdchange | disablesmtpd | disablesmtp | disablewebmail | disablenetdisk | disableimap | disablepop3 |
+-------------------+----------+------------------------------------+----------+------+----------+----------------------------+-------------------+----------+--------------+----------+-----------+-----------+---------------------+---------------------+--------+------------------+--------------+-------------+----------------+----------------+-------------+-------------+
| ypxns_98@test.com | ypxns_98 | $1$6N6Xoc8p$SWfYUchlpANM3g0lFLdA10 | | yp | | test.com/ypxns_98/Maildir/ | test.com/ypxns_98 | 5242880S | 5242880S | test.com | 1000 | 1000 | 2007-10-13 22:15:13 | 2008-10-12 22:14:42 | 1 | 0 | 0 | 0 | 0 | 0 | 1 | 0 |
| pp@test.com | pp | $1$eBeLYmGD$OLZHGHKtjyP677JxqT/oj1 | | pp | | test.com/pp/Maildir/ | test.com/pp | 5242880S | 5242880S | test.com | 1000 | 1000 | 2007-10-13 15:50:02 | 2008-10-12 15:49:49 | 1 | 0 | 0 | 0 | 0 | 0 | 1 | 0 |
+-------------------+----------+------------------------------------+----------+------+----------+----------------------------+-------------------+----------+--------------+----------+-----------+-----------+---------------------+---------------------+--------+------------------+--------------+-------------+----------------+----------------+-------------+-------------+
2 rows in set (0.03 sec)

当我用authtest的时候,日志和上面一样
[root@mail sbin]# ./authtest -s pop3 ypxns_98 123456
Authentication FAILED: Operation not permitted
[root@mail sbin]#


另外我 问一 下,关于那个校验码,我rpm安装perl-gd的时候,提示需要libgd.so.2,但是这个在/usr/lib/和/usr/local/lib/下都存在,可是 好像仍然找不到!!!!所以后来我就把它给注释掉了!!!

[ 本帖最后由 ypxns 于 2007-10-17 21:05 编辑 ]

ypxns 回复于:2007-10-17 21:14:25

引用:原帖由 liheng 于 2007-9-18 23:11 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=7369834&ptid=987344

marion 兄,我猜想也是这里的问题,刚开始还没反映过来,还没想明白应该在哪里改。刚刚终于想通了。
事后经过确认确实也是这里的问题,
解决方法:
在 outlook 里的帐号名写全(test@test.com)就OK了,mar ...


这个 和我一样的问题,原来是这样的啊!恩,再试一下!

zdyldy 回复于:2007-10-18 08:29:30

回复 #159 zdyldy 的帖子


[quota]……这是我用outlook配置时的maillog信息。好像错误在"extmail.extmail"这是不是寻找extmail数据库下面的extmail表的意思,如果是那我该怎么改成mailbox表。[/quota]

这个应该是在authmysqlrc中修改。


感谢帮忙!

我进那个文件看了啊,好像没有错误。对应的表是extmail,对应的表是mailbox。麻繁再帮我看一下,是哪里出了问题呢?

marion 回复于:2007-10-18 09:08:03

对应的“数据库”应该为extmail,对应的表为mailbox。

另,你再检查一下main.cf中关于虚拟域配置的部分。修改之后别忘了重启相关的服务。

如果还不行,把你的相关文件贴上来。

[ 本帖最后由 marion 于 2007-10-18 09:10 编辑 ]

zdyldy 回复于:2007-10-18 10:29:09

以上的方法在CentOS5上面适用吗?



rhel 5 上可以。

zdyldy 回复于:2007-10-18 10:49:48

回复 #163 zdyldy 的帖子


对应的“数据库”应该为extmail,对应的表为mailbox。

另,你再检查一下main.cf中关于虚拟域配置的部分。修改之后别忘了重启相关的服务。

如果还不行,把你的相关文件贴上来。


请看outlook上提示的错误信息。

发送测试电子邮件消息:outlook无法接到发送邮件服务器(smtp),可能是发送服务器的ssl或端口设置不正确。请在“高级”选项项卡上的“其它设置”中检查端口和ssl设置。

qdwmail 回复于:2007-10-18 10:50:55

楼主做一个PDF吧,方便大家下载

MYSQLER 回复于:2007-10-18 10:55:17

telnet localhost 25
Trying 127.0.0.1...
Connected to localhost.localdomain (127.0.0.1).
Escape character is '^]'.
一直在这没有任何反应

zdyldy 回复于:2007-10-18 13:07:02

回复 #163 zdyldy 的帖子


对应的“数据库”应该为extmail,对应的表为mailbox。

另,你再检查一下main.cf中关于虚拟域配置的部分。修改之后别忘了重启相关的服务。

如果还不行,把你的相关文件贴上来。

这是我main.cf文件的全部内容。


# Global Postfix configuration file. This file lists only a subset
# of all parameters. For the syntax, and for a complete parameter
# list, see the postconf(5) manual page (command: "man 5 postconf").
#
# For common configuration examples, see BASIC_CONFIGURATION_README
# and STANDARD_CONFIGURATION_README. To find these documents, use
# the command "postconf html_directory readme_directory", or go to
# http://www.postfix.org/.
#
# For best results, change no more than 2-3 parameters at a time,
# and test if Postfix still works after every change.

# SOFT BOUNCE
#
# The soft_bounce parameter provides a limited safety net for
# testing. When soft_bounce is enabled, mail will remain queued that
# would otherwise bounce. This parameter disables locally-generated
# bounces, and prevents the SMTP server from rejecting mail permanently
# (by changing 5xx replies into 4xx replies). However, soft_bounce
# is no cure for address rewriting mistakes or mail routing mistakes.
#
#soft_bounce = no

# LOCAL PATHNAME INFORMATION
#
# The queue_directory specifies the location of the Postfix queue.
# This is also the root directory of Postfix daemons that run chrooted.
# See the files in examples/chroot-setup for setting up Postfix chroot
# environments on different UNIX systems.
#
queue_directory = /var/spool/postfix

# The command_directory parameter specifies the location of all
# postXXX commands.
#
command_directory = /usr/local/postfix/sbin

# The daemon_directory parameter specifies the location of all Postfix
# daemon programs (i.e. programs listed in the master.cf file). This
# directory must be owned by root.
#
daemon_directory = /usr/local/postfix/libexec

# QUEUE AND PROCESS OWNERSHIP
#
# The mail_owner parameter specifies the owner of the Postfix queue
# and of most Postfix daemon processes. Specify the name of a user
# account THAT DOES NOT SHARE ITS USER OR GROUP ID WITH OTHER ACCOUNTS
# AND THAT OWNS NO OTHER FILES OR PROCESSES ON THE SYSTEM. In
# particular, don't specify nobody or daemon. PLEASE USE A DEDICATED
# USER.
#
mail_owner = postfix

# The default_privs parameter specifies the default rights used by
# the local delivery agent for delivery to external file or command.
# These rights are used in the absence of a recipient user context.
# DO NOT SPECIFY A PRIVILEGED USER OR THE POSTFIX OWNER.
#
#default_privs = nobody

# INTERNET HOST AND DOMAIN NAMES
#
# The myhostname parameter specifies the internet hostname of this
# mail system. The default is to use the fully-qualified domain name
# from gethostname(). $myhostname is used as a default value for many
# other configuration parameters.
#
myhostname = mail.oli.cn
#myhostname = virtual.domain.tld

# The mydomain parameter specifies the local internet domain name.
# The default is to use $myhostname minus the first component.
# $mydomain is used as a default value for many other configuration
# parameters.
#
mydomain = oli.cn

# SENDING MAIL
#
# The myorigin parameter specifies the domain that locally-posted
# mail appears to come from. The default is to append $myhostname,
# which is fine for small sites. If you run a domain with multiple
# machines, you should (1) change this to $mydomain and (2) set up
# a domain-wide alias database that aliases each user to
# user@that.users.mailhost.
#
# For the sake of consistency between sender and recipient addresses,
# myorigin also specifies the default domain name that is appended
# to recipient addresses that have no @domain part.
#
myorigin = oli.cn
#myorigin = $mydomain

# RECEIVING MAIL

# The inet_interfaces parameter specifies the network interface
# addresses that this mail system receives mail on. By default,
# the software claims all active interfaces on the machine. The
# parameter also controls delivery of mail to user@[ip.address].
#
# See also the proxy_interfaces parameter, for network addresses that
# are forwarded to us via a proxy or network address translator.
#
# Note: you need to stop/start Postfix when this parameter changes.
#
inet_interfaces = all
#inet_interfaces = $myhostname
#inet_interfaces = $myhostname, localhost

# The proxy_interfaces parameter specifies the network interface
# addresses that this mail system receives mail on by way of a
# proxy or network address translation unit. This setting extends
# the address list specified with the inet_interfaces parameter.
#
# You must specify your proxy/NAT addresses when your system is a
# backup MX host for other domains, otherwise mail delivery loops
# will happen when the primary MX host is down.
#
#proxy_interfaces =
#proxy_interfaces = 1.2.3.4

# The mydestination parameter specifies the list of domains that this
# machine considers itself the final destination for.
#
# These domains are routed to the delivery agent specified with the
# local_transport parameter setting. By default, that is the UNIX
# compatible delivery agent that lookups all recipients in /etc/passwd
# and /etc/aliases or their equivalent.
#
# The default is $myhostname + localhost.$mydomain. On a mail domain
# gateway, you should also include $mydomain.
#
# Do not specify the names of virtual domains - those domains are
# specified elsewhere (see VIRTUAL_README).
#
# Do not specify the names of domains that this machine is backup MX
# host for. Specify those names via the relay_domains settings for
# the SMTP server, or use permit_mx_backup if you are lazy (see
# STANDARD_CONFIGURATION_README).
#
# The local machine is always the final destination for mail addressed
# to user@[the.net.work.address] of an interface that the mail system
# receives mail on (see the inet_interfaces parameter).
#
# Specify a list of host or domain names, /file/name or type:table
# patterns, separated by commas and/or whitespace. A /file/name
# pattern is replaced by its contents; a type:table is matched when
# a name matches a lookup key (the right-hand side is ignored).
# Continue long lines by starting the next line with whitespace.
#
# See also below, section "REJECTING MAIL FOR UNKNOWN LOCAL USERS".
#
#mydestination = $myhostname, localhost.$mydomain, localhost
#mydestination = $myhostname, localhost.$mydomain, localhost, $mydomain, oli.cn, mail.oli.cn
#mydestination = $myhostname, localhost.$mydomain, localhost, $mydomain,
# mail.$mydomain, www.$mydomain, ftp.$mydomain

# REJECTING MAIL FOR UNKNOWN LOCAL USERS
#
# The local_recipient_maps parameter specifies optional lookup tables
# with all names or addresses of users that are local with respect
# to $mydestination, $inet_interfaces or $proxy_interfaces.
#
# If this parameter is defined, then the SMTP server will reject
# mail for unknown local users. This parameter is defined by default.
#
# To turn off local recipient checking in the SMTP server, specify
# local_recipient_maps = (i.e. empty).
#
# The default setting assumes that you use the default Postfix local
# delivery agent for local delivery. You need to update the
# local_recipient_maps setting if:
#
# - You define $mydestination domain recipients in files other than
# /etc/passwd, /etc/aliases, or the $virtual_alias_maps files.
# For example, you define $mydestination domain recipients in
# the $virtual_mailbox_maps files.
#
# - You redefine the local delivery agent in master.cf.
#
# - You redefine the "local_transport" setting in main.cf.
#
# - You use the "luser_relay", "mailbox_transport", or "fallback_transport"
# feature of the Postfix local delivery agent (see local(8)).
#
# Details are described in the LOCAL_RECIPIENT_README file.
#
# Beware: if the Postfix SMTP server runs chrooted, you probably have
# to access the passwd file via the proxymap service, in order to
# overcome chroot restrictions. The alternative, having a copy of
# the system passwd file in the chroot jail is just not practical.
#
# The right-hand side of the lookup tables is conveniently ignored.
# In the left-hand side, specify a bare username, an @domain.tld
# wild-card, or specify a user@domain.tld address.
#
#local_recipient_maps = unix:passwd.byname $alias_maps
#local_recipient_maps = proxy:unix:passwd.byname $alias_maps
#local_recipient_maps =

# The unknown_local_recipient_reject_code specifies the SMTP server
# response code when a recipient domain matches $mydestination or
# ${proxy,inet}_interfaces, while $local_recipient_maps is non-empty
# and the recipient address or address local-part is not found.
#
# The default setting is 550 (reject mail) but it is safer to start
# with 450 (try again later) until you are certain that your
# local_recipient_maps settings are OK.
#
unknown_local_recipient_reject_code = 550

# TRUST AND RELAY CONTROL

# The mynetworks parameter specifies the list of "trusted" SMTP
# clients that have more privileges than "strangers".
#
# In particular, "trusted" SMTP clients are allowed to relay mail
# through Postfix. See the smtpd_recipient_restrictions parameter
# in postconf(5).
#
# You can specify the list of "trusted" network addresses by hand
# or you can let Postfix do it for you (which is the default).
#
# By default (mynetworks_style = subnet), Postfix "trusts" SMTP
# clients in the same IP subnetworks as the local machine.
# On Linux, this does works correctly only with interfaces specified
# with the "ifconfig" command.
#
# Specify "mynetworks_style = class" when Postfix should "trust" SMTP
# clients in the same IP class A/B/C networks as the local machine.
# Don't do this with a dialup site - it would cause Postfix to "trust"
# your entire provider's network. Instead, specify an explicit
# mynetworks list by hand, as described below.
#
# Specify "mynetworks_style = host" when Postfix should "trust"
# only the local machine.
#
#mynetworks_style = class
#mynetworks_style = subnet
#mynetworks_style = host

# Alternatively, you can specify the mynetworks list by hand, in
# which case Postfix ignores the mynetworks_style setting.
#
# Specify an explicit list of network/netmask patterns, where the
# mask specifies the number of bits in the network part of a host
# address.
#
# You can also specify the absolute pathname of a pattern file instead
# of listing the patterns here. Specify type:table for table-based lookups
# (the value on the table right-hand side is not used).
#
mynetworks = 10.166.211.0/24, 127.0.0.0/8
#mynetworks = $config_directory/mynetworks
#mynetworks = hash:/etc/postfix/network_table
# The relay_domains parameter restricts what destinations this system will
# relay mail to. See the smtpd_recipient_restrictions description in
# postconf(5) for detailed information.
#
# By default, Postfix relays mail
# - from "trusted" clients (IP address matches $mynetworks) to any destination,
# - from "untrusted" clients to destinations that match $relay_domains or
# subdomains thereof, except addresses with sender-specified routing.
# The default relay_domains value is $mydestination.
#
# In addition to the above, the Postfix SMTP server by default accepts mail
# that Postfix is final destination for:
# - destinations that match $inet_interfaces or $proxy_interfaces,
# - destinations that match $mydestination
# - destinations that match $virtual_alias_domains,
# - destinations that match $virtual_mailbox_domains.
# These destinations do not need to be listed in $relay_domains.
#
# Specify a list of hosts or domains, /file/name patterns or type:name
# lookup tables, separated by commas and/or whitespace. Continue
# long lines by starting the next line with whitespace. A file name
# is replaced by its contents; a type:name table is matched when a
# (parent) domain appears as lookup key.
#
# NOTE: Postfix will not automatically forward mail for domains that
# list this system as their primary or backup MX host. See the
# permit_mx_backup restriction description in postconf(5).
#
#relay_domains = $mydestination

# INTERNET OR INTRANET

# The relayhost parameter specifies the default host to send mail to
# when no entry is matched in the optional transport(5) table. When
# no relayhost is given, mail is routed directly to the destination.
#
# On an intranet, specify the organizational domain name. If your
# internal DNS uses no MX records, specify the name of the intranet
# gateway host instead.
#
# In the case of SMTP, specify a domain, host, host:port, [host]:port,
# [address] or [address]:port; the form [host] turns off MX lookups.
#
# If you're connected via UUCP, see also the default_transport parameter.
#
#relayhost = $mydomain
#relayhost = [gateway.my.domain]
#relayhost = [mailserver.isp.tld]
#relayhost = uucphost
#relayhost = [an.ip.add.ress]

# REJECTING UNKNOWN RELAY USERS
#
# The relay_recipient_maps parameter specifies optional lookup tables
# with all addresses in the domains that match $relay_domains.
#
# If this parameter is defined, then the SMTP server will reject
# mail for unknown relay users. This feature is off by default.
#
# The right-hand side of the lookup tables is conveniently ignored.
# In the left-hand side, specify an @domain.tld wild-card, or specify
# a user@domain.tld address.
#
#relay_recipient_maps = hash:/etc/postfix/relay_recipients

# INPUT RATE CONTROL
#
# The in_flow_delay configuration parameter implements mail input
# flow control. This feature is turned on by default, although it
# still needs further development (it's disabled on SCO UNIX due
# to an SCO bug).
#
# A Postfix process will pause for $in_flow_delay seconds before
# accepting a new message, when the message arrival rate exceeds the
# message delivery rate. With the default 100 SMTP server process
# limit, this limits the mail inflow to 100 messages a second more
# than the number of messages delivered per second.
#
# Specify 0 to disable the feature. Valid delays are 0..10.
#
#in_flow_delay = 1s

# ADDRESS REWRITING
#
# The ADDRESS_REWRITING_README document gives information about
# address masquerading or other forms of address rewriting including
# username->Firstname.Lastname mapping.

# ADDRESS REDIRECTION (VIRTUAL DOMAIN)
#
# The VIRTUAL_README document gives information about the many forms
# of domain hosting that Postfix supports.

# "USER HAS MOVED" BOUNCE MESSAGES
#
# See the discussion in the ADDRESS_REWRITING_README document.

# TRANSPORT MAP
#
# See the discussion in the ADDRESS_REWRITING_README document.

# ALIAS DATABASE
#
# The alias_maps parameter specifies the list of alias databases used
# by the local delivery agent. The default list is system dependent.
#
# On systems with NIS, the default is to search the local alias
# database, then the NIS alias database. See aliases(5) for syntax
# details.
#
# If you change the alias database, run "postalias /etc/aliases" (or
# wherever your system stores the mail alias file), or simply run
# "newaliases" to build the necessary DBM or DB file.
#
# It will take a minute or so before changes become visible. Use
# "postfix reload" to eliminate the delay.
#
#alias_maps = dbm:/etc/aliases
alias_maps = hash:/etc/aliases
#alias_maps = hash:/etc/aliases, nis:mail.aliases
#alias_maps = netinfo:/aliases

zdyldy 回复于:2007-10-18 13:07:52

接上贴


# The alias_database parameter specifies the alias database(s) that
# are built with "newaliases" or "sendmail -bi". This is a separate
# configuration parameter, because alias_maps (see above) may specify
# tables that are not necessarily all under control by Postfix.
#
#alias_database = dbm:/etc/aliases
#alias_database = dbm:/etc/mail/aliases
#alias_database = hash:/etc/aliases
#alias_database = hash:/etc/aliases, hash:/opt/majordomo/aliases

# ADDRESS EXTENSIONS (e.g., user+foo)
#
# The recipient_delimiter parameter specifies the separator between
# user names and address extensions (user+foo). See canonical(5),
# local(8), relocated(5) and virtual(5) for the effects this has on
# aliases, canonical, virtual, relocated and .forward file lookups.
# Basically, the software tries user+foo and .forward+foo before
# trying user and .forward.
#
#recipient_delimiter = +

# DELIVERY TO MAILBOX
#
# The home_mailbox parameter specifies the optional pathname of a
# mailbox file relative to a user's home directory. The default
# mailbox file is /var/spool/mail/user or /var/mail/user. Specify
# "Maildir/" for qmail-style delivery (the / is required).
#
#home_mailbox = Mailbox
#home_mailbox = Maildir/

# The mail_spool_directory parameter specifies the directory where
# UNIX-style mailboxes are kept. The default setting depends on the
# system type.
#
#mail_spool_directory = /var/mail
#mail_spool_directory = /var/spool/mail

# The mailbox_command parameter specifies the optional external
# command to use instead of mailbox delivery. The command is run as
# the recipient with proper HOME, SHELL and LOGNAME environment settings.
# Exception: delivery for root is done as $default_user.
#
# Other environment variables of interest: USER (recipient username),
# EXTENSION (address extension), DOMAIN (domain part of address),
# and LOCAL (the address localpart).
#
# Unlike other Postfix configuration parameters, the mailbox_command
# parameter is not subjected to $parameter substitutions. This is to
# make it easier to specify shell syntax (see example below).
#
# Avoid shell meta characters because they will force Postfix to run
# an expensive shell process. Procmail alone is expensive enough.
#
# IF YOU USE THIS TO DELIVER MAIL SYSTEM-WIDE, YOU MUST SET UP AN
# ALIAS THAT FORWARDS MAIL FOR ROOT TO A REAL USER.
#
#mailbox_command = /some/where/procmail
#mailbox_command = /some/where/procmail -a "$EXTENSION"

# The mailbox_transport specifies the optional transport in master.cf
# to use after processing aliases and .forward files. This parameter
# has precedence over the mailbox_command, fallback_transport and
# luser_relay parameters.
#
# Specify a string of the form transport:nexthop, where transport is
# the name of a mail delivery transport defined in master.cf. The
# :nexthop part is optional. For more details see the sample transport
# configuration file.
#
# NOTE: if you use this feature for accounts not in the UNIX password
# file, then you must update the "local_recipient_maps" setting in
# the main.cf file, otherwise the SMTP server will reject mail for
# non-UNIX accounts with "User unknown in local recipient table".
#
#mailbox_transport = lmtp:unix:/file/name
#mailbox_transport = cyrus

# The fallback_transport specifies the optional transport in master.cf
# to use for recipients that are not found in the UNIX passwd database.
# This parameter has precedence over the luser_relay parameter.
#
# Specify a string of the form transport:nexthop, where transport is
# the name of a mail delivery transport defined in master.cf. The
# :nexthop part is optional. For more details see the sample transport
# configuration file.
#
# NOTE: if you use this feature for accounts not in the UNIX password
# file, then you must update the "local_recipient_maps" setting in
# the main.cf file, otherwise the SMTP server will reject mail for
# non-UNIX accounts with "User unknown in local recipient table".
#
#fallback_transport = lmtp:unix:/file/name
#fallback_transport = cyrus
#fallback_transport =

# The luser_relay parameter specifies an optional destination address
# for unknown recipients. By default, mail for unknown@$mydestination,
# unknown@[$inet_interfaces] or unknown@[$proxy_interfaces] is returned
# as undeliverable.
#
# The following expansions are done on luser_relay: $user (recipient
# username), $shell (recipient shell), $home (recipient home directory),
# $recipient (full recipient address), $extension (recipient address
# extension), $domain (recipient domain), $local (entire recipient
# localpart), $recipient_delimiter. Specify ${name?value} or
# ${name:value} to expand value only when $name does (does not) exist.
#
# luser_relay works only for the default Postfix local delivery agent.
#
# NOTE: if you use this feature for accounts not in the UNIX password
# file, then you must specify "local_recipient_maps =" (i.e. empty) in
# the main.cf file, otherwise the SMTP server will reject mail for
# non-UNIX accounts with "User unknown in local recipient table".
#
#luser_relay = $user@other.host
#luser_relay = $local@other.host
#luser_relay = admin+$local

# JUNK MAIL CONTROLS
#
# The controls listed here are only a very small subset. The file
# SMTPD_ACCESS_README provides an overview.

# The header_checks parameter specifies an optional table with patterns
# that each logical message header is matched against, including
# headers that span multiple physical lines.
#
# By default, these patterns also apply to MIME headers and to the
# headers of attached messages. With older Postfix versions, MIME and
# attached message headers were treated as body text.
#
# For details, see "man header_checks".
#
#header_checks = regexp:/etc/postfix/header_checks

# FAST ETRN SERVICE
#
# Postfix maintains per-destination logfiles with information about
# deferred mail, so that mail can be flushed quickly with the SMTP
# "ETRN domain.tld" command, or by executing "sendmail -qRdomain.tld".
# See the ETRN_README document for a detailed description.
#
# The fast_flush_domains parameter controls what destinations are
# eligible for this service. By default, they are all domains that
# this server is willing to relay mail to.
#
#fast_flush_domains = $relay_domains

# SHOW SOFTWARE VERSION OR NOT
#
# The smtpd_banner parameter specifies the text that follows the 220
# code in the SMTP server's greeting banner. Some people like to see
# the mail version advertised. By default, Postfix shows no version.
#
# You MUST specify $myhostname at the start of the text. That is an
# RFC requirement. Postfix itself does not care.
#
#smtpd_banner = $myhostname ESMTP $mail_name
#smtpd_banner = $myhostname ESMTP $mail_name ($mail_version)

# PARALLEL DELIVERY TO THE SAME DESTINATION
#
# How many parallel deliveries to the same user or domain? With local
# delivery, it does not make sense to do massively parallel delivery
# to the same user, because mailbox updates must happen sequentially,
# and expensive pipelines in .forward files can cause disasters when
# too many are run at the same time. With SMTP deliveries, 10
# simultaneous connections to the same domain could be sufficient to
# raise eyebrows.
#
# Each message delivery transport has its XXX_destination_concurrency_limit
# parameter. The default is $default_destination_concurrency_limit for
# most delivery transports. For the local delivery agent the default is 2.

#local_destination_concurrency_limit = 2
#default_destination_concurrency_limit = 20

# DEBUGGING CONTROL
#
# The debug_peer_level parameter specifies the increment in verbose
# logging level when an SMTP client or server host name or address
# matches a pattern in the debug_peer_list parameter.
#
debug_peer_level = 1

# The debug_peer_list parameter specifies an optional list of domain
# or network patterns, /file/name patterns or type:name tables. When
# an SMTP client or server host name or address matches a pattern,
# increase the verbose logging level by the amount specified in the
# debug_peer_level parameter.
#
#debug_peer_list = 127.0.0.1
#debug_peer_list = some.domain

# The debugger_command specifies the external command that is executed
# when a Postfix daemon program is run with the -D option.
#
# Use "command .. & sleep 5" so that the debugger can attach before
# the process marches on. If you use an X-based debugger, be sure to
# set up your XAUTHORITY environment variable before starting Postfix.
#
debugger_command =
PATH=/bin:/usr/bin:/usr/local/bin:/usr/X11R6/bin
xxgdb $daemon_directory/$process_name $process_id & sleep 5

# If you can't use X, use this to capture the call stack when a
# daemon crashes. The result is in a file in the configuration
# directory, and is named after the process name and the process ID.
#
# debugger_command =
# PATH=/bin:/usr/bin:/usr/local/bin; export PATH; (echo cont;
# echo where) | gdb $daemon_directory/$process_name $process_id 2>&1
# >$config_directory/$process_name.$process_id.log & sleep 5
#
# Another possibility is to run gdb under a detached screen session.
# To attach to the screen sesssion, su root and run "screen -r
# <id_string>" where <id_string> uniquely matches one of the detached
# sessions (from "screen -list").
#
# debugger_command =
# PATH=/bin:/usr/bin:/sbin:/usr/sbin; export PATH; screen
# -dmS $process_name gdb $daemon_directory/$process_name
# $process_id & sleep 1

# INSTALL-TIME CONFIGURATION INFORMATION
#
# The following parameters are used when installing a new Postfix version.
#
# sendmail_path: The full pathname of the Postfix sendmail command.
# This is the Sendmail-compatible mail posting interface.
#
sendmail_path = /usr/sbin/sendmail

# newaliases_path: The full pathname of the Postfix newaliases command.
# This is the Sendmail-compatible command to build alias databases.
#
newaliases_path = /usr/bin/newaliases

# mailq_path: The full pathname of the Postfix mailq command. This
# is the Sendmail-compatible mail queue listing command.
#
mailq_path = /usr/bin/mailq

# setgid_group: The group for mail submission and queue management
# commands. This must be a group name with a numerical group ID that
# is not shared with other accounts, not even with the Postfix account.
#
setgid_group = postdrop

# html_directory: The location of the Postfix HTML documentation.
#
html_directory = /var/www/postfix_html

# manpage_directory: The location of the Postfix on-line manual pages.
#
manpage_directory = /usr/local/postfix/man

# sample_directory: The location of the Postfix sample configuration files.
# This parameter is obsolete as of Postfix 2.1.
#
sample_directory = /etc/postfix

# readme_directory: The location of the Postfix README files.
#
readme_directory = no
#========================CYRUS-SASL=============================
#broken_sasl_auth_clients = yes
#smtpd_recipient_restrictions=permit_mynetworks,permit_sasl_authenticated,reject_invalid_hostname,reject_non_fqdn_hostname,reject_unknown_sender_domain,reject_non_fqdn_sender,reject_non_fqdn_recipient,reject_unknown_recipient_domain,reject_unauth_pipelining,reject_unauth_destination
#smtpd_sasl_auth_enable = yes
#smtpd_sasl_local_domain = $myhostname
#smtpd_sasl_security_options = noanonymous
#smtpd_sasl_application_name = smtpd
#smtpd_banner = Welcome to our $myhostname ESMTP,Warning: Version not Available!

broken_sasl_auth_clients = yes
smtpd_recipient_restrictions = permit_mynetworks,permit_sasl_authenticated,reject_invalid_hostname,reject_non_fqdn_hostname,reject_unknown_sender_domain,reject_non_fqdn_sender,reject_non_fqdn_recipient,reject_unknown_recipient_domain,reject_unauth_pipelining,reject_unauth_destination,permit
smtpd_sasl_auth_enable = yes
smtpd_sasl_local_domain = $myhostname
smtpd_sasl_security_options = noanonymous
smtpd_sasl_application_name = smtpd
smtpd_banner = Welcome to our $myhostname ESMTP,Warning: Version not Available!

#========================Virtual Mailbox Settings=========================
virtual_mailbox_base = /var/mailbox
virtual_mailbox_maps = mysql:/etc/postfix/mysql_virtual_mailbox_maps.cf
virtual_mailbox_domains = mysql:/etc/postfix/mysql_virtual_domains_maps.cf
virtual_alias_domains =
virtual_alias_maps = mysql:/etc/postfix/mysql_virtual_alias_maps.cf
virtual_uid_maps = static:2525
virtual_gid_maps = static:2525
virtual_transport = maildrop
#virtual_transport = virtual
maildrop_destination_recipient_limit = 1
maildrop_destination_concurrency_limit = 1
#=====================QUOTA Settings===========================
message_size_limit = 14336000
virtual_mailbox_limit = 20971520
virtual_create_maildirsize = yes
virtual_mailbox_extended = yes
virtual_mailbox_limit_maps = mysql:/etc/postfix/mysql_virtual_mailbox_limit_maps.cf
virtual_mailbox_limit_override = yes
virtual_maildir_limit_message = Sorry, the user's maildir has overdrawn his diskspace quota,please Tidy your mailbox and try again lager.
virtual_overquota_bounce = yes

zdyldy 回复于:2007-10-18 13:12:39

十五、安装clamav-0.91.2

最新的clamav-0.91.2需要zlib-1.2.2以上的版本的支持,而RHEL4上的版本为zlib-1.2.1,因此您需要先升级zlib

1、安装zlib-1.2.3

#tar zvxf zlib-1.2.3.tar.gz
#cd zlib-1.2.3
#./configure --prefix=/usr --shared
#make
#make test

2、安装clamav-0.91.2

添加ClamAV运行所需的组和用户:
#groupadd clamav






marion 老大 请看一下 安装zlib-1.2.3


怎么没有
make install

难到这个不用安装么,还是忘写了呢。

yecheng_110 回复于:2007-10-18 16:24:28

LZ能贴一下支持虚拟域和虚拟用户所用到的SQL表吗?
extmail 这个table里面的表是如何建立的?

[ 本帖最后由 yecheng_110 于 2007-10-18 16:29 编辑 ]

zdyldy 回复于:2007-10-18 17:05:40

在另外一台机器上可以用IP地址访问我的extmail

为什么用域名不行呢。

在另外一台机器上,可以解析出我的域名啊,是哪里出了问题呢。


而在我的linux服务器上,用哪种方式都可以访问。

marion 回复于:2007-10-19 10:12:14

引用:marion 老大 请看一下 安装zlib-1.2.3


怎么没有
make install

难到这个不用安装么,还是忘写了呢。


要make install,是忘记写上了。:emn28:

marion 回复于:2007-10-19 10:14:47

引用:原帖由 zdyldy 于 2007-10-18 17:05 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=7480248&ptid=987344
在另外一台机器上可以用IP地址访问我的extmail

为什么用域名不行呢。

在另外一台机器上,可以解析出我的域名啊,是哪里出了问题呢。


而在我的linux服务器上,用哪种方式都可以访问。


如果能解析域名却无法用域名访问,应该是你的apache虚拟主机的问题。

marion 回复于:2007-10-19 10:16:21

引用:原帖由 yecheng_110 于 2007-10-18 16:24 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=7479911&ptid=987344
LZ能贴一下支持虚拟域和虚拟用户所用到的SQL表吗?
extmail 这个table里面的表是如何建立的?


……使用extman源码目录下docs目录中的extmail.sql和init.sql建立数据库:

# cd /var/www/extsuite/extman
# mysql -u root -p <extmail.sql
# mysql -u root -p <init.sql

…………

MYSQLER 回复于:2007-10-19 10:47:07

marion 兄请教一下
小弟只想做内网邮件,不做病毒防护,越简单越好,请指点

zdyldy 回复于:2007-10-19 15:56:51

这是我的http.conf 文件请帮忙看一下啊,就是不能用域名访问.


#
# This is the main Apache HTTP server configuration file. It contains the
# configuration directives that give the server its instructions.
# See <URL:http://httpd.apache.org/docs/2.2> for detailed information.
# In particular, see
# <URL:http://httpd.apache.org/docs/2.2/mod/directives.html>
# for a discussion of each configuration directive.
#
# Do NOT simply read the instructions in here without understanding
# what they do. They're here only as hints or reminders. If you are unsure
# consult the online docs. You have been warned.
#
# Configuration and logfile names: If the filenames you specify for many
# of the server's control files begin with "/" (or "drive:/" for Win32), the
# server will use that explicit path. If the filenames do *not* begin
# with "/", the value of ServerRoot is prepended -- so "logs/foo.log"
# with ServerRoot set to "/usr/local/apache" will be interpreted by the
# server as "/usr/local/apache/logs/foo.log".

#
# ServerRoot: The top of the directory tree under which the server's
# configuration, error, and log files are kept.
#
# Do not add a slash at the end of the directory path. If you point
# ServerRoot at a non-local disk, be sure to point the LockFile directive
# at a local disk. If you wish to share the same ServerRoot for multiple
# httpd daemons, you will need to change at least LockFile and PidFile.
#
ServerRoot "/usr/local/apache"

#
# Listen: Allows you to bind Apache to specific IP addresses and/or
# ports, instead of the default. See also the <VirtualHost>
# directive.
#
# Change this to Listen on specific IP addresses as shown below to
# prevent Apache from glomming onto all bound IP addresses.
#
#Listen 12.34.56.78:80
Listen 80

#
# Dynamic Shared Object (DSO) Support
#
# To be able to use the functionality of a module which was built as a DSO you
# have to place corresponding `LoadModule' lines at this location so the
# directives contained in it are actually available _before_ they are used.
# Statically compiled modules (those listed by `httpd -l') do not need
# to be loaded here.
#
# Example:
# LoadModule foo_module modules/mod_foo.so
#
LoadModule authn_file_module modules/mod_authn_file.so
LoadModule authn_dbm_module modules/mod_authn_dbm.so
LoadModule authn_anon_module modules/mod_authn_anon.so
LoadModule authn_dbd_module modules/mod_authn_dbd.so
LoadModule authn_default_module modules/mod_authn_default.so
LoadModule authz_host_module modules/mod_authz_host.so
LoadModule authz_groupfile_module modules/mod_authz_groupfile.so
LoadModule authz_user_module modules/mod_authz_user.so
LoadModule authz_dbm_module modules/mod_authz_dbm.so
LoadModule authz_owner_module modules/mod_authz_owner.so
LoadModule authz_default_module modules/mod_authz_default.so
LoadModule auth_basic_module modules/mod_auth_basic.so
LoadModule auth_digest_module modules/mod_auth_digest.so
LoadModule dbd_module modules/mod_dbd.so
LoadModule dumpio_module modules/mod_dumpio.so
LoadModule ext_filter_module modules/mod_ext_filter.so
LoadModule include_module modules/mod_include.so
LoadModule filter_module modules/mod_filter.so
LoadModule deflate_module modules/mod_deflate.so
LoadModule log_config_module modules/mod_log_config.so
LoadModule logio_module modules/mod_logio.so
LoadModule env_module modules/mod_env.so
LoadModule expires_module modules/mod_expires.so
LoadModule headers_module modules/mod_headers.so
LoadModule ident_module modules/mod_ident.so
LoadModule setenvif_module modules/mod_setenvif.so
LoadModule ssl_module modules/mod_ssl.so
LoadModule mime_module modules/mod_mime.so
LoadModule dav_module modules/mod_dav.so
LoadModule status_module modules/mod_status.so
LoadModule autoindex_module modules/mod_autoindex.so
LoadModule asis_module modules/mod_asis.so
LoadModule info_module modules/mod_info.so
LoadModule suexec_module modules/mod_suexec.so
LoadModule cgi_module modules/mod_cgi.so
LoadModule dav_fs_module modules/mod_dav_fs.so
LoadModule vhost_alias_module modules/mod_vhost_alias.so
LoadModule negotiation_module modules/mod_negotiation.so
LoadModule dir_module modules/mod_dir.so
LoadModule imagemap_module modules/mod_imagemap.so
LoadModule actions_module modules/mod_actions.so
LoadModule speling_module modules/mod_speling.so
LoadModule userdir_module modules/mod_userdir.so
LoadModule alias_module modules/mod_alias.so
LoadModule rewrite_module modules/mod_rewrite.so

<IfModule !mpm_netware_module>
#
# If you wish httpd to run as a different user or group, you must run
# httpd as root initially and it will switch.
#
# User/Group: The name (or #number) of the user/group to run httpd as.
# It is usually good practice to create a dedicated user and group for
# running httpd, as with most system services.
#
User vmail
Group vmail
</IfModule>

# 'Main' server configuration
#
# The directives in this section set up the values used by the 'main'
# server, which responds to any requests that aren't handled by a
# <VirtualHost> definition. These values also provide defaults for
# any <VirtualHost> containers you may define later in the file.
#
# All of these directives may appear inside <VirtualHost> containers,
# in which case these default settings will be overridden for the
# virtual host being defined.
#

#
# ServerAdmin: Your address, where problems with the server should be
# e-mailed. This address appears on some server-generated pages, such
# as error documents. e.g. admin@your-domain.com
#
#ServerAdmin you@example.com

#
# ServerName gives the name and port that the server uses to identify itself.
# This can often be determined automatically, but we recommend you specify
# it explicitly to prevent problems during startup.
#
# If your host doesn't have a registered DNS name, enter its IP address here.
#
#ServerName www.example.com:80

#
# DocumentRoot: The directory out of which you will serve your
# documents. By default, all requests are taken from this directory, but
# symbolic links and aliases may be used to point to other locations.
#
#DocumentRoot "/var/www"

#
# Each directory to which Apache has access can be configured with respect
# to which services and features are allowed and/or disabled in that
# directory (and its subdirectories).
#
# First, we configure the "default" to be a very restrictive set of
# features.
#
<Directory />
Options FollowSymLinks
AllowOverride None
Order deny,allow
Deny from all
</Directory>

#
# Note that from this point forward you must specifically allow
# particular features to be enabled - so if something's not working as
# you might expect, make sure that you have specifically enabled it
# below.
#

#
# This should be changed to whatever you set DocumentRoot to.
#
<Directory "/var/www">
#
# Possible values for the Options directive are "None", "All",
# or any combination of:
# Indexes Includes FollowSymLinks SymLinksifOwnerMatch ExecCGI MultiViews
#
# Note that "MultiViews" must be named *explicitly* --- "Options All"
# doesn't give it to you.
#
# The Options directive is both complicated and important. Please see
# http://httpd.apache.org/docs/2.2/mod/core.html#options
# for more information.
#
Options Indexes FollowSymLinks

#
# AllowOverride controls what directives may be placed in .htaccess files.
# It can be "All", "None", or any combination of the keywords:
# Options FileInfo AuthConfig Limit
#
AllowOverride None

#
# Controls who can get stuff from this server.
#
Order allow,deny
Allow from all

</Directory>

#
# DirectoryIndex: sets the file that Apache will serve if a directory
# is requested.
#
<IfModule dir_module>
DirectoryIndex index.php index.html
</IfModule>

#
# The following lines prevent .htaccess and .htpasswd files from being
# viewed by Web clients.
#
<FilesMatch "^\.ht">
Order allow,deny
Deny from all
Satisfy All
</FilesMatch>

#
# ErrorLog: The location of the error log file.
# If you do not specify an ErrorLog directive within a <VirtualHost>
# container, error messages relating to that virtual host will be
# logged here. If you *do* define an error logfile for a <VirtualHost>
# container, that host's errors will be logged there and not here.
#
ErrorLog logs/error_log

#
# LogLevel: Control the number of messages logged to the error_log.
# Possible values include: debug, info, notice, warn, error, crit,
# alert, emerg.
#
LogLevel warn

<IfModule log_config_module>
#
# The following directives define some format nicknames for use with
# a CustomLog directive (see below).
#
LogFormat "%h %l %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-Agent}i\"" combined
LogFormat "%h %l %u %t \"%r\" %>s %b" common

<IfModule logio_module>
# You need to enable mod_logio.c to use %I and %O
LogFormat "%h %l %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-Agent}i\" %I %O" combinedio
</IfModule>

#
# The location and format of the access logfile (Common Logfile Format).
# If you do not define any access logfiles within a <VirtualHost>
# container, they will be logged here. Contrariwise, if you *do*
# define per-<VirtualHost> access logfiles, transactions will be
# logged therein and *not* in this file.
#
CustomLog logs/access_log common

#
# If you prefer a logfile with access, agent, and referer information
# (Combined Logfile Format) you can use the following directive.
#
#CustomLog logs/access_log combined
</IfModule>

<IfModule alias_module>
#
# Redirect: Allows you to tell clients about documents that used to
# exist in your server's namespace, but do not anymore. The client
# will make a new request for the document at its new location.
# Example:
# Redirect permanent /foo http://www.example.com/bar

#
# Alias: Maps web paths into filesystem paths and is used to
# access content that does not live under the DocumentRoot.
# Example:
# Alias /webpath /full/filesystem/path
#
# If you include a trailing / on /webpath then the server will
# require it to be present in the URL. You will also likely
# need to provide a <Directory> section to allow access to
# the filesystem path.

#
# ScriptAlias: This controls which directories contain server scripts.
# ScriptAliases are essentially the same as Aliases, except that
# documents in the target directory are treated as applications and
# run by the server when requested rather than as documents sent to the
# client. The same rules about trailing "/" apply to ScriptAlias
# directives as to Alias.
#
ScriptAlias /cgi-bin/ "/usr/local/apache/cgi-bin/"

</IfModule>

<IfModule cgid_module>
#
# ScriptSock: On threaded servers, designate the path to the UNIX
# socket used to communicate with the CGI daemon of mod_cgid.
#
#Scriptsock logs/cgisock
</IfModule>

#
# "/usr/local/apache/cgi-bin" should be changed to whatever your ScriptAliased
# CGI directory exists, if you have that configured.
#
<Directory "/usr/local/apache/cgi-bin">
AllowOverride None
Options None
Order allow,deny
Allow from all
</Directory>

#
# DefaultType: the default MIME type the server will use for a document
# if it cannot otherwise determine one, such as from filename extensions.
# If your server contains mostly text or HTML documents, "text/plain" is
# a good value. If most of your content is binary, such as applications
# or images, you may want to use "application/octet-stream" instead to
# keep browsers from trying to display binary files as though they are
# text.
#
DefaultType text/plain

<IfModule mime_module>
#
# TypesConfig points to the file containing the list of mappings from
# filename extension to MIME-type.
#
TypesConfig /etc/httpd/mime.types

#
# AddType allows you to add to or override the MIME configuration
# file specified in TypesConfig for specific file types.
#
#AddType application/x-gzip .tgz
#
# AddEncoding allows you to have certain browsers uncompress
# information on the fly. Note: Not all browsers support this.
#
#AddEncoding x-compress .Z
#AddEncoding x-gzip .gz .tgz
#
# If the AddEncoding directives above are commented-out, then you
# probably should define those extensions to indicate media types:
#
AddType application/x-compress .Z
AddType application/x-gzip .gz .tgz

#
# AddHandler allows you to map certain file extensions to "handlers":
# actions unrelated to filetype. These can be either built into the server
# or added with the Action directive (see below)
#
# To use CGI scripts outside of ScriptAliased directories:
# (You will also need to add "ExecCGI" to the "Options" directive.)
#
#AddHandler cgi-script .cgi

# For type maps (negotiated resources):
#AddHandler type-map var

#
# Filters allow you to process content before it is sent to the client.
#
# To parse .shtml files for server-side includes (SSI):
# (You will also need to add "Includes" to the "Options" directive.)
#
#AddType text/html .shtml
#AddOutputFilter INCLUDES .shtml
</IfModule>

#
# The mod_mime_magic module allows the server to use various hints from the
# contents of the file itself to determine its type. The MIMEMagicFile
# directive tells the module where the hint definitions are located.
#
#MIMEMagicFile /etc/httpd/magic

#
# Customizable error responses come in three flavors:
# 1) plain text 2) local redirects 3) external redirects
#
# Some examples:
#ErrorDocument 500 "The server made a boo boo."
#ErrorDocument 404 /missing.html
#ErrorDocument 404 "/cgi-bin/missing_handler.pl"
#ErrorDocument 402 http://www.example.com/subscription_info.html
#

#
# EnableMMAP and EnableSendfile: On systems that support it,
# memory-mapping or the sendfile syscall is used to deliver
# files. This usually improves server performance, but must
# be turned off when serving from networked-mounted
# filesystems or if support for these functions is otherwise
# broken on your system.
#
#EnableMMAP off
#EnableSendfile off

# Supplemental configuration
#
# The configuration files in the /etc/httpd/extra/ directory can be
# included to add extra features or to modify the default configuration of
# the server, or you may simply copy their contents here and change as
# necessary.

# Server-pool management (MPM specific)
#Include /etc/httpd/extra/httpd-mpm.conf

# Multi-language error messages
#Include /etc/httpd/extra/httpd-multilang-errordoc.conf

# Fancy directory listings
#Include /etc/httpd/extra/httpd-autoindex.conf

# Language settings
#Include /etc/httpd/extra/httpd-languages.conf

# User home directories
#Include /etc/httpd/extra/httpd-userdir.conf

# Real-time info on requests and configuration
#Include /etc/httpd/extra/httpd-info.conf

# Virtual hosts
#Include /etc/httpd/extra/httpd-vhosts.conf

# Local access to the Apache HTTP Server Manual
#Include /etc/httpd/extra/httpd-manual.conf

# Distributed authoring and versioning (WebDAV)
#Include /etc/httpd/extra/httpd-dav.conf

# Various default settings
#Include /etc/httpd/extra/httpd-default.conf

# Secure (SSL/TLS) connections
#Include /etc/httpd/extra/httpd-ssl.conf
#
# Note: The following must must be present to support
# starting without SSL on platforms with no /dev/random equivalent
# but a statically compiled-in mod_ssl.
#
<IfModule ssl_module>
SSLRandomSeed startup builtin
SSLRandomSeed connect builtin
</IfModule>
AddType application/x-httpd-php .php
AddType application/x-httpd-php-source .phps
<VirtualHost mail.oli.cn:80>
ServerName mail.oli.cn:80
DocumentRoot /var/www/extsuite/extmail/html/

ScriptAlias /extmail/cgi /var/www/extsuite/extmail/cgi
Alias /extmail /var/www/extsuite/extmail/html
ScriptAlias /extman/cgi /var/www/extsuite/extman/cgi
Alias /extman /var/www/extsuite/extman/html
</VirtualHost>

victorchang 回复于:2007-10-19 16:54:09

我按着文档做的,在开始的时候TELNET 127.0.0.1 25 进行测试都正常呀,
到最后全部调试完,只能WEB方式发邮件,收不到邮件,用FOXMAIL方式不能发和收呀...
我把配置写在这里,看哪位老大帮忙看一下呀...
需要说明的是:我在开始测试WEB发邮件时,总是会提示/var/mailbox/one234.....目录为存的提示,我将one234目录权限设置了一下,就可以发了,,可能是没有权限建立邮件目录的文件吧...

还请MARION多多帮助,弄了一天了,,都快疯了!!!

1./etc/postfix/main.cf
-------------------------------------------------
myhostname = one234.net
myorigin = one234.net
mydomain = one234.net
mydestination = $myhostname, localhost.$mydomain, localhost, $mydomain
mynetworks = 59.108.37.0/24, 127.0.0.0/8
virtual_mailbox_base = /var/mailbox
virtual_mailbox_maps = mysql:/etc/postfix/mysql_virtual_mailbox_maps.cf
virtual_mailbox_domains = mysql:/etc/postfix/mysql_virtual_domains_maps.cf
virtual_alias_domains =
virtual_alias_maps = mysql:/etc/postfix/mysql_virtual_alias_maps.cf
virtual_uid_maps = static:2525
virtual_gid_maps = static:2525
virtual_transport = virtual
maildrop_destination_recipient_limit = 1
maildrop_destination_concurrency_limit = 1
##########################QUOTA Settings########################
message_size_limit = 14336000
virtual_mailbox_limit = 20971520
virtual_create_maildirsize = yes
virtual_mailbox_extended = yes
virtual_mailbox_limit_maps = mysql:/etc/postfix/mysql_virtual_mailbox_limit_maps.cf
virtual_mailbox_limit_override = yes

virtual_maildir_limit_message = Sorry, the user's maildir has overdrawn his diskspace quota, please Tidy your mailbox and try again later.
virtual_overquota_bounce = yes
-------------------------------------------------------------------------------------

2.我把/etc/log/maillog删除了,不知道能不能自动再创建一个...

3.
[root@one234 postfix]# telnet 127.0.0.1 25
Trying 127.0.0.1...
Connected to localhost.localdomain (127.0.0.1).
Escape character is '^]'.
停在这里了,没有任何反应.

4./usr/lib/sasl2/smtpd.conf
--------------------------------------------------------------------------------------
pwcheck_method: authdaemond
log_level:3
mech_list: PLAIN LOGIN
authdaemond_path:/usr/local/courier-authlib/var/spool/authdaemon/socket

5.修改/etc/authdaemonrc 文件
authmodulelist="authmysql"
authmodulelistorig="authmysql"
daemons=10

编辑/etc/authmysqlrc 为以下内容
MYSQL_SERVER localhost
MYSQL_PORT 3306 (指定你的mysql监听的端口,这里使用默认的3306)
MYSQL_USERNAME user (我的MYSQL 管理员帐户)
MYSQL_PASSWORD passwordl (我的MYSQL密码)
MYSQL_SOCKET /tmp/mysql.sock
MYSQL_DATABASE extmail
MYSQL_USER_TABLE mailbox
MYSQL_CRYPT_PWFIELD password
MYSQL_UID_FIELD '2525'
MYSQL_GID_FIELD '2525'
MYSQL_LOGIN_FIELD username
MYSQL_HOME_FIELD concat('/var/mailbox/',maildir)
MYSQL_NAME_FIELD name
MYSQL_MAILDIR_FIELD concat('/var/mailbox/',maildir)

[ 本帖最后由 victorchang 于 2007-10-19 17:14 编辑 ]

victorchang 回复于:2007-10-19 16:56:24

<VirtualHost mail.oli.cn:80>
ServerName mail.oli.cn:80
DocumentRoot /var/www/extsuite/extmail/html/

ScriptAlias /extmail/cgi /var/www/extsuite/extmail/cgi
Alias /extmail /var/www/extsuite/extmail/html
ScriptAlias /extman/cgi /var/www/extsuite/extman/cgi
Alias /extman /var/www/extsuite/extman/html
</VirtualHost>

这段你加错地方了...
应该加在httpd.conf所在目录的extra目录的httpd-vhost文件中..

[ 本帖最后由 victorchang 于 2007-10-19 17:15 编辑 ]

marion 回复于:2007-10-19 17:11:48

引用:<VirtualHost mail.oli.cn:80>
ServerName mail.oli.cn:80
DocumentRoot /var/www/extsuite/extmail/html/

ScriptAlias /extmail/cgi /var/www/extsuite/extmail/cgi
Alias /extmail /var/www/extsuite/extmail/html
ScriptAlias /extman/cgi /var/www/extsuite/extman/cgi
Alias /extman /var/www/extsuite/extman/html
</VirtualHost>


将如上改为

NameVirtualHost *:80
<VirtualHost *:80>
ServerName mail.oli.cn:80
DocumentRoot /var/www/extsuite/extmail/html/

ScriptAlias /extmail/cgi /var/www/extsuite/extmail/cgi
Alias /extmail /var/www/extsuite/extmail/html
ScriptAlias /extman/cgi /var/www/extsuite/extman/cgi
Alias /extman /var/www/extsuite/extman/html
</VirtualHost>

victorchang 回复于:2007-10-20 02:05:37

########################Virtual Mailbox Settings########################
virtual_mailbox_base = /var/mailbox
virtual_mailbox_maps = mysql:/etc/postfix/mysql_virtual_mailbox_maps.cf
virtual_mailbox_domains = mysql:/etc/postfix/mysql_virtual_domains_maps.cf
virtual_alias_domains =
virtual_alias_maps = mysql:/etc/postfix/mysql_virtual_alias_maps.cf
virtual_uid_maps = static:2525
virtual_gid_maps = static:2525
virtual_transport = virtual
maildrop_destination_recipient_limit = 1
maildrop_destination_concurrency_limit = 1
##########################QUOTA Settings########################
message_size_limit = 14336000
virtual_mailbox_limit = 20971520
virtual_create_maildirsize = yes
virtual_mailbox_extended = yes
virtual_mailbox_limit_maps = mysql:/etc/postfix/mysql_virtual_mailbox_limit_maps.cf
virtual_mailbox_limit_override = yes
virtual_maildir_limit_message = Sorry, the user's maildir has overdrawn his diskspace quota, please Tidy your mailbox and try again later.
virtual_overquota_bounce = yes

没人回复,我就重新做了一遍,做完就一遍就测试一下TELNET 25的操作,结果发现在加完以上的内容后,进行TELNET 127.0.0.1 25 没有反应的原因之处.
有请marion帮助!

抽象派 回复于:2007-10-20 02:57:35

修改相应的头文件指向
# mv /usr/inculde/db4 /usr/inculde/db4.OFF
# rm /usr/inculde/db_cxx.h
# rm /usr/inculde/db.h
# rm /usr/inculde/db_185.h
# ln -sv /usr/local/BerkeleyDB/include /usr/include/db4
# ln -sv /usr/local/BerkeleyDB/include/db.h /usr/include/db.h
# ln -sv /usr/local/BerkeleyDB/include/db_cxx.h /usr/include/db_cxx.h


楼主这段写错了include写成inculde
只是笔误.不影响操作.大家注意一下就好.

victorchang 回复于:2007-10-20 03:47:57

我现在可以发邮件,通过FOXMAIL也可以了,
但在WEBMAIL和FOXMAIL方式都不能收邮件,不知道问题出在哪,
请帮助!!

marion 回复于:2007-10-20 09:04:06

引用:原帖由 抽象派 于 2007-10-20 02:57 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=7486963&ptid=987344
修改相应的头文件指向
# mv /usr/inculde/db4 /usr/inculde/db4.OFF
# rm /usr/inculde/db_cxx.h
# rm /usr/inculde/db.h
# rm /usr/inculde/db_185.h
# ln -sv /usr/local/BerkeleyDB/include /u ...



谢朋友指正,我去修改过来。

marion 回复于:2007-10-20 09:09:16

引用:原帖由 victorchang 于 2007-10-20 03:47 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=7486971&ptid=987344
我现在可以发邮件,通过FOXMAIL也可以了,
但在WEBMAIL和FOXMAIL方式都不能收邮件,不知道问题出在哪,
请帮助!!


看来是多试一次总会有结果的的:)

要想解决问题,你要贴上来的应该是相关的日志!比如对于不能收邮件,你就应该telnet一下本机的110端口(使用客户端登录收邮件也可以)登录邮箱进行邮件收取测试;如果因错误无法进行,日志就是帮助排错的重要信息了。

zdyldy 回复于:2007-10-20 10:08:41

回复 #178 zdyldy 的帖子



QUOTE:
<VirtualHost mail.oli.cn:80>
ServerName mail.oli.cn:80
DocumentRoot /var/www/extsuite/extmail/html/

ScriptAlias /extmail/cgi /var/www/extsuite/extmail/cgi
Alias /extmail /var/www/extsuite/extmail/html
ScriptAlias /extman/cgi /var/www/extsuite/extman/cgi
Alias /extman /var/www/extsuite/extman/html
</VirtualHost>

将如上改为

NameVirtualHost *:80
<VirtualHost *:80>
ServerName mail.oli.cn:80
DocumentRoot /var/www/extsuite/extmail/html/

ScriptAlias /extmail/cgi /var/www/extsuite/extmail/cgi
Alias /extmail /var/www/extsuite/extmail/html
ScriptAlias /extman/cgi /var/www/extsuite/extman/cgi
Alias /extman /var/www/extsuite/extman/html
</VirtualHost>




改过了啊,还是不行啊,用域名还是无法显示。 用IP地址可以访问。

[ 本帖最后由 zdyldy 于 2007-10-20 10:23 编辑 ]

zdyldy 回复于:2007-10-20 10:11:38

我还有一个问题啊,怎么实现群发呢。

我在alias域里设置了一下。可是不好使呢,就不知道在叫哪里设置了。

marion 回复于:2007-10-20 13:28:41

重启httpd服务了没?

这个恐怕你得补充apache设置的有关知识了。

marion 回复于:2007-10-20 13:30:35

引用:原帖由 zdyldy 于 2007-10-20 10:11 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=7487201&ptid=987344
我还有一个问题啊,怎么实现群发呢。

我在alias域里设置了一下。可是不好使呢,就不知道在叫哪里设置了。


有个非常简单的方法,你可以去extman的后台进行群发。

zdyldy 回复于:2007-10-20 13:59:06

回复 #187 zdyldy 的帖子


重启httpd服务了没?

这个恐怕你得补充apache设置的有关知识了。


重启了,可是不好使,按你发的帖子不就能用么。怎么到我这里出了问题呢。唉。

marion 回复于:2007-10-20 14:36:39

引用:原帖由 zdyldy 于 2007-10-20 13:59 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=7487780&ptid=987344
回复 #187 zdyldy 的帖子


重启了,可是不好使,按你发的帖子不就能用么。怎么到我这里出了问题呢。唉。


这个只是你的apache本身的问题,跟邮件服务器没有关系,因为你使用IP可以访问。我给出的仅仅是关于extmail和extman的相关部分的设置。恐怕其他人的都是可以的……

建议去认真检查虚拟主机的设置。

victorchang 回复于:2007-10-20 15:00:24

引用:原帖由 marion 于 2007-10-20 09:09 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=7487042&ptid=987344


看来是多试一次总会有结果的的:)

要想解决问题,你要贴上来的应该是相关的日志!比如对于不能收邮件,你就应该telnet一下本机的110端口(使用客户端登录收邮件也可以)登录邮箱进行邮件收取测试;如果因 ...

首先试试MIRON的回复.
我进行了TELNET 110 测试,在客户端和服务器端.
都提示:+OK hello there ..
至于日志,我昨天将MAILLOG文件给删除了,再就没有生成过日志,我手动建立了一个/VAR/LOG/MAILLOG后,也没有生成任何信息.
在/var/log/message 只有这些日志,不知道有没有用.

Oct 20 19:55:49 one234 sshd(pam_unix)[19372]: authentication failure; logname= uid=0 euid=0 tty=ssh ruser= rhost=59.40.182.181 user=nfsnobody
Oct 20 19:55:52 one234 sshd(pam_unix)[19374]: authentication failure; logname= uid=0 euid=0 tty=ssh ruser= rhost=59.40.182.181 user=rpcuser
Oct 20 19:55:55 one234 sshd(pam_unix)[19376]: authentication failure; logname= uid=0 euid=0 tty=ssh ruser= rhost=59.40.182.181 user=rpc
Oct 20 19:55:58 one234 sshd(pam_unix)[19378]: authentication failure; logname= uid=0 euid=0 tty=ssh ruser= rhost=59.40.182.181 user=gopher
Oct 20 20:01:01 one234 crond(pam_unix)[19380]: session opened for user root by (uid=0)
Oct 20 20:01:01 one234 crond(pam_unix)[19380]: session closed for user root
Oct 20 20:03:03 one234 sshd(pam_unix)[19384]: session opened for user root by root(uid=0)
Oct 20 20:58:23 one234 sshd(pam_unix)[19457]: session opened for user root by root(uid=0)
Oct 20 21:01:01 one234 crond(pam_unix)[19493]: session opened for user root by (uid=0)
Oct 20 21:01:01 one234 crond(pam_unix)[19493]: session closed for user root
[root@one234 ~]#

marion 回复于:2007-10-20 18:51:45

必须要maillog日志。

你怎么会删除它!!

建议把maillog的属主和属组改为postfix试一下。

yinglikx2006 回复于:2007-10-20 22:08:19

我在安装完EXTMAIL后,访问我的email.thinkce.net后,页面是空白,这是什么原因那, 请各位帮忙,

victorchang 回复于:2007-10-21 00:06:18

引用:原帖由 marion 于 2007-10-20 18:51 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=7488360&ptid=987344
必须要maillog日志。

你怎么会删除它!!

建议把maillog的属主和属组改为postfix试一下。

maillog已经生成日志,按你说的,改成了postfix属组..
我进行了telnet 127.0.0.1 110
user xxx
pass xxx
测试后,生成的日志为:
pop3d:-ERR chdir Maildir failed

zyhui 回复于:2007-10-21 12:34:44

在我安装好clamav、amavisd和SpamAssassin以后,发现图形日志分析不能用了,图片显示不出来,之前还是能用的,这是怎么回事儿?

MYSQLER 回复于:2007-10-21 13:32:54

marion

我按照你的一步步来做.一切都正常,安装完了extmail,还没有安装extman,按照你的提示说可以用web访问了,可是当我访问时出现500 Internal Server Error
查看日志

cat suexec_log



[2007-10-21 03:46:34]: user mismatch (nobody instead of www)

[2007-10-21 03:46:39]: user mismatch (nobody instead of www)

[2007-10-21 03:46:44]: user mismatch (nobody instead of www)

[2007-10-21 03:46:45]: user mismatch (nobody instead of www)

[2007-10-21 03:47:06]: user mismatch (nobody instead of www)

[2007-10-21 03:47:09]: user mismatch (nobody instead of www)

[2007-10-21 03:47:09]: user mismatch (nobody instead of www)

[2007-10-21 03:47:10]: user mismatch (nobody instead of www)

[2007-10-21 03:47:11]: user mismatch (nobody instead of www)

[2007-10-21 03:47:11]: user mismatch (nobody instead of www)

[2007-10-21 03:50:10]: user mismatch (nobody instead of www)

[2007-10-21 03:57:59]: user mismatch (nobody instead of www)

[2007-10-21 03:58:02]: user mismatch (nobody instead of www)

[2007-10-21 03:58:03]: user mismatch (nobody instead of www)

[2007-10-21 03:58:03]: user mismatch (nobody instead of www)

[2007-10-21 03:58:04]: user mismatch (nobody instead of www)

[2007-10-21 03:58:05]: user mismatch (nobody instead of www)

[2007-10-21 03:58:05]: user mismatch (nobody instead of www)

[2007-10-21 03:58:06]: user mismatch (nobody instead of www)

[2007-10-21 03:58:07]: user mismatch (nobody instead of www)

[2007-10-21 03:58:07]: user mismatch (nobody instead of www)

[2007-10-21 03:58:08]: user mismatch (nobody instead of www)

[2007-10-21 03:58:09]: user mismatch (nobody instead of www)

[2007-10-21 03:58:09]: user mismatch (nobody instead of www)

[2007-10-21 03:58:10]: user mismatch (nobody instead of www)

[2007-10-21 04:03:05]: user mismatch (nobody instead of www)

[2007-10-21 04:04:25]: user mismatch (nobody instead of www)

[2007-10-21 04:04:26]: user mismatch (nobody instead of www)

[2007-10-21 04:11:51]: user mismatch (nobody instead of www)

[2007-10-21 04:11:52]: user mismatch (nobody instead of www)

[2007-10-21 04:24:20]: user mismatch (nobody instead of www)

[2007-10-21 04:24:21]: user mismatch (nobody instead of www)

[2007-10-21 04:24:22]: user mismatch (nobody instead of www)

[2007-10-21 13:20:28]: user mismatch (nobody instead of www)


错误日志

[Sun Oct 21 03:58:07 2007] [error] [client 192.168.1.7] File does not exist: /var/www/extsuite/extmail/html/favicon.ico

[Sun Oct 21 03:58:07 2007] [error] [client 192.168.1.7] Premature end of script headers: index.cgi

[Sun Oct 21 03:58:08 2007] [error] [client 192.168.1.7] File does not exist: /var/www/extsuite/extmail/html/favicon.ico

[Sun Oct 21 03:58:08 2007] [error] [client 192.168.1.7] Premature end of script headers: index.cgi

[Sun Oct 21 03:58:08 2007] [error] [client 192.168.1.7] File does not exist: /var/www/extsuite/extmail/html/favicon.ico

[Sun Oct 21 03:58:09 2007] [error] [client 192.168.1.7] Premature end of script headers: index.cgi

[Sun Oct 21 03:58:09 2007] [error] [client 192.168.1.7] File does not exist: /var/www/extsuite/extmail/html/favicon.ico

[Sun Oct 21 03:58:09 2007] [error] [client 192.168.1.7] Premature end of script headers: index.cgi

[Sun Oct 21 03:58:09 2007] [error] [client 192.168.1.7] File does not exist: /var/www/extsuite/extmail/html/favicon.ico

[Sun Oct 21 03:58:10 2007] [error] [client 192.168.1.7] Premature end of script headers: index.cgi

[Sun Oct 21 03:58:10 2007] [error] [client 192.168.1.7] File does not exist: /var/www/extsuite/extmail/html/favicon.ico

[Sun Oct 21 04:03:05 2007] [error] [client 192.168.1.7] File does not exist: /var/www/extsuite/extmail/html/favicon.ico

[Sun Oct 21 04:03:05 2007] [error] [client 192.168.1.7] Premature end of script headers: index.cgi

[Sun Oct 21 04:03:05 2007] [error] [client 192.168.1.7] File does not exist: /var/www/extsuite/extmail/html/favicon.ico

[Sun Oct 21 04:04:25 2007] [error] [client 192.168.1.7] Premature end of script headers: index.cgi

[Sun Oct 21 04:04:25 2007] [error] [client 192.168.1.7] File does not exist: /var/www/extsuite/extmail/html/favicon.ico

[Sun Oct 21 04:04:26 2007] [error] [client 192.168.1.7] Premature end of script headers: index.cgi

[Sun Oct 21 04:04:26 2007] [error] [client 192.168.1.7] File does not exist: /var/www/extsuite/extmail/html/favicon.ico

[Sun Oct 21 04:11:51 2007] [error] [client 192.168.1.7] Premature end of script headers: index.cgi

[Sun Oct 21 04:11:51 2007] [error] [client 192.168.1.7] File does not exist: /var/www/extsuite/extmail/html/favicon.ico

[Sun Oct 21 04:11:52 2007] [error] [client 192.168.1.7] Premature end of script headers: index.cgi

[Sun Oct 21 04:11:52 2007] [error] [client 192.168.1.7] File does not exist: /var/www/extsuite/extmail/html/favicon.ico



marion 回复于:2007-10-21 20:09:31

装完extman后再进行访问!

marion 回复于:2007-10-21 20:11:06

这样的信息太过简单;

参照前面的帖子,打开authdaemon的日志功能,而后再登录一次,根据相关的日志分析问题症结所在。

marion 回复于:2007-10-21 20:13:01

这个没有遇见过,还真没有办法给你确定的答案。你可以尝试着定位下问题所在。如果有了结果,希望把结果发上来,以供其他人参照。

marion 回复于:2007-10-21 20:13:52

安装完extman后再来访问……

zyhui 回复于:2007-10-21 21:52:09

引用:原帖由 marion 于 2007-10-21 20:13 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=7490448&ptid=987344
这个没有遇见过,还真没有办法给你确定的答案。你可以尝试着定位下问题所在。如果有了结果,希望把结果发上来,以供其他人参照。

查了半天也没查出问题,图片都成红叉了。
在测试的时候还发现个问题,过滤器不能用,查了其他帖子发现标题类型的过滤器有bug,但是别的类型的过滤器可以用,可我的什么类型的过滤器都不能用。
日志:
Oct 21 21:50:55 mail postfix/smtpd[5020]: warning: dict_nis_init: NIS domain name not set - NIS lookups disabled
Oct 21 21:50:56 mail postfix/smtpd[5020]: connect from fk-out-0910.google.com[209.85.128.187]
Oct 21 21:50:58 mail postfix/smtpd[5020]: 27EAC708E6: client=fk-out-0910.google.com[209.85.128.187]
Oct 21 21:50:59 mail postfix/cleanup[5027]: 27EAC708E6: message-id=<ed7994e80710210650u6610175ah1e8e739dd45ef8a@mail.gmail.com>
Oct 21 21:50:59 mail postfix/qmgr[4461]: 27EAC708E6: from=<email.zyh@gmail.com>, size=2230, nrcpt=1 (queue active)
Oct 21 21:51:06 mail postfix/smtpd[5032]: warning: dict_nis_init: NIS domain name not set - NIS lookups disabled
Oct 21 21:51:06 mail postfix/smtpd[5032]: connect from localhost.localdomain[127.0.0.1]
Oct 21 21:51:06 mail postfix/smtpd[5032]: CA37F7099C: client=localhost.localdomain[127.0.0.1]
Oct 21 21:51:06 mail postfix/cleanup[5027]: CA37F7099C: message-id=<ed7994e80710210650u6610175ah1e8e739dd45ef8a@mail.gmail.com>
Oct 21 21:51:06 mail postfix/smtpd[5032]: disconnect from localhost.localdomain[127.0.0.1]
Oct 21 21:51:06 mail postfix/qmgr[4461]: CA37F7099C: from=<email.zyh@gmail.com>, size=2676, nrcpt=1 (queue active)
Oct 21 21:51:06 mail amavis[3822]: (03822-14) Passed CLEAN, [209.85.128.187] [209.85.128.187] <email.zyh@gmail.com> -> <hehe@onecheng.com>, Message-ID: <ed7994e80710210650u6610175ah1e8e739dd45ef8a@mail.gmail.com>, mail_id: Ewdj4WtIwct3, Hits: 0, size: 2228, queued_as: CA37F7099C, 7452 ms
Oct 21 21:51:06 mail postfix/smtp[5029]: 27EAC708E6: to=<hehe@onecheng.com>, relay=127.0.0.1[127.0.0.1]:10024, delay=9.5, delays=2/0.02/0.01/7.5, dsn=2.0.0, status=sent (250 2.0.0 Ok: queued as CA37F7099C)
Oct 21 21:51:06 mail postfix/qmgr[4461]: 27EAC708E6: removed
Oct 21 21:51:07 mail postfix/pipe[5033]: CA37F7099C: to=<hehe@onecheng.com>, relay=maildrop, delay=0.29, delays=0.12/0.06/0/0.11, dsn=2.0.0, status=sent (delivered via maildrop service)
Oct 21 21:51:07 mail postfix/qmgr[4461]: CA37F7099C: removed

zdyldy 回复于:2007-10-22 09:45:40

我公司有两个域名,分别为oyun.cn和oyun08.com

我在mailbox里建立了两个用户名:zdyldy@oyun.cnzdyldy@oyun08.com


现在要实现的是给这两个邮件地址中的任意一个发邮件,这两个地址都可以收到邮件.


我该怎么做呢.

zdyldy 回复于:2007-10-22 10:36:58

请问


root@extmail.org的密码怎么修改啊.

marion 回复于:2007-10-22 17:07:38

进入mysql,直接使用SQL命令修改即可。

安全起见,建议新建管理员帐号。

marion 回复于:2007-10-22 17:12:47

具体实现方法很繁琐,建议使用本版提供的“postfix中文权威指南”来了解相关的实现方法。

junger 回复于:2007-10-22 18:08:04

让postfix重新加载配置文件
# /usr/local/postfix/sbin/postfix reload
postfix/postfix-script: fatal: the Postfix mail system is not running


# telnet localhost 25
Trying 127.0.0.1...
Connected to localhost.localdomain (127.0.0.1).
Escape character is '^]'.
220 localhost.localdomain ESMTP Sendmail 8.13.1/8.13.1; Thu, 18 Oct 2007 18:47:04 -0400
ehlo mail.zhang.org
250-localhost.localdomain Hello zone [127.0.0.1], pleased to meet you
250-ENHANCEDSTATUSCODES
250-PIPELINING
250-8BITMIME
250-SIZE
250-DSN
250-ETRN
250-AUTH GSSAPI DIGEST-MD5 CRAM-MD5
250-DELIVERBY
250 HELP
没有这两行250-AUTH PLAIN LOGIN
250-AUTH=PLAIN LOGIN


vi /etc/postfix/main.cf
# Global Postfix configuration file. This file lists only a subset
# of all parameters. For the syntax, and for a complete parameter
# list, see the postconf(5) manual page (command: "man 5 postconf").
#
# For common configuration examples, see BASIC_CONFIGURATION_README
# and STANDARD_CONFIGURATION_README. To find these documents, use
# the command "postconf html_directory readme_directory", or go to
# http://www.postfix.org/.
#
# For best results, change no more than 2-3 parameters at a time,
# and test if Postfix still works after every change.

# SOFT BOUNCE
#
# The soft_bounce parameter provides a limited safety net for
# testing. When soft_bounce is enabled, mail will remain queued that
# would otherwise bounce. This parameter disables locally-generated
# bounces, and prevents the SMTP server from rejecting mail permanently
# (by changing 5xx replies into 4xx replies). However, soft_bounce
# is no cure for address rewriting mistakes or mail routing mistakes.
#
#soft_bounce = no

# LOCAL PATHNAME INFORMATION
#
# The queue_directory specifies the location of the Postfix queue.
# This is also the root directory of Postfix daemons that run chrooted.
# See the files in examples/chroot-setup for setting up Postfix chroot
# environments on different UNIX systems.
#
queue_directory = /var/spool/postfix

# The command_directory parameter specifies the location of all
# postXXX commands.
#
command_directory = /usr/local/postfix/sbin

# The daemon_directory parameter specifies the location of all Postfix
# daemon programs (i.e. programs listed in the master.cf file). This
# directory must be owned by root.
#
daemon_directory = /usr/local/postfix/libexec

# QUEUE AND PROCESS OWNERSHIP
#
# The mail_owner parameter specifies the owner of the Postfix queue
# and of most Postfix daemon processes. Specify the name of a user
# account THAT DOES NOT SHARE ITS USER OR GROUP ID WITH OTHER ACCOUNTS
# AND THAT OWNS NO OTHER FILES OR PROCESSES ON THE SYSTEM. In
# particular, don't specify nobody or daemon. PLEASE USE A DEDICATED
# USER.
#
mail_owner = postfix

# The default_privs parameter specifies the default rights used by
# the local delivery agent for delivery to external file or command.
# These rights are used in the absence of a recipient user context.
# DO NOT SPECIFY A PRIVILEGED USER OR THE POSTFIX OWNER.
#
#default_privs = nobody

# INTERNET HOST AND DOMAIN NAMES
#
# The myhostname parameter specifies the internet hostname of this
# mail system. The default is to use the fully-qualified domain name
# from gethostname(). $myhostname is used as a default value for many
# other configuration parameters.
#
myhostname = mail.zhang.org
#myhostname = virtual.domain.tld

# The mydomain parameter specifies the local internet domain name.
# The default is to use $myhostname minus the first component.
# $mydomain is used as a default value for many other configuration
# parameters.
#
mydomain = zhang.org

# SENDING MAIL
#
# The myorigin parameter specifies the domain that locally-posted
# mail appears to come from. The default is to append $myhostname,
# which is fine for small sites. If you run a domain with multiple
# machines, you should (1) change this to $mydomain and (2) set up
# a domain-wide alias database that aliases each user to
# user@that.users.mailhost.
#
# For the sake of consistency between sender and recipient addresses,
# myorigin also specifies the default domain name that is appended
# to recipient addresses that have no @domain part.
#
myorigin = zhang.org
#myorigin = $mydomain
# RECEIVING MAIL

# The inet_interfaces parameter specifies the network interface
# addresses that this mail system receives mail on. By default,
# the software claims all active interfaces on the machine. The
# parameter also controls delivery of mail to user@[ip.address].
#
# See also the proxy_interfaces parameter, for network addresses that
# are forwarded to us via a proxy or network address translator.
#
# Note: you need to stop/start Postfix when this parameter changes.
#
#inet_interfaces = all
#inet_interfaces = $myhostname

junger 回复于:2007-10-22 18:10:14

#inet_interfaces = $myhostname
#inet_interfaces = $myhostname, localhost

# The proxy_interfaces parameter specifies the network interface
# addresses that this mail system receives mail on by way of a
# proxy or network address translation unit. This setting extends
# the address list specified with the inet_interfaces parameter.
#
# You must specify your proxy/NAT addresses when your system is a
# backup MX host for other domains, otherwise mail delivery loops
# will happen when the primary MX host is down.
#
#proxy_interfaces =
#proxy_interfaces = 1.2.3.4

# The mydestination parameter specifies the list of domains that this
# machine considers itself the final destination for.
#
# These domains are routed to the delivery agent specified with the
# local_transport parameter setting. By default, that is the UNIX
# compatible delivery agent that lookups all recipients in /etc/passwd
# and /etc/aliases or their equivalent.
#
# The default is $myhostname + localhost.$mydomain. On a mail domain
# gateway, you should also include $mydomain.
#
# Do not specify the names of virtual domains - those domains are
# specified elsewhere (see VIRTUAL_README).
#
# Do not specify the names of domains that this machine is backup MX
# host for. Specify those names via the relay_domains settings for
# the SMTP server, or use permit_mx_backup if you are lazy (see
# STANDARD_CONFIGURATION_README).
#
# The local machine is always the final destination for mail addressed
# to user@[the.net.work.address] of an interface that the mail system
# receives mail on (see the inet_interfaces parameter).
#
# Specify a list of host or domain names, /file/name or type:table
# patterns, separated by commas and/or whitespace. A /file/name
# pattern is replaced by its contents; a type:table is matched when
# a name matches a lookup key (the right-hand side is ignored).
# Continue long lines by starting the next line with whitespace.
#
# See also below, section "REJECTING MAIL FOR UNKNOWN LOCAL USERS".
#
#mydestination = $myhostname, localhost.$mydomain, localhost
#mydestination = $myhostname, localhost.$mydomain, localhost, $mydomain,zhang.org,mail.zhang.org
#mydestination = $myhostname, localhost.$mydomain, localhost, $mydomain,
# mail.$mydomain, www.$mydomain, ftp.$mydomain

# REJECTING MAIL FOR UNKNOWN LOCAL USERS
#
# The local_recipient_maps parameter specifies optional lookup tables
# with all names or addresses of users that are local with respect
# to $mydestination, $inet_interfaces or $proxy_interfaces.
#
# If this parameter is defined, then the SMTP server will reject
# mail for unknown local users. This parameter is defined by default.
#
# To turn off local recipient checking in the SMTP server, specify
# local_recipient_maps = (i.e. empty).
#
# The default setting assumes that you use the default Postfix local
# delivery agent for local delivery. You need to update the
# local_recipient_maps setting if:
#
# - You define $mydestination domain recipients in files other than
# /etc/passwd, /etc/aliases, or the $virtual_alias_maps files.
# For example, you define $mydestination domain recipients in
# the $virtual_mailbox_maps files.
#
# - You redefine the local delivery agent in master.cf.
#
# - You redefine the "local_transport" setting in main.cf.
#
# - You use the "luser_relay", "mailbox_transport", or "fallback_transport"
# feature of the Postfix local delivery agent (see local(8)).
#
# Details are described in the LOCAL_RECIPIENT_README file.
#
# Beware: if the Postfix SMTP server runs chrooted, you probably have
# to access the passwd file via the proxymap service, in order to
# overcome chroot restrictions. The alternative, having a copy of
# the system passwd file in the chroot jail is just not practical.
#
# The right-hand side of the lookup tables is conveniently ignored.
# In the left-hand side, specify a bare username, an @domain.tld
# wild-card, or specify a user@domain.tld address.
#
#local_recipient_maps = unix:passwd.byname $alias_maps
#local_recipient_maps = proxy:unix:passwd.byname $alias_maps
#local_recipient_maps =

# The unknown_local_recipient_reject_code specifies the SMTP server
# response code when a recipient domain matches $mydestination or
# ${proxy,inet}_interfaces, while $local_recipient_maps is non-empty
# and the recipient address or address local-part is not found.
#
# The default setting is 550 (reject mail) but it is safer to start
# with 450 (try again later) until you are certain that your
# local_recipient_maps settings are OK.
#
unknown_local_recipient_reject_code = 550

# TRUST AND RELAY CONTROL

# The mynetworks parameter specifies the list of "trusted" SMTP
# clients that have more privileges than "strangers".
# In particular, "trusted" SMTP clients are allowed to relay mail
# through Postfix. See the smtpd_recipient_restrictions parameter
# in postconf(5).
#
# You can specify the list of "trusted" network addresses by hand
# or you can let Postfix do it for you (which is the default).
#
# By default (mynetworks_style = subnet), Postfix "trusts" SMTP
# clients in the same IP subnetworks as the local machine.
# On Linux, this does works correctly only with interfaces specified
# with the "ifconfig" command.
#
# Specify "mynetworks_style = class" when Postfix should "trust" SMTP
# clients in the same IP class A/B/C networks as the local machine.
# Don't do this with a dialup site - it would cause Postfix to "trust"
# your entire provider's network. Instead, specify an explicit
# mynetworks list by hand, as described below.
#
# Specify "mynetworks_style = host" when Postfix should "trust"
# only the local machine.
#
#mynetworks_style = class
#mynetworks_style = subnet
#mynetworks_style = host

# Alternatively, you can specify the mynetworks list by hand, in
# which case Postfix ignores the mynetworks_style setting.
#
# Specify an explicit list of network/netmask patterns, where the
# mask specifies the number of bits in the network part of a host
# address.
#
# You can also specify the absolute pathname of a pattern file instead
# of listing the patterns here. Specify type:table for table-based lookups
# (the value on the table right-hand side is not used).
#
mynetworks = 192.168.1.0/24, 127.0.0.0/8
#mynetworks = $config_directory/mynetworks
#mynetworks = hash:/etc/postfix/network_table

# The relay_domains parameter restricts what destinations this system will
# relay mail to. See the smtpd_recipient_restrictions description in
# postconf(5) for detailed information.
#
# By default, Postfix relays mail
# - from "trusted" clients (IP address matches $mynetworks) to any destination,
# - from "untrusted" clients to destinations that match $relay_domains or
# subdomains thereof, except addresses with sender-specified routing.
# The default relay_domains value is $mydestination.
#
# In addition to the above, the Postfix SMTP server by default accepts mail
# that Postfix is final destination for:
# - destinations that match $inet_interfaces or $proxy_interfaces,
# - destinations that match $mydestination
# - destinations that match $virtual_alias_domains,
# - destinations that match $virtual_mailbox_domains.
……
# This is the Sendmail-compatible mail posting interface.
#
sendmail_path = /usr/sbin/sendmail

# newaliases_path: The full pathname of the Postfix newaliases command.
# This is the Sendmail-compatible command to build alias databases.
#
newaliases_path = /usr/bin/newaliases

# mailq_path: The full pathname of the Postfix mailq command. This
# is the Sendmail-compatible mail queue listing command.
#
mailq_path = /usr/bin/mailq

# setgid_group: The group for mail submission and queue management
# commands. This must be a group name with a numerical group ID that
# is not shared with other accounts, not even with the Postfix account.
#
setgid_group = postdrop

# html_directory: The location of the Postfix HTML documentation.
#
html_directory = /var/www/postfix_html

# manpage_directory: The location of the Postfix on-line manual pages.
#
manpage_directory = /usr/local/postfix/man

# sample_directory: The location of the Postfix sample configuration files.
# This parameter is obsolete as of Postfix 2.1.
#
sample_directory = /etc/postfix

# readme_directory: The location of the Postfix README files.
#
readme_directory = no
############################CYRUS-SASL############################
#broken_sasl_auth_clients = yes
#smtpd_recipient_restrictions=permit_mynetworks,permit_sasl_authenticated,reject_invalid_hostname,reject_non_fqdn_hostname,reject_unknown_sender_domain,reject_non_fqdn_sender,reject_non_fqdn_recipient,reject_unknown_recipient_domain,reject_unauth_pipelining,reject_unauth_destination
#smtpd_sasl_auth_enable = yes
#smtpd_sasl_local_domain = $myhostname
#smtpd_sasl_security_options = noanonymous
#smtpd_sasl_application_name = smtpd
#smtpd_banner = Welcome to our $myhostname ESMTP,Warning: Version not Available!


broken_sasl_auth_clients = yes
smtpd_recipient_restrictions = permit_mynetworks,permit_sasl_authenticated,reject_invalid_hostname,reject_non_fqdn_hostname,reject_unknown_sender_domain,reject_non_fqdn_sender,reject_non_fqdn_recipient,reject_unknown_recipient_domain,reject_unauth_pipelining,reject_unauth_destination,permit
smtpd_sasl_auth_enable = yes
smtpd_sasl_local_domain = $myhostname
smtpd_sasl_security_options = noanonymous
smtpd_sasl_application_name = smtpd
smtpd_banner = Welcome to our $myhostname ESMTP,Warning: Version not Available!

下面是一些日志:# tail /var/log/messages
Oct 18 17:26:03 zone named[14788]: named.local:7: using RFC1035 TTL semantics
Oct 18 17:26:03 zone named[14788]: zone localhost/IN: loaded serial 20070301
Oct 18 17:26:03 zone named[14788]: zone zhang.org/IN: NS 'nameserver.zhang.org' has no address records (A or AAAA)
Oct 18 17:26:03 zone named[14788]: zone zhang.org/IN: loaded serial 20071810
Oct 18 17:26:03 zone named[14788]: running
Oct 18 17:32:15 zone su(pam_unix)[14794]: session opened for user redhat by root(uid=0)
Oct 18 17:32:58 zone su(pam_unix)[14822]: session opened for user root by root(uid=2527)
Oct 18 17:33:00 zone su(pam_unix)[14841]: session opened for user root by root(uid=0)
Oct 18 18:26:07 zone su(pam_unix)[15110]: session opened for user redhat by root(uid=0)
Oct 18 18:26:18 zone su(pam_unix)[15139]: session opened for user root by root(uid=2527)

# tail /var/log/maillog
Oct 18 22:05:11 zone postfix/postqueue[15046]: warning: Mail system is down -- accessing queue directly
Oct 18 18:16:48 zone postfix/postfix-script[15099]: starting the Postfix mail system
Oct 18 18:16:48 zone postfix/master[15100]: fatal: bind 0.0.0.0 port 25: Address already in use
Oct 18 18:18:03 zone sendmail[15102]: l9IMGsDq015102: from=redhat@zhang.org, size=32, class=0, nrcpts=1, msgid=<200710182217.l9IMGsDq015102@localhost.localdomain>, proto=ESMTP, daemon=MTA, relay=zone [127.0.0.1]
Oct 18 18:18:04 zone sendmail[15104]: l9IMGsDq015102: to=root@zhang.org, delay=00:00:19, xdelay=00:00:01, mailer=esmtp, pri=120032, relay=zhang.org. [66.116.125.144], dsn=4.0.0, stat=Deferred: Connection refused by zhang.org.
Oct 18 18:27:31 zone postfix/postfix-script[15177]: fatal: the Postfix mail system is not running
Oct 18 18:32:48 zone postfix/postfix-script[15181]: fatal: the Postfix mail system is not running
Oct 18 18:34:43 zone postfix/postfix-script[15185]: fatal: the Postfix mail system is not running
Oct 18 18:46:51 zone postfix/postfix-script[15192]: fatal: the Postfix mail system is not running
Oct 18 18:49:14 zone sendmail[15194]: l9IMl4hP015194: zone [127.0.0.1] did not issue MAIL/EXPN/VRFY/ETRN during connection to MTA

postfix基于cyrus-sasl的认证功能也开启了,另外我以前做的discuz也打不开了!!!
请问高手,问题出在哪里?

[ 本帖最后由 junger 于 2007-10-22 18:15 编辑 ]

yinglikx2006 回复于:2007-10-22 18:36:04

marion 兄,我装了extmail,extman后,我访问
http://email.thinkcore.net/extmail/cgi/index.cgi和
http://email.thinkcore.net/extman/cgi/index.cgi
是页面都是空白,什么错误也没有,

日志内容:
[root@email www]# tail -n 40 /var/log/mail
mail/ maillog maillog.1
[root@email www]# tail -n 40 /var/log/maillog
Oct 22 17:50:32 email postfix/cleanup[4817]: warning: 5CA8CE30194: virtual_alias_maps map lookup problem for root@thinkcore.net
Oct 22 17:50:32 email postfix/pickup[4906]: warning: 5D098E30194: message has been queued for 3 days
Oct 22 17:50:32 email postfix/pickup[4906]: 5D098E30194: uid=0 from=<root>
Oct 22 17:50:32 email postfix/cleanup[4817]: warning: 5D098E30194: virtual_alias_maps map lookup problem for root@thinkcore.net
Oct 22 17:51:32 email postfix/pickup[4906]: warning: 5B31EE30194: message has been queued for 1 days
Oct 22 17:51:32 email postfix/pickup[4906]: 5B31EE30194: uid=0 from=<root>
Oct 22 17:51:32 email postfix/cleanup[4817]: warning: 5B31EE30194: virtual_alias_maps map lookup problem for root@thinkcore.net
Oct 22 17:51:32 email postfix/pickup[4906]: 5C142E30194: uid=0 from=<root>
Oct 22 17:51:32 email postfix/cleanup[4817]: warning: 5C142E30194: virtual_alias_maps map lookup problem for root@thinkcore.net
Oct 22 17:51:32 email postfix/pickup[4906]: warning: 5D5D6E30194: message has been queued for 2 days
Oct 22 17:51:32 email postfix/pickup[4906]: 5D5D6E30194: uid=0 from=<root>
Oct 22 17:51:32 email postfix/cleanup[4817]: warning: 5D5D6E30194: virtual_alias_maps map lookup problem for root@thinkcore.net
Oct 22 17:51:32 email postfix/pickup[4906]: warning: 5DBC8E30194: message has been queued for 3 days
Oct 22 17:51:32 email postfix/pickup[4906]: 5DBC8E30194: uid=0 from=<root>
Oct 22 17:51:32 email postfix/cleanup[4817]: warning: 5DBC8E30194: virtual_alias_maps map lookup problem for root@thinkcore.net
Oct 22 17:52:32 email postfix/pickup[4906]: warning: 5BC02E30194: message has been queued for 1 days
Oct 22 17:52:32 email postfix/pickup[4906]: 5BC02E30194: uid=0 from=<root>
Oct 22 17:52:32 email postfix/cleanup[4817]: 5BC02E30194: message-id=<20071022095232.5BC02E30194@email.thinkcore.net>
Oct 22 17:52:32 email postfix/qmgr[416]: 5BC02E30194: from=<root@thinkcore.net>, size=319121, nrcpt=1 (queue active)
Oct 22 17:52:32 email postfix/pickup[4906]: 5E185E3018A: uid=0 from=<root>
Oct 22 17:52:32 email postfix/cleanup[4817]: 5E185E3018A: message-id=<20071022095232.5E185E3018A@email.thinkcore.net>
Oct 22 17:52:32 email postfix/qmgr[416]: 5E185E3018A: from=<root@thinkcore.net>, size=483649, nrcpt=1 (queue active)
Oct 22 17:52:32 email postfix/pickup[4906]: warning: 61829E30193: message has been queued for 2 days
Oct 22 17:52:32 email postfix/pickup[4906]: 61829E30193: uid=0 from=<root>
Oct 22 17:52:32 email postfix/cleanup[4817]: 61829E30193: message-id=<20071022095232.61829E30193@email.thinkcore.net>
Oct 22 17:52:32 email postfix/qmgr[416]: 61829E30193: from=<root@thinkcore.net>, size=110532, nrcpt=1 (queue active)
Oct 22 17:52:32 email postfix/pickup[4906]: warning: 62F16E30189: message has been queued for 3 days
Oct 22 17:52:32 email postfix/pickup[4906]: 62F16E30189: uid=0 from=<root>
Oct 22 17:52:32 email postfix/cleanup[4817]: 62F16E30189: message-id=<20071022095232.62F16E30189@email.thinkcore.net>
Oct 22 17:52:32 email postfix/local[4917]: warning: dict_nis_init: NIS domain name not set - NIS lookups disabled
Oct 22 17:52:32 email postfix/local[4918]: warning: dict_nis_init: NIS domain name not set - NIS lookups disabled
Oct 22 17:52:32 email postfix/local[4917]: 5BC02E30194: to=<root@thinkcore.net>, orig_to=<root>, relay=local, delay=136228, delays=136228/0.02/0/0.01, dsn=2.0.0, status=sent (delivered to mailbox)
Oct 22 17:52:32 email postfix/qmgr[416]: 62F16E30189: from=<root@thinkcore.net>, size=3276, nrcpt=1 (queue active)
Oct 22 17:52:32 email postfix/qmgr[416]: 5BC02E30194: removed
Oct 22 17:52:32 email postfix/local[4918]: 5E185E3018A: to=<root@thinkcore.net>, orig_to=<root>, relay=local, delay=49828, delays=49828/0.02/0/0.01, dsn=2.0.0, status=sent (delivered to mailbox)
Oct 22 17:52:32 email postfix/qmgr[416]: 5E185E3018A: removed
Oct 22 17:52:32 email postfix/local[4918]: 62F16E30189: to=<root@thinkcore.net>, orig_to=<root>, relay=local, delay=309030, delays=309030/0.01/0/0, dsn=2.0.0, status=sent (delivered to mailbox)
Oct 22 17:52:32 email postfix/qmgr[416]: 62F16E30189: removed
Oct 22 17:52:33 email postfix/local[4917]: 61829E30193: to=<root@thinkcore.net>, orig_to=<root>, relay=local, delay=222630, delays=222629/0.01/0/1.1, dsn=2.0.0, status=sent (delivered to mailbox)
Oct 22 17:52:33 email postfix/qmgr[416]: 61829E30193: removed

yinglikx2006 回复于:2007-10-22 18:43:21

并且我的telnet localhost 25 一切都正常啊,请问这是那里配置的问题呢?

zdyldy 回复于:2007-10-23 09:31:00

回复 #204 zdyldy 的帖子


具体实现方法很繁琐,建议使用本版提供的“postfix中文权威指南”来了解相关的实现方法。




marion老,您说的“postfix中文权威指南”在哪呢.我怎么才能看到呢.

marion 回复于:2007-10-23 11:26:30

引用:Oct 18 18:16:48 zone postfix/postfix-script[15099]: starting the Postfix mail system
Oct 18 18:16:48 zone postfix/master[15100]: fatal: bind 0.0.0.0 port 25: Address already in use


这个表明你的25端口在使用中,建议查看是否sendmil仍在运行!!!

marion 回复于:2007-10-23 11:30:10

如果postfix没有问题,你应该去apache的日志文件中查看问题所在。

marion 回复于:2007-10-23 11:31:57

引用:原帖由 zdyldy 于 2007-10-23 09:31 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=7497271&ptid=987344
回复 #204 zdyldy 的帖子
marion老,您说的“postfix中文权威指南”在哪呢.我怎么才能看到呢.


本版的置顶帖子中有提供下载!!!!

zdyldy 回复于:2007-10-23 13:24:46

[root@mail Mail-SPF-v2.005]# perl Makefile.PL
# running Build.PL
/usr/bin/perl Build.PL
Creating custom builder _build/lib/MyModuleBuilder.pm in _build/lib
Checking whether your kit is complete...
Looks good

Checking prerequisites...
- ERROR: Error is not installed
- ERROR: version is not installed

ERRORS/WARNINGS FOUND IN PREREQUISITES. You may wish to install the versions
of the modules indicated above before proceeding with this installation

Creating new 'Build' script for 'Mail-SPF' version 'v2.005'
[root@mail Mail-SPF-v2.005]#

[ 本帖最后由 zdyldy 于 2007-10-23 16:20 编辑 ]

victorchang 回复于:2007-10-23 13:30:55

1.我的不能WEBMAIL不能收邮件的问题已经解决.
按手册做的是mydestination = $mydomain, $myhostname
执行命令:postconf -e mydestination=
将/ETC/POSTFIX/MAIN.CF文件中设置成mydestination=
就可以收邮件了,但是现在遇新的问题:
在收到新邮件后,没有办法进入邮箱查询.提示错误:
Can't open /var/mailbox/one234.net/cy/Maildir//./new/1193138694.Vfd00I1ec34cM605786.localhost.localdomain, Permission denied
我就这个文件执行权限设置chmod -R 777 后,就可以正常进入邮箱了.

2.通过exman新建了帐户test,并通过WEBMAIL方式给自己发信,和另外一个邮箱发信..
另外一个邮箱是公网的,收到了,本身没有收到.
/VAR/LOG/MAILLOG提示信息:
t>, size=507, nrcpt=2 (queue active)
Oct 23 14:18:28 localhost postfix/virtual[4821]: warning: maildir access problem for UID/GID=2525/2525: create maildir file /var/mailbox/one234.net/test/Maildir/tmp/1193141908.P4821.localhost.localdomain: Permission denied

[ 本帖最后由 victorchang 于 2007-10-23 14:26 编辑 ]

zdyldy 回复于:2007-10-23 14:40:51

QUOTE:
原帖由 zdyldy 于 2007-10-23 09:31 发表
回复 #204 zdyldy 的帖子
marion,您说的“postfix中文权威指南”在哪呢.我怎么才能看到呢.
本版的置顶帖子中有提供下载!!!!

http://marion.cublog.cn 是这个网站么,怎么没找到呢.

victorchang 回复于:2007-10-23 15:35:13

引用:原帖由 zdyldy 于 2007-10-23 14:40 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=7499644&ptid=987344
QUOTE:
原帖由 zdyldy 于 2007-10-23 09:31 发表
回复 #204 zdyldy 的帖子
marion,您说的“postfix中文权威指南”在哪呢.我怎么才能看到呢.
本版的置顶帖子中有提供下载!!!!

http://marion.cublog ...

你应该学会GOOGLE搜呀..


http://www.sbear.cn/archives/63

junger 回复于:2007-10-23 16:15:21

安装Courier authentication library

# tar jxvf courier-authlib-0.59.3.tar.bz2
# cd courier-authlib-0.59.3
#./configure
--prefix=/usr/local/courier-authlib
--sysconfdir=/etc
--without-authpam
--without-authldap
--without-authpwd
--without-authshadow
--without-authvchkpw
--without-authpgsql
--with-authmysql
--with-mysql-libs=/usr/local/mysql/lib/mysql
--with-mysql-includes=/usr/local/mysql/inculde/mysql
--with-redhat
--with-authmysqlrc=/etc/authmysqlrc
--with-authdaemonrc=/etc/authdaemonrc
CFLAGS="-march=i686 -O2 -fexpensive-optimizations"
CXXFLAGS="-march=i686 -O2 -fexpensive-optimizations"
# make;make install
make all-recursive
make[1]: Entering directory `/usr/local/src/courier-authlib-0.59.3'
Making all in gdbmobj
make[2]: Entering directory `/usr/local/src/courier-authlib-0.59.3/gdbmobj'
make all-am
make[3]: Entering directory `/usr/local/src/courier-authlib-0.59.3/gdbmobj'
make[3]: Leaving directory `/usr/local/src/courier-authlib-0.59.3/gdbmobj'
make[2]: Leaving directory `/usr/local/src/courier-authlib-0.59.3/gdbmobj'
Making all in md5
make[2]: Entering directory `/usr/local/src/courier-authlib-0.59.3/md5'
make all-am
make[3]: Entering directory `/usr/local/src/courier-authlib-0.59.3/md5'
make[3]: Leaving directory `/usr/local/src/courier-authlib-0.59.3/md5'
make[2]: Leaving directory `/usr/local/src/courier-authlib-0.59.3/md5'
Making all in sha1
make[2]: Entering directory `/usr/local/src/courier-authlib-0.59.3/sha1'
make all-am
make[3]: Entering directory `/usr/local/src/courier-authlib-0.59.3/sha1'
make[3]: Leaving directory `/usr/local/src/courier-authlib-0.59.3/sha1'
make[2]: Leaving directory `/usr/local/src/courier-authlib-0.59.3/sha1'
Making all in libhmac
make[2]: Entering directory `/usr/local/src/courier-authlib-0.59.3/libhmac'
make all-am
make[3]: Entering directory `/usr/local/src/courier-authlib-0.59.3/libhmac'
make[3]: Leaving directory `/usr/local/src/courier-authlib-0.59.3/libhmac'
make[2]: Leaving directory `/usr/local/src/courier-authlib-0.59.3/libhmac'
Making all in numlib
make[2]: Entering directory `/usr/local/src/courier-authlib-0.59.3/numlib'
make all-am
make[3]: Entering directory `/usr/local/src/courier-authlib-0.59.3/numlib'
make[3]: Leaving directory `/usr/local/src/courier-authlib-0.59.3/numlib'
make[2]: Leaving directory `/usr/local/src/courier-authlib-0.59.3/numlib'
Making all in makedat
make[2]: Entering directory `/usr/local/src/courier-authlib-0.59.3/makedat'
make all-am
make[3]: Entering directory `/usr/local/src/courier-authlib-0.59.3/makedat'
make[3]: Leaving directory `/usr/local/src/courier-authlib-0.59.3/makedat'
make[2]: Leaving directory `/usr/local/src/courier-authlib-0.59.3/makedat'
Making all in userdb
make[2]: Entering directory `/usr/local/src/courier-authlib-0.59.3/userdb'
make all-am
make[3]: Entering directory `/usr/local/src/courier-authlib-0.59.3/userdb'
make[3]: Nothing to be done for `all-am'.
make[3]: Leaving directory `/usr/local/src/courier-authlib-0.59.3/userdb'
make[2]: Leaving directory `/usr/local/src/courier-authlib-0.59.3/userdb'
Making all in rfc822
make[2]: Entering directory `/usr/local/src/courier-authlib-0.59.3/rfc822'
make all-am
make[3]: Entering directory `/usr/local/src/courier-authlib-0.59.3/rfc822'
make[3]: Leaving directory `/usr/local/src/courier-authlib-0.59.3/rfc822'
make[2]: Leaving directory `/usr/local/src/courier-authlib-0.59.3/rfc822'
Making all in random128
make[2]: Entering directory `/usr/local/src/courier-authlib-0.59.3/random128'
make all-am
make[3]: Entering directory `/usr/local/src/courier-authlib-0.59.3/random128'
make[3]: Leaving directory `/usr/local/src/courier-authlib-0.59.3/random128'
make[2]: Leaving directory `/usr/local/src/courier-authlib-0.59.3/random128'
Making all in liblock
make[2]: Entering directory `/usr/local/src/courier-authlib-0.59.3/liblock'
make all-am
make[3]: Entering directory `/usr/local/src/courier-authlib-0.59.3/liblock'
make[3]: Leaving directory `/usr/local/src/courier-authlib-0.59.3/liblock'
make[2]: Leaving directory `/usr/local/src/courier-authlib-0.59.3/liblock'
Making all in liblog
make[2]: Entering directory `/usr/local/src/courier-authlib-0.59.3/liblog'
make all-am
make[3]: Entering directory `/usr/local/src/courier-authlib-0.59.3/liblog'
make[3]: Leaving directory `/usr/local/src/courier-authlib-0.59.3/liblog'
make[2]: Leaving directory `/usr/local/src/courier-authlib-0.59.3/liblog'
make[2]: Entering directory `/usr/local/src/courier-authlib-0.59.3'
Compiling authmysql.c
In file included from authmysql.c:18:
authmysql.h:8:19: mysql.h: No such file or directory
authmysql.h:9:20: errmsg.h: No such file or directory
make[2]: *** [authmysql.lo] Error 1
make[2]: Leaving directory `/usr/local/src/courier-authlib-0.59.3'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/usr/local/src/courier-authlib-0.59.3'
make: *** [all] Error 2
make install-recursive
make[1]: Entering directory `/usr/local/src/courier-authlib-0.59.3'
Making install in gdbmobj
make[2]: Entering directory `/usr/local/src/courier-authlib-0.59.3/gdbmobj'
make[3]: Entering directory `/usr/local/src/courier-authlib-0.59.3/gdbmobj'
make[3]: Nothing to be done for `install-exec-am'.
make[3]: Nothing to be done for `install-data-am'.
make[3]: Leaving directory `/usr/local/src/courier-authlib-0.59.3/gdbmobj'
make[2]: Leaving directory `/usr/local/src/courier-authlib-0.59.3/gdbmobj'
Making install in md5
make[2]: Entering directory `/usr/local/src/courier-authlib-0.59.3/md5'
make[3]: Entering directory `/usr/local/src/courier-authlib-0.59.3/md5'
make[3]: Nothing to be done for `install-exec-am'.
make[3]: Nothing to be done for `install-data-am'.
make[3]: Leaving directory `/usr/local/src/courier-authlib-0.59.3/md5'
make[2]: Leaving directory `/usr/local/src/courier-authlib-0.59.3/md5'
Making install in sha1
make[2]: Entering directory `/usr/local/src/courier-authlib-0.59.3/sha1'
make[3]: Entering directory `/usr/local/src/courier-authlib-0.59.3/sha1'
make[3]: Nothing to be done for `install-exec-am'.
make[3]: Nothing to be done for `install-data-am'.
make[3]: Leaving directory `/usr/local/src/courier-authlib-0.59.3/sha1'
make[2]: Leaving directory `/usr/local/src/courier-authlib-0.59.3/sha1'
Making install in libhmac
make[2]: Entering directory `/usr/local/src/courier-authlib-0.59.3/libhmac'
make[3]: Entering directory `/usr/local/src/courier-authlib-0.59.3/libhmac'
make[3]: Nothing to be done for `install-exec-am'.
make[3]: Nothing to be done for `install-data-am'.
make[3]: Leaving directory `/usr/local/src/courier-authlib-0.59.3/libhmac'
make[2]: Leaving directory `/usr/local/src/courier-authlib-0.59.3/libhmac'
Making install in numlib
make[2]: Entering directory `/usr/local/src/courier-authlib-0.59.3/numlib'
make[3]: Entering directory `/usr/local/src/courier-authlib-0.59.3/numlib'
make[3]: Nothing to be done for `install-exec-am'.
make[3]: Nothing to be done for `install-data-am'.
make[3]: Leaving directory `/usr/local/src/courier-authlib-0.59.3/numlib'
make[2]: Leaving directory `/usr/local/src/courier-authlib-0.59.3/numlib'
Making install in makedat
make[2]: Entering directory `/usr/local/src/courier-authlib-0.59.3/makedat'
make[3]: Entering directory `/usr/local/src/courier-authlib-0.59.3/makedat'
make[3]: Nothing to be done for `install-exec-am'.
make[3]: Nothing to be done for `install-data-am'.
make[3]: Leaving directory `/usr/local/src/courier-authlib-0.59.3/makedat'
make[2]: Leaving directory `/usr/local/src/courier-authlib-0.59.3/makedat'
Making install in userdb
make[2]: Entering directory `/usr/local/src/courier-authlib-0.59.3/userdb'
make install-am
make[3]: Entering directory `/usr/local/src/courier-authlib-0.59.3/userdb'
make[4]: Entering directory `/usr/local/src/courier-authlib-0.59.3/userdb'
make[4]: Nothing to be done for `install-exec-am'.
test -z "/usr/local/courier-authlib/man/man8" || mkdir -p -- "/usr/local/courier-authlib/man/man8"
/usr/bin/install -c -m 644 './makeuserdb.8' '/usr/local/courier-authlib/man/man8/makeuserdb.8'
/usr/bin/install -c -m 644 './userdb.8' '/usr/local/courier-authlib/man/man8/userdb.8'
/usr/bin/install -c -m 644 './userdbpw.8' '/usr/local/courier-authlib/man/man8/userdbpw.8'
make[4]: Leaving directory `/usr/local/src/courier-authlib-0.59.3/userdb'
make[3]: Leaving directory `/usr/local/src/courier-authlib-0.59.3/userdb'
make[2]: Leaving directory `/usr/local/src/courier-authlib-0.59.3/userdb'
Making install in rfc822
make[2]: Entering directory `/usr/local/src/courier-authlib-0.59.3/rfc822'
make install-am
make[3]: Entering directory `/usr/local/src/courier-authlib-0.59.3/rfc822'
make[4]: Entering directory `/usr/local/src/courier-authlib-0.59.3/rfc822'
make[4]: Nothing to be done for `install-exec-am'.
make[4]: Nothing to be done for `install-data-am'.
make[4]: Leaving directory `/usr/local/src/courier-authlib-0.59.3/rfc822'
make[3]: Leaving directory `/usr/local/src/courier-authlib-0.59.3/rfc822'
make[2]: Leaving directory `/usr/local/src/courier-authlib-0.59.3/rfc822'
Making install in random128
make[2]: Entering directory `/usr/local/src/courier-authlib-0.59.3/random128'
make[3]: Entering directory `/usr/local/src/courier-authlib-0.59.3/random128'
make[3]: Nothing to be done for `install-exec-am'.
make[3]: Nothing to be done for `install-data-am'.
make[3]: Leaving directory `/usr/local/src/courier-authlib-0.59.3/random128'
make[2]: Leaving directory `/usr/local/src/courier-authlib-0.59.3/random128'
Making install in liblock
make[2]: Entering directory `/usr/local/src/courier-authlib-0.59.3/liblock'
make[3]: Entering directory `/usr/local/src/courier-authlib-0.59.3/liblock'
make[3]: Nothing to be done for `install-exec-am'.
make[3]: Nothing to be done for `install-data-am'.
make[3]: Leaving directory `/usr/local/src/courier-authlib-0.59.3/liblock'
make[2]: Leaving directory `/usr/local/src/courier-authlib-0.59.3/liblock'
Making install in liblog
make[2]: Entering directory `/usr/local/src/courier-authlib-0.59.3/liblog'
make install-am
make[3]: Entering directory `/usr/local/src/courier-authlib-0.59.3/liblog'
make[4]: Entering directory `/usr/local/src/courier-authlib-0.59.3/liblog'
test -z "/usr/local/courier-authlib/sbin" || mkdir -p -- "/usr/local/courier-authlib/sbin"
/bin/sh ./libtool --mode=install /usr/bin/install -c 'courierlogger' '/usr/local/courier-authlib/sbin/courierlogger'
/usr/bin/install -c courierlogger /usr/local/courier-authlib/sbin/courierlogger
test -z "/usr/local/courier-authlib/man/man1" || mkdir -p -- "/usr/local/courier-authlib/man/man1"
/usr/bin/install -c -m 644 './courierlogger.1' '/usr/local/courier-authlib/man/man1/courierlogger.1'
make[4]: Leaving directory `/usr/local/src/courier-authlib-0.59.3/liblog'
make[3]: Leaving directory `/usr/local/src/courier-authlib-0.59.3/liblog'
make[2]: Leaving directory `/usr/local/src/courier-authlib-0.59.3/liblog'
make[2]: Entering directory `/usr/local/src/courier-authlib-0.59.3'
Compiling authmysql.c
In file included from authmysql.c:18:
authmysql.h:8:19: mysql.h: No such file or directory
authmysql.h:9:20: errmsg.h: No such file or directory
make[2]: *** [authmysql.lo] Error 1
make[2]: Leaving directory `/usr/local/src/courier-authlib-0.59.3'
make[1]: *** [install-recursive] Error 1
make[1]: Leaving directory `/usr/local/src/courier-authlib-0.59.3'
make: *** [install] Error 2

# chmod 755 /usr/local/courier-authlib/var/spool/authdaemon
chmod: cannot access `/usr/local/courier-authlib/var/spool/authdaemon': No such file or directory


# tail /var/log/maillog
Oct 18 20:20:52 zone postfix/cleanup[19887]: 02DCC8C13B: message-id=<20071019002033.02DCC8C13B@mail.zhang.org>
Oct 18 20:20:52 zone postfix/qmgr[19882]: 02DCC8C13B: from=<root@zhang.org>, size=353, nrcpt=1 (queue active)
Oct 18 20:20:52 zone postfix/smtp[19888]: 02DCC8C13B: to=<redhat@zhang.org>, relay=none, delay=31, delays=30/0.07/0.01/0, dsn=5.4.6, status=bounced (mail for zhang.org loops back to myself)
Oct 18 20:20:52 zone postfix/cleanup[19887]: 60D858C13F: message-id=<20071019002052.60D858C13F@mail.zhang.org>
Oct 18 20:20:52 zone postfix/qmgr[19882]: 60D858C13F: from=<>, size=2079, nrcpt=1 (queue active)
Oct 18 20:20:52 zone postfix/bounce[19890]: 02DCC8C13B: sender non-delivery notification: 60D858C13F
Oct 18 20:20:52 zone postfix/qmgr[19882]: 02DCC8C13B: removed
Oct 18 20:20:52 zone postfix/smtp[19888]: 60D858C13F: to=<root@zhang.org>, relay=none, delay=0.04, delays=0.03/0/0/0, dsn=5.4.6, status=bounced (mail for zhang.org loops back to myself)
Oct 18 20:20:52 zone postfix/qmgr[19882]: 60D858C13F: removed
Oct 18 20:20:53 zone postfix/smtpd[19884]: disconnect from zone[127.0.0.1]



# tail /var/log/messages
Oct 18 20:26:03 zone sshd(pam_unix)[19958]: session opened for user root by (uid=0)
Oct 18 21:04:23 zone su(pam_unix)[15139]: session closed for user root
Oct 18 21:04:23 zone su(pam_unix)[15110]: session closed for user redhat
Oct 18 21:04:23 zone su(pam_unix)[14841]: session closed for user root
Oct 18 21:04:23 zone su(pam_unix)[14822]: session closed for user root
Oct 18 21:04:23 zone su(pam_unix)[14794]: session closed for user redhat
Oct 18 21:04:23 zone su(pam_unix)[14748]: session closed for user root
Oct 18 21:04:24 zone su(pam_unix)[14731]: session closed for user root
Oct 18 21:04:24 zone su(pam_unix)[14711]: session closed for user root
Oct 18 21:04:24 zone su(pam_unix)[14682]: session closed for user redhat

是不是./configure时参数错了,还是……?可我都是按照LZ的文章做的啊,不应该啊!:em14: :em14:

zdyldy 回复于:2007-10-23 16:20:10

[root@mail Mail-SPF-v2.005]# perl Makefile.PL
# running Build.PL
/usr/bin/perl Build.PL
Creating custom builder _build/lib/MyModuleBuilder.pm in _build/lib
Checking whether your kit is complete...
Looks good

Checking prerequisites...
- ERROR: Error is not installed
- ERROR: version is not installed

ERRORS/WARNINGS FOUND IN PREREQUISITES. You may wish to install the versions
of the modules indicated above before proceeding with this installation

Creating new 'Build' script for 'Mail-SPF' version 'v2.005'
[root@mail Mail-SPF-v2.005]#


中间的两个错误是什么啊,如果是软件包,我没找到啊.

victorchang 回复于:2007-10-23 16:28:16

引用:原帖由 junger 于 2007-10-23 16:15 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=7500510&ptid=987344
安装Courier authentication library

# tar jxvf courier-authlib-0.59.3.tar.bz2
# cd courier-authlib-0.59.3
#./configure
--prefix=/usr/local/courier-authlib
--sysconfdir=/etc
...

这个问题我遇到过,应该是MYSQL路径的指向问题.
文档中说的是: /usr/local/mysql/lib/mysql ,你自己看一下,在lib下面,应该没有mysql 目录的,直接改成/usr/local/mysql/lib
还有一个步骤是:/usr/local/mysql/include/mysql 你自己看一下,在include下应该没有mysql目录的,改成/usr/local/mysql/include
把这两个参数改一下,你再编译试一下.....

[ 本帖最后由 victorchang 于 2007-10-23 16:32 编辑 ]

victorchang 回复于:2007-10-23 16:30:58

marion,帮忙看看我的问题呀,应该是权限的问题,不知道该怎么改动....

marion 回复于:2007-10-23 17:09:45

引用:Compiling authmysql.c
In file included from authmysql.c:18:
authmysql.h:8:19: mysql.h: No such file or directory
authmysql.h:9:20: errmsg.h: No such file or directory
make[2]: *** [authmysql.lo] Error 1
make[2]: Leaving directory `/usr/local/src/courier-authlib-0.59.3'
make[1]: *** [install-recursive] Error 1
make[1]: Leaving directory `/usr/local/src/courier-authlib-0.59.3'
make: *** [install] Error 2


这里已经报告错误是找不到mysql的相关头文件。试试以下命令后重新编译安装。

ln -sv /usr/local/mysql/include/mysql/* /usr/local/include

marion 回复于:2007-10-23 17:19:58

引用:Oct 23 14:18:28 localhost postfix/virtual[4821]: warning: maildir access problem for UID/GID=2525/2525: create maildir file /var/mailbox/one234.net/test/Maildir/tmp/1193141908.P4821.localhost.localdomain: Permission denied


没有权限访问maildir,/var/mailbox是不能被置为777的权限的,你检查一下它的属主应该是uid为2525的那个用户,如果你是按帖子一步步的做的话,即为postfix用户;同时,它的权限不能为777,最好设为700。如果还不行,把authdaemon的日志打开,而后把日志发上来。

marion 回复于:2007-10-23 17:23:47

引用:Checking prerequisites...
- ERROR: Error is not installed
- ERROR: version is not installed


这里不是已经表明了么????error和version没有安装。

去http://search.cpan.org搜索下载,并按照给出的三个标准步骤安装。

安装文档中也有相关说明的!!

victorchang 回复于:2007-10-23 19:25:59

引用:原帖由 marion 于 2007-10-23 17:19 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=7501163&ptid=987344


没有权限访问maildir,/var/mailbox是不能被置为777的权限的,你检查一下它的属主应该是uid为2525的那个用户,如果你是按帖子一步步的做的话,即为postfix用户;同时,它的权限不能为777,最好设为700。如果 ...

谢谢回复,
我看了一下,新建用户属主都是daemon.daemon用户的,不知道为什么?而且我是按文档一步一步做的呀.
我是这样的操作的,新建了一个帐户TEST,发现新属主是daemon.daemon
如下操作chmod -R 700 postfix.daemon
这样后,新建的TEST登录WEBMAIL.提示错误:
Can't chdir to /var/mailbox/one234.net/test2/Maildir/, Permission denied

[ 本帖最后由 victorchang 于 2007-10-23 19:36 编辑 ]

marion 回复于:2007-10-23 20:17:57

这是由于apache的运行身份指定的原因。

检查一下apache的User指令所指定的用户以及Group指定的组,对照安装文档中的说明仔细校正一下。(可以想像,运行httpd的用户不是postfix,却指定仅有postfix才能访问/var/mailbox,会有权限吗?)

victorchang 回复于:2007-10-23 22:04:46

引用:原帖由 marion 于 2007-10-23 20:17 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=7501853&ptid=987344
这是由于apache的运行身份指定的原因。

检查一下apache的User指令所指定的用户以及Group指定的组,对照安装文档中的说明仔细校正一下。(可以想像,运行httpd的用户不是postfix,却指定仅有postfix才能访问/ ...

测试了,新建的用户属主已经是POSTFIX,如下
---------------------------------

[root@mail one234.net]# pwd
/var/mailbox/one234.net
[root@mail one234.net]# ls -l
drwx------ 3 daemon daemon 4096 10&Ocirc;&Acirc; 23 21:56 cy
drwx------ 3 postfix postfix 4096 10&Ocirc;&Acirc; 23 22:32 gy
-----------
用新建的帐户gy进入,还是报下面的错误.
Can't chdir to /var/mailbox/one234.net/gy/Maildir/, Permission denied
-----
此问题已经解决,还是我操作上有问题,
我启动的APACHE服务,是在ROOT用户下,用/usr/local/apache2/bin/apachectl start进行启动的,
这时用ps -aux 查看,APACHE有一个父进程是用ROOT权限启动的,可能这个时候,EXTMAN在建立帐户的时候,权限写入会有问题,
于是将APACHE加到/ETC/RC.LOCAL中,进行自动启动,
启动后登录查看APACHE的进程全部是DAEMON权限启动的,这时,通过EXTMAN建立帐户,收发邮件就不会有权限写入的报错,
下一步测试FOXMAIL的终端方式收发....

[ 本帖最后由 victorchang 于 2007-10-24 09:55 编辑 ]

junger 回复于:2007-10-24 08:43:06

1、安装
# tar zxvf extmail-1.0.2.tar.gz
# mkdir -pv /var/www/extsuite
# mv extmail-1.0.2 /var/www/extsuite/extmail
# cp /var/www/extsuite/extmailwebmail.cf.default /var/www/extsuite/extmailwebmail.cf

cp: cannot stat `/var/www/extsuite/extmailwebmail.cf.default': No such file or directory


cp是不是应该为:
# cp /var/www/extsuite/extmail/webmail.cf.default /var/www/extsuite/extmail/webmail.cf

[root@zone extsuite]# cd extmail/
[root@zone extmail]# ls
AUTHORS dispatch.fcgi globabook.cf libs tools
cgi dispatch-init html README Version
ChangeLog dispatch_lig.sh INSTALL README.fcgi webmail.cf.default
CREDITS FAQ lang README.vpopmail

如果您没有打开apache服务器的suexec功能,也可以使用以下方法解决:
# vi /etc/httpd/httpd.conf
User postfix
Group postfix

<VirtualHost *:80>
ServerName mail.benet.org
DocumentRoot /var/www/extsuite/extmail/html/
ScriptAlias /extmail/cgi /var/www/extsuite/extmail/cgi
Alias /extmail /var/www/extsuite/extmail/html
</VirtualHost>

我怎样测试才能知道我有没有打开apache服务器的suexec功能?



另外还有一个问题:
[root@zone src]# cd DBD-mysql-3.0002_4
[root@zone DBD-mysql-3.0002_4]# perl Makefile.PL
Can't exec "mysql_config": No such file or directory at Makefile.PL line 79.

Cannot find the file 'mysql_config'! Your execution PATH doesn't seem
not contain the path to mysql_config. Resorting to guessed values!
Can't exec "mysql_config": No such file or directory at Makefile.PL line 468.
Can't exec "mysql_config": No such file or directory at Makefile.PL line 468.
Can't exec "mysql_config": No such file or directory at Makefile.PL line 468.
Can't exec "mysql_config": No such file or directory at Makefile.PL line 468.
Can't exec "mysql_config": No such file or directory at Makefile.PL line 468.
Can't exec "mysql_config": No such file or directory at Makefile.PL line 468.
Can't exec "mysql_config": No such file or directory at Makefile.PL line 468.
Can't exec "mysql_config": No such file or directory at Makefile.PL line 468.
Failed to determine directory of libmysqlclient.a|libmysqlclient.so. Use

perl Makefile.PL "--libs=-L<dir> -lmysqlclient -lz -lm -lcrypt -lnsl"

to set this directory. For details see the INSTALL.html file,
section "Linker flags" or type


77 me=`get_full_path $0`
78
79 basedir=`echo $me | sed -e 's;/bin/mysql_config;;'`
80
81 ldata='/usr/local/mysql/var'
82 execdir='/usr/local/mysql/libexec'
83 bindir='/usr/local/mysql/bin'

这个是什么问题?是环境变量还是……?:em14: :em14:

[ 本帖最后由 junger 于 2007-10-24 09:30 编辑 ]

danni505 回复于:2007-10-24 09:01:02

学习ing......

victorchang 回复于:2007-10-24 09:52:33

引用:原帖由 junger 于 2007-10-24 08:43 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=7503095&ptid=987344
1、安装
# tar zxvf extmail-1.0.2.tar.gz
# mkdir -pv /var/www/extsuite
# mv extmail-1.0.2 /var/www/extsuite/extmail
# cp /var/www/extsuite/extmailwebmail.cf.default /var/www/extsuite/extmailw ...

我觉得你可以通过EXTMAN建立一个帐户,
然后查看/var/mailbox/domains/new_account的目录的属主,是否是POSTFIX.POSTFIX,如果是,说明
已经启动,如果不是,可能是没有加载上呀....

zdyldy 回复于:2007-10-24 14:09:49

[root@mail Mail-SpamAssassin-3.2.3]# perl Makefile.PL
What email address or URL should be used in the suspected-spam report
text for users who want more information on your filter installation?
(In particular, ISPs should change this to a local Postmaster contact)
default text: [the administrator of that system]

NOTE: settings for "make test" are now controlled using "t/config.dist".
See that file if you wish to customise what tests are run, and how.

checking module dependencies and their versions...
Writing Makefile for Mail::SpamAssassin
Makefile written by ExtUtils::MakeMaker 6.30
[root@mail Mail-SpamAssassin-3.2.3]#


[root@mail Mail-SpamAssassin-3.2.3]# make check
make: *** 没有规则可以创建目标 "check". 停止.
[root@mail Mail-SpamAssassin-3.2.3]#


帮我看看,问题出在哪里啊.

我不知道该看哪个日志文件,如果想要看日志文件,请把文件名和所在目录告诉我好么.

marion 回复于:2007-10-24 14:15:22

引用:……[root@zone DBD-mysql-3.0002_4]# perl Makefile.PL
Can't exec "mysql_config": No such file or directory at Makefile.PL line 79.

Cannot find the file 'mysql_config'! Your execution PATH doesn't seem
not contain the path to mysql_config. Resorting to guessed values!
Can't exec "mysql_config": No such file or directory at Makefile.PL line 468.


这里已经说明问题所在,找不到mysql_config文件,解决办法在安装文档中应该有说明。

简单的做法:
#export PATH=$PATH:/usr/local/mysql/bin

marion 回复于:2007-10-24 14:19:11

引用:[root@mail Mail-SpamAssassin-3.2.3]# perl Makefile.PL
What email address or URL should be used in the suspected-spam report
text for users who want more information on your filter installation?
……………………
checking module dependencies and their versions...
Writing Makefile for Mail::SpamAssassin
Makefile written by ExtUtils::MakeMaker 6.30
[root@mail Mail-SpamAssassin-3.2.3]#

[root@mail Mail-SpamAssassin-3.2.3]# make check
make: *** 没有规则可以创建目标 "check". 停止.
……


好像没有看到你的make命令,怎么先make check了?

marion 回复于:2007-10-24 14:27:32

引用:我觉得你可以通过EXTMAN建立一个帐户,
然后查看/var/mailbox/domains/new_account的目录的属主,是否是POSTFIX.POSTFIX,如果是,说明
已经启动,如果不是,可能是没有加载上呀....


解决了问题不忘帮助别人:em02: ,赞!欢迎常来交流!

zdyldy 回复于:2007-10-24 14:28:38

我还有个问题,我怎么没找到,没有接收的邮件存放在哪个目录下呢.


我在/var/mailbox/下没看到啊

zdyldy 回复于:2007-10-24 14:31:47

回复 #233 zdyldy 的帖子




QUOTE:
[root@mail Mail-SpamAssassin-3.2.3]# perl Makefile.PL
What email address or URL should be used in the suspected-spam report
text for users who want more information on your filter installation?
……………………
checking module dependencies and their versions...
Writing Makefile for Mail::SpamAssassin
Makefile written by ExtUtils::MakeMaker 6.30
[root@mail Mail-SpamAssassin-3.2.3]#

[root@mail Mail-SpamAssassin-3.2.3]# make check
make: *** 没有规则可以创建目标 "check". 停止.
……
好像没有看到你的make命令,怎么先make check了?

不好意思,其实我执行make命令了,只是刚刚没打上.我先执行perl Makefile.PL 然后执行的make 再然后是make check

结果就出现了上面的错误.

victorchang 回复于:2007-10-24 14:45:04

引用:原帖由 zdyldy 于 2007-10-24 14:28 发表 [url=http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=7505690&ptid=987344]http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=7505690&ptid=987344

我还有个问题,我怎么没找到,没有接收的邮件存放在哪个目录下呢.


我在/var/mailbox/下没看到啊

你应该看一下/var/log/maillog文件中的日志呀,

是否是通过EXTMAN建立的帐户呢?
如果是,应该是和APACHE的配置有关了....具体看一下文档中的HTTPD \EXMAIL\EXMAN配置部分.

zdyldy 回复于:2007-10-24 15:14:50

2、安装amavisd-new-2.5.2

创建运行时目录,并赋予amavis用户(前文中所建)
# mkdir -pv /var/amavis/{tmp,var,db,home}
# chown -R amavis:amavis /var/amavis
#chmod -R 750 /var/amavis

#tar zxvf amavisd-new-2.5.2.tar.gz
#cd amavisd-new-2.5.2

拷贝服务端至$PATH中指定的目录,推荐拷贝至/usr/local/sbin:
#cp amavisd /usr/local/sbin/
#chown root /usr/local/sbin/amavisd
#chmod 755 /usr/local/sbin/amavisd


上面的步骤 解完包后,怎么没有进行安装呢.

是不是忘写了.

victorchang 回复于:2007-10-24 15:28:35

大家是不是应该解决问题后,将处理过程写上来,这样别人也可以直接利用了...
-----------------------------------------------------------
现在遇到的问题.
我现在FOXMAIL没有办法进行发送和接收.
telnet mail.one234.net 110
+OK Hello there.
user test@one234.net
+OK Password required.
pass ********
-ERR chdir Maildir failed

victorchang 回复于:2007-10-25 11:18:58

marion,帮忙看看这个问题呀...
我现在FOXMAIL没有办法进行发送和接收.
telnet mail.one234.net 110
+OK Hello there.
user test@one234.net
+OK Password required.
pass ********
-ERR chdir Maildir failed

marion 回复于:2007-10-25 14:26:56

引用:[root@mail Mail-SpamAssassin-3.2.3]# make check
make: *** 没有规则可以创建目标 "check". 停止.
[root@mail Mail-SpamAssassin-3.2.3]#


make命令没能完成。你应该把make时出现的错误信息贴上来。

marion 回复于:2007-10-25 14:27:40

打开authdaemon的日志,重新登录一次,把相关的错误日志发上来。

marion 回复于:2007-10-25 14:29:07

引用:上面的步骤 解完包后,怎么没有进行安装呢.

是不是忘写了.


你觉得是应该忘写了吗?:em20:

zdyldy 回复于:2007-10-25 14:55:26

回复 #240 zdyldy 的帖子



QUOTE:
上面的步骤 解完包后,怎么没有进行安装呢.

是不是忘写了.

你觉得是应该忘写了吗?



哈哈不好意思.我是不懂阿

zdyldy 回复于:2007-10-25 15:13:49

[root@mail Mail-SpamAssassin-3.2.3]# perl Makefile.PL
What email address or URL should be used in the suspected-spam report
text for users who want more information on your filter installation?
(In particular, ISPs should change this to a local Postmaster contact)
default text: [the administrator of that system]

到这步的时候系统提示按回车,

NOTE: settings for "make test" are now controlled using "t/config.dist".
See that file if you wish to customise what tests are run, and how.

checking module dependencies and their versions...
Checking if your kit is complete...
Looks good
Writing Makefile for Mail::SpamAssassin
Makefile written by ExtUtils::MakeMaker 6.30
[root@mail Mail-SpamAssassin-3.2.3]#

make时好像没发现错误.


FIX="/usr" -DDEF_RULES_DIR="/usr/share/spamassassin" -DLOCAL_RULES_DIR="/etc/mail/spamassassin" -DLOCAL_STATE_DIR="/var/lib/spamassassin" <lib/Mail/SpamAssassin/Plugin/DNSEval.pm >blib/lib/Mail/SpamAssassin/Plugin/DNSEval.pm
/usr/bin/perl build/preprocessor -Mconditional -Mvars -DVERSION="3.002003" -DPREFIX="/usr" -DDEF_RULES_DIR="/usr/share/spamassassin" -DLOCAL_RULES_DIR="/etc/mail/spamassassin" -DLOCAL_STATE_DIR="/var/lib/spamassassin" <lib/Mail/SpamAssassin/Plugin/URIDNSBL.pm >blib/lib/Mail/SpamAssassin/Plugin/URIDNSBL.pm
/usr/bin/perl build/preprocessor -Mconditional -Mvars -DVERSION="3.002003" -DPREFIX="/usr" -DDEF_RULES_DIR="/usr/share/spamassassin" -DLOCAL_RULES_DIR="/etc/mail/spamassassin" -DLOCAL_STATE_DIR="/var/lib/spamassassin" <lib/Mail/SpamAssassin/BayesStore/PgSQL.pm >blib/lib/Mail/SpamAssassin/BayesStore/PgSQL.pm
/usr/bin/perl build/preprocessor -Mconditional -Mvars -DVERSION="3.002003" -DPREFIX="/usr" -DDEF_RULES_DIR="/usr/share/spamassassin" -DLOCAL_RULES_DIR="/etc/mail/spamassassin" -DLOCAL_STATE_DIR="/var/lib/spamassassin" <lib/Mail/SpamAssassin/Util/DependencyInfo.pm >blib/lib/Mail/SpamAssassin/Util/DependencyInfo.pm
/usr/bin/perl build/preprocessor -Mconditional -Mvars -DVERSION="3.002003" -DPREFIX="/usr" -DDEF_RULES_DIR="/usr/share/spamassassin" -DLOCAL_RULES_DIR="/etc/mail/spamassassin" -DLOCAL_STATE_DIR="/var/lib/spamassassin" <lib/Mail/SpamAssassin/Plugin/Test.pm >blib/lib/Mail/SpamAssassin/Plugin/Test.pm
/usr/bin/perl build/preprocessor -Mconditional -Mvars -DVERSION="3.002003" -DPREFIX="/usr" -DDEF_RULES_DIR="/usr/share/spamassassin" -DLOCAL_RULES_DIR="/etc/mail/spamassassin" -DLOCAL_STATE_DIR="/var/lib/spamassassin" <lib/Mail/SpamAssassin/Util/TieOneStringHash.pm >blib/lib/Mail/SpamAssassin/Util/TieOneStringHash.pm
/usr/bin/perl build/preprocessor -Mconditional -Mvars -DVERSION="3.002003" -DPREFIX="/usr" -DDEF_RULES_DIR="/usr/share/spamassassin" -DLOCAL_RULES_DIR="/etc/mail/spamassassin" -DLOCAL_STATE_DIR="/var/lib/spamassassin" <lib/Mail/SpamAssassin/BayesStore/SDBM.pm >blib/lib/Mail/SpamAssassin/BayesStore/SDBM.pm
/usr/bin/perl build/preprocessor -Mconditional -Mvars -DVERSION="3.002003" -DPREFIX="/usr" -DDEF_RULES_DIR="/usr/share/spamassassin" -DLOCAL_RULES_DIR="/etc/mail/spamassassin" -DLOCAL_STATE_DIR="/var/lib/spamassassin" <lib/Mail/SpamAssassin/Dns.pm >blib/lib/Mail/SpamAssassin/Dns.pm
/usr/bin/perl build/preprocessor -Mconditional -Mvars -DVERSION="3.002003" -DPREFIX="/usr" -DDEF_RULES_DIR="/usr/share/spamassassin" -DLOCAL_RULES_DIR="/etc/mail/spamassassin" -DLOCAL_STATE_DIR="/var/lib/spamassassin" <lib/Mail/SpamAssassin/Plugin/HeaderEval.pm >blib/lib/Mail/SpamAssassin/Plugin/HeaderEval.pm
/usr/bin/perl build/preprocessor -Mconditional -Mvars -DVERSION="3.002003" -DPREFIX="/usr" -DDEF_RULES_DIR="/usr/share/spamassassin" -DLOCAL_RULES_DIR="/etc/mail/spamassassin" -DLOCAL_STATE_DIR="/var/lib/spamassassin" <lib/Mail/SpamAssassin/Message/Metadata.pm >blib/lib/Mail/SpamAssassin/Message/Metadata.pm
/usr/bin/perl build/preprocessor -Mconditional -Mvars -DVERSION="3.002003" -DPREFIX="/usr" -DDEF_RULES_DIR="/usr/share/spamassassin" -DLOCAL_RULES_DIR="/etc/mail/spamassassin" -DLOCAL_STATE_DIR="/var/lib/spamassassin" <lib/Mail/SpamAssassin/Plugin/AccessDB.pm >blib/lib/Mail/SpamAssassin/Plugin/AccessDB.pm
/usr/bin/perl build/preprocessor -Mconditional -Mvars -DVERSION="3.002003" -DPREFIX="/usr" -DDEF_RULES_DIR="/usr/share/spamassassin" -DLOCAL_RULES_DIR="/etc/mail/spamassassin" -DLOCAL_STATE_DIR="/var/lib/spamassassin" <lib/Mail/SpamAssassin/Bayes/CombineNaiveBayes.pm >blib/lib/Mail/SpamAssassin/Bayes/CombineNaiveBayes.pm
/usr/bin/perl build/preprocessor -Mconditional -Mvars -DVERSION="3.002003" -DPREFIX="/usr" -DDEF_RULES_DIR="/usr/share/spamassassin" -DLOCAL_RULES_DIR="/etc/mail/spamassassin" -DLOCAL_STATE_DIR="/var/lib/spamassassin" <lib/Mail/SpamAssassin/Locker.pm >blib/lib/Mail/SpamAssassin/Locker.pm
/usr/bin/perl build/preprocessor -Mconditional -Mvars -DVERSION="3.002003" -DPREFIX="/usr" -DDEF_RULES_DIR="/usr/share/spamassassin" -DLOCAL_RULES_DIR="/etc/mail/spamassassin" -DLOCAL_STATE_DIR="/var/lib/spamassassin" <lib/Mail/SpamAssassin/Message/Node.pm >blib/lib/Mail/SpamAssassin/Message/Node.pm
/usr/bin/perl build/preprocessor -Mconditional -Mvars -DVERSION="3.002003" -DPREFIX="/usr" -DDEF_RULES_DIR="/usr/share/spamassassin" -DLOCAL_RULES_DIR="/etc/mail/spamassassin" -DLOCAL_STATE_DIR="/var/lib/spamassassin" <lib/Mail/SpamAssassin/PluginHandler.pm >blib/lib/Mail/SpamAssassin/PluginHandler.pm
/usr/bin/perl build/preprocessor -Mconditional -Mvars -DVERSION="3.002003" -DPREFIX="/usr" -DDEF_RULES_DIR="/usr/share/spamassassin" -DLOCAL_RULES_DIR="/etc/mail/spamassassin" -DLOCAL_STATE_DIR="/var/lib/spamassassin" <lib/Mail/SpamAssassin/ArchiveIterator.pm >blib/lib/Mail/SpamAssassin/ArchiveIterator.pm
/usr/bin/perl build/preprocessor -Mconditional -Mvars -DVERSION="3.002003" -DPREFIX="/usr" -DDEF_RULES_DIR="/usr/share/spamassassin" -DLOCAL_RULES_DIR="/etc/mail/spamassassin" -DLOCAL_STATE_DIR="/var/lib/spamassassin" <lib/Mail/SpamAssassin/Conf/Parser.pm >blib/lib/Mail/SpamAssassin/Conf/Parser.pm
/usr/bin/perl build/preprocessor -Mconditional -Mvars -DVERSION="3.002003" -DPREFIX="/usr" -DDEF_RULES_DIR="/usr/share/spamassassin" -DLOCAL_RULES_DIR="/etc/mail/spamassassin" -DLOCAL_STATE_DIR="/var/lib/spamassassin" <lib/Mail/SpamAssassin/Plugin/Razor2.pm >blib/lib/Mail/SpamAssassin/Plugin/Razor2.pm
/usr/bin/perl build/preprocessor -Mconditional -Mvars -DVERSION="3.002003" -DPREFIX="/usr" -DDEF_RULES_DIR="/usr/share/spamassassin" -DLOCAL_RULES_DIR="/etc/mail/spamassassin" -DLOCAL_STATE_DIR="/var/lib/spamassassin" <lib/Mail/SpamAssassin/Plugin/VBounce.pm >blib/lib/Mail/SpamAssassin/Plugin/VBounce.pm
cp lib/spamassassin-run.pod blib/lib/spamassassin-run.pod
/usr/bin/perl build/preprocessor -Mconditional -Mvars -DVERSION="3.002003" -DPREFIX="/usr" -DDEF_RULES_DIR="/usr/share/spamassassin" -DLOCAL_RULES_DIR="/etc/mail/spamassassin" -DLOCAL_STATE_DIR="/var/lib/spamassassin" <lib/Mail/SpamAssassin/Plugin/DKIM.pm >blib/lib/Mail/SpamAssassin/Plugin/DKIM.pm
/usr/bin/perl build/preprocessor -Mconditional -Mvars -DVERSION="3.002003" -DPREFIX="/usr" -DDEF_RULES_DIR="/usr/share/spamassassin" -DLOCAL_RULES_DIR="/etc/mail/spamassassin" -DLOCAL_STATE_DIR="/var/lib/spamassassin" <lib/Mail/SpamAssassin/Reporter.pm >blib/lib/Mail/SpamAssassin/Reporter.pm
/usr/bin/perl build/preprocessor -Mconditional -Mvars -DVERSION="3.002003" -DPREFIX="/usr" -DDEF_RULES_DIR="/usr/share/spamassassin" -DLOCAL_RULES_DIR="/etc/mail/spamassassin" -DLOCAL_STATE_DIR="/var/lib/spamassassin" <lib/Mail/SpamAssassin/Plugin/OneLineBodyRuleType.pm >blib/lib/Mail/SpamAssassin/Plugin/OneLineBodyRuleType.pm
/usr/bin/perl build/preprocessor -Mconditional -Mvars -DVERSION="3.002003" -DPREFIX="/usr" -DDEF_RULES_DIR="/usr/share/spamassassin" -DLOCAL_RULES_DIR="/etc/mail/spamassassin" -DLOCAL_STATE_DIR="/var/lib/spamassassin" <lib/Mail/SpamAssassin/Locales.pm >blib/lib/Mail/SpamAssassin/Locales.pm
/usr/bin/perl build/preprocessor -Mconditional -Mvars -DVERSION="3.002003" -DPREFIX="/usr" -DDEF_RULES_DIR="/usr/share/spamassassin" -DLOCAL_RULES_DIR="/etc/mail/spamassassin" -DLOCAL_STATE_DIR="/var/lib/spamassassin" <lib/Mail/SpamAssassin/Plugin/Rule2XSBody.pm >blib/lib/Mail/SpamAssassin/Plugin/Rule2XSBody.pm
/usr/bin/perl build/preprocessor -Mconditional -Mvars -DVERSION="3.002003" -DPREFIX="/usr" -DDEF_RULES_DIR="/usr/share/spamassassin" -DLOCAL_RULES_DIR="/etc/mail/spamassassin" -DLOCAL_STATE_DIR="/var/lib/spamassassin" <lib/Mail/SpamAssassin/Plugin/Check.pm >blib/lib/Mail/SpamAssassin/Plugin/Check.pm
/usr/bin/perl build/preprocessor -Mconditional -Mvars -DVERSION="3.002003" -DPREFIX="/usr" -DDEF_RULES_DIR="/usr/share/spamassassin" -DLOCAL_RULES_DIR="/etc/mail/spamassassin" -DLOCAL_STATE_DIR="/var/lib/spamassassin" <lib/Mail/SpamAssassin/Plugin/ImageInfo.pm >blib/lib/Mail/SpamAssassin/Plugin/ImageInfo.pm
/usr/bin/perl build/preprocessor -Mconditional -Mvars -DVERSION="3.002003" -DPREFIX="/usr" -DDEF_RULES_DIR="/usr/share/spamassassin" -DLOCAL_RULES_DIR="/etc/mail/spamassassin" -DLOCAL_STATE_DIR="/var/lib/spamassassin" <lib/Mail/SpamAssassin/Plugin/BodyRuleBaseExtractor.pm >blib/lib/Mail/SpamAssassin/Plugin/BodyRuleBaseExtractor.pm
/usr/bin/perl build/preprocessor -Mconditional -Mvars -DVERSION="3.002003" -DPREFIX="/usr" -DDEF_RULES_DIR="/usr/share/spamassassin" -DLOCAL_RULES_DIR="/etc/mail/spamassassin" -DLOCAL_STATE_DIR="/var/lib/spamassassin" <lib/Mail/SpamAssassin/Bayes.pm >blib/lib/Mail/SpamAssassin/Bayes.pm
/usr/bin/perl build/preprocessor -Mconditional -Mvars -DVERSION="3.002003" -DPREFIX="/usr" -DDEF_RULES_DIR="/usr/share/spamassassin" -DLOCAL_RULES_DIR="/etc/mail/spamassassin" -DLOCAL_STATE_DIR="/var/lib/spamassassin" <lib/Mail/SpamAssassin/DBBasedAddrList.pm >blib/lib/Mail/SpamAssassin/DBBasedAddrList.pm
/usr/bin/perl build/preprocessor -Mconditional -Mvars -DVERSION="3.002003" -DPREFIX="/usr" -DDEF_RULES_DIR="/usr/share/spamassassin" -DLOCAL_RULES_DIR="/etc/mail/spamassassin" -DLOCAL_STATE_DIR="/var/lib/spamassassin" <lib/Mail/SpamAssassin/Plugin/WhiteListSubject.pm >blib/lib/Mail/SpamAssassin/Plugin/WhiteListSubject.pm
/usr/bin/perl build/preprocessor -Mconditional -Mvars -DVERSION="3.002003" -DPREFIX="/usr" -DDEF_RULES_DIR="/usr/share/spamassassin" -DLOCAL_RULES_DIR="/etc/mail/spamassassin" -DLOCAL_STATE_DIR="/var/lib/spamassassin" <lib/Mail/SpamAssassin/NetSet.pm >blib/lib/Mail/SpamAssassin/NetSet.pm
/usr/bin/perl build/preprocessor -Mconditional -Mvars -DVERSION="3.002003" -DPREFIX="/usr" -DDEF_RULES_DIR="/usr/share/spamassassin" -DLOCAL_RULES_DIR="/etc/mail/spamassassin" -DLOCAL_STATE_DIR="/var/lib/spamassassin" <lib/Mail/SpamAssassin/Plugin/AWL.pm >blib/lib/Mail/SpamAssassin/Plugin/AWL.pm
/usr/bin/perl build/preprocessor -Mconditional -Mvars -DVERSION="3.002003" -DPREFIX="/usr" -DDEF_RULES_DIR="/usr/share/spamassassin" -DLOCAL_RULES_DIR="/etc/mail/spamassassin" -DLOCAL_STATE_DIR="/var/lib/spamassassin" <lib/Mail/SpamAssassin/Plugin/HTMLEval.pm >blib/lib/Mail/SpamAssassin/Plugin/HTMLEval.pm
/usr/bin/perl build/preprocessor -Mconditional -Mvars -DVERSION="3.002003" -DPREFIX="/usr" -DDEF_RULES_DIR="/usr/share/spamassassin" -DLOCAL_RULES_DIR="/etc/mail/spamassassin" -DLOCAL_STATE_DIR="/var/lib/spamassassin" <lib/Mail/SpamAssassin/Logger.pm >blib/lib/Mail/SpamAssassin/Logger.pm
/usr/bin/perl build/preprocessor -Mconditional -Mvars -DVERSION="3.002003" -DPREFIX="/usr" -DDEF_RULES_DIR="/usr/share/spamassassin" -DLOCAL_RULES_DIR="/etc/mail/spamassassin" -DLOCAL_STATE_DIR="/var/lib/spamassassin" <lib/Mail/SpamAssassin/Plugin/Hashcash.pm >blib/lib/Mail/SpamAssassin/Plugin/Hashcash.pm
/usr/bin/perl build/preprocessor -Mconditional -Mvars -DVERSION="3.002003" -DPREFIX="/usr" -DDEF_RULES_DIR="/usr/share/spamassassin" -DLOCAL_RULES_DIR="/etc/mail/spamassassin" -DLOCAL_STATE_DIR="/var/lib/spamassassin" <lib/Mail/SpamAssassin/Plugin.pm >blib/lib/Mail/SpamAssassin/Plugin.pm
/usr/bin/perl build/preprocessor -Mconditional -Mvars -DVERSION="3.002003" -DPREFIX="/usr" -DDEF_RULES_DIR="/usr/share/spamassassin" -DLOCAL_RULES_DIR="/etc/mail/spamassassin" -DLOCAL_STATE_DIR="/var/lib/spamassassin" <lib/Mail/SpamAssassin/BayesStore/SQL.pm >blib/lib/Mail/SpamAssassin/BayesStore/SQL.pm
/usr/bin/perl build/preprocessor -Mconditional -Mvars -DVERSION="3.002003" -DPREFIX="/usr" -DDEF_RULES_DIR="/usr/share/spamassassin" -DLOCAL_RULES_DIR="/etc/mail/spamassassin" -DLOCAL_STATE_DIR="/var/lib/spamassassin" <lib/Mail/SpamAssassin.pm >blib/lib/Mail/SpamAssassin.pm
/usr/bin/perl build/preprocessor -Mconditional -Mvars -DVERSION="3.002003" -DPREFIX="/usr" -DDEF_RULES_DIR="/usr/share/spamassassin" -DLOCAL_RULES_DIR="/etc/mail/spamassassin" -DLOCAL_STATE_DIR="/var/lib/spamassassin" <lib/Mail/SpamAssassin/Locker/Flock.pm >blib/lib/Mail/SpamAssassin/Locker/Flock.pm
/usr/bin/perl build/preprocessor -Mconditional -Mvars -DVERSION="3.002003" -DPREFIX="/usr" -DDEF_RULES_DIR="/usr/share/spamassassin" -DLOCAL_RULES_DIR="/etc/mail/spamassassin" -DLOCAL_STATE_DIR="/var/lib/spamassassin" <lib/Mail/SpamAssassin/Logger/Syslog.pm >blib/lib/Mail/SpamAssassin/Logger/Syslog.pm
/usr/bin/perl build/preprocessor -Mconditional -Mvars -DVERSION="3.002003" -DPREFIX="/usr" -DDEF_RULES_DIR="/usr/share/spamassassin" -DLOCAL_RULES_DIR="/etc/mail/spamassassin" -DLOCAL_STATE_DIR="/var/lib/spamassassin" <lib/Mail/SpamAssassin/Plugin/SPF.pm >blib/lib/Mail/SpamAssassin/Plugin/SPF.pm
/usr/bin/perl build/preprocessor -Mconditional -Mvars -DVERSION="3.002003" -DPREFIX="/usr" -DDEF_RULES_DIR="/usr/share/spamassassin" -DLOCAL_RULES_DIR="/etc/mail/spamassassin" -DLOCAL_STATE_DIR="/var/lib/spamassassin" <lib/Mail/SpamAssassin/Plugin/Shortcircuit.pm >blib/lib/Mail/SpamAssassin/Plugin/Shortcircuit.pm
/usr/bin/perl build/preprocessor -Mconditional -Mvars -DVERSION="3.002003" -DPREFIX="/usr" -DDEF_RULES_DIR="/usr/share/spamassassin" -DLOCAL_RULES_DIR="/etc/mail/spamassassin" -DLOCAL_STATE_DIR="/var/lib/spamassassin" <lib/Mail/SpamAssassin/Client.pm >blib/lib/Mail/SpamAssassin/Client.pm
/usr/bin/perl build/preprocessor -Mconditional -Mvars -DVERSION="3.002003" -DPREFIX="/usr" -DDEF_RULES_DIR="/usr/share/spamassassin" -DLOCAL_RULES_DIR="/etc/mail/spamassassin" -DLOCAL_STATE_DIR="/var/lib/spamassassin" <lib/Mail/SpamAssassin/PerMsgStatus.pm >blib/lib/Mail/SpamAssassin/PerMsgStatus.pm
/usr/bin/perl build/preprocessor -Mconditional -Mvars -DVERSION="3.002003" -DPREFIX="/usr" -DDEF_RULES_DIR="/usr/share/spamassassin" -DLOCAL_RULES_DIR="/etc/mail/spamassassin" -DLOCAL_STATE_DIR="/var/lib/spamassassin" <lib/Mail/SpamAssassin/Plugin/URIDetail.pm >blib/lib/Mail/SpamAssassin/Plugin/URIDetail.pm
/usr/bin/perl build/preprocessor -Mconditional -Mvars -DVERSION="3.002003" -DPREFIX="/usr" -DDEF_RULES_DIR="/usr/share/spamassassin" -DLOCAL_RULES_DIR="/etc/mail/spamassassin" -DLOCAL_STATE_DIR="/var/lib/spamassassin" <lib/Mail/SpamAssassin/PerMsgLearner.pm >blib/lib/Mail/SpamAssassin/PerMsgLearner.pm
/usr/bin/perl build/preprocessor -Mconditional -Mvars -DVERSION="3.002003" -DPREFIX="/usr" -DDEF_RULES_DIR="/usr/share/spamassassin" -DLOCAL_RULES_DIR="/etc/mail/spamassassin" -DLOCAL_STATE_DIR="/var/lib/spamassassin" <lib/Mail/SpamAssassin/Plugin/WLBLEval.pm >blib/lib/Mail/SpamAssassin/Plugin/WLBLEval.pm
/usr/bin/perl build/preprocessor -Mconditional -Mvars -DVERSION="3.002003" -DPREFIX="/usr" -DDEF_RULES_DIR="/usr/share/spamassassin" -DLOCAL_RULES_DIR="/etc/mail/spamassassin" -DLOCAL_STATE_DIR="/var/lib/spamassassin" <lib/Mail/SpamAssassin/SQLBasedAddrList.pm >blib/lib/Mail/SpamAssassin/SQLBasedAddrList.pm
/usr/bin/perl build/preprocessor -Mconditional -Mvars -DVERSION="3.002003" -DPREFIX="/usr" -DDEF_RULES_DIR="/usr/share/spamassassin" -DLOCAL_RULES_DIR="/etc/mail/spamassassin" -DLOCAL_STATE_DIR="/var/lib/spamassassin" <lib/Mail/SpamAssassin/Plugin/AutoLearnThreshold.pm >blib/lib/Mail/SpamAssassin/Plugin/AutoLearnThreshold.pm
/usr/bin/perl build/preprocessor -Mconditional -Mvars -DVERSION="3.002003" -DPREFIX="/usr" -DDEF_RULES_DIR="/usr/share/spamassassin" -DLOCAL_RULES_DIR="/etc/mail/spamassassin" -DLOCAL_STATE_DIR="/var/lib/spamassassin" <lib/Mail/SpamAssassin/Plugin/TextCat.pm >blib/lib/Mail/SpamAssassin/Plugin/TextCat.pm
/usr/bin/perl build/preprocessor -Mconditional -Mvars -DVERSION="3.002003" -DPREFIX="/usr" -DDEF_RULES_DIR="/usr/share/spamassassin" -DLOCAL_RULES_DIR="/etc/mail/spamassassin" -DLOCAL_STATE_DIR="/var/lib/spamassassin" <lib/Mail/SpamAssassin/PersistentAddrList.pm >blib/lib/Mail/SpamAssassin/PersistentAddrList.pm
/usr/bin/perl build/preprocessor -Mconditional -Mvars -DVERSION="3.002003" -DPREFIX="/usr" -DDEF_RULES_DIR="/usr/share/spamassassin" -DLOCAL_RULES_DIR="/etc/mail/spamassassin" -DLOCAL_STATE_DIR="/var/lib/spamassassin" <lib/Mail/SpamAssassin/Locker/UnixNFSSafe.pm >blib/lib/Mail/SpamAssassin/Locker/UnixNFSSafe.pm
/usr/bin/perl build/preprocessor -Mconditional -Mvars -DVERSION="3.002003" -DPREFIX="/usr" -DDEF_RULES_DIR="/usr/share/spamassassin" -DLOCAL_RULES_DIR="/etc/mail/spamassassin" -DLOCAL_STATE_DIR="/var/lib/spamassassin" <lib/Mail/SpamAssassin/DnsResolver.pm >blib/lib/Mail/SpamAssassin/DnsResolver.pm
/usr/bin/perl build/preprocessor -Mconditional -Mvars -DVERSION="3.002003" -DPREFIX="/usr" -DDEF_RULES_DIR="/usr/share/spamassassin" -DLOCAL_RULES_DIR="/etc/mail/spamassassin" -DLOCAL_STATE_DIR="/var/lib/spamassassin" <lib/Mail/SpamAssassin/SubProcBackChannel.pm >blib/lib/Mail/SpamAssassin/SubProcBackChannel.pm
/usr/bin/perl build/preprocessor -Mconditional -Mvars -DVERSION="3.002003" -DPREFIX="/usr" -DDEF_RULES_DIR="/usr/share/spamassassin" -DLOCAL_RULES_DIR="/etc/mail/spamassassin" -DLOCAL_STATE_DIR="/var/lib/spamassassin" <lib/Mail/SpamAssassin/Bayes/CombineChi.pm >blib/lib/Mail/SpamAssassin/Bayes/CombineChi.pm
/usr/bin/perl build/preprocessor -Mconditional -Mvars -DVERSION="3.002003" -DPREFIX="/usr" -DDEF_RULES_DIR="/usr/share/spamassassin" -DLOCAL_RULES_DIR="/etc/mail/spamassassin" -DLOCAL_STATE_DIR="/var/lib/spamassassin" <lib/Mail/SpamAssassin/Locker/Win32.pm >blib/lib/Mail/SpamAssassin/Locker/Win32.pm
/usr/bin/perl build/preprocessor -Mconditional -Mvars -DVERSION="3.002003" -DPREFIX="/usr" -DDEF_RULES_DIR="/usr/share/spamassassin" -DLOCAL_RULES_DIR="/etc/mail/spamassassin" -DLOCAL_STATE_DIR="/var/lib/spamassassin" <lib/Mail/SpamAssassin/Plugin/RelayCountry.pm >blib/lib/Mail/SpamAssassin/Plugin/RelayCountry.pm
/usr/bin/perl build/preprocessor -Mconditional -Mvars -DVERSION="3.002003" -DPREFIX="/usr" -DDEF_RULES_DIR="/usr/share/spamassassin" -DLOCAL_RULES_DIR="/etc/mail/spamassassin" -DLOCAL_STATE_DIR="/var/lib/spamassassin" <lib/Mail/SpamAssassin/Util/RegistrarBoundaries.pm >blib/lib/Mail/SpamAssassin/Util/RegistrarBoundaries.pm
/usr/bin/perl build/preprocessor -Mvars -DVERSION="3.002003" -DPREFIX="/usr" -DDEF_RULES_DIR="/usr/share/spamassassin" -DLOCAL_RULES_DIR="/etc/mail/spamassassin"

zdyldy 回复于:2007-10-25 15:14:36

-DLOCAL_STATE_DIR="/var/lib/spamassassin" -DINSTALLSITELIB="/usr/lib/perl5/site_perl/5.8.8" -DCONTACT_ADDRESS="the administrator of that system" -Msharpbang -Mconditional -DPERL_BIN="/usr/bin/perl" -DPERL_WARN="" -DPERL_TAINT="" -m755 -isa-compile.raw -osa-compile
cp sa-compile blib/script/sa-compile
/usr/bin/perl "-MExtUtils::MY" -e "MY->fixin(shift)" blib/script/sa-compile
/usr/bin/perl spamc/configure.pl --prefix="/usr" --sysconfdir="/etc/mail/spamassassin" --datadir="/usr/share/spamassassin" --enable-ssl="no"
cd spamc
/usr/bin/perl version.h.pl
version.h.pl: creating version.h
./configure --prefix=/usr --sysconfdir=/etc/mail/spamassassin --datadir=/usr/share/spamassassin --enable-ssl=no
checking for gcc... gcc
checking for C compiler default output file name... a.out
checking whether the C compiler works... yes
checking whether we are cross compiling... no
checking for suffix of executables...
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether gcc accepts -g... yes
checking for gcc option to accept ANSI C... none needed
checking how to run the C preprocessor... gcc -E
checking for egrep... grep -E
checking for ANSI C header files... yes
checking for sys/types.h... yes
checking for sys/stat.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for memory.h... yes
checking for strings.h... yes
checking for inttypes.h... yes
checking for stdint.h... yes
checking for unistd.h... yes
checking sys/time.h usability... yes
checking sys/time.h presence... yes
checking for sys/time.h... yes
checking syslog.h usability... yes
checking syslog.h presence... yes
checking for syslog.h... yes
checking for unistd.h... (cached) yes
checking errno.h usability... yes
checking errno.h presence... yes
checking for errno.h... yes
checking sys/errno.h usability... yes
checking sys/errno.h presence... yes
checking for sys/errno.h... yes
checking time.h usability... yes
checking time.h presence... yes
checking for time.h... yes
checking sysexits.h usability... yes
checking sysexits.h presence... yes
checking for sysexits.h... yes
checking sys/socket.h usability... yes
checking sys/socket.h presence... yes
checking for sys/socket.h... yes
checking netdb.h usability... yes
checking netdb.h presence... yes
checking for netdb.h... yes
checking netinet/in.h usability... yes
checking netinet/in.h presence... yes
checking for netinet/in.h... yes
checking pwd.h usability... yes
checking pwd.h presence... yes
checking for pwd.h... yes
checking signal.h usability... yes
checking signal.h presence... yes
checking for signal.h... yes
checking openssl/crypto.h usability... yes
checking openssl/crypto.h presence... yes
checking for openssl/crypto.h... yes
checking zlib.h usability... yes
checking zlib.h presence... yes
checking for zlib.h... yes
checking for an ANSI C-conforming const... yes
checking for off_t... yes
checking for pid_t... yes
checking for uid_t in sys/types.h... yes
checking for size_t... yes
checking for SHUT_RD... yes
checking for socket in -lsocket... no
checking for connect in -linet... no
checking for t_accept in -lnsl... no
checking for deflate in -lz... yes
checking for dlopen in -ldl... yes
checking for socket... yes
checking for strdup... yes
checking for strtod... yes
checking for strtol... yes
checking for snprintf... yes
checking for shutdown... yes
checking for h_errno... yes
checking for in_addr_t... yes
checking for INADDR_NONE... yes
checking for EX__MAX... yes
checking for EAI_ADDRFAMILY... yes
checking for EAI_SYSTEM... (cached) yes
checking for EAI_NODATA... (cached) yes
configure: creating ./config.status
config.status: creating Makefile
config.status: creating spamc.h
config.status: creating config.h
make -f spamc/Makefile spamc/spamc
make[1]: Entering directory `/zuixin/Mail-SpamAssassin-3.2.3'
gcc -g -O2 spamc/spamc.c spamc/getopt.c spamc/libspamc.c spamc/utils.c \
-o spamc/spamc -ldl -lz
make[1]: Leaving directory `/zuixin/Mail-SpamAssassin-3.2.3'
cp spamc/spamc blib/script/spamc
/usr/bin/perl "-MExtUtils::MY" -e "MY->fixin(shift)" blib/script/spamc
/usr/bin/perl build/preprocessor -Mvars -DVERSION="3.002003" -DPREFIX="/usr" -DDEF_RULES_DIR="/usr/share/spamassassin" -DLOCAL_RULES_DIR="/etc/mail/spamassassin" -DLOCAL_STATE_DIR="/var/lib/spamassassin" -DINSTALLSITELIB="/usr/lib/perl5/site_perl/5.8.8" -DCONTACT_ADDRESS="the administrator of that system" -Msharpbang -Mconditional -DPERL_BIN="/usr/bin/perl" -DPERL_WARN="" -DPERL_TAINT="" -m755 -isa-learn.raw -osa-learn
cp sa-learn blib/script/sa-learn
/usr/bin/perl "-MExtUtils::MY" -e "MY->fixin(shift)" blib/script/sa-learn
/usr/bin/perl build/preprocessor -Mvars -DVERSION="3.002003" -DPREFIX="/usr" -DDEF_RULES_DIR="/usr/share/spamassassin" -DLOCAL_RULES_DIR="/etc/mail/spamassassin" -DLOCAL_STATE_DIR="/var/lib/spamassassin" -DINSTALLSITELIB="/usr/lib/perl5/site_perl/5.8.8" -DCONTACT_ADDRESS="the administrator of that system" -Msharpbang -Mconditional -DPERL_BIN="/usr/bin/perl" -DPERL_WARN="" -DPERL_TAINT="" -m755 -ispamassassin.raw -ospamassassin
cp spamassassin blib/script/spamassassin
/usr/bin/perl "-MExtUtils::MY" -e "MY->fixin(shift)" blib/script/spamassassin
/usr/bin/perl build/preprocessor -Mvars -DVERSION="3.002003" -DPREFIX="/usr" -DDEF_RULES_DIR="/usr/share/spamassassin" -DLOCAL_RULES_DIR="/etc/mail/spamassassin" -DLOCAL_STATE_DIR="/var/lib/spamassassin" -DINSTALLSITELIB="/usr/lib/perl5/site_perl/5.8.8" -DCONTACT_ADDRESS="the administrator of that system" -Msharpbang -Mconditional -DPERL_BIN="/usr/bin/perl" -DPERL_WARN="" -DPERL_TAINT="" -m755 -ispamd/spamd.raw -ospamd/spamd
cp spamd/spamd blib/script/spamd
/usr/bin/perl "-MExtUtils::MY" -e "MY->fixin(shift)" blib/script/spamd
/usr/bin/perl build/mkrules --exit_on_no_src --src rulesrc --out rules --manifest MANIFEST --manifestskip MANIFEST.SKIP
no source directory found: exiting
/usr/bin/perl build/preprocessor -Mvars -DVERSION="3.002003" -DPREFIX="/usr" -DDEF_RULES_DIR="/usr/share/spamassassin" -DLOCAL_RULES_DIR="/etc/mail/spamassassin" -DLOCAL_STATE_DIR="/var/lib/spamassassin" -DINSTALLSITELIB="/usr/lib/perl5/site_perl/5.8.8" -DCONTACT_ADDRESS="the administrator of that system" -Msharpbang -Mconditional -DPERL_BIN="/usr/bin/perl" -DPERL_WARN="" -DPERL_TAINT="" -m755 -isa-update.raw -osa-update
cp sa-update blib/script/sa-update
/usr/bin/perl "-MExtUtils::MY" -e "MY->fixin(shift)" blib/script/sa-update
Manifying blib/man1/sa-compile.1
Manifying blib/man1/spamassassin-run.1
Manifying blib/man1/sa-learn.1
Manifying blib/man1/spamassassin.1
Manifying blib/man1/spamd.1
Manifying blib/man1/spamc.1
Manifying blib/man1/sa-update.1
Manifying blib/man3/Mail::SpamAssassin::Logger::File.3pm
Manifying blib/man3/Mail::SpamAssassin::AutoWhitelist.3pm
Manifying blib/man3/Mail::SpamAssassin::Message::Metadata.3pm
Manifying blib/man3/Mail::SpamAssassin::Plugin::AccessDB.3pm
Manifying blib/man3/Mail::SpamAssassin::Plugin::Pyzor.3pm
Manifying blib/man3/Mail::SpamAssassin::BayesStore.3pm
Manifying blib/man3/Mail::SpamAssassin::Message::Node.3pm
Manifying blib/man3/Mail::SpamAssassin::PluginHandler.3pm
Manifying blib/man3/Mail::SpamAssassin::Util.3pm
Manifying blib/man3/Mail::SpamAssassin::Conf.3pm
Manifying blib/man3/Mail::SpamAssassin::Message.3pm
Manifying blib/man3/Mail::SpamAssassin::Logger::Stderr.3pm
Manifying blib/man3/Mail::SpamAssassin::ArchiveIterator.3pm
Manifying blib/man3/Mail::SpamAssassin::Plugin::Razor2.3pm
Manifying blib/man3/Mail::SpamAssassin::Conf::Parser.3pm
Manifying blib/man3/Mail::SpamAssassin::AsyncLoop.3pm
Manifying blib/man3/Mail::SpamAssassin::Plugin::VBounce.3pm
Manifying blib/man3/spamassassin-run.3pm
Manifying blib/man3/Mail::SpamAssassin::Plugin::DKIM.3pm
Manifying blib/man3/Mail::SpamAssassin::BayesStore::MySQL.3pm
Manifying blib/man3/Mail::SpamAssassin::Conf::LDAP.3pm
Manifying blib/man3/Mail::SpamAssassin::Plugin::OneLineBodyRuleType.3pm
Manifying blib/man3/Mail::SpamAssassin::Plugin::Rule2XSBody.3pm
Manifying blib/man3/Mail::SpamAssassin::Plugin::Check.3pm
Manifying blib/man3/Mail::SpamAssassin::Plugin::DCC.3pm
Manifying blib/man3/Mail::SpamAssassin::Plugin::BodyRuleBaseExtractor.3pm
Manifying blib/man3/Mail::SpamAssassin::Plugin::SpamCop.3pm
Manifying blib/man3/Mail::SpamAssassin::Bayes.3pm
Manifying blib/man3/Mail::SpamAssassin::Plugin::WhiteListSubject.3pm
Manifying blib/man3/Mail::SpamAssassin::Plugin::DomainKeys.3pm
Manifying blib/man3/Mail::SpamAssassin::Plugin::AWL.3pm
Manifying blib/man3/Mail::SpamAssassin::Logger.3pm
Manifying blib/man3/Mail::SpamAssassin::Plugin::AntiVirus.3pm
Manifying blib/man3/Mail::SpamAssassin::Plugin.3pm
Manifying blib/man3/Mail::SpamAssassin::Plugin::Hashcash.3pm
Manifying blib/man3/Mail::SpamAssassin::Plugin::ReplaceTags.3pm
Manifying blib/man3/Mail::SpamAssassin::Plugin::MIMEHeader.3pm
Manifying blib/man3/Mail::SpamAssassin.3pm
Manifying blib/man3/Mail::SpamAssassin::BayesStore::SQL.3pm
Manifying blib/man3/Mail::SpamAssassin::Logger::Syslog.3pm
Manifying blib/man3/Mail::SpamAssassin::Plugin::SPF.3pm
Manifying blib/man3/Mail::SpamAssassin::Plugin::Shortcircuit.3pm
Manifying blib/man3/Mail::SpamAssassin::Timeout.3pm
Manifying blib/man3/Mail::SpamAssassin::Conf::SQL.3pm
Manifying blib/man3/Mail::SpamAssassin::Plugin::ASN.3pm
Manifying blib/man3/Mail::SpamAssassin::PerMsgStatus.3pm
Manifying blib/man3/Mail::SpamAssassin::Client.3pm
Manifying blib/man3/Mail::SpamAssassin::Util::Progress.3pm
Manifying blib/man3/Mail::SpamAssassin::Plugin::URIDetail.3pm
Manifying blib/man3/Mail::SpamAssassin::PerMsgLearner.3pm
Manifying blib/man3/Mail::SpamAssassin::AICache.3pm
Manifying blib/man3/Mail::SpamAssassin::Plugin::AutoLearnThreshold.3pm
Manifying blib/man3/Mail::SpamAssassin::SQLBasedAddrList.3pm
Manifying blib/man3/Mail::SpamAssassin::Plugin::TextCat.3pm
Manifying blib/man3/Mail::SpamAssassin::Plugin::URIDNSBL.3pm
Manifying blib/man3/Mail::SpamAssassin::BayesStore::PgSQL.3pm
Manifying blib/man3/Mail::SpamAssassin::PersistentAddrList.3pm
Manifying blib/man3/Mail::SpamAssassin::Plugin::Test.3pm
Manifying blib/man3/Mail::SpamAssassin::DnsResolver.3pm
Manifying blib/man3/Mail::SpamAssassin::SubProcBackChannel.3pm
Manifying blib/man3/Mail::SpamAssassin::Plugin::RelayCountry.3pm
[root@mail Mail-SpamAssassin-3.2.3]# make check
make: *** 没有规则可以创建目标“check”。 停止。
[root@mail Mail-SpamAssassin-3.2.3]# make install
/usr/bin/perl build/mkrules --exit_on_no_src --src rulesrc --out rules --manifest MANIFEST --manifestskip MANIFEST.SKIP
no source directory found: exiting
/usr/bin/perl build/preprocessor -Mvars -DVERSION="3.002003" -DPREFIX="/usr" -DDEF_RULES_DIR="/usr/share/spamassassin" -DLOCAL_RULES_DIR="/etc/mail/spamassassin" -DLOCAL_STATE_DIR="/var/lib/spamassassin" -DINSTALLSITELIB="/usr/lib/perl5/site_perl/5.8.8" -DCONTACT_ADDRESS="the administrator of that system" -Msharpbang -Mconditional -DPERL_BIN="/usr/bin/perl" -DPERL_WARN="" -DPERL_TAINT="" -m755 -isa-update.raw -osa-update
cp sa-update blib/script/sa-update
/usr/bin/perl "-MExtUtils::MY" -e "MY->fixin(shift)" blib/script/sa-update
Manifying blib/man1/sa-update.1
Writing /usr/lib/perl5/site_perl/5.8.8/i386-linux-thread-multi/auto/Mail/SpamAssassin/.packlist
Appending installation info to /usr/lib/perl5/5.8.8/i386-linux-thread-multi/perllocal.pod
/usr/bin/perl "-MExtUtils::Command" -e mkpath /etc/mail/spamassassin
/usr/bin/perl -MFile::Copy -e "copy(q{rules/local.cf}, q{/etc/mail/spamassassin/local.cf}) unless -f q{/etc/mail/spamassassin/local.cf}"
/usr/bin/perl -MFile::Copy -e "copy(q{rules/init.pre}, q{/etc/mail/spamassassin/init.pre}) unless -f q{/etc/mail/spamassassin/init.pre}"
/usr/bin/perl -MFile::Copy -e "copy(q{rules/v310.pre}, q{/etc/mail/spamassassin/v310.pre}) unless -f q{/etc/mail/spamassassin/v310.pre}"
/usr/bin/perl -MFile::Copy -e "copy(q{rules/v312.pre}, q{/etc/mail/spamassassin/v312.pre}) unless -f q{/etc/mail/spamassassin/v312.pre}"
/usr/bin/perl -MFile::Copy -e "copy(q{rules/v320.pre}, q{/etc/mail/spamassassin/v320.pre}) unless -f q{/etc/mail/spamassassin/v320.pre}"
/usr/bin/perl "-MExtUtils::Command" -e mkpath /usr/share/spamassassin
/usr/bin/perl -e "map unlink, </usr/share/spamassassin/*>"
/usr/bin/perl build/preprocessor -Mvars -DVERSION="3.002003" -DPREFIX="/usr" -DDEF_RULES_DIR="/usr/share/spamassassin" -DLOCAL_RULES_DIR="/etc/mail/spamassassin" -DLOCAL_STATE_DIR="/var/lib/spamassassin" -DINSTALLSITELIB="/usr/lib/perl5/site_perl/5.8.8" -DCONTACT_ADDRESS="the administrator of that system" -m644 -Irules -O/usr/share/spamassassin 10_default_prefs.cf 20_advance_fee.cf 20_body_tests.cf 20_compensate.cf 20_dnsbl_tests.cf 20_drugs.cf 20_dynrdns.cf 20_fake_helo_tests.cf 20_head_tests.cf 20_html_tests.cf 20_imageinfo.cf 20_meta_tests.cf 20_net_tests.cf 20_phrases.cf 20_porn.cf 20_ratware.cf 20_uri_tests.cf 20_vbounce.cf 23_bayes.cf 25_accessdb.cf 25_antivirus.cf 25_asn.cf 25_dcc.cf 25_dkim.cf 25_domainkeys.cf 25_hashcash.cf 25_pyzor.cf 25_razor2.cf 25_replace.cf 25_spf.cf 25_textcat.cf 25_uribl.cf 30_text_de.cf 30_text_fr.cf 30_text_it.cf 30_text_nl.cf 30_text_pl.cf 30_text_pt_br.cf 50_scores.cf 60_awl.cf 60_shortcircuit.cf 60_whitelist.cf 60_whitelist_dk.cf 60_whitelist_dkim.cf 60_whitelist_spf.cf 60_whitelist_subject.cf 72_active.cf user_prefs.template languages sa-update-pubkey.txt
chmod 755 /usr/share/spamassassin
[root@mail Mail-SpamAssassin-3.2.3]#



太长了,我只能看到这么多 .

zdyldy 回复于:2007-10-25 15:25:21

#vi /etc/postifx/main.cf
在文末添加如下行:
content_filter=amavisfeed:[127.0.0.1]:10024

请确认一下,这行是否有错误,我加了这行之后,重起了postfix,可是发现10024端口没有起动.所以倒置,下面的 错误.



[root@mail amavisd-new-2.5.2]# telnet localhost 10024
Trying 127.0.0.1...
telnet: connect to address 127.0.0.1: Connection refused
telnet: Unable to connect to remote host: Connection refused
[root@mail amavisd-new-2.5.2]#

asia_ji 回复于:2007-10-26 08:28:26

marion兄弟,邮件服务器一切正常,但是无法给163发邮件,这是为什么?

zdyldy 回复于:2007-10-26 09:56:49

asia_ji
圣骑士




[引用] [报告] [回复] 顶部
250楼 发表于 2007-10-26 08:28
marion兄弟,邮件服务器一切正常,但是无法给163发邮件,这是为什么?



你安装spamassassin了么.我怎么安装不了阿.

make check时出错.错误在上面,可以帮我看一下么.

marion 回复于:2007-10-26 12:01:43

无法发指的是什么?拒收,还是“石沉大海”?

marion 回复于:2007-10-26 12:03:43

你的那个问题应该不算问题,接着往下进行吧。

asia_ji 回复于:2007-10-26 14:39:23

给163和126邮箱系统发邮件对方拒收,邮件被退回!

asia_ji 回复于:2007-10-26 15:17:18

tclrrd.c:582: warning: (near initialization for `rrdCmds[10]')
tclrrd.c:582: warning: initialization makes integer from pointer without a cast
tclrrd.c:582: error: `Tcl_CmdProc' undeclared here (not in a function)
tclrrd.c:582: error: syntax error before ')' token
tclrrd.c:582: warning: excess elements in scalar initializer
tclrrd.c:582: warning: (near initialization for `rrdCmds[10]')
tclrrd.c:582: warning: excess elements in scalar initializer
tclrrd.c:582: warning: (near initialization for `rrdCmds[10]')
tclrrd.c:583: error: ISO C forbids data definition with no type or storage class
tclrrd.c:588: error: syntax error before '*' token
tclrrd.c: In function `init':
tclrrd.c:590: error: `cmdInfoPtr' undeclared (first use in this function)
tclrrd.c:591: error: `Tcl_CmdInfo' undeclared (first use in this function)
tclrrd.c:591: error: syntax error before "info"
tclrrd.c:593: warning: implicit declaration of function `Tcl_InitStubs'
tclrrd.c:593: warning: nested extern declaration of `Tcl_InitStubs'
tclrrd.c:593: error: `interp' undeclared (first use in this function)
tclrrd.c:593: error: `TCL_VERSION' undeclared (first use in this function)
tclrrd.c:593: warning: comparison between pointer and integer
tclrrd.c:594: error: `TCL_ERROR' undeclared (first use in this function)
tclrrd.c:596: warning: implicit declaration of function `Tcl_PkgRequire'
tclrrd.c:596: warning: nested extern declaration of `Tcl_PkgRequire'
tclrrd.c:596: warning: comparison between pointer and integer
tclrrd.c:604: warning: implicit declaration of function `Tcl_SetVar2'
tclrrd.c:604: warning: nested extern declaration of `Tcl_SetVar2'
tclrrd.c:604: error: `TCL_GLOBAL_ONLY' undeclared (first use in this function)
tclrrd.c:612: warning: implicit declaration of function `Tcl_GetCommandInfo'
tclrrd.c:612: warning: nested extern declaration of `Tcl_GetCommandInfo'
tclrrd.c:612: error: `info' undeclared (first use in this function)
tclrrd.c:613: warning: nested extern declaration of `Tcl_AppendResult'
tclrrd.c:617: error: `safe' undeclared (first use in this function)
tclrrd.c:651: warning: implicit declaration of function `Tcl_CreateCommand'
tclrrd.c:651: warning: nested extern declaration of `Tcl_CreateCommand'
tclrrd.c:652: error: `ClientData' undeclared (first use in this function)
tclrrd.c:652: error: `Tcl_CmdDeleteProc' undeclared (first use in this function)
tclrrd.c:652: error: syntax error before ')' token
tclrrd.c:655: warning: implicit declaration of function `Tcl_PkgProvide'
tclrrd.c:655: warning: nested extern declaration of `Tcl_PkgProvide'
tclrrd.c:655: error: `TCL_OK' undeclared (first use in this function)
tclrrd.c: At top level:
tclrrd.c:663: error: syntax error before '*' token
tclrrd.c:664: warning: no previous prototype for 'Tclrrd_Init'
tclrrd.c: In function `Tclrrd_Init':
tclrrd.c:665: error: `interp' undeclared (first use in this function)
tclrrd.c: At top level:
tclrrd.c:674: error: syntax error before '*' token
tclrrd.c:675: warning: no previous prototype for 'Tclrrd_SafeInit'
tclrrd.c: In function `Tclrrd_SafeInit':
tclrrd.c:676: error: `interp' undeclared (first use in this function)
make[3]: *** [tclrrd.o] Error 1
make[3]: Leaving directory `/root/postfix/rrdtool-1.2.23/bindings/tcl'
make[2]: *** [all-recursive] Error 1
make[2]: Leaving directory `/root/postfix/rrdtool-1.2.23/bindings'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/root/postfix/rrdtool-1.2.23'
make: *** [all] Error 2

marion 回复于:2007-10-26 16:22:14

我的发信测试第一个就是对126和163的进行的,没有任何问题。

你把退信的信件内容发上来帮你分析一下……

marion 回复于:2007-10-26 16:24:29

引用:…………
tclrrd.c: In function `Tclrrd_SafeInit':
tclrrd.c:676: error: `interp' undeclared (first use in this function)
make[3]: *** [tclrrd.o] Error 1
make[3]: Leaving directory `/root/postfix/rrdtool-1.2.23/bindings/tcl'
make[2]: *** [all-recursive] Error 1
make[2]: Leaving directory `/root/postfix/rrdtool-1.2.23/bindings'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/root/postfix/rrdtool-1.2.23'
make: *** [all] Error 2……


你的应该是没有正确安装所需的tcl相关的软件包所致。简单的解决办法就是去发行光盘上找到相关的rpm包进行安装。

asia_ji 回复于:2007-10-27 08:52:16

标题: Undelivered Mail Returned to Sender 回复 | 转发 | 编码 | 删除 | <上一封 | 下一封> | 更多操作选项
来自: MAILER-DAEMON@mail.localdomain (Mail Delivery System) 将该来信人加到地址本中
发给: asia@dlfhw.cn
日期: Fri, 26 Oct 2007 13:43:07 +0800 (CST)
附件列表: delivery-status.txt (0.35K) 附件保存到网络磁盘
message.eml (0.54K) 附件保存到网络磁盘


This is the mail system at host mail.

I'm sorry to have to inform you that your message could not
be delivered to one or more recipients. It's attached below.

For further assistance, please send mail to postmaster.

If you do so, please include this problem report. You can
delete your own text from the attached returned message.

The mail system

<asia_ji@126.com>: mail for 126.com loops back to myself

asia_ji 回复于:2007-10-27 09:00:55

哈哈,果然是因为没有安装tcl-devel-8.4.7-2.i386.rpm 导致的make rrdtools失败的

asia_ji 回复于:2007-10-27 09:18:28

唉,我真是粗心大意,居然没有看到你帖子上面 “注意:安装以上软件所之前,请确保您的系统已经安装了tcl、tcl-devel、libart和libart-devel等相关的软件包;”这个提示。

junger 回复于:2007-10-27 10:31:53

这个问题我也遇到了,而且是在互联网上跑的postfix邮件服务器,
向126和163发邮件都不行,他会返回一个标题为Undelivered Mail Returned to Sender 的邮件,
但是他可以接收126和163的邮件,不知问题出在哪里?

asia_ji 回复于:2007-10-27 11:53:40

安装Mail::SPF::Query等时make test出现下列情况,该如何解决?

t/00_all....FAILED tests 9, 31, 39, 130, 133, 140, 143, 156, 159, 163, 166, 181, 184, 187, 190, 193, 196, 199, 202-203, 205-206, 208, 211, 214, 217, 220, 223
Failed 28/223 tests, 87.44% okay
Failed Test Stat Wstat Total Fail Failed List of Failed
-------------------------------------------------------------------------------
t/00_all.t 223 28 12.56% 9 31 39 130 133 140 143 156 159 163
166 181 184 187 190 193 196 199 202-
203 205-206 208 211 214 217 220 223
(1 subtest UNEXPECTEDLY SUCCEEDED).
Failed 1/1 test scripts, 0.00% okay. 28/223 subtests failed, 87.44% okay.
make: *** [test_dynamic] Error 255
/usr/bin/make test -- NOT OK
Running make install
make test had returned bad status, won't install without force

gunguymadman 回复于:2007-10-27 14:32:20

兄弟 不要搞spamassassion了 消耗太大 得不偿失

建议用greplist 灰名单

junger 回复于:2007-10-29 10:16:36

ps:重新启动apache服务器后,您的Webmail和Extman已经可以使用了,可以在浏览器中输入指定的虚拟主机的名称进行访问,如下:
http://mail.benet.org

选择管理即可登入extman进行后台管理了。默认管理帐号为:root@extmail.org 密码为:extmail*123*


[attach]219484[/attach]
40 my $connect = "DBI:mysql:database=$opt{dbname};host=$opt{host}";
41 if ($opt{socket}) {
42 $connect .= ";mysql_socket=$opt{socket}";
43 }
44 my $dbh = DBI->connect(
45 $connect,$opt{dbuser}, $opt{dbpw}, {'RaiseError' => 1}
46 );
47
48 $self->{dbh} = $dbh;
49 $self->{pwhandle} = Ext::Passwd->new(
50 fallback_scheme => $opt{crypt_type} || 'crypt

这是什么原因……?

[ 本帖最后由 junger 于 2007-10-29 13:12 编辑 ]
截图_2025-11-15_15-01-19.jpg
截图_2025-11-15_15-01-19.jpg (49.27 KiB) 查看 866 次
victorchang 回复于:2007-10-29 13:33:34

引用:原帖由 junger 于 2007-10-29 10:16 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=7523943&ptid=987344
ps:重新启动apache服务器后,您的Webmail和Extman已经可以使用了,可以在浏览器中输入指定的虚拟主机的名称进行访问,如下:
http://mail.benet.org

选择管理即可登入extman进行后台管理了。默认管理帐号为 ...

检查一下,你的extmail目录和extman目录的.webmail.cf或webman.cf文件中,
配置MYSQL访问的用户名和口令对吗?

marion 回复于:2007-10-29 17:34:06

强行安装吧,测试存在错误是在所难免的……

zdyldy 回复于:2007-10-30 09:14:32

(echo "# Do not edit -- this file documents how Postfix was built for your machine."; /bin/sh makedefs) >makedefs.tmp
set +e; if cmp makedefs.tmp conf/makedefs.out; then rm makedefs.tmp; \
else mv makedefs.tmp conf/makedefs.out; fi >/dev/null 2>/dev/null
set -e; for i in src/util src/global src/dns src/tls src/xsasl src/milter src/master src/postfix src/smtpstone src/sendmail src/error src/pickup src/cleanup src/smtpd src/local src/trivial-rewrite src/qmgr src/oqmgr src/smtp src/bounce src/pipe src/showq src/postalias src/postcat src/postconf src/postdrop src/postkick src/postlock src/postlog src/postmap src/postqueue src/postsuper src/qmqpd src/spawn src/flush src/verify src/virtual src/proxymap src/anvil src/scache src/discard src/tlsmgr; do \
(set -e; echo "[$i]"; cd $i; rm -f Makefile; \
make -f Makefile.in Makefile MAKELEVEL=) || exit 1; \
done;
[src/util]
cat ../../conf/makedefs.out Makefile.in >Makefile
[src/global]
cat ../../conf/makedefs.out Makefile.in >Makefile
[src/dns]
cat ../../conf/makedefs.out Makefile.in >Makefile
[src/tls]
cat ../../conf/makedefs.out Makefile.in >Makefile
[src/xsasl]
cat ../../conf/makedefs.out Makefile.in >Makefile
[src/milter]
cat ../../conf/makedefs.out Makefile.in >Makefile
[src/master]
cat ../../conf/makedefs.out Makefile.in >Makefile
[src/postfix]
cat ../../conf/makedefs.out Makefile.in >Makefile
[src/smtpstone]
cat ../../conf/makedefs.out Makefile.in >Makefile
[src/sendmail]
cat ../../conf/makedefs.out Makefile.in >Makefile
[src/error]
cat ../../conf/makedefs.out Makefile.in >Makefile
[src/pickup]
cat ../../conf/makedefs.out Makefile.in >Makefile
[src/cleanup]
cat ../../conf/makedefs.out Makefile.in >Makefile
[src/smtpd]
cat ../../conf/makedefs.out Makefile.in >Makefile
[src/local]
cat ../../conf/makedefs.out Makefile.in >Makefile
[src/trivial-rewrite]
cat ../../conf/makedefs.out Makefile.in >Makefile
[src/qmgr]
cat ../../conf/makedefs.out Makefile.in >Makefile
[src/oqmgr]
cat ../../conf/makedefs.out Makefile.in >Makefile
[src/smtp]
cat ../../conf/makedefs.out Makefile.in >Makefile
[src/bounce]
cat ../../conf/makedefs.out Makefile.in >Makefile
[src/pipe]
cat ../../conf/makedefs.out Makefile.in >Makefile
[src/showq]
cat ../../conf/makedefs.out Makefile.in >Makefile
[src/postalias]
cat ../../conf/makedefs.out Makefile.in >Makefile
[src/postcat]
cat ../../conf/makedefs.out Makefile.in >Makefile
[src/postconf]
cat ../../conf/makedefs.out Makefile.in >Makefile
[src/postdrop]
cat ../../conf/makedefs.out Makefile.in >Makefile
[src/postkick]
cat ../../conf/makedefs.out Makefile.in >Makefile
[src/postlock]
cat ../../conf/makedefs.out Makefile.in >Makefile
[src/postlog]
cat ../../conf/makedefs.out Makefile.in >Makefile
[src/postmap]
cat ../../conf/makedefs.out Makefile.in >Makefile
[src/postqueue]
cat ../../conf/makedefs.out Makefile.in >Makefile
[src/postsuper]
cat ../../conf/makedefs.out Makefile.in >Makefile
[src/qmqpd]
cat ../../conf/makedefs.out Makefile.in >Makefile
[src/spawn]
cat ../../conf/makedefs.out Makefile.in >Makefile
[src/flush]
cat ../../conf/makedefs.out Makefile.in >Makefile
[src/verify]
cat ../../conf/makedefs.out Makefile.in >Makefile
[src/virtual]
cat ../../conf/makedefs.out Makefile.in >Makefile
[src/proxymap]
cat ../../conf/makedefs.out Makefile.in >Makefile
[src/anvil]
cat ../../conf/makedefs.out Makefile.in >Makefile
[src/scache]
cat ../../conf/makedefs.out Makefile.in >Makefile
[src/discard]
cat ../../conf/makedefs.out Makefile.in >Makefile
[src/tlsmgr]
cat ../../conf/makedefs.out Makefile.in >Makefile
rm -f Makefile; (cat conf/makedefs.out Makefile.in) >Makefile





postfix安装不上啊,帮我看看啊.

junger 回复于:2007-10-30 10:04:44

[root@zone ~]# vi /var/www/extsuite/extmail/webmail.cf

# if mysql, all relate parameters should prefix as SYS_MYSQL
SYS_MYSQL_USER = postfix
SYS_MYSQL_PASS = 123456
SYS_MYSQL_DB = extmail
SYS_MYSQL_HOST = localhost
SYS_MYSQL_SOCKET = /tmp/mysql.sock
# table name
SYS_MYSQL_TABLE = mailbox
SYS_MYSQL_ATTR_USERNAME = username
SYS_MYSQL_ATTR_DOMAIN = domain

[root@zone ~]# vi /var/www/extsuite/extman/webman.cf

# if mysql, all relate paramters should prefix as SYS_MYSQL
SYS_MYSQL_USER = postfix
SYS_MYSQL_PASS = 123456
SYS_MYSQL_DB = extmail
SYS_MYSQL_HOST = localhost
SYS_MYSQL_SOCKET = /tmp/mysql.sock
# table name
SYS_MYSQL_TABLE = manager
SYS_MYSQL_ATTR_USERNAME = username
SYS_MYSQL_ATTR_PASSWD = password
# comment it if you only want to save crypted password
# we highly recommend that you disable the following line :)
# SYS_MYSQL_ATTR_CLEARPW = clearpwd

victorchang 回复于:2007-10-30 14:28:14

可以在本机通过MYSQL进行测试
#/usr/local/bin/mysql -upostfix -p123456
mysql>show databases;

mysql> show databases;
+--------------------+
| Database |
+--------------------+
| information_schema |
| extmail |
| mysql |
| postfix |
+--------------------+
6 rows in set (0.02 sec)

mysql>
mysql> use extmail;
Database change
如果以上能出就说明你的用户应该是有效...

[ 本帖最后由 victorchang 于 2007-10-30 16:09 编辑 ]

lbq431 回复于:2007-10-30 15:19:00

请问最近经常受到一些“发票”之类的垃圾邮件,如何解决

junger 回复于:2007-10-30 15:56:36

[root@zone ~]# /usr/local/mysql/bin/mysqladmin -u postfix -p 123456
Enter password:
/usr/local/mysql/bin/mysqladmin: connect to server at 'localhost' failed
error: 'Access denied for user 'postfix'@'localhost' (using password: YES)'

victorchang 回复于:2007-10-30 16:11:29

引用:原帖由 junger 于 2007-10-30 15:56 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=7530976&ptid=987344
[root@zone ~]# /usr/local/mysql/bin/mysqladmin -u postfix -p 123456
Enter password:
/usr/local/mysql/bin/mysqladmin: connect to server at 'localhost' failed
error: 'Access denied for user 'po ...


telnet 127.0.0.1 3306 看看MYSQL启动没有呀.
用ROOT用户进入试一试.

MYSQLER 回复于:2007-10-31 08:51:46

我按照你的一步步来做.一切都正常,安装完了extmail,并且安装了extman(上次提问时没有安装),按照你的提示说可以用web访问了,可是当我访问时出现500 Internal Server Error
查看日志

[Copy to clipboard] [ - ]CODE:
cat suexec_log

[2007-10-21 03:46:34]: user mismatch (nobody instead of www)
[2007-10-21 03:46:39]: user mismatch (nobody instead of www)
[2007-10-21 03:46:44]: user mismatch (nobody instead of www)
[2007-10-21 03:46:45]: user mismatch (nobody instead of www)
[2007-10-21 03:47:06]: user mismatch (nobody instead of www)
[2007-10-21 03:47:09]: user mismatch (nobody instead of www)
[2007-10-21 03:47:09]: user mismatch (nobody instead of www)
[2007-10-21 03:47:10]: user mismatch (nobody instead of www)
[2007-10-21 03:47:11]: user mismatch (nobody instead of www)
[2007-10-21 03:47:11]: user mismatch (nobody instead of www)
[2007-10-21 03:50:10]: user mismatch (nobody instead of www)
[2007-10-21 03:57:59]: user mismatch (nobody instead of www)
[2007-10-21 03:58:02]: user mismatch (nobody instead of www)
[2007-10-21 03:58:03]: user mismatch (nobody instead of www)
[2007-10-21 03:58:03]: user mismatch (nobody instead of www)
[2007-10-21 03:58:04]: user mismatch (nobody instead of www)
[2007-10-21 03:58:05]: user mismatch (nobody instead of www)
[2007-10-21 03:58:05]: user mismatch (nobody instead of www)
[2007-10-21 03:58:06]: user mismatch (nobody instead of www)
[2007-10-21 03:58:07]: user mismatch (nobody instead of www)
[2007-10-21 03:58:07]: user mismatch (nobody instead of www)
[2007-10-21 03:58:08]: user mismatch (nobody instead of www)
[2007-10-21 03:58:09]: user mismatch (nobody instead of www)
[2007-10-21 03:58:09]: user mismatch (nobody instead of www)
[2007-10-21 03:58:10]: user mismatch (nobody instead of www)
[2007-10-21 04:03:05]: user mismatch (nobody instead of www)
[2007-10-21 04:04:25]: user mismatch (nobody instead of www)
[2007-10-21 04:04:26]: user mismatch (nobody instead of www)
[2007-10-21 04:11:51]: user mismatch (nobody instead of www)
[2007-10-21 04:11:52]: user mismatch (nobody instead of www)
[2007-10-21 04:24:20]: user mismatch (nobody instead of www)
[2007-10-21 04:24:21]: user mismatch (nobody instead of www)
[2007-10-21 04:24:22]: user mismatch (nobody instead of www)
[2007-10-21 13:20:28]: user mismatch (nobody instead of www)
错误日志

[Copy to clipboard] [ - ]CODE:
[Sun Oct 21 03:58:07 2007] [error] [client 192.168.1.7] File does not exist: /var/www/extsuite/extmail/html/favicon.ico
[Sun Oct 21 03:58:07 2007] [error] [client 192.168.1.7] Premature end of script headers: index.cgi
[Sun Oct 21 03:58:08 2007] [error] [client 192.168.1.7] File does not exist: /var/www/extsuite/extmail/html/favicon.ico
[Sun Oct 21 03:58:08 2007] [error] [client 192.168.1.7] Premature end of script headers: index.cgi
[Sun Oct 21 03:58:08 2007] [error] [client 192.168.1.7] File does not exist: /var/www/extsuite/extmail/html/favicon.ico
[Sun Oct 21 03:58:09 2007] [error] [client 192.168.1.7] Premature end of script headers: index.cgi
[Sun Oct 21 03:58:09 2007] [error] [client 192.168.1.7] File does not exist: /var/www/extsuite/extmail/html/favicon.ico
[Sun Oct 21 03:58:09 2007] [error] [client 192.168.1.7] Premature end of script headers: index.cgi
[Sun Oct 21 03:58:09 2007] [error] [client 192.168.1.7] File does not exist: /var/www/extsuite/extmail/html/favicon.ico
[Sun Oct 21 03:58:10 2007] [error] [client 192.168.1.7] Premature end of script headers: index.cgi
[Sun Oct 21 03:58:10 2007] [error] [client 192.168.1.7] File does not exist: /var/www/extsuite/extmail/html/favicon.ico
[Sun Oct 21 04:03:05 2007] [error] [client 192.168.1.7] File does not exist: /var/www/extsuite/extmail/html/favicon.ico
[Sun Oct 21 04:03:05 2007] [error] [client 192.168.1.7] Premature end of script headers: index.cgi
[Sun Oct 21 04:03:05 2007] [error] [client 192.168.1.7] File does not exist: /var/www/extsuite/extmail/html/favicon.ico
[Sun Oct 21 04:04:25 2007] [error] [client 192.168.1.7] Premature end of script headers: index.cgi
[Sun Oct 21 04:04:25 2007] [error] [client 192.168.1.7] File does not exist: /var/www/extsuite/extmail/html/favicon.ico
[Sun Oct 21 04:04:26 2007] [error] [client 192.168.1.7] Premature end of script headers: index.cgi
[Sun Oct 21 04:04:26 2007] [error] [client 192.168.1.7] File does not exist: /var/www/extsuite/extmail/html/favicon.ico
[Sun Oct 21 04:11:51 2007] [error] [client 192.168.1.7] Premature end of script headers: index.cgi
[Sun Oct 21 04:11:51 2007] [error] [client 192.168.1.7] File does not exist: /var/www/extsuite/extmail/html/favicon.ico
[Sun Oct 21 04:11:52 2007] [error] [client 192.168.1.7] Premature end of script headers: index.cgi
[Sun Oct 21 04:11:52 2007] [error] [client 192.168.1.7] File does not exist: /var/www/extsuite/extmail/html/favicon.ico

victorchang 回复于:2007-10-31 09:24:42

引用:原帖由 MYSQLER 于 2007-10-31 08:51 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=7533152&ptid=987344
我按照你的一步步来做.一切都正常,安装完了extmail,并且安装了extman(上次提问时没有安装),按照你的提示说可以用web访问了,可是当我访问时出现500 Internal Server Error
查看日志

[Copy to clipboard] ...

这个问题就是APACHE的执行权限问题了.
我是这样设置的
在httpd.conf文件中
user daemon
group daemon
在extra/httpd-vhost.conf文件中
<VirtualHost *:80>
ServerName mail.****.net
DocumentRoot /var/www/extsuite/extmail/html/
ScriptAlias /extmail/cgi /var/www/extsuite/extmail/cgi
Alias /extmail /var/www/extsuite/extmail/html
SuexecUserGroup postfix postfix
</VirtualHost>

还有,你要保证extmail和extman的属主是postfix.postfix


我在装maildrop,然后配置vmail用户权限后,也出现了IIS 500的错误,没办法又改回了原来的方式...

[ 本帖最后由 victorchang 于 2007-10-31 09:34 编辑 ]

marion 回复于:2007-11-01 11:54:34

victorchang的分析是正确的,注意suexec的设置……

楚国布衣 回复于:2007-11-01 21:44:19

只想说2个字,谢谢。
如果LZ能把各个模块都有什么作用再明说一下就更好啦。

cnhawk386 回复于:2007-11-02 07:53:02

如下错误提示:
warning: dict_nis_init: NIS domain name not set - NIS lookups disabled
请教
谢谢

marion 回复于:2007-11-02 11:36:21

这个不妨事儿的,如果你想要去掉这个警告的话,可以到main.cf文件中找到aliases相关的项目中有关nis的设置并将其删除即可。

cnhawk386 回复于:2007-11-02 13:53:31

引用:原帖由 marion 于 2007-11-2 11:36 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=7543070&ptid=987344
这个不妨事儿的,如果你想要去掉这个警告的话,可以到main.cf文件中找到aliases相关的项目中有关nis的设置并将其删除即可。



即使从main.cf中去掉alias_maps = hash:/etc/aliases, nis:mail.aliases这一行
也是同样的错误提示

而且
postconf |grep nis
alias_maps = hash:/etc/aliases, nis:mail.aliases
lmtp_sasl_mechanism_filter =
smtp_sasl_mechanism_filter =


居然出现了被我删掉的alias_maps = hash:/etc/aliases, nis:mail.aliases

真是奇怪

cnhawk386 回复于:2007-11-02 13:55:15

Nov 3 15:17:45 wbxsb authdaemond: failed to connect to mysql server (server=localhost, userid=extmail): Access denied for user 'extmail'@'localhost' (using password: YES)

请教
谢谢

[ 本帖最后由 cnhawk386 于 2007-11-3 15:57 编辑 ]

zdyldy 回复于:2007-11-02 15:15:32

我用webmail发信后,发件箱里还有邮件,我想发完邮件后,发件箱里没有邮件应该怎么设置啊.

marion 回复于:2007-11-03 17:31:41

引用:Nov 3 15:17:45 wbxsb authdaemond: failed to connect to mysql server (server=localhost, userid=extmail): Access denied for user 'extmail'@'localhost' (using password: YES)……


extmail没有权限访问数据库,手动给其赋予权限即可。

junger 回复于:2007-11-03 18:05:13

[root@zone ~]# telnet 127.0.0.1 3306
Trying 127.0.0.1...
Connected to zone (127.0.0.1).
Escape character is '^]'.
8
5.0.45-logX[C{ehYc,[pEEjhK~Y!8Connection closed by foreign host.

marion 回复于:2007-11-03 18:48:29

请问,在你理解中,extman和3306端口是什么关系,为什么要telnet 3306?

junger 回复于:2007-11-05 11:23:01

我现在登入extman进行后台管理,它提示我44行有错误
[attach]220819[/attach]
40 my $connect = "DBI:mysql:database=$opt{dbname};host=$opt{host}";
41 if ($opt{socket}) {
42 $connect .= ";mysql_socket=$opt{socket}";
43 }
44 my $dbh = DBI->connect(
45 $connect,$opt{dbuser}, $opt{dbpw}, {'RaiseError' => 1}
46 );
47
48 $self->{dbh} = $dbh;
49 $self->{pwhandle} = Ext:asswd->new(
50 fallback_scheme => $opt{crypt_type} || 'crypt

victorchang兄问我是不是配置MYSQL访问的用户名和口令不对?
我看了一下没有错,但我在本机通过MYSQL进行测试

[root@zone ~]# /usr/local/mysql/bin/mysqladmin -u postfix -p 123456
Enter password:
/usr/local/mysql/bin/mysqladmin: connect to server at 'localhost' failed
error: 'Access denied for user 'postfix'@'localhost' (using password: YES)'
victorchang兄让我telnet 127.0.0.1 3306 看看MYSQL启动没有呀.
用ROOT用户进入试一试.

[ 本帖最后由 junger 于 2007-11-5 11:29 编辑 ]
截图_2025-11-15_15-04-25.jpg
截图_2025-11-15_15-04-25.jpg (52.24 KiB) 查看 865 次
marion 回复于:2007-11-05 13:16:03

引用:~]# /usr/local/mysql/bin/mysqladmin -u postfix -p 123456
Enter password:
/usr/local/mysql/bin/mysqladmin: connect to server at 'localhost' failed
error: 'Access denied for user 'postfix'@'localhost' (using password: YES)'



你可以用类似如下的命令登录MYSQL试一下:
#/usr/local/mysql/bin/mysql -u postfix -p
执行这个命令后会提示输入密码,此时再输入你的123456

修正一下,上次写成了mysqladmin,应该是mysql,后面victorchang朋友也给出了正确答案。

[ 本帖最后由 marion 于 2007-11-6 17:50 编辑 ]

micheal73 回复于:2007-11-06 00:16:16

楼主我想把你的东西搞成pdf,不过我要测试完成确认没有错误才可以,我的环境是centos4.5,我想应该没有区别的,可以在进行php编译过程中出现错误
我尝试做如下改动
引用:
六、安装php-5.2.3

# tar -zvxf php-5.2.3.tar.gz
# mkdir -p /usr/local/php
# cd php-5.2.3
# ./configure --prefix=/usr/local/php
--with-apxs2=/usr/local/apache/bin/apxs
--with-mysql=/usr/local/mysql
--with-mysqli=/usr/local/mysql/bin/mysql_config
--with-xml(不要此参数)
--with-png-dir=/usr/local
--with-jpeg-dir=/usr/local
--with-zlib
--with-freetype-dir=/usr/local(不要此参数)
--with-gd
--enable-track-vars (不要此参数)
--enable-mbstring=all
采用以上参数可能引起编译错误
(【网络解释】如果配置PHP时出错:configure: error: libjpeg.(a|so) not found
请安装:jpegsrc.v6b.tar.gz 和 libpng-1.2.8-config.tar.gz,如果没安装 GD 库,安装 gd-2.0.33.tar.gz ,这个新的默认就支持 gif
【个人做法】从安装光盘中找到gd-2.0.28-5.4E.i386.rpm,libpng-devel-1.2.7-1.el4.2.i386.rpm,libjpeg-devel-6b-33.i386.rpm包安装
)




你确定--with-xml --enable-track-vars参数是正确的吗,我./configure --help没有找到这些相关的参数啊?
还有 --with-freetype-dir=/usr/local 这个参数编译时报freetype.h无法找到的错误

我是新手,按道理看那么深的文章不太好,可是我坚持者每个字符都敲一遍,通过这个,我想我会慢慢的成长的。

我不知道你很多编译参数为什么要这么设置,每个参数的意义只有查help了

victorchang 回复于:2007-11-06 08:31:54

引用:原帖由 cnhawk386 于 2007-11-6 08:26 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=7555598&ptid=987344
哪里可以找到authmysqlrc这个文件的详细解释 google半天也没找到 也没有官方网站
我的配置如下:
MYSQL_SERVER localhost
MYSQL_USERNAME extmail
MYSQL_PASSWORD 123456
M ...

你的 uidnumber,gidnumber 为什么没有改呢???如果按文档做的,应该设置成2525吧,如果做了后面的maildrop应该改成1001呀
cat /etc/group 看一下,你的postfix 的GID是不是2525....

victorchang 回复于:2007-11-06 08:34:50

引用:原帖由 zdyldy 于 2007-11-2 15:15 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=7544455&ptid=987344
我用webmail发信后,发件箱里还有邮件,我想发完邮件后,发件箱里没有邮件应该怎么设置啊.

这个问题,好是像在发邮件的时候,默认选项是将邮件保存到发件箱中,你把选项去掉不就行了吗???
~_~

yinglikx2006 回复于:2007-11-06 09:18:18

各位老大帮忙呀。!急!!!!!
在安装完postfix,启用了cyrus-sasl的认证功能之后之后(还没有安装courier-authlib和courier-imap)在/var/log/maillog中发现的问题:
Nov 6 08:40:01 email postfix/pickup[14216]: 46C1768C18B: uid=0 from=<root>
Nov 6 08:40:01 email postfix/cleanup[14177]: warning: connect to mysql server localhost: Access denied for user

'extmail'@'localhost' (using password: YES)
Nov 6 08:40:01 email postfix/cleanup[14177]: warning: 46C1768C18B: virtual_alias_maps map lookup problem for

root@think.net
Nov 6 08:41:01 email postfix/pickup[14216]: 44E3B68C18B: uid=0 from=<root>
Nov 6 08:41:01 email postfix/cleanup[14177]: warning: 44E3B68C18B: virtual_alias_maps map lookup problem for

root@think.net
Nov 6 08:42:01 email postfix/pickup[14216]: 430B268C18B: uid=0 from=<root>
Nov 6 08:42:01 email postfix/cleanup[14177]: warning: connect to mysql server localhost: Access denied for user

'extmail'@'localhost' (using password: YES)
Nov 6 08:42:01 email postfix/cleanup[14177]: warning: 430B268C18B: virtual_alias_maps map lookup problem for

root@think.net
Nov 6 08:43:01 email postfix/pickup[14216]: 4129B68C18B: uid=0 from=<root>
Nov 6 08:43:01 email postfix/cleanup[14177]: warning: 4129B68C18B: virtual_alias_maps map lookup problem for

root@think.net
Nov 6 08:44:01 email postfix/pickup[14216]: 3F4D468C18B: uid=0 from=<root>
Nov 6 08:44:01 email postfix/cleanup[14177]: warning: connect to mysql server localhost: Access denied for user

'extmail'@'localhost' (using password: YES)
Nov 6 08:44:01 email postfix/cleanup[14177]: warning: 3F4D468C18B: virtual_alias_maps map lookup problem for

root@think.net
Nov 6 08:45:01 email postfix/pickup[14216]: 3D6EF68C18B: uid=0 from=<root>
Nov 6 08:45:01 email postfix/cleanup[14177]: warning: 3D6EF68C18B: virtual_alias_maps map lookup problem for

root@think.net
Nov 6 08:46:01 email postfix/pickup[14216]: 3B94468C18B: uid=0 from=<root>
Nov 6 08:46:01 email postfix/cleanup[14177]: warning: connect to mysql server localhost: Access denied for user

'extmail'@'localhost' (using password: YES)
Nov 6 08:46:01 email postfix/cleanup[14177]: warning: 3B94468C18B: virtual_alias_maps map lookup problem for

root@think.net
Nov 6 08:47:01 email postfix/pickup[14216]: 39BB068C18B: uid=0 from=<root>
Nov 6 08:47:01 email postfix/cleanup[14177]: warning: 39BB068C18B: virtual_alias_maps map lookup problem for

root@think.net
Nov 6 08:48:01 email postfix/pickup[14216]: 37DFF68C18B: uid=0 from=<root>
Nov 6 08:48:01 email postfix/cleanup[14177]: warning: connect to mysql server localhost: Access denied for user

'extmail'@'localhost' (using password: YES)
Nov 6 08:48:01 email postfix/cleanup[14177]: warning: 37DFF68C18B: virtual_alias_maps map lookup problem for

root@think.net
Nov 6 08:49:01 email postfix/pickup[14216]: 35FC968C18B: uid=0 from=<root>
Nov 6 08:49:01 email postfix/cleanup[14177]: warning: 35FC968C18B: virtual_alias_maps map lookup problem for

root@think.net
Nov 6 08:50:01 email postfix/pickup[14216]: 341F668C18B: uid=0 from=<root>
Nov 6 08:50:01 email postfix/cleanup[14177]: warning: connect to mysql server localhost: Access denied for user

'extmail'@'localhost' (using password: YES)
Nov 6 08:50:01 email postfix/cleanup[14177]: warning: 341F668C18B: virtual_alias_maps map lookup problem for

root@think.net

junger 回复于:2007-11-06 13:00:49

这样不行,这样输入的话出现:
[root@zone ~]# /usr/local/mysql/bin/mysqladmin -u postfix -p
/usr/local/mysql/bin/mysqladmin Ver 8.41 Distrib 5.0.45, for pc-linux-gnu on i686
Copyright (C) 2000-2006 MySQL AB
This software comes with ABSOLUTELY NO WARRANTY. This is free software,
and you are welcome to modify and redistribute it under the GPL license

Administration program for the mysqld daemon.
Usage: /usr/local/mysql/bin/mysqladmin [OPTIONS] command command....
-c, --count=# Number of iterations to make. This works with -i
(--sleep) only.
-#, --debug[=name] Output debug log. Often this is 'd:t:o,filename'.
-f, --force Don't ask for confirmation on drop database; with
multiple commands, continue even if an error occurs.
-C, --compress Use compression in server/client protocol.
--character-sets-dir=name
Directory where character sets are.
--default-character-set=name
Set the default character set.
-?, --help Display this help and exit.
-h, --host=name Connect to host.
-p, --password[=name]
Password to use when connecting to server. If password is
not given it's asked from the tty.
-P, --port=# Port number to use for connection.
--protocol=name The protocol of connection (tcp,socket,pipe,memory).
-r, --relative Show difference between current and previous values when
used with -i. Currently works only with extended-status.
-O, --set-variable=name
Change the value of a variable. Please note that this
option is deprecated; you can set variables directly with
--variable-name=value.
-s, --silent Silently exit if one can't connect to server.
-S, --socket=name Socket file to use for connection.
-i, --sleep=# Execute commands again and again with a sleep between.
-u, --user=name User for login if not current user.
-v, --verbose Write more information.
-V, --version Output version information and exit.
-E, --vertical Print output vertically. Is similar to --relative, but
prints output vertically.
-w, --wait[=#] Wait and retry if connection is down.
--connect_timeout=#
--shutdown_timeout=#

Variables (--variable-name=value)
and boolean options {FALSE|TRUE} Value (after reading options)
--------------------------------- -----------------------------
count 0
force FALSE
compress FALSE
character-sets-dir (No default value)
default-character-set (No default value)
host (No default value)
port 3306
relative FALSE
socket /tmp/mysql.sock
sleep 0
user postfix
verbose FALSE
vertical FALSE
connect_timeout 43200
shutdown_timeout 3600

Default options are read from the following files in the given order:
/etc/my.cnf ~/.my.cnf /usr/local/mysql/etc/my.cnf
The following groups are read: mysqladmin client
The following options may be given as the first argument:
--print-defaults Print the program argument list and exit
--no-defaults Don't read default options from any options file
--defaults-file=# Only read default options from the given file #
--defaults-extra-file=# Read this file after the global files are read

Where command is a one or more of: (Commands may be shortened)
create databasename Create a new database
debug Instruct server to write debug information to log
drop databasename Delete a database and all its tables
extended-status Gives an extended status message from the server
flush-hosts Flush all cached hosts
flush-logs Flush all logs
flush-status Clear status variables
flush-tables Flush all tables
flush-threads Flush the thread cache
flush-privileges Reload grant tables (same as reload)
kill id,id,... Kill mysql threads
password new-password Change old password to new-password, MySQL 4.1 hashing.
old-password new-password Change old password to new-password in old format.

ping Check if mysqld is alive
processlist Show list of active threads in server
reload Reload grant tables
refresh Flush all tables and close and open logfiles
shutdown Take server down
status Gives a short status message from the server
start-slave Start slave
stop-slave Stop slave
variables Prints variables available
version Get version info from server

victorchang 回复于:2007-11-06 15:49:52

引用:原帖由 junger 于 2007-11-6 13:00 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=7556965&ptid=987344
这样不行,这样输入的话出现:
[root@zone ~]# /usr/local/mysql/bin/mysqladmin -u postfix -p
/usr/local/mysql/bin/mysqladmin Ver 8.41 Distrib 5.0.45, for pc-linux-gnu on i686
Copyright (C) 2000- ...


你用/usr/local/mysql/bin/mysql -u postfix -p 试一试???

[ 本帖最后由 victorchang 于 2007-11-6 15:51 编辑 ]

zdyldy 回复于:2007-11-06 16:42:20

[root@mail oli]# /usr/local/sbin/amavisd
Problem in Amavis::DB or Amavis::DB::SNMP code: Can't locate BerkeleyDB.pm in @INC (@INC contains: /usr/lib/perl5/site_perl/5.8.8/i386-linux-thread-multi /usr/lib/perl5/site_perl/5.8.7/i386-linux-thread-multi /usr/lib/perl5/site_perl/5.8.6/i386-linux-thread-multi /usr/lib/perl5/site_perl/5.8.5/i386-linux-thread-multi /usr/lib/perl5/site_perl/5.8.8 /usr/lib/perl5/site_perl/5.8.7 /usr/lib/perl5/site_perl/5.8.6 /usr/lib/perl5/site_perl/5.8.5 /usr/lib/perl5/site_perl /usr/lib/perl5/vendor_perl/5.8.8/i386-linux-thread-multi /usr/lib/perl5/vendor_perl/5.8.7/i386-linux-thread-multi /usr/lib/perl5/vendor_perl/5.8.6/i386-linux-thread-multi /usr/lib/perl5/vendor_perl/5.8.5/i386-linux-thread-multi /usr/lib/perl5/vendor_perl/5.8.8 /usr/lib/perl5/vendor_perl/5.8.7 /usr/lib/perl5/vendor_perl/5.8.6 /usr/lib/perl5/vendor_perl/5.8.5 /usr/lib/perl5/vendor_perl /usr/lib/perl5/5.8.8/i386-linux-thread-multi /usr/lib/perl5/5.8.8) at (eval 45) line 15.
BEGIN failed--compilation aborted at (eval 45) line 15.
[root@mail oli]#


这是怎么回事啊.

vepeta 回复于:2007-11-06 17:35:38

引用:原帖由 zdyldy 于 2007-11-6 16:42 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=7558186&ptid=987344
[root@mail oli]# /usr/local/sbin/amavisd
Problem in Amavis::DB or Amavis::DB::SNMP code: Can't locate BerkeleyDB.pm in @INC (@INC contains: /usr/lib/perl5/site_perl/5.8.8/i386-linux-thread-mult ...

Can't locate BerkeleyDB.pm
这里已经说得很清楚了

marion 回复于:2007-11-06 17:57:42

引用:……
MYSQL_UID_FIELD uidnumber
MYSQL_GID_FIELD gidnumber
……


这里的uidnumber和gidnumber应该是你的MDA运行用户的uid号和gid号!

如果没有安装maildrop,这个用户一般是postfix的运行帐号;反之,则应该是maildrop的运行帐号。

junger 回复于:2007-11-06 17:58:51

还是不行 :em14: :em14:
有一个奇怪的现象:
[root@zone ~]# /usr/local/mysql/bin/mysql -u postfix -p
Enter password:
ERROR 1045 (28000): Access denied for user 'postfix'@'localhost' (using password: YES)

[root@zone ~]# /usr/local/mysql/bin/mysql -u postfix -p 123456
Enter password:
ERROR 1045 (28000): Access denied for user 'postfix'@'localhost' (using password: YES)


[root@zone ~]# /usr/local/mysql/bin/mysqladmin -u postfix -p 123456
Enter password:
/usr/local/mysql/bin/mysqladmin: connect to server at 'localhost' failed
error: 'Access denied for user 'postfix'@'localhost' (using password: YES)'

marion 回复于:2007-11-06 18:03:15

这个不是什么奇怪现象,建议多了解mysql的使用方法。

第一个命令是指定以postfix的身份用来登录的,结果显然是给定的密码或者是用户身份错误而无法登录。

第二个命令类同第一个,不过密码要是用引号引起来可能会更好些。

第三个就是个错误的使用方法。

marion 回复于:2007-11-06 18:06:30

这里看上去颇有些欣欣向荣之景啊,感谢各位朋友的关注!

尤其感谢victorchang和vepeta两位朋友对其他朋友的热心相助,欢迎继续关注此帖,并多多交流经验心得!


[ 本帖最后由 marion 于 2007-11-6 18:07 编辑 ]

victorchang 回复于:2007-11-07 08:18:47

引用:原帖由 cnhawk386 于 2007-11-7 07:16 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=7559702&ptid=987344
Nov 7 07:24:49 wbxsb postfix/smtpd[4758]: warning: dict_nis_init: NIS domain name not set - NIS lookups disabled
Nov 7 07:24:50 wbxsb postfix/smtpd[4758]: connect from unknown[192.168.0.121]
...

可以把/etc/postfix/main.cf粘出来看一下!
我认为是域名的设置问题....

这句话,你可以理解一下,不知道是否有帮助...
mydestination会自动根据机器名生成,因此如果不希望使用它的话,应将其设为空:postconf -e mydestination=
还有域名别忘了做MX记录.

[ 本帖最后由 victorchang 于 2007-11-7 08:38 编辑 ]

zdyldy 回复于:2007-11-07 09:48:45

QUOTE:
原帖由 zdyldy 于 2007-11-6 16:42 发表
[root@mail oli]# /usr/local/sbin/amavisd
Problem in Amavis:B or Amavis:B::SNMP code: Can't locate BerkeleyDB.pm in @INC (@INC contains: /usr/lib/perl5/site_perl/5.8.8/i386-linux-thread-mult ...
Can't locate BerkeleyDB.pm
这里已经说得很清楚了


谢谢您的关注,可是不我知道该怎么解决啊.能给我一个答案么.

victorchang 回复于:2007-11-07 11:52:05

引用:原帖由 zdyldy 于 2007-11-7 09:48 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=7560068&ptid=987344
QUOTE:
原帖由 zdyldy 于 2007-11-6 16:42 发表
[root@mail oli]# /usr/local/sbin/amavisd
Problem in Amavis:B or Amavis:B::SNMP code: Can't locate BerkeleyDB.pm in @INC (@INC contains: /usr/lib/ ...

四、安装BerkeleyDB

#tar zxvf db-4.5.20.tar.gz
#cd db-4.5.20/build_unix
#../dist/configure --prefix=/usr/local/BerkeleyDB
#make
#make install

修改相应的头文件指向
# mv /usr/include/db4 /usr/inculde/db4.OFF
# rm /usr/include/db_cxx.h
# rm /usr/include/db.h
# rm /usr/include/db_185.h
# ln -sv /usr/local/BerkeleyDB/include /usr/include/db4
# ln -sv /usr/local/BerkeleyDB/include/db.h /usr/include/db.h
# ln -sv /usr/local/BerkeleyDB/include/db_cxx.h /usr/include/db_cxx.h

配置库文件搜索路径
# echo "/usr/local/BerkeleyDB/lib" >> /etc/ld.so.conf
# ldconfig –v

zdyldy 回复于:2007-11-07 12:59:21

我已经安装过了啊.最开始我就安装了,是不是其它问题啊.

tubeman 回复于:2007-11-07 14:10:04

我照着手册作在安装mysql时,到这一步#cd /usr/local/src/mysql-5.0.45,提示我没有这个目录。这是怎么回事。后来手动建立了这个文件夹。在编译安装里头也没文件。后面的#cp support/mysql.server /etc/rc.d/init.d/mysqld就下不去了

marion 回复于:2007-11-07 19:44:37

/usr/local/src/mysql-5.0.45

这个目录指的是mysql-5.0.45.tar.gz解压后的目录。手动建立这个文件夹是没有任何意义的。

victorchang 回复于:2007-11-08 10:35:17

引用:原帖由 zdyldy 于 2007-11-7 12:59 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=7561252&ptid=987344
我已经安装过了啊.最开始我就安装了,是不是其它问题啊.

# echo "/usr/local/BerkeleyDB/lib" >> /etc/ld.so.conf
# ldconfig –v

上面这个设置了吗??如果没有设置,应该找不到所需so文件的...

marion 回复于:2007-11-08 18:04:49

楼上说的应该是一解决办法。

如果还不行,去你的BerkeleyDB的安装目录下找到BerkeleyDB.pm,并使用类以下的命令对其进行链接:
ln -sv /path/to/your/BerkeleyDB.pm /usr/lib/perl5/site_perl/5.8.8/i386-linux-thread-multi

注意将其中的/path/to/your/BerkeleyDB.pm换成你的BerkeleyDB.pm文件 的路径。

micheal73 回复于:2007-11-08 20:13:18

marion 为什么我按照你的编译参数编译php会有错误呢?
六、安装php-5.2.3

# tar -zvxf php-5.2.3.tar.gz
# mkdir -p /usr/local/php
# cd php-5.2.3
# ./configure --prefix=/usr/local/php
--with-apxs2=/usr/local/apache/bin/apxs
--with-mysql=/usr/local/mysql
--with-mysqli=/usr/local/mysql/bin/mysql_config
--with-xml(不要此参数)
--with-png-dir=/usr/local
--with-jpeg-dir=/usr/local
--with-zlib
--with-freetype-dir=/usr/local(不要此参数)
--with-gd
--enable-track-vars (不要此参数)
--enable-mbstring=all
我必须把不要此参数的标记的那个编译参数去掉才可以,而且我./configure --help
找不到with-xml enable--track-vars 这2个参数哦
帮我看一下吧

Yicho 回复于:2007-11-09 01:36:26

编译courier-authlib 的时候,发现问题

./configure \
> --prefix=/usr/local/courier-authlib \
> --sysconfdir=/etc \
> --without-authpam \
> --without-authldap \
> --without-authpwd \
> --without-authshadow \
> --without-authvchkpw \
> --without-authpgsql \
> --with-authmysql \
> --with-mysql-libs=/usr/local/mysql/lib/mysql \
> --with-mysql-includes=/usr/local/mysql/include/mysql \ #此处纠正楼主一个小小小小的笔误,是/include/mysql而不是/inculd/mysql
> --with-redhat \
> --with-authmysqlrc=/etc/authmysqlrc \
> --with-authdaemonrc=/etc/authdaemonrc \

。。。。

checking whether -lm is needed for floor... yes
checking for socket in -lsocket... no
checking for socket in -lsocket... (cached) no
checking for connect in -lsocket... no
checking for connect in -lsocket... (cached) no
checking for gdbm_open in -lgdbm... no
checking for gdbm_open... no
checking for dbopen in -ldb... no
checking for db_open in -ldb... no
checking for db_env_create in -ldb... no
checking for dbopen... no
checking for db_open... no
checking for db_env_create... no
configure: error: Cannot find either the gdbm or the db library.

而我之前已经安装了BerkeleyDB了啊,为什么找不到数据库呢?

[ 本帖最后由 Yicho 于 2007-11-9 02:35 编辑 ]

Yicho 回复于:2007-11-09 02:23:14

刚才装了个gdbm-devel竟然通过。按这样的话,安装db4-devel也应该通过。等下测试。

有个问题想问楼主,courier-authlib 与DB(或gdbm) 的关系是怎样的?BerkeleyDB保存了什么样的信息啊,还望赐教啊。

cnhawk386 回复于:2007-11-09 10:34:38

nit.sql文件中

INSERT INTO `mailbox` VALUES ('postmaster@extmail.org','postmaster','$1$phz1mRrj$3ok6BjeaoJYWDBsEPZb5C0','','PostMaster','','extmail.org/postmaster/Maildir/','extmail.org/postmaster','104857600S','52428800S','extmail.org',1000,1000,'2007-02-14 15:10:04','2010-11-08 15:10:04',1,0,0,0,0,0,0,0);

这里$1$phz1mRrj$3ok6BjeaoJYWDBsEPZb5C实际代表什么 插入数据库中应该怎么设定自己的密码呢??

MYSQLER 回复于:2007-11-09 11:10:55

终于安装完了,但是等录是提示:


Can't chdir to /var/mailbox/extmail.org/zhangll/Maildir/, No such file or directory


[ 本帖最后由 MYSQLER 于 2007-11-9 11:20 编辑 ]

MYSQLER 回复于:2007-11-09 11:34:11

再有一个问题就是我不能使用SuexecUserGroup postfix postfix

在apache的配置文件里面必须注释到这一行才能显示extmail的界面,否则会出现http 500的错误,
需要说明的是我在配置apache时加了参数--enable-suexec 和--with-suexec-caller=nobody
因为我用的是apache2.0不是2.2所以加了--with-suexec-caller=nobody,不知是不是这的原因


编译apache的参数:

./configure --prefix=/usr/local/apache --enable-so --enable-ssl --with-ssl=/usr/local/ssl --enable-track-vars --enable-rewrite --with-zlib --enable-mods-shared=most --enable-suexec --with-suexec-caller=nobody


[ 本帖最后由 MYSQLER 于 2007-11-9 11:38 编辑 ]

marion 回复于:2007-11-09 13:01:58

引用:
……我必须把不要此参数的标记的那个编译参数去掉才可以,而且我./configure --help
找不到with-xml enable--track-vars 这2个参数哦……


是什么样的错误呢?你应该发上来的是当时的错误提示。

marion 回复于:2007-11-09 13:04:27

引用:
……
而我之前已经安装了BerkeleyDB了啊,为什么找不到数据库呢?
……


如果在安装BerkeleyDB时链接过程一切正常,且已经将库文件的路径添加至/etc/ld.so.conf的话,应该不会出现此类错误,也不用安装那个devel。

marion 回复于:2007-11-09 13:08:14

引用:
……
这里$1$phz1mRrj$3ok6BjeaoJYWDBsEPZb5C实际代表什么 插入数据库中应该怎么设定自己的密码呢??
……



这个是加密存放的密码,采取的是直接输入加密后的密码的形式。你可以在添加条目的过程中用形如password('123456')的方式来输入你想使用的密码,这个函数会帮你加密并存入mysql中。

具体到可以使用的对于密码加密的方法,你可以参照mysql方面的教程进行进一步了解。

marion 回复于:2007-11-09 13:09:59

引用:原帖由 MYSQLER 于 2007-11-9 11:10 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=7570385&ptid=987344
终于安装完了,但是等录是提示:


Can't chdir to /var/mailbox/extmail.org/zhangll/Maildir/, No such file or directory



关面有许多相关的讨论此问题的回复,你不妨先去找找看。

cnhawk386 回复于:2007-11-09 14:15:44

引用:原帖由 marion 于 2007-11-9 13:08 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=7571205&ptid=987344


这个是加密存放的密码,采取的是直接输入加密后的密码的形式。你可以在添加条目的过程中用形如password('123456')的方式来输入你想使用的密码,这个函数会帮你加密并存入mysql中。

具体到可以使用的对于 ...


INSERT INTO `mailbox` VALUES ('abc@def.com','abc',password('123456'),'','abc','','def.com/abc/Maildir/','def.com/abc','104857600S','52428800S','wb.wzy',1001,1001,'2007-02-14 15:10:04','2010-11-08 15:10:04',1,0,0,0,0,0,0,0);

[root@wbxsb ~]# authtest -s login abc@def.com
Authentication succeeded.

Authenticated: abc@def.com (uid 1001, gid 1001)
Home Directory: /home/domains/def.com/abc
Maildir: /home/domains/def.com/abc/Maildir/
Quota: 104857600S
Encrypted Password: *6BB4837EB74329105EE4568DDA7DC67ED2CA2AD9
Cleartext Password: (none)
Options: (none)

而extmail网站上的配置文档:
usr/sbin/authtest -s login test@extmail.org test
结果如下:
Authentication succeeded.

Authenticated: test@extmail.org (uid 1000, gid 1000)
Home Directory: /home/domains/extmail.org/test
Maildir: /home/domains/extmail.org/test/Maildir/
Quota: 5242880
Encrypted Password: {crypt}uywiuN.XggXXc
Cleartext Password: test
Options: (none)


为什么一个是Encrypted Password: *6BB4837EB74329105EE4568DDA7DC67ED2CA2AD9
一个是Encrypted Password: {crypt}uywiuN.XggXXc呢?????
如何实现extmail网站上这种结果

[root@wbxsb clamav-0.91.2]# telnet 192.168.0.12 110
Trying 192.168.0.25...
Connected to 192.168.0.12 (192.168.0.12).
Escape character is '^]'.
+OK Hello there.
user abc@def.com
+OK Password required.
pass 123456
-ERR Login failed.


请问:问题大概出在哪里 谢谢

[ 本帖最后由 cnhawk386 于 2007-11-9 14:22 编辑 ]

marion 回复于:2007-11-09 15:00:36

引用:
……
为什么一个是Encrypted Password: *6BB4837EB74329105EE4568DDA7DC67ED2CA2AD9
一个是Encrypted Password: {crypt}uywiuN.XggXXc呢?????
如何实现extmail网站上这种结果
……



那个应该只是加密方式的区别;比如你可以试试在insert命令中使用crypt('123456')来代替password。
另外,你的pop没有成功登录是不是因为别的原因造成的?你最好通过日志先确信一下。

[ 本帖最后由 marion 于 2007-11-9 15:01 编辑 ]

cnhawk386 回复于:2007-11-09 16:19:49

引用:原帖由 marion 于 2007-11-9 15:00 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=7572020&ptid=987344


那个应该只是加密方式的区别;比如你可以试试在insert命令中使用crypt('123456')来代替password。
另外,你的pop没有成功登录是不是因为别的原因造成的?你最好通过日志先确信一下。



Nov 9 14:09:48 wbxsb pop3d: LOGIN FAILED, user=lsj@wb.wzy, ip=[::ffff:192.168.0.121]
Nov 9 14:11:12 wbxsb pop3d: LOGOUT, ip=[::ffff:192.168.0.121]
Nov 9 14:11:12 wbxsb pop3d: Disconnected, ip=[::ffff:192.168.0.121]

你确认你是使用的password('123456') 这种形式吗???

[ 本帖最后由 cnhawk386 于 2007-11-9 16:29 编辑 ]

cnhawk386 回复于:2007-11-09 16:52:18

/usr/local/sbin/amavisd -u amavis debug
Problem in Amavis::DB or Amavis::DB::SNMP code:
BerkeleyDB needs compatible versions of libdb & db.h
you have db.h version 4.4.20 and libdb version 4.2.52
Compilation failed in require at (eval 58) line 15.
BEGIN failed--compilation aborted at (eval 58) line 15.

marion 回复于:2007-11-09 17:14:19

引用:原帖由 cnhawk386 于 2007-11-9 16:52 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=7572721&ptid=987344
/usr/local/sbin/amavisd -u amavis debug
Problem in Amavis::DB or Amavis::DB::SNMP code:
BerkeleyDB needs compatible versions of libdb & db.h
you have db.h version 4.4.20 and libdb vers ...


头文件引用错误,期望得到新安装的版本,但找到的是旧有的版本。请确认前面 BerkeleyDB部分关于重新链接头文件的步骤已经正确执行。或者手动重新链接报错的头文件到正确的位置。

marion 回复于:2007-11-09 17:15:59

引用:
Nov 9 14:09:48 wbxsb pop3d: LOGIN FAILED, user=lsj@wb.wzy, ip=[::ffff:192.168.0.121]
Nov 9 14:11:12 wbxsb pop3d: LOGOUT, ip=[::ffff:192.168.0.121]
Nov 9 14:11:12 wbxsb pop3d: Disconnected, ip=[::ffff:192.168.0.121]



这个信息过于笼统,建议打开authlib的调试日志选项,而后重新登录一次再通过日志确认错误所在。

MYSQLER 回复于:2007-11-09 23:33:10

再有一个问题就是我不能使用SuexecUserGroup postfix postfix

在apache的配置文件里面必须注释到这一行才能显示extmail的界面,否则会出现http 500的错误,
需要说明的是我在配置apache时加了参数--enable-suexec 和--with-suexec-caller=nobody
因为我用的是apache2.0不是2.2所以加了--with-suexec-caller=nobody,不知是不是这的原因


编译apache的参数:


./configure --prefix=/usr/local/apache --enable-so --enable-ssl --with-ssl=/usr/local/ssl --enable-track-vars --enable-rewrite --with-zlib --enable-mods-shared=most --enable-suexec --with-suexec-caller=nobody


MYSQLER 回复于:2007-11-12 11:09:45

现在web的界面已经出来了...
但是有一个问题就是我新添加了两个用户。。发出去的信彼此都收不到。。我的DNS和mail的同一台机子上

[ 本帖最后由 MYSQLER 于 2007-11-12 15:57 编辑 ]

micheal73 回复于:2007-11-12 19:35:00

郁闷了,做到第八步,
引用:
#vi /etc/postfix/main.cf
添加以下内容:
############################CYRUS-SASL############################
broken_sasl_auth_clients = yes
smtpd_recipient_restrictions=permit_mynetworks,permit_sasl_authenticated,reject_invalid_hostname,reject_non_fqdn_hostname,reject_unknown_sender_domain,reject_non_fqdn_sender,reject_non_fqdn_recipient,reject_unknown_recipient_domain,reject_unauth_pipelining,reject_unauth_destination
smtpd_sasl_auth_enable = yes
smtpd_sasl_local_domain = $myhostname
smtpd_sasl_security_options = noanonymous
smtpd_sasl_application_name = smtpd
smtpd_banner = Welcome to our $myhostname ESMTP,Warning: Version not Available!

#vi /usr/local/lib/sasl2/smtpd.conf
添加如下内容:
pwcheck_method: saslauthd
mech_list: PLAIN LOGIN
引用:
可是找了半天,压根就没有smtpd.conf
而且奇怪的是在tar包postfix后发现有可执行文件smtpd,但是编译安装后居然发现smtpd没有安装,不知道是什么原因

victorchang 回复于:2007-11-13 08:50:37

引用:原帖由 MYSQLER 于 2007-11-12 11:09 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=7579657&ptid=987344
现在web的界面已经出来了...
但是有一个问题就是我新添加了两个用户。。发出去的信彼此都收不到。。我的DNS和mail的同一台机子上

要看maillog messages 日志了....

ououpp 回复于:2007-11-13 09:51:13

想想windows下的多么简单啊,2003+winmail,小规模应用没问题,搭系统1小时搞定,除了一个月死几回机,没什么缺点。呵呵。:mrgreen:

victorchang 回复于:2007-11-13 10:38:12

引用:原帖由 ououpp 于 2007-11-13 09:51 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=7584028&ptid=987344
想想windows下的多么简单啊,2003+winmail,小规模应用没问题,搭系统1小时搞定,除了一个月死几回机,没什么缺点。呵呵。:mrgreen:

可是后期维护绝对是个大问题呀,操作系统本身的漏洞\病毒\木马.....

Yicho 回复于:2007-11-13 19:36:18

用Winmail,你不知道会发生什么。即使知道发生了什么,你也不知道怎么办。即使你知道怎么办,你也不知道具体哪里办。

yh81521 回复于:2007-11-13 22:18:41

Manifying blib/man3/Net::DNS::RR::HINFO.3pm
Manifying blib/man3/Net::DNS::RR::MG.3pm
Manifying blib/man3/Net::DNS::RR::TKEY.3pm
Manifying blib/man3/Net::DNS::RR::NSAP.3pm
Manifying blib/man3/Net::DNS::RR::CERT.3pm
Manifying blib/man3/Net::DNS::Resolver::UNIX.3pm
Manifying blib/man3/Net::DNS::RR::MB.3pm
Manifying blib/man3/Net::DNS::Resolver::Base.3pm
/usr/bin/make -- OK
Running make test
PERL_DL_NONLAZY=1 /usr/bin/perl "-MExtUtils::Command::MM" "-e" "test_harness(0, 'blib/lib', 'blib/arch')" t/*.t
t/00-load..................ok 4/79#
# These tests were ran with:
# Net::DNS::VERSION: 0.61
# set environment variable NET_DNS_DEBUG to get all versions
t/00-load..................ok
t/00-pod...................skipped
all skipped: Test::Pod v0.95 required for testing POD
t/00-version...............ok
t/01-resolver-env..........ok
t/01-resolver-file.........ok
7/8 skipped: Could not read configuration file
t/01-resolver-opt..........ok
t/01-resolver..............ok
3/45 skipped: Tests may not run succesful from private IP(192.168.0.15)
t/02-header................ok
t/03-question..............ok
t/04-packet-unique-push....ok
t/04-packet................ok
t/05-rr-opt................ok
t/05-rr-rrsort.............ok
t/05-rr-sshfp..............skipped
all skipped: Digest::BubbleBabble not installed.
t/05-rr-txt................ok
t/05-rr-unknown............ok
t/05-rr....................ok
t/06-update................ok
t/07-misc..................ok
t/08-online................ok 56/93
# Failed test 'The object isa Net::DNS::Packet'
# at t/08-online.t line 109.
# The object isn't defined
# SERVFAIL
t/08-online................NOK 57
# Failed test 'The object isa Net::DNS::Packet'
# at t/08-online.t line 109.
# The object isn't defined
t/08-online................NOK 58# SERVFAIL
t/08-online................ok 85/93
# Failed test 'Correct name (with persistent socket and search)'
t/08-online................NOK 86# at t/08-online.t line 244.
# got: 'a.t.t.net-dns.org'
# expected: 'a.t.net-dns.org'
t/08-online................ok 91/93# Looks like you planned 93 tests but only ran 91.
# Looks like you failed 3 tests of 91 run.
t/08-online................dubious
Test returned status 3 (wstat 768, 0x300)
DIED. FAILED tests 57-58, 86, 92-93
Failed 5/93 tests, 94.62% okay
t/09-tkey..................ok
t/10-recurse...............skipped
all skipped: Cannot run these tests from this IP:192.168.0.15
t/11-escapedchars..........# Using the XS compiled dn_expand function
t/11-escapedchars..........ok 95/141#
# disabling XS based dns_expand for a moment.
t/11-escapedchars..........ok 98/141#
# Continuing to use the XS based dn_expand()
t/11-escapedchars..........ok
t/11-inet6.................ok
10/11 skipped: Socket6 and or IO::Socket::INET6 not loaded
t/12-compression...........ok 4/5123456789112345678921234567893123456789412345678951234567896123...
truncated to 63 octets (RFC1035 2.3.1) at t/12-compression.t line 56
t/12-compression...........ok
Failed Test Stat Wstat Total Fail Failed List of Failed
-------------------------------------------------------------------------------
t/08-online.t 3 768 93 7 7.53% 57-58 86 92-93
3 tests and 20 subtests skipped.
Failed 1/25 test scripts, 96.00% okay. 5/1181 subtests failed, 99.58% okay.
make: *** [test_dynamic] Error 255
/usr/bin/make test -- NOT OK
Running make install
make test had returned bad status, won't install without force

cpan>
=============
怎么老是失败,perl这块不很懂,我是网上直接安装的,不是它能自动检查依赖性的吗?

cnhawk386 回复于:2007-11-14 09:43:20

./configure --prefix=/usr/local/php \
--with-apxs2=/usr/local/apache/bin/apxs \
--with-mysql=/usr/local/mysql \
--with-mysqli=/usr/local/mysql/bin/mysql_config \
--with-xml \
--with-png \
--with-jpeg \
--with-zlib \
--with-freetype \
--with-gd \
--enable-track-vars \
--enable-mbstring=all


Notice: Following unknown configure options were used:

--with-xml
--with-png
--with-jpeg
--with-freetype
--enable-track-vars

这些缺少的包具体名称?

marion 回复于:2007-11-14 10:08:58

善哉此言!!使用Exchange时这方面的感受最为深刻:出了问题,给出的结果是让去找相关事件,参照某某网页,打开了大多还是不知所云。

marion 回复于:2007-11-14 10:10:45

这里估计是不可预测的原因导致的测试存在问题,并非依赖关系未有解决!

建议加force选项强行安装

marion 回复于:2007-11-14 10:14:05

PHP对于本系统来说并非必需,建议不必安装。

另,如果你采用的软件包和安装前的环境均与文中所声明的一致的话应该不会出现这些问题,我曾多次同样的方法安装过此包。

cnhawk386 回复于:2007-11-14 10:55:53

引用:原帖由 cnhawk386 于 2007-11-14 09:43 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=7588570&ptid=987344
./configure --prefix=/usr/local/php \
--with-apxs2=/usr/local/apache/bin/apxs \
--with-mysql=/usr/local/mysql \
--with-mysqli=/usr/local/mysql/bin/mysql_config \
--with-xml \
--wit ...



究竟缺少那些相关的包呢 根据提示好像很难找到对应包的名称

yecheng_110 回复于:2007-11-14 13:12:00

认证一直出问题
打开mysql的查询记录总算明白了

但是登录成功之后就不动了 maillog内容
引用:
Nov 14 12:52:18 localhost postfix/trivial-rewrite[22247]: warning: connect to mysql server localhost: Can't connect to local MySQL server through socket '/tmp/mysql.sock' (13)
Nov 14 12:52:18 localhost postfix/trivial-rewrite[22247]: fatal: mysql:/etc/postfix/mysql_virtual_domains_maps.cf(0,lock|fold_fix): table lookup problem


把连接数据库的localhost改为127.0.0.1就可以了
不知道怎么回事 /etc/hosts里分明有localhost这一项

新的错误:
引用:
Recipient address rejected: User unknown in local recipient table;


认证成功 但是找不到本域的虚拟用户

[ 本帖最后由 yecheng_110 于 2007-11-14 17:30 编辑 ]

marion 回复于:2007-11-14 16:12:41

libxml2
libpng
jpeg6
freetype

cnhawk386 回复于:2007-11-14 16:53:14

引用:原帖由 marion 于 2007-11-14 16:12 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=7590830&ptid=987344
libxml2
libpng
jpeg6
freetype



jpeg6包的具体名字是 哪个网站可以下载的到

marion 回复于:2007-11-14 17:12:07

http://www.ijg.org/files/

jpegsrc.v6b.tar.gz

下次最好能先google一下!

yh81521 回复于:2007-11-14 18:54:54

marion 老大,
我看很多材料安装perl的时候自己设置环境变量,而且很多文章大多设置不同,这块究竟该怎么设置,能简单较少下吗?
另外有没有关于perl模块这块的书,电子的实体的都成,只要别一上来就程序设计的就成.
是不是要好好研究大骆驼.

yh81521 回复于:2007-11-14 19:47:03

marion 老大.
如果perl模块测试不能过去都force的话,是不是会有问题啊?
我有至少4个不能测试通过啊,为什么啊!
要是在BSD上装就轻松多了.

marion 回复于:2007-11-16 11:07:18

引用:原帖由 yh81521 于 2007-11-14 19:47 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=7591835&ptid=987344
marion 老大.
如果perl模块测试不能过去都force的话,是不是会有问题啊?
我有至少4个不能测试通过啊,为什么啊!
要是在BSD上装就轻松多了.


这样来问,恐怕我是没有办法给出确切建议的。一般此种问题均与你的系统环境设置有关,偶尔的测试错误并不表示无法使用此软件提供的功能,强行未必会有问题。

yh81521 回复于:2007-11-16 14:39:01

恩,是的,强行安装成功.先谢谢!

但是还有一个问题: 安装SpamAssassin当 perl Makefile.PL 时,提示缺少 Razor2 模块,但是我在官方只找到了 Mail::SpamAssassin::Plugin::Razor2 这个,我只想问一下的这两个模块是一样的吗?为什么我找不到 Razor2 模块?
我该怎么办?

[ 本帖最后由 yh81521 于 2007-11-16 14:41 编辑 ]

marion 回复于:2007-11-16 17:26:11

SpamAssassin也可以使用CPAN安装,这样可能会更简单些。

如果你的系统事先没有安装Razor2,当然会缺少了。你找到的这个应该就是所需的模块,同样的方法编译安装即可。

yh81521 回复于:2007-11-16 17:40:28

不好意思,可能是我没说清楚!
我知道是少了Razor2模块,但是不管我是自动安装还是在主页找,都没有找到这个模块.

之前我说找到的Mail::SpamAssassin::plugin::Razor2模块,进去下载的是Mail-SpamAssassin-3.2.3.tar.gz包,这和我下的SpamAssassin安装包一样啊?我郁闷.


[root@mail ~]# /usr/bin/spamd -d
[3830] warn: server socket setup failed, retry 1: spamd: could not create INET socket on 127.0.0.1:783: Address already in use
[3830] warn: server socket setup failed, retry 2: spamd: could not create INET socket on 127.0.0.1:783: Address already in use
[3830] error: spamd: could not create INET socket on 127.0.0.1:783: Address already in use
spamd: could not create INET socket on 127.0.0.1:783: Address already in use

启动出错,这个是什么错误?

[ 本帖最后由 yh81521 于 2007-11-16 18:09 编辑 ]

marion 回复于:2007-11-16 19:50:28

引用:……
[3830] error: spamd: could not create INET socket on 127.0.0.1:783: Address already in use
spamd: could not create INET socket on 127.0.0.1:783: Address already in use
……


这里已经说明了,是已经有进程占用了相应的套接字。应该是已经有一个spamd在运行了。

MYSQLER 回复于:2007-11-17 18:27:22

再有一个问题就是我不能使用SuexecUserGroup postfix postfix

在apache的配置文件里面必须注释到这一行才能显示extmail的界面,否则会出现http 500的错误,
需要说明的是我在配置apache时加了参数--enable-suexec 和--with-suexec-caller=nobody
因为我用的是apache2.0不是2.2所以加了--with-suexec-caller=nobody,不知是不是这的原因


编译apache的参数:

[Copy to clipboard] [ - ]CODE:
./configure --prefix=/usr/local/apache --enable-so --enable-ssl --with-ssl=/usr/local/ssl --enable-track-vars --enable-rewrite --with-zlib --enable-mods-shared=most --enable-suexec --with-suexec-caller=nobody



为什么没人回答一下这个问题

s001 回复于:2007-11-18 16:19:22

问一下楼主,在装courier-authlib-0.93时,configure 的时候告诉没有mysqlclient.so文件,错误出在哪里?我是按照楼主的配置文件作的。

hackerzyh 回复于:2007-11-20 08:28:17

[Mon Nov 19 22:37:00 2007] [notice] Apache/2.0.52 (Red Hat) configured -- resuming normal operations
[Mon Nov 19 22:37:19 2007] [error] [client 192.168.0.49] /usr/bin/perl: symbol lookup error: /usr/lib/perl5/site_perl/5.8.5/i386-linux-thread-multi/auto/DBD/mysql/mysql.so: undefined symbol: DBIc_TRACE_LEVEL, referer: http://ext.kingjava.vicp.net/extmail/cgi/index.cgi
[Mon Nov 19 22:37:19 2007] [error] [client 192.168.0.49] Premature end of script headers: index.cgi, referer: http://ext.kingjava.vicp.net/extmail/cgi/index.cgi


登陆不了extmail,错误日志如上。
请精灵兄帮忙啊,着急等待中,

tcllxy 回复于:2007-11-20 10:12:41

收藏先,有空玩一下,谢谢分享

hackerzyh 回复于:2007-11-20 10:43:11

引用:原帖由 s001 于 2007-11-18 16:19 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=7605115&ptid=987344
问一下楼主,在装courier-authlib-0.93时,configure 的时候告诉没有mysqlclient.so文件,错误出在哪里?我是按照楼主的配置文件作的。




你自己安装一下mysqlclient就可以了

s001 回复于:2007-11-20 10:52:35

楼主,请看一下以下错误发生的原因(suexec_log)

uid:(2525/postfix) gid(2525/2525) cmd: index.cgi

command not in docroot (/var/www/extsuite/extmail/cgi/index.cgi)

s001 回复于:2007-11-20 11:00:47

我做下面的处理就可以编译通过了,但现在我打开ie出现500内部错误

ln -sv /usr/local/mysql/bin/mysql_config /usr/bin/mysql_config

hackerzyh 回复于:2007-11-20 11:08:15

引用:原帖由 s001 于 2007-11-20 11:00 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=7611992&ptid=987344
我做下面的处理就可以编译通过了,但现在我打开ie出现500内部错误

ln -sv /usr/local/mysql/bin/mysql_config /usr/bin/mysql_config



这个我就不清楚了。


你有没有看到我的那个问题。我也是新手,[Mon Nov 19 22:37:00 2007] [notice] Apache/2.0.52 (Red Hat) configured -- resuming normal operations
[Mon Nov 19 22:37:19 2007] [error] [client 192.168.0.49] /usr/bin/perl: symbol lookup error: /usr/lib/perl5/site_perl/5.8.5/i386-linux-thread-multi/auto/DBD/mysql/mysql.so: undefined symbol: DBIc_TRACE_LEVEL, referer: http://ext.kingjava.vicp.net/extmail/cgi/index.cgi
[Mon Nov 19 22:37:19 2007] [error] [client 192.168.0.49] Premature end of script headers: index.cgi, referer: http://ext.kingjava.vicp.net/extmail/cgi/index.cgi


登陆不了extmail,错误日志如上。

marion 回复于:2007-11-20 12:26:55

引用:[Mon Nov 19 22:37:00 2007] [notice] Apache/2.0.52 (Red Hat) configured -- resuming normal operations
[Mon Nov 19 22:37:19 2007] [error] [client 192.168.0.49] /usr/bin/perl: symbol lookup error: /usr/lib/perl5/site_perl/5.8.5/i386-linux-thread-multi/auto/DBD/mysql/mysql.so: undefined symbol: DBIc_TRACE_LEVEL, referer: http://ext.kingjava.vicp.net/extmail/cgi/index.cgi
[Mon Nov 19 22:37:19 2007] [error] [client 192.168.0.49] Premature end of script headers: index.cgi, referer: http://ext.kingjava.vicp.net/extmail/cgi/index.cgi

登陆不了extmail,错误日志如上。



Maybe you use a newer DBD::mysql module,but relative older DBI module,Update DBI module to the newest version and the problem is solved.

marion 回复于:2007-11-20 12:28:53

引用:问一下楼主,在装courier-authlib-0.93时,configure 的时候告诉没有mysqlclient.so文件,错误出在哪里?我是按照楼主的配置文件作的。


这个只需要将mysql的bin目录输出至$PATH即可,方法如下:
export PATH=$PATH:/usr/local/mysql/bin

marion 回复于:2007-11-20 12:31:23

这个貌似apache的问题,对于2.0,我也没有更多的处理经验,建议查一查相关文档。

hackerzyh 回复于:2007-11-20 17:24:49

引用:原帖由 marion 于 2007-11-20 12:26 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=7612490&ptid=987344



Maybe you use a newer DBD::mysql module,but relative older DBI module,Update DBI module to the newest version and the problem is solved.



问题已经解决,谢谢老兄

hackerzyh 回复于:2007-11-20 21:59:44

configure: WARNING:
----------------------------------------------------------------------------
* I found a copy of pkgconfig, but there is no libart-2.0.pc file around.
You may want to set the PKG_CONFIG_PATH variable to point to its
location.
----------------------------------------------------------------------------

configure: WARNING:
----------------------------------------------------------------------------
* I could not find a working copy of libart-2.0. Check config.log for hints on why
this is the case. Maybe you need to set LDFLAGS and CPPFLAGS appropriately
so that compiler and the linker can find libart_lgpl_2 and its header files. If
you have not installed libart-2.0, you can get it either from its original home on

ftp://ftp.gnome.org/pub/GNOME/sources/libart_lgpl/2.3/

You can find also find an archive copy on

http://oss.oetiker.ch/rrdtool/pub/libs

The last tested version of libart-2.0 is 2.3.17.

LIBS=-lm
LDFLAGS=
CPPFLAGS= -I/usr/include/libart-2.0

----------------------------------------------------------------------------

checking for zlibVersion in -lz... yes


我安装rrdtool的时候提示的错误,rrdtool版本是1.2.23.我系统上安装有libart2.3.16,我无法卸载现有的libart,因为关联到很多程序,请问marion有没有解决办法

cnhawk386 回复于:2007-11-21 09:32:05

请教;
我的mail服务器发送给外网的邮件 可以正常接收到
但是收不到外网发过来的邮件
我怀疑跟main.cf的设置有关系 请问:mail.cf哪些项的设置跟接收外网发过来的邮件有关
谢谢

marion 回复于:2007-11-21 10:21:48

引用:……我安装rrdtool的时候提示的错误,rrdtool版本是1.2.23.我系统上安装有libart2.3.16,我无法卸载现有的libart,因为关联到很多程序,请问marion有没有解决办法


为什么要卸载libart?文章中已经说明的是一定要安装libart和libart-devel。

marion 回复于:2007-11-21 10:23:16

引用:原帖由 cnhawk386 于 2007-11-21 09:32 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=7616197&ptid=987344
请教;
我的mail服务器发送给外网的邮件 可以正常接收到
但是收不到外网发过来的邮件
我怀疑跟main.cf的设置有关系 请问:mail.cf哪些项的设置跟接收外网发过来的邮件有关
谢谢


本版置顶帖中的“postfix中文权威指南”建议下载认真看看。

hackerzyh 回复于:2007-11-21 11:27:19

引用:原帖由 marion 于 2007-11-21 10:21 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=7616582&ptid=987344


为什么要卸载libart?文章中已经说明的是一定要安装libart和libart-devel。





已经解决,谢谢
不过编译时候有问题
tclrrd.c:20:17: tcl.h: 没有那个文件或目录
tclrrd.c:30: error: syntax error before '*' token
tclrrd.c:31: error: syntax error before '*' token
tclrrd.c:93: error: syntax error before "clientData"
tclrrd.c: In function `Rrd_Create':
tclrrd.c:103: error: `argc' undeclared (first use in this function)
tclrrd.c:103: error: (Each undeclared identifier is reported only once
tclrrd.c:103: error: for each function it appears in.)
tclrrd.c:103: error: `argv' undeclared (first use in this function)
tclrrd.c:108: warning: implicit declaration of function `Tcl_AppendResult'
tclrrd.c:108: warning: nested extern declaration of `Tcl_AppendResult'
tclrrd.c:108: error: `interp' undeclared (first use in this function)
tclrrd.c:111: error: `TCL_ERROR' undeclared (first use in this function)
tclrrd.c:114: warning: nested extern declaration of `Tcl_AppendResult'
tclrrd.c:121: warning: nested extern declaration of `Tcl_AppendResult'
tclrrd.c:128: warning: nested extern declaration of `Tcl_AppendResult'
tclrrd.c:137: warning: nested extern declaration of `Tcl_AppendResult'
tclrrd.c:144: warning: nested extern declaration of `Tcl_AppendResult'
tclrrd.c:156: warning: nested extern declaration of `Tcl_AppendResult'
tclrrd.c:166: warning: nested extern declaration of `Tcl_AppendResult'
tclrrd.c:172: warning: passing arg 5 of `rrd_create_r' from incompatible pointer type
tclrrd.c:177: warning: nested extern declaration of `Tcl_AppendResult'
tclrrd.c:183: error: `TCL_OK' undeclared (first use in this function)
tclrrd.c: At top level:
tclrrd.c:190: error: syntax error before "clientData"
tclrrd.c: In function `Rrd_Dump':
tclrrd.c:192: error: `argc' undeclared (first use in this function)
tclrrd.c:193: warning: nested extern declaration of `Tcl_AppendResult'
tclrrd.c:193: error: `interp' undeclared (first use in this function)
tclrrd.c:195: error: `TCL_ERROR' undeclared (first use in this function)
tclrrd.c:198: error: `argv' undeclared (first use in this function)
tclrrd.c:203: warning: nested extern declaration of `Tcl_AppendResult'
tclrrd.c:209: error: `TCL_OK' undeclared (first use in this function)
tclrrd.c: At top level:
tclrrd.c:216: error: syntax error before "clientData"
tclrrd.c: In function `Rrd_Last':
tclrrd.c:220: error: `argc' undeclared (first use in this function)
tclrrd.c:221: warning: nested extern declaration of `Tcl_AppendResult'
tclrrd.c:221: error: `interp' undeclared (first use in this function)
tclrrd.c:223: error: `TCL_ERROR' undeclared (first use in this function)
tclrrd.c:226: error: `argv' undeclared (first use in this function)
tclrrd.c:229: warning: nested extern declaration of `Tcl_AppendResult'
tclrrd.c:235: warning: implicit declaration of function `Tcl_SetIntObj'
tclrrd.c:235: warning: nested extern declaration of `Tcl_SetIntObj'
tclrrd.c:235: warning: implicit declaration of function `Tcl_GetObjResult'
tclrrd.c:235: warning: nested extern declaration of `Tcl_GetObjResult'
tclrrd.c:237: error: `TCL_OK' undeclared (first use in this function)
tclrrd.c: At top level:
tclrrd.c:244: error: syntax error before "clientData"
tclrrd.c: In function `Rrd_Update':
tclrrd.c:249: error: `argc' undeclared (first use in this function)
tclrrd.c:249: error: `argv' undeclared (first use in this function)
tclrrd.c:254: warning: nested extern declaration of `Tcl_AppendResult'
tclrrd.c:254: error: `interp' undeclared (first use in this function)
tclrrd.c:260: error: `TCL_ERROR' undeclared (first use in this function)
tclrrd.c:272: warning: nested extern declaration of `Tcl_AppendResult'
tclrrd.c:285: warning: nested extern declaration of `Tcl_AppendResult'
tclrrd.c:294: warning: passing arg 4 of `rrd_update_r' from incompatible pointer type
tclrrd.c:302: warning: nested extern declaration of `Tcl_AppendResult'
tclrrd.c:308: error: `TCL_OK' undeclared (first use in this function)
tclrrd.c: At top level:
tclrrd.c:312: error: syntax error before "clientData"
tclrrd.c: In function `Rrd_Lastupdate':
tclrrd.c:319: error: `Tcl_Obj' undeclared (first use in this function)
tclrrd.c:319: error: `listPtr' undeclared (first use in this function)
tclrrd.c:322: error: `argc' undeclared (first use in this function)
tclrrd.c:322: error: `argv' undeclared (first use in this function)
tclrrd.c:325: warning: nested extern declaration of `Tcl_GetObjResult'
tclrrd.c:325: error: `interp' undeclared (first use in this function)
tclrrd.c:328: warning: implicit declaration of function `Tcl_ListObjAppendElement'
tclrrd.c:328: warning: nested extern declaration of `Tcl_ListObjAppendElement'
tclrrd.c:329: warning: implicit declaration of function `Tcl_NewStringObj'
tclrrd.c:329: warning: nested extern declaration of `Tcl_NewStringObj'
tclrrd.c:347: error: `TCL_OK' undeclared (first use in this function)
tclrrd.c: At top level:
tclrrd.c:351: error: syntax error before "clientData"
tclrrd.c: In function `Rrd_Fetch':
tclrrd.c:357: error: `Tcl_Obj' undeclared (first use in this function)
tclrrd.c:357: error: `listPtr' undeclared (first use in this function)
tclrrd.c:361: error: `argc' undeclared (first use in this function)
tclrrd.c:361: error: `argv' undeclared (first use in this function)
tclrrd.c:365: warning: nested extern declaration of `Tcl_GetObjResult'
tclrrd.c:365: error: `interp' undeclared (first use in this function)
tclrrd.c:369: warning: nested extern declaration of `Tcl_ListObjAppendElement'
tclrrd.c:370: warning: nested extern declaration of `Tcl_NewStringObj'
tclrrd.c:380: warning: nested extern declaration of `Tcl_AppendResult'
tclrrd.c:383: error: `TCL_ERROR' undeclared (first use in this function)
tclrrd.c:386: error: `TCL_OK' undeclared (first use in this function)
tclrrd.c: At top level:
tclrrd.c:392: error: syntax error before "clientData"
tclrrd.c: In function `Rrd_Graph':
tclrrd.c:394: error: `Tcl_Channel' undeclared (first use in this function)
tclrrd.c:394: error: syntax error before "channel"
tclrrd.c:396: error: `ClientData' undeclared (first use in this function)
tclrrd.c:396: error: syntax error before "fd1"
tclrrd.c:409: error: `channel' undeclared (first use in this function)
tclrrd.c:409: warning: implicit declaration of function `Tcl_GetChannel'
tclrrd.c:409: warning: nested extern declaration of `Tcl_GetChannel'
tclrrd.c:409: error: `interp' undeclared (first use in this function)
tclrrd.c:409: error: `argv' undeclared (first use in this function)
tclrrd.c:413: error: `TCL_WRITABLE' undeclared (first use in this function)
tclrrd.c:414: warning: nested extern declaration of `Tcl_AppendResult'
tclrrd.c:416: error: `TCL_ERROR' undeclared (first use in this function)
tclrrd.c:422: warning: implicit declaration of function `Tcl_Flush'
tclrrd.c:422: warning: nested extern declaration of `Tcl_Flush'
tclrrd.c:422: error: `TCL_OK' undeclared (first use in this function)
tclrrd.c:423: warning: nested extern declaration of `Tcl_AppendResult'
tclrrd.c:424: warning: implicit declaration of function `Tcl_GetErrno'
tclrrd.c:424: warning: nested extern declaration of `Tcl_GetErrno'
tclrrd.c:427: warning: implicit declaration of function `Tcl_GetChannelHandle'
tclrrd.c:427: warning: nested extern declaration of `Tcl_GetChannelHandle'
tclrrd.c:427: error: `fd1' undeclared (first use in this function)
tclrrd.c:428: warning: nested extern declaration of `Tcl_AppendResult'
tclrrd.c:437: warning: nested extern declaration of `Tcl_AppendResult'
tclrrd.c:445: warning: nested extern declaration of `Tcl_AppendResult'
tclrrd.c:453: error: `argc' undeclared (first use in this function)
tclrrd.c:456: warning: implicit declaration of function `Tcl_ResetResult'
tclrrd.c:456: warning: nested extern declaration of `Tcl_ResetResult'
tclrrd.c:468: warning: nested extern declaration of `Tcl_AppendResult'
tclrrd.c:483: warning: nested extern declaration of `Tcl_AppendResult'
tclrrd.c: At top level:
tclrrd.c:495: error: syntax error before "clientData"
tclrrd.c: In function `Rrd_Tune':
tclrrd.c:499: error: `argc' undeclared (first use in this function)
tclrrd.c:499: error: `argv' undeclared (first use in this function)
tclrrd.c:504: warning: nested extern declaration of `Tcl_AppendResult'
tclrrd.c:504: error: `interp' undeclared (first use in this function)
tclrrd.c:507: error: `TCL_ERROR' undeclared (first use in this function)
tclrrd.c:510: error: `TCL_OK' undeclared (first use in this function)
tclrrd.c: At top level:
tclrrd.c:516: error: syntax error before "clientData"
tclrrd.c: In function `Rrd_Resize':
tclrrd.c:520: error: `argc' undeclared (first use in this function)
tclrrd.c:520: error: `argv' undeclared (first use in this function)
tclrrd.c:525: warning: nested extern declaration of `Tcl_AppendResult'
tclrrd.c:525: error: `interp' undeclared (first use in this function)
tclrrd.c:528: error: `TCL_ERROR' undeclared (first use in this function)
tclrrd.c:531: error: `TCL_OK' undeclared (first use in this function)
tclrrd.c: At top level:
tclrrd.c:537: error: syntax error before "clientData"
tclrrd.c: In function `Rrd_Restore':
tclrrd.c:541: error: `argc' undeclared (first use in this function)
tclrrd.c:541: error: `argv' undeclared (first use in this function)
tclrrd.c:546: warning: nested extern declaration of `Tcl_AppendResult'
tclrrd.c:546: error: `interp' undeclared (first use in this function)
tclrrd.c:549: error: `TCL_ERROR' undeclared (first use in this function)
tclrrd.c:552: error: `TCL_OK' undeclared (first use in this function)
tclrrd.c: At top level:
tclrrd.c:563: error: syntax error before "Tcl_CmdProc"
tclrrd.c:563: warning: no semicolon at end of struct or union
tclrrd.c:565: error: syntax error before '}' token
tclrrd.c:565: warning: type defaults to `int' in declaration of `CmdInfo'
tclrrd.c:565: error: ISO C forbids data definition with no type or storage classtclrrd.c:567: error: syntax error before "rrdCmds"
tclrrd.c:567: warning: type defaults to `int' in declaration of `rrdCmds'
tclrrd.c:568: warning: braces around scalar initializer
tclrrd.c:568: warning: (near initialization for `rrdCmds[0]')
tclrrd.c:568: warning: initialization makes integer from pointer without a cast
tclrrd.c:568: warning: excess elements in scalar initializer
tclrrd.c:568: warning: (near initialization for `rrdCmds[0]')
tclrrd.c:568: warning: excess elements in scalar initializer
tclrrd.c:568: warning: (near initialization for `rrdCmds[0]')
tclrrd.c:569: warning: braces around scalar initializer
tclrrd.c:569: warning: (near initialization for `rrdCmds[1]')
tclrrd.c:569: warning: initialization makes integer from pointer without a cast
tclrrd.c:569: warning: excess elements in scalar initializer
tclrrd.c:569: warning: (near initialization for `rrdCmds[1]')
tclrrd.c:569: warning: excess elements in scalar initializer
tclrrd.c:569: warning: (near initialization for `rrdCmds[1]')
tclrrd.c:570: warning: braces around scalar initializer
tclrrd.c:570: warning: (near initialization for `rrdCmds[2]')
tclrrd.c:570: warning: initialization makes integer from pointer without a cast
tclrrd.c:570: warning: excess elements in scalar initializer
tclrrd.c:570: warning: (near initialization for `rrdCmds[2]')
tclrrd.c:570: warning: excess elements in scalar initializer
tclrrd.c:570: warning: (near initialization for `rrdCmds[2]')
tclrrd.c:571: warning: braces around scalar initializer
tclrrd.c:571: warning: (near initialization for `rrdCmds[3]')
tclrrd.c:571: warning: initialization makes integer from pointer without a cast
tclrrd.c:571: warning: excess elements in scalar initializer
tclrrd.c:571: warning: (near initialization for `rrdCmds[3]')
tclrrd.c:571: warning: excess elements in scalar initializer
tclrrd.c:571: warning: (near initialization for `rrdCmds[3]')
tclrrd.c:572: warning: braces around scalar initializer
tclrrd.c:572: warning: (near initialization for `rrdCmds[4]')
tclrrd.c:572: warning: initialization makes integer from pointer without a cast
tclrrd.c:572: warning: excess elements in scalar initializer
tclrrd.c:572: warning: (near initialization for `rrdCmds[4]')
tclrrd.c:572: warning: excess elements in scalar initializer
tclrrd.c:572: warning: (near initialization for `rrdCmds[4]')
tclrrd.c:573: warning: braces around scalar initializer
tclrrd.c:573: warning: (near initialization for `rrdCmds[5]')
tclrrd.c:573: warning: initialization makes integer from pointer without a cast
tclrrd.c:573: warning: excess elements in scalar initializer
tclrrd.c:573: warning: (near initialization for `rrdCmds[5]')
tclrrd.c:573: warning: excess elements in scalar initializer
tclrrd.c:573: warning: (near initialization for `rrdCmds[5]')
tclrrd.c:574: warning: braces around scalar initializer
tclrrd.c:574: warning: (near initialization for `rrdCmds[6]')
tclrrd.c:574: warning: initialization makes integer from pointer without a cast
tclrrd.c:574: warning: excess elements in scalar initializer
tclrrd.c:574: warning: (near initialization for `rrdCmds[6]')
tclrrd.c:574: warning: excess elements in scalar initializer
tclrrd.c:574: warning: (near initialization for `rrdCmds[6]')
tclrrd.c:579: warning: braces around scalar initializer
tclrrd.c:579: warning: (near initialization for `rrdCmds[7]')
tclrrd.c:579: warning: initialization makes integer from pointer without a cast
tclrrd.c:579: warning: excess elements in scalar initializer
tclrrd.c:579: warning: (near initialization for `rrdCmds[7]')
tclrrd.c:579: warning: excess elements in scalar initializer
tclrrd.c:579: warning: (near initialization for `rrdCmds[7]')
tclrrd.c:580: warning: braces around scalar initializer
tclrrd.c:580: warning: (near initialization for `rrdCmds[8]')
tclrrd.c:580: warning: initialization makes integer from pointer without a cast
tclrrd.c:580: warning: excess elements in scalar initializer
tclrrd.c:580: warning: (near initialization for `rrdCmds[8]')
tclrrd.c:580: warning: excess elements in scalar initializer
tclrrd.c:580: warning: (near initialization for `rrdCmds[8]')
tclrrd.c:581: warning: braces around scalar initializer
tclrrd.c:581: warning: (near initialization for `rrdCmds[9]')
tclrrd.c:581: warning: initialization makes integer from pointer without a cast
tclrrd.c:581: warning: excess elements in scalar initializer
tclrrd.c:581: warning: (near initialization for `rrdCmds[9]')
tclrrd.c:581: warning: excess elements in scalar initializer
tclrrd.c:581: warning: (near initialization for `rrdCmds[9]')
tclrrd.c:582: warning: braces around scalar initializer
tclrrd.c:582: warning: (near initialization for `rrdCmds[10]')
tclrrd.c:582: warning: initialization makes integer from pointer without a cast
tclrrd.c:582: error: `Tcl_CmdProc' undeclared here (not in a function)
tclrrd.c:582: error: syntax error before ')' token
tclrrd.c:582: warning: excess elements in scalar initializer
tclrrd.c:582: warning: (near initialization for `rrdCmds[10]')
tclrrd.c:582: warning: excess elements in scalar initializer
tclrrd.c:582: warning: (near initialization for `rrdCmds[10]')
tclrrd.c:583: error: ISO C forbids data definition with no type or storage classtclrrd.c:588: error: syntax error before '*' token
tclrrd.c: In function `init':
tclrrd.c:590: error: `cmdInfoPtr' undeclared (first use in this function)
tclrrd.c:591: error: `Tcl_CmdInfo' undeclared (first use in this function)
tclrrd.c:591: error: syntax error before "info"
tclrrd.c:593: warning: implicit declaration of function `Tcl_InitStubs'
tclrrd.c:593: warning: nested extern declaration of `Tcl_InitStubs'
tclrrd.c:593: error: `interp' undeclared (first use in this function)
tclrrd.c:593: error: `TCL_VERSION' undeclared (first use in this function)
tclrrd.c:593: warning: comparison between pointer and integer
tclrrd.c:594: error: `TCL_ERROR' undeclared (first use in this function)
tclrrd.c:596: warning: implicit declaration of function `Tcl_PkgRequire'
tclrrd.c:596: warning: nested extern declaration of `Tcl_PkgRequire'
tclrrd.c:596: warning: comparison between pointer and integer
tclrrd.c:604: warning: implicit declaration of function `Tcl_SetVar2'
tclrrd.c:604: warning: nested extern declaration of `Tcl_SetVar2'
tclrrd.c:604: error: `TCL_GLOBAL_ONLY' undeclared (first use in this function)
tclrrd.c:612: warning: implicit declaration of function `Tcl_GetCommandInfo'
tclrrd.c:612: warning: nested extern declaration of `Tcl_GetCommandInfo'
tclrrd.c:612: error: `info' undeclared (first use in this function)
tclrrd.c:613: warning: nested extern declaration of `Tcl_AppendResult'
tclrrd.c:617: error: `safe' undeclared (first use in this function)
tclrrd.c:651: warning: implicit declaration of function `Tcl_CreateCommand'
tclrrd.c:651: warning: nested extern declaration of `Tcl_CreateCommand'
tclrrd.c:652: error: `ClientData' undeclared (first use in this function)
tclrrd.c:652: error: `Tcl_CmdDeleteProc' undeclared (first use in this function)tclrrd.c:652: error: syntax error before ')' token
tclrrd.c:655: warning: implicit declaration of function `Tcl_PkgProvide'
tclrrd.c:655: warning: nested extern declaration of `Tcl_PkgProvide'
tclrrd.c:655: error: `TCL_OK' undeclared (first use in this function)
tclrrd.c: At top level:
tclrrd.c:663: error: syntax error before '*' token
tclrrd.c:664: warning: no previous prototype for 'Tclrrd_Init'
tclrrd.c: In function `Tclrrd_Init':
tclrrd.c:665: error: `interp' undeclared (first use in this function)
tclrrd.c: At top level:
tclrrd.c:674: error: syntax error before '*' token
tclrrd.c:675: warning: no previous prototype for 'Tclrrd_SafeInit'
tclrrd.c: In function `Tclrrd_SafeInit':
tclrrd.c:676: error: `interp' undeclared (first use in this function)
make[3]: *** [tclrrd.o] 错误 1
make[3]: Leaving directory `/tmp/rrdbuild/rrdtool-1.2.23/bindings/tcl'
make[2]: *** [all-recursive] 错误 1
make[2]: Leaving directory `/tmp/rrdbuild/rrdtool-1.2.23/bindings'
make[1]: *** [all-recursive] 错误 1
make[1]: Leaving directory `/tmp/rrdbuild/rrdtool-1.2.23'
make: *** [all] 错误 2

marion 回复于:2007-11-21 11:38:42

安装tcl和tcl-devel了吗?

hackerzyh 回复于:2007-11-21 12:29:14

引用:原帖由 marion 于 2007-11-21 11:38 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=7617204&ptid=987344
安装tcl和tcl-devel了吗?



我是把你的贴子复制下来安装的,结果你的那行“注意”搞掉了,又去仔细看了一下帖子才发现,原来是没安装那些必要程序,非常谢谢!!!!




unixorg 回复于:2007-11-21 16:55:59

outlook里面的用户为什么要设置成为user@domain.lmd ,才能够正常收发。

设置为user 就不行了呢。假如我想设置为user,该如何设置我的配置文件。

hackerzyh 回复于:2007-11-21 19:30:22

[root@ext ~]# telnet localhost 10024
Trying 127.0.0.1...
Connected to localhost.localdomain (127.0.0.1).
Escape character is '^]'.
220 [127.0.0.1] ESMTP amavisd-new service ready
HELO localhost
250 [127.0.0.1]
MAIL FROM:<>
250 2.1.0 Sender <> OK
RCPT TO:<mos>
250 2.1.5 Recipient <mos> OK
DATA
354 End data with <CR><LF>.<CR><LF>
rom:Anti-Virus tester
To: MailServer Admin
Subject:amavisd test!
amavisd test!!

.
451 4.5.0 Error in processing, id=03479-01, virus_scan FAILED: virus_scan: ALL VIRUS SCANNERS FAILED: ClamAV-clamd av-scanner FAI LED: CODE(0xa02ade8) Too many retries to talk to :/var/run/clamav/clamd.socket (Can't connect to INET socket :/var/run/clamav/cla md.socket: \346\227\240\346\225\210\347\232\204\345\217\202\346\225\260) at (eval 53) line 310. at (eval 53) line 511.
quit
221 2.0.0 [127.0.0.1] amavisd-new closing transmission channel
Connection closed by foreign host.


为什么测试无法通过,请老大帮忙
ps 他们,没有不正常运行

virus_scan
virus_scan
SCANNERS
ClamAV-clamd
av-scanner

[ 本帖最后由 hackerzyh 于 2007-11-21 19:36 编辑 ]

hackerzyh 回复于:2007-11-21 22:21:41

已经按照marion兄的贴子安装完了,不过无法提供邮件服务功能,
服务器启动后,maillog的日志,现在的问题是无论是网页和Evolution都无法发送邮件,366楼的也是我的问题,我感觉这两个问题是有联系,请marion兄帮忙,焦急等待中!............................................



............................................................................................................
................................................................
Nov 21 22:50:04 ext clamd[2229]: Self checking every 1800 seconds.
Nov 21 22:50:17 ext spamd[2511]: logger: removing stderr method
Nov 21 22:50:17 ext postfix/postfix-script[2515]: fatal: usage: postfix start (or stop, reload, abort, flush, check, set-permissions, upgrade-configuration)
Nov 21 22:50:18 ext spamd[2516]: server socket setup failed, retry 1: spamd: could not create INET socket on 127.0.0.1:783: 地址已在使用
Nov 21 22:50:19 ext spamd[2513]: rules: meta test FM_DDDD_TIMES_2 has dependency 'FH_HOST_EQ_D_D_D_D' with a zero score
Nov 21 22:50:19 ext spamd[2513]: rules: meta test FM_SEX_HOSTDDDD has dependency 'FH_HOST_EQ_D_D_D_D' with a zero score
Nov 21 22:50:19 ext spamd[2513]: rules: meta test HS_PHARMA_1 has dependency 'HS_SUBJ_ONLINE_PHARMACEUTICAL' with a zero score
Nov 21 22:50:19 ext spamd[2513]: spamd: server started on port 783/tcp (running version 3.2.3)
Nov 21 22:50:19 ext spamd[2513]: spamd: server pid: 2513
Nov 21 22:50:19 ext spamd[2513]: spamd: server successfully spawned child process, pid 2518
Nov 21 22:50:19 ext spamd[2513]: spamd: server successfully spawned child process, pid 2519
Nov 21 22:50:19 ext spamd[2513]: prefork: child states: II
Nov 21 22:50:19 ext spamd[2516]: server socket setup failed, retry 2: spamd: could not create INET socket on 127.0.0.1:783: 地址已在使用
Nov 21 22:50:20 ext spamd[2516]: spamd: could not create INET socket on 127.0.0.1:783: 地址已在使用

marion 回复于:2007-11-22 12:20:40

这个并非是OE本身决定的;

我们为postfix配置了虚拟域,如果当两个域中的用户名称相同时如何区别他们?

marion 回复于:2007-11-22 12:22:56

错误报告已经说的相当清楚了。

莫非是想让我帮你配置?

hackerzyh 回复于:2007-11-22 13:28:59

老大给我开玩笑了,我不知道如何从 那里开始修改,请指点,

[ 本帖最后由 hackerzyh 于 2007-11-22 13:31 编辑 ]

s001 回复于:2007-11-22 17:30:34

引用:原帖由 marion 于 2007-11-20 12:28 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=7612500&ptid=987344


这个只需要将mysql的bin目录输出至$PATH即可,方法如下:
export PATH=$PATH:/usr/local/mysql/bin


谢谢楼主的回复。您所说的这一条我已经加入了$PATH中,但是还是不行。

现在我卡在了500 Internal server error 处,在error_log中出现的告警是:

Premature end of script headers: index.cgi

而在suexec_log中告警信息是

uid: (2525/postfix) gid: (2525/2525) cmd: index.cgi

command not in docroot (/var/www/extsuite/extmail/cgi/index.cgi)

请楼主指点一二,原因出在什么地方。

hackerzyh 回复于:2007-11-23 09:42:20

postfix能发不能收,看了一下日志,发现用户无法登录,这个是虚用户的,请老大帮忙看看怎么解决?

09:55:01 ext pop3d: Connection, ip=[58.252.61.25]
Nov 23 09:55:01 ext pop3d: LOGIN FAILED, user=kingmos, ip=[58.252.61.25]
Nov 23 09:55:06 ext pop3d: Disconnected, ip=[58.252.61.25]

[ 本帖最后由 hackerzyh 于 2007-11-23 09:51 编辑 ]

marion 回复于:2007-11-23 09:55:47

打开courier-authlib的日志,而后重新登录收信一次,然后发上来相关的日志。

jxg945 回复于:2007-11-23 11:05:08

marion兄 您好!
我按照您帖子,在ubuntu下架设,除了 Extmail-1.0.2 和Extman-0.2.2 是用源码包安装的其他都是用apt-get install 安装的.
目前 我遇到的问题 同34页 yecheng_110 遇到的一样

Nov 23 10:59:47 mail postfix/trivial-rewrite[9828]: warning: connect to mysql server localhost: Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (2)
Nov 23 10:59:47 mail postfix/trivial-rewrite[9828]: fatal: mysql:/etc/postfix/mysql_virtual_domains_maps.cf(0,lock|fold_fix): table lookup problem



root@mail:~# cat /etc/postfix/mysql_virtual_domains_maps.cf
user = extmail
password = extmail
hosts = localhost
dbname = extmail
table = domain
select_field = description
where_field = domain
root@mail:~#
root@mail:~#
root@mail:~# mysql -uextmail -pextmail
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 7
Server version: 5.0.38-Ubuntu_0ubuntu1.1-log Ubuntu 7.04 distribution

Type 'help;' or '\h' for help. Type '\c' to clear the buffer.

mysql>

这是为什么阿,请指点小弟.万分感谢

hackerzyh 回复于:2007-11-23 11:39:54

清除maillog, restart , 收发邮件, 日志如下,
如果不是所要的日志,请指出couirer-autolib日志存路径(根据couirer.conf的Logfile maillog我判断的是maillog)


Nov 23 12:48:28 ext authdaemond: modules="authmysql", daemons=10
Nov 23 12:48:28 ext authdaemond: Installing libauthmysql
Nov 23 12:48:29 ext authdaemond: Installation complete: authmysql
Nov 23 12:53:14 ext postfix/postfix-script[3278]: starting the Postfix mail system
Nov 23 12:53:14 ext postfix/master[3279]: daemon started -- version 2.4.5, configuration /etc/postfix
Nov 23 12:58:03 ext pop3d: Connection, ip=[192.168.0.49]
Nov 23 12:58:04 ext pop3d: LOGIN FAILED, user=root, ip=[192.168.0.49]
Nov 23 12:58:09 ext pop3d: LOGOUT, ip=[192.168.0.49]
Nov 23 12:58:09 ext pop3d: Disconnected, ip=[192.168.0.49]

[ 本帖最后由 hackerzyh 于 2007-11-23 12:32 编辑 ]

hackerzyh 回复于:2007-11-23 13:02:55

marion兄 能不能每天上午和下午都在半个小时回答我们的问题,盼望ING!

s001 回复于:2007-11-23 16:24:01

费了半天劲,终于解决了command no in docroot错误。

在装httpd-2.2.6时带参数 --with-suexec-docroot=/var/www即可

marion 回复于:2007-11-23 20:52:49

是maillog日志,但你应该使用一不能正常收信的用户进行登录收信,而后将其中相关的日志发上来!

marion 回复于:2007-11-23 20:55:48

引用:……Nov 23 10:59:47 mail postfix/trivial-rewrite[9828]: warning: connect to mysql server localhost: Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (2)
Nov 23 10:59:47 mail postfix/trivial-rewrite[9828]: fatal: mysql:/etc/postfix/mysql_virtual_domains_maps.cf(0,lock|fold_fix): table lookup problem
……


错误差不多已经言明:
1、检查你的mysql的sock文件的位置是否正确;
2、查看一下hosts文件,是不是有localhost指向本地主机;如果没有,请加之;或者将下面一段中
引用::~# cat /etc/postfix/mysql_virtual_domains_maps.cf
user = extmail
password = extmail
hosts = localhost
dbname = extmail
table = domain
select_field = description
where_field = domain


的hosts值指向127.0.0.1

marion 回复于:2007-11-23 20:57:26

祝贺你!

同时,请你把你所遇到的问题及解决办法在一个帖子中详细描述一下,以便后来人参考!

hackerzyh 回复于:2007-11-23 21:51:57

引用:原帖由 marion 于 2007-11-23 20:52 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=7631787&ptid=987344
是maillog日志,但你应该使用一不能正常收信的用户进行登录收信,而后将其中相关的日志发上来!




Nov 23 12:48:28 ext authdaemond: modules="authmysql", daemons=10
Nov 23 12:48:28 ext authdaemond: Installing libauthmysql
Nov 23 12:48:29 ext authdaemond: Installation complete: authmysql
Nov 23 12:53:14 ext postfix/postfix-script[3278]: starting the Postfix mail system
Nov 23 12:53:14 ext postfix/master[3279]: daemon started -- version 2.4.5, configuration /etc/postfix
Nov 23 12:58:03 ext pop3d: Connection, ip=[192.168.0.49]
Nov 23 12:58:04 ext pop3d: LOGIN FAILED, user=mos, ip=[192.168.0.49]
Nov 23 12:58:09 ext pop3d: LOGOUT, ip=[192.168.0.49]
Nov 23 12:58:09 ext pop3d: Disconnected, ip=[192.168.0.49]

如上就是,无论user=mos或者是user=mos@kingjava.vicp.net都不能进行pop登陆收信,而且我所有建立的虚用户和本机的用户都不能登陆收信,仅可以发邮件



补充,我的maildrop买有安装,只是装到了extman这里

[ 本帖最后由 hackerzyh 于 2007-11-23 22:14 编辑 ]

marion 回复于:2007-11-24 09:31:06

打开couier-authlib的日志!!重启相关服务,而后再登录,再看日志!

wlacf 回复于:2007-11-24 15:01:43

请问一下,出现如下错误应该如何解决:
引用:[root@mail courier-authlib-0.59.3]# /usr/local/sasl2/sbin/saslauthd -a shadow pam -d
saslauthd[9376] :main : num_procs : 5
saslauthd[9376] :main : mech_option: NULL
saslauthd[9376] :main : run_path : /var/state/saslauthd
saslauthd[9376] :main : auth_mech : shadow
saslauthd[9376] :main : could not chdir to: /var/state/saslauthd
saslauthd[9376] :main : chdir: No such file or directory
saslauthd[9376] :main : Check to make sure the directory exists and is
saslauthd[9376] :main : writeable by the user this process runs as.
[root@mail courier-authlib-0.59.3]#



惨啊,第三步还没过。谢谢了。

很抱歉,原来是创建目录时使用了[root@mail cyrus-sasl-2.1.22]# mkdir -pv /var/state/saslahthd
正确的是# mkdir -pv /var/state/saslauthd


.

[ 本帖最后由 wlacf 于 2007-11-24 16:48 编辑 ]

hackerzyh 回复于:2007-11-24 21:05:48

引用:原帖由 marion 于 2007-11-24 09:31 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=7632377&ptid=987344
打开couier-authlib的日志!!重启相关服务,而后再登录,再看日志!



Nov 24 21:03:29 ext authdaemond: stopping authdaemond children
Nov 24 21:03:29 ext authdaemond: modules="authmysql", daemons=10
Nov 24 21:03:29 ext authdaemond: Installing libauthmysql
Nov 24 21:03:29 ext authdaemond: Installation complete: authmysql

Nov 24 21:06:49 ext pop3d: Connection, ip=[192.168.0.49]
Nov 24 21:06:49 ext pop3d: LOGIN FAILED, user=root@kingjava.vicp.net, ip=[192.168.0.49]
Nov 24 21:06:54 ext pop3d: LOGOUT, ip=[192.168.0.49]
Nov 24 21:06:54 ext pop3d: Disconnected, ip=[192.168.0.49]


重启服务后,日志记录,红色字体为重启记录,另外为登录记录,依然

[ 本帖最后由 hackerzyh 于 2007-11-24 21:08 编辑 ]

hackerzyh 回复于:2007-11-24 22:12:14

谢谢你,marion,给我的启发,
问题已经解决
Nov 24 21:23:55 ext postfix/trivial-rewrite[3730]: warning: do not list domain kingjava.vicp.net in BOTH mydestination and virtual_mailbox_domains
问题就处在这里面.以前没发现这个错误,我注释掉了mydestination 就可以用user@domain.com登录收邮件了.不过不知道对其他人的问题有没有帮助,而且也不知道这样对后面安装是不是会有影响。请问marion你的有没有注释掉那?我的配置过程是基本完全和你的一样的

[ 本帖最后由 hackerzyh 于 2007-11-25 10:51 编辑 ]

lanfox2006 回复于:2007-11-24 23:15:24

应该是不错的,楼主是北大青鸟的吧?

marion 回复于:2007-11-25 13:21:04

这个问题在前面的帖子中已有多次讨论,你可能没有注意到。

本地域和虚拟域不能相同,注释掉也可以达到目的,仅此而已。

yh81521 回复于:2007-11-25 20:05:05

楼主,我的现在已经能在内网收发邮件了.
但是拿到外网后,收信正常,web发信提示helo出错,需要FQDN,显示:

Command parameter not implemented
服务器反馈信息:504 <***.***.**.**>: Helo command rejected: need fully-qualified hostname

foxmail发信提示:

The server reply:
504 <YANGHUI>: Helo command rejected: need fully-qualified hostname
Continue?


/etc/hosts配置:
127.0.0.1 localhost.localdomain localhost
192.168.3.1 mail.hxrxx.cn mail //服务器ip,在DMZ区,通过PIX转换成公网IP.
219.239.**.** mail.hxrxx.cn mail //公网ip

main.cf配置:
myhostname = mail.hxrxx.cn
mydomain = hxrxx.cn
myorigin = $mydomain
mydestination = $myhostname localhost localhost.$mydomain
mynetworks = 192.168.3.0/24 192.168.0.0/24
inet_interfaces = all

命令hostname结果:
mail.hxrxx.cn
命令domainname结果
(none)
命令domainname -f 结果
mail.hxrxx.cn

不知道还有什么地方不对???要改什么呢?
这个错误应该是服务器的HELO信息不是完整的域名,但是怎么更改服务器的helo信息呢,helo信息是调用那个配置文件呢?

[ 本帖最后由 yh81521 于 2007-11-25 22:08 编辑 ]
截图_2025-11-15_15-07-16.jpg
截图_2025-11-15_15-07-16.jpg (25.19 KiB) 查看 864 次
yh81521 回复于:2007-11-25 22:13:43

楼主真是青鸟的吗?你是那个的方的青鸟的呢?
我对青鸟有点失望,在那学了1年,现在回去问关于postfix的问题,在航天桥和公主坟2个青鸟都没有老师能够解答postfix的问题,说是没有用过啊......
郁闷...............

marion 回复于:2007-11-26 11:57:45

你应该把信件发出错误后/var/log/maillog中相关的日志发上来!

[ 本帖最后由 marion 于 2007-11-26 12:01 编辑 ]

MYSQLER 回复于:2007-11-26 16:59:47

安装完后..extmail可以正常打开..但是extman不可以打开.下面是错误日志


[Mon Nov 26 16:24:33 2007] [error] [client 192.168.1.2] /usr/bin/perl: symbol lookup error: /usr/lib/perl5/site_perl/5.8.5/i386-linux-thread-multi/auto/DBD/mysql/mysql.so: undefined symbol: DBIc_TRACE_LEVEL

[Mon Nov 26 16:24:33 2007] [error] [client 192.168.1.2] Premature end of script headers: index.cgi

[Mon Nov 26 16:24:44 2007] [error] [client 192.168.1.2] /usr/bin/perl: symbol lookup error: /usr/lib/perl5/site_perl/5.8.5/i386-linux-thread-multi/auto/DBD/mysql/mysql.so: undefined symbol: DBIc_TRACE_LEVEL

[Mon Nov 26 16:24:44 2007] [error] [client 192.168.1.2] Premature end of script headers: index.cgi

[Mon Nov 26 16:28:03 2007] [error] [client 192.168.1.2] /usr/bin/perl: symbol lookup error: /usr/lib/perl5/site_perl/5.8.5/i386-linux-thread-multi/auto/DBD/mysql/mysql.so: undefined symbol: DBIc_TRACE_LEVEL

[Mon Nov 26 16:28:03 2007] [error] [client 192.168.1.2] Premature end of script headers: index.cgi

[Mon Nov 26 16:28:05 2007] [error] [client 192.168.1.2] /usr/bin/perl: symbol lookup error: /usr/lib/perl5/site_perl/5.8.5/i386-linux-thread-multi/auto/DBD/mysql/mysql.so: undefined symbol: DBIc_TRACE_LEVEL

[Mon Nov 26 16:28:05 2007] [error] [client 192.168.1.2] Premature end of script headers: index.cgi

[Mon Nov 26 16:28:05 2007] [error] [client 192.168.1.2] /usr/bin/perl: symbol lookup error: /usr/lib/perl5/site_perl/5.8.5/i386-linux-thread-multi/auto/DBD/mysql/mysql.so: undefined symbol: DBIc_TRACE_LEVEL

[Mon Nov 26 16:28:05 2007] [error] [client 192.168.1.2] Premature end of script headers: index.cgi

[Mon Nov 26 16:28:19 2007] [error] [client 192.168.1.2] /usr/bin/perl: symbol lookup error: /usr/lib/perl5/site_perl/5.8.5/i386-linux-thread-multi/auto/DBD/mysql/mysql.so: undefined symbol: DBIc_TRACE_LEVEL

[Mon Nov 26 16:28:19 2007] [error] [client 192.168.1.2] Premature end of script headers: index.cgi

[Mon Nov 26 16:28:30 2007] [error] [client 192.168.1.2] /usr/bin/perl: symbol lookup error: /usr/lib/perl5/site_perl/5.8.5/i386-linux-thread-multi/auto/DBD/mysql/mysql.so: undefined symbol: DBIc_TRACE_LEVEL, referer: http://mail.test.com:8001/extmail/cgi/index.cgi

[Mon Nov 26 16:28:30 2007] [error] [client 192.168.1.2] Premature end of script headers: index.cgi, referer: http://mail.test.com:8001/extmail/cgi/index.cgi

[Mon Nov 26 16:28:36 2007] [error] [client 192.168.1.2] /usr/bin/perl: symbol lookup error: /usr/lib/perl5/site_perl/5.8.5/i386-linux-thread-multi/auto/DBD/mysql/mysql.so: undefined symbol: DBIc_TRACE_LEVEL

[Mon Nov 26 16:28:36 2007] [error] [client 192.168.1.2] Premature end of script headers: signup.cgi

[Mon Nov 26 16:33:10 2007] [error] [client 192.168.1.2] /usr/bin/perl: symbol lookup error: /usr/lib/perl5/site_perl/5.8.5/i386-linux-thread-multi/auto/DBD/mysql/mysql.so: undefined symbol: DBIc_TRACE_LEVEL

[Mon Nov 26 16:33:10 2007] [error] [client 192.168.1.2] Premature end of script headers: index.cgi


yh81521 回复于:2007-11-26 17:35:49

引用:原帖由 marion 于 2007-11-26 11:57 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=7638496&ptid=987344
你应该把信件发出错误后/var/log/maillog中相关的日志发上来!



/var/log/maillog

Nov 25 23:02:34 mail postfix/anvil[21923]: statistics: max connection rate 2/60s for (smtp:210.192.169.228) at Nov 25 22:57:54
Nov 25 23:02:34 mail postfix/anvil[21923]: statistics: max connection count 2 for (smtp:210.192.169.228) at Nov 25 22:57:54
Nov 25 23:02:34 mail postfix/anvil[21923]: statistics: max cache size 1 at Nov 25 22:57:53
Nov 25 23:07:21 mail postfix/smtpd[22316]: warning: dict_nis_init: NIS domain name not set - NIS lookups disabled
Nov 25 23:07:21 mail postfix/smtpd[22316]: connect from unknown[89.223.38.166]
Nov 25 23:07:23 mail postfix/smtpd[22316]: NOQUEUE: reject: RCPT from unknown[89.223.38.166]: 504 <89.223.38.166>: Helo command rejected: need fully-qualified hostname; from=<eugene@my-deja.com> to=<dytang@hxrxx.cn> proto=SMTP helo=<89.223.38.166>
Nov 25 23:07:23 mail postfix/smtpd[22316]: lost connection after RCPT from unknown[89.223.38.166]

Nov 25 23:07:23 mail postfix/smtpd[22316]: disconnect from unknown[89.223.38.166]
Nov 25 23:09:27 mail postfix/smtpd[22407]: warning: dict_nis_init: NIS domain name not set - NIS lookups disabled
Nov 25 23:09:27 mail postfix/smtpd[22407]: connect from unknown[218.249.203.221]
Nov 25 23:09:27 mail postfix/smtpd[22407]: NOQUEUE: reject: RCPT from unknown[218.249.203.221]: 504 <YANGHUI>: Helo command rejected: need fully-qualified hostname; from=<hyang@hxrxx.cn> to=<yh81521@163.com> proto=SMTP helo=<YANGHUI>
Nov 25 23:09:27 mail postfix/smtpd[22407]: lost connection after RCPT from unknown[218.249.203.221]
Nov 25 23:09:27 mail postfix/smtpd[22407]: disconnect from unknown[218.249.203.221]
Nov 25 23:09:28 mail postfix/smtpd[22407]: connect from unknown[218.249.203.221]
Nov 25 23:09:28 mail postfix/smtpd[22407]: NOQUEUE: reject: RCPT from unknown[218.249.203.221]: 504 <YANGHUI>: Helo command rejected: need fully-qualified hostname; from=<hyang@hxrxx.cn> to=<yh81521@163.com> proto=SMTP helo=<YANGHUI>
Nov 25 23:09:30 mail postfix/smtpd[22407]: lost connection after RCPT from unknown[218.249.203.221]
Nov 25 23:09:30 mail postfix/smtpd[22407]: disconnect from unknown[218.249.203.221]
Nov 25 23:09:41 mail postfix/postfix-script: stopping the Postfix mail system


上面日志里 helo=<YANGHUI> 好像有问题.这个是我客户机的netbois的名,并不是邮件的用户名,应该怎么改???

[ 本帖最后由 yh81521 于 2007-11-28 13:40 编辑 ]

marion 回复于:2007-11-27 11:33:17

引用:……error: /usr/lib/perl5/site_perl/5.8.5/i386-linux-thread-multi/auto/DBD/mysql/mysql.so: undefined symbol: DBIc_TRACE_LEVEL……


尝试将mysql的头文件链接至/usr/include或者/usr/local/include或许可以解决此问题。

MYSQLER 回复于:2007-11-27 14:17:56

引用:原帖由 marion 于 2007-11-27 11:33 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=7643661&ptid=987344


尝试将mysql的头文件链接至/usr/include或者/usr/local/include或许可以解决此问题。




已经解决..不过不是没有链接的问题是..DBD版本有点高

yh81521 回复于:2007-11-27 14:55:00

楼主,我的现在已经能在内网收发邮件了.
但是拿到外网后,收信正常,web和foxmail发信提示helo出错,需要FQDN,显示:

web发信提示:
Command parameter not implemented
服务器反馈信息:504 <***.***.**.**>: Helo command rejected: need fully-qualified hostname

foxmail发信提示:

The server reply:
504 <YANGHUI>: Helo command rejected: need fully-qualified hostname
Continue?


/etc/hosts配置:
127.0.0.1 localhost.localdomain localhost
192.168.3.1 mail.hxrxx.cn mail //服务器ip,在DMZ区,通过PIX转换成公网IP.
219.239.**.** mail.hxrxx.cn mail //公网ip

main.cf配置:
myhostname = mail.hxrxx.cn
mydomain = hxrxx.cn
myorigin = $mydomain
mydestination = $myhostname localhost localhost.$mydomain
mynetworks = 192.168.3.0/24 192.168.0.0/24
inet_interfaces = all

命令hostname结果:
mail.hxrxx.cn
命令domainname结果
(none)
命令domainname -f 结果
mail.hxrxx.cn

/var/log/maillog

Nov 25 23:02:34 mail postfix/anvil[21923]: statistics: max connection rate 2/60s for (smtp:210.192.169.22 at Nov 25 22:57:54
Nov 25 23:02:34 mail postfix/anvil[21923]: statistics: max connection count 2 for (smtp:210.192.169.22 at Nov 25 22:57:54
Nov 25 23:02:34 mail postfix/anvil[21923]: statistics: max cache size 1 at Nov 25 22:57:53
Nov 25 23:07:21 mail postfix/smtpd[22316]: warning: dict_nis_init: NIS domain name not set - NIS lookups disabled
Nov 25 23:07:21 mail postfix/smtpd[22316]: connect from unknown[89.223.38.166]
Nov 25 23:07:23 mail postfix/smtpd[22316]: NOQUEUE: reject: RCPT from unknown[89.223.38.166]: 504 <89.223.38.166>: Helo command rejected: need fully-qualified hostname; from=<eugene@my-deja.com> to=<dytang@hxrxx.cn> proto=SMTP helo=<89.223.38.166>
Nov 25 23:07:23 mail postfix/smtpd[22316]: lost connection after RCPT from unknown[89.223.38.166]

Nov 25 23:07:23 mail postfix/smtpd[22316]: disconnect from unknown[89.223.38.166]
Nov 25 23:09:27 mail postfix/smtpd[22407]: warning: dict_nis_init: NIS domain name not set - NIS lookups disabled
Nov 25 23:09:27 mail postfix/smtpd[22407]: connect from unknown[218.249.203.221]
Nov 25 23:09:27 mail postfix/smtpd[22407]: NOQUEUE: reject: RCPT from unknown[218.249.203.221]: 504 <YANGHUI>: Helo command rejected: need fully-qualified hostname; from=<hyang@hxrxx.cn> to=<yh81521@163.com> proto=SMTP helo=<YANGHUI>
Nov 25 23:09:27 mail postfix/smtpd[22407]: lost connection after RCPT from unknown[218.249.203.221]
Nov 25 23:09:27 mail postfix/smtpd[22407]: disconnect from unknown[218.249.203.221]
Nov 25 23:09:28 mail postfix/smtpd[22407]: connect from unknown[218.249.203.221]
Nov 25 23:09:28 mail postfix/smtpd[22407]: NOQUEUE: reject: RCPT from unknown[218.249.203.221]: 504 <YANGHUI>: Helo command rejected: need fully-qualified hostname; from=<hyang@hxrxx.cn> to=<yh81521@163.com> proto=SMTP helo=<YANGHUI>
Nov 25 23:09:30 mail postfix/smtpd[22407]: lost connection after RCPT from unknown[218.249.203.221]
Nov 25 23:09:30 mail postfix/smtpd[22407]: disconnect from unknown[218.249.203.221]
Nov 25 23:09:41 mail postfix/postfix-script: stopping the Postfix mail system


上面日志里 helo=<YANGHUI> 好像有问题.这个是我客户机的netbois的名,并不是邮件的用户名,应该怎么改???

[ 本帖最后由 yh81521 于 2007-11-27 14:59 编辑 ]

marion 回复于:2007-11-27 17:00:20

尝试修改main.cf中的拒绝规则。

yh81521 回复于:2007-11-27 17:04:24

broken_sasl_auth_clients = yes
smtpd_recipient_restrictions =
permit_mynetworks,
permit_sasl_authenticated,
reject_invalid_hostname,
reject_non_fqdn_hostname,
reject_unknown_sender_domain,
reject_non_fqdn_sender,
reject_non_fqdn_recipient,
reject_unknown_recipient_domain,
reject_unauth_pipelining,
reject_unauth_destination,
reject_rbl_client cdlless.anti-spam.org.cn,
permit
smtpd_sasl_auth_enable = yes
smtpd_sasl_local_domain = $myhostname
smtpd_sasl_security_options = noanonymous
smtpd_sasl_application_name = smtpd
smtpd_banner=$myhostname ESMTP "Version not Available"


这样是顺序问题吗?

marion 回复于:2007-11-27 17:06:39

引用:……reject_non_fqdn_sender,……


先去了这个验正一下,别忘了让postfix重新读取配置文件。

yh81521 回复于:2007-11-27 21:03:04

注释了 reject_non_fqdn_sender 还是一样.

但我注释了 reject_non_fqdn_hostname后,
没有 helo 的问题了,但是又出现新的问题: 554 <yh81521@163.com>:Relay access denied

是什么问题,被163给denie 了,我换过sina,yahoo,和自己公司邮箱都是这样??

现在的状态是: 在能上网的局域网里web,foxmail内网收发正常,可以向外发邮件;放到服务器的DMZ区后web收发都正常,
客户端收信正常,但发信却出现helo的域名不全和554 Relay access denied 错误.

marion 老大帮我分析一下可能是什么错误,我觉得应该不是什么太大的问题了,可能离成功不远了!有没有可能是防火墙或者dns的错误,但我都查了,没什么错误,而且错误现象也不像是这两个方面的问题!

下面是我修改以后用foxmail发邮件的maillog部分:

Nov 27 21:46:44 mail postfix/smtpd[6659]: warning: dict_nis_init: NIS domain name not set - NIS lookups disabled
Nov 27 21:46:44 mail postfix/smtpd[6659]: connect from unknown[218.249.203.221]
Nov 27 21:46:44 mail postfix/smtpd[6659]: NOQUEUE: reject: RCPT from unknown[218.249.203.221]: 554 <yh81521@163.com>: Relay access denied; from=<test@hxrxx.cn> to=<yh81521@163.com> proto=SMTP helo=<YANGHUI>
Nov 27 21:46:46 mail postfix/smtpd[6659]: disconnect from unknown[218.249.203.221]

[ 本帖最后由 yh81521 于 2007-11-27 22:04 编辑 ]

marion 回复于:2007-11-28 12:15:14

不太熟悉Foxmail,你仔细看看上面有没有关于开启验证之类的设置。
一定要打开验证功能,方法可以参照OE中的设置。前面也有讨论。

如果成功了,别忘了把去了的那项加上。那个应该不是问题所在。

yh81521 回复于:2007-11-28 13:10:05

恩,我再看看foxmail的设置.

Nov 27 21:46:44 mail postfix/smtpd[6659]: warning: dict_nis_init: NIS domain name not set - NIS lookups disabled


NIS一定需要开启吗?应该怎么开这个呢?

yh81521 回复于:2007-11-28 13:38:28

再麻烦marion帮我看看,这是放在外网给163发邮件的日志,邮件是发出去了,但是authdaemond却是失败,我找不到是哪的原因.


Nov 28 13:05:24 mail postfix/pickup[7826]: 647D190804E: uid=0 from=<root>
Nov 28 13:05:24 mail postfix/cleanup[7828]: 647D190804E: message-id=<20071127200205.647D190804E@mail.hxrxx.cn>
Nov 28 13:05:24 mail postfix/qmgr[7827]: 647D190804E: from=<root@hxrxx.cn>, size=20627, nrcpt=1 (queue active)
Nov 28 13:05:24 mail authdaemond: received userid lookup request: root@hxrxx.cn
Nov 28 13:05:24 mail authdaemond: authmysql: trying this module
Nov 28 13:05:24 mail authdaemond: SQL query: SELECT username, "", password, '1001', '1001', '/var/mailbox/', maildir, concat(quota,'S'), name, "" FROM mailbox WHERE username = "root@hxrxx.cn" AND (active='1')
Nov 28 13:05:24 mail authdaemond: zero rows returned
Nov 28 13:05:24 mail authdaemond: authmysql: REJECT - try next module
Nov 28 13:05:24 mail authdaemond: FAIL, all modules rejected
Nov 28 13:05:24 mail postfix/pipe[7832]: 647D190804E: to=<root@hxrxx.cn>, orig_to=<root>, relay=maildrop, delay=32599, status=bounced (user unknown. Command output: Invalid user specified. )Nov 28 13:05:24 mail postfix/cleanup[7828]: 75BAF908050: message-id=<20071128050524.75BAF908050@mail.hxrxx.cn>
Nov 28 13:05:24 mail postfix/qmgr[7827]: 75BAF908050: from=<>, size=22352, nrcpt=1 (queue active)
Nov 28 13:05:24 mail postfix/qmgr[7827]: 647D190804E: removed
Nov 28 13:05:24 mail authdaemond: received userid lookup request: root@hxrxx.cn
Nov 28 13:05:24 mail authdaemond: authmysql: trying this module
Nov 28 13:05:24 mail authdaemond: SQL query: SELECT username, "", password, '1001', '1001', '/var/mailbox/', maildir, concat(quota,'S'), name, "" FROM mailbox WHERE username = "root@hxrxx.cn" AND (active='1')
Nov 28 13:05:24 mail authdaemond: zero rows returned
Nov 28 13:05:24 mail authdaemond: authmysql: REJECT - try next module
Nov 28 13:05:24 mail authdaemond: FAIL, all modules rejected
Nov 28 13:05:24 mail postfix/pipe[7832]: 75BAF908050: to=<root@hxrxx.cn>, relay=maildrop, delay=0, status=bounced (user unknown. Command output: Invalid user specified. )
Nov 28 13:05:24 mail postfix/qmgr[7827]: 75BAF908050: removed
Nov 28 13:05:35 mail postfix/smtpd[7837]: warning: dict_nis_init: NIS domain name not set - NIS lookups disabled
Nov 28 13:05:35 mail postfix/smtpd[7837]: connect from yanghui[192.168.0.13]
Nov 28 13:05:35 mail postfix/smtpd[7837]: AB20E90804A: client=yanghui[192.168.0.13], sasl_method=LOGIN, sasl_username=test@hxrxx.cn
Nov 28 13:05:36 mail postfix/cleanup[7828]: AB20E90804A: message-id=<200711272159193439325@hxrxx.cn>
Nov 28 13:05:36 mail postfix/qmgr[7827]: AB20E90804A: from=<test@hxrxx.cn>, size=3477, nrcpt=1 (queue active)
Nov 28 13:05:36 mail postfix/smtp[7844]: AB20E90804A: to=<yh81521@163.com>, relay=mx.mail.163.split.netease.com[220.181.12.52], delay=1, status=sent (250 Mail OK queued as mx2,NMCowKC7JgMw+kxHu3SflQ==.7870S2 1196227120)
Nov 28 13:05:36 mail postfix/qmgr[7827]: AB20E90804A: removed
Nov 28 13:05:40 mail postfix/smtpd[7837]: disconnect from yanghui[192.168.0.13]
Nov 28 13:05:50 mail postfix/postfix-script: stopping the Postfix mail system
Nov 28 13:05:50 mail postfix/master[7825]: terminating on signal 15

marion 回复于:2007-11-28 18:32:00

先查看配置文件是否全部正确配置。

yh81521 回复于:2007-11-29 17:58:33

找到认证过不去的问题所在了,原来没开mysql的日志,今天打开了.
071129 17:18:02 10 Connect postfix@localhost on postfix
10 Quit
11 Connect postfix@localhost on postfix
11 Quit
12 Connect postfix@localhost on postfix
12 Query START TRANSACTION
12 Query SELECT password FROM mailbox WHERE username='test.cn@mail.hxrxx.cn' and domain='mail.hxrxx.cn' and active='1'
12 Query SELECT password FROM mailbox WHERE username='test.cn@mail.hxrxx.cn' and domain='mail.hxrxx.cn' and active='1'
12 Query COMMIT
12 Quit
13 Connect postfix@localhost on postfix
13 Quit


smtpd.conf 设置如下:
pwcheck_method: auxprop
auxprop_plugin: sql
mech_list: plain login
sql_engine: mysql
sql_hostnames: localhost
sql_user: postfix
sql_passwd: postfix
sql_database: postfix
sql_select: SELECT password FROM mailbox WHERE username='%u@%r' and domain='%r' and active='1'

最后一条语句 %u和%r 是怎么取值的,不知道该改哪啊, 老大帮帮忙!!!!!

w7374520 回复于:2007-11-30 15:59:24

ding......ding.......ding

fuleru 回复于:2007-12-02 10:33:12

想修改自己的个人信箱密码的时候,发现不能修改啊。

出现的错误是


DBD::mysql::st execute failed: Unknown column 'clearpwd' in 'field list' at /xxxer/extmail/libs/Ext/Auth/MySQL.pm line 175.


用的是ExtMail 1.0.3 版本。

cai120120 回复于:2007-12-02 18:29:54

:em49: :em49: :em49: :em49: :em49: :em49: :em49: :em49: :em49: :em49: :em49: :em49: :em49: :em49: :em49: :em49: :em49:

hackerzyh 回复于:2007-12-02 21:49:06

我在main.cf中设置
sender_bcc_maps = hash:/etc/postfix/sender_maps
recipient_bcc_maps = hash:/etc/postfix/recipient_maps


sender_maps ,recipient_maps 的内容如下
user1@domain1.com user2@domain.com

postmap
postfix reload
问题是:如果user1发邮件的话user2会收到3封user1发送出去的邮件,如果给user1发邮件的话user2也会收到3封发往user1的邮件,这是为什么?
之前我有提过这个问题,那此是每次user2都收到两封同样的邮件,我重新安装了spamassassin amavisd后就变成了,user2收到3封同样的邮件?盼望老大帮忙看看,等待中.................................

[ 本帖最后由 hackerzyh 于 2007-12-2 21:50 编辑 ]

yanbin923 回复于:2007-12-04 15:49:59

我在装第六步的时候 出现了安装php-5.2.3 无法make
我附了图片 难道是要安装libpng-1.2.16.tar
截图_2025-11-15_15-10-03.jpg
截图_2025-11-15_15-10-03.jpg (143.78 KiB) 查看 863 次
marion 回复于:2007-12-05 12:58:50

查看DBD的版本是否过新,或过旧。

marion 回复于:2007-12-05 13:00:15

你应该贴日志的,不是吗?

marion 回复于:2007-12-05 13:02:22

引用:我在装第六步的时候 出现了安装php-5.2.3 无法make
我附了图片 难道是要安装libpng-1.2.16.tar


你的推断是正确的。如果不想原码安装,你去发行光盘上找到相关的rpm包安装亦可。

php对本环境并非必须,不装亦可。

suntoltti 回复于:2007-12-06 11:45:28

按照marion的方法安装完成后,无法通过认证,请大家帮我分析分析

Dec 6 11:40:11 mazinger postfix/smtpd[15554]: connect from unknown[190.1.232.47]
Dec 6 11:40:12 mazinger pop3d: Connection, ip=[211.160.73.44]
Dec 6 11:40:12 mazinger postfix/smtpd[15558]: warning: dict_nis_init: NIS domain name not set - NIS lookups disabled
Dec 6 11:40:12 mazinger postfix/smtpd[15558]: connect from unknown[211.160.73.44]
Dec 6 11:40:12 mazinger postfix/smtpd[15558]: lost connection after CONNECT from unknown[211.160.73.44]
Dec 6 11:40:12 mazinger postfix/smtpd[15558]: disconnect from unknown[211.160.73.44]
Dec 6 11:40:12 mazinger pop3d: Disconnected, ip=[211.160.73.44]

Dec 6 11:40:14 mazinger postfix/smtpd[15554]: lost connection after RCPT from unknown[190.1.232.47]
Dec 6 11:40:14 mazinger postfix/smtpd[15554]: disconnect from unknown[190.1.232.47]
Dec 6 11:40:18 mazinger pop3d: Connection, ip=[211.160.73.44]
Dec 6 11:40:18 mazinger authdaemond: received auth request, service=pop3, authtype=login
Dec 6 11:40:18 mazinger authdaemond: authmysql: trying this module
Dec 6 11:40:18 mazinger authdaemond: SQL query: SELECT username., password., "", 2525., 2525.., concat('/var/mailbox/',maildir)., concat('/var/mailbox/',maildir), "", name, "" FROM mailbox WHERE username. = "vic"
Dec 6 11:40:18 mazinger authdaemond: zero rows returned
Dec 6 11:40:18 mazinger authdaemond: no password available to compare
Dec 6 11:40:18 mazinger authdaemond: authmysql: REJECT - try next module
Dec 6 11:40:18 mazinger authdaemond: FAIL, all modules rejected
Dec 6 11:40:18 mazinger pop3d: LOGIN FAILED, user=vic, ip=[211.160.73.44]
Dec 6 11:40:23 mazinger authdaemond: received auth request, service=pop3, authtype=login
Dec 6 11:40:23 mazinger authdaemond: authmysql: trying this module
Dec 6 11:40:23 mazinger authdaemond: SQL query: SELECT username., password., "", 2525., 2525.., concat('/var/mailbox/',maildir)., concat('/var/mailbox/',maildir), "", name, "" FROM mailbox WHERE username. = "vic@sfdsfd.com"
Dec 6 11:40:23 mazinger authdaemond: supplied password 'extmail*123*' does not match encrypted password 'dmljQG1hemluZ2VyLmNuLnB1Y2EuY29tAHZpY0BtYXppbmdlci5jbi5wdWNhLmNvbQBleHRtYWlsKjEyMyo='
Dec 6 11:40:23 mazinger authdaemond: authmysql: REJECT - try next module
Dec 6 11:40:23 mazinger authdaemond: FAIL, all modules rejected
Dec 6 11:40:23 mazinger pop3d: LOGIN FAILED, user=vic@sfdsfd.com, ip=[211.160.73.44]
Dec 6 11:40:28 mazinger pop3d: Disconnected, ip=[211.160.73.44]
Dec 6 11:40:28 mazinger postfix/smtpd[15558]: connect from unknown[211.160.73.44]
Dec 6 11:40:28 mazinger authdaemond: received auth request, service=smtp, authtype=login
Dec 6 11:40:28 mazinger authdaemond: authmysql: trying this module
Dec 6 11:40:28 mazinger authdaemond: SQL query: SELECT username., password., "", 2525., 2525.., concat('/var/mailbox/',maildir)., concat('/var/mailbox/',maildir), "", name, "" FROM mailbox WHERE username. = "vic@sfdsfd.com"
Dec 6 11:40:28 mazinger authdaemond: supplied password 'dffddf' does not match encrypted password 'dmljQG1hemluZ2VyLmNuLnB1Y2EuY29tAHZpY0BtYXppbmdlci5jbi5wdWNhLmNvbQBleHRtYWlsKjEyMyo='
Dec 6 11:40:28 mazinger authdaemond: authmysql: REJECT - try next module
Dec 6 11:40:28 mazinger authdaemond: FAIL, all modules rejected
Dec 6 11:40:28 mazinger postfix/smtpd[15558]: warning: unknown[211.160.73.44]: SASL LOGIN authentication failed: authentication failure
Dec 6 11:40:28 mazinger authdaemond: received auth request, service=smtp, authtype=login
Dec 6 11:40:28 mazinger authdaemond: authmysql: trying this module
Dec 6 11:40:28 mazinger authdaemond: SQL query: SELECT username., password., "", 2525., 2525.., concat('/var/mailbox/',maildir)., concat('/var/mailbox/',maildir), "", name, "" FROM mailbox WHERE username. = "vic@sfdsfd.com"
Dec 6 11:40:28 mazinger authdaemond: supplied password 'dffddf' does not match encrypted password 'dmljQG1hemluZ2VyLmNuLnB1Y2EuY29tAHZpY0BtYXppbmdlci5jbi5wdWNhLmNvbQBleHRtYWlsKjEyMyo='
Dec 6 11:40:28 mazinger authdaemond: authmysql: REJECT - try next module
Dec 6 11:40:28 mazinger authdaemond: FAIL, all modules rejected
Dec 6 11:40:28 mazinger postfix/smtpd[15558]: warning: unknown[211.160.73.44]: SASL LOGIN authentication failed: authentication failure
Dec 6 11:40:28 mazinger postfix/smtpd[15558]: lost connection after AUTH from unknown[211.160.73.44]
Dec 6 11:40:28 mazinger postfix/smtpd[15558]: disconnect from unknown[211.160.73.44]

suntoltti 回复于:2007-12-06 11:54:57

另外在本地也不能通过认证,用客户端连接的时候message出现如下错误:
Dec 6 10:47:54 mazinger postfix/smtpd[13297]: sql_select option missing
Dec 6 10:47:54 mazinger postfix/smtpd[13297]: auxpropfunc error no mechanism available
Dec 6 10:47:54 mazinger postfix/smtpd[13297]: _sasl_plugin_load failed on sasl_auxprop_plug_init for plugin: sql
Dec 6 11:15:11 mazinger syslog-ng[2246]: STATS: dropped 0
Dec 6 11:26:12 mazinger postfix/smtpd[14911]: sql_select option missing
Dec 6 11:26:12 mazinger postfix/smtpd[14911]: auxpropfunc error no mechanism available
Dec 6 11:26:12 mazinger postfix/smtpd[14911]: _sasl_plugin_load failed on sasl_auxprop_plug_init for plugin: sql
Dec 6 11:27:21 mazinger zmd: ServiceManager (ERROR): Service Refresh Failed: Failed to parse XML metadata: Can't add repository at http://ftp.chg.ru/pub/Linux/SuSE/suse/update/10.1/: Cannot create the installation source
Dec 6 11:27:21 mazinger zmd: Daemon (WARN): Not starting remote web server
Dec 6 11:28:46 mazinger postfix/smtpd[15073]: sql_select option missing
Dec 6 11:28:46 mazinger postfix/smtpd[15073]: auxpropfunc error no mechanism available
Dec 6 11:28:46 mazinger postfix/smtpd[15073]: _sasl_plugin_load failed on sasl_auxprop_plug_init for plugin: sql
Dec 6 11:39:17 mazinger sshd[15478]: Accepted publickey for root from 211.160.73.44 port 3202 ssh2
Dec 6 11:40:09 mazinger postfix/smtpd[15554]: sql_select option missing
Dec 6 11:40:09 mazinger postfix/smtpd[15554]: auxpropfunc error no mechanism available
Dec 6 11:40:09 mazinger postfix/smtpd[15554]: _sasl_plugin_load failed on sasl_auxprop_plug_init for plugin: sql
Dec 6 11:40:12 mazinger postfix/smtpd[15558]: sql_select option missing
Dec 6 11:40:12 mazinger postfix/smtpd[15558]: auxpropfunc error no mechanism available
Dec 6 11:40:12 mazinger postfix/smtpd[15558]: _sasl_plugin_load failed on sasl_auxprop_plug_init for plugin: sql

marion 回复于:2007-12-06 12:04:45

SASL能正常运行吗?courier-authlib可以支持sasl验正吗?

suntoltti 回复于:2007-12-06 13:41:30

这些都没有问题,
mazinger:/etc/apache2 # ps -ef |grep sasl
root 4653 1 0 13:41 ? 00:00:00 /usr/local/sasl2/sbin/saslauthd -a shadow pam
root 4654 4653 0 13:41 ? 00:00:00 /usr/local/sasl2/sbin/saslauthd -a shadow pam
root 4655 4653 0 13:41 ? 00:00:00 /usr/local/sasl2/sbin/saslauthd -a shadow pam
root 4656 4653 0 13:41 ? 00:00:00 /usr/local/sasl2/sbin/saslauthd -a shadow pam
root 4657 4653 0 13:41 ? 00:00:00 /usr/local/sasl2/sbin/saslauthd -a shadow pam
root 4665 3904 0 13:41 pts/3 00:00:00 grep sasl

root 2184 1 0 13:24 ? 00:00:00 /usr/local/courier-authlib/sbin/courierlogger -pid=/usr/local/courier-authlib/var/spool/authdaemon/pid -start /usr/local/courier-authlib/libexec/courier-authlib/authdaemond
root 2214 2184 0 13:24 ? 00:00:00 /usr/local/courier-authlib/libexec/courier-authlib/authdaemond
root 2227 1 0 13:24 ? 00:00:00 /usr/local/courier-authlib/sbin/courierlogger -pid=/var/run/imapd.pid -start -name=imapd /usr/local/courier-imap/libexec/couriertcpd -address=0 -maxprocs=40 -maxperip=4 -nodnslookup -noidentlookup 143 /usr/local/courier-imap/sbin/imaplogin /usr/local/courier-imap/bin/imapd Maildir
root 2228 2227 0 13:24 ? 00:00:00 /usr/local/courier-imap/libexec/couriertcpd -address=0 -maxprocs=40 -maxperip=4 -nodnslookup -noidentlookup 143 /usr/local/courier-imap/sbin/imaplogin /usr/local/courier-imap/bin/imapd Maildir
root 2249 1 0 13:24 ? 00:00:00 /usr/local/courier-authlib/sbin/courierlogger -pid=/var/run/pop3d.pid -start -name=pop3d /usr/local/courier-imap/libexec/couriertcpd -address=0 -maxprocs=40 -maxperip=4 -nodnslookup -noidentlookup 110 /usr/local/courier-imap/sbin/pop3login /usr/local/courier-imap/bin/pop3d Maildir
root 2250 2249 0 13:24 ? 00:00:00 /usr/local/courier-imap/libexec/couriertcpd -address=0 -maxprocs=40 -maxperip=4 -nodnslookup -noidentlookup 110 /usr/local/courier-imap/sbin/pop3login /usr/local/courier-imap/bin/pop3d Maildir
root 2291 2214 0 13:24 ? 00:00:00 /usr/local/courier-authlib/libexec/courier-authlib/authdaemond
root 2293 2214 0 13:24 ? 00:00:00 /usr/local/courier-authlib/libexec/courier-authlib/authdaemond
root 2294 2214 0 13:24 ? 00:00:00 /usr/local/courier-authlib/libexec/courier-authlib/authdaemond
root 2295 2214 0 13:24 ? 00:00:00 /usr/local/courier-authlib/libexec/courier-authlib/authdaemond
root 2296 2214 0 13:24 ? 00:00:00 /usr/local/courier-authlib/libexec/courier-authlib/authdaemond
root 2297 2214 0 13:24 ? 00:00:00 /usr/local/courier-authlib/libexec/courier-authlib/authdaemond
root 2298 2214 0 13:24 ? 00:00:00 /usr/local/courier-authlib/libexec/courier-authlib/authdaemond
root 2299 2214 0 13:24 ? 00:00:00 /usr/local/courier-authlib/libexec/courier-authlib/authdaemond
root 2300 2214 0 13:24 ? 00:00:00 /usr/local/courier-authlib/libexec/courier-authlib/authdaemond
root 2301 2214 0 13:24 ? 00:00:00 /usr/local/courier-authlib/libexec/courier-authlib/authdaemond

marion 回复于:2007-12-07 10:19:18

仔细检查配置文件,并确认所指定的帐户的确存在。

panwei789 回复于:2007-12-07 11:11:54

按照你的方法安装成功,用客户端登陆smtp正常,但是pop3还有问题,日志如下:
pop3d: scancur opendir("cur"): No such file or directory,
搜索了一下说发第一封信就可以,但我都发了n封了还是一样,找了一下在/var/mailbox里也没有发现它自建帐号,这个问题该怎么解决,请指教,是不是maildir和homedir的设置问题?我新建的帐户这两个字段都空着,如果需要加的话该怎么指定目录,我试着加了一下没有效果

[ 本帖最后由 panwei789 于 2007-12-7 11:15 编辑 ]

panwei789 回复于:2007-12-07 11:31:36

另外我authtest了一下:
Authenticated: vic@dnoffs.com (uid 2525, gid 2525)
Home Directory: /var/mailbox/
Maildir: /var/mailbox/
Quota: (none)
Encrypted Password: $1$phz1mRrj$3ok6BjeaoJYWDBsEPZb5C0
Cleartext Password: (none)
Options: (none)

marion 回复于:2007-12-07 12:49:39

重新发信一封,而后把相关的日志全部发上来,帮你分析一下。你最好通过webmail重新注册一帐号,重新发信试一下。

另,前面的很多帖子中没准儿对你的问题已经做过讨论,建议先去参考一下。

panwei789 回复于:2007-12-07 13:14:46

我没有安装webmail,我是用客户端连的,新建了个用户ok@dnoffs.com,日志如下:
Dec 7 13:10:18 mailserver pop3d: Connection, ip=[211.160.73.44]
Dec 7 13:10:19 mailserver authdaemond: received auth request, service=pop3, authtype=login
Dec 7 13:10:19 mailserver authdaemond: authmysql: trying this module
Dec 7 13:10:19 mailserver authdaemond: SQL query: SELECT username., password., "", 2525., 2525.., concat('/var/mailbox/',maildir)., concat('/var/mailbox/',maildir), "", name, "" FROM mailbox WHERE username. = "ok@dnoffs.com"
Dec 7 13:10:19 mailserver authdaemond: password matches successfully
Dec 7 13:10:19 mailserver authdaemond: authmysql: sysusername=<null>, sysuserid=2525, sysgroupid=2525, homedir=/var/mailbox/, address=ok@dnoffs.com, fullname=postfox, maildir=/var/mailbox/, quota=<null>, options=<null>
Dec 7 13:10:19 mailserver authdaemond: authmysql: clearpasswd=<null>, passwd=$1$phz1mRrj$3ok6BjeaoJYWDBsEPZb5C0
Dec 7 13:10:19 mailserver authdaemond: Authenticated: sysusername=<null>, sysuserid=2525, sysgroupid=2525, homedir=/var/mailbox/, address=ok@dnoffs.com, fullname=postfox, maildir=/var/mailbox/, quota=<null>, options=<null>
Dec 7 13:10:19 mailserver authdaemond: Authenticated: clearpasswd=extmail, passwd=$1$phz1mRrj$3ok6BjeaoJYWDBsEPZb5C0
Dec 7 13:10:19 mailserver pop3d: LOGIN, user=ok@dnoffs.com, ip=[211.160.73.44]
Dec 7 13:10:19 mailserver pop3d: scancur opendir("cur"): No such file or directory
Dec 7 13:10:19 mailserver postfix/smtpd[3940]: connect from unknown[211.160.73.44]
Dec 7 13:10:19 mailserver authdaemond: received auth request, service=smtp, authtype=login
Dec 7 13:10:19 mailserver authdaemond: authmysql: trying this module
Dec 7 13:10:19 mailserver authdaemond: SQL query: SELECT username., password., "", 2525., 2525.., concat('/var/mailbox/',maildir)., concat('/var/mailbox/',maildir), "", name, "" FROM mailbox WHERE username. = "ok@dnoffs.com"
Dec 7 13:10:19 mailserver authdaemond: password matches successfully
Dec 7 13:10:19 mailserver authdaemond: authmysql: sysusername=<null>, sysuserid=2525, sysgroupid=2525, homedir=/var/mailbox/, address=ok@dnoffs.com, fullname=postfox, maildir=/var/mailbox/, quota=<null>, options=<null>
Dec 7 13:10:19 mailserver authdaemond: authmysql: clearpasswd=<null>, passwd=$1$phz1mRrj$3ok6BjeaoJYWDBsEPZb5C0
Dec 7 13:10:19 mailserver authdaemond: Authenticated: sysusername=<null>, sysuserid=2525, sysgroupid=2525, homedir=/var/mailbox/, address=ok@dnoffs.com, fullname=postfox, maildir=/var/mailbox/, quota=<null>, options=<null>
Dec 7 13:10:19 mailserver authdaemond: Authenticated: clearpasswd=extmail, passwd=$1$phz1mRrj$3ok6BjeaoJYWDBsEPZb5C0
Dec 7 13:10:19 mailserver postfix/smtpd[3940]: NOQUEUE: reject: RCPT from unknown[211.160.73.44]: 550 5.1.1 <ok@dnoffs.com>: Recipient address rejected: User unknown in local recipient table; from=<ok@dnoffs.com> to=<ok@dnoffs.com> proto=ESMTP helo=<A-7DB368F3B24D4>
Dec 7 13:10:19 mailserver postfix/smtpd[3940]: disconnect from unknown[211.160.73.44]

marion 回复于:2007-12-07 13:18:15

虚拟域名是什么,是否与本地域名相同了?

[ 本帖最后由 marion 于 2007-12-7 13:21 编辑 ]

panwei789 回复于:2007-12-07 13:42:38

是相同的,我们所用的域是domain.com,然后这台机子的名称是test.domain.com,我在这台机子上架mail server,邮件地址为xxxxx@test.domain.com

panwei789 回复于:2007-12-07 14:03:35

刚才可能是用户名不全,看看这个日志:

Dec 7 14:21:01 mazinger pop3d: Connection, ip=[211.160.73.44]
Dec 7 14:21:01 mazinger authdaemond: received auth request, service=pop3, authtype=login
Dec 7 14:21:01 mazinger authdaemond: authmysql: trying this module
Dec 7 14:21:01 mazinger authdaemond: SQL query: SELECT username., password., "", 2525., 2525.., concat('/var/mailbox/',maildir)., concat('/var/mailbox/',maildir), "", name, "" FROM mailbox WHERE username. = "vic@test.donmain.com"
Dec 7 14:21:01 mazinger authdaemond: password matches successfully
Dec 7 14:21:01 mazinger authdaemond: authmysql: sysusername=<null>, sysuserid=2525, sysgroupid=2525, homedir=/var/mailbox/, address=vic@test.donmain.com, fullname=postfix, maildir=/var/mailbox/, quota=<null>, options=<null>
Dec 7 14:21:01 mazinger authdaemond: authmysql: clearpasswd=<null>, passwd=$1$phz1mRrj$3ok6BjeaoJYWDBsEPZb5C0
Dec 7 14:21:01 mazinger authdaemond: Authenticated: sysusername=<null>, sysuserid=2525, sysgroupid=2525, homedir=/var/mailbox/, address=vic@test.donmain.com, fullname=postfix, maildir=/var/mailbox/, quota=<null>, options=<null>
Dec 7 14:21:01 mazinger authdaemond: Authenticated: clearpasswd=extmail, passwd=$1$phz1mRrj$3ok6BjeaoJYWDBsEPZb5C0
Dec 7 14:21:01 mazinger pop3d: LOGIN, user=test@test.donmain.com, ip=[211.160.73.44]
Dec 7 14:21:01 mazinger pop3d: scancur opendir("cur"): No such file or directory

[ 本帖最后由 panwei789 于 2007-12-7 14:23 编辑 ]

marion 回复于:2007-12-07 14:38:10

如果你打算使用虚拟域的话,本地域绝不能与之相同。这个恐怕就是问题所在了。这个在帖子中和前面的一些讲座帖中已经有详细说明。

panwei789 回复于:2007-12-07 15:07:47

ok,已经解决,是以前设置过maildir全局变量的问题

[ 本帖最后由 panwei789 于 2007-12-9 22:04 编辑 ]

snfnvtk 回复于:2007-12-08 01:50:11

HEHE,太强大了!

zdyldy 回复于:2007-12-08 10:40:14

我的maillog日志太大了。每天都要几百兆。都是不能投递的邮件惹的祸。发不出去的邮件都要写在maillog里。

我查了一些关于maillog资料,对于暂是不能发送的邮件,postfix会给该邮件加一个邮票,等该邮票的的时间到了以后再发送该邮件。我想知道如果该信发不出去,那是不是一直循环发这个邮件呢,我可不可以设置发送几次后,如果还没有发送成功,就将这封邮件丢弃呢。


急!!!急!!!急!!!

wfswb007 回复于:2007-12-09 18:56:21

--with-xml
--with-png
--with-jpeg
--with-zlib
--with-freetype
--with-gd
我编译php的时候这些模块好像都没有起作用

这些都是装哪些包,能给说说吗

panwei789 回复于:2007-12-10 11:37:07

请教一下大大,如何不通过extmail直接在mysql里添加用户和密码?因为mysql里密码是加过密的,比如说user/passwd ,如何得到加密后的passwd?

marion 回复于:2007-12-10 12:05:50

错误信息是什么?

一般只要装了这几个软件包及其相关的devel包就不会出现问题,请检查。

marion 回复于:2007-12-10 12:07:34

在SQL的插入命令对应于passwd的一栏使用类同这样的方式(假设你要设置的密码为123456):
password('123456')

panwei789 回复于:2007-12-10 13:26:18

引用:原帖由 marion 于 2007-12-10 12:07 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=7697254&ptid=987344
在SQL的插入命令对应于passwd的一栏使用类同这样的方式(假设你要设置的密码为123456):
password('123456')



这样行吗?我试了一下,认证好像不能通过。是不是加密不一样,extmail 这个密码原来是$1$phz1mRrj$3ok6BjeaoJYWDBsEPZb5C0,用password后*2D4B317D0A140050AE5AB99BB10912DD8CFC283D,按理说两个应该一样的呀

[ 本帖最后由 panwei789 于 2007-12-10 13:29 编辑 ]

marion 回复于:2007-12-10 14:54:10

mysql提供的加密方法有好几种,你可以通过mysql的手册去查看一下,或者通过extman的源文件去看一下其使用的加密方式到底是什么;加密的方式不一定就是password,我那样讲只是要举个例子给你。

[ 本帖最后由 marion 于 2007-12-10 14:55 编辑 ]

幽冥公子 回复于:2007-12-10 15:54:14

学习中!

wfswb007 回复于:2007-12-11 20:25:57

我装完extman测试下就成这个现象了,不知道是什么原因,给解决下好吗

[ 本帖最后由 wfswb007 于 2007-12-11 20:30 编辑 ]
截图_2025-11-15_15-13-02.jpg
截图_2025-11-15_15-13-02.jpg (99.79 KiB) 查看 862 次
jwh1979 回复于:2007-12-12 10:34:44

你好,我在装DB-4.5.20时,mv /usr/inculde/db4 /usr/inculde/db4.OFF这条命令无法运行通过,请问是什么原因,有什么影响?

marion 回复于:2007-12-12 11:49:32

访问数据库被拒绝,请检查你提供的帐号(postfix)及对应的密码正确与否。

marion 回复于:2007-12-12 11:51:16

检查一下你有没有事先安装db4的devel包(RPM),如果没有话,这个不用做了,一般说来是不会有问题的。

jwh1979 回复于:2007-12-12 12:58:49

我现在装php时报错:<configure: error:libpng.(a|so) not found.>,是否和前面的错误有关?



解决了,重装了libpng。

[ 本帖最后由 jwh1979 于 2007-12-12 14:15 编辑 ]

jwh1979 回复于:2007-12-12 12:59:33

我现在装postfix-2.4.6 make install时报错:<error while loading shared libraries : libdb-4.5.so :cannot open No such file or directory >,是否和前面的错误有关?

[ 本帖最后由 jwh1979 于 2007-12-12 16:36 编辑 ]

wfswb007 回复于:2007-12-12 14:20:52

这个错误怎么解决呀
截图_2025-11-15_15-16-04.jpg
截图_2025-11-15_15-16-04.jpg (120.87 KiB) 查看 861 次
marion 回复于:2007-12-12 21:44:41

如果成功的编译安装了,而后要输出一下安装后的lib目录,参照帖子中的方法再试一次。

和前面的错误没有关系。

[ 本帖最后由 marion 于 2007-12-12 21:47 编辑 ]

jwh1979 回复于:2007-12-14 11:18:29

marion 兄,安装BDB-mysql出错如何解决,在MAKE时报错。


gcc -c -I/usr/lib/perl5/vendor_perl/5.8.5/i386-linux-thread-multi/auto/DBI -I/usr/include/mysql -g -pipe -m32 -march=i386 -mtune=pentium4 -D_GNU_SOURCE -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -fno-strict-aliasing -DDBD_MYSQL_WITH_SSL -g -D_REENTRANT -D_GNU_SOURCE -DDEBUGGING -fno-strict-aliasing -pipe -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -I/usr/include/gdbm -O2 -g -pipe -m32 -march=i386 -mtune=pentium4 -DVERSION=\"3.0002_4\" -DXS_VERSION=\"3.0002_4\" -fPIC "-I/usr/lib/perl5/5.8.5/i386-linux-thread-multi/CORE" dbdimp.c
dbdimp.c: In function `mysql_to_perl_type':
dbdimp.c:249: error: `MYSQL_TYPE_BIT' undeclared (first use in this function)
dbdimp.c:249: error: (Each undeclared identifier is reported only once
dbdimp.c:249: error: for each function it appears in.)
dbdimp.c:259: error: `MYSQL_TYPE_VARCHAR' undeclared (first use in this function)
dbdimp.c:263:25: warning: extra tokens at end of #ifdef directive
make: *** [dbdimp.o] 错误 1


现在web访问extmail时报:Internal Server Error
这和上面的错误有关吗?多谢了!!!

marion 回复于:2007-12-14 13:22:23

链接mysql的头文件至/usr/include或/usr/local/include或许可以解决此问题。

如下:

ln -s /usr/local/mysql/include/* /usr/include

copywu 回复于:2007-12-14 15:10:56

请各位帮忙看看这个问题呢,谢谢

通过amavisd容器进行病毒和垃圾邮件处理的时候出问题了
目前的测试环境是在局域网进行的,服务器自己做了dns,IP是内网IP 192.168.88.0/24
目前只有病毒邮件能够正常处理,其他任何邮件都被退信,无法发送

另外注意到一个细节,我在amavisd.conf中配置了管理员邮件地址为admin@xxx,被正常处理的病毒邮件是由该地址发出的,但是其他所有邮件都是从postmaster@xxx发出的,似乎这些邮件还没有到amavisd就被处理掉了?请帮忙分析一些问题出在哪里,谢谢
问题帖链接
http://bbs.chinaunix.net/thread-1028829-1-1.html

jwh1979 回复于:2007-12-14 16:46:17

我试过了,提示无法覆盖,是链接已存在吗?

guofs 回复于:2007-12-17 08:24:45

引用:原帖由 jwh1979 于 2007-12-14 11:18 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=7717173&ptid=987344
marion 兄,安装BDB-mysql出错如何解决,在MAKE时报错。


gcc -c -I/usr/lib/perl5/vendor_perl/5.8.5/i386-linux-thread-multi/auto/DBI -I/usr/include/mysql -g -pipe -m32 -march=i386 -mtune=pent ...

我也遇到了该问题,
正发晕呢

vepeta 回复于:2007-12-17 15:19:02

引用:原帖由 wfswb007 于 2007-12-12 14:20 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=7708261&ptid=987344
这个错误怎么解决呀

应该是权限问题。

dtzuo 回复于:2007-12-17 15:47:57

呵呵一直找RHEL方面的资料太少了,,收藏慢慢看

chameleon 回复于:2007-12-18 09:21:33

这个绝对是个好贴,呵呵,留个名...

guofs 回复于:2007-12-18 09:37:59

楼主marion是个高人,该贴帮忙很多人完成了postfix的系统架构。
我就是其中的受益者之一。

但我个人认为该贴若整理下,肯定会有更强的可读性和可操作性,
若不然该贴对于新手来说是有点难度。


下面的内容是我对该贴的认识和理解,希望楼主指导。
我希望下面的补充能帮到当初像我一样困惑的人们。



系统认证的逻辑结构方面:
===================================================
该贴的认证结构应该如下:
  +----------------------------------------------------+
  | |
  | 25/25 25/25 110/993 143/995 80/443 |
  | Incoming Outgoing POP3 IMAP WEB-MAIL |
  | || || || || || |
  +----------+------------+------------------+---------+
  | | | |
  | Postfix | Courier-imap | |
  | | | |
  | +------------+--------------------| extmail |
  | | Cyrus-SASL | | extman |
  | |------------+ | |
  | | Courier-authlib | |
| | | |
  |----------+-------------------------------+---------+
  | MySQL/OpenLDAP |
  +----------------------------------------------------+


PostFix对虚拟邮箱配额的支持
===================================================
该贴中的postfix配置文件main.cf对虚拟邮箱配额的支持,需在安装postfix时就
打上postfix-2.4.5-vda-ng.patch补丁。若不然不会支持虚拟邮箱配额。


extmail/extman的自动回复和邮件转发功能
===================================================
postfix自带的virtual MDA是不支持extmail中自动回复和邮件转发功能,需改才maildrop MDA
才可以支持


extman图形日志安装
===================================================
在安装rrdtool时,需如下模块
libart_lgpl
libart_lgpl-devel
libpng
libpng-devel
zlib
zlib-devel
freetype
freetype-devel
这些模块在Redhat的安装盘上都可以找到rpm包。



虚拟邮箱的家目录和邮件目录结构图
===================================================
---------------------------------------------------------
基目录 |
---------------------------------------------------------
虚拟用户的家目录 |
---------------------------------------------------------
虚拟用户的邮件目录 |
---------------------------------------------------------
/home/vmail/
|
|---domain1.com/
| |
| |---user1/
| | +----Maildir/
| | | |--cur/
| | | |--new/
| | | +--tmp/
| | +----Other
| +---user2/
| +----Maildir/
| | |--cur/
| | |--new/
| | +--tmp/
| +----Other
+---domain2.com/
|
+---user1/
| +----Maildir/
| | |--cur/
| | |--new/
| | +--tmp/
| +----Other
+---user2/
+----Maildir/
| |--cur/
| |--new/
| |--tmp/
+----Other


Postfix的防病毒防垃圾的结构图
===================================================
PostFix垃圾邮件控制流程顺序如下:
-------------------------------------------------
| Server: 220 smtp.example.com ESMTP PostFix | smtpd_client_restrictions----------
------------------------------------------------- |
| Client: HELO mail.ora.com | smtpd_helo_restrictions |
| Server: 250 smtp.example.com | |
------------------------------------------------- |
| Client: MAIL FROM: <info@test.com> | smtpd_sender_restrictions |------客户端检测
| Server: 250 OK | |
------------------------------------------------- |
| Client: RCPT TO: <guofs@example.com> | smtpd_recipient_restrictions |
| Server: 250 OK | |
------------------------------------------------- |
| Client: DATA | smtpd_data_restrictions------------
| Server: 354 End data with <CR><LF>.<CR><LF> |
-------------------------------------------------
| Client: To: Kyle Dent<kdent@example.com> | header_checks----------
| From: <info@ora.com> | |
| Subject: SMTP Example | mime_header_checks |
------------------------------------------------- nested_header_checks |-------内容检查
| This is a message body. | |
| It continues until a dot | body_checks------------
| is typed on a line by itself. |
| . |
-------------------------------------------------
对于防病毒防垃圾邮件的处理,分为两部分,
第一部分:
为客户端检测,由PostFix负责严格检测
第二部分:
为内容检查,由以下程序负责严格检测.
amavisd-new(解信程序,源码)
clamav(防病毒,源码)
spamassassin(防垃圾,源码)

[ 本帖最后由 guofs 于 2007-12-18 09:42 编辑 ]

chasfer 回复于:2007-12-18 11:03:43

marion兄:
真是太好了,非常感谢!
不过想请教一下,postfix 邮箱地址命名的时候,哪些特殊字符支持,哪些不支持,您了解吗?
非常感谢!

marion 回复于:2007-12-20 12:05:27

嗯,真是位有心的朋友!

volication 回复于:2007-12-20 12:36:54

编译安装好http后,启动报错:
./apachectl start
httpd: Syntax error on line 80 of /etc/httpd/httpd.conf: Cannot load /usr/local/apache/modules/mod_ssl.so into server: libssl.so.0.9.8: cannot open shared object file: No such file or directory

我是按照楼主的参数编译的,请问楼主是不是编译出错了!
谢谢!

[ 本帖最后由 volication 于 2007-12-20 12:41 编辑 ]

volication 回复于:2007-12-20 13:15:49

搞定了,由于自己粗心,安装openssl-0.9.8e是忘记:
# ln -sv /usr/local/ssl/lib/libssl.so.0.9.8 /usr/lib/libssl.so
导致找不到model_ssl.so

:P

zzm183 回复于:2007-12-22 02:26:14

tail /var/log/maillog
Dec 21 22:13:35 myserver postfix/master[2277]: warning: process /usr/local/postfix/libexec/trivial-rewrite pid 2806 exit status 1
Dec 21 22:13:35 myserver postfix/master[2277]: warning: /usr/local/postfix/libexec/trivial-rewrite: bad command startup -- throttling
Dec 21 22:13:35 myserver postfix/smtpd[2508]: warning: problem talking to service rewrite: Success
Dec 21 22:13:35 myserver postfix/master[2277]: warning: process /usr/local/postfix/libexec/trivial-rewrite pid 2805 exit status 1
Dec 21 22:13:36 myserver postfix/trivial-rewrite[2807]: warning: connect to mysql server localhost: Access denied for user 'extmail'@'localhost' (using password: NO)
Dec 21 22:13:36 myserver postfix/trivial-rewrite[2807]: fatal: mysql:/etc/postfix/mysql/mysql_virtual_alias_maps.cf(0,lock|fold_fix): table lookup problem
Dec 21 22:13:37 myserver postfix/smtpd[2501]: warning: problem talking to service rewrite: Success
Dec 21 22:13:37 myserver postfix/master[2277]: warning: process /usr/local/postfix/libexec/trivial-rewrite pid 2807 exit status 1
Dec 21 22:13:51 myserver postfix/pickup[2289]: warning: 43B9AC3D8C: message has been queued for 2 days
Dec 21 22:13:51 myserver postfix/pickup[2289]: 43B9AC3D8C: uid=0 from=<root>

google上查了半天没找到答案!!!帮帮忙哦。。。

zzm183 回复于:2007-12-22 02:28:01

自己发给自己也收不到 tail /var/log/messages
Dec 21 21:53:08 myserver postfix/smtpd[2501]: sql_select option missing
Dec 21 21:53:08 myserver postfix/smtpd[2501]: auxpropfunc error no mechanism available
Dec 21 21:53:33 myserver postfix/smtpd[2508]: sql_select option missing
Dec 21 21:53:33 myserver postfix/smtpd[2508]: auxpropfunc error no mechanism available

zzm183 回复于:2007-12-22 21:27:03

好开心。。。
admin
网站管理员
帖子: 11
注册时间: 2025年 10月 2日 03:38

Re: 原chinaunix.net论坛上的经典开源邮件系统架设和联调帖子

帖子 admin »

代码: 全选

备注:由于原帖子内容过长,出于页面加载效率,以回复形式分段发帖
以下是/usr/local/postfix/sbin/postconf 结果

address_verify_default_transport = $default_transportf
address_verify_local_transport = $local_transport
address_verify_map =
address_verify_negative_cache = yes
address_verify_negative_expire_time = 3d
address_verify_negative_refresh_time = 3h
address_verify_poll_count = 3
address_verify_poll_delay = 3s
address_verify_positive_expire_time = 31d
address_verify_positive_refresh_time = 7d
address_verify_relay_transport = $relay_transport
address_verify_relayhost = $relayhost
address_verify_sender = postmaster
address_verify_sender_dependent_relayhost_maps = $sender_dependent_relayhost_maps
address_verify_service_name = verify
address_verify_transport_maps = $transport_maps
address_verify_virtual_transport = $virtual_transport
alias_database = hash:/etc/aliases
alias_maps = hash:/etc/aliases, nis:mail.aliases
allow_mail_to_commands = alias, forward
allow_mail_to_files = alias, forward
allow_min_user = no
allow_percent_hack = yes
allow_untrusted_routing = no
alternate_config_directories =
always_bcc =
anvil_rate_time_unit = 60s
anvil_status_update_time = 600s
append_at_myorigin = yes
append_dot_mydomain = yes
application_event_drain_time = 100s
authorized_flush_users = static:anyone
authorized_mailq_users = static:anyone
authorized_submit_users = static:anyone
backwards_bounce_logfile_compatibility = yes
berkeley_db_create_buffer_size = 16777216
berkeley_db_read_buffer_size = 131072
best_mx_transport =
biff = yes
body_checks =
body_checks_size_limit = 51200
bounce_notice_recipient = postmaster
bounce_queue_lifetime = 5d
bounce_service_name = bounce
bounce_size_limit = 50000
bounce_template_file =
broken_sasl_auth_clients = yes
canonical_classes = envelope_sender, envelope_recipient, header_sender, header_recipient
canonical_maps =
cleanup_service_name = cleanup
command_directory = /usr/local/postfix/sbin
command_execution_directory =
command_expansion_filter = 1234567890!@%-_=+:,./abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ
command_time_limit = 1000s
config_directory = /etc/postfix
connection_cache_protocol_timeout = 5s
connection_cache_service_name = scache
connection_cache_status_update_time = 600s
connection_cache_ttl_limit = 2s
content_filter =
daemon_directory = /usr/local/postfix/libexec
daemon_timeout = 18000s
debug_peer_level = 1
debug_peer_list =
default_database_type = hash
default_delivery_slot_cost = 5
default_delivery_slot_discount = 50
default_delivery_slot_loan = 3
default_destination_concurrency_limit = 20
default_destination_recipient_limit = 50
default_extra_recipient_limit = 1000
default_minimum_delivery_slots = 3
default_privs = nobody
default_process_limit = 100
default_rbl_reply = $rbl_code Service unavailable; $rbl_class [$rbl_what] blocked using $rbl_domain${rbl_reason?; $rbl_reason}
default_recipient_limit = 10000
default_transport = smtp
default_verp_delimiters = +=
defer_code = 450
defer_service_name = defer
defer_transports =
delay_logging_resolution_limit = 2
delay_notice_recipient = postmaster
delay_warning_time = 0h
deliver_lock_attempts = 20
deliver_lock_delay = 1s
disable_dns_lookups = no
disable_mime_input_processing = no
disable_mime_output_conversion = no
disable_verp_bounces = no
disable_vrfy_command = no
dont_remove = 0
double_bounce_sender = double-bounce
duplicate_filter_limit = 1000
empty_address_recipient = MAILER-DAEMON
enable_original_recipient = yes
error_notice_recipient = postmaster
error_service_name = error
execution_directory_expansion_filter = 1234567890!@%-_=+:,./abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ
expand_owner_alias = no
export_environment = TZ MAIL_CONFIG LANG
fallback_transport =
fallback_transport_maps =
fast_flush_domains = $relay_domains
fast_flush_purge_time = 7d
fast_flush_refresh_time = 12h
fault_injection_code = 0
flush_service_name = flush
fork_attempts = 5
fork_delay = 1s
forward_expansion_filter = 1234567890!@%-_=+:,./abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ
forward_path = $home/.forward${recipient_delimiter}${extension}, $home/.forward
frozen_delivered_to = yes
hash_queue_depth = 1
hash_queue_names = deferred, defer
header_address_token_limit = 10240
header_checks =
header_size_limit = 102400
helpful_warnings = yes
home_mailbox =
hopcount_limit = 50
html_directory = /var/www/postfix_html
ignore_mx_lookup_error = no
import_environment = MAIL_CONFIG MAIL_DEBUG MAIL_LOGTAG TZ XAUTHORITY DISPLAY LANG=C
in_flow_delay = 1s
inet_interfaces = all
inet_protocols = ipv4
initial_destination_concurrency = 5
internal_mail_filter_classes =
invalid_hostname_reject_code = 501
ipc_idle = 100s
ipc_timeout = 3600s
ipc_ttl = 1000s
line_length_limit = 2048
lmtp_bind_address =
lmtp_bind_address6 =
lmtp_cname_overrides_servername = no
lmtp_connect_timeout = 0s
lmtp_connection_cache_destinations =
lmtp_connection_cache_on_demand = yes
lmtp_connection_cache_time_limit = 2s
lmtp_connection_reuse_time_limit = 300s
lmtp_data_done_timeout = 600s
lmtp_data_init_timeout = 120s
lmtp_data_xfer_timeout = 180s
lmtp_defer_if_no_mx_address_found = no
lmtp_destination_concurrency_limit = $default_destination_concurrency_limit
lmtp_destination_recipient_limit = $default_destination_recipient_limit
lmtp_discard_lhlo_keyword_address_maps =
lmtp_discard_lhlo_keywords =
lmtp_enforce_tls = no
lmtp_generic_maps =
lmtp_host_lookup = dns
lmtp_lhlo_name = $myhostname
lmtp_lhlo_timeout = 300s
lmtp_line_length_limit = 990
lmtp_mail_timeout = 300s
lmtp_mx_address_limit = 5
lmtp_mx_session_limit = 2
lmtp_pix_workaround_delay_time = 10s
lmtp_pix_workaround_threshold_time = 500s
lmtp_quit_timeout = 300s
lmtp_quote_rfc821_envelope = yes
lmtp_randomize_addresses = yes
lmtp_rcpt_timeout = 300s
lmtp_rset_timeout = 20s
lmtp_sasl_auth_enable = no
lmtp_sasl_mechanism_filter =
lmtp_sasl_password_maps =
lmtp_sasl_path =
lmtp_sasl_security_options = noplaintext, noanonymous
lmtp_sasl_tls_security_options = $lmtp_sasl_security_options
lmtp_sasl_tls_verified_security_options = $lmtp_sasl_tls_security_options
lmtp_sasl_type = cyrus
lmtp_send_xforward_command = no
lmtp_sender_dependent_authentication = no
lmtp_skip_5xx_greeting = yes
lmtp_starttls_timeout = 300s
lmtp_tcp_port = 24
lmtp_tls_CAfile =
lmtp_tls_CApath =
lmtp_tls_cert_file =
lmtp_tls_dcert_file =
lmtp_tls_dkey_file = $lmtp_tls_dcert_file
lmtp_tls_enforce_peername = yes
lmtp_tls_exclude_ciphers =
lmtp_tls_key_file = $lmtp_tls_cert_file
lmtp_tls_loglevel = 0
lmtp_tls_mandatory_ciphers = medium
lmtp_tls_mandatory_exclude_ciphers =
lmtp_tls_mandatory_protocols = SSLv3, TLSv1
lmtp_tls_note_starttls_offer = no
lmtp_tls_per_site =
lmtp_tls_policy_maps =
lmtp_tls_scert_verifydepth = 5
lmtp_tls_secure_cert_match = nexthop
lmtp_tls_security_level =
lmtp_tls_session_cache_database =
lmtp_tls_session_cache_timeout = 3600s
lmtp_tls_verify_cert_match = hostname
lmtp_use_tls = no
lmtp_xforward_timeout = 300s
local_command_shell =
local_destination_concurrency_limit = 2
local_destination_recipient_limit = 1
local_header_rewrite_clients = permit_inet_interfaces
local_recipient_maps =
local_transport = maildrop
luser_relay =
mail_name = Postfix
mail_owner = postfix
mail_release_date = 20060727
mail_spool_directory = /var/mail
mail_version = 2.3.2
mailbox_command =
mailbox_command_maps =
mailbox_delivery_lock = fcntl, dotlock
mailbox_size_limit = 51200000
mailbox_transport =
mailbox_transport_maps =
mailq_path = /usr/bin/mailq
manpage_directory = /usr/local/postfix/man
maps_rbl_domains =
maps_rbl_reject_code = 554
masquerade_classes = envelope_sender, header_sender, header_recipient
masquerade_domains =
masquerade_exceptions =
max_idle = 100s
max_use = 100
maximal_backoff_time = 4000s
maximal_queue_lifetime = 5d
message_reject_characters =
message_size_limit = 14336000
message_strip_characters =
milter_command_timeout = 30s
milter_connect_macros = j {daemon_name} v
milter_connect_timeout = 30s
milter_content_timeout = 300s
milter_data_macros = i
milter_default_action = tempfail
milter_end_of_data_macros = i
milter_helo_macros = {tls_version} {cipher} {cipher_bits} {cert_subject} {cert_issuer}
milter_macro_daemon_name = $myhostname
milter_macro_v = $mail_name $mail_version
milter_mail_macros = i {auth_type} {auth_authen} {auth_author} {mail_addr}
milter_protocol = 2
milter_rcpt_macros = i {rcpt_addr}
milter_unknown_command_macros =
mime_boundary_length_limit = 2048
mime_header_checks = $header_checks
mime_nesting_limit = 100
minimal_backoff_time = 1000s
multi_recipient_bounce_reject_code = 550
mydestination = $mynetworks $myhostname
mydomain = test.com
myhostname = mx.test.com
mynetworks = 127.0.0.0/8,192.168.1.0/24
mynetworks_style = subnet
myorigin = test.com
nested_header_checks = $header_checks
newaliases_path = /usr/bin/newaliases
non_fqdn_reject_code = 504
non_smtpd_milters =
notify_classes = resource, software
owner_request_special = yes
parent_domain_matches_subdomains = debug_peer_list,fast_flush_domains,mynetworks,permit_mx_backup_networks,qmqpd_authorized_clients,relay_domains,smtpd_access_maps
permit_mx_backup_networks =
pickup_service_name = pickup
plaintext_reject_code = 450
prepend_delivered_header = command, file, forward
process_id_directory = pid
propagate_unmatched_extensions = canonical, virtual
proxy_interfaces =
proxy_read_maps = $local_recipient_maps $mydestination $virtual_alias_maps $virtual_alias_domains $virtual_mailbox_maps $virtual_mailbox_domains $relay_recipient_maps $relay_domains $canonical_maps $sender_canonical_maps $recipient_canonical_maps $relocated_maps $transport_maps $mynetworks
qmgr_clog_warn_time = 300s
qmgr_fudge_factor = 100
qmgr_message_active_limit = 20000
qmgr_message_recipient_limit = 20000
qmgr_message_recipient_minimum = 10
qmqpd_authorized_clients =
qmqpd_error_delay = 1s
qmqpd_timeout = 300s
queue_directory = /var/spool/postfix
queue_file_attribute_count_limit = 100
queue_minfree = 0
queue_run_delay = 1000s
queue_service_name = qmgr
rbl_reply_maps =
readme_directory = no
receive_override_options =
recipient_bcc_maps =
recipient_canonical_classes = envelope_recipient, header_recipient
recipient_canonical_maps =
recipient_delimiter =
reject_code = 554
relay_clientcerts =
relay_destination_concurrency_limit = $default_destination_concurrency_limit
relay_destination_recipient_limit = $default_destination_recipient_limit
relay_domains = $mydestination
relay_domains_reject_code = 554
relay_recipient_maps =
relay_transport = relay
relayhost =
relocated_maps =
remote_header_rewrite_domain =
require_home_directory = no
resolve_dequoted_address = yes
resolve_null_domain = no
resolve_numeric_domain = no
rewrite_service_name = rewrite
sample_directory = /etc/postfix
sender_bcc_maps =
sender_canonical_classes = envelope_sender, header_sender
sender_canonical_maps =
sender_dependent_relayhost_maps =
sendmail_path = /usr/sbin/sendmail
service_throttle_time = 60s
setgid_group = postdrop
show_user_unknown_table_name = yes
showq_service_name = showq
smtp_always_send_ehlo = yes
smtp_bind_address =
smtp_bind_address6 =
smtp_cname_overrides_servername = no
smtp_connect_timeout = 30s
smtp_connection_cache_destinations =
smtp_connection_cache_on_demand = yes
smtp_connection_cache_time_limit = 2s
smtp_connection_reuse_time_limit = 300s
smtp_data_done_timeout = 600s
smtp_data_init_timeout = 120s
smtp_data_xfer_timeout = 180s
smtp_defer_if_no_mx_address_found = no
smtp_destination_concurrency_limit = $default_destination_concurrency_limit
smtp_destination_recipient_limit = $default_destination_recipient_limit
smtp_discard_ehlo_keyword_address_maps =
smtp_discard_ehlo_keywords =
smtp_enforce_tls = no
smtp_fallback_relay = $fallback_relay
smtp_generic_maps =
smtp_helo_name = $myhostname
smtp_helo_timeout = 300s
smtp_host_lookup = dns
smtp_line_length_limit = 990
smtp_mail_timeout = 300s
smtp_mx_address_limit = 5
smtp_mx_session_limit = 2
smtp_never_send_ehlo = no
smtp_pix_workaround_delay_time = 10s
smtp_pix_workaround_threshold_time = 500s
smtp_quit_timeout = 300s
smtp_quote_rfc821_envelope = yes
smtp_randomize_addresses = yes
smtp_rcpt_timeout = 300s
smtp_rset_timeout = 20s
smtp_sasl_auth_enable = no
smtp_sasl_mechanism_filter =
smtp_sasl_password_maps =
smtp_sasl_path =
smtp_sasl_security_options = noplaintext, noanonymous
smtp_sasl_tls_security_options = $smtp_sasl_security_options
smtp_sasl_tls_verified_security_options = $smtp_sasl_tls_security_options
smtp_sasl_type = cyrus
smtp_send_xforward_command = no
smtp_sender_dependent_authentication = no
smtp_skip_5xx_greeting = yes
smtp_skip_quit_response = yes
smtp_starttls_timeout = 300s
smtp_tls_CAfile =
smtp_tls_CApath =
smtp_tls_cert_file =
smtp_tls_dcert_file =
smtp_tls_dkey_file = $smtp_tls_dcert_file
smtp_tls_enforce_peername = yes
smtp_tls_exclude_ciphers =
smtp_tls_key_file = $smtp_tls_cert_file
smtp_tls_loglevel = 0
smtp_tls_mandatory_ciphers = medium
smtp_tls_mandatory_exclude_ciphers =
smtp_tls_mandatory_protocols = SSLv3, TLSv1
smtp_tls_note_starttls_offer = no
smtp_tls_per_site =
smtp_tls_policy_maps =
smtp_tls_scert_verifydepth = 5
smtp_tls_secure_cert_match = nexthop, dot-nexthop
smtp_tls_security_level =
smtp_tls_session_cache_database =
smtp_tls_session_cache_timeout = 3600s
smtp_tls_verify_cert_match = hostname
smtp_use_tls = no
smtp_xforward_timeout = 300s
smtpd_authorized_verp_clients = $authorized_verp_clients
smtpd_authorized_xclient_hosts =
smtpd_authorized_xforward_hosts =
smtpd_banner = Welcome to our $myhostname ESMTP,Warning: Version not Available!
smtpd_client_connection_count_limit = 50
smtpd_client_connection_rate_limit = 0
smtpd_client_event_limit_exceptions = ${smtpd_client_connection_limit_exceptions:$mynetworks}
smtpd_client_message_rate_limit = 0
smtpd_client_new_tls_session_rate_limit = 0
smtpd_client_recipient_rate_limit = 0
smtpd_client_restrictions =
smtpd_data_restrictions =
smtpd_delay_open_until_valid_rcpt = yes
smtpd_delay_reject = yes
smtpd_discard_ehlo_keyword_address_maps =
smtpd_discard_ehlo_keywords =
smtpd_end_of_data_restrictions =
smtpd_enforce_tls = no
smtpd_error_sleep_time = 1s
smtpd_etrn_restrictions =
smtpd_expansion_filter = \t\40!"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\\]^_`abcdefghijklmnopqrstuvwxyz{|}~
smtpd_forbidden_commands = CONNECT GET POST
smtpd_hard_error_limit = 20
smtpd_helo_required = no
smtpd_helo_restrictions =
smtpd_history_flush_threshold = 100
smtpd_junk_command_limit = 100
smtpd_milters =
smtpd_noop_commands =
smtpd_null_access_lookup_key = <>
smtpd_peername_lookup = yes
smtpd_policy_service_max_idle = 300s
smtpd_policy_service_max_ttl = 1000s
smtpd_policy_service_timeout = 100s
smtpd_proxy_ehlo = $myhostname
smtpd_proxy_filter =
smtpd_proxy_timeout = 100s
smtpd_recipient_limit = 1000
smtpd_recipient_overshoot_limit = 1000
smtpd_recipient_restrictions = permit_mynetworks,permit_sasl_authenticated,reject_invalid_hostname,reject_non_fqdn_hostname, reject_unknown_sender_domain,reject_non_fqdn_sender,reject_non_fqdn_recipient,reject_unknown_recipient_domain, reject_unauth_pipelining,reject_unauth_destination
smtpd_reject_unlisted_recipient = yes
smtpd_reject_unlisted_sender = no
smtpd_restriction_classes =
smtpd_sasl_auth_enable = yes
smtpd_sasl_authenticated_header = no
smtpd_sasl_exceptions_networks =
smtpd_sasl_local_domain = $myhostname
smtpd_sasl_path = smtpd
smtpd_sasl_security_options = noanonymous
smtpd_sasl_tls_security_options = $smtpd_sasl_security_options
smtpd_sasl_type = cyrus
smtpd_sender_login_maps =
smtpd_sender_restrictions =
smtpd_soft_error_limit = 10
smtpd_starttls_timeout = 300s
smtpd_timeout = 300s
smtpd_tls_CAfile =
smtpd_tls_CApath =
smtpd_tls_always_issue_session_ids = yes
smtpd_tls_ask_ccert = no
smtpd_tls_auth_only = no
smtpd_tls_ccert_verifydepth = 5
smtpd_tls_cert_file =
smtpd_tls_dcert_file =
smtpd_tls_dh1024_param_file =
smtpd_tls_dh512_param_file =
smtpd_tls_dkey_file = $smtpd_tls_dcert_file
smtpd_tls_exclude_ciphers =
smtpd_tls_key_file = $smtpd_tls_cert_file
smtpd_tls_loglevel = 0
smtpd_tls_mandatory_ciphers = medium
smtpd_tls_mandatory_exclude_ciphers =
smtpd_tls_mandatory_protocols = SSLv3, TLSv1
smtpd_tls_received_header = no
smtpd_tls_req_ccert = no
smtpd_tls_security_level =
smtpd_tls_session_cache_database =
smtpd_tls_session_cache_timeout = 3600s
smtpd_tls_wrappermode = no
smtpd_use_tls = no
soft_bounce = no
stale_lock_time = 500s
strict_7bit_headers = no
strict_8bitmime = no
strict_8bitmime_body = no
strict_mime_encoding_domain = no
strict_rfc821_envelopes = no
sun_mailtool_compatibility = no
swap_bangpath = yes
syslog_facility = mail
syslog_name = postfix
tls_daemon_random_bytes = 32
tls_export_cipherlist = ALL:+RC4:@STRENGTH
tls_high_cipherlist = !EXPORT:!LOW:!MEDIUM:ALL:+RC4:@STRENGTH
tls_low_cipherlist = !EXPORT:ALL:+RC4:@STRENGTH
tls_medium_cipherlist = !EXPORT:!LOW:ALL:+RC4:@STRENGTH
tls_null_cipherlist = !aNULL:eNULL+kRSA
tls_random_bytes = 32
tls_random_exchange_name = ${config_directory}/prng_exch
tls_random_prng_update_period = 3600s
tls_random_reseed_period = 3600s
tls_random_source = dev:/dev/urandom
trace_service_name = trace
transport_maps =
transport_retry_time = 60s
trigger_timeout = 10s
undisclosed_recipients_header = To: undisclosed-recipients:;
unknown_address_reject_code = 450
unknown_client_reject_code = 450
unknown_hostname_reject_code = 450
unknown_local_recipient_reject_code = 550
unknown_relay_recipient_reject_code = 550
unknown_virtual_alias_reject_code = 550
unknown_virtual_mailbox_reject_code = 550
unverified_recipient_reject_code = 450
unverified_sender_reject_code = 450
verp_delimiter_filter = -=+
virtual_alias_domains =
virtual_alias_expansion_limit = 1000
virtual_alias_maps = mysql:/etc/postfix/mysql_virtual_alias_maps.cf
virtual_alias_recursion_limit = 1000
virtual_destination_concurrency_limit = $default_destination_concurrency_limit
virtual_destination_recipient_limit = $default_destination_recipient_limit
virtual_gid_maps = static:1001
virtual_mailbox_base = /var/mailbox/
virtual_mailbox_domains = mysql:/etc/postfix/mysql_virtual_domains_maps.cf
virtual_mailbox_limit = 20971520
virtual_mailbox_lock = fcntl
virtual_mailbox_maps = mysql:/etc/postfix/mysql_virtual_mailbox_maps.cf
virtual_minimum_uid = 100
virtual_transport = maildrop
virtual_uid_maps = static:1001

=======================================================
这个是maillog的日志
an 10 14:05:06 server authdaemond: FAIL, all modules rejected
Jan 10 14:05:06 server postfix/pipe[10983]: 0835772C0AB: to=<linkui@mx.test.com>, relay=maildrop, delay=0.08, delays=0.02/0.01/0/0.05, dsn=5.1.1, status=bounced (user unknown. Command output: Invalid user specified. )
Jan 10 14:05:06 server postfix/cleanup[10979]: 19ADF72C0AC: message-id=<20080110060506.19ADF72C0AC@mx.test.com>
Jan 10 14:05:06 server postfix/qmgr[10726]: 19ADF72C0AC: from=<>, size=1949, nrcpt=1 (queue active)
Jan 10 14:05:06 server postfix/bounce[10985]: 0835772C0AB: sender non-delivery notification: 19ADF72C0AC
Jan 10 14:05:06 server postfix/qmgr[10726]: 0835772C0AB: removed
Jan 10 14:05:06 server authdaemond: received userid lookup request: root@test.com
Jan 10 14:05:06 server authdaemond: FAIL, all modules rejected
Jan 10 14:05:06 server postfix/pipe[10983]: 19ADF72C0AC: to=<root@test.com>, relay=maildrop, delay=0.01, delays=0/0/0/0.01, dsn=5.1.1, status=bounced (user unknown. Command output: Invalid user specified. )

guxing119 回复于:2008-01-10 16:42:28

感谢楼主分享,十分感谢

marion 回复于:2008-01-13 15:52:14

user unknown. Command output: Invalid user specified.

rabe 回复于:2008-01-14 15:21:35

引用:原帖由 marion 于 2008-1-13 15:52 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=7844833&ptid=987344
user unknown. Command output: Invalid user specified.

对啊一直有这个错误.自己发给自己也报......发到外网就可以,就是不能收信

falalala 回复于:2008-01-14 17:54:12

[root@mail postfix-2.4.6]# make makefiles 'CCARGS=-DHAS_MYSQL -I/usr/local/mysql/include/mysql -DUSE_SASL_AUTH -DUSE_CYRUS_SASL -I/usr/local/sasl2/include/sasl -I/usr/local/BerkeleyDB/include -DUSE_TLS -I/usr/local/ssl/include/openssl''AUXLIBS=-L/usr/local/mysql/lib/m
ysql -lmysqlclient -lz -lm -L/usr/local/sasl2/lib -lsasl2 -L/usr/local/BerkeleyDB/lib -L/usr/local/ssl/lib -lssl -lcrypto'
make -f Makefile.in MAKELEVEL= Makefiles
(echo "# Do not edit -- this file documents how Postfix was built for your machine."; /bin/sh makedefs) >makedefs.tmp
No <db.h> include file found.
Install the appropriate db*-devel package first.
See the RELEASE_NOTES file for more information.
make: *** [Makefiles] Error 1
make: *** [makefiles] Error 2

falalala 回复于:2008-01-16 10:00:56

不好意思,该问题找到了。是db.h 没做。

falalala 回复于:2008-01-16 13:14:29

configure courier-authlib-0.59.3时报错如下,请问如何解决?
configure: error: --with-authmysql specified but no mysqlclient.so

marion 回复于:2008-01-16 14:34:37

前面的帖子中多有讨论,帖子中也有相应的说明。
你可以试试以下方法
#echo "/usr/local/mysql/lib/mysql" >>/etc/ld.so.conf
#ldconfig -v

如果此步以后还不行,则进行下面的步骤
#ln -sv /usr/local/mysql/lib/mysql /usr/local/lib

falalala 回复于:2008-01-16 14:47:15

谢谢marion 及时地回复。
按照#ln -sv /usr/local/mysql/lib/mysql /usr/local/lib 做了一遍还是不行。请问还有可能是哪里的问题吗?

falalala 回复于:2008-01-16 15:44:42

我检查了我运行的
#echo "/usr/local/mysql/lib/mysql" >>/etc/ld.so.conf
#ldconfig -v
这两条命令,应该是这个命令没有生效,这个问题已经脱离了postfix,但还是希望marion能够指点一下
[root@mail lib]# ldconfig -v |grep mysql
ldconfig: Path `/usr/lib/mysql' given more than once
ldconfig: Can't stat /usr/local/mysql/lib/mysql:: No such file or directory
ldconfig: Can't stat libdbug.a: No such file or directory
ldconfig: Can't stat libheap.a: No such file or directory
ldconfig: Can't stat libmyisam.a: No such file or directory
ldconfig: Can't stat libmyisammrg.a: No such file or directory
ldconfig: Can't stat libmysqlclient.a: No such file or directory
ldconfig: Can't stat libmysqlclient.la: No such file or directory
ldconfig: Can't stat libmysqlclient_r.a: No such file or directory
ldconfig: Can't stat libmysqlclient_r.la: No such file or directory
ldconfig: Can't stat libmysqlclient_r.so: No such file or directory
ldconfig: Can't stat libmysqlclient_r.so.15: No such file or directory
ldconfig: Can't stat libmysqlclient_r.so.15.0.0: No such file or directory
ldconfig: Can't stat libmysqlclient.so: No such file or directory
ldconfig: Can't stat libmysqlclient.so.15: No such file or directory
ldconfig: Can't stat libmysqlclient.so.15.0.0: No such file or directory
ldconfig: Can't stat libmystrings.a: No such file or directory
ldconfig: Can't stat libmysys.a: No such file or directory
ldconfig: Can't stat libvio.a: No such file or directory
/usr/lib/mysql:
libmysqlclient.so.14 -> libmysqlclient.so.14.0.0
libmysqlclient_r.so.14 -> libmysqlclient_r.so.14.0.0
libmysqlclient.so.10 -> libmysqlclient.so.10.0.0
libmysqlclient_r.so.10 -> libmysqlclient_r.so.10.0.0
/usr/local/mysql/lib/mysql:
libmysqlclient.so.15 -> libmysqlclient.so.15.0.0
libmysqlclient_r.so.15 -> libmysqlclient_r.so.15.0.0
还有,我发现在/usr/lib下面原来是存在一个mysql目录,不知是否有影响。
该怎么解决这个问题呢?

falalala 回复于:2008-01-16 16:45:30

问题解决了,解决办法就是删除原有rpm包mysql
然后执行
#echo "/usr/local/mysql/lib/mysql" >>/etc/ld.so.conf
#ldconfig -v
总之就是库文件链接问题。

falalala 回复于:2008-01-18 11:47:59

Jan 18 11:42:19 mail pop3d: Connection, ip=[192.168.0.2]
Jan 18 11:42:19 mail authdaemond: received auth request, service=pop3, authtype=login
Jan 18 11:42:19 mail authdaemond: authmysql: trying this module
Jan 18 11:42:19 mail authdaemond: SQL query: SELECT username, password, "", '2525', '2525', concat('/var/mailbox/',maildir), "", "", name, "" FROM mailbox WHERE username = "test@test.com"
Jan 18 11:42:19 mail authdaemond: password matches successfully
Jan 18 11:42:19 mail authdaemond: authmysql: sysusername=<null>, sysuserid=2525, sysgroupid=2525, homedir=/var/mailbox/test.com/test/Maildir/, address=test@test.com, fullname=test, maildir=<null>, quota=<null>, options=<null>
Jan 18 11:42:19 mail authdaemond: authmysql: clearpasswd=<null>, passwd=$1$D6kiF7cp$IC5WcnNJgUrFzV/30iS5N1
Jan 18 11:42:19 mail authdaemond: Authenticated: sysusername=<null>, sysuserid=2525, sysgroupid=2525, homedir=/var/mailbox/test.com/test/Maildir/, address=test@test.com, fullname=test, maildir=<null>, quota=<null>, options=<null>
Jan 18 11:42:19 mail authdaemond: Authenticated: clearpasswd=test123, passwd=$1$D6kiF7cp$IC5WcnNJgUrFzV/30iS5N1
Jan 18 11:42:19 mail pop3d: chdir Maildir: No such file or directory

虽然在上述贴子中看到类似错误,,但我的仍然没有解决。。,请楼主帮看看了。。

[ 本帖最后由 falalala 于 2008-1-18 11:52 编辑 ]

falalala 回复于:2008-01-18 11:51:07

Jan 18 11:42:19 mail pop3d: Connection, ip=[192.168.0.2]
Jan 18 11:42:19 mail authdaemond: received auth request, service=pop3, authtype=login
Jan 18 11:42:19 mail authdaemond: authmysql: trying this module
Jan 18 11:42:19 mail authdaemond: SQL query: SELECT username, password, "", '2525', '2525', concat('/var/mailbox/',maildir), "", "", name, "" FROM mailbox WHERE username = "test@test.com"
Jan 18 11:42:19 mail authdaemond: password matches successfully
Jan 18 11:42:19 mail authdaemond: authmysql: sysusername=<null>, sysuserid=2525, sysgroupid=2525, homedir=/var/mailbox/test.com/test/Maildir/, address=test@test.com, fullname=test, maildir=<null>, quota=<null>, options=<null>
Jan 18 11:42:19 mail authdaemond: authmysql: clearpasswd=<null>, passwd=$1$D6kiF7cp$IC5WcnNJgUrFzV/30iS5N1
Jan 18 11:42:19 mail authdaemond: Authenticated: sysusername=<null>, sysuserid=2525, sysgroupid=2525, homedir=/var/mailbox/test.com/test/Maildir/, address=test@test.com, fullname=test, maildir=<null>, quota=<null>, options=<null>
Jan 18 11:42:19 mail authdaemond: Authenticated: clearpasswd=test123, passwd=$1$D6kiF7cp$IC5WcnNJgUrFzV/30iS5N1
Jan 18 11:42:19 mail pop3d: chdir Maildir: No such file or directory

上面的帖子,,有类似错误,,参考了,但我的仍然没有解决,,请给各检查思路,,

falalala 回复于:2008-01-18 14:18:22

请问搂主安装完“十三、安装Extman-0.2.2“,邮件系统就应该就具备收发功能了吧?
我安装完”十三、安装Extman-0.2.2“后,想先测试一下邮件系统,但发现outlook和webmail都可以发送邮件,但都不能收邮件。
日志中的错误信息显示:
Jan 18 14:14:13 mail pop3d: chdir Maildir: No such file or directory
这是什么原因呢?

marion 回复于:2008-01-18 18:46:40

是不是本地域和虚拟域使用了相同的域名?

jdwu 回复于:2008-01-19 07:16:20

marion兄 新手请教

安装到maildrop 结束 无法打开extmail登陆界面
suexec_log
target uid/gid(1001/1001)mismatch directory(2525/2525)or program(2525/2525)

当然 也没有下面的信息
如果日志中的记录类同以下项,则安装成功

Sep 16 12:04:43 Ixor postfix/pipe[14266]: 46B491A5CB: to=<marion@test.com>, relay=maildrop,

delay=2306, delays=2306/0.04/0/0.07, dsn=2.0.0, status=sent (delivered via maildrop service)
请问这个问题出在哪里?

marion 回复于:2008-01-19 09:26:11

target uid/gid(1001/1001)mismatch directory(2525/2525)or program(2525/2525)

有些目录的属主或服务的运行身份没能正确指向到1001用户。

jdwu 回复于:2008-01-19 17:18:04

引用:原帖由 marion 于 2008-1-19 09:26 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=7873139&ptid=987344
target uid/gid(1001/1001)mismatch directory(2525/2525)or program(2525/2525)

有些目录的属主或服务的运行身份没能正确指向到1001用户。


看了你的回帖,我通过chown -R vmail.vmail /var/www/ 把问题解决了 遇到同样问题的朋友可以参考下

谢谢marion兄 我是初学者 07年12月26日开始装Linux 到架构DNS WEB postfix 遇到了很多困难,大部分是通过google 和前面各位回帖解决的,里面有很多不懂的地方,很多问题虽然解决了,这还不够,以后我还会深入学习。
在此感谢各位无私奉献的精神,我想我要做的是学会然后传承。

zmcjs 回复于:2008-01-19 22:06:55

要是能做成pdf发布就好了!

柳拂风 回复于:2008-01-21 10:46:47

请教楼主:
安装maildrop的作用是什么?装上它有什么好处?

我装上maildrop以后,给别人发邮件正常,但是不能给自己发邮件,日志里也看不出什么来,没法搞定。
于是我把maildrop删了。于是一切正常了,下面的病毒扫描和垃圾邮件过滤等也正常。

就是说我没使用maildrop,邮件系统也一切正常。
那么,为什么要多装一个maildrop呢?
装它的目的是什么?
是不是可以提升性能?
麻烦你给我解答一下,谢谢。

falalala 回复于:2008-01-21 10:53:22

marion ,感谢了,就是这个原因,本地域和虚拟域使用了相同的域名造成的。现在已经好了。
那我还想问一个概念性的问题。本地域和虚拟域主要区别在哪里? 我有3个域邮箱甚至更多的域,其中一个是主要的,那这个主要的是放到本地域里好,还是放到虚拟域里好。extmail能否管理本地域?如果不能,我是否可以不要本地域,全部采用虚拟域,这样可以吗?请给个意见。。

柳拂风 回复于:2008-01-21 11:05:00

楼上,
我觉得本地域没什么用,是乱写的,
我注册的域名都是配成虚拟域来使用,收发邮件都是用虚拟域。
呵呵~~

marion 回复于:2008-01-21 12:39:39

独立的MDA,更为精细的邮件投递控制。

本文仅讲了安装,没有更多的篇幅讲使用方法,可以google,相关文章很多。

marion 回复于:2008-01-21 12:41:20

可以全部采用虚拟域

柳拂风 回复于:2008-01-21 13:57:14

谢谢解答。

在按照楼主的文档安装完后,
我又增加了Spam Locker,与SpamAssassin一起并用。
看起来还收发都正常。
不知楼主有没有用过Spam Locker?跟SpamAssassin相比哪个过滤效果好一些?

changchun_li 回复于:2008-01-22 14:31:44

能用现在最新的源码 在安装一次吗

现在很多都改了
认证都用dovecot 了 十分期待中。。。。。。。。。。。。。。。。

falalala 回复于:2008-01-22 15:53:45

刚开始,在http://www.oracle.com/technology/software/products/berkeley-db/index.html[/url这里下载 db-4.5.20.tar.gz 并且安装文档步骤安装完毕
在第17步“十七、安装amavisd-new-2.5.2”中,又安装文档在http://search.cpan.org 这里下载了BerkeleyDB-0.33.tar.gz 并安装之。
接下来在我使用命令[root@mail db4]# /usr/local/sbin/amavisd debug
Problem in Amavis::DB or Amavis::DB::SNMP code:
BerkeleyDB needs compatible versions of libdb & db.h
you have db.h version 4.5.20 and libdb version 4.2.52
Compilation failed in require at (eval 92) line 15.
BEGIN failed--compilation aborted at (eval 92) line 15.
会报如下错误。虽然错误说的db.h version 4.5.20 and libdb version 4.2.52不兼容,看了之前的贴子也有遇到过这个问题,但好像没有解决方法。请问怎么解决呢?

falalala 回复于:2008-01-22 17:33:41

请问这位兄弟,你是如何解决了这个问题的?

falalala 回复于:2008-01-22 17:46:32

我有遇到和这个问题相同的错误,也尝试了重新链接头文件,但始终没有解决,请给与解决办法?

falalala 回复于:2008-01-22 17:48:02

引用:原帖由 marion 于 2007-11-9 17:14 发表 [url=http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=7572888&ptid=987344]http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=7572888&ptid=987344



头文件引用错误,期望得到新安装的版本,但找到的是旧有的版本。请确认前面 BerkeleyDB部分关于重新链接头文件的步骤已经正确执行。或者手动重新链接报错的头文件到正确的位置。



我有遇到和这个问题相同的错误,也尝试了重新链接头文件,但始终没有解决,请给与解决办法?

柳拂风 回复于:2008-01-25 09:02:50

我在RHEL5.1上面装的,
好像没遇到上面几位说的问题。
btw,相关的lib我尽量使用RHEL5.1光盘自带的rpm包来安装。

柳拂风 回复于:2008-01-25 16:39:31

郁闷
我在另一台服务器上装,遇到这个问题了
汗~~~

柳拂风 回复于:2008-01-25 18:15:40

郁闷啊
在另一台服务器上死活搞不定,同样都是RHEL5.1的系统啊
只好禁用BerkeleyDB:
# vi /etc/amavisd.conf
$enable_db = 0;

目前收发正常,垃圾邮件也能过滤。
只是不知道禁用BerkeleyDB会不会有什么隐患?

rubylrn 回复于:2008-01-28 10:38:24

努力呵呵 学生来过了 我偶然间发现的:em03: :em03: :em03:

jd_chen 回复于:2008-01-30 20:47:39

后续部分是什么呀??????

zzm183 回复于:2008-01-30 23:04:10

我的测试邮箱服务器出问题了 前几天还好好的 没动过配置 今天突然发不了信了 能收信
6FF8B1F78C4: from=<ftpdata@XXXXXXX>, size=578, nrcpt=1 (queue active)
Jan 30 22:48:34 hzhjsj postfix/smtp[3170]: connect to yahoo.com.cn[202.165.102.205]: Connection timed out (port 25)
Jan 30 22:48:34 hzhjsj postfix/smtp[3170]: 6FF8B1F78C4: to=<zjx1183@yahoo.com.cn>, relay=none, delay=505, delays=475/0.02/30/0, dsn=4.4.1, status=deferred (connect to yahoo.com.cn[202.165.102.205]: Connection timed out)
发每个邮箱都这样 发自己内网邮箱没问题
各们大大们帮我看看出什么问题了?谢~~~~```

pcb2000 回复于:2008-01-30 23:28:32

我也遇到了这一问题.
cpan官网对这一问题的解决方案:

Another variation on the theme of having two versions of Berkeley DB on
your system.

Solution: Setting the LIB & INCLUDE variables in config.in to point to the
correct directories can sometimes be enough to fix this
problem. If that doesn't work the easiest way to fix the
problem is to either delete or temporarily rename the copies
of db.h and libdb.a that you don't want BerkeleyDB to use.

出处:
http://www.cpan.org/modules/by-module/BerkeleyDB/BerkeleyDB-0.10.readme

柳拂风 回复于:2008-01-31 08:59:19

If that doesn't work the easiest way to fix the problem is to either delete or temporarily rename the copies of db.h and libdb.a that you don't want BerkeleyDB to use.

看来禁用BerkeleyDB也是可以的,哈哈哈


猜测它禁用BerkeleyDB后,应该使用文本来存数据吧?
访问量不大的话,我觉得应该不会有什么问题的。

柳拂风 回复于:2008-01-31 09:00:41

我来狗尾续貂

楼主别见怪啊

柳拂风 回复于:2008-01-31 09:04:37

安装Spam Locker

前面安装的SpamAssassin是基于"邮件内容"来进行判别的垃圾邮件过滤系统,
而Spam Locker是基于邮件"发送行为"来进行判别的垃圾邮件过滤系统。

两种模式的垃圾邮件过滤系统孰优孰劣在此不做评判,请安装者自行选择。
两个过滤系统可分别安装,也可以并存运行。

Spam Locker简称slockd,
下载地址:http://www.extmail.org/download/
Spam Locker要用到的perl模块:
Net::DNS
Digest::MD5
Digest::SHA1
Digest::HMAC
Net::IP

安装步骤
解包然后将slockd-xxxx 改名并移动到/usr/local目录,
# tar -zxvf slockd-0.10.tar.gz
# mv slockd-0.10 slockd
# mv slockd /usr/local/
配置slockd:
进入/usr/local/slockd目录,编辑config/main.cf 配置文件,每个配置参数都有简短的注释,如果要修改的话,请仔细阅读注释后方可修改。
默认情况下,slockd将只监听127.0.0.1(localhost)的10030端口,公网是无法访问这一服务的,
这样做是为了安全起见,防止被其他有心人利用来做坏事。默认的日志将在标准的输出和标准错误输出(STDERR)显示。

将如下行去掉注释:
setsid 1
使之以后台的方式运行。
接下来,可以配置slockd的日志路径和pid文件路径,默认配置为:
log_file /var/log/slockd.log
pid_file /var/run/slockd.pid

启动slockd:
# /usr/local/slockd/slockd-init start
添加开机时自动执行
# echo "/usr/local/slockd/slockd-init start" >> /etc/rc.local

进入/usr/local/slockd/tools 目录,输入:
perl policy_sig -h localhost -p 10030 --helo FOOBAR \
--ip 192.168.0.1 --from [email=test@foo.com]test@foo.com[/email] --to [email=test@bar.com]test@bar.com[/email]
此时,程序应该返回如下错误信息:
action=504 <FOOBAR>: rejected, see [url=http://bl.extmail.org/cgi/why?fqdn]http://bl.extmail.org/cgi/why?fqdn
这表示slockd初步的正常工作了。
配置MTA:
编辑/etc/postfix/main.cf
将“check_policy_service inet:127.0.0.1:10030”记录增加到smtpd_recipient_restrictions 里,
一个建议的配置如下:
########## slockd ##########
smtpd_recipient_restrictions =
permit_mynetworks,
permit_sasl_authenticated,
reject_non_fqdn_hostname,
reject_non_fqdn_sender,
reject_non_fqdn_recipient,
reject_unauth_destination,
reject_unauth_pipelining,
reject_invalid_hostname,
check_policy_service inet:127.0.0.1:10030
########## slockd end ##########
配置完毕后,重新启动postfix。
注意的是,上面的配置是将slockd的查询放到最后,这也是进一步提高资源利用率的办法,
因为有部分功能postfix已实现了,所以就先由postfix检测,如果检测不到再由slockd完成。

[ 本帖最后由 柳拂风 于 2008-1-31 11:07 编辑 ]

柳拂风 回复于:2008-01-31 09:11:04

增加Chinese_rules.cf支持
Chinese_rules.cf是教育科研网的反垃圾邮件小组对大量垃圾邮件和正常邮件进行分析后得出的一个关键字/分数规则集,
用于处理中文(简体)垃圾邮件。这里我们通过如下命令增加到系统:
# wget -N -P /usr/share/spamassassin [url=http://www.ccert.edu.cn/spam/sa/Chinese_rules.cf]http://www.ccert.edu.cn/spam/sa/Chinese_rules.cf

运行以下调试命令以确认amavisd没有错误:
# /usr/sbin/amavisd debug
如果没有异常提示或报错退出则表示一切都正常,按ctrl+c终止。

重启amavisd服务。

也可以将获取Chinese_rules.cf 的命令添加到crond中以便更新。








2008年02月26日更改:
本人经过一段时间的使用,觉得Chinese_rules.cf 的词汇量太少了(看文件的日期两年没有更新了),对中文垃圾邮件的过滤效果不是很理想(这只是本人的感觉,实际效果请自行测试)。
现已改用另外的规则表(见附件)
将附件中的cf文件复制到/usr/share/spamassassin下,
#unzip spamassassin-rules.zip
# cd spamassassin-rules/
# cp *.cf /usr/share/spamassassin/
重启spamassassin和amavisd

这三个规则表来源于网上,原作者是“疯狂老头”。
详见http://www.extmail.org/forum/thread-5341-1-1.html
(原规则表对垃圾词汇的打分很高,本人已对这三个表的分值做了修改,降低到原来的三分之一以下。
如果你知道spamassassin的分值是怎么回事,并希望采用原来的分值,请到上面的地址下载原文件。)



坛子为什么不能重新上传附件的?
想更新一下,变成两个附件了!汗~~

[ 本帖最后由 柳拂风 于 2008-3-7 11:49 编辑 ]

spamassassin-rules.zip

spamassassin-rules.zip

柳拂风 回复于:2008-01-31 09:19:28

增加FCGI支持

为extmail增加FCGI的支持,主要是为了获得优异的web效能,克服CGI不能应付大量访问及低效率的缺陷。
据说,FCGI的页面效率是CGI模式的十倍以上。

安装mod_fastcgi
mod_fastcgi 是针对Apache Web服务器的FCGI支持模块,
下载地址[url=http://www.fastcgi.com/dist/mod_fastcgi-2.4.6.tar.gz]http://www.fastcgi.com/dist/mod_fastcgi-2.4.6.tar.gz

# tar -zxvf mod_fastcgi-2.4.6.tar.gz
# cd mod_fastcgi-2.4.6
# cp Makefile.AP2 Makefile
# make top_dir=/usr/local/apache install

除了Apache需要FCGI的支持外,extmail也需要相应的perl-FCGI模块。
下载地址http://dries.ulyssis.org/rpm/packages/perl-FCGI/info.html
用以下命令安装:
# rpm -ivh perl-FCGI-0.67-1.2.el5.rf.i386.rpm
(请安装跟你的操作系统版本对应的安装包)

在apache的配置文件的Extmail虚拟主机部分,添加如下内容:
LoadModule fastcgi_module modules/mod_fastcgi.so
<Ifmodule mod_fastcgi.c>
FastCgiExternalServer /var/www/extsuite/extmail/dispatch.fcgi -host 127.0.0.1:8888
</Ifmodule>
同时,去掉如下行:
ScriptAlias /extmail/cgi/ /var/www/extsuite/extmail/cgi/
Alias /extmail /var/www/extsuite/extmail/html
ScriptAlias /extman/cgi/ /var/www/extsuite/extman/cgi/
Alias /extman /var/www/extsuite/extman/html

改为:
Alias /extmail/cgi/ /var/www/extsuite/extmail/dispatch.fcgi/
Alias /extmail /var/www/extsuite/extmail/html
Alias /extman/cgi/ /var/www/extsuite/extmail/dispatch.fcgi/
Alias /extman /var/www/extsuite/extman/html
<Location "/extmail/cgi">
SetHandler fastcgi-script
</Location>
<Location "/extman/cgi">
SetHandler fastcgi-script
</Location>

然后编辑/var/www/extsuite/extmail/dispatch-init文件,修改如下:
SU_UID=vmail
SU_GID=vmail
BASE=/var/www/extsuite/extmail

启动fastcgi server:
# /var/www/extsuite/extmail/dispatch-init start
如果没有意外将启动5个dispatch.fcgi守护进程.
添加自启动:
# echo "/var/www/extsuite/extmail/dispatch-init start" >> /etc/rc.d/rc.local
重启apache
# /usr/local/apache/bin/apachectl restart

[ 本帖最后由 柳拂风 于 2008-2-17 15:02 编辑 ]

柳拂风 回复于:2008-01-31 09:24:44

在楼主的帖子里发上面的东西实在是很冒昧,还请见谅。

我准备研究把postfix套装当作反垃圾邮件网关来用,研究成功的话,再发上来给大家看看。

marion 回复于:2008-01-31 09:29:54

我后续想做的工作其实就是SpamLocker,FastCGI和SMTPS、pops,只是最近没有时间一直没时间做,柳兄高义,既然已经有成果,拿出来共享这是大家风范,不必谈什么“见谅”。

回头测试一下,而后把它们加到原帖中去。到时候借用了,也请不要见怪。:em03:

柳拂风 回复于:2008-02-02 10:12:16

设置反垃圾邮件网关

将此邮件系统套装设置成一个反垃圾邮件网关来使用,为没有过滤功能的邮件系统提供过滤服务。
前提是本postfix系统主机具有公网ip或做了端口映射(总之是能直接接收来自internet的邮件),
并能访问到旧邮件系统主机。

本例如下:
一个旧邮件系统example.com,
ip=211.147.xx.xx
已作如下域名解析
mail.example.com
pop3.example.com
smtp.example.com
都指向211.147.xx.xx
并做MX记录指向mail.example.com

因系统较老,没有垃圾邮件过滤功能,上面又有大量用户,不方便更换系统,
而购买商业反垃圾邮件网关又价格昂贵,拟使用本postfix系统来为其作垃圾邮件过滤。

旧邮件系统无须作任何更改,所有操作都是针对本postfix系统的。

新建域名解析mailgw.example.com,使其指向本postfix系统主机ip,
并修改原MX记录,使其指向mailgw.example.com

修改本postfix系统的配置:
# vi /etc/postfix/main.cf
在后面加入两行
relay_domains = example.com
transport_maps = hash:/etc/postfix/transport_maps

新建文件
# vi /etc/postfix/transport_maps
加入一行
example.com relay:[211.147.xx.xx]

生成db文件:
# /usr/local/postfix/sbin/postmap /etc/postfix/transport_maps
查看确认db文件已生成:
# ls -l /etc/postfix/transport_maps.db
-rw-r--r-- 1 root root 12288 02-01 14:45 /etc/postfix/transport_maps.db

重启postfix,
使用第三方邮件系统(比如网易邮箱)发送邮件到user@example.com进行测试,
查看/var/log/maillog,
成功的话可以看到如下信息:
Feb 1 17:25:43 vtest postfix/smtp[9330]: 81CAC458400: to=<user@example.com>, relay=211.147.xx.xx[211.147.xx.xx]:25, delay=0.41, delays=0.26/0.03/0.08/0.05, dsn=2.0.0, status=sent (250 2.0.0 Ok: queued as 3F57846098D)
Feb 1 17:25:43 vtest postfix/qmgr[9319]: 81CAC458400: removed

表明发往user@example.com的邮件已经被转发到211.147.xx.xx上了。
登陆旧邮件系统进行查收。

注:此邮件网关仅对来自internet的邮件进行过滤,而用户日常收发邮件仍然直接使用旧的系统,这样做对旧邮件系统几乎没有影响。
(参考资料:《POSTFIX权威指南》第九章)

柳拂风 回复于:2008-02-02 10:34:41

配置DNS缓存

发送邮件时,系统必须到DNS服务器上进行查询,如果自己有DNS服务器或者DNS缓存,会大大加快域名查询速度。
这里安装的是djbdns,如果你装有bind的话,就不要装这个了。
进入本安装包install-djbdns-rpm目录(见附件),运行install.sh安装,
注:install.sh最后两行的ip地址是广西电信的DNS服务器地址,运行前请修改为你所在区域的dns服务器地址。
(你也可以自己去下载djbdns的源码来编译安装,下载地址及安装教程 http://cr.yp.to/djbdns.html,这个貌似很麻烦~~)

启动
# /etc/init.d/djbdns start
启动正常的话会在53端口监听
验证djbdns是否起作用:
# dig [url=http://www.163.com]www.163.com (别的网站域名也可以)
再执行一次上述命令,应该能感觉到第二次运行时的响应速度明显比第一次快。

刷新DNS缓存:
有时候互联网上的DNS记录已经发生改变了,而你的DNS缓存还是旧的,可用如下命令来刷新
# /usr/bin/svc -t /service/dnscache
你也可以将上述命令写个脚本添加到crontab进行定期刷新:
# vi /root/flush_dns.sh
添加下行
/usr/bin/svc -t /service/dnscache
# chmod 755 /root/flush_dns.sh
# crontab -e
添加下行
1 1 * * * /root/flush_dns.sh


(这个本不应属于postfix邮件服务器的一部分的,加进来只是为了方便一点。如果你的邮件数量不是很多的话,作DNS缓存的意义不大;如果你经常往外大量群发邮件,就比较有用了。)

install-djbdns-rpm.tar.gz

柳拂风 回复于:2008-02-02 10:48:41

坛子里很冷清了啊
大家都放假回家过年了吧
在此给各位拜个年先~

junger 回复于:2008-02-02 12:12:26

年底了,太忙了,

好久没来了,

没想到来了这么多高人!

继续学习!

junger 回复于:2008-02-02 12:17:23

第一个命令是指定以postfix的身份用来登录的,结果显然是给定的密码或者是用户身份错误而无法登录。

第二个命令类同第一个,不过密码要是用引号引起来可能会更好些。

第三个就是个错误的使用方法。

楼上解释过,看来咱们两个出现了同样的错误。

柳拂风 回复于:2008-02-13 09:13:22

忽然发现,
这里边没用到php呀,装它干嘛呢? :mrgreen: :mrgreen: :mrgreen:

yh81521 回复于:2008-02-13 22:58:08

在sasl认证这块我的变量取值是错的,不知道怎么回事.配置文件如下:
=====================
pwcheck_method: auxprop
auxprop_plugin: sql
mech_list: plain login
sql_engine: mysql
sql_hostnames: localhost
sql_user: postfix
sql_passwd: postfix
sql_database: postfix
sql_select: SELECT password FROM mailbox WHERE username='%u@%r' and domain='%r' and active='1'
=======================
因为sasl认证总是不能成功,查询日志message是 无法查询到结果.
Feb 13 21:29:25 hirain sshd(pam_unix)[4488]: session opened for user root by root(uid=0)
Feb 13 21:30:02 hirain postfix/smtpd[4372]: sql plugin: no result found
Feb 13 21:30:02 hirain postfix/smtpd[4372]: sql plugin: no result found

查看mysql查询日志.配置文件中username='%u@%r' 的取值是错的.

080213 22:23:15 243 Connect postfix@localhost on postfix
243 Quit
244 Connect postfix@localhost on postfix
244 Quit
245 Connect postfix@localhost on postfix
245 Query START TRANSACTION
245 Query SELECT password FROM mailbox WHERE username='hyang.com@domain.com' and domain='domain.com' and active='1'
245 Query SELECT password FROM mailbox WHERE username='hyang.com@domain.com' and domain='domain.com' and active='1'
245 Query COMMIT
245 Quit
================================
我要认证邮件是[email=hyang@domain.com]hyang@domain.com[/email]但是查询时用户名 %u 取值 成了 "hyang.com" 了. mysql数据库中是没问题的.
我就是想知道smtpd.conf中的 %u [被获取或存储属性的用户的用户名].这个用户名应该是 hyang 才对,不知道它是怎么取值的?我应该改什么?
是否能够支持表达式,把后边的.com去掉, 但是官方主业上说只支持4各变量: %u %r %p %v,没有其它的了..
我该怎么办,谁来救救我啊!!!!!!!!!!!!!!!!!


[ 本帖最后由 yh81521 于 2008-2-14 11:34 编辑 ]

skeche 回复于:2008-02-14 01:14:07

楼主做了一件大功德

yh81521 回复于:2008-02-14 20:54:10

好冷清啊,都忙着过会情人去了....

dreamever 回复于:2008-02-16 16:05:36

好复杂啊,想配个邮件服务器,看来两个星期是不行了。。
怎么那么多包呢,有没有一个集成的。从网上找那些包好麻烦啊。

unixnovice 回复于:2008-02-16 19:13:46

建议加入smtpS和POP3S

柳拂风 回复于:2008-02-17 12:55:48

我把这些软件都打成一个包了,
要的话你去下载吧
http://www.dragonflys.cn/download/postfix.tar.gz

fdhunter 回复于:2008-02-19 08:35:01

引用:原帖由 柳拂风 于 2008-2-17 12:55 发表 [url=http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=7969494&ptid=987344]http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=7969494&ptid=987344

我把这些软件都打成一个包了,
要的话你去下载吧
http://www.dragonflys.cn/download/postfix.tar.gz

帅哥,下载不了啊!

柳拂风 回复于:2008-02-19 08:51:24

不好意思,
在测试的时候把机子搞挂了,
可能正好让你赶上了。

你再试试,不行的话我放到别的服务器上。

[ 本帖最后由 柳拂风 于 2008-2-19 08:52 编辑 ]

marion 回复于:2008-02-19 16:33:09

引用:我把这些软件都打成一个包了,
要的话你去下载吧
http://www.dragonflys.cn/download/postfix.tar.gz



:em03: 功得无量……

柳拂风 回复于:2008-02-20 09:37:45

比较郁闷的一个问题,很多ip地址被列入黑名单了,搞得发不了邮件

mail postfix/smtpd[31682]: NOQUEUE: reject: RCPT from unknown[58.59.xx.xx]: 450 4.7.1 <webmaster@xxx.com>: Recipient address rejected: rejected, see http://bl.extmail.org/cgi/freq?58.59.xx.xx; from=<test@xx.cn> to=<webmaster@xxx.com> proto=ESMTP helo=<mail.test.com>

总不能一个ip一个ip的去设白名单吧?那一万年也搞不完啊。
有什么好办法吗?

[ 本帖最后由 柳拂风 于 2008-2-20 09:40 编辑 ]

colderhua 回复于:2008-02-22 10:50:58

请教marion 兄弟,帮忙看看是那里出问题了,我在postfix,extman,extmail都指明了用/var/mailbox,但寄信去寄到/var/mail里去了.谢谢

# echo "test"| maildrop -V 10 -d test01@test.com
maildrop: authlib: groupid=1001
maildrop: authlib: userid=1001
maildrop: authlib: logname=test01@test.com,

home=/var/mailbox/test.com/test01/Maildir/, mail=(default)
maildrop: Changing to /var/mailbox/test.com/test01/Maildir/
Message start at 0 bytes, envelope sender=test01@test.com
Tokenized logfile
Tokenized string: "/var/log/maildrop.log"
Tokenized ;
Tokenized eof
/etc/maildroprc(1): Opening logfile /var/log/maildrop.log
maildrop: Attempting .mailfilter
maildrop: Delivering to /var/mail/test01@test.com
maildrop: Flock()ing /var/mail/test01@test.com.
maildrop: Appending to /var/mail/test01@test.com.
maildrop: Delivery complete.

colderhua 回复于:2008-02-22 15:49:30

已经解决问题

修改/etc/maildroprc,
增加
to "$HOME/Maildir"

就行了.

junger 回复于:2008-02-22 17:25:16

人气这么旺啊!

kepa520 回复于:2008-02-25 11:44:18

楼主,我在安装Berkeley-DB时,到修改头文件的指向时出错,提示找不到文件或目录,但我明明能看到文件夹和文件啊,错误如图,请帮忙看一下,谢谢!
截图_2025-11-15_15-20-09.jpg
截图_2025-11-15_15-20-09.jpg (186.31 KiB) 查看 854 次
junger 回复于:2008-02-27 09:25:37

你再看看你的输入是否有错误?

好像不是/usr/inculde/db4吧!

# mv /usr/include/db4 /usr/inculde/db4.OFF

gdou007 回复于:2008-02-27 16:16:47

防火墙和SELinux都是关闭的

1、访问Extmail报错如下:

Forbidden

You don't have permission to access / on this server.

2、报错日志信息如下:
#cat /usr/local/apache/logs/suexec_log
[2008-02-27 13:15:34]: uid: (2525/postfix) gid: (2525/2525) cmd: index.cgi
[2008-02-27 13:15:34]: command not in docroot (/var/www/extsuite/extmail/cgi/index.cgi)
[2008-02-27 13:24:53]: too few arguments

#cat /usr/local/apache/logs/error_log
[Wed Feb 27 13:48:53 2008] [error] [client 192.168.3.49] client denied by server configuration: /var/www/extsuite/extmail/html/
[Wed Feb 27 13:50:24 2008] [error] [client 192.168.3.49] client denied by server configuration: /var/www/extsuite/extmail/cgi/index.cgi


3、httpd.conf 配置如下:

ServerRoot "/usr/local/apache"

Listen 80


# Example:
# LoadModule foo_module modules/mod_foo.so
#
LoadModule authn_file_module modules/mod_authn_file.so
LoadModule authn_dbm_module modules/mod_authn_dbm.so
LoadModule authn_anon_module modules/mod_authn_anon.so
LoadModule authn_dbd_module modules/mod_authn_dbd.so
LoadModule authn_default_module modules/mod_authn_default.so
LoadModule authz_host_module modules/mod_authz_host.so
LoadModule authz_groupfile_module modules/mod_authz_groupfile.so
LoadModule authz_user_module modules/mod_authz_user.so
LoadModule authz_dbm_module modules/mod_authz_dbm.so
LoadModule authz_owner_module modules/mod_authz_owner.so
LoadModule authz_default_module modules/mod_authz_default.so
LoadModule auth_basic_module modules/mod_auth_basic.so
LoadModule auth_digest_module modules/mod_auth_digest.so
LoadModule dbd_module modules/mod_dbd.so
LoadModule dumpio_module modules/mod_dumpio.so
LoadModule ext_filter_module modules/mod_ext_filter.so
LoadModule include_module modules/mod_include.so
LoadModule filter_module modules/mod_filter.so
LoadModule substitute_module modules/mod_substitute.so
LoadModule deflate_module modules/mod_deflate.so
LoadModule log_config_module modules/mod_log_config.so
LoadModule logio_module modules/mod_logio.so
LoadModule env_module modules/mod_env.so
LoadModule expires_module modules/mod_expires.so
LoadModule headers_module modules/mod_headers.so
LoadModule ident_module modules/mod_ident.so
LoadModule setenvif_module modules/mod_setenvif.so
LoadModule ssl_module modules/mod_ssl.so
LoadModule mime_module modules/mod_mime.so
LoadModule dav_module modules/mod_dav.so
LoadModule status_module modules/mod_status.so
LoadModule autoindex_module modules/mod_autoindex.so
LoadModule asis_module modules/mod_asis.so
LoadModule info_module modules/mod_info.so
LoadModule suexec_module modules/mod_suexec.so
LoadModule cgi_module modules/mod_cgi.so
LoadModule dav_fs_module modules/mod_dav_fs.so
LoadModule vhost_alias_module modules/mod_vhost_alias.so
LoadModule negotiation_module modules/mod_negotiation.so
LoadModule dir_module modules/mod_dir.so
LoadModule imagemap_module modules/mod_imagemap.so
LoadModule actions_module modules/mod_actions.so
LoadModule speling_module modules/mod_speling.so
LoadModule userdir_module modules/mod_userdir.so
LoadModule alias_module modules/mod_alias.so
LoadModule rewrite_module modules/mod_rewrite.so
LoadModule php5_module modules/libphp5.so

<IfModule !mpm_netware_module>
<IfModule !mpm_winnt_module>

User postfix
Group postfix

</IfModule>
</IfModule>

ServerAdmin you@example.com

ServerName mail.ch.com:80

DocumentRoot "/var/www"

<Directory />
Options FollowSymLinks
AllowOverride None
Order deny,allow
Deny from all
</Directory>

<Directory "/usr/local/apache/htdocs">

Options Indexes FollowSymLinks
AllowOverride None
Order allow,deny
Allow from all
</Directory>

<IfModule dir_module>
DirectoryIndex index.html index.php
</IfModule>

<FilesMatch "^\.ht">
Order allow,deny
Deny from all
Satisfy All
</FilesMatch>

ErrorLog "logs/error_log"

LogLevel warn

<IfModule log_config_module>
LogFormat "%h %l %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-Agent}i\"" combined
LogFormat "%h %l %u %t \"%r\" %>s %b" common

<IfModule logio_module>
# You need to enable mod_logio.c to use %I and %O
LogFormat "%h %l %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-Agent}i\" %I %O" combinedio
</IfModule>

CustomLog "logs/access_log" common

</IfModule>

<IfModule alias_module>

ScriptAlias /cgi-bin/ "/usr/local/apache/cgi-bin/"

</IfModule>

<IfModule cgid_module>
# ScriptSock: On threaded servers, designate the path to the UNIX
# socket used to communicate with the CGI daemon of mod_cgid.
#Scriptsock logs/cgisock
</IfModule>

<Directory "/usr/local/apache/cgi-bin">
AllowOverride None
Options None
Order allow,deny
Allow from all
</Directory>


DefaultType text/plain

<IfModule mime_module>

TypesConfig /etc/httpd/mime.types

AddType application/x-compress .Z
AddType application/x-gzip .gz .tgz

</IfModule>

<IfModule ssl_module>
SSLRandomSeed startup builtin
SSLRandomSeed connect builtin
</IfModule>
AddType application/x-httpd-php .php
AddType application/x-httpd-php-source .phps

NameVirtualHost *:80

<VirtualHost *:80>
ServerName mail.ch.com
DocumentRoot /var/www/extsuite/extmail/html/
ScriptAlias /extmail/cgi /var/www/extsuite/extmail/cgi
Alias /extmail /var/www/extsuite/extmail/html
SuexecUserGroup postfix postfix
</VirtualHost>

[ 本帖最后由 gdou007 于 2008-2-27 16:34 编辑 ]

hc_ttcm 回复于:2008-02-27 16:51:33

好好看看
最近就再整postfix呢?

gdou007 回复于:2008-02-27 17:13:51

安装perl-GD报错

[root@testmail src]# rpm -ivh perl-GD-2.35-1.el5.rf.i386.rpm
warning: perl-GD-2.35-1.el5.rf.i386.rpm: Header V3 DSA signature: NOKEY, key ID 1aa78495
error: Failed dependencies:
libgd.so.2 is needed by perl-GD-2.35-1.el5.rf.i386


不知道这个libgd.so.2是在哪个包里的?

柳拂风 回复于:2008-02-28 00:28:47

Extman的管理员登陆校验码需要perl-GD模块,而perl-GD需要gd,
这两个gd是两码事,不要弄混了。

perl-GD的安装包是GD-2.35.tar.gz

gd的安装包是gd-2.0.35.tar.gz
这里有gd下载:http://www.libgd.org/

gd需要gettext和gettext-devel包,没装的话,先把这两个rpm包补装上。

柳拂风 回复于:2008-02-28 00:40:28

544楼,
你的应该是权限问题,
你检查一下目录的权限设置对不对
# ls -l var/www/extsuite/extmail/ 看看

另外,把你的httpd.conf 配置最后面这一行去掉:
SuexecUserGroup postfix postfix

gdou007 回复于:2008-02-28 09:27:19

引用:原帖由 柳拂风 于 2008-2-28 00:40 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=8014690&ptid=987344
544楼,
你的应该是权限问题,
你检查一下目录的权限设置对不对
# ls -l var/www/extsuite/extmail/ 看看

另外,把你的httpd.conf 配置最后面这一行去掉:
SuexecUserGroup postfix postfix



运行suexec的目录必须包含指定的目录里,通过suexec -V 可以看到docroot目录是/usr/local/apache/htdocs
所以不可以放在/var/www下,把目录改为
/usr/local/apache/htdocs 就好了,可是就是不知道怎样修改 docroot目录为/var/www


现在登陆后台的验证码,出来了,可是还是提示“
校验码不正确,请重新输入

大小写匹配都还是提示校验码不正确。真是很郁闷!






marion 回复于:2008-02-28 10:57:23

引用:运行suexec的目录必须包含指定的目录里,通过suexec -V 可以看到docroot目录是/usr/local/apache/htdocs
所以不可以放在/var/www下,把目录改为/usr/local/apache/htdocs 就好了,可是就是不知道怎样修改 docroot目录为/var/www


现在登陆后台的验证码,出来了,可是还是提示“校验码不正确,请重新输入

大小写匹配都还是提示校验码不正确。真是很郁闷!



docroot是编译apache时可以指定;应该也可以在文档中用指令指定,建议查看一下apache的手册。

校验码功能你可以先关了,前面有说明。另,在extmail的官方网站对出现此问题的原因多有讨论。

kepa520 回复于:2008-02-28 15:40:48

引用:原帖由 junger 于 2008-2-27 09:25 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=8009667&ptid=987344
你再看看你的输入是否有错误?

好像不是/usr/inculde/db4吧!

# mv /usr/include/db4 /usr/inculde/db4.OFF


汗!一语道破天机!实在太粗心了,看了半天也没看出来,太谢谢你了!:em03:

marion 回复于:2008-03-05 12:23:40

引用:原帖由 unixnovice 于 2008-2-16 19:13 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=7967990&ptid=987344
建议加入smtpS和POP3S


正在测试使用中,等把文档完善了就发上来。

gagapp 回复于:2008-03-05 12:41:19

页面打不开,提示
":flock" is not exported by the Fcntl module Can't continue after import errors at /usr/local/apache/htdocs/extsuite/extmail/libs/Ext/Utils.pm line 15 BEGIN failed--compilation aborted at /usr/local/apache/htdocs/extsuite/extmail/libs/Ext/Utils.pm line 15. Compilation failed in require at /usr/local/apache/htdocs/extsuite/extmail/libs/Ext/CGI.pm line 18. BEGIN failed--compilation aborted at /usr/local/apache/htdocs/extsuite/extmail/libs/Ext/CGI.pm line 18. Compilation failed in require at /usr/local/apache/htdocs/extsuite/extmail/libs/Ext/App.pm line 23. BEGIN failed--compilation aborted at /usr/local/apache/htdocs/extsuite/extmail/libs/Ext/App.pm line 23. Compilation failed in require at /usr/local/apache/htdocs/extsuite/extmail/libs/Ext/App/Login.pm line 19. BEGIN failed--compilation aborted at /usr/local/apache/htdocs/extsuite/extmail/libs/Ext/App/Login.pm line 19. Compilation failed in require at index.cgi line 21.

jiayong277 回复于:2008-03-05 21:19:38

引用: --with-xml
--with-png
--with-jpeg
--with-zlib
--with-freetype
--with-gd
--enable-track-vars
--enable-mbstring=all


出现不明选项? 请问LZ安装的时候有没有出现?

jiayong277 回复于:2008-03-06 22:30:45

我在安装的DBD-mysql-3.0002_4的时候

#perl Makefile.PL
出现下面这种情况!好像少了什么东西~?请指点
引用:
Can't locate DBI/DBD.pm in @INC (@INC contains: /usr/lib/perl5/site_perl/5.8.8/i386-linux-thread-multi /usr/lib/perl5/site_perl/5.8.7/i386-linux-thread-multi /usr/lib/perl5/site_perl/5.8.6/i386-linux-thread-multi /usr/lib/perl5/site_perl/5.8.5/i386-linux-thread-multi /usr/lib/perl5/site_perl/5.8.8 /usr/lib/perl5/site_perl/5.8.7 /usr/lib/perl5/site_perl/5.8.6 /usr/lib/perl5/site_perl/5.8.5 /usr/lib/perl5/site_perl /usr/lib/perl5/vendor_perl/5.8.8/i386-linux-thread-multi /usr/lib/perl5/vendor_perl/5.8.7/i386-linux-thread-multi /usr/lib/perl5/vendor_perl/5.8.6/i386-linux-thread-multi /usr/lib/perl5/vendor_perl/5.8.5/i386-linux-thread-multi /usr/lib/perl5/vendor_perl/5.8.8 /usr/lib/perl5/vendor_perl/5.8.7 /usr/lib/perl5/vendor_perl/5.8.6 /usr/lib/perl5/vendor_perl/5.8.5 /usr/lib/perl5/vendor_perl /usr/lib/perl5/5.8.8/i386-linux-thread-multi /usr/lib/perl5/5.8.8 .) at Makefile.PL line 23.




#make 的时候
引用:
make: *** 没有指明目标并且找不到 makefile。 停止。



在线等!!谢谢

int3 回复于:2008-03-07 14:02:37

PERL-DBI這個模塊你裝了?

jiayong277 回复于:2008-03-08 21:15:50

可以了,

jiayong277 回复于:2008-03-10 12:39:08

有了perl-DBI 还是不可以make
会出现下面这种错误,请指点一下
make: *** 没有指明目标并且找不到 makefile。 停止。

可恶的 回复于:2008-03-10 13:34:04

感谢楼主的分享,小弟现在就开始架构,学习一下。

alexa 回复于:2008-03-10 18:27:29

引用:原帖由 falalala 于 2008-1-22 15:53 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=7886235&ptid=987344
Problem in Amavis::DB or Amavis::DB::SNMP code:
BerkeleyDB needs compatible versions of libdb & db.h
you have db.h version 4.5.20 and libdb version 4.2.52
Compilation failed in require at (eval 92) line 15.
BEGIN failed--compilation aborted at (eval 92) line 15.






我也遇到同样的问题 原因是系统中有不同版本的BerkeleyDB 解决方法如下:

在安装BerkeleyDB perl模块的时候 我用的是cpan自动安装 出错 因此到cpan.org下载一个手动编译安装

修改config.in文件中 lib 和 include的路径 重新编译安装 通过



官方原文:


Incompatible versions of db.h and libdb
---------------------------------------

BerkeleyDB seems to have built correctly, but you get an error like this
when you run the test harness:

$ make test
PERL_DL_NONLAZY=1 /home/paul/perl/install/bin/perl5.00503
-Iblib/arch -Iblib/lib -I/usr/local/lib/perl5/5.00503/i586-linux
-I/usr/local/lib/perl5/5.00503 -e 'use Test::Harness qw(&runtests $verbose);
$verbose=0; runtests @ARGV;' t/*.t
t/btree.............
BerkeleyDB needs compatible versions of libdb & db.h
you have db.h version 2.6.4 and libdb version 2.7.5
BEGIN failed--compilation aborted at t/btree.t line 25.
dubious
Test returned status 255 (wstat 65280, 0xff00)
...

Another variation on the theme of having two versions of Berkeley DB on
your system.

Solution: Setting the LIB & INCLUDE variables in config.in to point to the
correct directories can sometimes be enough to fix this
problem. If that doesn't work the easiest way to fix the
problem is to either delete or temporarily rename the copies
of db.h and libdb.a that you don't want BerkeleyDB to use.
If you are running Linux, please read the Linux Notes section below.

yh81521 回复于:2008-03-10 21:37:04

# spamassassin -d --lint
[10857] warn: config: failed to parse line, skipping, in "/etc/mail/spamassassin/local.cf": rewrite_subject 1
[10857] warn: lint: 1 issues detected, please rerun with debug enabled for more information
我用的SpamAssassin3.2.3

这个错误怎么调试?哪出错了呢?有没有和我遇到一样错误的呢?

柳拂风 回复于:2008-03-11 09:54:01

"/etc/mail/spamassassin/local.cf":
rewrite_subject 1 这个选项有问题,注掉它试试

yh81521 回复于:2008-03-12 10:17:33

恩,注释掉就可以了。
但是柳兄,能解释下rewrite_subject 1的意思吗?我不用它会有什么问题吗?
它是不是和后面的配置rewrite_header Subject *****SPAM***** 相关联。是不是检测邮件标题的选项,去掉是不是会使过滤垃圾邮件主题出现问题?

[ 本帖最后由 yh81521 于 2008-3-12 10:21 编辑 ]

柳拂风 回复于:2008-03-12 11:13:14

rewrite_subject 1 这个选项成立时,
rewrite_header Subject *****SPAM***** 这个选项才起作用,它是用来修改标题的


资料上是这么说的,我没法验证,因为我自己装的系统就没法启用rewrite_subject 1,可能跟一些perl模块有关,可是我也不知道跟哪个模块有关,所有spamassassin需要的perl模块我都安装并进行升级了。

不启用这个选项暂时没发现什么不良影响,垃圾邮件过滤效果还不错。

yh81521 回复于:2008-03-12 14:32:10

谢谢柳兄解答,那我就放心了,呵呵。。。

marion 回复于:2008-03-14 14:24:15

你讲的再清楚一些或许有助于其他人帮你判断问题所在。

lminz 回复于:2008-03-14 22:47:49

我安装的时候忘记了删除sendmail,装好后都成功了才记起没删除,然后运行rpm -e sendmail --nodeps删除
删除后进webmail正常,但发送邮件时出错,显示Send fail, return code -1
maillog显示错误为
Mar 14 22:43:07 mailserver postfix/smtpd[25662]: fatal: open database /etc/aliases.db: No such file or directory
Mar 14 22:43:08 mailserver postfix/master[25628]: warning: process /usr/local/postfix/sbin/smtpd pid 25662 exit status 1
Mar 14 22:43:08 mailserver postfix/master[25628]: warning: /usr/local/postfix/sbin/smtpd: bad command startup -- throttling
请问老大应该如何修复?
我重新执行newaliases 提示 error while loading shared libraries: libmysqlclient.so.14;cannot open shared object file: No such file or directory
我装了 Mysqlclient 后可以运行newaliases,但还是不能发邮件。
错误日志如下
Mar 15 00:32:23 mailserver pop3d: LOGOUT, user=lmz@XXX.cn, ip=[218.14.*.*], top=0, retr=0, rcvd=12, sent=39, time=0
Mar 15 00:34:58 mailserver postfix/anvil[26078]: statistics: max connection rate 1/60s for (smtp:70.23.207.224) at Mar 15 00:26:26
Mar 15 00:34:58 mailserver postfix/anvil[26078]: statistics: max connection count 1 for (smtp:70.23.207.224) at Mar 15 00:26:26
Mar 15 00:34:58 mailserver postfix/anvil[26078]: statistics: max cache size 2 at Mar 15 00:28:50

[ 本帖最后由 lminz 于 2008-3-15 00:37 编辑 ]

marion 回复于:2008-03-16 08:43:23

在一定程度上讲,postfix的目的是为了取代Sendmail,因此,postfix的许多程序和文件都同Sendmail同名,postfix安装完成后再删除sendmail会导致什么,我想这个不难猜到。

lminz 回复于:2008-03-16 22:19:26

引用:原帖由 marion 于 2008-3-16 08:43 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=8086672&ptid=987344
在一定程度上讲,postfix的目的是为了取代Sendmail,因此,postfix的许多程序和文件都同Sendmail同名,postfix安装完成后再删除sendmail会导致什么,我想这个不难猜到。

老大,有啥办法不?要重新安装一次?

lminz 回复于:2008-03-17 08:24:21

重新make install 一次POSTFIX就可以了,谢谢老大。
请问后台管理员用户名可以改不?root@extmail.org我想改也不行,新加的管理员权限不是ADMIN,请问有什么办法?还有ROOT密码忘记了如何?谢谢指点。

lminz 回复于:2008-03-17 08:28:19

我的图形日志原来是可以的,现在都变成红色叉叉了,有什么办法?

itdailin 回复于:2008-03-18 11:47:31

楼主:安装好了后可以出现WEBMAIL的页面,但不管是登陆邮件还是后台管理都没有办法进去!
我查看了MAILLOG出现以下错误!可以帮我找找错误的地方么?
Mar 18 11:18:50 mail1 postfix/pickup[2877]: D75663F48B0: uid=0 from=<root>
Mar 18 11:18:50 mail1 postfix/cleanup[2878]: warning: connect to mysql server localhost: Access denied for user 'extmail'@'localhost' (using password: YES)
Mar 18 11:18:50 mail1 postfix/cleanup[2878]: warning: D75663F48B0: virtual_alias_maps map lookup problem for root@wh.com
Mar 18 11:19:50 mail1 postfix/pickup[2877]: D55A43F48B0: uid=0 from=<root>
Mar 18 11:19:50 mail1 postfix/cleanup[2878]: warning: D55A43F48B0: virtual_alias_maps map lookup problem for root@wh.com
Mar 18 11:20:50 mail1 postfix/pickup[2877]: D342E3F48B0: uid=0 from=<root>
Mar 18 11:20:50 mail1 postfix/cleanup[2878]: warning: connect to mysql server localhost: Access denied for user 'extmail'@'localhost' (using password: YES)
Mar 18 11:20:50 mail1 postfix/cleanup[2878]: warning: D342E3F48B0: virtual_alias_maps map lookup problem for root@wh.com
Mar 18 11:21:50 mail1 postfix/pickup[2877]: D14C93F48B0: uid=0 from=<root>
Mar 18 11:21:50 mail1 postfix/cleanup[2878]: warning: D14C93F48B0: virtual_alias_maps map lookup problem for root@wh.com
Mar 18 11:22:50 mail1 postfix/pickup[2877]: CF3D33F48B0: uid=0 from=<root>
Mar 18 11:22:50 mail1 postfix/cleanup[2878]: warning: connect to mysql server localhost: Access denied for user 'extmail'@'localhost' (using password: YES)
Mar 18 11:22:50 mail1 postfix/cleanup[2878]: warning: CF3D33F48B0: virtual_alias_maps map lookup problem for root@wh.com
Mar 18 11:23:50 mail1 postfix/pickup[2877]: CD22A3F48B0: uid=0 from=<root>
Mar 18 11:23:50 mail1 postfix/cleanup[2878]: warning: CD22A3F48B0: virtual_alias_maps map lookup problem for root@wh.com
Mar 18 11:24:50 mail1 postfix/pickup[2877]: CAE483F48B0: uid=0 from=<root>
Mar 18 11:24:50 mail1 postfix/cleanup[2878]: warning: connect to mysql server localhost: Access denied for user 'extmail'@'localhost' (using password: YES)
Mar 18 11:24:50 mail1 postfix/cleanup[2878]: warning: CAE483F48B0: virtual_alias_maps map lookup problem for root@wh.com
Mar 18 11:25:50 mail1 postfix/pickup[2877]: C8AEA3F48B0: uid=0 from=<root>
Mar 18 11:25:50 mail1 postfix/cleanup[2878]: warning: C8AEA3F48B0: virtual_alias_maps map lookup problem for root@wh.com
Mar 18 11:26:50 mail1 postfix/pickup[2877]: C67793F48B0: uid=0 from=<root>
Mar 18 11:26:50 mail1 postfix/cleanup[2878]: warning: connect to mysql server localhost: Access denied for user 'extmail'@'localhost' (using password: YES)
Mar 18 11:26:50 mail1 postfix/cleanup[2878]: warning: C67793F48B0: virtual_alias_maps map lookup problem for root@wh.com
Mar 18 11:27:50 mail1 postfix/pickup[2877]: C45723F48B0: uid=0 from=<root>
Mar 18 11:27:50 mail1 postfix/cleanup[2878]: warning: C45723F48B0: virtual_alias_maps map lookup problem for root@wh.com
Mar 18 11:28:50 mail1 postfix/pickup[2877]: C23FA3F48B0: uid=0 from=<root>
Mar 18 11:28:50 mail1 postfix/cleanup[2878]: warning: connect to mysql server localhost: Access denied for user 'extmail'@'localhost' (using password: YES)
Mar 18 11:28:50 mail1 postfix/cleanup[2878]: warning: C23FA3F48B0: virtual_alias_maps map lookup problem for root@wh.com
Mar 18 11:29:50 mail1 postfix/pickup[2877]: C002F3F48B0: uid=0 from=<root>
Mar 18 11:29:50 mail1 postfix/cleanup[2878]: warning: C002F3F48B0: virtual_alias_maps map lookup problem for root@wh.com
Mar 18 11:30:50 mail1 postfix/pickup[2877]: BDF353F48B0: uid=0 from=<root>
Mar 18 11:30:50 mail1 postfix/cleanup[2878]: warning: connect to mysql server localhost: Access denied for user 'extmail'@'localhost' (using password: YES)
Mar 18 11:30:50 mail1 postfix/cleanup[2878]: warning: BDF353F48B0: virtual_alias_maps map lookup problem for root@wh.com
Mar 18 11:31:50 mail1 postfix/pickup[2877]: BC0423F48B0: uid=0 from=<root>
Mar 18 11:31:50 mail1 postfix/cleanup[2878]: warning: BC0423F48B0: virtual_alias_maps map lookup problem for root@wh.com
Mar 18 11:32:50 mail1 postfix/pickup[2877]: B9FED3F48B0: uid=0 from=<root>
Mar 18 11:32:50 mail1 postfix/cleanup[2878]: warning: connect to mysql server localhost: Access denied for user 'extmail'@'localhost' (using password: YES)
Mar 18 11:32:50 mail1 postfix/cleanup[2878]: warning: B9FED3F48B0: virtual_alias_maps map lookup problem for root@wh.com
Mar 18 11:33:50 mail1 postfix/pickup[2877]: B80433F48B0: uid=0 from=<root>
Mar 18 11:33:50 mail1 postfix/cleanup[2878]: warning: B80433F48B0: virtual_alias_maps map lookup problem for root@wh.com

lminz 回复于:2008-03-18 15:08:42

楼上的,装好后要用root@extmail.org登录,密码看楼主的第一页。
要修改root用户的后缀域名好像只能在MYSQL里改。

kepa520 回复于:2008-03-19 20:15:29

大大们,我刚装上postfix,启动后验证服务启动状况:
执行telnet localhost 25出现
Trying 127.0.0.1...
Connected to test.com(127.0.0.1).
Escape character is '^]'.
这时系统就停在这里了 按ctr+c也不管用。

是postfix没安装好吗?

lminz 回复于:2008-03-20 00:14:31

楼上的,我也是这样,不理它继续安装用就可以,我也不知为什么,
我装EMOS系统也是这样停住,可能是网络原因?谁清楚的解析一下。

bobo_zhshb 回复于:2008-03-20 10:14:53

我在安装DBD-mysql-3.0002_4的时候,当perl Makefile.pl后make的时候,提示错误如下:
gcc -c -I/usr/lib/perl5/vendor_perl/5.8.5/i386-linux-thread-multi/auto/DBI -I/usr/include/mysql -g -pipe -m32 -march=i386 -mtune=pentium4 -D_GNU_SOURCE -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -fno-strict-aliasing -DDBD_MYSQL_WITH_SSL -g -D_REENTRANT -D_GNU_SOURCE -DDEBUGGING -fno-strict-aliasing -pipe -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -I/usr/include/gdbm -O2 -g -pipe -m32 -march=i386 -mtune=pentium4 -DVERSION=\"3.0002_4\" -DXS_VERSION=\"3.0002_4\" -fPIC "-I/usr/lib/perl5/5.8.5/i386-linux-thread-multi/CORE" dbdimp.c
dbdimp.c: In function `mysql_to_perl_type':
dbdimp.c:249: error: `MYSQL_TYPE_BIT' undeclared (first use in this function)
dbdimp.c:249: error: (Each undeclared identifier is reported only once
dbdimp.c:249: error: for each function it appears in.)
dbdimp.c:259: error: `MYSQL_TYPE_VARCHAR' undeclared (first use in this function)
dbdimp.c:263:25: warning: extra tokens at end of #ifdef directive
make: *** [dbdimp.o] Error 1
我按照提示去做以下操作ln -s /usr/local/mysql/include/* /usr/include又出现这个错误提示:
ln: `/usr/include/mysql': cannot overwrite directory
我又尝试
ln -s /usr/local/mysql/include/* /usr/local/include
ln -s /usr/local/mysql/include/mysql/* /usr/include/
ln -s /usr/local/mysql/include/mysql/* /usr/local/include/
然后make仍然是错误,请您帮忙说明一下问题原因好么?

bobo_zhshb 回复于:2008-03-20 12:55:32

用域名访问的错误提示如下,我也貌似看出来是DBD没有安装的原因。但是DBD安装就是出现上面的错误
截图_2025-11-15_15-47-58.jpg
截图_2025-11-15_15-47-58.jpg (150.91 KiB) 查看 853 次
bobo_zhshb 回复于:2008-03-20 14:39:29

尝试安装perl-dbi-1.40-8.i386.rpm后,问题依旧!

bobo_zhshb 回复于:2008-03-20 15:11:04

使用perl Makefile.PL --cflags=-I/usr/local/mysql/include/mysql后。问题解决!

bobo_zhshb 回复于:2008-03-20 15:33:22

但是接下来的问题出现了,如下:
DBI connect('database=extmail;host=localhost;mysql_socket=/tmp/mysql.sock','postfix',...) failed: Access denied for user 'postfix'@'localhost' (using password: YES) at /var/www/extsuite/extmail/libs/Ext/Auth/MySQL.pm line 44

bobo_zhshb 回复于:2008-03-20 16:03:07

引用:原帖由 bobo_zhshb 于 2008-3-20 15:33 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=8105680&ptid=987344
但是接下来的问题出现了,如下:
DBI connect('database=extmail;host=localhost;mysql_socket=/tmp/mysql.sock','postfix',...) failed: Access denied for user 'postfix'@'localhost' (using password: YES ...


问题已经解决,原因是没有建立用户,而是使用的初始root用户,应该切换到管理用户就可以了使用root了!

bobo_zhshb 回复于:2008-03-20 16:50:51

又出现了一个问题?
在后台输入用户名root@extmail.org和密码extmail*123*,提示说不正确的用户名或密码。

kepa520 回复于:2008-03-21 15:17:40

今天在安装courier-authlib到./configure时再次出现问题:
“configure: error: --with-authmysql specified but no mysqlclient.so”这个问题
搜索后只发现libmysqlclient.so,大大们帮忙看看.

itdailin 回复于:2008-03-21 20:13:03

大虾们:来看看啊,帮帮忙啊:
我按照老大的步骤安装,安装过程没有出现任何问题,但当我在浏览器中输入http://mail1.wh.com进去的时候出现的是如下图的样子,出来的是APACHE的测试页面,我的HTTPD.CONF部分我修改过的配置如下:
User postfix
Group postfix
</IfModule>
</IfModule>
DocumentRoot "/var/www"
<Directory />
Options FollowSymLinks
AllowOverride None
Order deny,allow
Deny from all
</Directory
<Directory "/usr/www">
<IfModule dir_module>
DirectoryIndex index.html
</IfModule>
<IfModule ssl_module>
SSLRandomSeed startup builtin
SSLRandomSeed connect builtin
</IfModule>
<VirtualHost *:80>
ServerName mail.benet.org
DocumentRoot /var/www/extsuite/extmail/html/
ScriptAlias /extmail/cgi /var/www/extsuite/extmail/cgi
Alias /extmail /var/www/extsuite/extmail/html
SuexecUserGroup postfix postfix
</VirtualHost>
我的main.cf配置:
myhostname = mail1.wh.com
mydomain = wh.com
myorigin = wh.com
mydestination = $myhostname, localhost.$mydomain, localhost, $mydomain
mynetworks = 192.168.0.0/24, 127.0.0.0/8
############################CYRUS-SASL############################
broken_sasl_auth_clients = yes
smtpd_recipient_restrictions=permit_mynetworks,permit_sasl_authenticated,reject_invalid_hostname,reject_non_fqdn_hostname,reject_unknown_sender_domain,reject_non_fqdn_sender,reject_non_fqdn_recipient,reject_unknown_recipient_domain,reject_unauth_pipelining,reject_unauth_destination
smtpd_sasl_auth_enable = yes
smtpd_sasl_local_domain = $myhostname
smtpd_sasl_security_options = noanonymous
smtpd_sasl_application_name = smtpd
smtpd_banner = Welcome to our $myhostname ESMTP,Warning: Version not Available!
########################Virtual Mailbox Settings########################
virtual_mailbox_base = /var/mailbox
virtual_mailbox_maps = mysql:/etc/postfix/mysql_virtual_mailbox_maps.cf
virtual_mailbox_domains = mysql:/etc/postfix/mysql_virtual_domains_maps.cf
virtual_alias_domains =
virtual_alias_maps = mysql:/etc/postfix/mysql_virtual_alias_maps.cf
virtual_uid_maps = static:2525
virtual_gid_maps = static:2525
virtual_transport = virtual
maildrop_destination_recipient_limit = 1
maildrop_destination_concurrency_limit = 1
##########################QUOTA Settings########################
message_size_limit = 14336000
virtual_mailbox_limit = 20971520
virtual_create_maildirsize = yes
virtual_mailbox_extended = yes
virtual_mailbox_limit_maps = mysql:/etc/postfix/mysql_virtual_mailbox_limit_maps.cf
virtual_mailbox_limit_override = yes
virtual_maildir_limit_message = Sorry, the user's maildir has overdrawn his diskspace quota, please Tidy your mailbox and try again later.
virtual_overquota_bounce = yes
我该怎么办啊!!!!!求救!!!!:emn53: :emn53: :emn53:
截图_2025-11-15_15-51-14.jpg
截图_2025-11-15_15-51-14.jpg (120.52 KiB) 查看 852 次
itdailin 回复于:2008-03-21 20:20:14

继续求救!在线等大侠解救!!:em32:

itdailin 回复于:2008-03-21 20:23:49

引用:原帖由 kepa520 于 2008-3-21 15:17 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=8111388&ptid=987344
今天在安装courier-authlib到./configure时再次出现问题:
“configure: error: --with-authmysql specified but no mysqlclient.so”这个问题
搜索后只发现libmysqlclient.so,大大们帮忙看看.

兄弟这个问题应该是MYSQL安装的时候就出了问题,也许你没有注意!!错误的问题已经写出来了

kepa520 回复于:2008-03-22 13:38:47

引用:原帖由 itdailin 于 2008-3-21 20:23 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=8112701&ptid=987344

兄弟这个问题应该是MYSQL安装的时候就出了问题,也许你没有注意!!错误的问题已经写出来了


不会吧,我好不容易装到这一步的啊:em16:

kinfio 回复于:2008-03-22 23:14:42

Can't chdir to /home/domains/****/****/Maildir/, Permission denied

求教楼主这个问题,用户登陆时出现这个问题,因该去看那些 脚本文件 和 日志,来解决这个问题呢?
这个问题需要去看那些配置文件和做那些权限的修改呢?
vuser vgroup 这是我的属主和属组

lquan286 回复于:2008-03-26 13:26:56

Mar 26 13:16:09 redhat pop3d: Connection, ip=[192.168.0.43]
Mar 26 13:16:27 redhat authdaemond: received auth request, service=pop3, authtype=login
Mar 26 13:16:27 redhat authdaemond: authmysql: trying this module
Mar 26 13:16:27 redhat authdaemond: SQL query: SELECT username, password, "", '2525', '2525', concat('/var/mailbox/',maildir), "", "", name, "" FROM mailbox WHERE username = "quantest.com"
Mar 26 13:16:27 redhat authdaemond: zero rows returned
Mar 26 13:16:27 redhat authdaemond: no password available to compare
Mar 26 13:16:27 redhat authdaemond: authmysql: REJECT - try next module
Mar 26 13:16:27 redhat authdaemond: FAIL, all modules rejected
Mar 26 13:16:27 redhat pop3d: LOGIN FAILED, user=quan, ip=[192.168.0.43]
Mar 26 13:16:40 redhat pop3d: LOGOUT, ip=[192.168.0.43]
Mar 26 13:16:40 redhat pop3d: Disconnected, ip=[192.168.0.43]
Mar 26 13:16:41 redhat pop3d: Connection, ip=[192.168.0.43]
Mar 26 13:17:03 redhat pop3d: LOGOUT, ip=[192.168.0.43]
Mar 26 13:17:03 redhat pop3d: Disconnected, ip=[192.168.0.43]
Mar 26 13:17:04 redhat pop3d: Connection, ip=[192.168.0.43]
Mar 26 13:17:18 redhat authdaemond: received auth request, service=pop3, authtype=login
Mar 26 13:17:18 redhat authdaemond: authmysql: trying this module
Mar 26 13:17:18 redhat authdaemond: SQL query: SELECT username, password, "", '2525', '2525', concat('/var/mailbox/',maildir), "", "", name, "" FROM mailbox WHERE username = "quan@test.com"
Mar 26 13:17:18 redhat authdaemond: password matches successfully
Mar 26 13:17:18 redhat authdaemond: authmysql: sysusername=<null>, sysuserid=2525, sysgroupid=2525, homedir=/var/mailbox/test.com/quan/Maildir/, address=quan@test.com, fullname=quan, maildir=<null>, quota=<null>, options=<null>
Mar 26 13:17:18 redhat authdaemond: authmysql: clearpasswd=<null>, passwd=$1$jDLlkMKv$3TrU8PezNgtKJ1WlbYFlu1
Mar 26 13:17:18 redhat authdaemond: Authenticated: sysusername=<null>, sysuserid=2525, sysgroupid=2525, homedir=/var/mailbox/test.com/quan/Maildir/, address=quan@test.com, fullname=quan, maildir=<null>, quota=<null>, options=<null>
Mar 26 13:17:18 redhat authdaemond: Authenticated: clearpasswd=123456, passwd=$1$jDLlkMKv$3TrU8PezNgtKJ1WlbYFlu1
Mar 26 13:17:18 redhat pop3d: chdir Maildir: No such file or directory

piaoxue 回复于:2008-03-26 17:03:22

柳兄,能不能把那个打包的软件重新提供一下,以前那个不可以下载了

谢谢

柳拂风 回复于:2008-03-27 10:58:32

可以下载了

marion 回复于:2008-03-29 16:03:00

前面帖子多有说明,你看看就可以找到答案的。希望你现在已经找到解决办法了。:)

hackerzyh 回复于:2008-03-31 21:03:58

老大,我的邮件监控为什么总是收到两封相同的邮件。设置方式是来自extmail.org/forum


添加数据表mail_watch
CREATE TABLE `mail_watch` (
`sender` varchar(100) NOT NULL,
`bcc` varchar(100) NOT NULL,
PRIMARY KEY (`sender`)
)

main.cf

sender_bcc_maps = mysql:/etc/postfix/mail_watch.cf
recipient_bcc_maps = mysql:/etc/postfix/mail_watch.cf

mysql_watch.cf

user = postfix
password = xxxxx
dbname = postfix
table = mail_watch
select_field = bcc
where_field = sender
hosts = localhost

这样就可以指定某个人监控某个人的邮件了

柳拂风 回复于:2008-04-01 16:22:44

是不是你的邮件在postfix路过了两次?

--->postfix--->maildrop--->postfix--->

我没用maildrop,大概是这个流程吧?

24559982 回复于:2008-04-01 17:52:46

Mark!

hackerzyh 回复于:2008-04-02 14:01:28

是的。那这么修改才不会出现接受重复监控邮件,谢谢

piaoxue 回复于:2008-04-02 14:49:20

谢谢柳大哥

柳拂风 回复于:2008-04-02 15:51:50

我没这样用过。
这个是在百度查的,你试试看有没有用?

在main.cf加入:
enable_original_recipient = no

hackerzyh 回复于:2008-04-02 16:33:07

已经测试过了。ok!谢谢老大!

[ 本帖最后由 hackerzyh 于 2008-4-2 16:58 编辑 ]

marion 回复于:2008-04-05 20:39:10

柳兄辛苦了,希望大家能更进一步的敞开交流使用心得!:)

3645636 回复于:2008-04-07 00:25:17

真鸡巴麻烦,曲高和寡

bladezxf 回复于:2008-04-08 14:37:51

install_driver(mysql) failed 翻过很多帖子,还是没弄好


通过命令行脚本可以执行mysql
通过sql-bench里./test-connect -user root -p mypw -host 127.0.0.1 -sock /tmp/mysql.sock
也可以执行操作。
但登录extmail还是一样出错
install_driver(mysql) failed: Can't load '/usr/local/lib/perl5/site_perl/5.10.0/i686-linux-thread-multi/auto/DBD/mysql/mysql.so' for module DBD::mysql: libmysqlclient.so.15: cannot open shared object file: Permission denied at /usr/local/lib/perl5/5.10.0/i686-linux-thread-multi/DynaLoader.pm line 203. at (eval 11) line 3 Compilation failed in require at (eval 11) line 3. Perhaps a required shared library or dll isn't installed where expected at /var/www/extsuite/extmail/libs/Ext/Auth/MySQL.pm line 44

系统redhat as4u4 mysql 5.0.45 DBI装到最心了。DBD::mysql换了几个版本都不行。
perl版本更新到5.10.0了。默认的版本5.8.5也出错
extman extmail看到有更新,也更新到最心了,一样的错误提示,
查了很多帖 ,还是弄不好,求助。

[ 本帖最后由 bladezxf 于 2008-4-9 16:16 编辑 ]

hackerzyh 回复于:2008-04-10 08:06:43

柳老大,你好。我的问题是关于邮件监控重复收取相同邮件的问题

我添加了enable_original_recipient = no后,本域内的邮件不会被监控邮箱重复接受,但是外部域寄过来的邮件依然被重复接受

marion 回复于:2008-04-10 11:02:49

引用:……Can't load '/usr/local/lib/perl5/site_perl/5.10.0/i686-linux-thread-multi/auto/DBD/mysql/mysql.so' for module DBD::mysql: libmysqlclient.so.15: ……


问题应该就在这两处错误处,仔细排查一下libmysqlclient.so.15是否可以被加载,以及usr/local/lib/perl5/site_perl/5.10.0/i686-linux-thread-multi/auto/DBD/mysql/mysql.so文件是否存在。

gunguymadman 回复于:2008-04-10 15:27:39

marion 兄弟

我认为spamassassion 很垃圾 太耗资源

我做的是greylist

不知道你认为反垃圾还有哪些好的有效解决方案

还有就是安全问题 你的文章中针对安全方案有什么好的策略和思考呢

希望大家可以交流交流

luren04 回复于:2008-04-12 23:43:25

非常感谢,真诚期待未完的部分!!!

bladezxf 回复于:2008-04-13 21:47:40

谢谢marion 的回复 mysqlclient是加载的,mysql.so也存在,更换过好多版本
在redhat as4u4上始终不行 。查了很多资料
在Centos5上很容易就可以了
mysql版本 5.0.45
perl 5.8.8
DBI 1.603
DBD-mysql 3.0002_4


但有个新问题
extman 用root登不上,提示 不正确的用户名或密码 新注册的用户可以登
在extmail.org里看到要同步时间,时间同步也一样登不上。哎

已解决
root是不能通过mail.***.com/extmail登的
应该是mail.****.com/etxman

[ 本帖最后由 bladezxf 于 2008-4-14 13:24 编辑 ]

很平凡的Man 回复于:2008-04-15 15:06:53

搂主你是在太NB

wangjyl 回复于:2008-04-19 01:07:31

输入用户名和密码后出现如下报错:
DBI connect('database=extmail;host=localhost;mysql_socket=/tmp/mysql.sock','webman',...) failed: Access denied for user 'postfix'@'localhost' (using password: YES)at /var/www/extsuite/extmail/libs/Ext/Auth/MySQL.pm line 44
在webmail.cf中也改了SYS_SQL_USER和PASS,但还是登不进去,请问如何解决?谢谢啦!

marion 回复于:2008-04-22 22:23:55

打开认证日志,问题应该会一目了然的!前面的帖子中有具体实现办法,建议参照。

bladezxf 回复于:2008-04-23 15:35:45

我按照marion 老大这个配置来做的,
但我的最后发现不通过身份验证也能发邮件
随便输一个帐号,以这个邮件服务器来发送,也能发邮件
有人一样的情况吗?

邮件日志里
SASL authentication failure: cannot connect to Courier authdaemond: No such file or directory

[root@mail ~]# more /etc/authdaemonrc | grep -v "#"
authmodulelist="authmysql"
authmodulelistorig="authmysql"
daemons=10
authdaemonvar=/usr/local/courier-authlib/var/spool/authdaemon

[root@mail ~]# ls -la /usr/local/courier-authlib/var/spool/authdaemon
total 12
drwxr-xr-x 2 daemon daemon 4096 Apr 23 16:06 .
drwxr-xr-x 3 root root 4096 Apr 21 17:34 ..
-rw-r--r-- 1 root root 5 Apr 23 16:06 pid
-rw------- 1 root root 0 Apr 21 17:40 pid.lock
srwxrwxrwx 1 root root 0 Apr 23 16:06 socket

main.cf中
##############SASL####################
smtpd_sasl_auth_enable = yes
smtpd_sasl2_auth_enable = yes
smtpd_sasl_security_options = noanonymous
broken_sasl_auth_clients = yes

smtpd_recipient_restrictions =
permit_mynetworks,
permit_sasl_authenticated,
reject_unknown_sender_domain,
reject_non_fqdn_sender,
reject_non_fqdn_recipient,
reject_unknown_recipient_domain,
reject_unauth_pipelining,
reject_unauth_destination,
permit

smtpd_sender_login_maps =
mysql:/etc/postfix/mysql_virtual_sender_maps.cf,
mysql:/etc/postfix/mysql_virtual_alias_maps.cf


smtpd_reject_unlisted_sender = yes

smtpd_sender_restrictions =
reject_sender_login_mismatch,
reject_authenticated_sender_login_mismatch,
reject_unauthenticated_sender_login_mismatch

[root@mail ~]# more /usr/local/sasl2/lib/sasl2/smtpd.conf
pwcheck_method: authdaemond
log_level: 3
mech_listLAIN LOGIN
authdaemond_path:/usr/local/courier-authlib/var/spool/authdaemon/socket

求助,那里的错误呢

[ 本帖最后由 bladezxf 于 2008-4-23 16:31 编辑 ]

marion 回复于:2008-04-25 20:54:50

记得本版块中有个专门的帖子讨论过这个问题及解决办法,你耐心找一找。:wink:

sikun 回复于:2008-04-28 14:33:13

Apr 26 16:43:16 test authdaemond: stopping authdaemond children
Apr 26 16:43:17 test authdaemond: modules="authmysql", daemons=10
Apr 26 16:43:18 test authdaemond: Installing libauthmysql
Apr 26 16:43:18 test authdaemond: libauthmysql.so: cannot open shared object file: No such file or directory

提示没有libauthmysql.so这个文件,这个文件是不是在编译courier-authlib时生成的,我没有在系统中找到这个文件,各位老大请指点,谢谢

nicsky 回复于:2008-05-05 16:08:35

谢谢楼主了。

marion 回复于:2008-05-09 17:41:01

重新检查一下courier-authlib的安装步骤,同时注意查看是否把库文件目录进行了输出。

falalala 回复于:2008-05-28 17:28:18

加了病毒防护和垃圾过滤,开始抱这样一个错误
May 28 17:18:33 mail amavis[14452]: (14452-03) (!!)run_av (ClamAV-clamd) FAILED - unexpected , output="/var/amavis/tmp/amavis-20080528T171832-14452/parts: lstat() failed. ERROR\n"
May 28 17:18:33 mail amavis[14452]: (14452-03) (!!)ClamAV-clamd av-scanner FAILED: CODE(0x9212358) unexpected , output="/var/amavis/tmp/amavis-20080528T171832-14452/parts: lstat() failed. ERROR\n" at (eval 112) line 523.
May 28 17:18:33 mail amavis[14452]: (14452-03) (!!)WARN: all primary virus scanners failed, considering backups
May 28 17:18:33 mail amavis[14452]: (14452-03) (!!)TROUBLE in check_mail: virus_scan FAILED: virus_scan: ALL VIRUS SCANNERS FAILED: ClamAV-clamd av-scanner FAILED: CODE(0x9212358) unexpected , output="/var/amavis/tmp/amavis-20080528T171832-14452/parts: lstat() failed. ERROR\n" at (eval 112) line 523.

请给个检查思路?

kufang_he1209 回复于:2008-05-29 10:23:24

有没有人在FREEBSD上实验成功的。都快理不清头绪了。有的话交流一下。

marion 回复于:2008-05-29 13:39:24

检查一下clamav的运行用户是否跟amavis的为同一个用户。

falalala 回复于:2008-06-02 11:11:56

没错,就是用户的问题。解决了,谢谢!

falalala 回复于:2008-06-02 11:29:25

本来,按照本贴,我的邮件服务器已经可以正常收发邮件了。
由于需要,我需要变更一个ip地址,待我变更后,发现邮件系统不能发往虚拟域以外的域的邮件了。
但是可以收虚拟域及虚拟域以外的邮件。
请问可能是哪里出现了问题?

junger 回复于:2008-06-03 16:26:07

请教 postfixadmin+postfix+dovecot 用postfixadmin 添加用户时出现错误


又是增加邮箱成功,又是建立邮箱失败?
截图_2025-11-15_15-53-55.jpg
截图_2025-11-15_15-53-55.jpg (65.49 KiB) 查看 851 次
marion 回复于:2008-06-04 10:36:51

我看的是一头雾水,请讲的再明白些。

marion 回复于:2008-06-04 10:38:09

有日志么?

估计应该是添加邮箱的执行过程是成功的,但由于postfixadmin对用户邮箱所在目录没有写权限而无法写入操作所致。

usercode 回复于:2008-06-06 15:07:27

按照楼主的方法,当试着安装完HTTP,启动appache时,有错误提示:
/usr/local/apache/bin/apachectl start
httpd: Syntax error on line 81 of /etc/httpd/httpd.conf: Cannot load /usr/local/apache/modules/mod_ssl.so into server: libssl.so.0.9.8: cannot open shared object file: No such file or directory

我是按照完全安装该方法来做的啦,是那里出了问题呢?

usercode 回复于:2008-06-06 15:23:18

按照楼主的方法在安装到每三步的cyrus-sasl-2.1.22.tar.gz时,运行最后一步时出错:


/usr/local/sasl2/sbin/testsaslauthd -u root -p root
connect() : No such file or directory

请问是什么原因呢?是不是这里的错误导致了我在第624楼发出的错误?
先在这里向楼主谢谢了!

usercode 回复于:2008-06-06 16:54:13

请问楼主:当我把/etc/httpd/httpd.conf文件中的有一行释掉,就可以正常启动appache了,
#LoadModule ssl_module modules/mod_ssl.so
那这样对接下来的其他安装或者功能是否有影响? 如果不去掉这一行,那么,在启动appache时,总是提示:

/usr/local/apache/bin/apachectl start
httpd: Syntax error on line 81 of /etc/httpd/httpd.conf: Cannot load /usr/local/apache/modules/mod_ssl.so into server: libssl.so.0.9.8: cannot open shared object file: No such file or directory

不知道对后面的安装是否有影响?

usercode 回复于:2008-06-08 08:27:27

当安装到第十二部份后,还是不能通过outlook收发邮件,总是提示需要用户名和密码,另外进入webmail也不行,修改了/etc/httpd/httpd.conf文件后,总是提示:Forbidden
You don't have permission to access / on this server. 如果使用系统自认的 /usr/local/apache/htdocs 这个路径就可以显示 it work的页面。是乎在安装过程中也没有什么错误提示呢,是哪里的问题?

usercode 回复于:2008-06-08 08:40:55

错误日志如下:
Jun 8 07:57:25 AS4 postfix/cleanup[6371]: warning: C28E1644466: virtual_alias_maps map lookup problem for root@srup.3322.org
Jun 8 07:58:25 AS4 postfix/pickup[6370]: C092B644466: uid=0 from=<root>
Jun 8 07:58:25 AS4 postfix/cleanup[6371]: warning: connect to mysql server localhost: Access denied for user 'extmail'@'localhost' (using password: YES)
Jun 8 07:58:25 AS4 postfix/cleanup[6371]: warning: C092B644466: virtual_alias_maps map lookup problem for root@srup.3322.org
Jun 8 07:59:25 AS4 postfix/pickup[6370]: BED5D644466: uid=0 from=<root>
Jun 8 07:59:25 AS4 postfix/cleanup[6371]: warning: BED5D644466: virtual_alias_maps map lookup problem for root@srup.3322.org
Jun 8 08:00:25 AS4 postfix/pickup[6370]: BCDB0644466: uid=0 from=<root>
Jun 8 08:00:25 AS4 postfix/cleanup[6371]: warning: connect to mysql server localhost: Access denied for user 'extmail'@'localhost' (using password: YES)
Jun 8 08:00:25 AS4 postfix/cleanup[6371]: warning: BCDB0644466: virtual_alias_maps map lookup problem for root@srup.3322.org
Jun 8 08:01:25 AS4 postfix/pickup[6370]: BB1CA644466: uid=0 from=<root>
Jun 8 08:01:25 AS4 postfix/cleanup[6371]: warning: BB1CA644466: virtual_alias_maps map lookup problem for root@srup.3322.org
Jun 8 08:02:25 AS4 postfix/pickup[6370]: B921A644466: uid=0 from=<root>
Jun 8 08:02:25 AS4 postfix/cleanup[6371]: B921A644466: message-id=<20080608000225.B921A644466@AS4.srup.3322.org>
Jun 8 08:02:25 AS4 postfix/qmgr[6380]: B921A644466: from=<root@srup.3322.org>, size=7355, nrcpt=1 (queue active)
Jun 8 08:02:25 AS4 postfix/local[7415]: B921A644466: to=<root@srup.3322.org>, orig_to=<root>, relay=local, delay=14420, delays=14419/0.06/0/0.01, dsn=2.0.0, status=sent (delivered to mailbox)
Jun 8 08:02:25 AS4 postfix/qmgr[6380]: B921A644466: removed
Jun 8 08:31:13 AS4 pop3d: Connection, ip=[121.13.101.133]
Jun 8 08:31:13 AS4 authdaemond: failed to connect to mysql server (server=localhost, userid=admin): Access denied for user 'admin'@'localhost' (using password: YES)
Jun 8 08:31:13 AS4 pop3d: LOGIN FAILED, user=rock_feng@srup.3322.org, ip=[121.13.101.133]
Jun 8 08:31:13 AS4 pop3d: authentication error: Input/output error

烦请楼主指点指点,谢谢了。都已经重新安装过整个RHEL4,第624,625楼的安装错误问题已经解决了,但安装到十二部份后,就是邮件收发不行,开启apache后,也进入不了。Outlook端的错误提示如下:

无法连接到服务器。 帐户: 'srup.3322.org', 服务器: 'srup.3322.org', 协议: SMTP, 端口: 25, 安全(SSL): 否, 套接字错误: 10061, 错误号: 0x800CCC0E

登录邮件服务器时出错。“密码”被拒绝。 帐户: 'srup.3322.org', 服务器: 'srup.3322.org', 协议: POP3, 服务器响应: '-ERR Temporary problem, please try again later', 端口: 110, 安全(SSL): 否, 服务器错误: 0x800CCC90, 错误号: 0x800CCC92

ie_e 回复于:2008-06-12 16:54:43

为什么我这边完全按照你的步骤处理,然后到第十三步骤:"可以在浏览器中输入指定的虚拟主机的名称进行访问,如下:
http://mail.benet.org"这步,出现显示不出来,IE无法访问...
我这边设置
[root@~]# ping mail.benet.org
PING mail.benet.org (10.15.117.68) 56(84) bytes of data.
64 bytes from 10.15.117.68: icmp_seq=0 ttl=64 time=0.055 ms
64 bytes from 10.15.117.68: icmp_seq=1 ttl=64 time=0.369 ms
10.15.117.68是我机器的内部IP地址,我已经做DNS解析了,而且解析的MX记录也正常,就是无法通过mail.benet.org访问或者http://10.15.117.68访问进入管理界面?
不知道是什么原因,该启动的服务都启动的...另外安装过程中已经调试成功就到这边...

zenglingping 回复于:2008-06-13 09:34:39

感谢楼主的作品,已打印出来,正在研究,很多东西还看不懂;

例:
# tar zxvf openssl-0.9.8e.tar.gz
# cd openssl-0.9.8e
# ./config shared zlib
# make
# make test
# make install
# mv /usr/bin/openssl /usr/bin/openssl.OFF 这个是为什么呢,我看楼主的很多软件编译后都要OFF,OFF是关闭的意思吧,刚编译好,又为什么要关闭呢?
# mv /usr/include/openssl /usr/include/openssl.OFF
# rm /usr/lib/libssl.so
# ln -s /usr/local/ssl/bin/openssl /usr/bin/openssl
# ln -s /usr/local/ssl/include/openssl /usr/include/openssl
# ln -sv /usr/local/ssl/lib/libssl.so.0.9.8 /usr/lib/libssl.so

另外,像openssl、cyrus-sasl系统安装时默认已经安装了;又删除不了,依照你给的步骤做不出结果来,可能是还没有读懂全文;

我使用的平台是centos 5.0;没有安装任何服务器套件,只安装了base、development tools;

zenglingping 回复于:2008-06-13 09:37:26

引用:原帖由 usercode 于 2008-6-6 15:07 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=8545934&ptid=987344
按照楼主的方法,当试着安装完HTTP,启动appache时,有错误提示:
/usr/local/apache/bin/apachectl start
httpd: Syntax error on line 81 of /etc/httpd/httpd.conf: Cannot load /usr/local/apache/module ...


我的也无法启用ssl,即加载ssl的参数后无法编译成功,无奈之后,我干脆把enable-ssl删除了,先不启用ssl试试吧;

[ 本帖最后由 zenglingping 于 2008-6-13 09:39 编辑 ]

zenglingping 回复于:2008-06-13 09:41:29

引用:原帖由 usercode 于 2008-6-6 15:23 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=8546165&ptid=987344
按照楼主的方法在安装到每三步的cyrus-sasl-2.1.22.tar.gz时,运行最后一步时出错:


/usr/local/sasl2/sbin/testsaslauthd -u root -p root
connect() : No such file or directory

请问是什么原因呢? ...



亦遇到同样的问题,后来使用rpm -qa |grep sasl看了一下,系统已经安装了这个东东,版本是一样的;

mdiane 回复于:2008-06-13 10:34:42

请问,为什么我的mail server把所有的邮件都当成垃圾邮件给过滤掉了
$sa_tag_level_deflt = 8.0;
$sa_tag2_level_deflt = 10;
$sa_kill_level_deflt = 10;
$sa_dsn_cutoff_level = 9;
--------------
$final_virus_destiny = D_REJECT;
$final_banned_destiny = D_BOUNCE;
$final_spam_destiny = D_REJECT;
$final_bad_header_destiny = D_PASS;
如果把$final_spam_destiny更改为D_PASS就可以发送,不过发送的所有邮件都打上SPAM标识

lovehack2006 回复于:2008-06-13 10:37:59

太多了,先顶了再看吧!!

usercode 回复于:2008-06-13 17:02:54

谢谢 631楼朋友的回复,我最后又重新安装了RHEL,现在这个问题解决了,可以正常登录到apache的界面了,之前可能是httpd.con文件中设置有哪里没有搞对。

usercode 回复于:2008-06-13 17:11:54

谢谢632楼朋友的回复,之前系统自带的rpm包软件,是没有与mysql数据库相连的,所以需要重新编译安装,请仔细参考楼主的原作,可以发现后面的部份mv........的这些部份就是移除掉之前的设置文件的,然后再通过ln连接到现在重新编译安装后的文件路径才起作用。

usercode 回复于:2008-06-13 17:43:33

怎样让加入的虚拟域和虚拟用户设置生效?我已经登录 extmail的webmail界面加入虚拟域和虚拟用户,也可以通过webmail发邮件出去了,但是收不到来自外面的邮件地址发给虚拟域地址的邮件。之前在没有加入虚拟域和虚拟用户的时候,都还可以收到来自外面的邮件,现在加入虚拟域和虚拟用户后,本地域和虚拟域都收不到邮件了。

比如现在我已经加入了一个 testa.3322.org的虚拟域以及test-1@testa.3322.org邮件用户(这些都是通过登录到extmail的webmail界面后,加入的),当外面的邮件帐号在回复来自test-1@testa.3322.org的邮件时,就收到以下的错误邮件提示:
(reason: 550 5.1.1 <test-1@testa.3322.org>: Recipient address rejected: User unknown in virtual alias table)

查看这台新建立的RHEL服务器错误日志如下:

Jun 14 00:28:59 RHEL postfix/qmgr[2229]: 9EA6E4FF210: from=<test-1@testa.3322.org>, size=519, nrcpt=1 (queue active)
Jun 14 00:28:59 RHEL postfix/trivial-rewrite[2241]: warning: do not list domain testa.3322.org in BOTH mydestination and virtual_mailbox_domains
Jun 14 00:28:59 RHEL postfix/local[2244]: 9EA6E4FF210: to=<test-1@testa.3322.org>, relay=local, delay=0.11, delays=0.09/0.02/0/0.01, dsn=2.0.0, status=sent (delivered to mailbox)


我查看了mydestination 和 virtual_mailbox_domains 这两个文件,都是按照楼主的原作上设置的,请问,如果加入了虚拟域和虚拟用户后,还有其他哪些地方和哪些配置文件需要更改才能生效?
哪位朋友能否为我指点指点?在此先深表感谢了!

zenglingping 回复于:2008-06-18 18:51:39

谢谢楼上朋友关注;

一路小心按照楼主的文章进行得还算顺利,但现在我已遇到新的问题,安装并设置完extmail and extman两个组件及虚拟目录下后,无法打开网页界面,提示:

Internal Server Error
The server encountered an internal error or misconfiguration and was unable to complete your request.

Please contact the server administrator, lpzeng@lanexpert.cn and inform them of the time the error occurred, and anything you might have done that may have caused the error.

More information about this error may be available in the server error log.

未设置虚拟主机之前是可以访问网页的(测试网页),80端口处于正常监听状态;

usercode 回复于:2008-06-18 22:39:27

应该是httpd.con文件内虚拟关于主机的设置部份的问题,请仔细参照楼主的原作。

zenglingping 回复于:2008-06-19 08:37:04

我的虚拟机部分配置如下:

<VirtualHost *:80>

ServerName mail.lanexpert.cn
DocumentRoot /var/www/extsuite/extmail/html

ScriptAlias /extmail/cgi /var/www/extsuite/extmail/cgi
ScriptAlias /extman/cgi /var/www/extsuite/extman/cgi

Alias /extmail /var/www/extsuite/extmail/html
Alias /extman /var/www/extsuite/extman/html

SuexecUserGroup postfix postfix

</VirtualHost>

zenglingping 回复于:2008-06-19 11:54:02

引用:原帖由 zenglingping 于 2008-6-19 08:37 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=8617466&ptid=987344
我的虚拟机部分配置如下:



ServerName mail.lanexpert.cn
DocumentRoot /var/www/extsuite/extmail/html

ScriptAlias /extmail/cgi /var/www/extsuite/extmail/cgi
ScriptAlias /extman/cgi /var/ ...


此问题已解决,应该是虚拟主机的设置问题,现更正如下:

User apache

Group apache



NameVirtualHost *:80



<VirtualHost *:80>



ServerName mail.lanexpert.cn:80

DocumentRoot /var/www/extsuite/extmail/html/



ScriptAlias /extmail/cgi /var/www/extsuite/extmail/cgi

Alias /extmail /var/www/extsuite/extmail/html



ScriptAlias /extman/cgi /var/www/extsuite/extman/cgi

Alias /extman /var/www/extsuite/extman/html



#SuexecUserGroup postfix postfix



</VirtualHost>



[ 本帖最后由 zenglingping 于 2008-6-21 09:11 编辑 ]

zenglingping 回复于:2008-06-19 17:20:29

新的问题又出现了:

1.虚拟域及本地域是否不可以同名?
如果是这样的话,那么,在实际环境中,是否可以这样设计:本地主机名(FQDN):mail.domainname.local 虚拟域名用:mail.doaminname.com

2.我现在无法登陆webmail,可以登陆extman,登陆extmail提示如下错误:

Can't chdir to /home/mailbox/lanexpert.cn/lingping/Maildir/, No such file or directory

我查过,在以上路径在mail服务器上是存在的;

usercode 回复于:2008-06-20 08:14:41

主域名和虚拟域名不要同名。
同时要注意这个邮件的存放路径,一定要统一,如果你是设置在/home/mailbox中的话,那之前所有的设置中也要相应地设置成这个路径,因为楼主的原作中有些地方是设置/var/mailbox

zenglingping 回复于:2008-06-20 18:48:02

现又在重新安装。。。

acmilanwin 回复于:2008-06-22 02:02:55

我完全按照您的方法做的,只是没有加maildrop配置文件我就不贴了,

用webmail收发都正常,但是用outlook就接收和发送都不行

无法使用安全密码身份验证登录到服务器。 帐户: 'pop3.supersec.com', 服务器: 'pop3.supersec.com', 协议: POP3, 服务器响应: '-ERR Invalid command.', 端口: 110, 安全(SSL): 否, 服务器错误: 0x800CCC90, 错误号: 0x800CCC18

选不选安全连接都不行,用户名我写全了

请帮帮我吧!

[ 本帖最后由 acmilanwin 于 2008-6-22 02:06 编辑 ]

szxqq 回复于:2008-06-22 06:00:52

在那里下载啊!为什么没有找到?

marion 回复于:2008-06-22 15:43:21

贴日志上来

或许前面的帖子有解决办法,建议去查查看。

acmilanwin 回复于:2008-06-22 21:17:58

[root@www ~]# tail -20 /var/log/maillog
Jun 22 10:17:51 www extmail[30459]: user=<luyang@supersec.com>, client=221.205.3.1, module=login, status=loginok
Jun 22 18:14:50 www postfix/smtpd[31039]: warning: dict_nis_init: NIS domain name not set - NIS lookups disabled
Jun 22 18:14:50 www postfix/smtpd[31039]: warning: 61.224.202.111: address not listed for hostname 61-224-202-111.dynamic.hinet.net
Jun 22 18:14:50 www postfix/smtpd[31039]: connect from unknown[61.224.202.111]
Jun 22 18:14:51 www postfix/smtpd[31039]: NOQUEUE: reject: RCPT from unknown[61.224.202.111]: 504 5.5.2 <124.42.11.117>: Helo command rejected: need fully-qualified hostname; from=<0617@163.com> to=<88888@ez1000.net> proto=SMTP helo=<124.42.11.117>
Jun 22 18:14:51 www postfix/smtpd[31039]: lost connection after RCPT from unknown[61.224.202.111]
Jun 22 18:14:51 www postfix/smtpd[31039]: disconnect from unknown[61.224.202.111]
Jun 22 18:18:11 www postfix/anvil[31041]: statistics: max connection rate 1/60s for (smtp:61.224.202.111) at Jun 22 18:14:50
Jun 22 18:18:11 www postfix/anvil[31041]: statistics: max connection count 1 for (smtp:61.224.202.111) at Jun 22 18:14:50
Jun 22 18:18:11 www postfix/anvil[31041]: statistics: max cache size 1 at Jun 22 18:14:50
Jun 22 21:42:50 www pop3d: Connection, ip=[221.204.175.175]
Jun 22 21:42:50 www pop3d: Disconnected, ip=[221.204.175.175]
Jun 22 21:44:09 www pop3d: Connection, ip=[221.204.175.175]
Jun 22 21:44:09 www pop3d: Disconnected, ip=[221.204.175.175]
Jun 22 21:45:48 www pop3d: Connection, ip=[221.204.175.175]
Jun 22 21:45:48 www pop3d: Disconnected, ip=[221.204.175.175]
Jun 22 21:46:50 www pop3d: Connection, ip=[221.204.175.175]
Jun 22 21:46:50 www pop3d: Disconnected, ip=[221.204.175.175]
Jun 22 21:47:16 www pop3d: Connection, ip=[221.204.175.175]
Jun 22 21:47:16 www pop3d: LOGIN FAILED, user=liutie@supersec.com, ip=[221.204.175.175]




最后的日志是没有选安全密码验证登陆,但outlook让我输入用户名密码,怎么输都不对

marion 回复于:2008-06-23 09:29:43

打开认证的日志功能,贴认证日志。

Weikey 回复于:2008-06-23 10:01:21

疑惑:
楼主,您的openssl在这里充当一个什么角色呢?
关于证书,您的帖子里面还没提到啊!

zenglingping 回复于:2008-06-23 15:30:05

谢问如何打开认证日志呀?

我的开始也不能通过outlook收发邮件(webmail收发内网及外网均正常),后来一个个配置文件的检查,发现有一个"_"写成了"-",纠正后outlook收发正常;

marion 回复于:2008-06-25 10:14:12

本打算做smtps、pops、imaps的应用,一直没有时间。只好待续……:)

zenglingping 回复于:2008-06-25 13:13:14

不知其它人是否有遇到此问题:
安装防毒及防垃圾组件后extman的图开日志无法显示,在未安装amavisd/spmassassin/clamav之前,图开日志显示是正常的;

但安装以上组件之后,图形日志即无法显示,不知是否跟此有关联:
截图_2025-11-15_15-57-20.jpg
截图_2025-11-15_15-57-20.jpg (33.56 KiB) 查看 850 次
zenglingping 回复于:2008-06-25 17:05:54

问题已解决,是由于权限的关系。

是安装并设置maildrop后引起的;

zenglingping 回复于:2008-06-25 17:11:11

修改前:

drwxr-xr-x 4 postfix postfix 4096 Jun 22 23:05 viewlog



修改后:



#cd /tmp

# chown -R vmail.vmail viewlogll viewlog/

total 8

drwxr-xr-x 2 vmail vmail 4096 Jun 23 17:54 normal

drwxr-xr-x 2 vmail vmail 4096 Jun 21 21:11 thumb



刷新之后问题解决。

zenglingping 回复于:2008-06-25 20:01:01

想请问一下楼主:

按照此文档配置,垃圾邮件被存放在哪里了?或者说去哪里查看垃圾邮件?

usercode 回复于:2008-06-27 08:23:21

最近两天时间了,都一直不能更新这个病毒定义码,设置上是按照楼主的方法,将那个XY是更改成cn的,之前都可以update。有其他人遇到类似的问题吗?还是我这里的服务器的问题?以下是错误日志:

Jun 27 08:13:38 mail freshclam[3224]: nonblock_connect: connect timing out (30 secs)
Jun 27 08:13:38 mail freshclam[3224]: Can't connect to port 80 of host db.cn.clamav.net (IP: 221.6.197.162)
Jun 27 08:13:38 mail freshclam[3224]: Trying host db.cn.clamav.net (58.221.253.171)...
Jun 27 08:14:08 mail freshclam[3224]: nonblock_connect: connect timing out (30 secs)
Jun 27 08:14:08 mail freshclam[3224]: Can't connect to port 80 of host db.cn.clamav.net (IP: 58.221.253.171)
Jun 27 08:14:08 mail freshclam[3224]: getpatch: Can't download daily-7548.cdiff from db.cn.clamav.net
Jun 27 08:14:08 mail freshclam[3224]: Retrieving http://db.cn.clamav.net/daily-7548.cdiff

zenglingping 回复于:2008-06-27 08:52:26

参考:


# freshclam

ClamAV update process started at Fri Jun 27 08:46:36 2008

WARNING: Your ClamAV installation is OUTDATED!

WARNING: Local version: 0.93 Recommended version: 0.93.1

DON'T PANIC! Read http://www.clamav.net/support/faq

main.cld is up to date (version: 47, sigs: 312304, f-level: 31, builder: sven)

Downloading daily-7555.cdiff [100%]

Downloading daily-7556.cdiff [100%]

Downloading daily-7557.cdiff [100%]

Downloading daily-7558.cdiff [100%]

Downloading daily-7559.cdiff [100%]

Downloading daily-7560.cdiff [100%]

Downloading daily-7561.cdiff [100%]

Downloading daily-7562.cdiff [100%]

Downloading daily-7563.cdiff [100%]

Downloading daily-7564.cdiff [100%]

Downloading daily-7565.cdiff [100%]

Downloading daily-7566.cdiff [100%]

Downloading daily-7567.cdiff [100%]

Downloading daily-7568.cdiff [100%]

Downloading daily-7569.cdiff [100%]

Downloading daily-7570.cdiff [100%]

Downloading daily-7571.cdiff [100%]

Downloading daily-7572.cdiff [100%]

Downloading daily-7573.cdiff [100%]

Downloading daily-7574.cdiff [100%]

Downloading daily-7575.cdiff [100%]

daily.cld updated (version: 7575, sigs: 19671, f-level: 31, builder: ccordes)

WARNING: Your ClamAV installation is OUTDATED!

WARNING: Current functionality level = 29, recommended = 31

DON'T PANIC! Read http://www.clamav.net/support/faq

Database updated (331975 signatures) from database.clamav.net (IP: 202.71.97.92)

[root@mail ~]#


开始时我也用db.cn.clamav.net,后来我与香港一同事讨论后,他建议我直接用国外官方的更新地址:database.clamav.net
更新都是正常,如果能设置到香港代理,速度就更好了。。。

[ 本帖最后由 zenglingping 于 2008-6-27 08:53 编辑 ]

acmilanwin 回复于:2008-06-28 14:08:42

[root@www sasl2]# tail -f /var/log/messages
Jun 28 04:47:17 www sshd(pam_unix)[763]: check pass; user unknown
Jun 28 04:47:17 www sshd(pam_unix)[763]: authentication failure; logname= uid=0 euid=0 tty=ssh ruser= rhost=mail.igame.com.tw
Jun 28 04:47:21 www sshd(pam_unix)[765]: check pass; user unknown
Jun 28 04:47:21 www sshd(pam_unix)[765]: authentication failure; logname= uid=0 euid=0 tty=ssh ruser= rhost=mail.igame.com.tw
Jun 28 07:33:40 www postfix/smtpd[779]: sql_select option missing
Jun 28 07:33:40 www postfix/smtpd[779]: auxpropfunc error no mechanism available
Jun 28 12:22:50 www sshd(pam_unix)[829]: session opened for user root by root(uid=0)
Jun 28 12:25:29 www postfix/smtpd[865]: sql_select option missing
Jun 28 12:25:29 www postfix/smtpd[865]: auxpropfunc error no mechanism available
Jun 28 14:23:34 www sshd(pam_unix)[887]: session opened for user root by root(uid=0)

usercode 回复于:2008-07-03 11:51:33

Jul 3 10:21:51 up postfix/smtpd[2775]: sql_select option missing
Jul 3 10:21:51 up postfix/smtpd[2775]: auxpropfunc error no mechanism available
Jul 3 10:36:34 up postfix/smtpd[2790]: sql_select option missing
Jul 3 10:36:34 up postfix/smtpd[2790]: auxpropfunc error no mechanism available
Jul 3 10:38:04 up postfix/smtpd[2794]: sql_select option missing
Jul 3 10:38:04 up postfix/smtpd[2794]: auxpropfunc error no mechanism available
Jul 3 10:43:48 up postfix/smtpd[2804]: sql_select option missing
Jul 3 10:43:48 up postfix/smtpd[2804]: auxpropfunc error no mechanism available
Jul 3 10:50:54 up postfix/smtpd[2821]: sql_select option missing
Jul 3 10:50:54 up postfix/smtpd[2821]: auxpropfunc error no mechanism available
Jul 3 10:54:10 up postfix/smtpd[2824]: sql_select option missing
Jul 3 10:54:10 up postfix/smtpd[2824]: auxpropfunc error no mechanism available
Jul 3 11:00:47 up postfix/smtpd[2834]: sql_select option missing
Jul 3 11:00:47 up postfix/smtpd[2834]: auxpropfunc error no mechanism available
Jul 3 11:04:03 up postfix/smtpd[2858]: sql_select option missing
Jul 3 11:04:03 up postfix/smtpd[2858]: auxpropfunc error no mechanism available
Jul 3 11:08:02 up postfix/smtpd[2878]: sql_select option missing
Jul 3 11:08:02 up postfix/smtpd[2878]: auxpropfunc error no mechanism available


这是什么原因造成的?但邮件收发是乎也没有影响的。

usercode 回复于:2008-07-03 11:54:04

原来是我的firewall设置问题, 现在通过cn更新也没有问题了,应该通过CN的网站更新要快些吧。

usercode 回复于:2008-07-03 12:01:05

我也想问这个问题,楼主是否再同我们指点指点?不胜谢意!

zenglingping 回复于:2008-07-03 19:18:38

tail -n 10 /var/log/messages

Jul 3 01:20:46 mail postfix/smtpd[2750]: sql_select option missing

Jul 3 01:20:46 mail postfix/smtpd[2750]: auxpropfunc error no mechanism available

Jul 3 04:02:10 mail postfix/smtpd[3220]: sql_select option missing

Jul 3 04:02:10 mail postfix/smtpd[3220]: auxpropfunc error no mechanism available

Jul 3 17:59:07 mail postfix/smtpd[3742]: sql_select option missing

Jul 3 17:59:07 mail postfix/smtpd[3742]: auxpropfunc error no mechanism available

Jul 3 17:59:14 mail postfix/smtpd[3754]: sql_select option missing

Jul 3 17:59:14 mail postfix/smtpd[3754]: auxpropfunc error no mechanism available


我的也都一样,而且我现在安装了两台,一台收,一台发,两台的日志都是一样(安装方法也是一样参考本文的)

亦有很多朋友遇到此问题:

http://bbs.chinaunix.net/viewthread.php?tid=1044356

http://www.extmail.org/forum/thread-5935-1-1.html

http://bbs2.chinaunix.net/viewthread.php?tid=763763

[ 本帖最后由 zenglingping 于 2008-7-3 19:21 编辑 ]

zenglingping 回复于:2008-07-03 19:20:59

检查了一下,这个应该是的,但对于防垃圾邮件的认识与配置还需要好好的补上一课;


[root@mail ~]# ll /var/virusmails/

total 456

-rw-r----- 1 amavis amavis 699 Jun 25 11:52 badh-nQf+GVIFlOxj

-rw-r----- 1 amavis amavis 1034 Jul 1 19:49 spam-03sEc2nrNBwi.gz

-rw-r----- 1 amavis amavis 2348 Jun 28 18:00 spam-0+nBJDUNdbAA.gz

-rw-r----- 1 amavis amavis 18244 Jul 1 20:06 spam-5t-d3zFLZaZ3.gz

-rw-r----- 1 amavis amavis 56404 Jul 1 20:10 spam-7k9QOcwyAwje.gz

-rw-r----- 1 amavis amavis 2497 Jun 25 18:33 spam-B6HxGdD0f1si.gz

-rw-r----- 1 amavis amavis 18211 Jul 1 19:51 spam-dewLb--Ief5d.gz

-rw-r----- 1 amavis amavis 2313 Jun 25 17:45 spam-DPZwETtwznbY.gz

-rw-r----- 1 amavis amavis 2437 Jun 25 18:33 spam-Ibus+GjV1UbW.gz

-rw-r----- 1 amavis amavis 2594 Jun 25 19:49 spam-iONZkOrdXcSl.gz

-rw-r----- 1 amavis amavis 506 Jun 25 10:41 spam-KtyREXS4WDWd.gz

-rw-r----- 1 amavis amavis 1044 Jun 25 13:25 spam-la9yjNcO0QkO.gz

-rw-r----- 1 amavis amavis 2394 Jun 28 18:00 spam-lGTfdnVyWIS4.gz

-rw-r----- 1 amavis amavis 990 Jul 1 19:55 spam-lKpzExEHRIbn.gz

-rw-r----- 1 amavis amavis 670 Jun 25 17:24 spam-lx8qq5WzgTIV.gz

-rw-r----- 1 amavis amavis 18210 Jul 1 20:08 spam-mGC6Y9PzUkid.gz

-rw-r----- 1 amavis amavis 2875 Jun 25 19:52 spam-MOZxCjpZ0MRT.gz

-rw-r----- 1 amavis amavis 18246 Jul 1 19:58 spam-MqYUwd9XNuZd.gz

-rw-r----- 1 amavis amavis 2351 Jul 1 18:54 spam-NoxSCkL0JOhf.gz

-rw-r----- 1 amavis amavis 2284 Jun 28 19:25 spam-qCD9-4pmZKPq.gz

-rw-r----- 1 amavis amavis 18237 Jul 1 20:05 spam-qOS9C14nKacg.gz

-rw-r----- 1 amavis amavis 1080 Jul 1 19:46 spam-qwQj7oPmmSwv.gz

-rw-r----- 1 amavis amavis 909 Jun 25 19:39 spam-sulIb5s3Iuoc.gz

-rw-r----- 1 amavis amavis 919 Jun 25 19:39 spam-T1l+ST9vARDt.gz

-rw-r----- 1 amavis amavis 677 Jun 25 14:56 spam-T6YQq1ZSclTB.gz

-rw-r----- 1 amavis amavis 18239 Jul 1 20:03 spam-TVX1E-KMrnBf.gz

-rw-r----- 1 amavis amavis 916 Jun 25 19:37 spam-UlmH-kRLPytz.gz

-rw-r----- 1 amavis amavis 2296 Jun 28 19:25 spam-vDJ0SIwDjiXd.gz

-rw-r----- 1 amavis amavis 679 Jun 26 18:54 spam-X30gzPdzAEI8.gz

-rw-r----- 1 amavis amavis 496 Jun 25 10:51 spam-xP5GEABC5npC.gz

-rw-r----- 1 amavis amavis 891 Jun 25 15:38 virus-98ewAkdincWJ

-rw-r----- 1 amavis amavis 83551 Jun 25 14:32 virus-h2GgQfE4eWo1

-rw-r----- 1 amavis amavis 83251 Jun 25 14:29 virus-L5YhK2OOl6iY

-rw-r----- 1 amavis amavis 2118 Jun 25 15:43 virus-MQg0LH1rA9R9



shayoulala 回复于:2008-07-04 10:14:01

很好很强大```借鉴一下

ruying 回复于:2008-07-08 15:18:35

请问下,您说的安装软件DB-4.5.20,这个软件是什么哪?如果是BerkeleyDB,我搜索到的版本都很小,都是零点几的版本啊。方便的话,给我回个信息,告诉我该软件的官方网站或者可以下载到的网址好吗?谢谢您了。
------------------
已经找到
这个只有网站,oracle网站不露出链接,否则我就贴出wget命令了。
http://www.oracle.com/technology/software/products/berkeley-db/htdocs/popup/db/4.7.25/db-

[ 本帖最后由 ruying 于 2008-7-10 09:53 编辑 ]

ruying 回复于:2008-07-09 21:33:47

楼主和几位高手,打扰一下:
我按照楼主的教程在一步步的做邮件系统,遇到了一些问题,都尝试解决或者蒙混过关了。
在安装SASL的时候,教程里写道:
启动并测试
# /usr/local/sasl2/sbin/saslauthd -a shadow pam
# /usr/local/sasl2/sbin/testsaslauthd -u root -p root用户密码
我可以执行第一个命令,但执行第二个命令的时候就会报错:
[root@localhost ~]# /usr/local/sasl2.1.22/sbin/testsaslauthd -u root -p @me.cn
connect() : No such file or directory
0: [root@localhost ~]# /usr/local/sasl2.1.22/sbin/testsaslauthd -u root -p @me.cn
connect() : No such file or directory
0: [root@localhost ~]#

----------------------------------------
kill掉所有的saslauthd进程,然后重新执行
#/usr/local/sasl2.1.22/sbin/saslauthd -a shadow pam ,屏幕无报错,ps cux 也显示正常打开了5个saslauthd。
#######自此以上的内容大家可以忽略,我已经发现错在开机自启动启动的命令里/etc/rc.local,并更正了上面的错误,但下面的错误仍然存在######################
这个时候尝试更改root用户的密码报错就变了:
[root@localhost ~]# /usr/local/sasl2.1.22/sbin/testsaslauthd -u root -p @me.cn
0: NO "authentication failed"
------------------------------------------------------------
请您帮我一下好吗?需要什么配置资料您尽管开口,从现在到晚上12点,还有明天白天上班的时间我都在线。谢谢您了。
我是一个新手,只能顺着楼主的教程去做,太复杂的、变通性质的操作我还根本做不了,已经卡在这里很久了,请高手们帮帮忙好吗?哪怕只告诉我我应该去看哪里的日志也可以。

[ 本帖最后由 ruying 于 2008-7-10 01:30 编辑 ]

zenglingping 回复于:2008-07-10 09:07:02

这个似乎没有什么问题,可以继续下一步的工作;

我在测试也是遇到过此问题,你可以新建一个用户,密码设置简单一些,例如密码为123456

/usr/local/sasl2.1.22/sbin/testsaslauthd -u ruying -p 123456


ruying 回复于:2008-07-10 09:31:28

引用:原帖由 zenglingping 于 2008-7-10 09:07 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=8777899&ptid=987344
这个似乎没有什么问题,可以继续下一步的工作;

我在测试也是遇到过此问题,你可以新建一个用户,密码设置简单一些,例如密码为123456

/usr/local/sasl2.1.22/sbin/testsaslauthd -u ruying -p 123456

-------------------------------------------
[root@localhost ~]# /usr/local/sasl2.1.22/sbin/testsaslauthd -u ruying -p 123456
0: NO "authentication failed"
[root@localhost ~]#
-------------------------------------------
谢谢您的回复,可是还是不行。我已经把所有操作都检查过一遍了,我的操作是照着楼主的教程做的,只可能有部分路径(/usr/local/sasl2.1.22/)是自定义的。
您说的没问题是什么意思哪?是说换个简单的用户密码(非root)就可以正常操作,还是说这一步越过了也没什么哪?

-----------------------安装sasl-2.1.22------------------------------
#tar zxvf cyrus-sasl-2.1.22.tar.gz
#cd cyrus-sasl-2.1.22
#./configure --prefix=/usr/local/sasl2 --disable-gssapi --disable-anon --disable-sample --disable-digest --enable-plain --enable-login --enable-sql --with-mysql=/usr/local/mysql --with-mysql-includes=/usr/local/mysql/include/mysql --with-mysql-libs=/usr/local/mysql/lib/mysql --with-authdaemond=/usr/local/courier-authlib/var/spool/authdaemon/socket

--disable-gssapi (禁用通用安全服务应用程序接口(GSSAPI) )
--disable-anon (禁用ANON,ANON是啥我也不太清楚)
--disable-sample (Cyrus SASL库带了两个测试程序:sasl2-sample-server和sasl2-samle-client,分别对应着服务程序和客户程序,可对SASL的配置进行测试。现在我们可以禁用掉它)
--disable-digest (禁用digest,它是啥我也不太清楚)
--enable-plain (使用plain的验证机制)
--enable-login (默认配置不支持login认证机制,但对Outlook Express是必需的)
--enable-sql (原版解释是enable SQL auxprop [no],搞不懂auxprop,貌似不是个英文单词)
--with-mysql=/usr/local/mysql --with-mysql-includes=/usr/local/mysql/include/mysql --with-mysql-libs=/usr/local/mysql/lib/mysql --with-authdaemond=/usr/local/courier-authlib/var/spool/authdaemon/socket (这是指定一些程序的路径,请特别注意尚未安装的courier-authlib,在安装courier-authlib请保证编译安装的路径和这里的一致)
#make
#make install

如果有的话,请关闭原有的sasl:
# mv /usr/lib/libsasl2.a /usr/lib/libsasl2.a.OFF
# mv /usr/lib/libsasl2.la /usr/lib/libsasl2.la.OFF
# mv /usr/lib/libsasl2.so.2.0.19 /usr/lib/libsasl2.so.2.0.19.OFF
# mv /usr/lib/sasl2 /usr/lib/sasl2.OFF
# rm /usr/lib/libsasl2.so
# rm /usr/lib/libsasl2.so.2

# ln -sv /usr/local/sasl2/lib/* /usr/lib

postfix 2.3以后的版本会分别在/usr/local/lib和/usr/local/include中搜索sasl库文件及头文件,故还须将其链接至此目录中:
# ln -sv /usr/local/sasl2/lib/* /usr/local/lib
# ln -sv /usr/local/sasl2/include/sasl/* /usr/local/include

创建运行时需要的目录并调试启动
# mkdir -pv /var/state/saslauthd
# /usr/local/sasl2/sbin/saslauthd -a shadow pam -d
(不明白shadow是什么意思,不是有了pam做加密方式了么?)

启动并测试
# /usr/local/sasl2/sbin/saslauthd -a shadow pam
# /usr/local/sasl2/sbin/testsaslauthd -u root -p root用户密码

配置库文件搜索路径
# echo "/usr/local/sasl2/lib" >> /etc/ld.so.conf
# echo "/usr/local/sasl2/lib/sasl2" >> /etc/ld.so.conf
# ldconfig -v

开机自动启动
# echo "/usr/local/sasl2/sbin/saslauthd -a shadow pam">>/etc/rc.local

[ 本帖最后由 ruying 于 2008-7-10 09:33 编辑 ]

zenglingping 回复于:2008-07-10 10:03:31

/usr/local/sasl2.1.22/sbin/testsaslauthd -

改成一致试试呢?因为系统通常已经安装了sasl2

参考:
# /usr/local/sasl2/sbin/testsaslauthd -u lingping -p 12345

0: OK "Success."


ruying 回复于:2008-07-10 10:05:32

引用:原帖由 zenglingping 于 2008-7-10 10:03 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=8778530&ptid=987344
/usr/local/sasl2.1.22/sbin/testsaslauthd -
改成一致试试呢?因为系统通常已经安装了sasl2

参考:
# /usr/local/sasl2/sbin/testsaslauthd -u lingping -p 12345
0: OK "Success."

---------
哦,你等我删除重装试一下。

柳拂风 回复于:2008-07-10 10:12:28

你上面说的“db”就是BerkeleyDB。
这个系统所用到的软件我打成了一个包,你可以到这里下载
http://www.dragonflys.cn/download/postfix.tar.gz

这是几个月前打的包了,不过用起来应该没有什么问题。当然你也可以自己去找更新的版本。

zenglingping 回复于:2008-07-10 10:19:25

谢谢,我已下载,但我使用mysql-5.0.45.tar遇到问题,或许是系统环境不同引起的;

ruying 回复于:2008-07-10 10:26:28

引用:原帖由 柳拂风 于 2008-7-10 10:12 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=8778641&ptid=987344/url]
你上面说的“db”就是BerkeleyDB。
这个系统所用到的软件我打成了一个包,你可以到这里下载
http://www.dragonflys.cn/download/postfix.tar.gz

这是几个月前打的包了,不过用起来应该没有什么问题。当然你 ...

谢谢,BerkeleyDB我已经找到了最新版本的下载链接,帖子我也改过了。
[url=http://www.oracle.com/technology/software/products/berkeley-db/htdocs/popup/db/4.7.25/db-targz.html]http://www.oracle.com/technology/software/products/berkeley-db/htdocs/popup/db/4.7.25/db-

---------------------
柳先生请和zenglingping 一起帮我看一下SASL的的BUG可以吗?我重新编译安装过了sasl2,但还是报错
[root@localhost ~]# /usr/local/sasl2/sbin/testsaslauthd -u root -p @163.com
0: NO "authentication failed"
[root@localhost ~]#
----------------debug信息-------------------
[root@localhost saslauthd]# /usr/local/sasl2/sbin/saslauthd -a shadow pam -d
saslauthd[7375] :main : num_procs : 5
saslauthd[7375] :main : mech_option: NULL
saslauthd[7375] :main : run_path : /var/state/saslauthd
saslauthd[7375] :main : auth_mech : shadow
saslauthd[7375] :ipc_init : using accept lock file: /var/state/saslauthd/mux.accept
saslauthd[7375] :detach_tty : master pid is: 0
saslauthd[7375] :ipc_init : listening on socket: /var/state/saslauthd/mux
saslauthd[7375] :main : using process model
saslauthd[7376] :get_accept_lock : acquired accept lock
saslauthd[7375] :have_baby : forked child: 7376
saslauthd[7375] :have_baby : forked child: 7377
saslauthd[7375] :have_baby : forked child: 7378
saslauthd[7375] :have_baby : forked child: 7379
saslauthd[7376] :rel_accept_lock : released accept lock
saslauthd[7377] :get_accept_lock : acquired accept lock
saslauthd[7376] :do_auth : auth failure: [user=root] [service=imap] [realm=] [mech=shadow] [reason=Unknown]
saslauthd[7376] :do_request : response: NO

saslauthd[7377] :rel_accept_lock : released accept lock
saslauthd[7378] :get_accept_lock : acquired accept lock
saslauthd[7377] :do_auth : auth failure: [user=root] [service=imap] [realm=] [mech=shadow] [reason=Unknown]
saslauthd[7377] :do_request : response: NO

柳拂风 回复于:2008-07-10 10:31:47

你的操作系统是什么版本?
你执行一下
# history | grep sasl
贴出来给我们看看你装sasl的时候是怎么做的?

ruying 回复于:2008-07-10 10:35:23

引用:原帖由 柳拂风 于 2008-7-10 10:31 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=8778890&ptid=987344
你的操作系统是什么版本?
你执行一下
# history | grep sasl
贴出来给我们看看你装sasl的时候是怎么做的?

[root@localhost ~]# uname -a
Linux localhost.localdomain 2.6.9-11.EL #1 Fri May 20 18:17:57 EDT 2005 i686 i686 i386 GNU/Linux
操作系统的rhel4
操作是严格按照楼主的教程做的,
./configure --prefix=/usr/local/sasl2 --disable-gssapi --disable-anon --disable-sample --disable-digest --enable-plain --enable-login --enable-sql --with-mysql=/usr/local/mysql --with-mysql-includes=/usr/local/mysql/include/mysql --with-mysql-libs=/usr/local/mysql/lib/mysql --with-authdaemond=/usr/local/courier-authlib/var/spool/authdaemon/socket
make
make install
关闭原有的sasl:
# mv /usr/lib/libsasl2.a /usr/lib/libsasl2.a.OFF
# mv /usr/lib/libsasl2.la /usr/lib/libsasl2.la.OFF
# mv /usr/lib/libsasl2.so.2.0.19 /usr/lib/libsasl2.so.2.0.19.OFF
# mv /usr/lib/sasl2 /usr/lib/sasl2.OFF
# rm /usr/lib/libsasl2.so
# rm /usr/lib/libsasl2.so.2

# ln -sv /usr/local/sasl2/lib/* /usr/lib

postfix 2.3以后的版本会分别在/usr/local/lib和/usr/local/include中搜索sasl库文件及头文件,故还须将其链接至此目录中:
# ln -sv /usr/local/sasl2/lib/* /usr/local/lib
# ln -sv /usr/local/sasl2/include/sasl/* /usr/local/include

创建运行时需要的目录并调试启动
# mkdir -pv /var/state/saslauthd
# /usr/local/sasl2/sbin/saslauthd -a shadow pam -d


启动并测试
# /usr/local/sasl2/sbin/saslauthd -a shadow pam
# /usr/local/sasl2/sbin/testsaslauthd -u root -p root用户密码

配置库文件搜索路径
# echo "/usr/local/sasl2/lib" >> /etc/ld.so.conf
# echo "/usr/local/sasl2/lib/sasl2" >> /etc/ld.so.conf
# ldconfig -v
-----------------------
这些操作都做过了。

ruying 回复于:2008-07-10 10:37:34

44 wget http://down1.chinaunix.net/distfiles/cyrus-sasl-2.1.22.tar.gz
166 /usr/local/sasl2.1.22/sbin/saslauthd -a shadow pam -d
169 cd /usr/local/sasl2.1.22/
181 /usr/local/sasl2.1.22/sbin/saslauthd -a shadow
182 /usr/local/sasl2.1.22/sbin/saslauthd --help
184 cd /usr/local/sasl2.1.22/sbin
186 ./testsaslauthd -uroot -p
187 ./testsaslauthd -u root -p @ttttt.com
188 more testsaslauthd
189 ./testsaslauthd -u root -p @ttttt.com
190 ./testsaslauthd -u root -p ttttt
191 ./testsaslauthd -u root -p oooo
192 more testsaslauthd
193 tail -200f testsaslauthd
195 ./testsaslauthd -u o -p oooo
201 /usr/local/sasl2/sbin/saslauthd -a shadow pam
202 ./saslauthd -a shadow pam
203 ./testsaslauthd -u root -p oooo
204 /etc/init.d/saslauthd start
205 ./testsaslauthd -u root -p oooo
207 ./testsaslauthd -u root -p @ttttt.com
222 /usr/local/sasl2/sbin/testsaslauthd -h
223 /usr/local/sasl2/sbin/testsaslauthd --help
224 /usr/local/sasl2.1.22/l2/sbin/testsaslauthd --help
225 /usr/local/sasl2.1.22/sbin/testsaslauthd --help
226 /usr/local/sasl2.1.22/sbin/testsaslauthd -u root -p @ttttt.com
227 /usr/local/sasl2.1.22/sbin/testsaslauthd -u root -p
228 /usr/local/sasl2.1.22/sbin/testsaslauthd -u root -p ttttt.com
229 /usr/local/sasl2/sbin/testsaslauthd -u root -p @ttttt.com
230 /usr/local/sasl2.1.22/sbin/testsaslauthd -u root -p @ttttt.com
231 /usr/local/sasl2.1.22/sbin/testsaslauthd -u root -p ttttt.com
232 /usr/local/sasl2.1.22/sbin/testsaslauthd -u root -p @ttttt.com
233 /usr/local/sasl2.1.22/sbin/testsaslauthd -u root -p @ttttt.com
234 /usr/local/sasl2.1.22/sbin/testsaslauthd --help
236 /usr/local/sasl2.1.22/sbin/testsaslauthd -u root -p @ttttt.com
237 ls /usr/local/sasl2.1.22/sbin/testsaslauthd
238 ls /usr/local/sasl2.1.22/sbin/testsaslauthd -l
239 /etc/init.d/saslauthd start 3
240 /etc/init.d/saslauthd start
241 /etc/init.d/saslauthd restart
242 /usr/local/sasl2.1.22/sbin/testsaslauthd -u root -p @ttttt.com
243 echo "/usr/local/sasl2/lib" >> /etc/ld.so.conf
246 echo "/usr/local/sasl2/sbin/saslauthd -a shadow pam">>/etc/rc.local
247 /usr/local/sasl2.1.22/sbin/testsaslauthd -u root -p @ttttt.com
255 rpm -qa cyrus-sasl-sql-2.1.19-5.EL4.i386
256 rpm -qa cyrus-sasl-sql
443 rpm -qa sasl
444 rpm -qa sasl*
445 tar xzfv cyrus-sasl-2.1.22.tar.gz
446 cd cyrus-sasl-2.1.22
449 rpm qa sasl
450 rpm -qa sasl
453 ./configure --prefix=/usr/local/sasl2.1.22 --disable-gssapi --disable-anon --disable-sample --disable-digest --enable-plain
455 ./configure --prefix=/usr/local/sasl2.1.22 --disable-gssapi --disable-anon --disable-sample --disable-digest --enable-plain --enable-login --enable-sql --with-mysql=/usr/local/mysql --with-mysql-includes=/usr/local/mysql/include/mysql --with-mysql-libs=/usr/local/mysql/lib/mysql --with-authdaemond=/usr/local/courier-authlib/var/spool/authdaemon/socket
458 cd /usr/local/sasl2.1.22/
459 mv /usr/lib/libsasl2.a /usr/lib/libsasl2.a.OFF
460 mv /usr/lib/libsasl2.la /usr/lib/libsasl2.la.OFF
461 mv /usr/lib/libsasl2.so.2.0.19 /usr/lib/libsasl2.so.2.0.19.OFF
462 mv /usr/lib/sasl2 /usr/lib/sasl2.OFF
463 mv /usr/lib/libsasl2.so /usr/lib/libsasl2.so.bak
464 mv /usr/lib/libsasl2.so.2 /usr/lib/libsasl2.so.2.bak
465 ln -sv /usr/local/sasl2.1.22/lib/* /usr/lib
466 ln -sv /usr/local/sasl2.1.22/lib/* /usr/local/lib
467 ln -sv /usr/local/sasl2.1.22/include/sasl/* /usr/local/include
468 mkdir -pv /var/state/saslauthd
469 /usr/local/sasl2.1.22/sbin/saslauthd --help
470 /usr/local/sasl2.1.22/sbin/saslauthd --help
471 /usr/local/sasl2/sbin/saslauthd -a shadow pam -d
472 /usr/local/sasl2.1.22/sbin/saslauthd -a shadow pam -d
473 /usr/local/sasl2.1.22/sbin/saslauthd -a shadow pam -d
474 /usr/local/sasl2.1.22/sbin/saslauthd -a shadow pam -d
475 /usr/local/sasl2.1.22/sbin/saslauthd -a shadow pam
476 /usr/local/sasl2.1.22/sbin/saslauthd
477 /usr/local/sasl2.1.22/sbin/saslauthd -a shadow
478 /usr/local/sasl2.1.22/sbin/saslauthd -a shadow pam
480 /usr/local/sasl2.1.22/sbin/saslauthd -a shadow pa
481 /usr/local/sasl2.1.22/sbin/saslauthd -a shadow
482 /usr/local/sasl2.1.22/sbin/saslauthd -a shadow pam
483 /usr/local/sasl2.1.22/sbin/saslauthd -a shadow pam
484 /usr/local/sasl2/sbin/saslauthd --help
485 /usr/local/sasl2.1.22/sbin/saslauthd --help
486 /usr/local/sasl2.1.22/sbin/testsaslauthd -u root -p @ttttt.com
487 /usr/local/sasl2.1.22/sbin/testsaslauthd -u root -p @ttttt.com
488 /usr/local/sasl2.1.22/sbin/testsaslauthd -u root -p @ttttt.com
489 /usr/local/sasl2.1.22/sbin/testsaslauthd -u root -p @ttttt.com
490 /usr/local/sasl2.1.22/sbin/testsaslauthd -u root -p @ttttt.com
491 /usr/local/sasl2.1.22/sbin/testsaslauthd -u root2 -p @ttttt.com
492 saslauthd -v
493 vi /etc/sysconfig/saslauthd
494 /usr/local/sasl2.1.22/sbin/testsaslauthd -u user1 -p @ttttt.com
495 /usr/local/sasl2.1.22/sbin/testsaslauthd -u test1 -p @ttttt.com
496 /etc/init.d/saslauthd start
497 /usr/local/sasl2.1.22/sbin/testsaslauthd -u root -p @ttttt.com
498 vi /etc/sysconfig/saslauthd
499 /etc/init.d/saslauthd restart
500 /usr/local/sasl2.1.22/sbin/testsaslauthd -u root -p @ttttt.com
501 vi /etc/sysconfig/saslauthd
502 /etc/init.d/saslauthd restart
503 /usr/local/sasl2.1.22/sbin/testsaslauthd -u root -p @ttttt.com
504 /usr/local/sasl2.1.22/sbin/testsaslauthd -u test3 -p @ttttt.com
505 /usr/local/sasl2.1.22/sbin/testsaslauthd -u root -p @ttttt.com
508 more /etc/sysconfig/saslauthd
509 more etc/saslauthd.conf
510 more /etc/saslauthd.conf
511 saslauthd -v
512 vo /etc/saslauthd.conf
513 vi /etc/saslauthd.conf
515 vi /etc/saslauthd.conf
516 vi /etc/sysconfig/saslauthd
517 /etc/init.d/saslauthd restart
518 /usr/local/sasl2.1.22/sbin/testsaslauthd -u root -p @ttttt.com
519 /usr/local/sasl2.1.22/sbin/testsaslauthd -u root -p ooo
537 /usr/local/sasl2.1.22/sbin/saslauthd --help
539 /usr/local/sasl2.1.22/sbin/testsaslauthd -u root -p @ttttt.com
540 service saslauthd start
541 /usr/local/sasl2.1.22/sbin/testsaslauthd -u root -p @ttttt.com
542 /usr/local/sasl2.1.22/sbin/testsaslauthd -u root -p 000
543 /etc/init.d/saslauthd start
544 /usr/local/sasl2.1.22/sbin/testsaslauthd -u root -p 000
545 /usr/local/sasl2.1.22/sbin/testsaslauthd -u root -p
546 /usr/local/sasl2.1.22/sbin/testsaslauthd -u root -p
547 /usr/local/sasl2/sbin/saslauthd -a shadow pam
548 /usr/local/sasl2.1.22/sbin/saslauthd -a shadow pam
549 /usr/local/sasl2.1.22/sbin/testsaslauthd -u root -p
550 /usr/local/sasl2.1.22/sbin/testsaslauthd -u root -p @talktiem.cn
551 /usr/local/sasl2.1.22/sbin/testsaslauthd -u root -p @ttttt.com
552 /usr/local/sasl2.1.22/sbin/saslauthd -a shadow pam -d
553 /usr/local/sasl2.1.22/sbin/saslauthd -a shadow pam
556 /usr/local/sasl2.1.22/sbin/saslauthd -a shadow pam
558 /usr/local/sasl2.1.22/sbin/testsaslauthd -u root -p @ttttt.com
560 /usr/local/sasl2.1.22/sbin/testsaslauthd -u 123 -p 123
561 /etc/init.d/saslauthd start
562 /usr/local/sasl2.1.22/sbin/testsaslauthd -u root -p @ttttt.com
564 vi /etc/sysconfig/saslauthd
565 /usr/local/sasl2.1.22/sbin/testsaslauthd -u root -p @ttttt.com
567 /usr/local/sasl2.1.22/sbin/testsaslauthd -u root -p @ttttt.com
568 /etc/init.d/saslauthd strat
569 /etc/init.d/saslauthd start
570 /usr/local/sasl2.1.22/sbin/testsaslauthd -u root -p @ttttt.com
574 /usr/local/sasl2.1.22/sbin/testsaslauthd -u ruying -p 123456
575 mv /usr/lib/libsasl2.so /usr/lib/libsasl2.so.bak
576 mv /usr/lib/libsasl2.so.2 /usr/lib/libsasl2.so.2.bak
578 /usr/local/sasl2.1.22/sbin/testsaslauthd -u ruying -p 123456
579 ln -sv /usr/local/sasl2.1.22/lib/* /usr/lib
580 /usr/local/sasl2.1.22/sbin/testsaslauthd -u ruying -p 123456
582 /usr/local/sasl2/sbin/testsaslauthd -u root -p @ttttt.com
586 /usr/local/sasl2/sbin/testsaslauthd -u root -p @ttttt.com
588 /usr/local/sasl2/sbin/testsaslauthd -u root -p @ttttt.com
593 history | grep sasl

柳拂风 回复于:2008-07-10 10:44:06

你安装的过程中有没有报什么错误?
你另建一个用户试过吗?

ruying 回复于:2008-07-10 10:45:52

引用:原帖由 柳拂风 于 2008-7-10 10:44 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=8779060&ptid=987344
你安装的过程中有没有报什么错误?
你另建一个用户试过吗?

[root@localhost ~]# /usr/local/sasl2/sbin/testsaslauthd -u user1 -p password
0: NO "authentication failed"
[root@localhost ~]# /usr/local/sasl2/sbin/testsaslauthd -u a1 -p pas
0: NO "authentication failed"
安装过程中并未报错,不知是否可以通过查看日志的方式排查错误?sasl的日志默认放在哪里啊?

柳拂风 回复于:2008-07-10 11:02:08

有可能是你装的sasl跟系统原来的混在一起了
你 #setup 然后看“系统服务”里面的saslauthd有没有被打上*号?

ruying 回复于:2008-07-10 11:15:52

引用:原帖由 柳拂风 于 2008-7-10 11:02 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=8779276&ptid=987344
有可能是你装的sasl跟系统原来的混在一起了
你 #setup 然后看“系统服务”里面的saslauthd有没有被打上*号?

我在系统服务里saslauthd默认不打*号,无论是否勾上*号都不行。
[root@localhost ~]# rpm -qa sasl*
[root@localhost ~]#
--------------------
我能不能一边排障,一边绕过这一步哪?
教程上的步骤是:
1.mysql
2.openssl
3.sasl
4.BerkeleyDB
5。httpd
6.php
七、安装Postfix
八、为postfix开启基于cyrus-sasl的认证功能
九、让postfix支持虚拟域和虚拟用户
………………
我想问下,如果SASL有故障,我能不能继续做下面的配置哪?

[ 本帖最后由 ruying 于 2008-7-10 11:34 编辑 ]

Weikey 回复于:2008-07-10 11:37:18

请问楼主 "BerkeleyDB" 在这个邮件系统里面扮演什么角色呢?在逻辑结构里面也没有“BerkeleyDB”出现。作为数据库方面,已经有了MYSQL啊!

zenglingping 回复于:2008-07-10 16:21:36

如果按照本文所设的步骤,绕过此步会有一些问题:
1.编译postfix时有些关于sasl的参数无法使用;

2.无法启用身份验证;

如果实在不好找原因,可以重装OS试试,或者在另外一台机子(或VM)试试;

Weikey 回复于:2008-07-10 20:14:17

还有关于 BerkeleyDB 其他的一些问题。
在postfix的官方网站howto文档中,有一篇文章为“Postfix+MySQL+Courier+SpamAssassin+Clamav+Amavisd-new+SASL+Maildrop+Squirrelmail ”地址如下:
http://www.postfix.org/docs.html
http://www.postfixvirtual.net/
楼主postfix相关配置和该帖子有很多类似的地方!郁闷的是这些文章我都看了,最后被搞的很迷惑了。
官方howto里面,编译sasl的时候,有把 BerkeleyDB 配置进去。
还真希望大家赐教, BerkeleyDB 在该邮件系统里面到底扮演什么角色呢?谢谢!

ruying 回复于:2008-07-10 21:32:42

引用:原帖由 Weikey 于 2008-7-10 20:14 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=8784643&ptid=987344
还有关于 BerkeleyDB 其他的一些问题。
在postfix的官方网站howto文档中,有一篇文章为“Postfix+MySQL+Courier+SpamAssassin+Clamav+Amavisd-new+SASL+Maildrop+Squirrelmail ”地址如下:
http://www.post ...

楼主已经说过了,你没看回帖哦,楼主说过这个东西是保留的,想用还没来得及用……

zhangfengsh 回复于:2008-07-11 16:29:56

收藏一下。

Weikey 回复于:2008-07-11 18:05:48

DBI connect('database=extmail;host=localhost;mysql_socket=/tmp/mysql.sock','postfix',...) failed: Can't connect to local MySQL server through socket '/tmp/mysql.sock' (2) at /var/www/extsuite/extmail/libs/Ext/Auth/MySQL.pm line 44

各位老大,我登录webmail,就出现上面的错误提示。但是可以登录webmain。

注:
MYSQL我是使用系统自带的rpm包安装的。
mysql.sock文件的实际路径为
/var/lib/mysql/mysql.sock
我设置为这个路径同样出现上述错误!

Extmail
/var/www/extsuite/extmail/webmail.cf
SYS_MYSQL_SOCKET =


Extman
vi /var/www/extsuite/extman/webman.cf
SYS_MYSQL_SOCKET


Courier authentication library
/etc/authmysqlrc
MYSQL_SOCKET


特请各位帮忙看看问题出在哪里!

同时,楼上有位兄弟出现过和我类似的问题,我借鉴了一下,似乎对我没什么帮助!急阿!


错误日志如下:
Jul 11 17:30:40 weiguo authdaemond: failed to connect to mysql server (server=localhost, userid=extmail): Can't connect to local MySQL server t
hrough socket '/var/mysql/mysql.sock' (2)

[ 本帖最后由 Weikey 于 2008-7-11 18:22 编辑 ]

Weikey 回复于:2008-07-11 18:14:01

引用:原帖由 zenglingping 于 2008-6-13 09:34 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=8581597&ptid=987344
感谢楼主的作品,已打印出来,正在研究,很多东西还看不懂;

例:
# tar zxvf openssl-0.9.8e.tar.gz
# cd openssl-0.9.8e
# ./config shared zlib
# make
# make test
# make install
# mv /usr/bi ...


本身有的 openssl 安装路径不同哦!
现在将其安装在
/usr/local/ssl
lib、include等都在该目录下面
楼主所关闭的只是原来的openssl,再创建链接。。。

Weikey 回复于:2008-07-11 21:20:08

引用:原帖由 zhangfengsh 于 2008-7-11 16:29 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=8792196&ptid=987344
收藏一下。



哦!我把这个帖子看了两遍了。。。都没找到啊!

似乎仅看到楼主说:tls暂缓执行吧。。。

Weikey 回复于:2008-07-11 21:31:23

引用:原帖由 柳拂风 于 2008-1-25 18:15 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=7903073&ptid=987344
郁闷啊
在另一台服务器上死活搞不定,同样都是RHEL5.1的系统啊
只好禁用BerkeleyDB:
# vi /etc/amavisd.conf
$enable_db = 0;

目前收发正常,垃圾邮件也能过滤。
只是不知道禁用BerkeleyDB会不会有什么 ...


请问 BerkeleyDB 在这个有机安系统里面扮演什么角色?谢谢!

Weikey 回复于:2008-07-12 09:30:36

引用:原帖由 Weikey 于 2008-7-11 18:05 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=8793287&ptid=987344
DBI connect('database=extmail;host=localhost;mysql_socket=/tmp/mysql.sock','postfix',...) failed: Can't connect to local MySQL server through socket '/tmp/mysql.sock' (2) at /var/www/extsuite/ext ...


该问题已解决!
仔细检查了一下 Extmail 的配置文件。。。
SYS_MYSQL_USER = postfix
SYS_MYSQL_PASS = 123456


修改成:

SYS_MYSQL_USER = Extmail
SYS_MYSQL_PASS = Extmail

就可以了

但是,通过Mozilla Firefox使用Webmail登录邮箱速度超慢阿,至少要5分钟才能进去阿!使用windows 2000下的IE6倒是满快的。

Weikey 回复于:2008-07-12 09:40:46

Jul 12 09:13:28 weiguo extmail[6348]: user=<weiguolau@weiguo.com>, client=192.168.1.8, module=login, status=loginok

Jul 12 09:09:52 weiguo pop3d: Connection, ip=[192.168.1.8]

Jul 12 09:09:52 weiguo pop3d: LOGIN FAILED, user=weiguolau, ip=[192.168.1.8]

Jul 12 09:09:57 weiguo pop3d: Disconnected, ip=[192.168.1.8]


pop3不能验证身份,提示密码错误。。。
oulook同样提示pop3密码错误!

---------------------------------------------------------
已解决,
用户名处,输入格式:user@domain

即可!

[ 本帖最后由 Weikey 于 2008-7-12 11:06 编辑 ]

Weikey 回复于:2008-07-12 10:23:49

引用:原帖由 liheng 于 2007-9-18 23:11 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=7369834&ptid=987344

marion 兄,我猜想也是这里的问题,刚开始还没反映过来,还没想明白应该在哪里改。刚刚终于想通了。
事后经过确认确实也是这里的问题,
解决方法:
在 outlook 里的帐号名写全(test@test.com)就OK了,mar ...



兄弟。。。有没有在帐号里面,不写全名的方法阿!
我也遇到了这个问题的困扰。。
还好,我之前就看了所有的回帖!
当我遇到你这样的错误的时候,还好回头看看你所遇到的问题。。。
万幸阿!

Weikey 回复于:2008-07-12 10:33:25

楼主!以及各位大哥!
该邮件系统存在一个身份验证的极大漏洞阿!
不需要密码,即可发邮件!
测试方法:
“我的服务器要求身份验证”不选,不保存密码,这样就能发邮件,我晕死!

详见:
http://bbs.chinaunix.net/thread-1196318-1-1.html

[ 本帖最后由 Weikey 于 2008-7-12 11:03 编辑 ]

Weikey 回复于:2008-07-12 11:05:24

引用:原帖由 Weikey 于 2008-7-12 09:40 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=8795754&ptid=987344
Jul 12 09:13:28 weiguo extmail[6348]: user=, client=192.168.1.8, module=login, status=loginok

Jul 12 09:09:52 weiguo pop3d: Connection, ip=[192.168.1.8]

Jul 12 09:09:52 weiguo pop3d: LOGIN ...


已解决,
用户名处,输入格式:user@domain

即可!

[ 本帖最后由 Weikey 于 2008-7-12 11:06 编辑 ]

yuhongchun 回复于:2008-07-13 00:37:52

支持 一下

safe.cn 回复于:2008-07-13 12:57:22

DBD-Mysql目前最新的版本为DBD-mysql-4.005,但它和系统中的perl结合使用时会造成extmail无法正常使用,因此我们采用3的版本:
# tar zxvf DBD-mysql-3.0002_4.tar.gz
# cd DBD-mysql-3.0002_4
# unset LANG
# PATH=/usr/local/mysql/bin:$PATH; export PATH
# perl Makefile.PL -mysql_config=/usr/local/mysql/bin/mysql_config -testuser=root -testpassword=123456
# perl -MCPAN -e shell
# make
# make test
# make install
这样才可以正常安装,按照楼主那样编译是不可以正常安装的;

marion 回复于:2008-07-13 16:56:27

还没有解决?
sasl的安装并不麻烦,关键是“头文件”及“库文件”的链接一定要做正确了。

marion 回复于:2008-07-13 16:58:01

谢谢又提供了一供方法,希望其他朋友进行参考。

前面的方法或许是可以的,因为很多人,包括我自己的很多次安装都是照此进行的。

愿再进一步探讨。

Weikey 回复于:2008-07-14 16:25:36

引用:原帖由 safe.cn 于 2008-7-13 12:57 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=8801451&ptid=987344
DBD-Mysql目前最新的版本为DBD-mysql-4.005,但它和系统中的perl结合使用时会造成extmail无法正常使用,因此我们采用3的版本:
# tar zxvf DBD-mysql-3.0002_4.tar.gz
# cd DBD-mysql-3.0002_4
# unset LA ...


RHEL5自带的也是
perl-DBD-MySQL-3.0007-1.fc6

我没有重新安装Mysql,直接使用RHEL5自带的MySQL、perl-DBD-MySQL

省了不少麻烦!

zenglingping 回复于:2008-07-14 16:38:58

以下添加smtp 的 tls 加密部分,欢迎楼主及各位指导,谢谢!

二十一、开启Postfix(smtp)的TLS功能
[2008-7-14 updated]

STARTTLS(TLS)介绍

TLS - Transport Layer Security ( 为网路 OSI 七层中的第四层加密技术,SSL - Secure Socket Layer 协定为之前身 )
SASL - Simple Authentication and Security Layer ( 简易的安全认证,SASL 同时也提供 SMTP 认证,定义在 RFC-2554 http://www.ietf.org/rfc/rfc2554.txt )
Key - 安全连线金钥 ( key-pair ) CA - 授权凭证 ( Certification Authority )

网路上有些独立公正单位例如 VeriSign 及 GlobalSign 等等……它们就是专门贩卖安全金钥 Key 以及授权凭证 CA 的单位,我们这边採用自行製作安全金钥以及授权凭证,自行製作的安全金钥与授权凭证,在功能上与买来的相同,只是向独立公正单位购买来的 Key 跟 CA,会让 Client 使用者心理上觉得比较有保障,因为我们不做生意所以也不需要花钱买Key 跟 CA ,这边 Postfix + TLS 主要目的是保障我的连线加密防止帐号密码外洩。

(一)SMTP和STARTTLS

[转自Marion博客]
SMTP协议默认使用明文在网络传送用户名和密码,这是十分危险的。为此,Postfix使用TLS(Transport Layer Security)来解决这个潜在的危险问题。TLS不仅可以用来加密用户名和密码,还可以加密传送信件的内容。Sendmail使用starttls命令来启动一个SMTP会话加密进程(TLS会话)。Micorsoft的outlook软件和其它的许多MUA也支持STARTTLS。

STARTTLS能实现什么样的功能?
1.实现对一次E-MAIL通讯中server端以及client端彼此身份的校验;
2.加密传输信件(身份不能确认的情况下亦可以实现);
3.认证转发;

由于SMTP是一个存储转发协议,并且一封电子邮件的转交投递可能会涉及到多台SMTP服务器,因此,一个MUA就算能够通过认证并把E-MAIL加密传输至将要经过的第一台SMTP服务器,让最终用户的SMTP通过发送端的身份认证,并认为信件传送过程中没有被篡改也是不太可能的。故而,RFC文件声明说一个实现公共Email的SMTP服务器是不必苛求于在传送邮件中实现上述功能的。不过,对于一个私有网络中的邮件传输来讲,能够以要求必需提供有效证书来实现严格的身份认证和加密传输,因为我们可以将证书部署到需要传送EMAIL服务的每个客户端。

当然,尽管基于TLS的SMTP服务所提供的功能不像基于SSL的HTTP服务那样完美,但在服务器和客户端之间的一次认证会话间加密传输用户名和密码却是完全可以实现的。

(二)openssl简明使用手册

[转自Marion博客]
此处简要介绍了使用openssl来生成CA证书、申请证书、颁发证书以及撤销证书的过程,临时补上openssl一课。

1. 首先建立CA密钥:
openssl genrsa -des3 -out ca.key 1024 (创建密钥)
chmod 400 ca.key (修改权限为仅root能访问)
openssl rsa -noout -text -in ca.key (查看创建的证书)

2. 利用CA密钥自签署CA证书:
openssl req -new -x509 -days 3650 -key ca.key -out ca.crt
chmod 400 ca.crt (修改权限为仅root能访问)
openssl x509 -noout -text -in ca.crt (查看创建的证书)

3. 创建服务器证书签署申请:
openssl genrsa -des3 -out client.key 1024
chmod 400 server.key (修改权限为仅root能访问)
openssl rsa -noout -text -in client.key (查看创建的证书)

4. 利用证书签署申请生成请求:
openssl req -new -key client.key -out client.csr
openssl req -noout -text -in client.csr (查看创建的请求)

5.进行证书签署:
这时候需要先设置一下openssl的配置文件。
modify /usr/share/ssl/openssl.cnf并根据这个配置文件创建相应的目录和文件。
在创建了serial文件之后,还需要添加当前的八进制的serial number,如:01
然后执行:
openssl ca -keyfile ca.key -cert ca.crt -in client.csr -out client.pem

6.证书撤销:
openssl ca -keyfile ca.key -cert ca.crt -revoke client.pem
这时数据库被更新证书被标记上撤销的标志,需要生成新的证书撤销列表:
openssl ca -gencrl -keyfile ca.key -cert ca.crt -out crl/test.crl
查看证书撤销列表:
openssl crl -noout -text -in crl/test.crl
证书撤销列表文件要在WEB站点上可以使用,必须将crldays或crlhours和crlexts加到证书中:
openssl ca -gencrl -config /etc/openssl.cnf -crldays 7 -crlexts crl_ext -out crl/sopac-ca.crl


1. 制作CA证书与Private Key给Postfix SSL/TLS

#建立存放CA的文件夹(非必须)
#mkdir /usr/local/postfix/CA

#cd /usr/local/postfix/CA/


使用CA.pl这个脚本可以方便的制作证书,将此脚本复制到刚刚建立的CA目录下
#cp /usr/local/ssl/misc/CA.pl ./


a. Become your own Certificate Authority, so that you can sign your own public key(官方原文)
执行perl脚本
#perl CA.pl -newca




回车后出现如下代码:

CA certificate filename (or enter to create) #此处我直接回车,保持默认证书名称



Making CA certificate ...

Generating a 1024 bit RSA private key

.......++++++

...++++++

writing new private key to './demoCA/private/cakey.pem'

Enter PEM pass phrase: #输入密码

Verifying - Enter PEM pass phrase: #再次输入密码

-----

You are about to be asked to enter information that will be incorporated

into your certificate request.

What you are about to enter is what is called a Distinguished Name or a DN.

There are quite a few fields but you can leave some blank

For some fields there will be a default value,

If you enter '.', the field will be left blank.

-----

Country Name (2 letter code) [AU]:CN ←此处为国家名称代码

State or Province Name (full name) [Some-State]:GD ←此处为地域(省)名称

Locality Name (eg, city) []:DG ←此处为城市名称

Organization Name (eg, company) [Internet Widgits Pty Ltd]:lanexpert ←此处为单位名称

Organizational Unit Name (eg, section) []:IT ←此处为部分名称

Common Name (eg, YOUR name) []:lingping ←此处为你的名称或服务器名字或省略

Email Address []:lpzeng@lanexpert.cn ←此处为管理邮件



Please enter the following 'extra' attributes

to be sent with your certificate request

A challenge password []:123456 ←输入密码

An optional company name []: ←输入公司名称或省略

Using configuration from /usr/local/ssl/openssl.cnf

Enter pass phrase for ./demoCA/private/cakey.pem:

Check that the request matches the signature

Signature ok

Certificate Details:

Serial Number:

c9:46:33:18:b3:8d:33:d2

Validity

Not Before: Jul 14 03:17:09 2008 GMT

Not After : Jul 14 03:17:09 2011 GMT

Subject:

countryName = CN

stateOrProvinceName = GD

organizationName = lanexpert

organizationalUnitName = IT

commonName = lingping

emailAddress = lpzeng@lanexpert.cn

X509v3 extensions:

X509v3 Subject Key Identifier:

5F:5D:AB:C6:D1:8E:56:7E:01:24:12:16:70:3C:5F:F9:B2:FE:78:C7

X509v3 Authority Key Identifier:

keyid:5F:5D:AB:C6:D1:8E:56:7E:01:24:12:16:70:3C:5F:F9:B2:FE:78:C7

DirName:/C=CN/ST=GD/O=lanexpert/OU=IT/CN=lingping/emailAddress=lpzeng@lanexpert.cn

serial:C9:46:33:18:B3:8D:33:D2



X509v3 Basic Constraints:

CA:TRUE

Certificate is to be certified until Jul 14 03:17:09 2011 GMT (1095 days)




b. Create an unpassworded private key for host mail.lanexpert.local and create an unsigned public key certificate.(官方原文,大意为创建一个没有密码的私有Key给主机和创建一个没有签名的公共Key证书)



# openssl req -new -nodes -keyout lp-key.pem -out lp-req.pem -days 3650

Generating a 1024 bit RSA private key

.++++++

...........................++++++

writing new private key to 'lp-key.pem'

-----

You are about to be asked to enter information that will be incorporated

into your certificate request.

What you are about to enter is what is called a Distinguished Name or a DN.

There are quite a few fields but you can leave some blank

For some fields there will be a default value,

If you enter '.', the field will be left blank.

-----

Country Name (2 letter code) [AU]:CN

State or Province Name (full name) [Some-State]:GD

Locality Name (eg, city) []:DG

Organization Name (eg, company) [Internet Widgits Pty Ltd]:lanexpert

Organizational Unit Name (eg, section) []:IT

Common Name (eg, YOUR name) []:lingping

Email Address []:lpzeng@lanexpert.cn



Please enter the following 'extra' attributes

to be sent with your certificate request

A challenge password []:123456

An optional company name []:




c. Sign the public key certificate for host mail.lanexpert.local with the Certification Authority private key that we created a few steps ago.



# openssl ca -out lp-cert.pem -infiles lp-req.pem

Using configuration from /usr/local/ssl/openssl.cnf

Enter pass phrase for ./demoCA/private/cakey.pem:

Check that the request matches the signature

Signature ok

Certificate Details:

Serial Number:

c9:46:33:18:b3:8d:33:d3

Validity

Not Before: Jul 14 03:19:53 2008 GMT

Not After : Jul 14 03:19:53 2009 GMT

Subject:

countryName = CN

stateOrProvinceName = GD

organizationName = lanexpert

organizationalUnitName = IT

commonName = lingping

emailAddress = lpzeng@lanexpert.cn

X509v3 extensions:

X509v3 Basic Constraints:

CA:FALSE

Netscape Comment:

OpenSSL Generated Certificate

X509v3 Subject Key Identifier:

21:B8:4C:AB:8D:D6:E3:E8:E1:14:E4:50:8E:0B:AF:C7:0D:08:4C:86

X509v3 Authority Key Identifier:

keyid:5F:5D:AB:C6:D1:8E:56:7E:01:24:12:16:70:3C:5F:F9:B2:FE:78:C7



Certificate is to be certified until Jul 14 03:19:53 2009 GMT (365 days)

Sign the certificate? [y/n]:y





1 out of 1 certificate requests certified, commit? [y/n]y

Write out database with 1 new entries

Data Base Updated




d. Install the host private key, the host public key certificate, and the Certification Authority certificate files. This requires super-user privileges.(官方原文)



为了管理方便,将以上创建的证书全部复制到/etc/postfix目录下,并设置相应的权限

#cp demoCA/cacert.pem lp-key.pem lp-cert.pem /etc/postfix/

#chmod 644 /etc/postfix/lp-cert.pem /etc/postfix/cacert.pem

#chmod 400 /etc/postfix/lp-key.pem




2. 修改Postfix配置文件,添加启用TLS选项



#nano /etc/postfix/main.cf

添加以下内容:

# Smtp TLS config

smtp_use_tls = yes

smtp_tls_security_level = may

smtp_tls_session_cache_databases = btree:/var/lib/postfix/smtp_tls_session_cache

smtpd_use_tls = yes

smtp_tls_note_starttls_offer = yes

smtpd_tls_key_file = /etc/postfix/lp-key.pem (注意路径是否正确)

smtpd_tls_cert_file = /etc/postfix/lp-cert.pem (注意路径是否正确)

smtpd_tls_CAfile = /etc/postfix/cacert.pem (注意路径是否正确)

smtpd_tls_loglevel = 1

smtpd_tls_received_header = yes

smtpd_tls_session_cache_timeout = 3600s

smtpd_tls_security_level = may

smtpd_tls_session_cache_databases = btree:/var/lib/postfix/smtpd_tls_session_cache

tls_random_source = dev:/dev/urandom




#nano /etc/postfix/master.cf

启用以下选项:

smtps inet n - n - - smtpd

-o smtpd_tls_wrappermode=yes

-o smtpd_sasl_auth_enable=yes


注意“-o”前面的空格



重新加载Postfix配置文件

#postfix reload




检查并测试TLS是否启动成功

Smtp默认SSL端口是465

# netstat -tunlp |grep 465

tcp 0 0 0.0.0.0:465 0.0.0.0:* LISTEN 20559/master




#telnet localhost 25 #测试是否启动TLS加密

Trying 127.0.0.1...

Connected to localhost.localdomain (127.0.0.1).

Escape character is '^]'.

220 Welcome to our mail.lanexpert.cn ESMTP,Warning:Version not Available!

ehlo lanexpert.local

250-mail.lanexpert.local

250-PIPELINING

250-SIZE 14336000

250-VRFY

250-ETRN

250-STARTTLS #多出一行

250-AUTH LOGIN PLAIN

250-AUTH=LOGIN PLAIN

250-ENHANCEDSTATUSCODES

250-8BITMIME

250 DSN

Starttls #手动输入

220 2.0.0 Ready to start TLS #显示此字样为成功启用

quit

quit

Connection closed by foreign host.




在客户端(如Outlook)设置加密的smtp发信测试是否正常

[attach]273688[/attach]



经测试,使用加密后的smtp发送邮件是正常的。



配置文件部分参考资料:http://www.postfix.org/TLS_README.html

PS.开始时没有按照官方文档配置(参考此文档http://www.lihuawei.cn/FreeBSD/document/postfix_tls_sasl2_courier-imap.html),出现如下错误(未解决),后来按照官方文档重新配置,此问题解决:

Report:同样telnet localhost 25 ‘out’表示自动出现的,’In’表示手动输入的

Out: 220 Welcome to our mail.lanexpert.cn ESMTP,Warning:Version not Available!

In: ehlo lanexpert.cn

Out: 250-mail.lanexpert.local

Out: 250-PIPELINING

Out: 250-SIZE 14336000

Out: 250-VRFY

Out: 250-ETRN

Out: 250-STARTTLS

Out: 250-AUTH LOGIN PLAIN

Out: 250-AUTH=LOGIN PLAIN

Out: 250-ENHANCEDSTATUSCODES

Out: 250-8BITMIME

Out: 250 DSN

In: starttls

Out: 454 4.7.0 TLS not available due to local problem

In: quit

Out: 221 2.0.0 Bye


[ 本帖最后由 zenglingping 于 2008-7-14 16:42 编辑 ]
截图_2025-11-15_16-00-57.jpg
截图_2025-11-15_16-00-57.jpg (63.8 KiB) 查看 849 次
zenglingping 回复于:2008-07-14 16:45:06


二十二、启用POP3及IMAP加密功能

[2008-7-14 updated]

1.设置POP3s (Port:995)证书产生的配置文件



# nano /usr/local/courier-imap/etc/pop3d.cnf




根据自己的实据情况作出相应的修改:

RANDFILE = /usr/local/courier-imap/share/pop3d.rand



[ req ]

default_bits = 1024

encrypt_key = yes

distinguished_name = req_dn

x509_extensions = cert_type

prompt = no



[ req_dn ]

C=CN #国家代码

ST=GD #地域或省名称

L=DG #城市名称

O=lanexpert #组织名称

OU=IT #单位名称

CN=localhost

emailAddress=lpzeng@lanexpert.cn #管理邮件





[ cert_type ]

nsCertType = server


2.设置IMAPs(Port:993)证书产生的配置文件



# nano /usr/local/courier-imap/etc/imapd.cnf





RANDFILE = /usr/local/courier-imap/share/imapd.rand



[ req ]

default_bits = 1024

encrypt_key = yes

distinguished_name = req_dn

x509_extensions = cert_type

prompt = no



[ req_dn ]

C=CN

ST=GD

L=DG

O=lanexpert

OU=IT

CN=localhost

emailAddress=lpzeng@lanexpert.cn





[ cert_type ]

nsCertType = server


3. 运行以下命令生成安全登陆认证的金钥imapd.pem和pop3d.pem文件,存放于/usr/local/courier-imap/share/目录下



#/usr/local/courier-imap/sbin/mkimapdcert

#/usr/local/courier-imap/sbin/mkpop3dcert




检查证书文件是否成功生成:

# ll /usr/local/courier-imap/share/*.pem

-rw------- 1 root root 1999 Jul 14 12:24 /usr/local/courier-imap/share/imapd.pem

-rw------- 1 root root 2003 Jul 14 12:24 /usr/local/courier-imap/share/pop3d.pem


4. 修改imapd-ssl及pop3d-ssl配置文件,启用imapd-ssl及pop3d-ssl



#nano /usr/local/courier-imap/etc/imapd-ssl

将 IMAPDSSLSTART=NO

改为:

IMAPDSSLSTART=YES


#nano /usr/local/courier-imap/etc/pop3d-ssl

将POP3_STARTTLS=NO

改为:

POP3_STARTTLS=YES




保存并退出,重启courier-imapd 服务

service courier-imapd restart


检查imapd-ssl及pop3d-ssl启动是否正常:

# netstat -tunlp |grep :993

tcp 0 0 0.0.0.0:993 0.0.0.0:* LISTEN 21361/couriertcpd



# netstat -tunlp |grep :995

tcp 0 0 0.0.0.0:995 0.0.0.0:* LISTEN 21373/couriertcpd




从以上检查结果可知,993&995在正常监听状态中,基本上,imapd-ssl与pop3d-ssl正常启用并运行,以下在客户端(outlook)设置测试接收邮件是否正常:



Outlook POP3-ssl设置如下:



[attach]273694[/attach]



IMAP-ssl设置如下:

配置部分参考资料:http://www.lihuawei.cn/FreeBSD/document ... -imap.html

经测试,以上配置OK,已成功启用IMAPs及POP3s.
截图_2025-11-15_16-04-07.jpg
截图_2025-11-15_16-04-07.jpg (71.08 KiB) 查看 848 次
截图_2025-11-15_16-04-31.jpg
截图_2025-11-15_16-04-31.jpg (56.42 KiB) 查看 848 次
Weikey 回复于:2008-07-14 16:57:36


Jul 14 16:04:07 weiguo pop3d: Connection, ip=[192.168.1.8]

Jul 14 16:04:07 weiguo authdaemond: received auth request, service=pop3, authtype=login

Jul 14 16:04:07 weiguo authdaemond: authmysql: trying this module

Jul 14 16:04:07 weiguo authdaemond: authmysqllib: connected. Versions: header 50045, client 50045, server 50045

Jul 14 16:04:07 weiguo authdaemond: SQL query: SELECT username, password, "", '1000', '1000', concat('/var/mailbox/',maildir), concat('/var/mailbox/',maildir), "", name, "" FROM mailbox WHERE username = 'weiguolau@weiguo.com'

Jul 14 16:04:07 weiguo authdaemond: password matches successfully

Jul 14 16:04:07 weiguo authdaemond: authmysql: sysusername=<null>, sysuserid=1000, sysgroupid=1000, homedir=/var/mailbox/weiguo.com/weiguolau/Maildir/, address=weiguolau@weiguo.com, fullname=weiguolau, maildir=/var/mailbox/weiguo.com/weiguolau/Maildir/, quota=<null>, options=<null>

Jul 14 16:04:07 weiguo authdaemond: authmysql: clearpasswd=<null>, passwd=$1$YvUtyD8p$TIU4Gu3ngwazNz/LOZn1B0

Jul 14 16:04:07 weiguo authdaemond: Authenticated: sysusername=<null>, sysuserid=1000, sysgroupid=1000, homedir=/var/mailbox/weiguo.com/weiguolau/Maildir/, address=weiguolau@weiguo.com, fullname=weiguolau, maildir=/var/mailbox/weiguo.com/weiguolau/Maildir/, quota=<null>, options=<null>

Jul 14 16:04:07 weiguo authdaemond: Authenticated: clearpasswd=weiguolau, passwd=$1$YvUtyD8p$TIU4Gu3ngwazNz/LOZn1B0

Jul 14 16:04:07 weiguo pop3d: LOGIN, user=weiguolau@weiguo.com, ip=[192.168.1.8], port=[1269]

Jul 14 16:04:07 weiguo pop3d: LOGOUT, user=weiguolau@weiguo.com, ip=[192.168.1.8], port=[1269], top=0, retr=0, rcvd=12, sent=39, time=0

[ 本帖最后由 Weikey 于 2008-7-14 17:05 编辑 ]


Weikey 回复于:2008-07-14 16:58:15


Jul 14 16:05:08 weiguo pop3d-ssl: Connection, ip=[192.168.1.8]

Jul 14 16:05:10 weiguo authdaemond: received auth request, service=pop3, authtype=login

Jul 14 16:05:10 weiguo authdaemond: authmysql: trying this module

Jul 14 16:05:10 weiguo authdaemond: authmysqllib: connected. Versions: header 50045, client 50045, server 50045

Jul 14 16:05:10 weiguo authdaemond: SQL query: SELECT username, password, "", '1000', '1000', concat('/var/mailbox/',maildir), concat('/var/mailbox/',maildir), "", name, "" FROM mailbox WHERE username = 'weiguolau@weiguo.com'

Jul 14 16:05:10 weiguo authdaemond: password matches successfully

Jul 14 16:05:10 weiguo pop3d-ssl: LOGIN, user=weiguolau@weiguo.com, ip=[192.168.1.8], port=[1276]

Jul 14 16:05:10 weiguo authdaemond: authmysql: sysusername=<null>, sysuserid=1000, sysgroupid=1000, homedir=/var/mailbox/weiguo.com/weiguolau/Maildir/, address=weiguolau@weiguo.com, fullname=weiguolau, maildir=/var/mailbox/weiguo.com/weiguolau/Maildir/, quota=<null>, options=<null>

Jul 14 16:05:10 weiguo authdaemond: authmysql: clearpasswd=<null>, passwd=$1$YvUtyD8p$TIU4Gu3ngwazNz/LOZn1B0

Jul 14 16:05:10 weiguo authdaemond: Authenticated: sysusername=<null>, sysuserid=1000, sysgroupid=1000, homedir=/var/mailbox/weiguo.com/weiguolau/Maildir/, address=weiguolau@weiguo.com, fullname=weiguolau, maildir=/var/mailbox/weiguo.com/weiguolau/Maildir/, quota=<null>, options=<null>

Jul 14 16:05:10 weiguo authdaemond: Authenticated: clearpasswd=weiguolau, passwd=$1$YvUtyD8p$TIU4Gu3ngwazNz/LOZn1B0

Jul 14 16:05:10 weiguo pop3d-ssl: LOGOUT, user=weiguolau@weiguo.com, ip=[192.168.1.8], port=[1276], top=0, retr=0, rcvd=12, sent=39, time=0

[ 本帖最后由 Weikey 于 2008-7-14 17:04 编辑 ]


Weikey 回复于:2008-07-14 17:06:57


楼上的大哥太快了。。。。

我也正准备补充TLS相关的内容。。。。。

无巧不成拙阿。。。。。


zenglingping 回复于:2008-07-14 17:09:08


呵呵,我看了一下,你的配置有些不同,也可以共享一下呀。。。:mrgreen:



weiguo


Weikey 回复于:2008-07-14 17:20:59


Jul 14 17:13:14 weiguo pop3d-ssl: Connection, ip=[192.168.1.8]

Jul 14 17:13:16 weiguo authdaemond: received auth request, service=pop3, authtype=login

Jul 14 17:13:16 weiguo authdaemond: authmysql: trying this module

Jul 14 17:13:16 weiguo authdaemond: authmysqllib: connected. Versions: header 50045, client 50045, server 50045

Jul 14 17:13:16 weiguo authdaemond: SQL query: SELECT username, password, "", '1000', '1000', concat('/var/mailbox/',maildir), concat('/var/mailbox/',maildir), "", name, "" FROM mailbox WHERE username = 'weiguolau@weiguo.com'

Jul 14 17:13:16 weiguo authdaemond: password matches successfully

Jul 14 17:13:16 weiguo authdaemond: authmysql: sysusername=<null>, sysuserid=1000, sysgroupid=1000, homedir=/var/mailbox/weiguo.com/weiguolau/Maildir/, address=weiguolau@weiguo.com, fullname=weiguolau, maildir=/var/mailbox/weiguo.com/weiguolau/Maildir/, quota=<null>, options=<null>

Jul 14 17:13:16 weiguo authdaemond: authmysql: clearpasswd=<null>, passwd=$1$YvUtyD8p$TIU4Gu3ngwazNz/LOZn1B0

Jul 14 17:13:16 weiguo authdaemond: Authenticated: sysusername=<null>, sysuserid=1000, sysgroupid=1000, homedir=/var/mailbox/weiguo.com/weiguolau/Maildir/, address=weiguolau@weiguo.com, fullname=weiguolau, maildir=/var/mailbox/weiguo.com/weiguolau/Maildir/, quota=<null>, options=<null>

Jul 14 17:13:16 weiguo authdaemond: Authenticated: clearpasswd=weiguolau, passwd=$1$YvUtyD8p$TIU4Gu3ngwazNz/LOZn1B0

Jul 14 17:13:16 weiguo pop3d-ssl: LOGIN, user=weiguolau@weiguo.com, ip=[192.168.1.8], port=[1297]

Jul 14 17:13:16 weiguo pop3d-ssl: LOGOUT, user=weiguolau@weiguo.com, ip=[192.168.1.8], port=[1297], top=0, retr=0, rcvd=12, sent=39, time=0

Jul 14 17:13:23 weiguo postfix/smtpd[6945]: connect from unknown[192.168.1.8]

Jul 14 17:13:23 weiguo authdaemond: received auth request, service=smtp, authtype=login

Jul 14 17:13:23 weiguo authdaemond: authmysql: trying this module

Jul 14 17:13:23 weiguo authdaemond: SQL query: SELECT username, password, "", '1000', '1000', concat('/var/mailbox/',maildir), concat('/var/mailbox/',maildir), "", name, "" FROM mailbox WHERE username = 'weiguolau@weiguo.com'

Jul 14 17:13:23 weiguo authdaemond: password matches successfully

Jul 14 17:13:23 weiguo authdaemond: authmysql: sysusername=<null>, sysuserid=1000, sysgroupid=1000, homedir=/var/mailbox/weiguo.com/weiguolau/Maildir/, address=weiguolau@weiguo.com, fullname=weiguolau, maildir=/var/mailbox/weiguo.com/weiguolau/Maildir/, quota=<null>, options=<null>

Jul 14 17:13:23 weiguo authdaemond: authmysql: clearpasswd=<null>, passwd=$1$YvUtyD8p$TIU4Gu3ngwazNz/LOZn1B0

Jul 14 17:13:23 weiguo authdaemond: Authenticated: sysusername=<null>, sysuserid=1000, sysgroupid=1000, homedir=/var/mailbox/weiguo.com/weiguolau/Maildir/, address=weiguolau@weiguo.com, fullname=weiguolau, maildir=/var/mailbox/weiguo.com/weiguolau/Maildir/, quota=<null>, options=<null>

Jul 14 17:13:23 weiguo authdaemond: Authenticated: clearpasswd=weiguolau, passwd=$1$YvUtyD8p$TIU4Gu3ngwazNz/LOZn1B0

Jul 14 17:13:23 weiguo postfix/smtpd[6945]: 6E33F217A7E: client=unknown[192.168.1.8], sasl_method=LOGIN, sasl_username=weiguolau@weiguo.com

Jul 14 17:13:23 weiguo postfix/cleanup[6953]: 6E33F217A7E: message-id=<000801c8e592$2265ec30$08a59384@cplkm20>

Jul 14 17:13:23 weiguo postfix/qmgr[6955]: 6E33F217A7E: from=<weiguolau@weiguo.com>, size=1424, nrcpt=1 (queue active)

Jul 14 17:13:23 weiguo postfix/smtpd[6945]: disconnect from unknown[192.168.1.8]

Jul 14 17:13:23 weiguo postfix/trivial-rewrite[6971]: warning: do not list domain weiguo.com in BOTH virtual_mailbox_domains and relay_domains

Jul 14 17:13:23 weiguo postfix/virtual[6956]: 6E33F217A7E: to=<hy_mis_liuwg@weiguo.com>, relay=virtual, delay=0.06, delays=0.05/0.01/0/0, dsn=2.0.0, status=sent (delivered to maildir)

Jul 14 17:13:23 weiguo postfix/qmgr[6955]: 6E33F217A7E: removed

Jul 14 17:13:24 weiguo pop3d-ssl: Connection, ip=[192.168.1.8]

Jul 14 17:13:24 weiguo authdaemond: received auth request, service=pop3, authtype=login

Jul 14 17:13:24 weiguo authdaemond: authmysql: trying this module

Jul 14 17:13:24 weiguo authdaemond: SQL query: SELECT username, password, "", '1000', '1000', concat('/var/mailbox/',maildir), concat('/var/mailbox/',maildir), "", name, "" FROM mailbox WHERE username = 'weiguolau@weiguo.com'

Jul 14 17:13:24 weiguo authdaemond: password matches successfully

Jul 14 17:13:24 weiguo authdaemond: authmysql: sysusername=<null>, sysuserid=1000, sysgroupid=1000, homedir=/var/mailbox/weiguo.com/weiguolau/Maildir/, address=weiguolau@weiguo.com, fullname=weiguolau, maildir=/var/mailbox/weiguo.com/weiguolau/Maildir/, quota=<null>, options=<null>

Jul 14 17:13:24 weiguo authdaemond: authmysql: clearpasswd=<null>, passwd=$1$YvUtyD8p$TIU4Gu3ngwazNz/LOZn1B0

Jul 14 17:13:24 weiguo authdaemond: Authenticated: sysusername=<null>, sysuserid=1000, sysgroupid=1000, homedir=/var/mailbox/weiguo.com/weiguolau/Maildir/, address=weiguolau@weiguo.com, fullname=weiguolau, maildir=/var/mailbox/weiguo.com/weiguolau/Maildir/, quota=<null>, options=<null>

Jul 14 17:13:24 weiguo authdaemond: Authenticated: clearpasswd=weiguolau, passwd=$1$YvUtyD8p$TIU4Gu3ngwazNz/LOZn1B0

Jul 14 17:13:24 weiguo pop3d-ssl: LOGIN, user=weiguolau@weiguo.com, ip=[192.168.1.8], port=[1299]

Jul 14 17:13:24 weiguo pop3d-ssl: LOGOUT, user=weiguolau@weiguo.com, ip=[192.168.1.8], port=[1299], top=0, retr=0, rcvd=12, sent=39, time=0

[ 本帖最后由 Weikey 于 2008-7-17 14:50 编辑 ]


Weikey 回复于:2008-07-14 17:41:50


引用:原帖由 zenglingping 于 2008-7-14 17:09 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=8810540&ptid=987344

呵呵,我看了一下,你的配置有些不同,也可以共享一下呀。。。:mrgreen:

weiguo

一、 sasl不同之处,多了几条:

--with-dbpath=/usr/local/BerkeleyDB \

--with-bdb-libdir=/usr/local/BerkeleyDB/lib \

--with-bdb-incdir=/usr/local/BerkeleyDB/include \

二、courier-authlib 在 $下编译 在#下安装

如此而已

Weikey 回复于:2008-07-14 17:43:46


其实我都不知道 BerkeleyDB 在这个邮件系统里面扮演什么角色。。。

哈哈!不过,我在安装软件的时候,现会去看一下其配置参数,如果有关于 BerkeleyDB 我就会配置进去。。。。。。


zuxi_sui 回复于:2008-07-16 11:38:55


在安装postfix时报错如下



bin/postconf: /lib/tls/libc.so.6: version `GLIBC_2.4' not found (required by /usr/lib/libssl.so.0.9.

请问如何解决?看了下资料,可能是库问题。


Weikey 回复于:2008-07-17 14:50:01


引用:原帖由 zuxi_sui 于 2008-7-16 11:38 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=8824358&ptid=987344

在安装postfix时报错如下



bin/postconf: /lib/tls/libc.so.6: version `GLIBC_2.4' not found (required by /usr/lib/libssl.so.0.9.

请问如何解决?看了下资料,可能是库问题。




应该是没有找到openssl的lib吧...



建议你将postfix的配置发上来看看..


chen1104 回复于:2008-07-17 17:54:05


引用:原帖由 fuleru 于 2007-9-27 16:03 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=7410573&ptid=987344

我在编译courier-imap遇到了些问题,请问是什么原因?

Making all in tcpd

make[2]: Entering directory `/root/postfix/courier-imap-4.1.3/tcpd'

make all-am

make[3]: Entering directory `/root/pos ...






错误同上,后按照楼主给的解答可能是openssl的问题,于是重新编译openssl,出现如下错误,请教各位达人!





以下是错误代码



make[2]: Entering directory `/root/openssl-0.9.8h/apps'

../libcrypto.a(bn86-elf.o)(.text+0x0): In function `bn_mul_add_words':

: multiple definition of `bn_mul_add_words'

../libcrypto.a(bn_asm.o)(.text+0x0): first defined here

/usr/bin/ld: Warning: size of symbol `bn_mul_add_words' changed from 451 in ../libcrypto.a(bn_asm.o) to 700 in ../libcrypto.a(bn86-elf.o)

../libcrypto.a(bn86-elf.o)(.text+0x2c0): In function `bn_mul_words':

: multiple definition of `bn_mul_words'

../libcrypto.a(bn_asm.o)(.text+0x1c3): first defined here

/usr/bin/ld: Warning: size of symbol `bn_mul_words' changed from 447 in ../libcrypto.a(bn_asm.o) to 320 in ../libcrypto.a(bn86-elf.o)

../libcrypto.a(bn86-elf.o)(.text+0x400): In function `bn_sqr_words':

: multiple definition of `bn_sqr_words'

../libcrypto.a(bn_asm.o)(.text+0x382): first defined here

/usr/bin/ld: Warning: size of symbol `bn_sqr_words' changed from 235 in ../libcrypto.a(bn_asm.o) to 225 in ../libcrypto.a(bn86-elf.o)

../libcrypto.a(bn86-elf.o)(.text+0x4f0): In function `bn_div_words':

: multiple definition of `bn_div_words'

../libcrypto.a(bn_asm.o)(.text+0x46d): first defined here

/usr/bin/ld: Warning: size of symbol `bn_div_words' changed from 267 in ../libcrypto.a(bn_asm.o) to 23 in ../libcrypto.a(bn86-elf.o)

../libcrypto.a(bn86-elf.o)(.text+0x510): In function `bn_add_words':

: multiple definition of `bn_add_words'

../libcrypto.a(bn_asm.o)(.text+0x578): first defined here

/usr/bin/ld: Warning: size of symbol `bn_add_words' changed from 188 in ../libcrypto.a(bn_asm.o) to 428 in ../libcrypto.a(bn86-elf.o)

../libcrypto.a(bn86-elf.o)(.text+0x6c0): In function `bn_sub_words':

: multiple definition of `bn_sub_words'

../libcrypto.a(bn_asm.o)(.text+0x634): first defined here

/usr/bin/ld: Warning: size of symbol `bn_sub_words' changed from 222 in ../libcrypto.a(bn_asm.o) to 428 in ../libcrypto.a(bn86-elf.o)

collect2: ld returned 1 exit status

make[2]: *** [link_app.gnu] Error 1

make[2]: Leaving directory `/root/openssl-0.9.8h/apps'

make[1]: *** [openssl] Error 2

make[1]: Leaving directory `/root/openssl-0.9.8h/apps'

make: *** [build_apps] Error 1





上面就是出错的部分。


liuhuizhen 回复于:2008-07-17 18:33:55


太精彩了

要好好的研究


yuanyuan025 回复于:2008-07-19 08:24:39


嘻嘻顶了


zenglingping 回复于:2008-07-19 15:08:38


原文中的authmysqlrc配置部分有个小问题:



编辑/etc/authmysqlrc 为以下内容,其中2525,2525 为postfix 用户的UID和GID。

MYSQL_SERVER localhost

MYSQL_PORT 3306 (指定你的mysql监听的端口,这里使用默认的3306)

MYSQL_USERNAME extmail (这时为后文要用的数据库的所有者的用户名)

MYSQL_PASSWORD extmail (密码)

MYSQL_SOCKET /tmp/mysql.sock

MYSQL_DATABASE extmail

MYSQL_USER_TABLE mailbox

MYSQL_CRYPT_PWFIELD password

MYSQL_UID_FIELD '2525'

MYSQL_GID_FIELD '2525'

MYSQL_LOGIN_FIELD username

MYSQL_HOME_FIELD concat('/var/mailbox/'maildir)

MYSQL_NAME_FIELD name

MYSQL_MAILDIR_FIELD concat('/var/mailbox/',maildir)




正确为:
MYSQL_HOME_FIELD concat('/var/mailbox/',homedir)




这样设置会导致在extmail中无法自动回复和转发指定收件人。



参考extmail官方论坛:http://www.extmail.org/forum/thread-8378-1-1.html

[ 本帖最后由 zenglingping 于 2008-7-19 15:12 编辑 ]


marion 回复于:2008-07-19 16:19:16


引用:正确为:



[Copy to clipboard] [ - ]

CODE:

MYSQL_HOME_FIELD concat('/var/mailbox/',homedir)



这样设置会导致在extmail中无法自动回复和转发指定收件人。



参考extmail官方论坛:http://www.extmail.org/forum/thread-8378-1-1.html




笔误,已更正;谢!


marion 回复于:2008-07-19 16:20:55


应该是头文件或库文件链接错误。


zenglingping 回复于:2008-07-19 17:28:01


谢谢马老大,如果有时间,请帮忙指正701及702有关tls配置方面的不足之处。。


zenglingping 回复于:2008-07-19 17:30:13


SYS_MYSQL_USER = postfix

SYS_MYSQL_PASS = 123456




时间允许的话,请老大把这个也更正一下。。。


zuxi_sui 回复于:2008-07-22 12:42:54


在启动 /usr/local/sbin/amavisd start时出错,关于DB_file

后来就去掉了perl -MCPAN -e shell

安装下载目录下找到了DB_File.pm ,然后从那目录下删除掉了,

这样可以启动了。但extmail不能打开了。如下信息



页面报错如下:

Can't locate DB_File.pm in @INC (@INC contains: /mail/webapps/extsuite/extmail/libs /usr/lib/perl5/5.8.5/i386-linux-thread-multi /usr/lib/perl5/5.8.5 /usr/lib/perl5/site_perl/5.8.5/i386-linux-thread-multi /usr/lib/perl5/site_perl/5.8.4/i386-linux-thread-multi /usr/lib/perl5/site_perl/5.8.3/i386-linux-thread-multi /usr/lib/perl5/site_perl/5.8.2/i386-linux-thread-multi /usr/lib/perl5/site_perl/5.8.1/i386-linux-thread-multi /usr/lib/perl5/site_perl/5.8.0/i386-linux-thread-multi /usr/lib/perl5/site_perl/5.8.5 /usr/lib/perl5/site_perl/5.8.4 /usr/lib/perl5/site_perl/5.8.3 /usr/lib/perl5/site_perl/5.8.2 /usr/lib/perl5/site_perl/5.8.1 /usr/lib/perl5/site_perl/5.8.0 /usr/lib/perl5/site_perl /usr/lib/perl5/vendor_perl/5.8.5/i386-linux-thread-multi /usr/lib/perl5/vendor_perl/5.8.4/i386-linux-thread-multi /usr/lib/perl5/vendor_perl/5.8.3/i386-linux-thread-multi /usr/lib/perl5/vendor_perl/5.8.2/i386-linux-thread-multi /usr/lib/perl5/vendor_perl/5.8.1/i386-linux-thread-multi /usr/lib/perl5/vendor_perl/5.8.0/i386-linux-thread-multi /usr/lib/perl5/vendor_perl/5.8.5 /usr/lib/perl5/vendor_perl/5.8.4 /usr/lib/perl5/vendor_perl/5.8.3 /usr/lib/perl5/vendor_perl/5.8.2 /usr/lib/perl5/vendor_perl/5.8.1 /usr/lib/perl5/vendor_perl/5.8.0 /usr/lib/perl5/vendor_perl) at /mail/webapps/extsuite/extmail/libs/Ext/DB.pm line 81. BEGIN failed--compilation aborted at /mail/webapps/extsuite/extmail/libs/Ext/DB.pm line 81. Compilation failed in require at /mail/webapps/extsuite/extmail/libs/Ext/Storage/Maildir.pm line 575. BEGIN failed--compilation aborted at /mail/webapps/extsuite/extmail/libs/Ext/Storage/Maildir.pm line 575. Compilation failed in require at /mail/webapps/extsuite/extmail/libs/Ext/App.pm line 28. BEGIN failed--compilation aborted at /mail/webapps/extsuite/extmail/libs/Ext/App.pm line 28. Compilation failed in require at /mail/webapps/extsuite/extmail/libs/Ext/App/Login.pm line 16. BEGIN failed--compilation aborted at /mail/webapps/extsuite/extmail/libs/Ext/App/Login.pm line 16. Compilation failed in require at /mail/webapps/extsuite/extmail/cgi/index.cgi line 20.









启动:/usr/local/sbin/amavisd start



Problem in Amavis:B or Amavis:B::SNMP code:

BerkeleyDB needs compatible versions of libdb & db.h

you have db.h version 4.6.21 and libdb version 4.2.52

Compilation failed in require at (eval 7 line 15.

BEGIN failed--compilation aborted at (eval 7 line 15.



也是关于BerkeleyDB 的


zuxi_sui 回复于:2008-07-22 13:33:54


参考55楼<<<---Problem in Amavis:B or Amavis:B::SNMP code:

BerkeleyDB needs compatible versions of libdb & db.h

you have db.h version 4.5.20 and libdb version 4.2.52

Compilation failed in require at (eval 92) line 15.

BEGIN failed--compilation aborted at (eval 92) line 15

-->>在安装BerkeleyDB perl模块的时候 我用的是cpan自动安装 出错 因此到cpan.org下载一个手动编译安装

修改



现在启动/usr/local/sbin/amavisd start 不会有问题了。但页面访问extmail仍旧有问题,还是包错如下:

Can't locate DB_File.pm in @INC (@INC contains: /mail/webapps/extsuite/extmail/libs /usr/lib/perl5/5.8.5/i386-linux-thread-multi /usr/lib/perl5/5.8.5 /usr/lib/perl5/site_perl/5.8.5/i386-linux-thread-multi /usr/lib/perl5/site_perl/5.8.4/i386-linux-thread-multi /usr/lib/perl5/site_perl/5.8.3/i386-linux-thread-multi /usr/lib/perl5/site_perl/5.8.2/i386-linux-thread-multi /usr/lib/perl5/site_perl/5.8.1/i386-linux-thread-multi /usr/lib/perl5/site_perl/5.8.0/i386-linux-thread-multi /usr/lib/perl5/site_perl/5.8.5 /usr/lib/perl5/site_perl/5.8.4 /usr/lib/perl5/site_perl/5.8.3 /usr/lib/perl5/site_perl/5.8.2 /usr/lib/perl5/site_perl/5.8.1 /usr/lib/perl5/site_perl/5.8.0 /usr/lib/perl5/site_perl /usr/lib/perl5/vendor_perl/5.8.5/i386-linux-thread-multi /usr/lib/perl5/vendor_perl/5.8.4/i386-linux-thread-multi /usr/lib/perl5/vendor_perl/5.8.3/i386-linux-thread-multi /usr/lib/perl5/vendor_perl/5.8.2/i386-linux-thread-multi /usr/lib/perl5/vendor_perl/5.8.1/i386-linux-thread-multi /usr/lib/perl5/vendor_perl/5.8.0/i386-linux-thread-multi /usr/lib/perl5/vendor_perl/5.8.5 /usr/lib/perl5/vendor_perl/5.8.4 /usr/lib/perl5/vendor_perl/5.8.3 /usr/lib/perl5/vendor_perl/5.8.2 /usr/lib/perl5/vendor_perl/5.8.1 /usr/lib/perl5/vendor_perl/5.8.0 /usr/lib/perl5/vendor_perl) at /mail/webapps/extsuite/extmail/libs/Ext/DB.pm line 81. BEGIN failed--compilation aborted at /mail/webapps/extsuite/extmail/libs/Ext/DB.pm line 81. Compilation failed in require at /mail/webapps/extsuite/extmail/libs/Ext/Storage/Maildir.pm line 575. BEGIN failed--compilation aborted at /mail/webapps/extsuite/extmail/libs/Ext/Storage/Maildir.pm line 575. Compilation failed in require at /mail/webapps/extsuite/extmail/libs/Ext/App.pm line 28. BEGIN failed--compilation aborted at /mail/webapps/extsuite/extmail/libs/Ext/App.pm line 28. Compilation failed in require at /mail/webapps/extsuite/extmail/libs/Ext/App/Login.pm line 16. BEGIN failed--compilation aborted at /mail/webapps/extsuite/extmail/libs/Ext/App/Login.pm line 16. Compilation failed in require at /mail/webapps/extsuite/extmail/cgi/index.cgi line 20.


zuxi_sui 回复于:2008-07-22 13:45:12


终于解决了。原来是手动编译时没有指定BerkeleyDB 的路径


zuxi_sui 回复于:2008-07-22 17:15:07


Red Hat Enterprise Linux AS release 4 (Nahant Update 4) 下安装到postfix时出错了。



bin/postconf: /lib/tls/libc.so.6: version `GLIBC_2.4' not found (required by /usr/lib/libssl.so.0.9.8)


bigbigsh 回复于:2008-07-22 19:32:00


这个文章是我见过最好的一个..资料真的很多.不得不感叹~~开放的力量...我也打算开始装~~


marion 回复于:2008-07-23 10:09:18


感谢你的辛勤劳动及开源精神,我把这两篇回复的说明加在原文中,让各位朋友去参照测试使用了。


abcd99 回复于:2008-07-23 11:01:13


真是好人,我正好在学习postfix



谢谢楼主和所有热情分享经验的高手们


zuxi_sui 回复于:2008-07-23 13:02:30


web可以发信,也收到了推信,foxmail只能发,不能收,是因为没有真实域名的原因嘛

foxmail 包错-ERR LOGIN FAILED.

maillog 日志如下:

Jul 23 13:01:22 test pop3d: Connection, ip=[192.168.0.138]

Jul 23 13:01:22 test pop3d: LOGIN FAILED, user=testt, ip=[192.168.0.138]

Jul 23 13:01:29 test pop3d: Disconnected, ip=[192.168.0.138]

Jul 23 13:01:32 test pop3d: Connection, ip=[192.168.0.138]

Jul 23 13:01:32 test pop3d: LOGIN FAILED, user=testt, ip=[192.168.0.138]

Jul 23 13:01:38 test pop3d: Disconnected, ip=[192.168.0.138]


zenglingping 回复于:2008-07-23 15:36:04


做内部测试不需要真实域名亦可。


zenglingping 回复于:2008-07-23 15:37:20


引用:原帖由 marion 于 2008-7-23 10:09 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=8888461&ptid=987344

感谢你的辛勤劳动及开源精神,我把这两篇回复的说明加在原文中,让各位朋友去参照测试使用了。




因您的大作才接触postfix,了解太少了,对postfix认识不够,担心误人子弟。。


bigbigsh 回复于:2008-07-24 20:51:49


太感谢楼主因你的配置我开始学习POSTFIX

有一点看不懂你的配置..这些内容写在哪里~~~~~~~~~~~

由于extmail要进行本地邮件的投递操作,故必须将运行apache服务器用户的身份修改为您的邮件投递代理的用户;本例中打开了apache服务器的suexec功能,故使用以下方法来实现虚拟主机运行身份的指定。此例中的MDA为postfix自带,因此将指定为postfix用户:

<VirtualHost *:80>

ServerName mail.benet.org

DocumentRoot /var/www/extsuite/extmail/html/

ScriptAlias /extmail/cgi /var/www/extsuite/extmail/cgi

Alias /extmail /var/www/extsuite/extmail/html

SuexecUserGroup postfix postfix

</VirtualHost>



还有下现面这些

放在httpd.conf那个位置...脚本的最底下吗?

如果您没有打开apache服务器的suexec功能,也可以使用以下方法解决:

# vi /etc/httpd/httpd.conf

User postfix

Group postfix



<VirtualHost *:80>

ServerName mail.benet.org

DocumentRoot /var/www/extsuite/extmail/html/

ScriptAlias /extmail/cgi /var/www/extsuite/extmail/cgi

Alias /extmail /var/www/extsuite/extmail/html

</VirtualHost>

[ 本帖最后由 bigbigsh 于 2008-7-24 20:55 编辑 ]


Weikey 回复于:2008-07-25 09:53:03


引用:原帖由 zuxi_sui 于 2008-7-22 17:15 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=8884357&ptid=987344

Red Hat Enterprise Linux AS release 4 (Nahant Update 4) 下安装到postfix时出错了。



bin/postconf: /lib/tls/libc.so.6: version `GLIBC_2.4' not found (required by /usr/lib/libssl.so.0.9.8)




`GLIBC_2.4' not found



安装glibc,系统安装光盘里面有吧!!


zenglingping 回复于:2008-07-25 10:44:18


引用:原帖由 bigbigsh 于 2008-7-24 20:51 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=8903949&ptid=987344

太感谢楼主因你的配置我开始学习POSTFIX

有一点看不懂你的配置..这些内容写在哪里~~~~~~~~~~~

由于extmail要进行本地邮件的投递操作,故必须将运行apache服务器用户的身份修改为您的邮件投递代理的用户;本例 ...






写在httpd.conf文末即可;



不使用suexec参数的话,直接改apache服务器的用户名与组亦可。


bigbigsh 回复于:2008-07-25 10:55:51


太感谢zenglingping

我现在又可以开始配啦...感觉很顺利~~~就是装PHP的时候差几个包不过搞定了~~等我配好了我也写一下..我装的过程中出现的难点~~:wink:



zenglingping

你们装DBD-mysql

有没有出现这个问题

[root@mailserver DBD-mysql-3.0002_4]# perl Makefile.PL

Can't locate DBI/DBD.pm in @INC (@INC contains: /usr/lib/perl5/5.8.5/i386-linux-thread-multi /usr/lib/perl5/5.8.5 /usr/lib/perl5/site_perl/5.8.5/i386-li

[root@mailserver DBD-mysql-3.0002_4]# make

make: *** No targets specified and no makefile found. Stop.

[root@mailserver DBD-mysql-3.0002_4]#

[ 本帖最后由 bigbigsh 于 2008-7-25 11:35 编辑 ]


bigbigsh 回复于:2008-07-25 11:52:43


原因找到了..原来是我MYSQ LDBI-1.50没装



现在又有一个问题



[root@mailserver docs]# mysql -u root -p < extmail.sql

-bash: mysql: command not found

root@mailserver docs]# mysql -u root -p < init.sql

-bash: mysql: command not found



我可不可以这样做..我MYSQL很菜的~~

[root@mailserver bin]# /usr/local/mysql/bin/mysql -u root -p </var/www/extsuite/extman/docs/extmail.sql

Enter password:

[root@mailserver bin]# /usr/local/mysql/bin/mysql -u root -p </var/www/extsuite/extman/docs/init.sql

Enter password:

[root@mailserver bin]#

[ 本帖最后由 bigbigsh 于 2008-7-25 12:17 编辑 ]


zenglingping 回复于:2008-07-25 12:00:09


本邮件系统可以不安装php.因为extmail不是基于php的webmail...


bigbigsh 回复于:2008-07-25 12:18:45


现在又有一个问题



[root@mailserver docs]# mysql -u root -p < extmail.sql

-bash: mysql: command not found

root@mailserver docs]# mysql -u root -p < init.sql

-bash: mysql: command not found



我可不可以这样做..我MYSQL很菜的~~

[root@mailserver bin]# /usr/local/mysql/bin/mysql -u root -p </var/www/extsuite/extman/docs/extmail.sql

Enter password:

[root@mailserver bin]# /usr/local/mysql/bin/mysql -u root -p </var/www/extsuite/extman/docs/init.sql

Enter password:

[root@mailserver bin]#


bigbigsh 回复于:2008-07-25 14:35:58


那位帮我看这下这个是什么原因..我登陆 EXTMAIL报这个错 网上说是用户密码不对..

DBI connect('database=extmail;host=localhost;mysql_socket=/tmp/mysql.sock','postfix',...) failed: Access denied for user 'postfix'@'localhost' (using password: YES) at /var/www/extsuite/extmail/libs/Ext/Auth/MySQL.pm line 44



是不是要在mysql数据库里建两个用户和密码(这步我没做..因为文档没让我做)

用户extmail 密码extmail

用户postfix 密码123456





这两步我都加了

etc/authmysqlrc

MYSQL_USERNAME extmail

MYSQL_PASSWORD extmail

/var/www/extsuite/extmail/webmail.cf

SYS_MYSQL_USER = postfix

SYS_MYSQL_PASS = 123456

[ 本帖最后由 bigbigsh 于 2008-7-25 14:39 编辑 ]


bigbigsh 回复于:2008-07-25 14:57:40


该问题已解决!

仔细检查了一下 Extmail 的配置文件。。。

SYS_MYSQL_USER = postfix

SYS_MYSQL_PASS = 123456

修改成:

SYS_MYSQL_USER = Extmail

SYS_MYSQL_PASS = Extmail

请老大把这里更改一下..免的新手跟我一样找了半天



现在又有新问题

[root@mailserver saslauthd]# /usr/local/sasl2/sbin/testsaslauthd -u user1 -p password

-bash: /usr/local/sasl2/sbin/testsaslauthd: No such file or directory

为什么这里我没有生成..那什么办

[ 本帖最后由 bigbigsh 于 2008-7-25 15:51 编辑 ]


chen1104 回复于:2008-07-25 16:48:38


引用:原帖由 marion 于 2008-7-19 16:20 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=8862984&ptid=987344

应该是头文件或库文件链接错误。






问题已经解决,我的OPENSSL的版本可能用得太高了,开始是用OPENSSL-0.98h的版本,后换成openssl-0.98g的版本后,编译没出过问题,且courier-imap编译也不再出错!!



谢楼主!!


bigbigsh 回复于:2008-07-25 17:16:27


新问题

[root@mailserver saslauthd]# /usr/local/sasl2/sbin/testsaslauthd -u user1 -p password

-bash: /usr/local/sasl2/sbin/testsaslauthd: No such file or directory

为什么这里我没有生成..那什么办

网上找资料

testsaslauthd程序默认是没有编译的,

需要在源码目录树的saslauthd子目录中运行 # make testsaslauthd命令生成

[root@mailserver saslauthd]# cp testsaslauthd /usr/local/sasl2/sbin/



为什么还是老样子

[root@mailserver sbin]# /usr/local/sasl2/sbin/testsaslauthd -u root -p root

connect() : No such file or directory

0: [root@mailserver sbin]#


zenglingping 回复于:2008-07-25 17:26:08


重新编译一下sasl试试。。


bigbigsh 回复于:2008-07-25 17:39:23


回 zenglingping



[root@mailserver src]# rpm -e openldap-devel-2.2.13-8.i386

[root@mailserver src]# rpm -e cyrus-sasl-devel-2.1.19-14.i386

[root@mailserver src]# rpm -e python-ldap-2.0.1-2.i386

我刚刚删除几个系统里自带的这几个..

重新编要紧吗?还有我刚刚

查了一下这里有这个文件

[root@mailserver sasl2]# find / -name testsaslauthd

/usr/sbin/testsaslauthd

/usr/local/src/cyrus-sasl-2.1.22/saslauthd/testsaslauthd



[root@mailserver sasl2]# /usr/sbin/testsaslauthd -u root -p root

connect() : No such file or directory

[ 本帖最后由 bigbigsh 于 2008-7-25 17:41 编辑 ]


bigbigsh 回复于:2008-07-25 19:10:40


我重新装了一下 sasl

[root@mailserver sbin]# cat /var/log/messages





Jul 25 20:11:39 mailserver saslauthd[3064]: detach_tty : master pid is: 3064

Jul 25 20:11:39 mailserver saslauthd[3064]: ipc_init : listening on socket: /var/state/saslauthd/mux

Jul 25 20:11:40 mailserver fstab-sync[3073]: removed all generated mount points

Jul 25 20:15:41 mailserver sshd(pam_unix)[3122]: session opened for user root by (uid=0)

Jul 25 20:30:25 mailserver saslauthd[17148]: detach_tty : master pid is: 0

Jul 25 20:30:25 mailserver saslauthd[17148]: ipc_init : listening on socket: /var/state/saslauthd/mux

Jul 25 20:30:32 mailserver saslauthd[17148]: server_exit : master exited: 0

Jul 25 20:30:35 mailserver saslauthd[17154]: detach_tty : could not lock pid file /var/state/saslauthd/saslauthd.pid: Resource temporarily unavailable

Jul 25 20:30:35 mailserver saslauthd[17153]: detach_tty : Cannot start saslauthd

Jul 25 20:30:35 mailserver saslauthd[17153]: detach_tty : Another instance of saslauthd is currently running

[root@mailserver sbin]#


bigbigsh 回复于:2008-07-25 22:07:19


我重新装了还是没有这个文件

[root@mailserver sbin]# /usr/local/sasl2/sbin/testsaslauthd -u root -p root

-bash: /usr/local/sasl2/sbin/testsaslauthd: No such file or directory

[root@mailserver sbin]#


bigbigsh 回复于:2008-07-26 00:51:21


[root@mailserver sbin]# /usr/local/sasl2/sbin/testsaslauthd -u root -p root

-bash: /usr/local/sasl2/sbin/testsaslauthd: No such file or directory

关于以上这个问题我终于搞定了..

我的步骤是删除

第一 yum remove cyrus-sasl

第二testsaslauthd程序默认是没有编译

源码目录树的saslauthd子目录中运行 # make testsaslauthd命令生成

cp testsaslauthd /usr/local/sasl2/sbin/

/usr/local/sasl2/sbin/testsaslauthd -u root -p root

connect() : No such file or directory

第三步saslauthd会在在/etc/生成sasldb2

sasldb2文件默认权限是root用户可以读写和root组可以读,所以当你使用其他用户认证时,是无法读取数据的.你可以用chmod o+r sasldb2,让其他用户也可以读取数据,就不会出现连接不到服务的问题了

ps cux 查看一下进程

root 3041 0.0 0.1 3628 464 ? Ss 02:08 0:00 saslauthd

kill -9 3041

/usr/local/sasl2/sbin/saslauthd -a shadow pam



[root@mailserver ~]# /usr/local/sasl2/sbin/testsaslauthd -u ljq -p wellhope

0: OK "Success."



:wink: :wink: :wink: :wink: 这个地方我今天搞了一天...晕


bigbigsh 回复于:2008-07-26 18:01:01


一有一个怪问题。那位朋友帮我看看是什么原因//

foxmail发送邮发不了..

按marion的文档说/usr/local/lib/sasl2/smtpd.conf

pwcheck_method: authdaemond

log_level: 3

mech_list:PLAIN LOGIN

authdaemond_path:/usr/local/courier-authlib/var/spool/authdaemon/socket

我发不了

但是如果我加上pwcheck_method: saslauthd就可以发了

这是什么原因,是不是我courier-authlib有问题//


bigbigsh 回复于:2008-07-27 11:25:49


以上问题解决了..原因是我perl-GD没装管理员页面进不去.域没加, 用户当然也就没有了~~~:)

所以就出现用户密码不对啦~~~~~~


bigbigsh 回复于:2008-07-27 23:00:02


那位大师帮我看看...我现在做到能正常外发MAIL ,但是自己给自己发不行,其它的邮箱往这里发退信,以下是maillog日志.帮忙看看谢谢!!!





Jul 28 00:18:58 mailserver pop3d: LOGIN, user=lin@dcas.cn, ip=[222.66.101.226]

Jul 28 00:18:59 mailserver pop3d: LOGOUT, user=lin@dcas.cn, ip=[222.66.101.226], top=0, retr=0, rcvd=12, sent=39, time=1

Jul 28 00:19:31 mailserver postfix/smtpd[3091]: connect from unknown[222.66.101.226]

Jul 28 00:19:36 mailserver postfix/smtpd[3091]: NOQUEUE: reject: RCPT from unknown[222.66.101.226]: 554 5.7.1 <candy59839@yahoo.com.tw>: Relay access denied; from=<michael78694@MyMainServer.com> to=<candy59839@yahoo.com.tw> proto=SMTP helo=<www.MyMainServer.com>

Jul 28 00:19:36 mailserver postfix/smtpd[3091]: lost connection after RCPT from unknown[222.66.101.226]

Jul 28 00:19:36 mailserver postfix/smtpd[3091]: disconnect from unknown[222.66.101.226]

Jul 28 00:19:48 mailserver postfix/smtpd[3091]: connect from unknown[222.66.101.226]

Jul 28 00:19:49 mailserver postfix/trivial-rewrite[3125]: warning: do not list domain dcas.cn in BOTH virtual_alias_domains and virtual_mailbox_domains

Jul 28 00:19:49 mailserver postfix/smtpd[3091]: NOQUEUE: reject: RCPT from unknown[222.66.101.226]: 550 5.1.1 <jinquan@dcas.cn>: Recipient address rejected: User unknown in virtual alias table; from=<499387551@qq.com> to=<jinquan@dcas.cn> proto=SMTP helo=<smtpbg25.qq.com>

Jul 28 00:19:49 mailserver postfix/smtpd[3091]: disconnect from unknown[222.66.101.226]

Jul 28 00:20:14 mailserver pop3d: Connection, ip=[222.66.101.226]

Jul 28 00:20:15 mailserver authdaemond: received auth request, service=pop3, authtype=login

Jul 28 00:20:15 mailserver authdaemond: authmysql: trying this module

Jul 28 00:20:15 mailserver authdaemond: SQL query: SELECT username, password, "", '1001', '1001', concat('/var/mailbox/',homedir), concat('/var/mailbox/',maildir), "", name, "" FROM mailbox WHERE username = "lin@dcas.cn"

Jul 28 00:20:15 mailserver authdaemond: password matches successfully

Jul 28 00:20:15 mailserver authdaemond: authmysql: sysusername=<null>, sysuserid=1001, sysgroupid=1001, homedir=/var/mailbox/dcas.cn/lin, address=lin@dcas.cn, fullname=<null>, maildir=/var/mailbox/dcas.cn/lin/Maildir/, quota=<null>, options=<null>

Jul 28 00:20:15 mailserver authdaemond: Authenticated: sysusername=<null>, sysuserid=1001, sysgroupid=1001, homedir=/var/mailbox/dcas.cn/lin, address=lin@dcas.cn, fullname=<null>, maildir=/var/mailbox/dcas.cn/lin/Maildir/, quota=<null>, options=<null>

Jul 28 00:20:15 mailserver pop3d: LOGIN, user=lin@dcas.cn, ip=[222.66.101.226]

Jul 28 00:20:16 mailserver pop3d: LOGOUT, user=lin@dcas.cn, ip=[222.66.101.226], top=0, retr=0, rcvd=12, sent=39, time=1

[root@mailserver ~]#


zenglingping 回复于:2008-07-28 08:51:51


重点检查一下/etc/authmysqlrc和/etc/postfix/main.cf配置文件,我也曾遇到过类似问题,都是由于输入时的疏忽造成的;



另外,你在extmail中收发邮件是否正常呢?


bigbigsh 回复于:2008-07-28 10:27:30


回zenglingping

extmail能发邮件给别人,但是给本地邮箱发信就不行。用FOXMAIL往外发邮件可以,FOXMAIL收信没有报错。。但是没有信件.自己给自己发报错


bigbigsh 回复于:2008-07-28 10:46:24


我清空了日志重新发MAIL,,,我把日志帖出来大家帮我指点一下~~~



[root@mailserver log]# more messages

Jul 28 12:12:18 mailserver postfix/smtpd[4426]: sql_select option missing

Jul 28 12:12:18 mailserver postfix/smtpd[4426]: auxpropfunc error no mechanism available





[root@mailserver log]# more maillog

Jul 28 12:12:18 mailserver postfix/smtpd[4426]: warning: dict_nis_init: NIS doma

in name not set - NIS lookups disabled

Jul 28 12:12:18 mailserver postfix/smtpd[4426]: connect from unknown[196.196.0.1

50]

Jul 28 12:12:18 mailserver authdaemond: received auth request, service=smtp, aut

htype=login

Jul 28 12:12:18 mailserver authdaemond: authmysql: trying this module

Jul 28 12:12:18 mailserver authdaemond: SQL query: SELECT username, password, ""

, '1001', '1001', concat('/var/mailbox/',homedir), concat('/var/mailbox/',maildi

r), "", name, "" FROM mailbox WHERE username = "lin@dcas.cn"

Jul 28 12:12:18 mailserver authdaemond: password matches successfully

Jul 28 12:12:18 mailserver authdaemond: authmysql: sysusername=<null>, sysuserid

=1001, sysgroupid=1001, homedir=/var/mailbox/dcas.cn/lin, address=lin@dcas.cn, f

ullname=<null>, maildir=/var/mailbox/dcas.cn/lin/Maildir/, quota=<null>, options

=<null>

Jul 28 12:12:18 mailserver authdaemond: Authenticated: sysusername=<null>, sysus

erid=1001, sysgroupid=1001, homedir=/var/mailbox/dcas.cn/lin, address=lin@dcas.c

n, fullname=<null>, maildir=/var/mailbox/dcas.cn/lin/Maildir/, quota=<null>, opt

ions=<null>

Jul 28 12:12:18 mailserver postfix/trivial-rewrite[4429]: warning: do not list d

omain dcas.cn in BOTH virtual_alias_domains and virtual_mailbox_domains

Jul 28 12:12:18 mailserver postfix/smtpd[4426]: NOQUEUE: reject: RCPT from unkno

wn[196.196.0.150]: 550 5.1.1 <lin@dcas.cn>: Recipient address rejected: User unknown in virtual alias table; from=<lin

@dcas.cn> to=<lin@dcas.cn> proto=ESMTP helo=<14e6780851cb4a5>

Jul 28 12:12:18 mailserver postfix/smtpd[4426]: disconnect from unknown[196.196.0.150]

Jul 28 12:12:18 mailserver pop3d: Connection, ip=[196.196.0.150]

Jul 28 12:12:18 mailserver authdaemond: received auth request, service=pop3, authtype=login

Jul 28 12:12:18 mailserver authdaemond: authmysql: trying this module

Jul 28 12:12:18 mailserver authdaemond: SQL query: SELECT username, password, "", '1001', '1001', concat('/var/mailbox

/',homedir), concat('/var/mailbox/',maildir), "", name, "" FROM mailbox WHERE username = "lin@dcas.cn"

Jul 28 12:12:18 mailserver authdaemond: password matches successfully

Jul 28 12:12:18 mailserver authdaemond: authmysql: sysusername=<null>, sysuserid=1001, sysgroupid=1001, homedir=/var/m

ailbox/dcas.cn/lin, address=lin@dcas.cn, fullname=<null>, maildir=/var/mailbox/dcas.cn/lin/Maildir/, quota=<null>, opt

ions=<null>

Jul 28 12:12:18 mailserver authdaemond: Authenticated: sysusername=<null>, sysuserid=1001, sysgroupid=1001, homedir=/v

ar/mailbox/dcas.cn/lin, address=lin@dcas.cn, fullname=<null>, maildir=/var/mailbox/dcas.cn/lin/Maildir/, quota=<null>,

options=<null>

Jul 28 12:12:18 mailserver pop3d: LOGIN, user=lin@dcas.cn, ip=[196.196.0.150]

Jul 28 12:12:18 mailserver pop3d: LOGOUT, user=lin@dcas.cn, ip=[196.196.0.150], top=0, retr=0, rcvd=12, sent=39, time=

0

Jul 28 12:12:29 mailserver pop3d: Connection, ip=[196.196.0.150]

Jul 28 12:12:29 mailserver authdaemond: received auth request, service=pop3, authtype=login

Jul 28 12:12:29 mailserver authdaemond: authmysql: trying this module

Jul 28 12:12:29 mailserver authdaemond: SQL query: SELECT username, password, "", '1001', '1001', concat('/var/mailbox

/',homedir), concat('/var/mailbox/',maildir), "", name, "" FROM mailbox WHERE username = "lin@dcas.cn"

Jul 28 12:12:29 mailserver authdaemond: password matches successfully

Jul 28 12:12:29 mailserver authdaemond: authmysql: sysusername=<null>, sysuserid=1001, sysgroupid=1001, homedir=/var/m

ailbox/dcas.cn/lin, address=lin@dcas.cn, fullname=<null>, maildir=/var/mailbox/dcas.cn/lin/Maildir/, quota=<null>, opt

ions=<null>

Jul 28 12:12:29 mailserver authdaemond: Authenticated: sysusername=<null>, sysuserid=1001, sysgroupid=1001, homedir=/v

ar/mailbox/dcas.cn/lin, address=lin@dcas.cn, fullname=<null>, maildir=/var/mailbox/dcas.cn/lin/Maildir/, quota=<null>,

options=<null>

Jul 28 12:12:29 mailserver pop3d: LOGIN, user=lin@dcas.cn, ip=[196.196.0.150]

Jul 28 12:12:29 mailserver pop3d: LOGOUT, user=lin@dcas.cn, ip=[196.196.0.150], top=0, retr=0, rcvd=12, sent=39, time=

0

Jul 28 12:12:43 mailserver postfix/smtpd[4426]: connect from unknown[196.196.0.150]

Jul 28 12:12:43 mailserver authdaemond: received auth request, service=smtp, authtype=login

Jul 28 12:12:43 mailserver authdaemond: authmysql: trying this module

Jul 28 12:12:43 mailserver authdaemond: SQL query: SELECT username, password, "", '1001', '1001', concat('/var/mailbox

/',homedir), concat('/var/mailbox/',maildir), "", name, "" FROM mailbox WHERE username = "lin@dcas.cn"

Jul 28 12:12:43 mailserver authdaemond: password matches successfully

Jul 28 12:12:43 mailserver authdaemond: authmysql: sysusername=<null>, sysuserid=1001, sysgroupid=1001, homedir=/var/m

ailbox/dcas.cn/lin, address=lin@dcas.cn, fullname=<null>, maildir=/var/mailbox/dcas.cn/lin/Maildir/, quota=<null>, opt

ions=<null>

Jul 28 12:12:43 mailserver authdaemond: Authenticated: sysusername=<null>, sysuserid=1001, sysgroupid=1001, homedir=/v

ar/mailbox/dcas.cn/lin, address=lin@dcas.cn, fullname=<null>, maildir=/var/mailbox/dcas.cn/lin/Maildir/, quota=<null>,

options=<null>

Jul 28 12:12:43 mailserver postfix/smtpd[4426]: NOQUEUE: reject: RCPT from unknown[196.196.0.150]: 550 5.1.1 <lin@dcas

.cn>: Recipient address rejected: User unknown in virtual alias table; from=<lin@dcas.cn> to=<lin@dcas.cn> proto=ESMTP

helo=<14e6780851cb4a5>

Jul 28 12:12:43 mailserver postfix/smtpd[4426]: disconnect from unknown[196.196.0.150]

[ 本帖最后由 bigbigsh 于 2008-7-28 10:49 编辑 ]


zuiaifly 回复于:2008-07-28 12:13:33

名称就不写了,网址里可以看出来

几个容易找的就不写了

ftp://ftp.csie.ncu.edu.tw/FreeBSD/ports/distfiles/extman-0.2.2.tar.gz

ftp://ftp.int.ru/.1/FreeBSD/distfiles/extmail-1.0.2.tar.gz

ftp://ftp.int.ru/.1/FreeBSD/distfiles/amavisd-new-2.5.2.tar.gz

ftp://ftp.freebsdchina.org/pub/OpenBSD/distfiles/maildrop-2.0.4.tar.bz2

ftp://ftp.in2p3.fr/pub/FreeBSD/ports/ia64/packages-6-stable/ipv6/courier-imap-4.1.3,1.tbz

ftp://ftp.esat.net/mirrors/.3/ftp.netbsd.org/pub/NetBSD/packages/current-packages/NetBSD/x86_64/4.0_2007Q4/mail/spamassassin-3.2.3.tgz

ftp://ftp.in2p3.fr/pub/FreeBSD/ports/ia64/packages-6-stable/mail/courier-authlib-0.59.3.tbz

http://apache.mirror.phpchina.com/spamassassin/source/Mail-SpamAssassin-3.2.5.tar.gz

ftp://ftp.iem.ac.ru/anti/clamav/clamav-0.91.2.tar.gz

http://www.openssl.org/source/openssl-0.9.8e.tar.gz

ftp://ftp.in2p3.fr/pub/FreeBSD/ports/ia64/packages-6-stable/ipv6/courier-imap-4.1.3,1.tbz

ftp://ftp.esat.net/mirrors/.3/ftp.netbsd.org/pub/NetBSD/packages/current-packages/NetBSD/x86_64/4.0_2007Q4/mail/spamassassin-3.2.3.tgz

ftp://ftp.in2p3.fr/pub/FreeBSD/ports/ia64/packages-6-stable/mail/courier-authlib-0.59.3.tbz

ftp://ftp.iem.ac.ru/anti/clamav/clamav-0.91.2.tar.gz

http://www.openssl.org/source/openssl-0.9.8e.tar.gz

http://apache.mirror.phpchina.com/httpd/httpd-2.2.9.tar.gz

http://download-east.oracle.com/berkeley-db/db-4.5.20.tar.gz

http://sunsite.informatik.rwth-aachen.de/mysql/Downloads/MySQL-5.0/mysql-5.0.45.tar.gz

http://down1.chinaunix.net/distfiles/cyrus-sasl-2.1.22.tar.gz

http://postfix.imar.ro/postfix-release/official/postfix-2.4.5.tar.gz


bigbigsh 回复于:2008-07-28 12:50:10


自己顶一下。。。那位朋友帮我看看


zenglingping 回复于:2008-07-28 15:23:31


<lingping@dcas.cn>: host 222.66.101.226[222.66.101.226] said: 550 5.1.1

<lingping@dcas.cn>: Recipient address rejected: User unknown in local

recipient table (in reply to RCPT TO command)




你的配置有问题,可以贴出来大家检查看看。。。



到目前为止,你安装了哪些组件,有没有安装maildrop或防病毒?从日志上看,似乎还没有安装maildrop.


sunboyu 回复于:2008-07-28 16:17:05


这个结构非常得不错,学习一下


bigbigsh 回复于:2008-07-28 17:14:49


回zenglingping

我安装到maildrop ,防拉级还有防病毒我没装, 还有使用Extman的图形日志我没装.

我把文件发出来。。帮我看看



我今天把目录删除还是老样子





[root@mailserver ~]# cat /var/log/messages

Jul 28 18:51:27 mailserver shutdown: shutting down for system reboot

Jul 28 18:51:27 mailserver init: Switching to runlevel: 6

Jul 28 18:51:29 mailserver haldaemon: haldaemon -TERM succeeded

Jul 28 18:51:29 mailserver messagebus: messagebus -TERM succeeded

Jul 28 18:51:29 mailserver atd: atd shutdown succeeded

Jul 28 18:51:29 mailserver cups: cupsd shutdown succeeded

Jul 28 18:51:29 mailserver xfs[2915]: terminating

Jul 28 18:51:29 mailserver xfs: xfs shutdown succeeded

Jul 28 18:51:30 mailserver gpm: gpm shutdown succeeded

Jul 28 18:51:30 mailserver sshd: sshd shutdown succeeded

Jul 28 18:51:30 mailserver smartd[2708]: smartd received signal 15: Terminated

Jul 28 18:51:30 mailserver smartd[2708]: smartd is exiting (exit status 0)

Jul 28 18:51:30 mailserver smartd: smartd shutdown succeeded

Jul 28 18:51:30 mailserver xinetd[2811]: Exiting...

Jul 28 18:51:30 mailserver xinetd: xinetd shutdown succeeded

Jul 28 18:51:30 mailserver acpid: acpid shutdown succeeded

Jul 28 18:51:31 mailserver crond: crond shutdown succeeded

Jul 28 18:51:31 mailserver courier-authlib: Stopping Courier authentication services:

Jul 28 18:51:31 mailserver courier-authlib: authdaemond

Jul 28 18:51:31 mailserver rc: Stopping courier-authlib: succeeded

Jul 28 18:51:31 mailserver portmap: portmap shutdown succeeded

Jul 28 18:51:31 mailserver kernel: Kernel logging (proc) stopped.

Jul 28 18:51:31 mailserver kernel: Kernel log daemon terminating.

Jul 28 18:51:32 mailserver syslog: klogd shutdown succeeded

Jul 28 18:51:32 mailserver exiting on signal 15

Jul 28 18:53:19 mailserver syslogd 1.4.1: restart.

Jul 28 18:53:19 mailserver syslog: syslogd startup succeeded

Jul 28 18:53:19 mailserver kernel: klogd 1.4.1, log source = /proc/kmsg started.

Jul 28 18:53:19 mailserver kernel: Linux version 2.6.9-67.EL (mockbuild@builder10.centos.org) (gcc version 3.4.6 20060404 (Red Hat 3.4.6-9)) #1 Fri Nov 16 12:34:13 EST 2007

Jul 28 18:53:19 mailserver kernel: BIOS-provided physical RAM map:

Jul 28 18:53:19 mailserver kernel: BIOS-e820: 0000000000000000 - 00000000000a0000 (usable)

Jul 28 18:53:19 mailserver kernel: BIOS-e820: 00000000000f0000 - 0000000000100000 (reserved)

Jul 28 18:53:19 mailserver kernel: BIOS-e820: 0000000000100000 - 000000000fff0000 (usable)

Jul 28 18:53:19 mailserver kernel: BIOS-e820: 000000000fff0000 - 000000000fff3000 (ACPI NVS)

Jul 28 18:53:19 mailserver kernel: BIOS-e820: 000000000fff3000 - 0000000010000000 (ACPI data)

Jul 28 18:53:19 mailserver kernel: BIOS-e820: 00000000ffff0000 - 0000000100000000 (reserved)

Jul 28 18:53:19 mailserver kernel: 0MB HIGHMEM available.

Jul 28 18:53:19 mailserver kernel: 255MB LOWMEM available.

Jul 28 18:53:19 mailserver kernel: Using x86 segment limits to approximate NX protection

Jul 28 18:53:19 mailserver syslog: klogd startup succeeded

Jul 28 18:53:19 mailserver kernel: zapping low mappings.

Jul 28 18:53:20 mailserver kernel: DMI not present.

Jul 28 18:53:20 mailserver irqbalance: Can't balance irqs on a uniprocessor system: failed

Jul 28 18:53:20 mailserver kernel: ACPI: PM-Timer IO Port: 0x4008

Jul 28 18:53:20 mailserver kernel: Allocating PCI resources starting at 20000000 (gap: 10000000:efff0000)

Jul 28 18:53:20 mailserver kernel: Built 1 zonelists

Jul 28 18:53:20 mailserver kernel: Kernel command line: ro root=/dev/VolGroup00/LogVol00

Jul 28 18:53:20 mailserver kernel: Local APIC disabled by BIOS -- you can enable it with "lapic"

Jul 28 18:53:20 mailserver kernel: Initializing CPU#0

Jul 28 18:53:20 mailserver kernel: CPU 0 irqstacks, hard=c0409000 soft=c0408000

Jul 28 18:53:20 mailserver kernel: PID hash table entries: 1024 (order: 10, 16384 bytes)

Jul 28 18:53:20 mailserver kernel: Detected 651.871 MHz processor.

Jul 28 18:53:20 mailserver kernel: Using pmtmr for high-res timesource

Jul 28 18:53:20 mailserver kernel: Console: colour VGA+ 80x25

Jul 28 18:53:20 mailserver kernel: Dentry cache hash table entries: 65536 (order: 6, 262144 bytes)

Jul 28 18:53:20 mailserver kernel: Inode-cache hash table entries: 32768 (order: 5, 131072 bytes)

Jul 28 18:53:20 mailserver kernel: Memory: 254212k/262080k available (2169k kernel code, 7192k reserved, 725k data, 172k init, 0k highmem)

Jul 28 18:53:20 mailserver kernel: Calibrating delay using timer specific routine.. 1304.13 BogoMIPS (lpj=652068)

Jul 28 18:53:20 mailserver portmap: portmap startup succeeded

Jul 28 18:53:20 mailserver kernel: Security Scaffold v1.0.0 initialized

Jul 28 18:53:20 mailserver kernel: SELinux: Initializing.

Jul 28 18:53:20 mailserver kernel: There is already a security framework initialized, register_security failed.

Jul 28 18:53:20 mailserver courier-authlib: Starting Courier authentication services:

Jul 28 18:53:20 mailserver kernel: selinux_register_security: Registering secondary module capability

Jul 28 18:53:20 mailserver kernel: Capability LSM initialized as secondary

Jul 28 18:53:20 mailserver kernel: Mount-cache hash table entries: 512 (order: 0, 4096 bytes)

Jul 28 18:53:20 mailserver kernel: CPU: L1 I Cache: 64K (64 bytes/line), D cache 64K (64 bytes/line)

Jul 28 18:53:20 mailserver courier-authlib: authdaemond

Jul 28 18:53:20 mailserver kernel: CPU: L2 Cache: 512K (64 bytes/line)

Jul 28 18:53:21 mailserver rc: Starting courier-authlib: succeeded

Jul 28 18:53:21 mailserver kernel: Intel machine check architecture supported.

Jul 28 18:53:21 mailserver kernel: Intel machine check reporting enabled on CPU#0.

Jul 28 18:53:21 mailserver kernel: CPU: AMD Athlon(tm) Processor stepping 01

Jul 28 18:53:21 mailserver kernel: Enabling fast FPU save and restore... done.

Jul 28 18:53:21 mailserver netfs: Mounting other filesystems: succeeded

Jul 28 18:53:21 mailserver kernel: Checking 'hlt' instruction... OK.

Jul 28 18:53:21 mailserver kernel: ACPI: IRQ5 SCI: Level Trigger.

Jul 28 18:53:21 mailserver kernel: checking if image is initramfs... it is

Jul 28 18:53:22 mailserver kernel: Freeing initrd memory: 1152k freed

Jul 28 14:52:32 mailserver rc.sysinit: -e

Jul 28 18:53:22 mailserver kernel: NET: Registered protocol family 16

Jul 28 18:52:32 mailserver date: Mon Jul 28 18:52:32 EDT 2008

Jul 28 18:53:22 mailserver smartd[2681]: smartd version 5.33 [i686-redhat-linux-gnu] Copyright (C) 2002-4 Bruce Allen

Jul 28 18:53:22 mailserver kernel: PCI: PCI BIOS revision 2.10 entry at 0xfb450, last bus=1

Jul 28 18:52:32 mailserver rc.sysinit: Setting clock (localtime): Mon Jul 28 18:52:32 EDT 2008 succeeded

Jul 28 18:53:22 mailserver smartd[2681]: Home page is http://smartmontools.sourceforge.net/

Jul 28 18:53:22 mailserver kernel: PCI: Using configuration type 1

Jul 28 18:52:36 mailserver udevsend[1493]: starting udevd daemon

Jul 28 18:53:22 mailserver smartd[2681]: Opened configuration file /etc/smartd.conf

Jul 28 18:53:22 mailserver kernel: mtrr: v2.0 (20020519)

Jul 28 18:52:36 mailserver start_udev: Starting udev: succeeded

Jul 28 18:53:22 mailserver smartd[2681]: Configuration file /etc/smartd.conf parsed.

Jul 28 18:53:22 mailserver kernel: ACPI: Subsystem revision 20040816

Jul 28 18:52:45 mailserver rc.sysinit: -e

Jul 28 18:53:22 mailserver smartd[2681]: Device: /dev/hdb, opened

Jul 28 18:53:22 mailserver kernel: ACPI: Interpreter enabled

Jul 28 18:52:46 mailserver sysctl: net.ipv4.ip_forward = 0

Jul 28 18:53:22 mailserver smartd[2681]: Device: /dev/hdb, found in smartd database.

Jul 28 18:53:22 mailserver kernel: ACPI: Using PIC for interrupt routing

Jul 28 18:52:46 mailserver sysctl: net.ipv4.conf.default.rp_filter = 1

Jul 28 18:53:23 mailserver kernel: ACPI: PCI Root Bridge [PCI0] (00:00)

Jul 28 18:53:23 mailserver smartd[2681]: Device: /dev/hdb, is SMART capable. Adding to "monitor" list.

Jul 28 18:52:46 mailserver sysctl: net.ipv4.conf.default.accept_source_route = 0

Jul 28 18:53:23 mailserver kernel: PCI: Probing PCI hardware (bus 00)

Jul 28 18:53:23 mailserver smartd[2681]: Monitoring 1 ATA and 0 SCSI devices

Jul 28 18:52:46 mailserver sysctl: kernel.sysrq = 0

Jul 28 18:53:23 mailserver smartd[2681]: Device: /dev/hdb, 1 Currently unreadable (pending) sectors

Jul 28 18:52:46 mailserver sysctl: kernel.core_uses_pid = 1

Jul 28 18:53:23 mailserver kernel: ACPI: PCI Interrupt Link [LNKA] (IRQs 1 3 4 5 6 7 *10 11 12 14 15)

Jul 28 18:53:23 mailserver smartd[2681]: Sending warning via mail to root ...

Jul 28 18:52:46 mailserver rc.sysinit: Configuring kernel parameters: succeeded

Jul 28 18:53:23 mailserver kernel: ACPI: PCI Interrupt Link [LNKB] (IRQs 1 3 4 5 6 7 10 11 12 14 15) *0, disabled.

Jul 28 18:52:46 mailserver rc.sysinit: Setting hostname mailserver: succeeded

Jul 28 18:53:23 mailserver kernel: ACPI: PCI Interrupt Link [LNKC] (IRQs 1 3 4 5 6 7 10 11 *12 14 15)

Jul 28 18:52:46 mailserver fsck: /dev/VolGroup00/LogVol00: clean, 110518/3670016 files, 738435/7331840 blocks

Jul 28 18:53:23 mailserver kernel: ACPI: PCI Interrupt Link [LNKD] (IRQs 1 3 4 5 6 7 10 *11 12 14 15)

Jul 28 18:52:46 mailserver rc.sysinit: Checking root filesystem succeeded

Jul 28 18:53:23 mailserver kernel: Linux Plug and Play Support v0.97 (c) Adam Belay

Jul 28 18:52:46 mailserver rc.sysinit: Remounting root filesystem in read-write mode: succeeded

Jul 28 18:53:24 mailserver kernel: usbcore: registered new driver usbfs

Jul 28 18:52:47 mailserver lvm.static: 2 logical volume(s) in volume group VolGroup00 now active

Jul 28 18:53:24 mailserver kernel: usbcore: registered new driver hub

Jul 28 18:52:47 mailserver rc.sysinit: Setting up Logical Volume Management: succeeded

Jul 28 18:53:24 mailserver kernel: PCI: Using ACPI for IRQ routing

Jul 28 18:52:47 mailserver fsck: /boot: clean, 35/26104 files, 12694/104388 blocks

Jul 28 18:53:24 mailserver kernel: ACPI: PCI Interrupt Link [LNKD] enabled at IRQ 11

Jul 28 18:52:47 mailserver rc.sysinit: Checking filesystems succeeded

Jul 28 18:53:24 mailserver kernel: ACPI: PCI Interrupt 0000:00:07.2[D] -> GSI 11 (level, low) -> IRQ 11

Jul 28 18:52:48 mailserver rc.sysinit: Mounting local filesystems: succeeded

Jul 28 18:53:24 mailserver kernel: ACPI: PCI Interrupt Link [LNKC] enabled at IRQ 12

Jul 28 18:52:48 mailserver rc.sysinit: Enabling local filesystem quotas: succeeded

Jul 28 18:53:25 mailserver kernel: ACPI: PCI Interrupt 0000:00:07.5[C] -> GSI 12 (level, low) -> IRQ 12

Jul 28 18:52:48 mailserver rc.sysinit: Enabling swap space: succeeded

Jul 28 18:53:25 mailserver kernel: ACPI: PCI Interrupt Link [LNKA] enabled at IRQ 10

Jul 28 18:53:25 mailserver smartd[2681]: Warning via mail to root: successful

Jul 28 18:52:49 mailserver init: Entering runlevel: 3

Jul 28 18:53:25 mailserver kernel: ACPI: PCI Interrupt 0000:00:08.0[A] -> GSI 10 (level, low) -> IRQ 10

Jul 28 18:53:25 mailserver smartd[2697]: smartd has fork()ed into background mode. New PID=2697.

Jul 28 18:53:25 mailserver smartd: smartd startup succeeded

Jul 28 18:52:50 mailserver vgchange: 2 logical volume(s) in volume group "VolGroup00" monitored

Jul 28 18:53:25 mailserver kernel: ACPI: PCI Interrupt 0000:00:0b.0[A] -> GSI 11 (level, low) -> IRQ 11

Jul 28 18:52:50 mailserver lvm2-monitor: Starting monitoring for VG VolGroup00: succeeded

Jul 28 18:53:25 mailserver kernel: ACPI: PCI Interrupt 0000:01:00.0[A] -> GSI 10 (level, low) -> IRQ 10

Jul 28 18:53:09 mailserver kudzu: succeeded

Jul 28 18:53:25 mailserver kernel: apm: BIOS version 1.2 Flags 0x07 (Driver version 1.16ac)

Jul 28 18:53:09 mailserver rc: Starting openibd: succeeded

Jul 28 18:53:25 mailserver kernel: apm: overridden by ACPI.

Jul 28 18:53:09 mailserver rc: Starting pcmcia: succeeded

Jul 28 18:53:25 mailserver kernel: audit: initializing netlink socket (disabled)

Jul 28 18:53:09 mailserver sysctl: net.ipv4.ip_forward = 0

Jul 28 18:53:25 mailserver kernel: audit(1217271142.243:1): initialized

Jul 28 18:53:09 mailserver sysctl: net.ipv4.conf.default.rp_filter = 1

Jul 28 18:53:25 mailserver acpid: acpid startup succeeded

Jul 28 18:53:25 mailserver kernel: Total HugeTLB memory allocated, 0

Jul 28 18:53:09 mailserver sysctl: net.ipv4.conf.default.accept_source_route = 0

Jul 28 18:53:25 mailserver kernel: VFS: Disk quotas dquot_6.5.1

Jul 28 18:53:09 mailserver sysctl: kernel.sysrq = 0

Jul 28 18:53:25 mailserver kernel: Dquot-cache hash table entries: 1024 (order 0, 4096 bytes)

Jul 28 18:53:09 mailserver sysctl: kernel.core_uses_pid = 1

Jul 28 18:53:09 mailserver network: Setting network parameters: succeeded

Jul 28 18:53:26 mailserver kernel: Initializing Cryptographic API

Jul 28 18:53:10 mailserver network: Bringing up loopback interface: succeeded

Jul 28 18:53:26 mailserver kernel: ksign: Installing public key data

Jul 28 18:53:15 mailserver network: Bringing up interface eth0: succeeded

Jul 28 18:53:26 mailserver kernel: Loading keyring

Jul 28 18:53:19 mailserver network: Bringing up interface eth1: succeeded

Jul 28 18:53:27 mailserver kernel: - Added public key CF3BB4B0ED2ED3CE

Jul 28 18:53:27 mailserver kernel: - User ID: CentOS (Kernel Module GPG key)

Jul 28 18:53:27 mailserver kernel: PCI: Disabling Via external APIC routing

Jul 28 18:53:27 mailserver kernel: pci_hotplug: PCI Hot Plug PCI Core version: 0.5

Jul 28 18:53:27 mailserver kernel: ACPI: Processor [CPU0] (supports C1 C2, 2 throttling states)

Jul 28 18:53:27 mailserver kernel: Real Time Clock Driver v1.12

Jul 28 18:53:27 mailserver kernel: Linux agpgart interface v0.100 (c) Dave Jones

Jul 28 18:53:27 mailserver kernel: agpgart: Detected VIA KX133 chipset

Jul 28 18:53:27 mailserver kernel: agpgart: Maximum main memory to use for agp memory: 203M

Jul 28 18:53:27 mailserver kernel: agpgart: AGP aperture is 64M @ 0xd0000000

Jul 28 18:53:27 mailserver kernel: serio: i8042 AUX port at 0x60,0x64 irq 12

Jul 28 18:53:28 mailserver kernel: serio: i8042 KBD port at 0x60,0x64 irq 1

Jul 28 18:53:28 mailserver kernel: Serial: 8250/16550 driver $Revision: 1.90 $ 68 ports, IRQ sharing enabled

Jul 28 18:53:28 mailserver kernel: ttyS0 at I/O 0x3f8 (irq = 4) is a 16550A

Jul 28 18:53:28 mailserver kernel: ttyS1 at I/O 0x2f8 (irq = 3) is a 16550A

Jul 28 18:53:28 mailserver kernel: RAMDISK driver initialized: 16 RAM disks of 16384K size 1024 blocksize

Jul 28 18:53:28 mailserver kernel: Uniform Multi-Platform E-IDE driver Revision: 7.00alpha2

Jul 28 18:53:28 mailserver kernel: ide: Assuming 33MHz system bus speed for PIO modes; override with idebus=xx

Jul 28 18:53:29 mailserver kernel: VP_IDE: IDE controller at PCI slot 0000:00:07.1

Jul 28 18:53:29 mailserver kernel: VP_IDE: chipset revision 16

Jul 28 18:53:29 mailserver kernel: VP_IDE: not 100% native mode: will probe irqs later

Jul 28 18:53:29 mailserver kernel: VP_IDE: VIA vt82c686a (rev 22) IDE UDMA66 controller on pci0000:00:07.1

Jul 28 18:53:29 mailserver kernel: ide0: BM-DMA at 0xd000-0xd007, BIOS settings: hda:pio, hdb:DMA

Jul 28 18:53:29 mailserver cups: cupsd startup succeeded

Jul 28 18:53:29 mailserver kernel: ide1: BM-DMA at 0xd008-0xd00f, BIOS settings: hdc:pio, hdd:pio

Jul 28 18:53:29 mailserver kernel: hdb: IBM-DTLA-307030, ATA DISK drive

Jul 28 18:53:29 mailserver kernel: Using cfq io scheduler

Jul 28 18:53:29 mailserver kernel: ide0 at 0x1f0-0x1f7,0x3f6 on irq 14

Jul 28 18:53:29 mailserver kernel: hdb: max request size: 128KiB

Jul 28 18:53:29 mailserver kernel: hdb: 60036480 sectors (30738 MB) w/1916KiB Cache, CHS=59560/16/63, UDMA(66)

Jul 28 18:53:29 mailserver kernel: hdb: hdb1 hdb2

Jul 28 18:53:29 mailserver kernel: ide-floppy driver 0.99.newide

Jul 28 18:53:29 mailserver kernel: usbcore: registered new driver hiddev

Jul 28 18:53:29 mailserver kernel: usbcore: registered new driver usbhid

Jul 28 18:53:29 mailserver kernel: drivers/usb/input/hid-core.c: v2.0:USB HID core driver

Jul 28 18:53:29 mailserver kernel: mice: PS/2 mouse device common for all mice

Jul 28 18:53:29 mailserver kernel: input: AT Translated Set 2 keyboard on isa0060/serio0

Jul 28 18:53:29 mailserver kernel: md: md driver 0.90.0 MAX_MD_DEVS=256, MD_SB_DISKS=27

Jul 28 18:53:29 mailserver kernel: NET: Registered protocol family 2

Jul 28 18:53:29 mailserver kernel: IP route cache hash table entries: 4096 (order: 2, 16384 bytes)

Jul 28 18:53:29 mailserver kernel: TCP established hash table entries: 16384 (order: 5, 131072 bytes)

Jul 28 18:53:29 mailserver kernel: TCP bind hash table entries: 16384 (order: 6, 458752 bytes)

Jul 28 18:53:29 mailserver kernel: TCP: Hash tables configured (established 16384 bind 16384)

Jul 28 18:53:29 mailserver kernel: Initializing IPsec netlink socket

Jul 28 18:53:29 mailserver kernel: NET: Registered protocol family 1

Jul 28 18:53:29 mailserver kernel: NET: Registered protocol family 17

Jul 28 18:53:29 mailserver kernel: ACPI wakeup devices:

Jul 28 18:53:29 mailserver kernel: PWRB PCI0 USB0 USB1 UAR1 UAR2 LPT1

Jul 28 18:53:29 mailserver kernel: ACPI: (supports S0 S1 S3 S4 S4bios S5)

Jul 28 18:53:29 mailserver kernel: Freeing unused kernel memory: 172k freed

Jul 28 18:53:29 mailserver kernel: device-mapper: 4.5.5-ioctl (2006-12-01) initialised: dm-devel@redhat.com

[ 本帖最后由 bigbigsh 于 2008-7-28 17:28 编辑 ]

配置文件.rar


bigbigsh 回复于:2008-07-28 17:28:53


Jul 28 18:53:29 mailserver kernel: kjournald starting. Commit interval 5 seconds

Jul 28 18:53:29 mailserver kernel: EXT3-fs: mounted filesystem with ordered data mode.

Jul 28 18:53:30 mailserver sshd: succeeded

Jul 28 18:53:30 mailserver kernel: inserting floppy driver for 2.6.9-67.EL

Jul 28 18:53:30 mailserver kernel: FDC 0 is a post-1991 82077

Jul 28 18:53:30 mailserver kernel: 8139too Fast Ethernet driver 0.9.27

Jul 28 18:53:30 mailserver kernel: ACPI: PCI Interrupt 0000:00:08.0[A] -> GSI 10 (level, low) -> IRQ 10

Jul 28 18:53:30 mailserver kernel: eth0: RealTek RTL8139 at 0xe800, 00:e0:4c:e0:6d:c6, IRQ 10

Jul 28 18:53:30 mailserver kernel: ACPI: PCI Interrupt 0000:00:0b.0[A] -> GSI 11 (level, low) -> IRQ 11

Jul 28 18:53:30 mailserver kernel: eth1: RealTek RTL8139 at 0xec00, 00:e0:4d:d6:86:46, IRQ 11

Jul 28 18:53:30 mailserver kernel: ACPI: PCI Interrupt 0000:00:07.5[C] -> GSI 12 (level, low) -> IRQ 12

Jul 28 18:53:30 mailserver kernel: parport0: PC-style at 0x378 [PCSPP,EPP]

Jul 28 18:53:30 mailserver kernel: parport_pc: Via 686A parallel port: io=0x378

Jul 28 18:53:30 mailserver kernel: USB Universal Host Controller Interface driver v2.2

Jul 28 18:53:30 mailserver kernel: ACPI: PCI Interrupt 0000:00:07.2[D] -> GSI 11 (level, low) -> IRQ 11

Jul 28 18:53:30 mailserver kernel: uhci_hcd 0000:00:07.2: UHCI Host Controller

Jul 28 18:53:30 mailserver kernel: uhci_hcd 0000:00:07.2: irq 11, io base 0000d400

Jul 28 18:53:30 mailserver kernel: uhci_hcd 0000:00:07.2: new USB bus registered, assigned bus number 1

Jul 28 18:53:30 mailserver kernel: hub 1-0:1.0: USB hub found

Jul 28 18:53:30 mailserver kernel: hub 1-0:1.0: 2 ports detected

Jul 28 18:53:30 mailserver kernel: md: Autodetecting RAID arrays.

Jul 28 18:53:30 mailserver kernel: md: autorun ...

Jul 28 18:53:30 mailserver kernel: md: ... autorun DONE.

Jul 28 18:53:30 mailserver kernel: ACPI: Power Button (FF) [PWRF]

Jul 28 18:53:30 mailserver kernel: EXT3 FS on dm-0, internal journal

Jul 28 18:53:30 mailserver kernel: loop: loaded (max 8 devices)

Jul 28 18:53:30 mailserver kernel: kjournald starting. Commit interval 5 seconds

Jul 28 18:53:31 mailserver kernel: EXT3 FS on hdb1, internal journal

Jul 28 18:53:31 mailserver kernel: EXT3-fs: mounted filesystem with ordered data mode.

Jul 28 18:53:31 mailserver kernel: Adding 524280k swap on /dev/VolGroup00/LogVol01. Priority:-1 extents:1

Jul 28 18:53:31 mailserver kernel: ip_tables: (C) 2000-2002 Netfilter core team

Jul 28 18:53:31 mailserver kernel: ip_tables: (C) 2000-2002 Netfilter core team

Jul 28 18:53:31 mailserver kernel: eth0: link up, 100Mbps, full-duplex, lpa 0x45E1

Jul 28 18:53:31 mailserver kernel: ip_tables: (C) 2000-2002 Netfilter core team

Jul 28 18:53:31 mailserver kernel: eth1: link down

Jul 28 18:53:31 mailserver kernel: lp0: using parport0 (polling).

Jul 28 18:53:31 mailserver kernel: lp0: console ready

Jul 28 18:53:31 mailserver kernel: NET: Registered protocol family 10

Jul 28 18:53:31 mailserver kernel: Disabled Privacy Extensions on device c038a3a0(lo)

Jul 28 18:53:31 mailserver kernel: ADDRCONF(NETDEV_UP): eth1: link is not ready

Jul 28 18:53:31 mailserver kernel: IPv6 over IPv4 tunneling driver

Jul 28 18:53:31 mailserver xinetd: xinetd startup succeeded

Jul 28 18:53:31 mailserver xinetd[2800]: xinetd Version 2.3.13 started with libwrap loadavg options compiled in.

Jul 28 18:53:31 mailserver xinetd[2800]: Started working: 0 available services

Jul 28 18:53:33 mailserver courier-imapd: Starting Courier-IMAP server:

Jul 28 18:53:34 mailserver courier-imapd: pop3

Jul 28 18:53:34 mailserver courier-imapd:

Jul 28 18:53:34 mailserver rc: Starting courier-imapd: succeeded

Jul 28 18:53:34 mailserver gpm[2873]: *** info [startup.c(95)]:

Jul 28 18:53:34 mailserver gpm[2873]: Started gpm successfully. Entered daemon mode.

Jul 28 18:53:34 mailserver gpm: gpm startup succeeded

Jul 28 18:53:34 mailserver crond: crond startup succeeded

Jul 28 18:53:36 mailserver xfs: xfs startup succeeded

Jul 28 18:53:36 mailserver anacron: anacron startup succeeded

Jul 28 18:53:37 mailserver atd: atd startup succeeded

Jul 28 18:53:37 mailserver xfs[2900]: ignoring font path element /usr/X11R6/lib/X11/fonts/100dpi:unscaled (unreadable)

Jul 28 18:53:37 mailserver xfs[2900]: ignoring font path element /usr/share/fonts/default/Type1 (unreadable)

Jul 28 18:53:37 mailserver messagebus: messagebus startup succeeded

Jul 28 18:53:37 mailserver haldaemon: haldaemon startup succeeded

Jul 28 18:53:38 mailserver fstab-sync[2946]: removed all generated mount points

Jul 28 18:53:58 mailserver sshd(pam_unix)[2995]: session opened for user root by (uid=0)

Jul 28 18:54:48 mailserver saslauthd[3034]: detach_tty : master pid is: 3034

Jul 28 18:54:48 mailserver saslauthd[3034]: ipc_init : listening on socket: /var/state/saslauthd/mux

Jul 28 18:54:49 mailserver saslauthd[3040]: detach_tty : could not lock pid file /var/state/saslauthd/saslauthd.pid: Resource temporarily unavailable

Jul 28 18:54:49 mailserver saslauthd[3039]: detach_tty : Cannot start saslauthd

Jul 28 18:54:49 mailserver saslauthd[3039]: detach_tty : Another instance of saslauthd is currently running

Jul 28 18:55:54 mailserver postfix/smtpd[3114]: sql_select option missing

Jul 28 18:55:54 mailserver postfix/smtpd[3114]: auxpropfunc error no mechanism available


bigbigsh 回复于:2008-07-28 17:29:57


[root@mailserver ~]# cat /var/log/maillog

Jul 28 18:51:31 mailserver authdaemond: stopping authdaemond children

Jul 28 18:53:21 mailserver authdaemond: modules="authmysql", daemons=10

Jul 28 18:53:21 mailserver authdaemond: Installing libauthmysql

Jul 28 18:53:22 mailserver authdaemond: Installation complete: authmysql

Jul 28 18:54:04 mailserver pop3d: Connection, ip=[196.196.0.150]

Jul 28 18:54:04 mailserver pop3d: LOGIN, user=lin@dcas.cn, ip=[196.196.0.150]

Jul 28 18:54:04 mailserver pop3d: LOGOUT, user=lin@dcas.cn, ip=[196.196.0.150], top=0, retr=0, rcvd=12, sent=39, time=0

Jul 28 18:54:05 mailserver pop3d: Connection, ip=[196.196.0.150]

Jul 28 18:54:05 mailserver pop3d: LOGIN, user=lin@dcas.cn, ip=[196.196.0.150]

Jul 28 18:54:05 mailserver pop3d: LOGOUT, user=lin@dcas.cn, ip=[196.196.0.150], top=0, retr=0, rcvd=12, sent=39, time=0

Jul 28 18:54:12 mailserver pop3d: Connection, ip=[196.196.0.150]

Jul 28 18:54:12 mailserver pop3d: LOGIN, user=lin@dcas.cn, ip=[196.196.0.150]

Jul 28 18:54:12 mailserver pop3d: LOGOUT, user=lin@dcas.cn, ip=[196.196.0.150], top=0, retr=0, rcvd=12, sent=39, time=0

Jul 28 18:55:11 mailserver postfix/postfix-script[3086]: starting the Postfix mail system

Jul 28 18:55:11 mailserver postfix/master[3087]: daemon started -- version 2.5.2, configuration /etc/postfix

Jul 28 18:55:11 mailserver postfix/pickup[3089]: 75AD01F81CE: uid=0 from=<root>

Jul 28 18:55:11 mailserver postfix/cleanup[3090]: 75AD01F81CE: message-id=<20080728225511.75AD01F81CE@mail.dcas.cn>

Jul 28 18:55:11 mailserver postfix/qmgr[3088]: 75AD01F81CE: from=<root@dcas.cn>, size=783, nrcpt=1 (queue active)

Jul 28 18:55:11 mailserver postfix/trivial-rewrite[3091]: warning: do not list domain dcas.cn in BOTH mydestination and virtual_mailbox_domains

Jul 28 18:55:11 mailserver postfix/local[3094]: warning: dict_nis_init: NIS domain name not set - NIS lookups disabled

Jul 28 18:55:11 mailserver postfix/local[3094]: 75AD01F81CE: to=<root@dcas.cn>, orig_to=<root>, relay=local, delay=107, delays=107/0.21/0/0.03, dsn=2.0.0, status=sent (delivered to mailbox)

Jul 28 18:55:11 mailserver postfix/qmgr[3088]: 75AD01F81CE: removed

Jul 28 18:55:43 mailserver pop3d: Connection, ip=[196.196.0.150]

Jul 28 18:55:43 mailserver pop3d: LOGIN, user=lin@dcas.cn, ip=[196.196.0.150]

Jul 28 18:55:43 mailserver pop3d: LOGOUT, user=lin@dcas.cn, ip=[196.196.0.150], top=0, retr=0, rcvd=12, sent=39, time=0

Jul 28 18:55:54 mailserver postfix/smtpd[3114]: warning: dict_nis_init: NIS domain name not set - NIS lookups disabled

Jul 28 18:55:54 mailserver postfix/smtpd[3114]: connect from unknown[196.196.0.150]

Jul 28 18:55:54 mailserver postfix/trivial-rewrite[3117]: warning: do not list domain dcas.cn in BOTH mydestination and virtual_mailbox_domains

Jul 28 18:55:55 mailserver postfix/smtpd[3114]: NOQUEUE: reject: RCPT from unknown[196.196.0.150]: 550 5.1.1 <lin@dcas.cn>: Recipient address rejected: User unknown in local recipient table; from=<lin@dcas.cn> to=<lin@dcas.cn> proto=ESMTP helo=<14e6780851cb4a5>

Jul 28 18:55:55 mailserver postfix/smtpd[3114]: disconnect from unknown[196.196.0.150]

Jul 28 18:55:57 mailserver postfix/smtpd[3114]: connect from unknown[196.196.0.150]

Jul 28 18:55:57 mailserver postfix/smtpd[3114]: NOQUEUE: reject: RCPT from unknown[196.196.0.150]: 550 5.1.1 <lin@dcas.cn>: Recipient address rejected: User unknown in local recipient table; from=<lin@dcas.cn> to=<lin@dcas.cn> proto=ESMTP helo=<14e6780851cb4a5>

Jul 28 18:55:57 mailserver postfix/smtpd[3114]: disconnect from unknown[196.196.0.150]

Jul 28 18:55:57 mailserver pop3d: Connection, ip=[196.196.0.150]

Jul 28 18:55:57 mailserver pop3d: LOGIN, user=lin@dcas.cn, ip=[196.196.0.150]

Jul 28 18:55:57 mailserver pop3d: LOGOUT, user=lin@dcas.cn, ip=[196.196.0.150], top=0, retr=0, rcvd=12, sent=39, time=0

Jul 28 18:57:29 mailserver postfix/smtpd[3114]: connect from unknown[222.66.101.226]

Jul 28 18:57:35 mailserver postfix/smtpd[3114]: NOQUEUE: reject: RCPT from unknown[222.66.101.226]: 550 5.1.1 <lin@dcas.cn>: Recipient address rejected: User unknown in local recipient table; from=<499387551@qq.com> to=<lin@dcas.cn> proto=SMTP helo=<smtpbg27.qq.com>

Jul 28 18:57:35 mailserver postfix/smtpd[3114]: disconnect from unknown[222.66.101.226]

[root@mailserver ~]#

zenglingping 回复于:2008-07-28 18:00:07

请运行:

#postconf -n >/etc/postfix/main.cf.new

#mv /etc/postfix/main.cf /etc/postfix/main.cf.bak

#mv /etc/postfix/main.cf.new /etc/postfix/main.cf

方便排错,另外,请将authmysqlrc的配置文件给出看看。。。

bigbigsh 回复于:2008-07-28 19:42:41

谢谢zenglingping一直的帮忙..我刚刚下班没及时看到信息~~

如果方便的话加一下你QQ交个朋友

QQ:499387551

[ 本帖最后由 bigbigsh 于 2008-7-28 19:45 编辑 ]

authmysqlrc.rar

zenglingping 回复于:2008-07-29 10:37:19

引用:原帖由 bigbigsh 于 2008-7-28 19:42 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=8933475&ptid=987344

谢谢zenglingping一直的帮忙..我刚刚下班没及时看到信息~~

如果方便的话加一下你QQ交个朋友

QQ:499387551

你的虚拟域名与本地域名(hostname)是否相同?

bigbigsh 回复于:2008-07-29 11:42:03

[root@mailserver log]# cat maillog

Jul 29 13:06:46 mailserver postfix/smtpd[4817]: fatal: open dictionary: expecting "type:name" form instead of "(i.e."

Jul 29 13:06:47 mailserver postfix/master[4803]: warning: process /usr/local/postfix/libexec/smtpd pid 4817 exit status 1

Jul 29 13:06:47 mailserver postfix/master[4803]: warning: /usr/local/postfix/libexec/smtpd: bad command startup -- throttling

Jul 29 13:07:47 mailserver postfix/smtpd[4828]: fatal: open dictionary: expecting "type:name" form instead of "(i.e."

Jul 29 13:07:48 mailserver postfix/master[4803]: warning: process /usr/local/postfix/libexec/smtpd pid 4828 exit status 1

Jul 29 13:07:48 mailserver postfix/master[4803]: warning: /usr/local/postfix/libexec/smtpd: bad command startup -- throttling

Jul 29 13:08:48 mailserver postfix/smtpd[4829]: fatal: open dictionary: expecting "type:name" form instead of "(i.e."

Jul 29 13:08:49 mailserver postfix/master[4803]: warning: process /usr/local/postfix/libexec/smtpd pid 4829 exit status 1

Jul 29 13:08:49 mailserver postfix/master[4803]: warning: /usr/local/postfix/libexec/smtpd: bad command startup -- throttling

Jul 29 13:09:49 mailserver postfix/smtpd[4830]: fatal: open dictionary: expecting "type:name" form instead of "(i.e."

Jul 29 13:09:50 mailserver postfix/master[4803]: warning: process /usr/local/postfix/libexec/smtpd pid 4830 exit status 1

Jul 29 13:09:50 mailserver postfix/master[4803]: warning: /usr/local/postfix/libexec/smtpd: bad command startup -- throttling

Jul 29 13:10:45 mailserver pop3d: Connection, ip=[222.66.101.226]

Jul 29 13:10:45 mailserver pop3d: LOGIN, user=jinquan@dcas.cn, ip=[222.66.101.226]

Jul 29 13:10:45 mailserver pop3d: LOGOUT, user=jinquan@dcas.cn, ip=[222.66.101.226], top=0, retr=0, rcvd=12, sent=39, time=0

[root@mailserver log]#

bigbigsh 回复于:2008-07-29 11:45:05

如果相同是不是要注掉

abcd99 回复于:2008-07-29 15:07:08

DB-4.5.20的作用是什么

I-like 回复于:2008-07-29 16:37:51

引用:原帖由 bobo_zhshb 于 2008-3-20 16:03 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=8105893&ptid=987344

问题已经解决,原因是没有建立用户,而是使用的初始root用户,应该切换到管理用户就可以了使用root了!

我现在就是卡在这里,

在哪新建用户?mysql里?

zenglingping 回复于:2008-07-29 16:55:19

引用:原帖由 bigbigsh 于 2008-7-29 11:45 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=8937456&ptid=987344

如果相同是不是要注掉

相同的话就比较麻烦。。。我也没有找到解决的方法(我曾经为此重装),你也可以更改hostname名称及相关名称试试(包括域名,DNS等等)。

我是这样做的,

hostname:mail.domain.local

Virtual domain name:domail.com

yuanyuan025 回复于:2008-07-30 10:57:07

好东西啊

marion 回复于:2008-07-30 23:39:44

引用:……Jul 29 13:09:49 mailserver postfix/smtpd[4830]: fatal: open dictionary: expecting "type:name" form instead of "(i.e."……

指定引用文件的格式错误,比如类同如下的方式

mysql:/etc/postfix/mysql_virtual_mailbox_maps.cf

marion 回复于:2008-07-30 23:44:42

当时的目的:

1、解决依赖关系;

2、软件版本的同步;

bigbigsh 回复于:2008-07-31 00:26:16

引用:原帖由 marion 于 2008-7-30 23:39 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=8952235&ptid=987344

指定引用文件的格式错误,比如类同如下的方式

mysql:/etc/postfix/mysql_virtual_mailbox_maps.cf

########################Virtual Mailbox Settings########################

virtual_mailbox_base = /var/mailbox

virtual_mailbox_maps = mysql:/etc/postfix/mysql_virtual_mailbox_maps.cf

virtual_mailbox_domains = mysql:/etc/postfix/mysql_virtual_domains_maps.cf

virtual_alias_domains =

virtual_alias_maps = mysql:/etc/postfix/mysql_virtual_alias_maps.cf

virtual_uid_maps = static:1001

virtual_gid_maps = static:1001

virtual_transport = maildrop

maildrop_destination_recipient_limit = 1

maildrop_destination_concurrency_limit = 1

我按你的方法这样写...我没看到问题请marion 兄给我指点

marion 回复于:2008-07-31 08:09:59

你应该认真仔细的查看[font=黑体]整个[/font]配置文件,而非仅仅那一段,我指出的是类同格式的错误,而非指你列出的那个段有错误。日志中已经指出错误了,为什么不能认真排查一下。

[ 本帖最后由 marion 于 2008-7-31 08:11 编辑 ]


bigbigsh 回复于:2008-08-01 01:30:50


我还是没找到原因所在

[root@mailserver sbin]# egrep '(reject|warning|error|fatal|panic):' /var/log/mai

llog

Aug 1 02:06:18 mailserver pop3d: error: No such file or directory

Aug 1 02:06:18 mailserver pop3d: authentication error: No such file or director

y

Aug 1 02:06:27 mailserver pop3d: error: No such file or directory

Aug 1 02:06:27 mailserver pop3d: authentication error: No such file or director

y

Aug 1 02:06:32 mailserver pop3d: error: No such file or directory

Aug 1 02:06:32 mailserver pop3d: authentication error: No such file or director

y

Aug 1 02:09:27 mailserver pop3d: error: No such file or directory

Aug 1 02:09:27 mailserver pop3d: authentication error: No such file or director

y

Aug 1 02:10:12 mailserver pop3d: error: No such file or directory

Aug 1 02:10:12 mailserver pop3d: authentication error: No such file or director

y

Aug 1 02:13:11 mailserver pop3d: error: No such file or directory

Aug 1 02:13:11 mailserver pop3d: authentication error: No such file or director

y

Aug 1 02:36:34 mailserver pop3d: error: No such file or directory

Aug 1 02:36:34 mailserver pop3d: authentication error: No such file or director

y

Aug 1 02:54:13 mailserver postfix/smtpd[3120]: warning: dict_nis_init: NIS doma

in name not set - NIS lookups disabled

Aug 1 02:54:33 mailserver postfix/smtpd[3120]: NOQUEUE: reject: RCPT from unkno

wn[222.66.101.226]: 450 4.1.8 <girodelmondo@promozioni.postepay.it>: Sender addr

ess rejected: Domain not found; from=<girodelmondo@promozioni.postepay.it> to=<c

irce@dcas.cn> proto=ESMTP helo=<mail.ht-store.com>

[root@mailserver sbin]#

我把/var/mailbox给删除了..现在maillbox不能生成域目录..什么办

ujjidt 回复于:2008-08-01 09:37:06

真的很佩服楼主,此贴楼主能维护到现在真不容易!

 我按照楼主的第一贴的方式安装了相关的软件包,前面也出了不少问题,但也都Google解决了,现在已经安装到extmail和Extman了。当我打开Extmail输入你提供的默认用户名和密码登录报错,点免费注册也报错。

报如下错误“Internal Server Error

The server encountered an internal error or misconfiguration and was unable to complete your request.

Please contact the server administrator, you@example.com and inform them of the time the error occurred, and anything you might have done that may have caused the error.

More information about this error may be available in the server error log.

Apache错误信息

“[Fri Aug 01 07:19:40 2008] [notice] SIGHUP received. Attempting to restart

[Fri Aug 01 07:19:40 2008] [notice] Apache/2.2.8 (Unix) PHP/5.2.5 configured -- resuming normal operations

[Fri Aug 01 07:19:52 2008] [error] [client 58.211.x.x] /usr/bin/perl: symbol lookup error: /usr/lib/perl5/site_perl/5.8.8/i386-linux-thread-multi/auto/DBD/mysql/mysql.so: undefined symbol: mysql_init

[Fri Aug 01 07:19:52 2008] [error] [client 58.211.x.x] Premature end of script headers: signup.cgi

[Fri Aug 01 07:20:10 2008] [error] [client 58.211.x.x] /usr/bin/perl: symbol lookup error: /usr/lib/perl5/site_perl/5.8.8/i386-linux-thread-multi/auto/DBD/mysql/mysql.so: undefined symbol: mysql_init

[Fri Aug 01 07:20:10 2008] [error] [client 58.211.x.x] Premature end of script headers: signup.cgi

zenglingping 回复于:2008-08-01 11:44:06

可以重新执行extmail的sql脚本。。。

这样会重建所有数据库,另外不知你前面的问题搞得怎样。

ruochen 回复于:2008-08-01 12:01:06

引用:原帖由 ujjidt 于 2008-8-1 09:37 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=8962584&ptid=987344

真的很佩服楼主,此贴楼主能维护到现在真不容易!

 我按照楼主的第一贴的方式安装了相关的软件包,前面也出了不少问题,但也都Google解决了,现在已经安装到extmail和Extman了。当我打开Extmail输入你提供的默 ...

注意apache的perl模块或者cgi模块

还有suexec的问题

bigbigsh 回复于:2008-08-01 14:12:41

我搞定了..谢谢marion兄~~你让我重新认真看postfix中文说书..

错的地方是这样

smtpd_recipient_restrictions=permit_mynetworks,permit_sasl_authenticated,reject_invalid_hostname,reject_non_fqdn_hostname,reject_unknown_sender_domain,reject_non_fqdn_sender,reject_non_fqdn_recipient,reject_unknown_recipient_domain,reject_unauth_pipelining,reject_unauth_destination

=等号左右要有空格..

再次感谢marion兄的文档

[ 本帖最后由 bigbigsh 于 2008-8-1 14:15 编辑 ]

ujjidt 回复于:2008-08-01 19:09:16

感谢你的回复,你能不能再说清楚一下,检查Perl和cgi模板的。

 还有,因为我Apache编译的时候没有加suexec的,现在无法使用suexec运行,我只能在Httpd.conf修改User,Gounp了。可是我这样修改以后其它的网站跑起来就会有问题,您有什么好的解决方案吗?还有,一般重新编译安装Apache对原来的PHp、Mysql环境会有影响吗?谢谢!

bigbigsh 回复于:2008-08-01 23:41:26

引用:原帖由 ujjidt 于 2008-8-1 19:09 发表 http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=8968188&ptid=987344

感谢你的回复,你能不能再说清楚一下,检查Perl和cgi模板的。

 还有,因为我Apache编译的时候没有加suexec的,现在无法使用suexec运行,我只能在Httpd.conf修改User,Gounp了。可是我这样修改以后其它的网站跑 ...

不用suexed也可以 重新编apache没关系的.认真看楼主的文档..没问题的..我就看楼主的文档现在已经好用了~

ujjidt 回复于:2008-08-06 12:27:24

我重新编译了Apache现在已经可以使用Suexec了,但是Suexec总是报错主目录有问题,而我的Suexec定义的目录用Suexec -V查看是正常的。现在Suexec.log还是报这个错“2008-08-06 11:56:37]: command not in docroot (/var/www/extsuite/extmail/cgi/index.cgi)

[2008-08-06 11:56:37]: uid: (510/postfix) gid: (510/510) cmd: index.cgi

[2008-08-06 11:56:37]: command not in docroot (/var/www/extsuite/extmail/cgi/index.cgi)

[2008-08-06 11:56:37]: uid: (510/postfix) gid: (510/510) cmd: index.cgi

[2008-08-06 11:56:37]: command not in docroot (/var/www/extsuite/extmail/cgi/index.cgi)

[2008-08-06 11:56:37]: uid: (510/postfix) gid: (510/510) cmd: index.cgi

[2008-08-06 11:56:37]: command not in docroot (/var/www/extsuite/extmail/cgi/index.cgi)

原文链接:http://bbs.chinaunix.net/viewthread.php?tid=987344
转载请注明作者名及原文出处
回复