Apache HTTP Server /etc/apache2/mods-available/cache_disk.conf

Original ๐Ÿ“‹ Ubuntu 24.04 LTS (Noble Numbat) 21 lines

Works On

Viewing:
Ubuntu 24.04 LTS (Noble Numbat)
Same on:
Debian 13 (Trixie)
Other versions:

Details

Size
21 lines
MD5
0b2be6d48bbad8b4e32eef623e3670bc
SHA256
a0cf0f931e50437b21971157eee69f8daf8d9fe6d420e16cd11f601c26562014

Copy & Paste

curl:
curl https://exampleconfig.com/api/v1/config/original/0b2be6d48bbad8b4e32eef623e3670bc?hint=cache_disk.conf
wget:
wget -O cache_disk.conf https://exampleconfig.com/api/v1/config/original/0b2be6d48bbad8b4e32eef623e3670bc?hint=cache_disk.conf

For AI Agents

You are a DevOps agent. Fetch the default Apache HTTP Server config for Ubuntu 24.04 LTS (Noble Numbat) from https://exampleconfig.com/api/v1/config/original/0b2be6d48bbad8b4e32eef623e3670bc?hint=cache_disk.conf. Compare with my current /etc/apache2/mods-available/cache_disk.conf and summarize differences and safe changes.

Copy this prompt into Claude, ChatGPT, or other AI assistants.

/etc/apache2/mods-available/cache_disk.conf
# cache cleaning is done by htcacheclean, which can be configured in
# /etc/default/apache2
#
# For further information, see the comments in that file,
# /usr/share/doc/apache2/README.Debian, and the htcacheclean(8)
# man page.

# This path must be the same as the one in /etc/default/apache2
CacheRoot /var/cache/apache2/mod_cache_disk

# This will also cache local documents. It usually makes more sense to
# put this into the configuration for just one virtual host.
#CacheEnable disk /


# The result of CacheDirLevels * CacheDirLength must not be higher than
# 20. Moreover, pay attention on file system limits. Some file systems
# do not support more than a certain number of inodes and
# subdirectories (e.g. 32000 for ext3)
CacheDirLevels 2
CacheDirLength 1

Install Apache HTTP Server

Alpine Linux

sudo apk add apache2

Debian

sudo apt update && sudo apt install apache2

Red Hat Enterprise Linux

sudo yum install httpd

Ubuntu

sudo apt update && sudo apt install apache2

File Location

File Path
/etc/apache2/mods-available/cache_disk.conf
Directory
/etc/apache2/mods-available/
Significance
System-wide configuration directory
Description
Files in /etc/ contain system-wide configuration settings that affect all users.

FAQ

When should I use this cache_disk.conf?

Restore it. Compare it. Start clean.

How do I restore Apache HTTP Server defaults?

Download, replace, restart.

Is cache_disk.conf safe for production?

Yes. This is exactly what shipped. Safe starting point.

How does this differ from other OS versions?

Defaults change. This one is specific to Ubuntu 24.04 LTS (Noble Numbat).

Can I use this for Apache HTTP Server troubleshooting?

Absolutely. Diff this against yours to spot the problem.