Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum. |
Notices |
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
Are you new to LinuxQuestions.org? Visit the following links:
Site Howto |
Site FAQ |
Sitemap |
Register Now
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
|
 |
10-09-2003, 06:26 PM
|
#1
|
Senior Member
Registered: Nov 2001
Location: Budapest, Hungary
Distribution: SuSE 6.4-11.3, Dsl linux, FreeBSD 4.3-6.2, Mandrake 8.2, Redhat, UHU, Debian Etch
Posts: 1,126
Rep:
|
Timeout after 30s (apache+php+postgreSQL)
The execution of my php script doing database queries is interrupted by a "Error: timeout on server" message or something like that after 30s, though I already made the following changes to avoid such timeouts:
1. inserted 'set_time_limit(360)' at the beginning of the script,
2. set 'max_execution_time=300' and 'max_input_time=600' in php.ini,
3. set 'Timeout 300' in httpd.conf, and restarted apache (apachectl restart)
Is there something I missed? Why my requests keep timing out?
Last edited by J_Szucs; 10-09-2003 at 07:13 PM.
|
|
|
10-09-2003, 06:55 PM
|
#2
|
Member
Registered: May 2003
Location: Brazil
Distribution: Gentoo
Posts: 81
Rep:
|
Wasn't the timeout on the PostgreSQL server?
|
|
|
10-09-2003, 07:23 PM
|
#3
|
Senior Member
Registered: Nov 2001
Location: Budapest, Hungary
Distribution: SuSE 6.4-11.3, Dsl linux, FreeBSD 4.3-6.2, Mandrake 8.2, Redhat, UHU, Debian Etch
Posts: 1,126
Original Poster
Rep:
|
Quote:
Wasn't the timeout on the PostgreSQL server?
|
I do not think so, since I could not find any timeout settings in postgresql.conf.
Besides, if there were any limitation on the runtime of a query or PostgreSQL connection, I do not think it would be as short as 30s (I think an SQL query is reasonably allowed to run for several minutes by default).
Last edited by J_Szucs; 10-09-2003 at 07:24 PM.
|
|
|
10-10-2003, 03:26 AM
|
#4
|
Senior Member
Registered: Nov 2001
Location: Budapest, Hungary
Distribution: SuSE 6.4-11.3, Dsl linux, FreeBSD 4.3-6.2, Mandrake 8.2, Redhat, UHU, Debian Etch
Posts: 1,126
Original Poster
Rep:
|
Wow!
I tried it from within the LAN, and there is no 30s timeout!
So the timeout I experienced from home was either due to the fact that I connected to the server from the outside of our LAN, or maybe my efforts to sighup apache took effect after some hours of delay.
When I connect to the server from the outside I do it through a natd port forward on the firewall, and a stunnel between the http and https ports. I already checked stunnel, there is no 30s timeout (only a 300s one). A 30s timeout in natd seems unlikely, too.
So I am still puzzled...
Last edited by J_Szucs; 10-10-2003 at 05:16 AM.
|
|
|
10-10-2003, 01:30 PM
|
#5
|
Senior Member
Registered: Nov 2001
Location: Budapest, Hungary
Distribution: SuSE 6.4-11.3, Dsl linux, FreeBSD 4.3-6.2, Mandrake 8.2, Redhat, UHU, Debian Etch
Posts: 1,126
Original Poster
Rep:
|
The timeout is still there from the outside.
So:
ipfw + natd +stunnel + apache + php + postgresql = 30s timeout
stunnel + apache + php + postgresql = no 30s timeout
It seems that it has something to do with the firewall or natd.
|
|
|
06-07-2015, 11:01 PM
|
#6
|
LQ Newbie
Registered: Jun 2015
Posts: 2
Rep: 
|
Quote:
Originally Posted by J_Szucs
The timeout is still there from the outside.
So:
ipfw + natd +stunnel + apache + php + postgresql = 30s timeout
stunnel + apache + php + postgresql = no 30s timeout
It seems that it has something to do with the firewall or natd.
|
How did you resolve this? I might be encountering the same issue.
|
|
|
06-07-2015, 11:06 PM
|
#7
|
Moderator
Registered: Oct 2008
Distribution: Slackware [64]-X.{0|1|2|37|-current} ::12<=X<=15, FreeBSD_12{.0|.1}
Posts: 6,366
|
You have replied to a 12 year old thread!
You would do much better to open your own thread and provide the information relevant to your own system.
And welcome to LQ!
|
|
|
All times are GMT -5. The time now is 09:37 AM.
|
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.
|
Latest Threads
LQ News
|
|