By default, request timeout in Apache 2.4 is 60 seconds. If you want to increase request timeout in Apache, you will need to use the TimeOut directive. Here’s how to increase request timeout in Apache.
How to Increase Request Timeout in Apache
Here are the steps to increase request timeout in Apache.
1. Open Apache configuration file
Open Apache configuration file in a text editor. You will find the Apache server configuration file located at one of the following locations, depending on your installation.
$ sudo vi /etc/apache2/apache2.conf
If you have setup Apache virtual host, you can alternatively open virtual host file.
Bonus Read : How to Speed Up Apache Web Server
2. Increase Request Timeout in Apache
If you want to increase request timeout to 600 seconds, just add the following line to your Apache configuration file.
Bonus Read : How to Increase Apache Requests Per Second
3. Restart Apache Web Server
Restart Apache server to apply changes.
$ sudo service apache2 restart
$ sudo service httpd restart
Bonus Read : How to Install mod_wsgi on Ubuntu
Please note, sometimes it may be not enough to only increase request timeout in Apache. For example, if you are running a PHP site on your web server, you will also need to increase request timeout in php.ini file.