sudo apt-get install nginx mysql-server build-essential libxml2-dev libreadline6 libreadline6-dev openssl libssl-dev curl libcurl4-gnutls-dev libjpeg-dev libpng-dev libmcrypt-dev

[root@host]# chkconfig nginx on

[root@host]# service nginx start
[root@host]# service nginx stop
[root@host]# service nginx restart
[root@host]# service nginx status
[root@host]# service nginx reload

Cenos 7.0

yum -y install mariadb-server mariadb
systemctl start mariadb

yum -y install mariadb-server mariadb

systemctl start mariadb

sudo yum install epel-release
sudo yum install nginx
sudo systemctl start nginx

//修改密码

UPDATE user SET password=PASSWORD('123456') WHERE user='root';

FLUSH PRIVILEGES;

  1. yum install wget gcc gcc-c++ make re2c curl curl-devel libxml2 libxml2-devel libjpeg libjpeg-devel libpng libpng-devel libmcrypt libmcrypt-devel zlib zlib-devel openssl openssl-devel freetype freetype-devel gd gd-devel perl perl-devel ncurses ncurses-devel bison bison-devel libtool gettext gettext-devel cmake bzip2 bzip2-devel pcre pcre-devel
 
./configure --prefix=/usr/local/php  --enable-fpm --enable-sockets --with-mcrypt --enable-mbstring --with-curl --disable-debug  --disable-rpath --enable-inline-optimization --with-bz2 --enable-sysvsem --enable-sysvshm --enable-pcntl --enable-mbregex  --with-mhash --enable-zip --with-pcre-regex --with-png-dir=/extra_disk/pkg/libpng-1.6.21 --with-gd --with-pdo-mysql --enable-pdo --with-openssl --with-freetype-dir=/usr/include/freetype2/freetype/ --with-zlib-dir=/extra_disk/pkg/zlib-1.2.8 --with-jpeg-dir=/extra_disk/pkg/jpeg-6b

PHP Setup

./configure --prefix=/usr/local/php  --enable-fpm --enable-sockets --enable-mbstring --with-curl --disable-debug  --disable-rpath --enable-inline-optimization --with-bz2 --enable-sysvsem --enable-sysvshm --enable-pcntl --enable-mbregex  --with-mhash --enable-zip --with-pcre-regex --with-mysql --with-gd --with-pdo-mysql --enable-pdo --with-openssl --with-freetype-dir=/usr/include/freetype2/freetype/ --with-zlib-dir=/extra_disk/package/zlib-1.2.8 --with-jpeg-dir=/extra_disk/package/jpeg-6b --with-pdo-oci=instantclient,/usr,11.2.0.3.0


 

[root@host]# make

[root@host]# make install

ubuntu

./configure --prefix=/usr/local/php --with-config-file-path=/usr/local/php/etc --enable-fpm --enable-sockets --with-mcrypt --enable-mbstring --with-curl --disable-debug  --disable-rpath --enable-inline-optimization --with-bz2 --enable-sysvsem --enable-sysvshm --enable-pcntl --enable-mbregex  --with-mhash --enable-zip --with-pcre-regex --with-gd --with-pdo-mysql --enable-pdo --with-openssl

groupadd www
useradd -g www www

vi /usr/local/php/etc/php-fpm.conf

user = www

group = www

sudo apt-get install sysv-rc-conf

sysv-rc-conf php-fpm on

sysv-rc-conf nginx on

sysv-rc-conf mysql on

解决办法

cp /usr/local/php/etc/php-fpm.conf.default /usr/local/php/etc/php-fpm.conf

cd php 7.0 sapi/fpm/

cp www.conf /usr/local/php/etc/php-fpm.conf

cp php.ini-production /usr/local/php/lib/php.ini

/usr/local/php/bin/php -i | grep "Loaded Configuration File"

[root@host]# cd sapi/fpm/
[root@host]# cp init.d.php-fpm /etc/init.d/php-fpm

[root@host]# chmod 755 /etc/init.d/php-fpm

[root@host]# /etc/init.d/php-fpm start

[root@host]# /sbin/chkconfig --add /etc/init.d/php-fpm --(添加到开机服务列表)

[root@host]# /sbin/chkconfig php-fpm on

php-fpm的启动、停止和重启:

[root@host]# /etc/init.d/php-fpm start

[root@host]# /etc/init.d/php-fpm stop

打开80端口必须输入以下

[root@host]# /sbin/iptables -I INPUT -p tcp --dport 80 -j ACCEPT

[root@host]# service iptables save

[root@host]# service iptables restart

insert into user(Host,User,Password)values("localhost","test",password("123456"));

flush privileges;

grant all privileges on hsker.* to 'test'@'%' identified by '123456';

flush privileges;

update user set host = '%' where user = 'test';

MySQL Daemon failed to start

chmod 777 -R /var/lib/mysql;

yum install ibus-table-wubi.noarch

#显示当前网络连接
#nmcli connection show
NAME UUID TYPE DEVICE
eno1 5fb06bd0-0bb0-7ffb-45f1-d6edd65f3e03 802-3-ethernet eno1

#修改当前网络连接对应的DNS服务器,这里的网络连接可以用名称或者UUID来标识
#nmcli con mod eno1 ipv4.dns "114.114.114.114 8.8.8.8"

#将dns配置生效
#nmcli con up eno1

centos lnmp 安装笔记的更多相关文章

  1. CentOS LNMP安装phpMyAdmin

    假设: 已经配置好LNMP环境,并且Nginx的网页目录在/usr/local/nginx/html 1.下载phpMyAdmin wget https://files.phpmyadmin.net/ ...

  2. centos docker 安装笔记

    安装epel rpm -ivh http://dl.fedoraproject.org/pub/epel/6/i386/epel-release-6-8.noarch.rpm rpm --import ...

  3. CentOS 7 安装 LNMP 环境(PHP7 + MySQL5.7 + Nginx1.10)

    记录下在CentOS 7 安装 LNMP 环境(PHP7 + MySQL5.7 + Nginx1.10)过程笔记. 工具 VMware版本号 : 12.0.0 CentOS版本 : 7.0 一.修改 ...

  4. MonoDevelop 4.2.2/Mono 3.4.0 in CentOS 6.5 安装笔记

    MonoDevelop 4.2.2/Mono 3.4.0 in CentOS 6.5 安装笔记 说明 以root账户登录Linux操作系统,注意:本文中的所有命令行前面的 #> 表示命令行提示符 ...

  5. Centos编译安装PHP 5.5笔记

    本篇是在 Centos 6.4 32bit 下编译安装 php 5.5.5 的笔记,接上篇 Centos编译安装Apache 2.4.6笔记.php 5.5.x 和 centos 源里面的 php 5 ...

  6. centos LNMP第一部分环境搭建 LAMP LNMP安装先后顺序 php安装 安装nginx 编写nginx启动脚本 懒汉模式 mv /usr/php/{p.conf.default,p.conf} php运行方式SAPI介绍 第二十三节课

    centos  LNMP第一部分环境搭建 LAMP安装先后顺序  LNMP安装先后顺序 php安装 安装nginx  编写nginx启动脚本   懒汉模式  mv   /usr/local/php/{ ...

  7. centos lnmp一键安装

    安装 系统需求: 需要2 GB硬盘剩余空间 128M以上内存,OpenVZ的建议192MB以上(小内存请勿使用64位系统) Linux下区分大小写,输入命令时请注意! 安装步骤: 1.使用putty或 ...

  8. Docker学习笔记之-在CentOS中安装Docker

    上一节演示了如何 通过Xshell连接CentOS服务,链接:Docker学习笔记之-通过Xshell连接 CentOS服务 本节将演示 如何在CentOS中安装 Docker 第一步:更新系统包到最 ...

  9. [转载]centos 7(1611)安装笔记

    centos 7(1611)安装笔记   麻烦 前天我把双系统笔记本里的 deepin 的磁盘分区直接从 Windows 7 磁盘管理里格式化了,结果悲催了,开不了机了,显示: 我以为是 Window ...

随机推荐

  1. Sorting Algorithm

    sorting 应该是最容易被考到的东西,自己老是学了背,背了忘.为了方便复习,这里进行总结 1. Bubble Sort 定义:每两个两个比较,每扫完一次,当前扫过的最大值放在了末尾. for i ...

  2. hdoj 1950 Bridging signals【二分求最大上升子序列长度】【LIS】

    Bridging signals Time Limit: 5000/1000 MS (Java/Others)    Memory Limit: 65536/32768 K (Java/Others) ...

  3. 还原dede数据后系统基本参数空白栏目无显示的解决方法

    有时dedecms开发的网站在更换空间还原数据后,出现"系统基本参数"空白,而且可以看到tag也没有了. 大家不妨看看后台"数据库备份/还原"处,已经还原后的表 ...

  4. UVa1628 UVaLive5847 Pizza Delivery

    填坑系列(p.302) 既然不知道后面还要卖多少个就加一维状态嘛.. lrj写的O(n)转移?其实转移可以O(1) 貌似按x排序有奇效? #include<cstdio> #include ...

  5. 【Jsoup爬取网页内容】

    思路:根据给定URL分析其源码,得到所需的网页内容的位置,制定规则采集或下载之 采集的图片和文字示例: tags: tag:brazil tag:dog tag:pet tag:pointyfaced ...

  6. winform 五子棋 判断输赢 分类: WinForm 2014-08-07 20:55 256人阅读 评论(0) 收藏

    新手上路,高手勿进! 利用数组,根据新旧数组值的不同,获取那个点是什么棋子: 说明: 棋盘:15*15; 定义4个全局变量: string[,] stroldlist = new string[15, ...

  7. 【Android - 框架】之OkHttp的使用

    OkHttp是一个非常优秀的网络访问框架,当下非常火的Retrofit的底层就是使用OkHttp进行封装的.接下来介绍以下OkHttp的简单使用. 1.导入依赖 在Android Studio中,在M ...

  8. 【转】HTML5的语音输入 渐进使用HTML5语言识别, so easy!

    转自: 本文地址:http://www.zhangxinxu.com/wordpress/?p=2408 一.本不想写此文 HTML5语音识别(现在一般用在搜索上),目前相关介绍还是挺多的.为何呢?因 ...

  9. Boa服务器在ARM+Linux上的移植

    下面给大家介绍一下Boa服务器移植的具体操作步骤,希望能够有帮助. 环境        主机:ubuntu8.10        交叉工具链:gcc-3.4.5-glibc-2.3.6         ...

  10. [PWA] Keynote: Progressive Web Apps across all frameworks

    PWA: Add to home screen Angular Universal Server side rendering: for achieving better proference on ...