• nginx环境准备


    一、环境调试确认

    1、四项确认

    • 确认公网已连通。
    • 确认yum源可用。
    • 确认iptables已经关闭。
    • 确认selinux已经关闭。

    a、确认是否连通公网。

    ping www.baidu.com

    b、确认 yum 源可用。

    yum list | grep gcc

    c、确认iptables是否关闭

    sudo iptables -L

     发现iptables没有关闭。关闭iptables

    iptables -F   //关闭iptables

    再次确认iptables是否关闭。我们发现iptables已经关闭了

    然后确认 iptable nat 这张表是否有规则

    iptables -t nat -L

     

    我们发现存在规则,关闭 nat 这张表里的规则

    iptables -t nat -F

    再次确认 nat 这张表的规则是否已关闭。 

     

    到此为止,iptables中的所有规则都全部关闭了。

    d、确认 selinux 是否开启。

    getenforce

    发现selinux在运行在运行中。为强制模式

    关闭selinux

    setenforce 0

     再次确认 selinux是否已经关闭

    处于宽容模式(Permissive)或者关闭模式(disabled)都可以。

     2、两项安装

    a、安装系统的基本库。

    yum -y install gcc gcc-c++ autoconf pcre pcre-devel make automake

    b、安装基本工具。

    yum -y install wget httpd-tools vim

    3、一次初始化。

    a、初始化创建几个目录。

    cd /opt
    mkdir app download logs work backup

    app:代码目录。

    download:网上下载的源码包目录。 

    logs:自定义日志目ongoing录。

    work:shell脚本目录。

    backup:默认的配置文件的备份等各种备份目录。

    本文为袋鼠学习中的总结,如有转载请注明出处:https://www.cnblogs.com/chrdai/p/11298078.html

  • 相关阅读:
    发现pythonWin里面的一个地方挺别扭
    细节-质量-态度
    对于Borland出售IDE业务的一点感想
    ReView100遍?!
    代码生成原则Top10
    使用asp.net进行多关键字查询的例子
    代码生成FAQ(翻译)
    msdn中文上的几篇有用的sqlServer2000的文章
    RSS 阅读工具Omea Reader
    Ubuntu18.04 安装Postgresql12
  • 原文地址:https://www.cnblogs.com/chrdai/p/11298078.html
Copyright © 2020-2023  润新知