记录一次因为tmp目录无法读写而造成mod_gzip故障的解决方法
检查apache的错误日志,发现有大量如下错误:
[Wed Dec 24 10:59:59 2008] [warn] mod_gzip: ERROR: fopen(/tmp/_1444_179_80.wrk) in dyn1_getfdo1
[Wed Dec 24 10:59:59 2008] [warn] mod_gzip: ERROR: Make sure all named directories exist and have the correct permissions.
[Wed Dec 24 10:59:59 2008] [warn] mod_gzip: RECOVERY [GET /_vti_bin/owssvr.dll?UL=1&ACT=4&BUILD=4518&STRMVER=4&CAPREQ=0 HTTP/1.1]
[Wed Dec 24 10:59:59 2008] [error] [client 222.212.251.233] File does not exist: /home/webadm/htdocs/_vti_bin/owssvr.dll
[Wed Dec 24 10:59:59 2008] [error] [client 125.85.173.194] mod_gzip: ERROR: Couldn't create a file descriptor at HTTP : /tmp/_882_299_200.wrk
尝试tmp分区是否可写:
[root@localhost logs]# touch /tmp/aa
touch: cannot touch `/tmp/aa': Read-only file system
故障处理:
1、从dns列表中把此apache去掉:
2、重新对/tmp分区做文件系统
umount /tmp
mkfs.ext3 /dev/sda7
3、重新挂载/tmp分区
mount -t ext3 /dev/sda7 /tmp
这样重新做了ext3分区后,/tmp目录还是无法为mod_gzip所用,经查,是因为/tmp分区没有设置“粘着位”,ok,设置此位后,mod_gzip工作正常。
chmod 1777 /tmp
重新加入lvs列表:
/home/bin/apachectl stop
/home/bin/apachectl startssl
故障处理完毕,apache错误日志不再报错,用httpwatch抓css页面,对比之前的大小,mod_gzip已经开始正常压缩。
阅读(832) | 评论(0) | 转发(0) |