Linux shh服务、网页服务部署

远程连接
安装centos系统时一般默认安装了sshd服务
使用Xshell5 连接
ssh 192.168.1.129   默认是22端口号
vim /etc/ssh/sshd_config     Port 2222  修改端口号    UseDNS yes/no 修改是否使用DNS   解决连接时比较慢的问题   不行在本地解析  /etc/hosts 中加入自己的ip
 
 
 
部署http服务,用于提供网页服务
零、准备环境。
        1.关闭防火墙    service iptables stop        chkconfig iptables off
        2.关闭selinux    setenforce 0
一、yum install httpd -y   安装服务
二、修改配置文件  /etc/httpd/conf/httpd.conf               需要记住DocumentRoot网站根目录       Linsten   80  服务监听的端口号
        新建测试文件或者默认index文件
三、重启服务
四、测试
posted @ 2021-03-16 13:28  持久  阅读(103)  评论(0编辑  收藏  举报