#设置环境变量: vi /etc/profile PATH=/usr/local/sbin:/usr/local/bin:/usr/ccs/bin:/usr/sbin:/sbin:/bin:/usr/local/mysql/bin:/usr/bin:/usr/dt/bin:/usr/openwin/bin:/usr/ucb
# cp /var/qmail/boot/home /var/qmail/rc 对rc文件进行修改,以决定投送方式: # vi /var/qmail/rc 这里要注意,这三个文件中的命令最好写在一行. =====================================rc===================================== #!/bin/sh # Using splogger to send the log through syslog. # Using dot-forward to support sendmail-style ~/.forward files. # Using qmail-local to deliver messages to ~/Mailbox by default.
################## 安装autorespond ################## gtar xzvf autorespond-2.0.2.tgz cd autorespond-2.0.2 vi Makefile 将其中的INSTALL_DIR =修改为 /var/qmail/bin make make install cp autorespond /usr/local/bin
2. maildrop gzip xxx tar xxx cd xxx ./configure --prefix=xxxx make make install
3. Time-HiRes gzip tar perl Makefile.PL make make test make install 可能遇到的问题: 1) sh: cc: 没找到 #确认 cc在你的$PATH中 默认:/usr/ucb/cc 2) cc: unrecognized option `-KPIC' #做下列操作 mv /usr/ucb/cc /usr/ucb/cc_orgi ln -s /usr/local/bin/gcc /usr/ucb/cc vi Makefile 36行 CCCDLFLAGS = -KPIC 改成 CCCDLFLAGS = -fPIC 264行 OPTIMIZE = -xO3 -xdepend 改成 OPTIMIZE = -O3
4. Berkeley DB a) 源码: cd db-4.1.25/build_unix setenv CC gcc ../dist/configure make install cp /usr/local/BerkeleyDB.4.2/include/db* /usr/local/include/ #这步不做也可以 b) pkg: pkgadd -d xxxx
5. DB_File gzip tar perl Makefile.PL make make install 可能遇到的问题: 1), 2)同Time-HiRes,但是 mv /usr/ucb/cc /usr/ucb/cc_orgi ln -s /usr/local/bin/gcc /usr/ucb/cc 没有必要做了! 3)安装Berkeley DB时如果没有做 cp ,有可能会找不到db.h 办法1 # vi config.in 修改 INCLUDE = /usr/local/BerkeleyDB/include LIB = /usr/local/BerkeleyDB/lib 的BerkeleyDB实际路径 办法2 #在 perl Makefile.PL之前 执行下列操作: DB_FILE_INCLUDE=/usr/local/BerkeleyDB.3.3/include DB_FILE_LIB=/usr/local/BerkeleyDB.3.3/lib export DB_FILE_INCLUDE DB_FILE_LIB
6. TNEF gzip tar cd ./congfiure make make install 7. qmail-scanner gzip tar cd SUIDPERL=/usr/bin/perl export SUIDPERL #suidperl 在linux下有,在solaris下没找到,只好这样了 qmail-scanner ./configure --qmail-queue-binary /var/qmail/bin/qmail-queue --admin postmaster --domain mydomain.com --notify sender,admin --local-domains mydomain.com --lang en_GB --debug yes --unzip yes --scanners clamscan --log-details no --install 修改qmail-scanner-queue.pl中的 my $clamscan_options="-r --disable-summary --max-recursion=10 --max-space=1000000";为 my $clamscan_options="-r --mbox --disable-summary --max-recursion=10 --max-space=1000000";
可能出现的问题: 1) 没打qmail-queue的patch ,赶紧打上 2)如果安装maildrop时指定 prefix了,有可能找不到reformime ,将 maildrop的 bin路径放到$PATH中 3)Error: Could not load Log module Radius/LogSYSLOG.pm: Can't locate syslog.ph in @INC(did you run h2ph?) (@INC contains…… 做下列操作: cd /usr/include find /usr -name "h2ph" /usr/perl5/5.00503/bin/h2ph * sys/* cd /usr/include /usr/perl5/bin/h2ph -r -l . vi /usr/perl5/site_perl/5.005/sun4-solaris/_h2ph_pre.ph 将第2行注释掉,即: unless (defined & { sub () { "" } } 变成 #unless (defined & { sub () { "" } }