存档

文章标签 ‘apache’

查看apache、mysql、php编译参数

2010年6月19日 1 条评论

apache编译参数:

通过编译安装文件夹下的cat config.status文件进行查看;

或到安装目录如/usr/local/2/build下的config.nice文件查看。

php编译参数:

直接通过命令:/usr/local//bin/ -i |grep configure ;

或者通过编译安装文件夹下的cat config.nice文件进行查看;

或利用phpinfo()参数进行查看。

mysql编译参数:

直接通过命令:cat “/usr/local//bin/mysqlbug”|grep configure ;

分类: √linux, √web 标签: , ,

freebsd下apache+nginx+php+mysql+eaccelerator+memcache安装配置

2010年4月19日 没有评论

freebsd下apache+nginx++++memcache安装配置
太长了。到后面没那么细心了。直接复制粘贴上来。就不加说明了。
1.安装apache

bsd1# pwd
/usr/ports/www/22
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
阅读全文…

Apache虚拟主机配置

2010年4月7日 没有评论

虚拟主机有许多方法来实现,比如多IP,多域名,多端口等。这里主要将多域名和多端口的实现步骤。
第一种:多端口的实现

#监听的端口号,如果想一个IP地址多端口控制访问的话必须填写端口
Listen 81
Listen 82

#端口81的虚拟主机

DocumentRoot “Webroot/port01″

#端口82的虚拟主机

DocumentRoot “Webroot/port02″

阅读全文…

freebsd apache

2010年3月27日 没有评论

1.报错Freebsd: No such file or directory: Failed to enable the ‘’ Accept Filter
载入模块
vivi#kldload accf_http
vivi#kldload accf_data
重启apache就好了

2.vivi# ./ -k start 无提示,80端口未开

查看日志
vivi# cat /var/log/httpd-error.log
[Sat Mar 27 22:09:46 2010] [alert] (EAI 8)hostname nor servname provided, or not known: mod_unique_id: unable to find IPv4 address of “vivi”

编辑/usr/local/etc/22/httpd.conf
注释这行 #LoadModule unique_id_module libexec/apache22/mod_unique_id.so

打开/etc/rc.conf设置:

accf_data_load=”YES”
accf_http_load=”YES”
apache22_enable=”YES”

apache 虚拟主机配置

2009年7月24日 没有评论

编辑/etc/httpd/conf/httpd.conf

NameVirtualHost  218.85.17.99:80

<Directory “/var/www/”>

DirectoryIndex index. index.html

Options FollowSymLinks

AllowOverride All

Order allow,deny

Allow from all

</Directory>

<VirtualHost 218.85.157.99:80>

阅读全文…

分类: √linux 标签: , ,

解决centos 自动安装的php不支持mysql

2009年6月14日 1 条评论

在Centos5.3上装一个discuz论坛,发现discuz的提示信息里显示不支持mysql:

_connect() 不支持 请检查mysql 模块是否正确加载.

 查看/usr/lib//modules/里面根本没有mysql.so

 找到centos5.3安装盘,找到CentOS目录下的

阅读全文…

分类: √linux 标签: , , ,