Skip to content

Improve cache or settings dir may already exist#346

Merged
svenba merged 2 commits intokeycdn:masterfrom
8ctopus:cache-and-settings-dir-may-already-exist
Mar 1, 2026
Merged

Improve cache or settings dir may already exist#346
svenba merged 2 commits intokeycdn:masterfrom
8ctopus:cache-and-settings-dir-may-already-exist

Conversation

@8ctopus
Copy link
Copy Markdown
Contributor

@8ctopus 8ctopus commented May 6, 2025

In some setups, the cache or settings directory may already exist on the server, which should normally be harmless. However, Cache Enabler flags this as an issue and displays the following persistent message in the WordPress dashboard:

Cache Enabler requires the directory %2$s to exist and be writable (mode 755, for example)

In my case, the cache directory is a symbolic link that PHP running as www-data does not have access to. As a result, when I disable the plugin, the cache symlink remains.

Here’s a snapshot of the directory structure:

la /srv/wordpress/web/app
total 20
drwxrwxr-x  5 ubuntu ubuntu 4096 May  5 13:57 .
drwxrwxr-x  4 ubuntu ubuntu 4096 May  5 07:29 ..
lrwxrwxrwx  1 ubuntu ubuntu   49 May  5 13:57 advanced-cache.php -> ../../../storage/cache-enabler/advanced-cache.php
lrwxrwxrwx  1 ubuntu ubuntu   14 Jul 17  2023 cache -> ../../../cache
drwxrwxr-x  3 ubuntu ubuntu 4096 Apr  6  2023 mu-plugins
drwxrwxr-x 11 ubuntu ubuntu 4096 May  5 07:35 plugins
drwxrwxr-x  4 ubuntu ubuntu 4096 Jul 10  2023 themes
lrwxrwxrwx  1 ubuntu ubuntu   19 Jul 17  2023 uploads -> ../../../wp-uploads

@svenba svenba merged commit 8cd7bbe into keycdn:master Mar 1, 2026
@8ctopus 8ctopus deleted the cache-and-settings-dir-may-already-exist branch March 19, 2026 12:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants