64位ContOS 5 PHP IMAP 模块安装

64位Linux PHP IMAP模块安装
.下载编译c-client.tar.Z
wget ftp://ftp.cac.washington.edu/imap/c-client.tar.Z
gunzip c-client.tar.Z
tar xvf c-client.tar
cd imap-2007e
make lr5 EXTRACFLAGS=”-fPIC”
(lr5 Redhat5及以上 CentOS5以上 Redhat4 使用 lrh)
cp -pfr c-client /usr/local/imap-c-client
mkdir /usr/local/imap-c-client/lib
cp /usr/local/imap-c-client/c-client.a /usr/local/imap-c-client/lib/libc-client.a

.编译php
./configure –prefix=/usr/local/php … –with-imap=/usr/local/imap-c-client –with-imap-ssl
make
make install

Apache Umask 问题。

近日用Joomla对文件管理有两个需求:
1 是FTP可以管理所有的文件
2 是Joomla程序本身可以管理所有的文件

所以Apache 、ftp用户需要同时对文件进行增删改。 用户权限需为umask 002
即目录:为775,普通文件为 664

在网上查Apache Umask方法,只需要运行 echo “umask 002” >> /etc/sysconfig/httpd
或是 echo “umask 002” >>/usr/local/apache2/bin/apachectl 里面去就可以解决,屡次失败。

偶然搜一下面一段话:

To set the Umask of files created by apache, either run `umask` in all your startup scripts,install mod_umask

恍然大悟,原来还还有umask的模块需要编译。于是……

To disable Apache Info show for security reasons.

I tend to forget the syntax every time, but one of the first things I do when I setup an Apache web server is add/edit these two directive in my httpd.conf:

ServerSignature OffServerTokens Prod

The first one,

ServerSignature Off

tells apache not to display the server version on error pages, or other pages it generates.

The second one

ServerTokens Prod

tells apache to only return Apache in the Server header, returned on every page request.

Why do this?