1. If there is no ftp software, install and run the following program directly:
yum -y install vsftpd chkconfig vsftpd on
The installation gave the following error:
Could not retrieve mirrorlist http://mirrorlist.centos.org/?release=6&arch=x86_64&repo=os error was 14: PYCURL ERROR 6 - "Couldn't resolve host 'mirrorlist.centos.org'" Error: Cannot find a valid baseurl for repo: base
It is because of the lack of DNS. The solution is as follows: go to the /etc directory and configure resolv.conf to add the nameserver IP: [root@localhost ~]# vi /etc/resolv.conf #The following address is Fujian Telecom DNS nameserver 218.85.157.99
2. Command
Start vsftpd: service vsftpd start Stop vsftpd: service vsftpd stop Restart vsftpd: service vsftpd restart
1. Install nginx+php+mysql
wget http://nginx.org/packages/centos/6/noarch/RPMS/nginx-release-centos-6-0.el6.ngx.noarch.rpm //Download rpm file rpm -ivh nginx-release-centos-6-0.el6.ngx.noarch.rpm //Unzip rpm -qa | grep nginx to check whether nginx is added to the source path install php mysql nginx yum install mysql mysql-server php php-mysql php-fpm nginx If you can't find the source address, please find the update third-party source library in the tips yum install php-cli php-gd php-imap php-ldap php-odbc php-pear php-xml php-xmlrpc php-mbstring php-mcrypt php-mssql php-snmp php-soap php-tidy php-common php-devel
For separate installation, please refer to the following
1.1. Install the php-fpm service separately
yum install -y php php-mysql php-gd libjpeg* php-imap php-ldap php-odbc php-pear php-xml php-xmlrpc php-mbstring php-mcrypt php-bcmath php-mhash libmcrypt libmcrypt-devel php-fpm #start php-fpm /etc/rc.d/init.d/php-fpm start set autostart chkconfig php-fpm on
1.2. Install mysql separately
Install MYSQL yum -y install mysql mysql-server start mysql service mysqld start chkconfig mysqld on #Set to boot Set a password for the root account mysql_secure_installation restart all services service mysqld restart service nginx restart /etc/rc.d/init.d/php-fpm restart test was successful
2. Install svn client
yum install subversion Get the code: svn checkout path svn update //Go to the acquisition directory, update the code
3. Add service auto-start
nginx service chkconfig --add nginx chkconfig nginx on service nginx start php-fpm chkconfig --add php-fpm chkconfig php-fpm on service php-fpm start mysql chkconfig --add mysqld chkconfig mysqld on service mysqld start
4. Uninstall the software
yum remove httpd yum remove mysql yum remove php
5. Firewall configuration
Modify the file /etc/sysconfig/iptables [root@bogon ~]# cd /etc/sysconfig/ [root@bogon sysconfig]# vi iptables
6. Centos7 mysql cannot be used directly
need to install mariadb
# yum install mariadb-server -y # systemctl start mariadb.service # systemctl enable mariadb.service # mysql
Point the database file to another file (using a soft link)
It is created when selinux is opened, so even if you close selinux, its permission control will still work.
7.yum installation
# yum -y remove php* # yum install epel-release # rpm -ivh http://rpms.famillecollet.com/enterprise/remi-release-7.rpm # yum -y install --enablerepo=remi --enablerepo=remi-php56 httpd php php-mbstring php-pear # yum list | grep httpd entOs 5.x rpm -Uvh http://mirror.webtatic.com/yum/el5/latest.rpm CentOs 6.x rpm -Uvh http://mirror.webtatic.com/yum/el6/latest.rpm CentOs 7.X rpm -Uvh https://mirror.webtatic.com/yum/el7/epel-release.rpm rpm -Uvh https://mirror.webtatic.com/yum/el7/webtatic-release.rpm 安装php5.6
yum install --enablerepo=remi --enablerepo=remi-php56 php php-opcache php-devel php-mbstring php-mcrypt php-mysqlnd php-phpunit-PHPUnit php-pecl-xdebug php-pecl-xhprof
安装 php-fpm
yum install --enablerepo=remi --enablerepo=remi-php56 php-fpm