| 1 2 | Cache engine Cake\Cache\Engine\FileEngine is not properly configured. Warning (2): file_put_contents(/var/www/html/cakephp3/logs/error.log) [function.file-put-contents]: failed to open stream: Permission denied [CORE/src/Log/Engine/FileLog.php, line 134] | 
以下のようなエラーが出てしまった場合、
他のサイトを見るとSELinuxが有効になっているので、
Disabledに変更しろとの内容が多かった。
ただ、私の場合はなぜか、ディレクトリのパーミッションが変わっていたようで、
以下のコマンドでパーミッションを変更する。。
| 1 2 | chmod -R 777 /[sample_dir]/logs chmod -R 777 /[sample_dir]/cache | 
すると上記によるエラーは解決し、新たに以下のエラーが出ます。
| 1 | SQLSTATE[HY000]: General error: 8 attempt to write a readonly database | 
こちらも同様に指定のファイルのパーミッションを変更する。
| 1 | chmod 777 /tmp/debug_kit.sqlite | 
これで全て解決しました。
もし、解決しない場合は、SELinuxの影響を疑ってみましょう。
SELinuxが影響しているかどうかは、以下のコマンドで有効の確認をします。
| 1 2 | getenforce Enfocing | 
| 1 2 3 | setenforce 0 getenforce Disabled | 
で直せばOKです。
