Jump to content

Recommended Posts

Hi, I'm a newbie here, and also in PHP.

 

Sorry for my bad English. I've walked around to find the answer of my problem, but I still can't get it.

 

I develop PHP 5.2.5 Application, using SQL Server 2005 database, and run in IIS 6.0[/img].

I also use PHP SQL Server 2005 driver provides by microsoft.

My database is placed in another server.

My application is used by almost 30-40 users at the same time.

If the application is used by few users, the application works smoothly.

But, if the application is used by a lot of users (around 30), it suddenly down and show this error..

 

Unable to connect x.x.x.x Array ( [0] => Array ( [0] => 08001 [sqlSTATE] => 08001 [1] => 2 [code] => 2 [2] => [Microsoft][sql Native Client]Named Pipes Provider: Could not open a connection to SQL Server [2]. [message] => [Microsoft][sql Native Client]Named Pipes Provider: Could not open a connection to SQL Server [2]. ) [1] => Array ( [0] => HYT00 [sqlSTATE] => HYT00 [1] => 0 [code] => 0 [2] => [Microsoft][sql Native Client]Login timeout expired [message] => [Microsoft][sql Native Client]Login timeout expired ) [2] => Array ( [0] => 08001 [sqlSTATE] => 08001 [1] => 2 [code] => 2 [2] => [Microsoft][sql Native Client]An error has occurred while establishing a connection to the server. When connecting to SQL Server 2005, this failure may be caused by the fact that under the default settings SQL Server does not allow remote connections. [message] => [Microsoft][sql Native Client]An error has occurred while establishing a connection to the server. When connecting to SQL Server 2005, this failure may be caused by the fact that under the default settings SQL Server does not allow remote connections. ) )

 

FYI, there is also another application , developed by my friend, in the same server who use the same SQL Server. When my application shows the error above, his application shows the same error. So I conclude, the error in the database.

 

If this happen, I restart the IIS and it backs to normal.

 

I guess there is something wrong with the max connection that SQL Server 2005 can accept. I assume that because I use the transaction..

 

   //start transaction
     ---> process
  //end transaction

 

Maybe, because of the long process, and also the amount of user that use the same page, the database reach max limit and then down.

 

I don;t know how to checked whether the database has reach max connection. I've checked the max connection that's allowed and it use default value (unlimited).

 

The problem makes me headache. The application has lived and I must solved this problem quickly..

 

Could anyone help me? Thanks before...     

 

Link to comment
https://forums.phpfreaks.com/topic/148783-sql-server-suddenly-downed/
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.