zoukankan      html  css  js  c++  java
  • Linux下修改Apache即httpd的端口

    原文出处:Linux下修改Apache即httpd的端口

    停止httpd服务

    [root@67 sbin]# service httpd stop
    Redirecting to /bin/systemctl stop httpd.service

    查看httpd的状态,确认httpd服务已经停止

    [root@67 sbin]# service httpd status
    Redirecting to /bin/systemctl status httpd.service
    ● httpd.service - The Apache HTTP Server
       Loaded: loaded (/usr/lib/systemd/system/httpd.service; disabled; vendor preset: disabled)
       Active: inactive (dead)
         Docs: man:httpd(8)
               man:apachectl(8)
    
    8月 23 03:36:01 67.59.247.60.static.bjtelecom.net systemd[1]: Reloading The Apache HTTP Server.
    8月 23 03:36:07 67.59.247.60.static.bjtelecom.net systemd[1]: Reloaded The Apache HTTP Server.
    8月 30 03:29:01 67.59.247.60.static.bjtelecom.net systemd[1]: Reloading The Apache HTTP Server.
    8月 30 03:29:07 67.59.247.60.static.bjtelecom.net systemd[1]: Reloaded The Apache HTTP Server.
    9月 05 03:37:01 67.59.247.60.static.bjtelecom.net systemd[1]: Reloading The Apache HTTP Server.
    9月 05 03:37:01 67.59.247.60.static.bjtelecom.net systemd[1]: Reloaded The Apache HTTP Server.
    9月 06 03:27:01 67.59.247.60.static.bjtelecom.net systemd[1]: Reloading The Apache HTTP Server.
    9月 06 03:27:11 67.59.247.60.static.bjtelecom.net systemd[1]: Reloaded The Apache HTTP Server.
    9月 11 14:29:34 67.59.247.60.static.bjtelecom.net systemd[1]: Stopping The Apache HTTP Server...
    9月 11 14:29:35 67.59.247.60.static.bjtelecom.net systemd[1]: Stopped The Apache HTTP Server.

    查找httpd.conf配置文件的存放路径

    find / -name httpd.conf

    编辑httpd.conf配置文件

    查找Listen配置段

     修改Listen后面的端口,默认是80,这里修改为8080

    保存并退出

    修改后需要再次启动httpd服务

  • 相关阅读:
    frp穿透.md
    6_模板与渲染.md
    4_多数据格式返回请求结果.md
    3_请求参数绑定与多数据格式处理.md
    5_中间件.md
    1_go_gin介绍.md
    2_Gin网络请求与路由处理.md
    14_文件.md
    firefox油猴脚本编写.md
    js 四舍五入
  • 原文地址:https://www.cnblogs.com/kaerxifa/p/13651717.html
Copyright © 2011-2022 走看看