服务器之家:专注于服务器技术及软件下载分享
分类导航

Linux|Centos|Ubuntu|系统进程|Fedora|注册表|Bios|Solaris|Windows7|Windows10|Windows11|windows server|

服务器之家 - 服务器系统 - Centos - Centos5.2配置LAMP与Centos5.3配置LAMP(22)

Centos5.2配置LAMP与Centos5.3配置LAMP(22)

2019-10-11 14:12Centos教程网 Centos

配置虚拟主机 备份相关配置文件 mv /usr/local/apache2/conf/extra/httpd-vhosts.conf /usr/local/apache2/conf/extra/httpd-vhosts.conf.save mv /usr/local/apache2/conf/extra/httpd-default.conf


配置虚拟主机 

备份相关配置文件 

mv /usr/local/apache2/conf/extra/httpd-vhosts.conf /usr/local/apache2/conf/extra/httpd-vhosts.conf.save 
mv /usr/local/apache2/conf/extra/httpd-default.conf /usr/local/apache2/conf/extra/httpd-default.conf.save 
mv /usr/local/apache2/conf/extra/httpd-mpm.conf /usr/local/apache2/conf/extra/httpd-mpm.conf.save 


创建3个apache相关的文件 

vi /usr/local/apache2/conf/extra/httpd-vhosts.conf 

NameVirtualHost *:80 


ServerAdmin shake.chen@gmail.com 
DocumentRoot “/data/www/wwwroot/test.com” 
ServerName test.com 
ServerAlias bbs.test.com 
ErrorLog “logs/test.com-error_log” 
CustomLog “|/usr/local/cronolog/sbin/cronolog /data/logs/access_www.test.com.%Y%m%d” combined 



ServerAdmin shake.chen@gmail.com 
DocumentRoot “/data/www/wwwroot/linux.com” 
ServerName linux.com 

延伸 · 阅读

精彩推荐