PHP5.3働いていないとMySQL5.1IIS7時out
質問
ってPHP5.3,MySQL5.1IIS7窓7phpされていないワイナリを使用しています。思想で設定エラーや不完全なインストールマです。
- MySQL5.1組
- PHP5.3は、phpinfo()を示す情報として有効にMySQL
- IISのワンストップを使用fastCgiModule行PHP
- IISレジスタはクリアしました。ini更新
- ポートは3306ファイアウォールの自由で開かれる世界
- クリアしました。iniが正しく構成され
- されていc:\php のWindowsシステムのパス
過去の思い出の可動ファイルlibmysql.dllは、System32かんのいらっしゃるphp5.3.1、ドライバーが内蔵今 http://us3.php.net/manual/en/mysqlnd.install.php.
(これんかくして記録私の成果を自分のブログとして http://inteldesigner.com/2010/code/having-problems-getting-php5-3-to-work-with-mysql5-1 )
必要:
- いる必要がありPHP手作業で行わない使用にインストーラまたは古いバージョン
- さんPHP5.3作MySQL5.1かをインストールできWordpress2.9Drupal7a
リンクの提供するというものiis webサイトにあります。私は推測して更新されない新しいソフトウェアです。
バグ-ソリューション:
の溶液はこちら: http://bugs.php.net/bug.php?id=50172 へのから、全国で上映されます。ラマンのiis.net フォーラム http://forums.iis.net/p/1164911/1933894.aspx
症状:
Phpの機能 mysql_connect()
とphp5.3ロックのサーバがエラーを返します500.(IPv6があるので上記を参照リンク)
コード試験:
<?php
$con = mysql_connect("localhost","root","***");
if (!$con)
{
die('Could not connect: ' . mysql_error());
}
// some code
mysql_close($con);
?>
誤差:
ブラウザから:
HTTP Error 500.0 - Internal Server Error
C:\php\php-cgi.exe - The FastCGI process exceeded configured activity timeout
する活動を行う意欲 php -f c:\public_html\index.php
コマンドラインからん:
PHP Warning: mysql_connect(): [2002] A connection attempt failed because the co
nnected party did not (trying to connect via tcp://localhost:3306) in C:\public
_html\index.php on line 10
Warning: mysql_connect(): [2002] A connection attempt failed because the connect
ed party did not (trying to connect via tcp://localhost:3306) in C:\public_html
\index.php on line 10
PHP Warning: mysql_connect(): A connection attempt failed because the connected
party did not properly respond after a period of time, or established connectio
n failed because connected host has failed to respond.
in C:\public_html\index.php on line 10
Warning: mysql_connect(): A connection attempt failed because the connected part
y did not properly respond after a period of time, or established connection fai
led because connected host has failed to respond.
in C:\public_html\index.php on line 10
Could not connect: A connection attempt failed because the connected party did n
ot properly respond after a period of time, or established connection failed bec
ause connected host has failed to respond.
C:\Users\Kevin>
解決
don.ramanは書いてます:
http://bugs.php.net/bug.phpを見てください?このように、解像度のid = 50172 の
別の方法としては、この動作を持たないPHP 5.2.12を使用することです。
私が見つけたそれ http://forums.iis.net/p/1164911/ 1933894.aspx とそれについて投稿します。
他のヒント
私は、Windows 7 / Apacheの/ MySQLでmy_sql_connectエラーが発生しました。 「127.0.0.1」から「ローカルホスト」から変更ホストパラメータも私のために働いています。
(あなたはすぐにそのIPアドレスを検索したい場合は、コマンドプロンプトから型「のping」)また、他のホストのためだけのIPアドレスの代わりにホスト名を使用します。
い:
- へ
C://Windows/System32/drivers/etc
- 編集ファイルと呼ばれ
host
きんいただくには十分な権限を編集すので、右クリックしていくプロパティ->セキュリティ->編集を選択し、ユーザーご利用されているアカウントを完全に制御でをクリックする完全な制御をチェックを入れると、以下の者に適用される。>Ok
Open host
ファイルをメモ帳またはその他のANSI標準テキストエディタ、strncasecmpの線 # 127.0.0.1 localhost
を取り除 #
て保存してください。