|
I have web321 server. I want to use mysql_pconnect connection string for my mysql database. If increasing number of connections is not possible it's okey for me but i need persistent mysql conection. Can i do so? Thanks in advance. |
|
Hi, Yes, persistent connections are allowed. First of all thanks a lot for your reply. I am not able to use persistent connection. The table that i am using is a temporary table and table type is MEMORY. When the page loads i create a table using statement CREATE TEMPORARY TABLE [columns]) ENGINE = MEMORY or MYISAM. It works fine first time when the page loads but when i try to query same table through ajax on button click i get mysql error 'table<xyz> dosen't exist'. I believe it is related to mysql connection because it breaks?? or it is something related to PHP?Your help will be greatly appreciated. Regards. If you're using PHP with the shared Apache instance, this probably won't work since PHP is working as CGI. With CGI, every new request is launched in its own process, so the information from the previous request (process) is destroyed. In other words, using persistent connections over CGI is pointless, as those connections don't actually persist. If you want to use PHP with persistent connections, you would have to install your own web server (for example, Apache with mod_php) and use that instead of the shared Apache. That make sense. So should i ask webfaction if they can have apache module enabled for my account? Is it possible to do it per connection basis? Thanks for your help. Sorry, we don't have PHP as an Apache module running on the shared Apache instance. You'd have to build your own Apache for this. Okey i got it. Please tell me if it will be a long and hard process to build apache from the source on webfaction server? will i have to build php5 and mysql from the source and connect them to apache again with all the configuration options for each libraries? What other libraries will i have to install with apache?
Currently I have two websites on webfaction server, will this change affact all of them? i just want apache with mode_php for only one website & not for other.
Can you please provide me any doc how to do this or any help? It seems to be long process!!! Hi again, Actually, you might be able to use the Apache server that is already installed, and just build mod_php in your account. You can then start the server using "/usr/sbin/httpd -f ~/httpd.conf" to specify your own config file for the Apache server. It is not a very straightforward process, so if you run into any troubles, feel free to open a ticket at our support site.
showing 5 of 6
show all
|