3

When I open the frontend and backend I always got an error like this:

"Warning: include(/var/www/test.com/var/view_preprocessed/html/vendor/magento/module-theme/view/base/templates/root.phtml): failed to open stream: No such file or directory in /var/www/test.com/vendor/magento/framework/View/Result/Page.php on line 312";

I checked inside var/view_processed folder and it only has 1 css file.

I already tried this solution, but it's not working, I already set the permission for var folder to 775 but it's not working either

chmod -R 775 var

The only solution for me right now is change the Magento mode from production to developer.

bin/magento deploy:mode:set developer

When I change to developer mode it's working fine, but when I change back to production mode the same error appear. How to fix this error for production mode?

  • Can you set all files to 644 permission and directories to 755 of your magento root directory? Also try 777 to magento_root/var for testing. – Sukumar Gorai May 22 '18 at 7:40
  • @SukumarGorai still not working – Tiny Dancer May 22 '18 at 8:30
  • magento.stackexchange.com/a/138800/69 redploy & be sure to purge all caches. php bin/magento setup:static-content:deploy – B00MER May 23 '18 at 1:46

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.