wget -c http://soft.vpser.net/lnmp/lnmp1.4-full.tar.gz tar zxvf lnmp1.4-full.tar.gz cd lnmp1.4-full ./install
执行上面的命令后按照要求输入数据库密码、选择数据库的类型(提供 mysql 和 mariadb ) 以及 PHP 的版本即可进行编译安装。
root@centos:~/lnmp1.4-full# ./install.sh
+------------------------------------------------------------------------+ | LNMP V1.4 for Ubuntu Linux Server, Written by Licess | +------------------------------------------------------------------------+ | A tool to auto-compile & install LNMP/LNMPA/LAMP on Linux | +------------------------------------------------------------------------+ | For more information please visit https://lnmp.org | +------------------------------------------------------------------------+ You have 5 options for your DataBase install. 1: Install MySQL 5.1.73 2: Install MySQL 5.5.56 (Default) 3: Install MySQL 5.6.36 4: Install MySQL 5.7.18 5: Install MariaDB 5.5.56 6: Install MariaDB 10.0.30 7: Install MariaDB 10.1.23 0: DO NOT Install MySQL/MariaDB Enter your choice (1, 2, 3, 4, 5, 6, 7 or 0): 7 # 选择数据库,部分版本的数据库需要内存大于2G You will install MariaDB 10.1.23 =========================== Please setup root password of MySQL.(Default password: root) # 设置mysql root 密码 Please enter: 123456@# MySQL root password: 123456@# =========================== Do you want to enable or disable the InnoDB Storage Engine? # 是否安装 InnoDB 引擎 Default enable,Enter your choice [Y/n]: y You will enable the InnoDB Storage Engine =========================== You have 6 options for your PHP install. # 选择 PHP 版本 1: Install PHP 5.2.17 2: Install PHP 5.3.29 3: Install PHP 5.4.45 4: Install PHP 5.5.38 (Default) 5: Install PHP 5.6.31 6: Install PHP 7.0.21 7: Install PHP 7.1.7 Enter your choice (1, 2, 3, 4, 5, 6 or 7): 7 You will install PHP 7.1.7 =========================== You have 3 options for your Memory Allocator install. 1: Don't install Memory Allocator. (Default) 2: Install Jemalloc 3: Install TCMalloc Enter your choice (1, 2 or 3): 2 You will install JeMalloc
Press any key to install...or Press Ctrl+c to cancel # 按任意键继续安装