Issue Bug Closed

#31255CF: Could not create directory

Steffen Gebert 10/25/11, 02:57 updated 10/23/17, 21:48

Description

Installing TYPO3 in a directory, where the web server user has no write permissions at all ends up with a RuntimeException:

PHP Fatal error:  Uncaught exception 'RuntimeException' with message 'Could not create directory!' in t3lib/class.t3lib_div.php:2909
Stack trace:
#0 t3lib/cache/backend/class.t3lib_cache_backend_filebackend.php(201): t3lib_div::mkdir_deep('/var/www/typo3t...')
#1 t3lib/cache/backend/class.t3lib_cache_backend_filebackend.php(99): t3lib_cache_backend_FileBackend->createFinalCacheDirectory('/var/www/typo3t...')
#2 t3lib/cache/frontend/class.t3lib_cache_frontend_abstractfrontend.php(63): t3lib_cache_backend_FileBackend->setCache(Object(t3lib_cache_frontend_PhpFrontend))
#3 t3lib/cache/frontend/class.t3lib_cache_frontend_phpfrontend.php(45): t3lib_cache_frontend_AbstractFrontend->__construct('cache_phpcode', Object(t3lib_cache_backend_FileBackend))
#4 [internal function]: t3lib_cache_frontend_PhpFrontend->__construct('cache_phpcode', Object(t3lib_cache_backend_FileBackend))
#5 /var/www/typo3_sr in t3lib/cache/backend/class.t3lib_cache_backend_filebackend.php on line 203

The bad thing is that modern browsers dont’t show that Exception, but show just a Server Error page.

If possible, we should check, whether the directory is writable and then output a message, which finds its way to the user!

In doubt I’m fine with taking this from the 4.6.0 target.

Reviews 0

No change resolves or names this issue in its commit message, and no comment links one.