cancel
Showing results for 
Search instead for 
Did you mean: 

Magento 2.2.6 - frontend and admin blank after setup:di:compile

Magento 2.2.6 - frontend and admin blank after setup:di:compile

I've seen similar questions on here but none solve the problem for me. I hoping someone can help me solve/investigate/debug this problem.

 

I have Magento 2.2.6 installed on a Ubuntu 18.02 with LAMP (PHP 7.1). I had the store up and running and all was going well. I have the free Pixtron theme from HiddenTechies installed.

 

When trying to configure Braintree payments, I read something that told me to run

php bin/magento setup:di:compile

(I can't remember why).

 

After that command ran, everything is totally blank. When I go to the frontend and admin login in a web browser, they are blank. The page source for either doesn't have any content.

I tried a bunch of commands like 'setup:upgrade' and 'cache:flush' but nothing helps. This happened previously and I ended up wiping the server and starting from scratch, but that isn't a long-term solution.

 

I have a suspicion that the issue may related to permissions because I don't fully understand what I'm doing with them (I'm learning). Maybe there's a way to do a permissions "health check".

 

Any advice/pointers in the right direction appreciated. Thanks.

5 REPLIES 5

Re: Magento 2.2.6 - frontend and admin blank after setup:di:compile

Hello @rob223

 

I think you should try running following commands. And also you should check your console to see if the js and css files are loading

      php bin/magento setup:upgrade

      php bin/magento setup:static-content:deploy

      php bin/magento indexer:reindex

      chmod -R 777 var/ pub/ generated

 

You can also refer to following link:

https://www.simicart.com/blog/magento-white-screen/

https://magento.stackexchange.com/questions/224912/magento-2-2-4-white-blank-page-after-setupdicompi...

 

If it works for you Kudos and accept as solution!

Re: Magento 2.2.6 - frontend and admin blank after setup:di:compile

Hello @rob223

 

I think you should try running following commands. And also you should check your console to see if the js and css files are loading

      php bin/magento setup:upgrade

      php bin/magento setup:static-content:deploy

      php bin/magento indexer:reindex

      chmod -R 777 var/ pub/ generated

You can also refer to following link:

https://www.simicart.com/blog/magento-white-screen/

https://magento.stackexchange.com/questions/224912/magento-2-2-4-white-blank-page-after-setupdicompi...

 

If it works for you Kudos and accept as solution!

Re: Magento 2.2.6 - frontend and admin blank after setup:di:compile

@Surbhiagr thanks very much; this helped but there is still something missing. 

 

The HTML pages are now loading but the .css and .js are not. All the .css and .js files that are showing a 404 error in the console are from my theme (Hidden Techies Pixtron). 

 

Example:

[Error] Failed to load resource: the server responded with a status of 404 (Not Found) (owl.transitions.css, line 0) - http://xxx.xxx.xxx.xxx/pub/static/version1540746840/frontend/Hiddentechies/pixtron/en_US/Hiddentechies_Base/css/owl.transitions.css

 

I can see the files in the correct directories except the 'version1540746840' directory doesn't exist in the directory structure. However, the number is in a file called 'deployed_version.txt' in pub/static. 

 

Any ideas? 

 

 

Re: Magento 2.2.6 - frontend and admin blank after setup:di:compile

-

Re: Magento 2.2.6 - frontend and admin blank after setup:di:compile

Hello,

 

you can try running content deploy command for store 

 

  php bin/magento setup:static-content:deploy en_US

 

where US is the country code.