zoukankan      html  css  js  c++  java
  • LNMP安装

    LNMP

     

    1. 环境准备

     

    1. 安装小工具

    安装lrzsz  拖入安装包  usr/local/src/目录

    [root@localhost src]# rpm -ivh nginx-1.8.0-1.el7.ngx.x86_64.rpm

     

    安装数据库

    [root@localhost src]# yum -y install mariadb mariadb-server

     

    安装mysql驱动

    [root@localhost src]# yum -y install php php-devel php-mysql

     

    安装php管理

    [root@localhost src]# rpm -ivh php-fpm-5.4.16-36.el7_1.x86_64.rpm

     

    1. 修改配置文件 备份一份

     

    [root@localhost src]# vim /etc/nginx/

    conf.d/         koi-utf         mime.types      scgi_params     win-utf         

    fastcgi_params  koi-win         nginx.conf      uwsgi_params    

    [root@localhost src]# cp /etc/nginx/nginx.conf  /etc/nginx/nginx.conf.bak

    [root@localhost src]# vim /etc/nginx/nginx.conf

    [root@localhost src]# cd /etc/nginx/conf.d/

    [root@localhost conf.d]# ls

    default.conf  example_ssl.conf

    [root@localhost conf.d]# vim default.conf

     

    修改配置文件

    [root@localhost conf.d]# vim default.conf

    [root@localhost conf.d]# cp default.conf  default.conf.bak

    [root@localhost conf.d]# vim default.conf

     

     

    重新启动

    进入mysql数据库

     

    安装unzip 解压文件

    Yum -y install unzip

    Unzip upload.zip -d /usr/share/nginx/html/

     

    [root@localhost src]# cd /usr/share/nginx/html/

    [root@localhost html]# ll

    [root@localhost html]# chmod -R 777 upload/

    [root@localhost html]# ll

    [root@localhost html]# systemctl restart php-fpm

    [root@localhost html]# systemctl restart nginx

    [root@localhost html]# systemctl restart mysql

    Failed to restart mysql.service: Unit mysql.service failed to load: No such file or directory.

    [root@localhost html]# systemctl restart mariadb

    [root@localhost html]# ip a

     

    访问页面

  • 相关阅读:
    unity3D打造skybox淡入淡出
    FastGUI for NGUI教程
    (转)oracle的split函数
    (转)oracle嵌套表示例
    (转)pipe row的用法, Oracle split 函数写法.
    (转)Oracle 包(Package)
    (转)Oracle存储过程中的事务
    distinct与order by
    Oracle存储过程使用总结
    (转)Oracle中动态SQL详解
  • 原文地址:https://www.cnblogs.com/wjy879922714/p/11203812.html
Copyright © 2011-2022 走看看