首先说下试验需求
目前有单台的LAMP,但是网站需求量增大单台已经无法满足需求了,所以我们需要在增加一台服务器来提高网站需求量:
试验拓扑图如下:
注:应为没有公网解析,所以就将DNS
服务器做在了新增机器上,这里使用的是两台RHEL5.8的虚拟机,本机IP是192.168.80.1
实施步骤:
配置yum,安装好编译环境,selinux关闭
1、配置DNS解析:
1)首先卸载本机的DNS,这里安装bind97的
# yum -y remove bind-utils bind-libs # yum -y install bind97 bind97-utils bind97-libs # vim /etc/named.conf …… options { listen-on port 53 { any; }; directory "/var/named"; dump-file "/var/named/data/cache_dump.db"; statistics-file "/var/named/data/named_stats.txt"; memstatistics-file "/var/named/data/named_mem_stats.txt"; allow-query { any; }; recursion yes; }; …… # vim /etc/named.rfc1912.zones zone "linuxidc.com" IN { type master; file "linuxidc.com.zone"; }; zone "168.192.in-addr.arpa" IN { type master; file "192.168.zone"; }; # vim /var/named/linuxidc.com.zone $TTL 600 $ORIGIN linuxidc.com. @ IN SOA ns.linuxidc.com. admin.linuxidc.com. ( 2012071501 1H 10M 7D 3H ) IN NS ns ns IN A 192.168.80.139 ns IN A 192.168.80.140 www IN A 192.168.80.139 www IN A 192.168.80.140 # vim /var/named/192.168.zone $TTL 600 @ IN SOA ns.linuxidc.com. admin.linuxidc.com. ( 2012071501 1H 10M 7D 3H ) IN NS ns.linuxidc.com. 80.139 IN PTR ns.linuxidc.com. 80.140 IN PTR ns.linuxidc.com. 80.139 IN PTR 80.140 IN PTR