PHP Warning: require(/var/www/html/magento2/bin/../app/bootstrap.php): failed to open stream: No such file or directory in /var/www/html/magento2/bin/magento on line 14
PHP Fatal error: require(): Failed opening required '/var/www/html/magento2/bin/../app/bootstrap.php' (include_path='.:/usr/share/php') in /var/www/html/magento2/bin/magento on line 14
Error when execute sudo php bin/magento setup:upgrade
Best Answer
Please make sure the file
/var/www/html/magento2/app/bootstrap.php
is available.This error indicates it is not.
Also make sure to set correct permission to your files as described:
https://devdocs.magento.com/guides/v2.3/install-gde/trouble/readiness/tshoot_rc_perms.html
With
sudo
this shouldn't be a problem, nevertheless I recommend not using super user.