开发学院操作系统CentOS CentOS下载生成RPM与创建maildrop rpm 阅读

CentOS下载生成RPM与创建maildrop rpm

 2010-05-27 23:10:27 来源:WEB开发网   
核心提示:经过长时间学习CentOS安装maildrop,你可能会遇到CentOS安装maildrop下载问题,CentOS下载生成RPM与创建maildrop rpm,这里将介绍CentOS安装maildrop问题的解决方法,他的缩写既是CentOS,操作系统CentOS安装maildrop,A、CentOS安装maildro

经过长时间学习CentOS安装maildrop,你可能会遇到CentOS安装maildrop下载问题,这里将介绍CentOS安装maildrop问题的解决方法,他的缩写既是CentOS。CentOS社区将Redhat的网站上的所有源代码下载下来,进行重新编译。操作系统CentOS安装maildrop。

A、CentOS安装maildrop下载生成RPM
[root@localhost postfix]# cd
[root@localhost ~]# wget http://prdownloads.sourceforge.net/courier/maildrop-2.0.4.tar.bz2
[root@localhost ~]# cp maildrop-2.0.4.tar.bz2 $SOURCE
[root@localhost ~]# tar xjf maildrop-2.0.4.tar.bz2
[root@localhost ~]# cd maildrop-2.0.4
[root@localhost maildrop-2.0.4]# cp maildrop.spec $SPEC
[root@localhost maildrop-2.0.4]# cd $SPEC

CentOS安装编辑maildrop.spec 把下面:
BuildRequires: /usr/include/fam.h gdbm-devel pcre-devel
改为:
BuildRequires:  gdbm-devel pcre-devel
把下面:
%configure --with-devel --enable-userdb --enable-maildirquota  \
--enable-syslog=1 --enable-trusted-users='root mail daemon postmaster qmaild mmdf' \
--enable-restrict-trusted=0 \
--enable-sendmail=/usr/sbin/sendmail
改为:
%configure --with-devel --enable-userdb --enable-maildirquota \
--enable-syslog=1 --enable-trusted-users='root mail daemon postmaster qmaild mmdf' \
--enable-restrict-trusted=0 --enable-sendmail=/usr/sbin/sendmail \
--enable-authlib

B、CentOS安装创建maildrop rpm
[root@localhost SPECS]# yum -y install pcre-devel
[root@localhost SPECS]# rpmbuild -bb maildrop.spec
[root@localhost SPECS]# cd $RPMS/i386
[root@localhost i386]# rpm -ivh maildrop-2.0.4-1.i386.rpm

C、CentOS安装添加虚似用户及创建目录
[root@localhost i386]# cd
[root@localhost ~]# groupadd -g 1000 vgroup
[root@localhost ~]# useradd -g 1000 -u 1000 -s /sbin/nologin -d /dev/null vuser
编辑/etc/postfix/master.cf ,加入下面的内容:
maildrop unix -   n   n   -   -   pipe
flags=DRhu user=vuser argv=/usr/bin/maildrop -d ${user}@${nexthop} ${recipient} ${user} ${extension} ${nexthop}

D、CentOS安装创建邮件存储目录
[root@localhost ~]# mkdir -p /home/data/domains/extmail.org/postmaster
[root@localhost ~]# maildirmake /home/data/domains/extmail.org/postmaster/Maildir
[root@localhost ~]# chown -R vuser:vgroup /home/data/domains/  

E、CentOS安装测试maildrop
[root@localhost ~]# echo "test" | maildrop -V 10 -d postmaster@extmail.org
maildrop: authlib: groupid=1000
maildrop: authlib: userid=1000
maildrop: authlib: logname=postmaster@extmail.org, home=/home/data/domains/extmail.org/postmaster, mail=/home/data/domains/extmail.org/postmaster/Maildir/
maildrop: Changing to /home/data/domains/extmail.org/postmaster
Message start at 0 bytes, envelope sender=postmaster@extmail.org
maildrop: Attempting .mailfilter
maildrop: Delivery complete.
出现上以信息说明authlib,maildrop 工作正常

F、CentOS安装测试pop3
[root@localhost ~]# telnet localhost 110
Trying 127.0.0.1...
Connected to localhost.localdomain (127.0.0.1).
Escape character is '^]'.
+OK Hello there.
user postmaster@extmail.org
+OK Password required.
pass extmail
+OK logged in.
list
+OK POP3 clients that break here, they violate STD53.
1 6
.
retr 1
+OK 6 octets follow.
test
.
quit
+OK Bye-bye.
Connection closed by foreign host.

G、CentOS安装测试postfix
[root@localhost ~]# perl -MMIME::Base64 -e 'print encode_base64("postmaster\@extmail.org");'
cG9zdG1hc3RlckBleHRtYWlsLm9yZw==
[root@localhost ~]# perl -MMIME::Base64 -e 'print encode_base64("extmail");'        
ZXh0bWFpbA==
[root@localhost ~]# service postfix restart (重启一下)
[root@localhost ~]# telnet localhost 25
Trying 127.0.0.1...
Connected to localhost.localdomain (127.0.0.1).
Escape character is '^]'.
220 yiyou.org ESMTP Mail System
ehlo test.com
250-mail.yiyou.org
250-PIPELINING
250-SIZE 14680064
250-VRFY
250-ETRN
250-AUTH LOGIN PLAIN
250-AUTH=LOGIN PLAIN
250-ENHANCEDSTATUSCODES
250-8BITMIME
250 DSN
auth login
334 VXNlcm5hbWU6
cG9zdG1hc3RlckBleHRtYWlsLm9yZw==
334 UGFzc3dvcmQ6
ZXh0bWFpbA==
235 2.7.0 Authentication successful
quit
221 2.0.0 Bye
Connection closed by foreign host

Tags:CentOS 下载 生成

编辑录入:爽爽 [复制链接] [打 印]
[]
  • 好
  • 好的评价 如果觉得好,就请您
      0%(0)
  • 差
  • 差的评价 如果觉得差,就请您
      0%(0)
更多精彩
    赞助商链接

    热点阅读
      焦点图片
        最新推荐
          精彩阅读