linux应用与安(web)
web服务器1、卸载原来已经存在的httpd
http://s1.运维网.com/images/20180313/1520877149542734.png
2、插入光盘:Benet 5.0所需软件\linux安全及高级应用\rhel-server-6.5-x86_64-dvd.iso
http://s1.运维网.com/images/20180313/1520877178570315.png
3、源码编译安装httpd,下图为: 1)解包 2)配置
http://s1.运维网.com/images/20180313/1520877219862419.png
4、编译和安装
http://s1.运维网.com/images/20180313/1520877252762775.png
下图为安装编译和安装过程中的状态,这里将会等待几分钟,耐心等待...
http://s1.运维网.com/images/20180313/1520877276313384.png
5、确认安装结果,如果出现下图所示,表示安装成功了
http://s1.运维网.com/images/20180313/1520878635218930.png
6、优化执行路径
http://s1.运维网.com/images/20180313/1520878697444341.png
http://s1.运维网.com/images/20180313/1520878756331982.png
7、添加httpd系统服务(添加好了之后就可以使用service命令开启服务器)
http://s1.运维网.com/images/20180313/1520878802326692.png
下图中标示的第一行需要修改,第二三行需要添加
http://s1.运维网.com/images/20180313/1520878841101235.pnghttp://s1.运维网.com/images/20180313/1520878862505831.png
8、配置并启动httpd服务
http://s1.运维网.com/images/20180313/1520878911526749.png
找到下面的位置,把签名#去掉,然后修改成自己的域名
http://s1.运维网.com/images/20180313/1520878944569247.png
9、语法检查如果没错,就可以开启httpd服务了
http://s1.运维网.com/images/20180313/1520878979227241.png
10、制作网页
http://s1.运维网.com/images/20180313/1520879026288538.pnghttp://s1.运维网.com/images/20180313/1520879034478516.png
11、修改服务器的ip地址
如果是克隆的操作系统,还需要做以下操作
http://s1.运维网.com/images/20180313/1520879081371703.png
删除下图中的HWADDR这一行,然后reboot重启系统
http://s1.运维网.com/images/20180313/1520879107701141.png
http://s1.运维网.com/images/20180313/1520879185401118.png
12、配置dns服务器
1)安装dns(更换redhat6.5光盘)
http://s1.运维网.com/images/20180313/1520879392439308.png
http://s1.运维网.com/images/20180313/1520879402266736.png
2)修改主配置文件
http://s1.运维网.com/images/20180313/1520879460971151.png
http://s1.运维网.com/images/20180313/1520879518348817.png
3)修改数据文件
http://s1.运维网.com/images/20180313/1520879571850935.png
http://s1.运维网.com/images/20180313/1520879582468037.png
4)启动named服务
http://s1.运维网.com/images/20180313/1520879631155276.png
13、修改客户机的ip地址
http://s1.运维网.com/images/20180313/1520879657442620.png
14、在客户机上浏览网页
http://s1.运维网.com/images/20180313/1520879693640349.png
15、在服务器上修改dns的指向
http://s1.运维网.com/images/20180313/1520879720786782.png
http://s1.运维网.com/images/20180313/1520879767248692.png
16、在服务器上使用火狐浏览器浏览网页
http://s1.运维网.com/images/20180313/1520879971707499.png
17、配置网站访问统计awstats
1)解压缩awstas软件
http://s1.运维网.com/images/20180313/1520880241637432.png
2)建立配置文件
http://s1.运维网.com/images/20180313/1520880285381309.png
在屏幕最下面输入/usr/local/httpd/conf/httpd.conf
http://s1.运维网.com/images/20180313/1520880320117646.pnghttp://s1.运维网.com/images/20180313/1520880339924662.pnghttp://s1.运维网.com/images/20180313/1520880351446003.png
http://s1.运维网.com/images/20180313/1520880422158931.png
按照上面图示完成即可,最后按回车结束
3)修改站点统计配置文件
http://s1.运维网.com/images/20180313/1520880451538658.png
修改下面的两项
http://s1.运维网.com/images/20180313/1520880525177195.png
http://s1.运维网.com/images/20180313/1520880541620139.png
建立数据目录
http://s1.运维网.com/images/20180313/1520880572680985.png
4)执行日志分析
http://s1.运维网.com/images/20180313/1520880608715182.png
5)为了自动更新,建立计划任务
Crontab-e
http://s1.运维网.com/images/20180313/1520880662447217.png
http://s1.运维网.com/images/20180313/1520880680727630.png
6)在客户机上访问日志分析系统
http://s1.运维网.com/images/20180313/1520880707524134.png
上图网页中并没有访问的记录,所以刷新几次www.google.com,刷新完成之后再次执行
./awstats_updateall.plnow
http://s1.运维网.com/images/20180313/1520880731531607.png
页:
[1]