Keep Server Online
If you find the Apache Lounge, the downloads and overall help useful, please express your satisfaction with a donation.
or
A donation makes a contribution towards the costs, the time and effort that's going in this site and building.
Thank You! Steffen
Your donations will help to keep this site alive and well, and continuing building binaries. Apache Lounge is not sponsored.
| |
|
Topic: mod_rewrite and permalink Make Server Load >60 and Site D |
|
Author |
|
smsm3650
Joined: 02 Jul 2015 Posts: 2
|
Posted: Thu 02 Jul '15 16:20 Post subject: mod_rewrite and permalink Make Server Load >60 and Site D |
|
|
I use permalink in my Site .. To enable it .. I enabled mod_rewrite in htaccess by adding this code
Code: |
# BEGIN WordPress
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteRule ^index\.php$ - [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
## RewriteRule . /index.php [L]
</IfModule>
|
But Once I Remove Comment Makr ( # ) from ( RewriteRule . /index.php [L] ) .. Server Load Get very high up to 60 and site Down .. So how Can i fix this ?
I Have CENTOS 6.6 x86_64 with Apache/2.2.29 |
|
Back to top |
|
James Blond Moderator

Joined: 19 Jan 2006 Posts: 7402 Location: EU, Germany, Next to Hamburg
|
Posted: Thu 02 Jul '15 16:28 Post subject: |
|
|
You can set AllowOverride to none and
put the config into the vhost config.
the new default wordpress rewriting is ( put it in the <Directory> block from your document root)
Code: |
AddDefaultCharset UTF-8
# BEGIN WordPress
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteRule ^index\.php$ - [L]
# add a trailing slash to /wp-admin
RewriteRule ^wp-admin$ wp-admin/ [R=301,L]
RewriteCond %{REQUEST_FILENAME} -f [OR]
RewriteCond %{REQUEST_FILENAME} -d
RewriteRule ^ - [L]
RewriteRule ^(wp-(content|admin|includes).*) $1 [L]
RewriteRule ^(.*\.php)$ $1 [L]
RewriteRule . index.php [L]
</IfModule>
# END WordPress
</Directory>
|
You may try that. If you still have such a high load you may install a plugin like w3 total cache to reduse the impact to a minimum. |
|
Back to top |
|
smsm3650
Joined: 02 Jul 2015 Posts: 2
|
Posted: Thu 02 Jul '15 22:26 Post subject: |
|
|
WOOOOOOOOOOOW WOOOOOOOOOOOOOOW ... MORE THAN EXPECTED ... Ultra greattttttttttttte Bro ... you know ..
My site Hanging due to this more than 2 time / week .. From More than 3 Years Ago I Troubleshooting by Changing PHP Handler and Rebuild Apache .. But You Solved it By that Magic Code ... THAAAAAAAAAAAAAAAAAANKS as much as i cannot say |
|
Back to top |
|
James Blond Moderator

Joined: 19 Jan 2006 Posts: 7402 Location: EU, Germany, Next to Hamburg
|
Posted: Wed 08 Jul '15 23:00 Post subject: |
|
|
You are welcome |
|
Back to top |
|
|
|
|
|
|