﻿<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>运维部落 &#187; php</title>
	<atom:link href="http://help.vps12.com/tag/php/feed" rel="self" type="application/rss+xml" />
	<link>https://help.vps12.com</link>
	<description>分享服务器运维及实践解决方案</description>
	<lastBuildDate>Sat, 25 Jan 2025 07:14:14 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.2.1</generator>
		<item>
		<title>phpMyadmin中import (最大限制：2,048 KB), 解决方法</title>
		<link>https://help.vps12.com/1603.html</link>
		<comments>https://help.vps12.com/1603.html#comments</comments>
		<pubDate>Tue, 05 Jul 2016 09:32:03 +0000</pubDate>
		<dc:creator>vps12.com</dc:creator>
				<category><![CDATA[解决方案]]></category>
		<category><![CDATA[Linux]]></category>
		<category><![CDATA[php]]></category>
		<category><![CDATA[vps12.com]]></category>

		<guid isPermaLink="false">http://help.vps12.com/?p=1603</guid>
		<description><![CDATA[解决方法： 找到php.ini搜索这3个地方 upload_max_filesize ， memory_limit 和 post_max_size 将他们后面的值修改成大于你需要导入的数据库大小就好了。 然后重启的PHP环境.]]></description>
		<wfw:commentRss>https://help.vps12.com/1603.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>双机高可用、负载均衡、MySQL(读写分离、主从自动切换)架构设计（转）</title>
		<link>https://help.vps12.com/1355.html</link>
		<comments>https://help.vps12.com/1355.html#comments</comments>
		<pubDate>Tue, 04 Aug 2015 17:25:16 +0000</pubDate>
		<dc:creator>vps12.com</dc:creator>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[解决方案]]></category>
		<category><![CDATA[软件使用]]></category>
		<category><![CDATA[mysql]]></category>
		<category><![CDATA[nginx]]></category>
		<category><![CDATA[php]]></category>
		<category><![CDATA[vps12.com]]></category>

		<guid isPermaLink="false">http://help.vps12.com/?p=1355</guid>
		<description><![CDATA[架构简介 前几天网友来信说帮忙实现这样一个架构：只有两台机器，需要实现其中一台死机之后另一台能接管这台机器的服务，并且在两台机器正常服务时，两台机器都能用上。于是设计了如下的架构。 此架构主要是由keepalived实现双机高可用，维护了一个外网VIP,一个内网VIP。正常情况时，外网VIP和内网VIP都绑定在server1服务器，web请求发送到server1的nginx，nginx对于静态资源请求就直接在本机检索并返回，对于php的动态请求，则负载均衡到server1和server2。对于SQL请求，会将此类请求发送到Atlas MySQL中间件，Atlas接收到请求之后，把涉及写操作的请求发送到内网VIP，读请求操作发送到mysql从，这样就实现了读写分离。 当主服务器server1宕机时，keepalived检测到后，立即把外网VIP和内网VIP绑定到server2，并把server2的mysql切换成主库。此时由于外网VIP已经转移到了server2，web请求将发送给server2的nginx。nginx检测到server1宕机，不再把请求转发到server1的php-fpm。之后的sql请求照常发送给本地的atlas，atlas把写操作发送给内网VIP，读操作发送给mysql从，由于内网VIP已经绑定到server2了，server2的mysql同时接受写操作和读操作。 当主服务器server1恢复后，server1的mysql自动设置为从，与server2的mysql主同步。keepalived不抢占server2的VIP，继续正常服务。 架构要求 要实现此架构，需要三个条件： 1、服务器可以设置内网IP，并且设置的内网IP互通; 2、服务器可以随意绑定IDC分配给我们使用的外网IP，即外网IP没有绑定MAC地址; 3、MySQL服务器支持GTID，即MySQL-5.6.5以上版本。 环境说明 server1 eth0: 10.96.153.110(对外IP) eth1: 192.168.1.100(对内IP) server2 eth0: 10.96.153.114(对外IP) eth1: 192.168.1.101(对内IP) 系统都是CentOS-6。 对外VIP: 10.96.153.239 对内VIP: 192.168.1.150 hosts设置 /etc/hosts: 192.168.1.100 server1 192.168.1.101 server2 Nginx PHP MySQL Memcached安装 这几个软件的安装推荐使用EZHTTP来完成。 解决session共享问题 php默认的session存储是在/tmp目录下，现在我们是用两台服务器作php请求的负载，这样会造成session分布在两台服务器的/tmp目录下，导致依赖于session的功能不正常。我们可以使用memcached来解决此问题。 上一步我们已经安装好了memcached，现在只需要配置php.ini来使用memcached，配置如下，打开php.ini配置文件，修改为如下两行的值： session.save_handler = memcache session.save_path = “tcp://192.168.1.100:11211,tcp://192.168.1.101:11211&#8243; 之后重启php-fpm生效。 Nginx配置 Server1配置 http { [...] upstream php-server [...]]]></description>
		<wfw:commentRss>https://help.vps12.com/1355.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>XAMPP php版本历史</title>
		<link>https://help.vps12.com/1226.html</link>
		<comments>https://help.vps12.com/1226.html#comments</comments>
		<pubDate>Sat, 17 Jan 2015 18:37:17 +0000</pubDate>
		<dc:creator>vps12.com</dc:creator>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[apache]]></category>
		<category><![CDATA[mysql]]></category>
		<category><![CDATA[php]]></category>
		<category><![CDATA[vps12.com]]></category>

		<guid isPermaLink="false">http://blog.vps12.com/?p=1226</guid>
		<description><![CDATA[XAMPP版本历史如图 http://code.stephenmorley.org/articles/xampp-version-history-apache-mysql-php/ XAMPP Apache MySQL PHP 5 PHP 4 1.8.1 2.4.3 5.5.27 5.4.7 1.8.0 2.4.2 5.5.25a 5.4.4 1.7.7 2.2.21 5.5.16 5.3.8 1.7.5 2.2.21 5.5.15 5.3.8 1.7.4 2.2.17 5.5.8 5.3.5 1.7.3 2.2.14 5.1.41 5.3.1 1.7.2 2.2.12 5.1.37 5.3.0 1.7.1 2.2.11 5.1.33 5.2.9 1.7.0 2.2.11 5.1.30 5.2.8 1.6.8 2.2.9 5.0.67 5.2.6 4.4.9 1.6.7 2.2.9 5.0.51b 5.2.6 4.4.8 [...]]]></description>
		<wfw:commentRss>https://help.vps12.com/1226.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Windows下的PHP安装文件线程安全和非线程安全的区别</title>
		<link>https://help.vps12.com/1202.html</link>
		<comments>https://help.vps12.com/1202.html#comments</comments>
		<pubDate>Tue, 25 Nov 2014 12:49:16 +0000</pubDate>
		<dc:creator>vps12.com</dc:creator>
				<category><![CDATA[网络产品]]></category>
		<category><![CDATA[软件使用]]></category>
		<category><![CDATA[iis]]></category>
		<category><![CDATA[mysql]]></category>
		<category><![CDATA[php]]></category>
		<category><![CDATA[vps12.com]]></category>
		<category><![CDATA[台湾vps]]></category>
		<category><![CDATA[日本vps]]></category>
		<category><![CDATA[服务器]]></category>
		<category><![CDATA[美国vps]]></category>
		<category><![CDATA[香港vps]]></category>

		<guid isPermaLink="false">http://blog.vps12.com/?p=1202</guid>
		<description><![CDATA[从2000年10月20日发布的第一个Windows版的PHP3.0.17开始的都是线程安全的版本，这是由于与Linux/Unix系统是采用 多进程的工作方式不同的是Windows系统是采用多线程的工作方式。如果在IIS下以CGI方式运行PHP会非常慢，这是由于CGI模式是建立在多进程 的基础之上的，而非多线程。一般我们会把PHP配置成以ISAPI的方式来运行，ISAPI是多线程的方式，这样就快多了。但存在一个问题，很多常用的 PHP扩展是以Linux/Unix的多进程思想来开发的，这些扩展在ISAPI的方式运行时就会出错搞垮IIS。而用线程安全版本的话顶多只是搞跨某个 线程，而不会影响到整个IIS的安全。 当然在IIS下CGI模式才是 PHP运行的最安全方式，但CGI模式对于每个HTTP请求都需要重新加载和卸载整个PHP环境，其消耗是巨大的。为了兼顾IIS下PHP的效率和安全， 有人给出了FastCGI的解决方案。FastCGI可以让PHP的进程重复利用而不是每一个新的请求就重开一个进程。同时FastCGI也可以允许几个 进程同时执行。这样既解决了CGI进程模式消耗太大的问题，又利用上了CGI进程模式不存在线程安全问题的优势。 因此，如果是使用ISAPI的方式来运行PHP就必须用Thread Safe(线程安全)的版本；而用FastCGI模式运行PHP的话就没有必要用线程安全检查了，用None Thread Safe(NTS，非线程安全)的版本能够更好的提高效率。 因此，如果是使用ISAPI的方式来运行PHP就必须用Thread Safe(线程安全)的版本；而用FastCGI模式运行PHP的话就没有必要用线程安全检查了，用None Thread Safe(NTS，非线程安全)的版本能够更好的提高效率。 附：德问相关问题摘录 下载PHP安装文件时，我看到有两种不同的二进制文件，像是非线程安全（Non Thread Safe）和线程安全（Thread Safe），比如该页面所列：http://windows.php.net/download/。这个是什么意思，之间有什么区别？ 这个主要是针对web server 而言，在windows环境下，如果你使用的web server 是apchae 或者 iis 7以下版本，则应该选择线程安全的安装文件，而如果你使用Fast-cgi模式时，可以选择非线程安全，因为 web sever 本身能保证线程安全。 当然还有二进制文件编译时所使用的编译器：vc9 (vs系列) vc6(gcc) 如楼上所言，是针对web server的，部分web server在处理应用请求的时候是用多线程而非多进程的方式处理，线程方式因为涉及到共享寄存器和内存，所以很容易出错，这个时候程序就需要花一些额外的经历去处理寄存器中的数据一致性，即保证线程安全。 所以是否采用线程安全主要看你的web server所采用的PHP请求处理方式，如果是多线程处理，那么请选择线程安全的，否则选择非线程安全的，如楼上所说Fast-cgi方式可选择非线程安全的]]></description>
		<wfw:commentRss>https://help.vps12.com/1202.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>PHP在64位Win2003和IIS下运行设置方法</title>
		<link>https://help.vps12.com/851.html</link>
		<comments>https://help.vps12.com/851.html#comments</comments>
		<pubDate>Tue, 07 May 2013 11:48:17 +0000</pubDate>
		<dc:creator>vps12.com</dc:creator>
				<category><![CDATA[解决方案]]></category>
		<category><![CDATA[iis]]></category>
		<category><![CDATA[php]]></category>
		<category><![CDATA[vps12.com]]></category>
		<category><![CDATA[台湾vps]]></category>
		<category><![CDATA[日本vps]]></category>
		<category><![CDATA[服务器]]></category>
		<category><![CDATA[服务器安全]]></category>
		<category><![CDATA[美国vps]]></category>
		<category><![CDATA[香港vps]]></category>

		<guid isPermaLink="false">http://blog.vps12.com/?p=851</guid>
		<description><![CDATA[环境是windows 2003 sp2 企业版 64位 iis配置好PHP之后居然出现错误信息: %1 不是有效的 Win32 应用程序。 说这不是一个有效的win32程序&#8230; 解决办法： 由于系统是64位的..只好将IIS改为32位的工作模式。 于是找到了这条命令,详情参见微软官方的帮助文档： Configuring IIS to Run 32-bit Applications on 64-bit Windows (IIS 6.0): cscript.exe adsutil.vbs set W3SVC/AppPools/Enable32BitAppOnWin64 “true” 或者 cscript %SYSTEMDRIVE%\inetpub\adminscripts\adsutil.vbs SET W3SVC/AppPools/Enable32bitAppOnWin64 1 //这是一行命令！！切勿当成2条语句执行上面的命令是将将IIS由64位模式修改为32位模式。 更改完模式之后然后按照32位系统配置php即可 操作完成后支行 iisreset 重启iis 生效 如果你要从32位改为64位的.也只需要一个命令 cscript %SYSTEMDRIVE%\inetpub\adminscripts\adsutil.vbs SET W3SVC/AppPools/Enable32bitAppOnWin64 0 //这是一行命令..切勿当成2条语句执行 当然,在更改完之后,PHP是无法运行的了,.NET运行的的话,就需要重新注册一次 32位：%SYSTEMROOT%\Microsoft.NET\Framework\v2.0.40607\aspnet_regiis.exe -i 64位：%SYSTEMROOT%\Microsoft.NET\Framework64\v2.0.40607\aspnet_regiis.exe -i]]></description>
		<wfw:commentRss>https://help.vps12.com/851.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>php扩展php_curl.dll不加载解决方法</title>
		<link>https://help.vps12.com/846.html</link>
		<comments>https://help.vps12.com/846.html#comments</comments>
		<pubDate>Thu, 02 May 2013 18:38:28 +0000</pubDate>
		<dc:creator>vps12.com</dc:creator>
				<category><![CDATA[解决方案]]></category>
		<category><![CDATA[php]]></category>
		<category><![CDATA[vps12.com]]></category>
		<category><![CDATA[台湾vps]]></category>
		<category><![CDATA[日本vps]]></category>
		<category><![CDATA[美国vps]]></category>
		<category><![CDATA[香港vps]]></category>

		<guid isPermaLink="false">http://blog.vps12.com/?p=846</guid>
		<description><![CDATA[方法一（已通过测试）已经内置有php_curl.dll,在ext目录下,此DLL用于支持SSL和zlib. 在php.ini中找到有extension=php_curl.dll, 去掉前面的注释. 设置extension_dir=c:\php\ext, 刷新PHP页面时报错, 说找不到模块php_curl.dll. 拷贝php_curl.dll 到windows\system32,还是同样的错. 在网上找了一下,需要将: libeay32.dll, ssleay32.dll, php5ts.dll, php_curl.dll 都拷贝到system32目录下,重启apache即可. 方法二也可试试： 这个php_curl.dll就依赖两个文件（ssleay32.dll和libeay32.dll）如果这两个文件没有配置对那么就会提示找不到此动态库，这两个文件在php的目录下面。 解决办法：在Apache的httpd.conf的文件中配置一下： LoadFile “D:/webserver/php/ssleay32.dll” LoadFile “D:/webserver/php/libeay32.dll” 然后重启一下apache服务就ok了。 ps:不管是iis还是apache，直接复制以上三个dll文件到system32目录下一般就可以解决问题。反正这三个文件是一定要在一起才生效。不然不行。]]></description>
		<wfw:commentRss>https://help.vps12.com/846.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>iis下进行伪静态配置时提示系统找不到指定的文件的解决办法</title>
		<link>https://help.vps12.com/592.html</link>
		<comments>https://help.vps12.com/592.html#comments</comments>
		<pubDate>Sun, 25 Nov 2012 14:34:44 +0000</pubDate>
		<dc:creator>vps12.com</dc:creator>
				<category><![CDATA[解决方案]]></category>
		<category><![CDATA[php]]></category>
		<category><![CDATA[vps12.com]]></category>
		<category><![CDATA[伪静态]]></category>
		<category><![CDATA[服务器]]></category>
		<category><![CDATA[服务器安全]]></category>

		<guid isPermaLink="false">http://blog.vps12.com/?p=592</guid>
		<description><![CDATA[出现的情况： windows2003系统iis6环境安装了静态化插件，配置wp及dzbbs时，老显示系统找不到指定的文件。空间是支持伪静态的，其他的网站可正确使用，这个是什么原因？查找了半天。以为是规则文件不对，但确认规则文件正确后，重启iis，还是如此。 查找原因： iis下进行伪静态配置时提示系统找不到指定的文件的原因基本可以确认为以下几个： 1、检查是否成功添加Helicon目录权限。 2、检查是否成功添加你需要伪静态站点的目录权限。 3、是否重启过IIS。 4、是否有在IIS整个网站中删除ISAPI_Rewrite3，如果没有，重复应用了，也会有冲突。 解决问题： 经查iis网站所在目录少配置了权限NETWORK SERVICE！加入读取和写入权限。问题解决。]]></description>
		<wfw:commentRss>https://help.vps12.com/592.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>asp及php的url跳转代码实现</title>
		<link>https://help.vps12.com/517.html</link>
		<comments>https://help.vps12.com/517.html#comments</comments>
		<pubDate>Sat, 10 Nov 2012 17:50:05 +0000</pubDate>
		<dc:creator>vps12.com</dc:creator>
				<category><![CDATA[编程实践]]></category>
		<category><![CDATA[asp]]></category>
		<category><![CDATA[php]]></category>
		<category><![CDATA[vps12.com]]></category>
		<category><![CDATA[服务器]]></category>
		<category><![CDATA[服务器安全]]></category>
		<category><![CDATA[跳转]]></category>

		<guid isPermaLink="false">http://blog.vps12.com/?p=517</guid>
		<description><![CDATA[php语言环境下的跳转 ?View Code PHP1 2 3 4 &#60;?php header&#40;&#34;HTTP/1.1 301 Moved Permanently&#34;&#41;; header&#40;&#34;Location: http://www.vps12.com/&#34;&#41;; ?&#62; asp语言环境下的跳转 ?View Code ASP1 2 3 4 5 6 &#60;%@ Language=VBScript %&#62; &#60;% Response.Status=&#34;301 Moved Permanently&#34; Response.AddHeader &#34;Location&#34;, &#34; http://www.vps12.com/&#34; Response.End %&#62;]]></description>
		<wfw:commentRss>https://help.vps12.com/517.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>配置基于Windows2003集成环境IIS+Php+Mysql+Zend+Rewrite+Gzip+asp+.net+n点虚拟主机管理系统(图文)</title>
		<link>https://help.vps12.com/487.html</link>
		<comments>https://help.vps12.com/487.html#comments</comments>
		<pubDate>Sun, 04 Nov 2012 05:07:29 +0000</pubDate>
		<dc:creator>vps12.com</dc:creator>
				<category><![CDATA[VPS新手指南/教程]]></category>
		<category><![CDATA[.net]]></category>
		<category><![CDATA[iis]]></category>
		<category><![CDATA[mysql]]></category>
		<category><![CDATA[php]]></category>
		<category><![CDATA[vps]]></category>
		<category><![CDATA[vps12.com]]></category>
		<category><![CDATA[zend]]></category>
		<category><![CDATA[服务器]]></category>

		<guid isPermaLink="false">http://blog.vps12.com/?p=487</guid>
		<description><![CDATA[经常大家在使用vps及服务器时需要对一些环境进行配置，比如要在win在运行php及asp或是.net的网站，那么这么复杂的配置对一个新接触服务器管理的亲手来讲，的确有些复制，那么为了更好的服务于大家，本文以新手安装方式来建立配置基于Windows2003集成环境： IIS+Php+Mysql+Zend+Rewrite+asp+.net+n点虚拟主机管理系统 我们从0开始，一步步建立。当我们拿到一台新的服务器或是vps时，以干净的系统为基础。一步步来操作： 一、准备工作： 1.首先我们先要确认一下我们需要安装的最基础也是最重要的iis是否有安装文件！！一般默认情况下安装系统的提供商都会给于安装文件如i386。以我们vps12.com提供给客户的环境为例。是放在c:\i386目录。可以在安装时直接调用。 2.确认下其他的软件是否下载好了。本文需要安装使用的软件有以下： 1 iis安装文i386(也有其他爱好者分享出来的专用iis6的安装文件也可以) 2 asp.net2.0 3 Rewrite for iis插件（伪静态组件） 4 n点虚拟主机管理系统 5 php for windows 6 mysql for windows 7 zend for windows 8 serv-u (ftp服务端) ps:其中5-8软件我们用最容易的方式操作安装。要用到个软件 小骑士。是本着最为简化方式安装配置。以最快捷傻瓜式安装。 3.开始安装iis 开始 -&#62; 设置 -&#62; 控制面板 -&#62; 添加或删除程序 -&#62; 添加删除windows组件，然后找到 应用程序服务器 按如图所未勾选组件。 注意这边有个小的细节就是可以直接勾asp.net这个。然后再勾最后一个。这样就可以了。其他不要勾。 然后会提示没有文件要指定地址。然后我们选择一下 c:\i386 ，复制文件完成后。iis这样就安装完了。 详细步骤请参考图文教程：如何安装IIS  http://help.vps12.com/386.html 4. 安装asp.net 2.0 这个不用说。很容易。没有细节上的东西要注意，一直下一步就安装完成了。 [...]]]></description>
		<wfw:commentRss>https://help.vps12.com/487.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>php.ini中文版注释</title>
		<link>https://help.vps12.com/238.html</link>
		<comments>https://help.vps12.com/238.html#comments</comments>
		<pubDate>Sat, 12 Nov 2011 05:20:46 +0000</pubDate>
		<dc:creator>vps12.com</dc:creator>
				<category><![CDATA[网络产品]]></category>
		<category><![CDATA[软件使用]]></category>
		<category><![CDATA[iis]]></category>
		<category><![CDATA[Linux]]></category>
		<category><![CDATA[php]]></category>
		<category><![CDATA[vps12.com]]></category>
		<category><![CDATA[web]]></category>
		<category><![CDATA[台湾vps]]></category>
		<category><![CDATA[日本vps]]></category>
		<category><![CDATA[服务器]]></category>
		<category><![CDATA[美国vps]]></category>
		<category><![CDATA[香港vps]]></category>

		<guid isPermaLink="false">http://blog.vps12.com/?p=238</guid>
		<description><![CDATA[php.ini 是php语言环境中最为重要的配置文件。以下我们就来详细介绍一下参数及功能： ?View Code CODE1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 [...]]]></description>
		<wfw:commentRss>https://help.vps12.com/238.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
