There is a Linux Server running redhat and PHP 5.1.6 and a Windows Server for SQL 2005.
On the last weeks the application started to return eventually mssql_connect erros, saying server is unavailable.
There is no network instability that we could map.
We've tried to replace mssql_connect with mssql_pconnect, but then the erros returned eventually were on mssql_select_db instead of mssql_connect.
I've discovered that PHP 5.1 added a new parameter [, bool $new_link ] on both mssql_connect and mssql_pconnect.
Documantation for new_link says:
What is the best technique recommended to connect to SQL Server for a production server?If a second call is made to mssql_connect() with the same arguments, no new link will be established, but instead, the link identifier of the already opened link will be returned. This parameter modifies this behavior and makes mssql_connect() always open a new link, even if mssql_connect() was called before with the same parameters.
- mssql_connect or mssql_pconnect?
- new_link = true ou new_link = false?