[root@viyin etc]# tail /var/log/messages
Aug 6 11:29:26 viyin kernel: printk: 640 messages suppressed.
Aug 6 11:29:26 viyin kernel: TCP: time wait bucket table overflow
Aug 6 11:29:31 viyin kernel: printk: 299 messages suppressed.
Aug 6 11:29:31 viyin kernel: TCP: time wait bucket table overflow
Aug 6 11:29:37 viyin kernel: printk: 590 messages suppressed.
Aug 6 11:29:37 viyin kernel: TCP: time wait bucket table overflow
Aug 6 11:29:41 viyin kernel: printk: 711 messages suppressed.
Aug 6 11:29:41 viyin kernel: TCP: time wait bucket table overflow
Aug 6 11:29:46 viyin kernel: printk: 290 messages suppressed.
Aug 6 11:29:46 viyin kernel: TCP: time wait bucket table overflow
查看80连接状态
[root@viyin ~]# netstat -an | grep 80 | awk ‘{print $6}’ | sort | uniq -c | sort -rn
5539 ESTABLISHED
768 TIME_WAIT
321 FIN_WAIT1
165 FIN_WAIT2
56 LAST_ACK
32 CONNECTED
22 SYN_RECV
5 STREAM
3 LISTEN
1 33410680
修改 /etc/sysctl.conf
sysctl net.ipv4.tcp_max_tw_buckets=10000
apache编译参数:
通过编译安装文件夹下的cat config.status文件进行查看;
或到安装目录如/usr/local/apache2/build下的config.nice文件查看。
php编译参数:
直接通过命令:/usr/local/php/bin/php -i |grep configure ;
或者通过编译安装文件夹下的cat config.nice文件进行查看;
或利用phpinfo()参数进行查看。
mysql编译参数:
直接通过命令:cat “/usr/local/mysql/bin/mysqlbug”|grep configure ;
freebsd下apache+nginx+php+mysql+eaccelerator+memcache安装配置
太长了。到后面没那么细心了。直接复制粘贴上来。就不加说明了。
1.安装apache
bsd1# pwd
/usr/ports/www/apache22
bsd1# make install clean
2.安装MYSQL
./configure –prefix=/usr/local/mysql –enable-assembler –with-charset=utf8 –enable-thread-safe-client –with-extra-charsets=all –with-big-tables –with-readline –with-ssl –with-embedded-server –enable-local-infile –with-plugins=innobase
make -j 5
make install
groupadd mysql
useradd -g mysql mysql
cp /usr/local/mysql/share/mysql/my-medium.cnf /etc/my.cnf
/usr/local/mysql/bin/mysql_install_db –user=mysql
chown -R mysql /usr/local/mysql/var
chgrp -R mysql /usr/local/mysql/.
cp /usr/local/mysql/share/mysql/mysql.server /etc/init.d/mysql
chmod 755 /etc/init.d/mysql
这是linux的安装命令。BSD照着改一下
2.安装PHP
先装组件jpeg,libpng,freetype,zlib,gd,curl,libxml2,libxslt,libmcrypt
pkg_add -r gd
pkg_add -r freetype
pkg_add -r curl
pkg_add -r libxml2
pkg_add -r libxslt
pkg_add -r libmcrypt
pkg_add -r mhash
./configure –prefix=/usr/local/php –with-config-file-path=/etc –with-apxs2=/usr/local/sbin/apxs –with-mysql=/usr/local/mysql –with-mysqli=/usr/local/mysql/bin/mysql_config –with-iconv-dir –with-freetype-dir –with-jpeg-dir –with-png-dir –with-zlib –with-libxml-dir –enable-xml –disable-rpath –enable-discard-path –enable-magic-quotes –enable-safe-mode –enable-bcmath –enable-shmop –enable-sysvsem –enable-inline-optimization –with-curl –with-curlwrappers –enable-mbregex –enable-force-cgi-redirect –enable-mbstring –with-mcrypt –enable-ftp –with-gd –enable-gd-native-ttf –with-openssl –with-mhash –enable-pcntl –enable-sockets –with-xmlrpc –enable-zip –enable-soap –without-pear –with-gettext –with-mime-magic –enable-suhosin
make &&make install
cp php.ini-dist /etc/php.ini
阅读全文…
分类: √freebsd, √linux, √web, √个人碎语, √历史, √思科华为, √文章精选 标签: apache, eaccelerator, famp, freebsd, memcache, mysql, php, √nginx
配置文件中增加
fastcgi_intercept_errors on;
作者:猪头
版权没有,欢迎转载,转载请勿注明出处
(本文只针对Discuz论坛系统讨论,由于软件包更新速度比较快,你看本贴的时候可能已经是使用新版本的软件包了,安装方法可能不一致,详细请查看软件包的README文件)
测试环境:理想论坛(55188).
理想论坛为国内人气最旺的股票论坛,注册会员已超过100万,并以每月60000人的速度稳定递增,每日页面访问量超过200万,并保持稳定增长的趋势,60分钟在线平均约2万多人,最高记录3万3千多。 目前主题超过30万,帖子接近1千万,数据库大小5.8GB,附件总大小大约150GB
之前理想论坛有三台服务器,两台WEB服务器以及一台数据库服务器,访问已经渐渐出现瓶颈,在猪头的建议下,站长决定增加一台服务器放数据库,另外三台做WEB,并且对原有的服务器的操作系统进行升级。
硬件具体情况
MySQL服务器: DualXeon 5335/8GB内存/73G SAS硬盘(RAID0+1)/CentOS5.1-x86_64/MySQL5
三台WEB服务器如下:
N1. Dual Xeon 3.0 2GB 内存
N1. Dual Xeon 3.0 4GB 内存
N1. Dual Xeon 3.0(双核) 4G内存
另外有三块300G的SCSI硬盘准备做RAID5,用来存放附件,四台机器通过内网连接
猪头考虑过的解决方案如下:
1. ZEUS + PHP5 + eAccelerator
2. squid + Apache2 + PHP + eAccelerator
3. nginx + PHP(fastcgi) + eAccelerator
4. nginx + Apache2 + PHP + eAccelerator
阅读全文…
在Centos5.3上装一个discuz论坛,发现discuz的提示信息里显示不支持mysql:
mysql_connect() 不支持 请检查mysql 模块是否正确加载.
查看/usr/lib/php/modules/里面根本没有mysql.so
找到centos5.3安装盘,找到CentOS目录下的
阅读全文…