{"id":34666,"date":"2023-02-09T23:14:36","date_gmt":"2024-01-20T08:31:50","guid":{"rendered":"https:\/\/www.silicloud.com\/zh\/blog\/centos7%e3%81%abphp5-6mysql5-7nginx1-8%e3%81%ae%e7%92%b0%e5%a2%83%e6%a7%8b%e7%af%89\/"},"modified":"2024-04-29T13:56:03","modified_gmt":"2024-04-29T05:56:03","slug":"centos7%e3%81%abphp5-6mysql5-7nginx1-8%e3%81%ae%e7%92%b0%e5%a2%83%e6%a7%8b%e7%af%89","status":"publish","type":"post","link":"https:\/\/www.silicloud.com\/zh\/blog\/centos7%e3%81%abphp5-6mysql5-7nginx1-8%e3%81%ae%e7%92%b0%e5%a2%83%e6%a7%8b%e7%af%89\/","title":{"rendered":"CentOS7\u306bPHP5.6,MySQL5.7,Nginx1.8\u306e\u74b0\u5883\u69cb\u7bc9"},"content":{"rendered":"<h2>\u306f\u3058\u3081\u306b<\/h2>\n<p>MySQL\u306egeometry\u30ab\u30e9\u30e0\u3092\u4f7f\u3063\u3066\u307f\u305f\u304b\u3063\u305f\u306e\u3067\u3001Vagrant\u3067CentOS7,PHP5.6,MySQL5.7,Nginx1.8\u306e\u74b0\u5883\u69cb\u7bc9\u3057\u3066\u307f\u307e\u3057\u305f\u3002<br \/>\nfuelphp\u3067\u958b\u767a\u3059\u308b\u306e\u3067Nginx\u306e\u8a2d\u5b9a\u7b87\u6240\u306bfuelphp\u7528\u306e\u8a2d\u5b9a\u3082\u3042\u308a\u307e\u3059\u304c\u30b3\u30e1\u30f3\u30c8\u30a2\u30a6\u30c8\u3057\u3066\u307e\u3059\u3002<br \/>\n\u5f53\u624b\u9806\u3067\u306ffuelphp\u306e\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u306f\u542b\u3093\u3067\u3044\u307e\u305b\u3093\u3002<\/p>\n<h2>\u4e3b\u673a\u7684\u8bbe\u7f6e<\/h2>\n<ul class=\"post-ul\">\n<li style=\"list-style-type: none;\">\n<ul class=\"post-ul\">OSX 10.5.1<\/ul>\n<\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<ul class=\"post-ul\">\n<li style=\"list-style-type: none;\">\n<ul class=\"post-ul\">Vagrant 1.8.1<\/ul>\n<\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<ul class=\"post-ul\">VertualBox 5.0.12<\/ul>\n<h2>\u865a\u62df\u673a\u914d\u7f6e<\/h2>\n<ul class=\"post-ul\">\n<li style=\"list-style-type: none;\">\n<ul class=\"post-ul\">CentOS 7.0.1406<\/ul>\n<\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<ul class=\"post-ul\">\n<li style=\"list-style-type: none;\">\n<ul class=\"post-ul\">PHP 5.6.17<\/ul>\n<\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<ul class=\"post-ul\">\n<li style=\"list-style-type: none;\">\n<ul class=\"post-ul\">MySQL 5.7.10<\/ul>\n<\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<ul class=\"post-ul\">Nginx 1.8.0<\/ul>\n<h2>\u51c6\u5907\u57fa\u4e8eCentOS7\u7684\u865a\u62df\u673a\u955c\u50cf\u3002<\/h2>\n<p>\u6709\u4e00\u4e2a\u540d\u4e3avagrantbox.ex\u7684CentOS7.0 x86_64 minimal\uff08\u5e26\u6709VirtualBoxGuestAddtions 4.3.14\u7248\u672c\uff09\uff0c\u56e0\u6b64\u5c06\u4ee5\u6b64\u4e3a\u57fa\u7840\u8fdb\u884c\u6784\u5efa\u3002<\/p>\n<ul class=\"post-ul\">\n<li style=\"list-style-type: none;\">\n<ul class=\"post-ul\">box\u306e\u8ffd\u52a0<\/ul>\n<\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<ul class=\"post-ul\">\n<li style=\"list-style-type: none;\">\n<ul class=\"post-ul\">vagrant box add centos7 https:\/\/f0fff3908f081cb6461b407be80daf97f07ac418.googledrive.com\/host\/0BwtuV7VyVTSkUG1PM3pCeDJ4dVE\/centos7.box<\/ul>\n<\/li>\n<\/ul>\n<p>vagrant\u521d\u671f\u5316<br \/>\nvagrant init centos7<\/p>\n<p>\u751f\u6210\u3055\u308c\u305fVagrantfile\u306e\u4fee\u6b63<\/p>\n<pre class=\"post-pre\"><code># -*- mode: ruby -*-\r\n# vi: set ft=ruby :\r\n\r\n# All Vagrant configuration is done below. The \"2\" in Vagrant.configure\r\n# configures the configuration version (we support older styles for\r\n# backwards compatibility). Please don't change it unless you know what\r\n# you're doing.\r\nVagrant.configure(2) do |config|\r\n  # The most common configuration options are documented and commented below.\r\n  # For a complete reference, please see the online documentation at\r\n  # https:\/\/docs.vagrantup.com.\r\n\r\n  # Every Vagrant development environment requires a box. You can search for\r\n  # boxes at https:\/\/atlas.hashicorp.com\/search.\r\n  config.vm.box = \"centos7\"\r\n\r\n  # Disable automatic box update checking. If you disable this, then\r\n  # boxes will only be checked for updates when the user runs\r\n  # `vagrant box outdated`. This is not recommended.\r\n  # config.vm.box_check_update = false\r\n\r\n  # Create a forwarded port mapping which allows access to a specific port\r\n  # within the machine from a port on the host machine. In the example below,\r\n  # accessing \"localhost:8080\" will access port 80 on the guest machine.\r\n  # config.vm.network \"forwarded_port\", guest: 80, host: 8080\r\n\r\n  # Create a private network, which allows host-only access to the machine\r\n  # using a specific IP.\r\n  config.vm.network \"private_network\", ip: \"192.168.33.10\" # \u21e6 HOST\u304b\u3089VM\u306b\u30a2\u30af\u30bb\u30b9\u53ef\u80fd\u306b\u3059\u308b\u305f\u3081\u30b3\u30e1\u30f3\u30c8\u5916\u3059\u3002\u4ed6\u306eVagrant\u304c\u3042\u308b\u306a\u3089ip\u5909\u3048\u308b\u3002\r\n\r\n  # Create a public network, which generally matched to bridged network.\r\n  # Bridged networks make the machine appear as another physical device on\r\n  # your network.\r\n  # config.vm.network \"public_network\"\r\n\r\n  # Share an additional folder to the guest VM. The first argument is\r\n  # the path on the host to the actual folder. The second argument is\r\n  # the path on the guest to mount the folder. And the optional third\r\n  # argument is a set of non-required options.\r\n  # config.vm.synced_folder \"..\/data\", \"\/vagrant_data\"\r\n\r\n  # Provider-specific configuration so you can fine-tune various\r\n  # backing providers for Vagrant. These expose provider-specific options.\r\n  # Example for VirtualBox:\r\n  #\r\n  # config.vm.provider \"virtualbox\" do |vb|\r\n  #   # Display the VirtualBox GUI when booting the machine\r\n  #   vb.gui = true\r\n  #\r\n  #   # Customize the amount of memory on the VM:\r\n  #   vb.memory = \"1024\"\r\n  # end\r\n  #\r\n  # View the documentation for the provider you are using for more\r\n  # information on available options.\r\n\r\n  # Define a Vagrant Push strategy for pushing to Atlas. Other push strategies\r\n  # such as FTP and Heroku are also available. See the documentation at\r\n  # https:\/\/docs.vagrantup.com\/v2\/push\/atlas.html for more information.\r\n  # config.push.define \"atlas\" do |push|\r\n  #   push.app = \"YOUR_ATLAS_USERNAME\/YOUR_APPLICATION_NAME\"\r\n  # end\r\n\r\n  # Enable provisioning with a shell script. Additional provisioners such as\r\n  # Puppet, Chef, Ansible, Salt, and Docker are also available. Please see the\r\n  # documentation for more information about their specific syntax and use.\r\n  # config.vm.provision \"shell\", inline: &lt;&lt;-SHELL\r\n  #   sudo apt-get update\r\n  #   sudo apt-get install -y apache2\r\n  # SHELL\r\n\r\n  # vm\u5074\u306e\u6642\u523b\u3092host\u306b\u5408\u308f\u305b\u308b\r\n  # VM\u7acb\u3061\u4e0a\u3052\u3063\u3071\u306a\u3057\u306b\u3057\u3066PC\u30b9\u30ea\u30fc\u30d7\u3057\u305f\u3042\u3068\u306b\u898b\u308b\u3068\u30ba\u30ec\u304f\u308b\uff1f\r\n  # CentOS7\u304b\u3089\u306fChrony\u304cntp\u306e\u4ee3\u308f\u308a\u306b\u306a\u3063\u305f\u3088\u3046\u306a\u306e\u3067\u305d\u3063\u3061\u306b\u5909\u66f4\u3002\r\n  # config.vm.provider :virtualbox do |vb|\r\n  #  vb.customize [\"setextradata\", :id, \"VBoxInternal\/Devices\/VMMDev\/0\/Config\/GetHostTimeDisabled\", 1]\r\n  # end\r\nend\r\n<\/code><\/pre>\n<ul class=\"post-ul\">\n<li style=\"list-style-type: none;\">\n<ul class=\"post-ul\">vagrant\u8d77\u52d5<\/ul>\n<\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<ul class=\"post-ul\">\n<li style=\"list-style-type: none;\">\n<ul class=\"post-ul\">vagrant up<\/ul>\n<\/li>\n<\/ul>\n<p>vm\u306b\u63a5\u7d9a<br \/>\nvagrant ssh<\/p>\n<h2>VM\u5074\u4f5c\u696d \u74b0\u5883\u8a2d\u5b9a<\/h2>\n<p>\u5047\u8bbe\u6240\u6709VM\u64cd\u4f5c\u90fd\u662f\u4ee5root\u7528\u6237\u6267\u884c\u3002\u767b\u5f55\u4e3aroot\u7528\u6237\u3002<\/p>\n<ul class=\"post-ul\">\n<li style=\"list-style-type: none;\">\n<ul class=\"post-ul\">\u30d0\u30fc\u30b8\u30e7\u30f3\u78ba\u8a8d<\/ul>\n<\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<ul class=\"post-ul\">\n<li style=\"list-style-type: none;\">\n<ul class=\"post-ul\">cat \/etc\/redhat-release<\/ul>\n<\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<ul class=\"post-ul\">\n<li style=\"list-style-type: none;\">\n<ul class=\"post-ul\">CentOS7.0\u3088\u308a\u6700\u65b0\u3092\u4f7f\u3044\u305f\u3044\u5834\u5408 -&gt; yum -y upgrade<\/ul>\n<\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<ul class=\"post-ul\">\n<li style=\"list-style-type: none;\">\n<ul class=\"post-ul\">package update\u306e\u5834\u5408 -&gt; yum -y update<\/ul>\n<\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<ul class=\"post-ul\">\n<li style=\"list-style-type: none;\">\n<ul class=\"post-ul\">*upgrade,update\u3057\u306a\u304f\u3066\u3082\u53ef<\/ul>\n<\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<ul class=\"post-ul\">\n<li style=\"list-style-type: none;\">\n<ul class=\"post-ul\">selinux\u7121\u52b9<\/ul>\n<\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<ul class=\"post-ul\">\n<li style=\"list-style-type: none;\">\n<ul class=\"post-ul\">setenforce 0<\/ul>\n<\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<ul class=\"post-ul\">\n<li style=\"list-style-type: none;\">\n<ul class=\"post-ul\">selinux\u6c38\u7d9a\u7121\u52b9<\/ul>\n<\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<ul class=\"post-ul\">\n<li style=\"list-style-type: none;\">\n<ul class=\"post-ul\">sed -i &#8216;s\/SELINUX=enforcing\/SELINUX=disabled\/g&#8217; \/etc\/sysconfig\/selinux<\/ul>\n<\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<ul class=\"post-ul\">\n<li style=\"list-style-type: none;\">\n<ul class=\"post-ul\">sed -i &#8216;s\/SELINUX=enforcing\/SELINUX=disabled\/g&#8217; \/etc\/selinux\/config<\/ul>\n<\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<ul class=\"post-ul\">\n<li style=\"list-style-type: none;\">\n<ul class=\"post-ul\">*1\u756a\u76ee\u3060\u3051\u3060\u3068\u30b5\u30fc\u30d0\u30fc\u518d\u8d77\u52d5\u6642\u306b\u623b\u3063\u3066\u3057\u307e\u3063\u3066\u3044\u305f\u30022\u756a\u76ee\u3060\u3051\u3067\u3082\u5e73\u6c17\uff1f<\/ul>\n<\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<ul class=\"post-ul\">\n<li style=\"list-style-type: none;\">\n<ul class=\"post-ul\">selinux\u78ba\u8a8d<\/ul>\n<\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<ul class=\"post-ul\">\n<li style=\"list-style-type: none;\">\n<ul class=\"post-ul\">getenforce<\/ul>\n<\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<ul class=\"post-ul\">\n<li style=\"list-style-type: none;\">\n<ul class=\"post-ul\">Permissive\u304c\u8868\u793a\u3055\u308c\u308c\u3070OK<\/ul>\n<\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<ul class=\"post-ul\">\n<li style=\"list-style-type: none;\">\n<ul class=\"post-ul\">\u6642\u523b\u3092\u65e5\u672c\u6642\u9593\u306b\u8a2d\u5b9a<\/ul>\n<\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<ul class=\"post-ul\">\n<li style=\"list-style-type: none;\">\n<ul class=\"post-ul\">\\cp -f \/usr\/share\/zoneinfo\/Japan \/etc\/localtime<\/ul>\n<\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<ul class=\"post-ul\">\n<li style=\"list-style-type: none;\">\n<ul class=\"post-ul\">timedatectl set-timezone Asia\/Tokyo<\/ul>\n<\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<ul class=\"post-ul\">\n<li style=\"list-style-type: none;\">\n<ul class=\"post-ul\">\u6642\u523b\u540c\u671f<\/ul>\n<\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<ul class=\"post-ul\">\n<li style=\"list-style-type: none;\">\n<ul class=\"post-ul\">yum -y install chrony<\/ul>\n<\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<ul class=\"post-ul\">vim \/etc\/chrony.conf<\/ul>\n<pre class=\"post-pre\"><code>+ server ntp.nict.jp iburst\r\n+ server ntp1.jst.mfeed.ad.jp iburst\r\n+ server ntp2.jst.mfeed.ad.jp iburst\r\n+ server ntp3.jst.mfeed.ad.jp iburst\r\n- #server 0.centos.pool.ntp.org iburst\r\n- #server 1.centos.pool.ntp.org iburst\r\n- #server 2.centos.pool.ntp.org iburst\r\n- #server 3.centos.pool.ntp.org iburst\r\n<\/code><\/pre>\n<h2>VM\u5074\u8a2d\u5b9a MySQL5.7\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb<\/h2>\n<ul class=\"post-ul\">\n<li style=\"list-style-type: none;\">\n<ul class=\"post-ul\">mariadb\u3068\u7af6\u5408\u3057\u306a\u3044\u3088\u3046\u306b\u524a\u9664<\/ul>\n<\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<ul class=\"post-ul\">\n<li style=\"list-style-type: none;\">\n<ul class=\"post-ul\">yum -y remove mariadb-libs<\/ul>\n<\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<ul class=\"post-ul\">\n<li style=\"list-style-type: none;\">\n<ul class=\"post-ul\">rm -rf \/var\/lib\/mysql\/<\/ul>\n<\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<ul class=\"post-ul\">\n<li style=\"list-style-type: none;\">\n<ul class=\"post-ul\">MySQL\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb<\/ul>\n<\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<ul class=\"post-ul\">\n<li style=\"list-style-type: none;\">\n<ul class=\"post-ul\">yum -y install http:\/\/dev.mysql.com\/get\/mysql57-community-release-el7-7.noarch.rpm<\/ul>\n<\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<ul class=\"post-ul\">yum -y install mysql-community-server<\/ul>\n<h2>\u5b89\u88c5PHP 5.6\u3002<\/h2>\n<ul class=\"post-ul\">\n<li style=\"list-style-type: none;\">\n<ul class=\"post-ul\">epel\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb<\/ul>\n<\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<ul class=\"post-ul\">\n<li style=\"list-style-type: none;\">\n<ul class=\"post-ul\">rpm -Uvh http:\/\/ftp.iij.ad.jp\/pub\/linux\/fedora\/epel\/7\/x86_64\/e\/epel-release-7-5.noarch.rpm<\/ul>\n<\/li>\n<\/ul>\n<p>remi\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb<br \/>\nrpm -Uvh http:\/\/rpms.famillecollet.com\/enterprise\/remi-release-7.rpm<\/p>\n<p>PHP\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb(\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u30e2\u30b8\u30e5\u30fc\u30eb\u306f\u4efb\u610f\u3067)<br \/>\nyum -y install &#8211;enablerepo=remi &#8211;enablerepo=remi-php56 php php-devel php-gd php-mbstring php-mcrypt php-memcache php-mysql php-mysqlnd php-pdo php-gd php-fpm php-cli php-xml phpMyAdmin<\/p>\n<h2>\u5b89\u88c5Nginx<\/h2>\n<p>rpm -Uvh http:\/\/nginx.org\/packages\/centos\/7\/noarch\/RPMS\/nginx-release-centos-7-0.el7.ngx.noarch.rpm<br \/>\nyum -y install nginx<\/p>\n<h2>\u542f\u52a8\u670d\u52a1<\/h2>\n<ul class=\"post-ul\">\n<li style=\"list-style-type: none;\">\n<ul class=\"post-ul\">\u4e00\u65e6\u3001MySQL\u3001firewall\u3001chrony\u306e\u30b5\u30fc\u30d3\u30b9\u8d77\u52d5<\/ul>\n<\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<ul class=\"post-ul\">systemctl start mysqld.service &amp;&amp; systemctl start firewalld.service &amp;&amp; systemctl start chronyd.service<\/ul>\n<h2>\u5404\u79cd\u670d\u52a1\u7684\u81ea\u52a8\u542f\u52a8\u8bbe\u7f6e<\/h2>\n<ul class=\"post-ul\">\n<li style=\"list-style-type: none;\">\n<ul class=\"post-ul\">Nginx,php-fpm,MySQL,firewall\u306e\u81ea\u52d5\u8d77\u52d5\u3092\u8a2d\u5b9a<\/ul>\n<\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<ul class=\"post-ul\">systemctl enable nginx.service &amp;&amp; systemctl enable php-fpm.service &amp;&amp; systemctl enable mysqld.service &amp;&amp; systemctl enable firewalld.service &amp;&amp; systemctl enable chronyd<\/ul>\n<h2>MySQL\u7684\u914d\u7f6e<\/h2>\n<ul class=\"post-ul\">\n<li style=\"list-style-type: none;\">\n<ul class=\"post-ul\">my.cnf\u306e\u4fee\u6b63(\u6587\u5b57\u30b3\u30fc\u30c9\u306a\u3069)<\/ul>\n<\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<ul class=\"post-ul\">vi \/etc\/my.cnf<\/ul>\n<pre class=\"post-pre\"><code>[mysqld]\r\n+ character-set-server = utf8       # \u6587\u5b57\u30b3\u30fc\u30c9\r\n+ validate_password = OFF           # \u30d1\u30b9\u30ef\u30fc\u30c9\u3092\u8907\u96d1\u5316\u3057\u3066\u3044\u306a\u3044\u3068\u53d7\u3051\u4ed8\u3051\u306a\u3044\u8a2d\u5b9a\u3092\u7121\u52b9\r\n+ default_password_lifetime = 0     # \u30d1\u30b9\u30ef\u30fc\u30c9\u6709\u52b9\u671f\u9650\u3092\u7121\u52b9\u3002\u30c7\u30d5\u30a9\u30eb\u30c8\u3060\u3068365\u65e5\u3067\u5207\u308c\u3066\u30ed\u30b0\u30a4\u30f3\u3067\u304d\u306a\u304f\u306a\u308b\r\n+ log_timestamps=system             # log\u51fa\u529b\u30bf\u30a4\u30e0\u30b9\u30bf\u30f3\u30d7\u3092JST\u3002\u30c7\u30d5\u30a9\u30eb\u30c8\u3060\u3068UTC\r\n# my.cnf\u306e\u8a2d\u5b9a\u306f\u3082\u3063\u3068\u3084\u308b\u3053\u3068\u3042\u308b\u3068\u601d\u3046\u304c\u3068\u308a\u3042\u3048\u305a\u3002\r\n<\/code><\/pre>\n<ul class=\"post-ul\">\n<li style=\"list-style-type: none;\">\n<ul class=\"post-ul\">cnf\u4fee\u6b63\u3057\u305f\u306e\u3067MySQL\u3092\u518d\u8d77\u52d5<\/ul>\n<\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<ul class=\"post-ul\">\n<li style=\"list-style-type: none;\">\n<ul class=\"post-ul\">systemctl restart mysqld.service<\/ul>\n<\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<ul class=\"post-ul\">\n<li style=\"list-style-type: none;\">\n<ul class=\"post-ul\">root\u521d\u671f\u30d1\u30b9\u30ef\u30fc\u30c9\u78ba\u8a8d<\/ul>\n<\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<ul class=\"post-ul\">\n<li style=\"list-style-type: none;\">\n<ul class=\"post-ul\">grep -e &#8216;A temporary password is generated for root@localhost&#8217; \/var\/log\/mysqld.log<\/ul>\n<\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<ul class=\"post-ul\">\n<li style=\"list-style-type: none;\">\n<ul class=\"post-ul\">root\u30d1\u30b9\u30ef\u30fc\u30c9\u306a\u3069\u3092\u5909\u66f4<\/ul>\n<\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<ul class=\"post-ul\">mysql_secure_installation<\/ul>\n<pre class=\"post-pre\"><code>2016-01-07T00:28:18.308696Z 1 [Note] A temporary password is generated for root@localhost: L!omqpK#k4bq\r\n[root@localhost ~]# mysql_secure_installation\r\n\r\nSecuring the MySQL server deployment.\r\n\r\nEnter password for user root:[grep\u3067\u78ba\u8a8d\u3057\u305f\u30d1\u30b9\u30ef\u30fc\u30c9\u3092\u5165\u529b] \r\n\r\nThe existing password for the user account root has expired. Please set a new password.\r\n\r\nNew password: [vagrant \u3068\u3057\u307e\u3057\u305f]\r\n\r\nRe-enter new password: [vagrant]\r\nThe 'validate_password' plugin is installed on the server.\r\nThe subsequent steps will run with the existing configuration\r\nof the plugin.\r\nUsing existing password for root.\r\n\r\nEstimated strength of the password: 0 \r\nChange the password for root ? ((Press y|Y for Yes, any other key for No) : No # \u82f1\u6570\u8a18\u53f7\u306a\u3069\u542b\u3093\u3060\u30d1\u30b9\u30ef\u30fc\u30c9\u3067\u8a2d\u5b9a\u3059\u308b\u304b\uff1f\u3063\u3066\u805e\u3044\u3066\u304f\u308b\u3051\u3069\u8a2d\u5b9a\u3057\u306a\u3044\u3002\r\n\r\n ... skipping.\r\nBy default, a MySQL installation has an anonymous user,\r\nallowing anyone to log into MySQL without having to have\r\na user account created for them. This is intended only for\r\ntesting, and to make the installation go a bit smoother.\r\nYou should remove them before moving into a production\r\nenvironment.\r\n\r\nRemove anonymous users? (Press y|Y for Yes, any other key for No) : y # anonymous ser\u524a\u9664\u3059\u308b\r\nSuccess.\r\n\r\n\r\nNormally, root should only be allowed to connect from\r\n'localhost'. This ensures that someone cannot guess at\r\nthe root password from the network.\r\n\r\nDisallow root login remotely? (Press y|Y for Yes, any other key for No) : y\r\nSuccess.\r\n\r\nBy default, MySQL comes with a database named 'test' that\r\nanyone can access. This is also intended only for testing,\r\nand should be removed before moving into a production\r\nenvironment.\r\n\r\n\r\nRemove test database and access to it? (Press y|Y for Yes, any other key for No) : y # test db\u3092\u524a\u9664\u3059\u308b\r\n - Dropping test database...\r\nSuccess.\r\n\r\n - Removing privileges on test database...\r\nSuccess.\r\n\r\nReloading the privilege tables will ensure that all changes\r\nmade so far will take effect immediately.\r\n\r\nReload privilege tables now? (Press y|Y for Yes, any other key for No) : y # \u518d\u8d77\u52d5\u3059\u308b\r\nSuccess.\r\n\r\nAll done! \r\n<\/code><\/pre>\n<h2>PHP\u8bbe\u7f6e<\/h2>\n<ul class=\"post-ul\">\n<li style=\"list-style-type: none;\">\n<ul class=\"post-ul\">php.ini\u306e\u4fee\u6b63<\/ul>\n<\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<ul class=\"post-ul\">\n<li style=\"list-style-type: none;\">\n<ul class=\"post-ul\">timezone,session.save_path\u3092\u4fee\u6b63(CentOS7\u3067\u306f\/tmp\u306b\u30d5\u30a1\u30a4\u30eb\u7f6e\u3044\u3066\u3082\u30b7\u30b9\u30c6\u30e0\u3067\u6d88\u3055\u308c\u308b\u305f\u3081)<\/ul>\n<\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<ul class=\"post-ul\">\n<li style=\"list-style-type: none;\">\n<ul class=\"post-ul\">sed -i &#8216;s\/;date.timezone =$\/date.timezone = &#8220;Asia\\\/Tokyo&#8221;\/g&#8217; \/etc\/php.ini<\/ul>\n<\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<ul class=\"post-ul\">\n<li style=\"list-style-type: none;\">\n<ul class=\"post-ul\">sed -i &#8216;s\/;session.save_path = &#8220;\\\/tmp&#8221;$\/session.save_path = &#8220;\\\/var\\\/lib\\\/php\\\/session&#8221;\/g&#8217; \/etc\/php.ini<\/ul>\n<\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<ul class=\"post-ul\">\n<li style=\"list-style-type: none;\">\n<ul class=\"post-ul\">session.save_path\u306e\u30b0\u30eb\u30fc\u30d7\u5909\u66f4<\/ul>\n<\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<ul class=\"post-ul\">\n<li style=\"list-style-type: none;\">\n<ul class=\"post-ul\">chown :vagrant \/var\/lib\/php\/session<\/ul>\n<\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<ul class=\"post-ul\">\n<li style=\"list-style-type: none;\">\n<ul class=\"post-ul\">php-fpm.cnf\u306e\u4fee\u6b63<\/ul>\n<\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<ul class=\"post-ul\">\n<li style=\"list-style-type: none;\">\n<ul class=\"post-ul\">user,group\u3092vagrant\u306b\u4fee\u6b63<\/ul>\n<\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<ul class=\"post-ul\">\n<li style=\"list-style-type: none;\">\n<ul class=\"post-ul\">sed -i &#8220;s\/user = apache$\/user = vagrant\/g&#8221; \/etc\/php-fpm.d\/www.conf<\/ul>\n<\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<ul class=\"post-ul\">sed -i &#8220;s\/group = apache$\/group = vagrant\/g&#8221; \/etc\/php-fpm.d\/www.conf<\/ul>\n<h2>Nginx\u914d\u7f6e<\/h2>\n<ul class=\"post-ul\">\n<li style=\"list-style-type: none;\">\n<ul class=\"post-ul\">\u30c9\u30ad\u30e5\u30e1\u30f3\u30c8\u30eb\u30fc\u30c8\u30c7\u30a3\u30ec\u30af\u30c8\u30ea\u4f5c\u6210<\/ul>\n<\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<ul class=\"post-ul\">\n<li style=\"list-style-type: none;\">\n<ul class=\"post-ul\">rm -rf \/var\/www &amp;&amp; mkdir -p \/var\/www\/public<\/ul>\n<\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<ul class=\"post-ul\">\n<li style=\"list-style-type: none;\">\n<ul class=\"post-ul\">\u78ba\u8a8d\u7528php\u30d5\u30a1\u30a4\u30eb\u4f5c\u6210<\/ul>\n<\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<ul class=\"post-ul\">\n<li style=\"list-style-type: none;\">\n<ul class=\"post-ul\">echo &#8216;<!--?php phpinfo();' &gt; \/var\/www\/public\/index.php&lt;br ?--> user,group\u5909\u66f4<\/ul>\n<\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<ul class=\"post-ul\">\n<li style=\"list-style-type: none;\">\n<ul class=\"post-ul\">chown -R vagrant:vagrant \/var\/www<\/ul>\n<\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<ul class=\"post-ul\">\n<li style=\"list-style-type: none;\">\n<ul class=\"post-ul\">conf\u4f5c\u6210<\/ul>\n<\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<ul class=\"post-ul\">vi \/etc\/nginx\/conf.d\/dev.conf<\/ul>\n<pre class=\"post-pre\"><code># app\r\nserver {\r\n    listen       80;\r\n    server_name  192.168.33.10;\r\n    charset utf-8;\r\n\r\n    # file_upload_size.default 1mb.\r\n    client_max_body_size  32M;\r\n\r\n    # access_log\u306fformat\u306f\u6307\u5b9a\u53ef\u80fd\u3060\u304c\u3001level\u306f\u6307\u5b9a\u4e0d\u53ef\r\n    # \"main\"\u3068\u8a18\u8f09\u3057\u3066\u3044\u308b\u306e\u306f\u3001nginx.conf\u306bmain\u3068\u3044\u3046\u540d\u524d\u3067format\u3092\u8a2d\u5b9a\u3057\u3066\u3044\u3066\u305d\u308c\u3092\u4f7f\u3063\u3066\u3044\u308b\r\n    access_log  \/var\/log\/nginx\/access.log main;\r\n\r\n    # error_log\u306fformat\u306f\u6307\u5b9a\u4e0d\u53ef\u3060\u304c\u3001level\u306f\u6307\u5b9a\u53ef\u80fd\r\n    # log\u30ec\u30d9\u30eb\u306fdebug,info,notice,warn,error,crit\u304b\u3089\u9078\u3076\r\n    error_log  \/var\/log\/nginx\/error.log debug;\r\n\r\n    location \/ {\r\n        root   \/var\/www\/public;\r\n        index  index.php;\r\n\r\n        # ===fuelphp\u4f7f\u3046\u306a\u3089\u5fc5\u8981===\r\n        # rewrite setting\r\n        # try_files $uri $uri\/ \/index.php$is_args$args;\r\n        # ===\/ fuelphp\u4f7f\u3046\u306a\u3089\u5fc5\u8981===\r\n    }\r\n\r\n    location ~ \\.php$ {\r\n        root           \/var\/www\/public;\r\n        fastcgi_pass   127.0.0.1:9000;\r\n        fastcgi_index  index.php;\r\n        fastcgi_param  SCRIPT_FILENAME  $document_root$fastcgi_script_name;\r\n        # fastcgi_param  FUEL_ENV \"production\";# ===fuelphp\u4f7f\u3046\u306a\u3089\u5fc5\u8981===\r\n        include        fastcgi_params;\r\n    }\r\n}\r\n\r\n# phpmyadmin\r\nserver {\r\n    listen       8080;\r\n    server_name  192.168.33.10;\r\n\r\n    charset utf-8;\r\n    access_log  \/var\/log\/nginx\/phpmyadmin.access.log  main;\r\n    error_log  \/var\/log\/nginx\/phpmyadmin.error.log  error;\r\n\r\n    location \/ {\r\n        root   \/usr\/share\/phpMyAdmin;\r\n        index  index.php;\r\n    }\r\n\r\n    location ~ \\.php$ {\r\n        root           \/usr\/share\/phpMyAdmin;\r\n        fastcgi_pass   127.0.0.1:9000;\r\n        fastcgi_index  index.php;\r\n        fastcgi_param  SCRIPT_FILENAME  $document_root$fastcgi_script_name;\r\n        include        fastcgi_params;\r\n    }\r\n}\r\n<\/code><\/pre>\n<ul class=\"post-ul\">\n<li style=\"list-style-type: none;\">\n<ul class=\"post-ul\">\/etc\/nginx\/nginx.conf\u306e\u4fee\u6b63<\/ul>\n<\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<ul class=\"post-ul\">\n<li style=\"list-style-type: none;\">\n<ul class=\"post-ul\">sed -i &#8220;s\/user nginx;$\/user vagrant;\/g&#8221; \/etc\/nginx\/nginx.conf<\/ul>\n<\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<ul class=\"post-ul\">\n<li style=\"list-style-type: none;\">\n<ul class=\"post-ul\">\/etc\/nginx\/conf.d\/default.conf\u3092\u4f7f\u308f\u306a\u3044\u306e\u3067\u30ea\u30cd\u30fc\u30e0<\/ul>\n<\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<ul class=\"post-ul\">\n<li style=\"list-style-type: none;\">\n<ul class=\"post-ul\">mv \/etc\/nginx\/conf.d\/default.conf \/etc\/nginx\/conf.d\/default.conf.bk<\/ul>\n<\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<ul class=\"post-ul\">\n<li style=\"list-style-type: none;\">\n<ul class=\"post-ul\">php-fpm,nginx\u8d77\u52d5<\/ul>\n<\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<ul class=\"post-ul\">\n<li style=\"list-style-type: none;\">\n<ul class=\"post-ul\">php-fpm,Nginx\u306e\u8a2d\u5b9a\u30d5\u30a1\u30a4\u30eb\u3092\u66f4\u65b0\u3057\u305f\u306e\u3067\u518d\u8d77\u52d5<\/ul>\n<\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<ul class=\"post-ul\">systemctl start nginx.service &amp;&amp; systemctl start php-fpm.service<\/ul>\n<h2>\u9632\u706b\u5899\u8bbe\u7f6e<\/h2>\n<ul class=\"post-ul\">\n<li style=\"list-style-type: none;\">\n<ul class=\"post-ul\">\u5b8c\u5168\u7121\u52b9<\/ul>\n<\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<ul class=\"post-ul\">\n<li style=\"list-style-type: none;\">\n<ul class=\"post-ul\">systemctl stop firewalld<\/ul>\n<\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<ul class=\"post-ul\">\n<li style=\"list-style-type: none;\">\n<ul class=\"post-ul\">systemctl disable firewalld<\/ul>\n<\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<ul class=\"post-ul\">\n<li style=\"list-style-type: none;\">\n<ul class=\"post-ul\">*\u958b\u767a\u74b0\u5883\u306a\u306e\u3067\u4e0a\u8a18\u306e\u307f\u3067\u53ef\u3002\u52c9\u5f37\u304c\u3066\u3089\u4e0a\u8a18\u3067\u306f\u306a\u304f\u3001\u4e0b\u8a18\u8a2d\u5b9a\u306b\u3057\u3066\u307f\u307e\u3057\u305f\u3002<\/ul>\n<\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<ul class=\"post-ul\">\n<li style=\"list-style-type: none;\">\n<ul class=\"post-ul\">http,https,8080\u30dd\u30fc\u30c8\u3092\u6c38\u7d9a\u8a31\u53ef<\/ul>\n<\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<ul class=\"post-ul\">\n<li style=\"list-style-type: none;\">\n<ul class=\"post-ul\">firewall-cmd &#8211;add-service=http &#8211;permanent &amp;&amp; firewall-cmd &#8211;add-service=https &#8211;permanent &amp;&amp; firewall-cmd &#8211;add-port=8080\/tcp &#8211;permanent<\/ul>\n<\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<ul class=\"post-ul\">\n<li style=\"list-style-type: none;\">\n<ul class=\"post-ul\">firewall\u518d\u8d77\u52d5<\/ul>\n<\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<ul class=\"post-ul\">\n<li style=\"list-style-type: none;\">\n<ul class=\"post-ul\">firewall-cmd &#8211;reload<\/ul>\n<\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<ul class=\"post-ul\">\n<li style=\"list-style-type: none;\">\n<ul class=\"post-ul\">\u8a2d\u5b9a\u5185\u5bb9\u78ba\u8a8d<\/ul>\n<\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<ul class=\"post-ul\">\n<li style=\"list-style-type: none;\">\n<ul class=\"post-ul\">firewall-cmd &#8211;list-services<\/ul>\n<\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<ul class=\"post-ul\">firewall-cmd &#8211;list-ports<\/ul>\n<h2>\u786e\u8ba4\u8bbf\u95ee<\/h2>\n<ul class=\"post-ul\">\n<li style=\"list-style-type: none;\">\n<ul class=\"post-ul\">PHP<\/ul>\n<\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<ul class=\"post-ul\">\n<li style=\"list-style-type: none;\">\n<ul class=\"post-ul\">http:\/\/192.168.33.10<\/ul>\n<\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<ul class=\"post-ul\">\n<li style=\"list-style-type: none;\">\n<ul class=\"post-ul\">phpinfo\u304c\u51fa\u308b\u4e8b<\/ul>\n<\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<ul class=\"post-ul\">\n<li style=\"list-style-type: none;\">\n<ul class=\"post-ul\">phpMyAdmin<\/ul>\n<\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<ul class=\"post-ul\">\n<li style=\"list-style-type: none;\">\n<ul class=\"post-ul\">http:\/\/192.168.33.10:8080<\/ul>\n<\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<ul class=\"post-ul\">\n<li style=\"list-style-type: none;\">\n<ul class=\"post-ul\">id:root<\/ul>\n<\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<ul class=\"post-ul\">\n<li style=\"list-style-type: none;\">\n<ul class=\"post-ul\">pw:vagrant<\/ul>\n<\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<ul class=\"post-ul\">\u3067\u30ed\u30b0\u30a4\u30f3\u51fa\u6765\u308b\u4e8b<\/ul>\n<h2>\u6c89\u8ff7\u4e8e\u7684\u5730\u65b9<\/h2>\n<p>\u3069\u3046\u3082\u7e4b\u304c\u3089\u306a\u3044\u3068\u601d\u3063\u305f\u3089\u3001selinux\u304c\u6709\u52b9\u3060\u3063\u305f\u3002\u3002\u3002<br \/>\n\u3069\u3046\u3082\u7e4b\u304c\u3089\u306a\u3044\u3068\u601d\u3063\u305f\u3089\u3001firewall\u304c\u6709\u52b9\u3060\u3063\u305f\u3002\u3002\u3002<\/p>\n<p>(\u00b4-`).\uff61oO(\u6211\u8981\u5b66\u4e60Ansible\u548cDocker\u3002)<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u306f\u3058\u3081\u306b MySQL\u306egeometry\u30ab\u30e9\u30e0\u3092\u4f7f\u3063\u3066\u307f\u305f\u304b\u3063\u305f\u306e\u3067\u3001Vagrant\u3067CentOS7,PHP5. [&hellip;]<\/p>\n","protected":false},"author":4,"featured_media":0,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[],"class_list":["post-34666","post","type-post","status-publish","format-standard","hentry","category-uncategorized"],"yoast_head":"<!-- This site is optimized with the Yoast SEO Premium plugin v21.5 (Yoast SEO v21.5) - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>CentOS7\u306bPHP5.6,MySQL5.7,Nginx1.8\u306e\u74b0\u5883\u69cb\u7bc9 - Blog - Silicon Cloud<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.silicloud.com\/zh\/blog\/centos7\u306bphp5-6mysql5-7nginx1-8\u306e\u74b0\u5883\u69cb\u7bc9\/\" \/>\n<meta property=\"og:locale\" content=\"zh_CN\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"CentOS7\u306bPHP5.6,MySQL5.7,Nginx1.8\u306e\u74b0\u5883\u69cb\u7bc9\" \/>\n<meta property=\"og:description\" content=\"\u306f\u3058\u3081\u306b MySQL\u306egeometry\u30ab\u30e9\u30e0\u3092\u4f7f\u3063\u3066\u307f\u305f\u304b\u3063\u305f\u306e\u3067\u3001Vagrant\u3067CentOS7,PHP5. [&hellip;]\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.silicloud.com\/zh\/blog\/centos7\u306bphp5-6mysql5-7nginx1-8\u306e\u74b0\u5883\u69cb\u7bc9\/\" \/>\n<meta property=\"og:site_name\" content=\"Blog - Silicon Cloud\" \/>\n<meta property=\"article:published_time\" content=\"2024-01-20T08:31:50+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2024-04-29T05:56:03+00:00\" \/>\n<meta name=\"author\" content=\"\u79d1, \u96c5\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"\u4f5c\u8005\" \/>\n\t<meta name=\"twitter:data1\" content=\"\u79d1, \u96c5\" \/>\n\t<meta name=\"twitter:label2\" content=\"\u9884\u8ba1\u9605\u8bfb\u65f6\u95f4\" \/>\n\t<meta name=\"twitter:data2\" content=\"8 \u5206\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"WebPage\",\"@id\":\"https:\/\/www.silicloud.com\/zh\/blog\/centos7%e3%81%abphp5-6mysql5-7nginx1-8%e3%81%ae%e7%92%b0%e5%a2%83%e6%a7%8b%e7%af%89\/\",\"url\":\"https:\/\/www.silicloud.com\/zh\/blog\/centos7%e3%81%abphp5-6mysql5-7nginx1-8%e3%81%ae%e7%92%b0%e5%a2%83%e6%a7%8b%e7%af%89\/\",\"name\":\"CentOS7\u306bPHP5.6,MySQL5.7,Nginx1.8\u306e\u74b0\u5883\u69cb\u7bc9 - Blog - Silicon Cloud\",\"isPartOf\":{\"@id\":\"https:\/\/www.silicloud.com\/zh\/blog\/#website\"},\"datePublished\":\"2024-01-20T08:31:50+00:00\",\"dateModified\":\"2024-04-29T05:56:03+00:00\",\"author\":{\"@id\":\"https:\/\/www.silicloud.com\/zh\/blog\/#\/schema\/person\/41e222757cdd2a3365361328bd79970a\"},\"breadcrumb\":{\"@id\":\"https:\/\/www.silicloud.com\/zh\/blog\/centos7%e3%81%abphp5-6mysql5-7nginx1-8%e3%81%ae%e7%92%b0%e5%a2%83%e6%a7%8b%e7%af%89\/#breadcrumb\"},\"inLanguage\":\"zh-Hans\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/www.silicloud.com\/zh\/blog\/centos7%e3%81%abphp5-6mysql5-7nginx1-8%e3%81%ae%e7%92%b0%e5%a2%83%e6%a7%8b%e7%af%89\/\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/www.silicloud.com\/zh\/blog\/centos7%e3%81%abphp5-6mysql5-7nginx1-8%e3%81%ae%e7%92%b0%e5%a2%83%e6%a7%8b%e7%af%89\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"\u9996\u9875\",\"item\":\"https:\/\/www.silicloud.com\/zh\/blog\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"CentOS7\u306bPHP5.6,MySQL5.7,Nginx1.8\u306e\u74b0\u5883\u69cb\u7bc9\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/www.silicloud.com\/zh\/blog\/#website\",\"url\":\"https:\/\/www.silicloud.com\/zh\/blog\/\",\"name\":\"Blog - Silicon Cloud\",\"description\":\"\",\"inLanguage\":\"zh-Hans\"},{\"@type\":\"Person\",\"@id\":\"https:\/\/www.silicloud.com\/zh\/blog\/#\/schema\/person\/41e222757cdd2a3365361328bd79970a\",\"name\":\"\u79d1, \u96c5\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"zh-Hans\",\"@id\":\"https:\/\/www.silicloud.com\/zh\/blog\/#\/schema\/person\/image\/\",\"url\":\"https:\/\/secure.gravatar.com\/avatar\/1b2d3e00a7df03689797ebd4af8c5827ba5af936849a71050ec331f4cf902c5d?s=96&d=mm&r=g\",\"contentUrl\":\"https:\/\/secure.gravatar.com\/avatar\/1b2d3e00a7df03689797ebd4af8c5827ba5af936849a71050ec331f4cf902c5d?s=96&d=mm&r=g\",\"caption\":\"\u79d1, \u96c5\"},\"url\":\"https:\/\/www.silicloud.com\/zh\/blog\/author\/keya\/\"},{\"@type\":\"ImageObject\",\"inLanguage\":\"zh-Hans\",\"@id\":\"https:\/\/www.silicloud.com\/zh\/blog\/centos7%e3%81%abphp5-6mysql5-7nginx1-8%e3%81%ae%e7%92%b0%e5%a2%83%e6%a7%8b%e7%af%89\/#local-main-organization-logo\",\"url\":\"\",\"contentUrl\":\"\",\"caption\":\"Blog - Silicon Cloud\"}]}<\/script>\n<!-- \/ Yoast SEO Premium plugin. -->","yoast_head_json":{"title":"CentOS7\u306bPHP5.6,MySQL5.7,Nginx1.8\u306e\u74b0\u5883\u69cb\u7bc9 - Blog - Silicon Cloud","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/www.silicloud.com\/zh\/blog\/centos7\u306bphp5-6mysql5-7nginx1-8\u306e\u74b0\u5883\u69cb\u7bc9\/","og_locale":"zh_CN","og_type":"article","og_title":"CentOS7\u306bPHP5.6,MySQL5.7,Nginx1.8\u306e\u74b0\u5883\u69cb\u7bc9","og_description":"\u306f\u3058\u3081\u306b MySQL\u306egeometry\u30ab\u30e9\u30e0\u3092\u4f7f\u3063\u3066\u307f\u305f\u304b\u3063\u305f\u306e\u3067\u3001Vagrant\u3067CentOS7,PHP5. [&hellip;]","og_url":"https:\/\/www.silicloud.com\/zh\/blog\/centos7\u306bphp5-6mysql5-7nginx1-8\u306e\u74b0\u5883\u69cb\u7bc9\/","og_site_name":"Blog - Silicon Cloud","article_published_time":"2024-01-20T08:31:50+00:00","article_modified_time":"2024-04-29T05:56:03+00:00","author":"\u79d1, \u96c5","twitter_card":"summary_large_image","twitter_misc":{"\u4f5c\u8005":"\u79d1, \u96c5","\u9884\u8ba1\u9605\u8bfb\u65f6\u95f4":"8 \u5206"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"WebPage","@id":"https:\/\/www.silicloud.com\/zh\/blog\/centos7%e3%81%abphp5-6mysql5-7nginx1-8%e3%81%ae%e7%92%b0%e5%a2%83%e6%a7%8b%e7%af%89\/","url":"https:\/\/www.silicloud.com\/zh\/blog\/centos7%e3%81%abphp5-6mysql5-7nginx1-8%e3%81%ae%e7%92%b0%e5%a2%83%e6%a7%8b%e7%af%89\/","name":"CentOS7\u306bPHP5.6,MySQL5.7,Nginx1.8\u306e\u74b0\u5883\u69cb\u7bc9 - Blog - Silicon Cloud","isPartOf":{"@id":"https:\/\/www.silicloud.com\/zh\/blog\/#website"},"datePublished":"2024-01-20T08:31:50+00:00","dateModified":"2024-04-29T05:56:03+00:00","author":{"@id":"https:\/\/www.silicloud.com\/zh\/blog\/#\/schema\/person\/41e222757cdd2a3365361328bd79970a"},"breadcrumb":{"@id":"https:\/\/www.silicloud.com\/zh\/blog\/centos7%e3%81%abphp5-6mysql5-7nginx1-8%e3%81%ae%e7%92%b0%e5%a2%83%e6%a7%8b%e7%af%89\/#breadcrumb"},"inLanguage":"zh-Hans","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.silicloud.com\/zh\/blog\/centos7%e3%81%abphp5-6mysql5-7nginx1-8%e3%81%ae%e7%92%b0%e5%a2%83%e6%a7%8b%e7%af%89\/"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/www.silicloud.com\/zh\/blog\/centos7%e3%81%abphp5-6mysql5-7nginx1-8%e3%81%ae%e7%92%b0%e5%a2%83%e6%a7%8b%e7%af%89\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"\u9996\u9875","item":"https:\/\/www.silicloud.com\/zh\/blog\/"},{"@type":"ListItem","position":2,"name":"CentOS7\u306bPHP5.6,MySQL5.7,Nginx1.8\u306e\u74b0\u5883\u69cb\u7bc9"}]},{"@type":"WebSite","@id":"https:\/\/www.silicloud.com\/zh\/blog\/#website","url":"https:\/\/www.silicloud.com\/zh\/blog\/","name":"Blog - Silicon Cloud","description":"","inLanguage":"zh-Hans"},{"@type":"Person","@id":"https:\/\/www.silicloud.com\/zh\/blog\/#\/schema\/person\/41e222757cdd2a3365361328bd79970a","name":"\u79d1, \u96c5","image":{"@type":"ImageObject","inLanguage":"zh-Hans","@id":"https:\/\/www.silicloud.com\/zh\/blog\/#\/schema\/person\/image\/","url":"https:\/\/secure.gravatar.com\/avatar\/1b2d3e00a7df03689797ebd4af8c5827ba5af936849a71050ec331f4cf902c5d?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/1b2d3e00a7df03689797ebd4af8c5827ba5af936849a71050ec331f4cf902c5d?s=96&d=mm&r=g","caption":"\u79d1, \u96c5"},"url":"https:\/\/www.silicloud.com\/zh\/blog\/author\/keya\/"},{"@type":"ImageObject","inLanguage":"zh-Hans","@id":"https:\/\/www.silicloud.com\/zh\/blog\/centos7%e3%81%abphp5-6mysql5-7nginx1-8%e3%81%ae%e7%92%b0%e5%a2%83%e6%a7%8b%e7%af%89\/#local-main-organization-logo","url":"","contentUrl":"","caption":"Blog - Silicon Cloud"}]}},"_links":{"self":[{"href":"https:\/\/www.silicloud.com\/zh\/blog\/wp-json\/wp\/v2\/posts\/34666","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.silicloud.com\/zh\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.silicloud.com\/zh\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.silicloud.com\/zh\/blog\/wp-json\/wp\/v2\/users\/4"}],"replies":[{"embeddable":true,"href":"https:\/\/www.silicloud.com\/zh\/blog\/wp-json\/wp\/v2\/comments?post=34666"}],"version-history":[{"count":2,"href":"https:\/\/www.silicloud.com\/zh\/blog\/wp-json\/wp\/v2\/posts\/34666\/revisions"}],"predecessor-version":[{"id":85679,"href":"https:\/\/www.silicloud.com\/zh\/blog\/wp-json\/wp\/v2\/posts\/34666\/revisions\/85679"}],"wp:attachment":[{"href":"https:\/\/www.silicloud.com\/zh\/blog\/wp-json\/wp\/v2\/media?parent=34666"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.silicloud.com\/zh\/blog\/wp-json\/wp\/v2\/categories?post=34666"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.silicloud.com\/zh\/blog\/wp-json\/wp\/v2\/tags?post=34666"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}