- Issue created by @emptyvoid
- Status changed to Postponed: needs info
9 days ago 9:42pm 30 May 2025
Every time a 404 is generated from site traffic the 404 event is logged. But system also triggers at least two warning errors in the system log. For sites with a lot of traffic the 404 event log is indated with 3 instead of 1 record per 404 event.
Core: 9.5.9
PHP: 8.1
Apache: 2.4.52
MariaDB: 10.6.12
Enter an invalid url on the site.
Clean up the 404 regular expressions and or add filters to clean it up.
/core/modules/system/config/install/system.performance.yml
LIne: 7
fast_404:
enabled: true
paths: '/\.(?:txt|png|gif|jpe?g|css|js|ico|swf|flv|cgi|bat|pl|dll|exe|asp)$/i'
exclude_paths: '/\/(?:styles|imagecache)\//'
Remove the "(" and ")" in the regular expressions to look like.
fast_404:
enabled: true
paths: '/\.?:txt|png|gif|jpe?g|css|js|ico|swf|flv|cgi|bat|pl|dll|exe|asp$/i'
exclude_paths: '/\/?:styles|imagecache\//'
Alternatively, and of course a messier alternative is to add filters to the code that calls the settings.
(patch attached)
If reformatting the install YAML consider a update hook to reset the default settings.
Active
9.5
Last updated