Welcome to WebmasterWorld Guest from

Forum Moderators: Ocean10000 & incrediBILL & phranque

Message Too Old, No Replies

Disable/bypass custom apache modules?

apache apache2 modules

5:05 pm on Feb 13, 2013 (gmt 0)

New User

joined:Feb 13, 2013
posts: 1
votes: 0

Hi all,
So I asked the question below on stackoverflow.com and serverfault.com and got NO responses. Maybe someone here is better :)

Question below:

I have an apache server running on an embedded device that serves webpages to clients using a bunch of custom modules.

I'm now trying to load some webpages from the device using []

These pages don't need any of the custom modules since they don't use any of their processing.

The problem is apache still runs through all the modules when loading the page and this causes the page to load very slowly even though it's coming from the local filesystem. I've tried using file: to retrieve the pages but then some pages don't display correctly because we are using jquery.

All the pages that don't need the modules are in a specific directory "foo" under the 'DocumentRoot'

I've tried putting checks in all the modules to disable the processing but it's still isn't good enough because it still runs through the modules.

Is there a way for me to add another module that makes a check and then stops all the rest from running?
Can this be done with AddHandler/RemoveHandler, mod_rewrite?
I've tried
<Location /foo>
SetHandler None

and that didn't work.

Can I make these files have a different extension like .fhtml and use that?

Other ideas?

We're running Apache/2.2.22 (Unix)
7:07 pm on Feb 20, 2013 (gmt 0)


WebmasterWorld Administrator coopster is a WebmasterWorld Top Contributor of All Time 10+ Year Member

joined:July 31, 2003
votes: 0

Welcome to WebmasterWorld, cvillone.

LoadModule only works in the context of server config which means it is going to either fire up the module or not. How the module is invoked is another story. For example, mod_rewrite is a directive specific to the rewrite module and is only invoked when the RewriteEngine is On, even though the module can be loaded at http server startup.

I would hope your custom modules would have a similar directive that allow you to invoke or not invoke the process accordingly. That's where I would start anyway.
1:03 am on Feb 21, 2013 (gmt 0)

Senior Member from US 

WebmasterWorld Senior Member lucy24 is a WebmasterWorld Top Contributor of All Time Top Contributors Of The Month

joined:Apr 9, 2011
votes: 244

I realize this is tangential to your question but this line worries me:

The problem is apache still runs through all the modules when loading the page and this causes the page to load very slowly...

Is there something special about your local pages that interacts with the modules to make the pages load slowly, while the ordinary, user-accessible pages aren't affected? Otherwise it sounds as if all pages load slowly all the time-- but for some reason this isn't a cause for concern. I really, really don't want to read the question as saying that slow performance is OK for the public but not for you ;)