Is it safe to assume, that nothing gets broken after enabling an apache module? For example, I want to enable mod_headers
on production server, but I'm afraid it can break something, perhaps because it can interact with other modules or because of any other reason?
Asked
Active
Viewed 71 times
4

Alex Lomia
- 143
- 4
-
2Not if you have a dev/staging environment! – ceejayoz Jul 27 '16 at 13:47
-
@ceejayoz Thanks for a reply. In what cases enabling a new module might break something? I imagine the modules being 'standalone' pieces, am I wrong? – Alex Lomia Jul 27 '16 at 13:52
-
2Agree, not much use specifying something as production if there is no staging. That said, a little more info would be helpful, why this module? caches and timeouts? if so thats most likely where there will be more issues. Enabling the module rarely has serious problems in my experience its when you start to configure something unfamiliar is when it will break things. – cormpadre Jul 27 '16 at 13:53
-
1As an example: enabling something like `mod_security` might break a web application with the default rules. Your config may have existing but currently-ignored `
` calls for the new module that result in a bad config. Enabling mod_php's PHP7 might break your site if it was written for PHP5. etc. etc. etc. – ceejayoz Jul 27 '16 at 13:53 -
Ultimately, if your app can't weather a few minutes of downtime while you frantically undo what you enabled in the config, it needs a staging server. – ceejayoz Jul 27 '16 at 13:55
-
@ceejayoz I'm dealing with legacy systems with tons of outdated code on them and frankly, don't know much about server configuration yet. This area is like a black box filled with magic to me yet, hence the noob questions without much details – Alex Lomia Jul 27 '16 at 13:57
-
@AlexanderLomia Definitely have been there. If at all possible, figure out a way to clone the server to a local install so you can tinker at will. – ceejayoz Jul 27 '16 at 14:00
-
@ceejayoz Thanks for an excellent advice, will try to do just that – Alex Lomia Jul 27 '16 at 14:03
1 Answers
2
Your assumption that loading Apache modules will not break anything is wrong. A simple counterexample would be:
<IfModule module_safe>
# Break things for fun and profit.
</IfModule>
Assuming that module_safe
is perfectly fine, your configuration can still change on Loading that module.

M. Glatki
- 1,964
- 1
- 17
- 33