PHPをもっと使えるように
# yum install php-devel
# yum install php-pear
cronolog インストール
# wget http://cronolog.org/download/cronolog-1.6.2.tar.gz
# tar xvzf cronolog-1.6.2.tar.gz
# cd cronolog-1.6.2
# ./configure
# make
# make install
eaccelerator インストール
# wget http://bart.eaccelerator.net/source/0.9.6/eaccelerator-0.9.6.tar.bz2
# tar xvjf eaccelerator-0.9.6.tar.bz2
# cd eaccelerator-0.9.6
# phpize
# phpize
# which php-config
# ./configure –enable-eaccelerator=shared –with-php-config=/usr/bin/php-config
# make
# make install
php.ini に記述する
[eaccelerator]
zend_extension=”/usr/lib/php/modules/eaccelerator.so”
eaccelerator.shm_size = “32”
eaccelerator.cache_dir = “/home/redadmin/php/cache/eaccelerator”
eaccelerator.enable = “1”
eaccelerator.optimizer = “1”
eaccelerator.check_mtime = “1”
eaccelerator.debug = “0”
eaccelerator.filter = “”
eaccelerator.shm_max = “0”
eaccelerator.shm_ttl = “0”
eaccelerator.shm_prune_period = “0”
eaccelerator.shm_only = “0”
eaccelerator.compress = “1”
eaccelerator.compress_level = “9”
eaccelerator.keys = “shm_and_disk”
eaccelerator.sessions = “shm_and_disk”
eaccelerator.content = “shm_and_disk”
webalizer インストール
画像ライブラリを先にインストールする
# yum install libpng*
# yum install libjpeg*
# yum install libgd*
# yum install gd-devel
# wget ftp://ftp.mrunix.net/pub/webalizer/webalizer-2.21-02-src.tar.Z
# tar xvzf webalizer-2.21-02-src.tar.Z
# cd webalizer-2.21-02
# ./configure –with-language=japanese –enable-dns
# make
# make install
cron 設定
# vi /etc/cron.dialy/01webalizer
/usr/local/bin/webalizer -Q -c /home/httpd/vhosts/xxxxxxxxx/conf/xxxxxxxxxxxx.conf /var/log/httpd/xxxxxxxxxxxxxxx/`date -d ‘yesterday’ +%Y/%m`/access_log > /dev/null 2>&1
imagick インストール
ライブラリのエラーがでるのでまずこれをインストールする
# cd /usr/local/src/
# wget http://sourceforge.net/projects/re2c/files/re2c/0.13.5/re2c-0.13.5.tar.gz/download
# tar xvzf re2c-0.13.5.tar.gz
# makcd re2c-0.13.5
# ./configure
# make
# make install
# yum -y install ImageMagick-devel
# pecl install imagick
php.iniに記述
extension=imagick.so
Basic認証
# htpasswd -c /home/httpd/vhosts/xxxxxx/conf/.htpasswd xxxxx
password : xxxxxxxxx
.htacess 書式
AuthType Basic
AuthUserFile /home/httpd/vhosts/xxxxxxx/conf/.htpasswd
AuthGroupFile /dev/null
AuthName “Enter password”
Require valid-user
ntpd 時刻合わせ
# /usr/sbin/ntpdate -s ntp.kuins.kyoto-u.ac.jp
# date
# vi /etc/crontab
cron に記述する
# ntpd
0 5 * * * root /usr/sbin/ntpdate -s ntp.kuins.kyoto-u.ac.jp > /dev/null 2>&1
yumの自動更新を停止する
/etc/init.d/yum-updatesd stop