Add new Product, Page or Categories is Broken

I just installed Magento 2.3.5-p1 with Sampledata and everything seems fine until I go to admin panel and view products page or category or pages etc. I get a blank page and errors in the log files. I am also unable to add new product and I see nothing but a blank as shown in the screenshots.

System.log

[2020-07-13 05:52:27] main.INFO: Broken reference: the 'tracking' element cannot be added as child to 'header', because the latter doesn't exist [] []
[2020-07-13 05:52:27] main.INFO: Broken reference: the 'global_notices' element cannot be added as child to 'global.notices', because the latter doesn't exist [] []
[2020-07-13 05:52:27] main.INFO: Broken reference: the 'logo' element cannot be added as child to 'header', because the latter doesn't exist [] []
[2020-07-13 05:52:27] main.INFO: Broken reference: the 'global.search' element cannot be added as child to 'header', because the latter doesn't exist [] []
[2020-07-13 05:52:27] main.INFO: Broken reference: the 'user' element cannot be added as child to 'header', because the latter doesn't exist [] []
[2020-07-13 05:52:27] main.INFO: Broken reference: the 'menu' element cannot be added as child to 'page.menu', because the latter doesn't exist [] []
[2020-07-13 05:52:27] main.INFO: Broken reference: the 'breadcrumbs' element cannot be added as child to 'page.breadcrumbs', because the latter doesn't exist [] []
[2020-07-13 05:52:27] main.INFO: Broken reference: the 'formkey' element cannot be added as child to 'page.formkey', because the latter doesn't exist [] []
[2020-07-13 05:52:27] main.INFO: Broken reference: the 'page.title' element cannot be added as child to 'main.top', because the latter doesn't exist [] []
[2020-07-13 05:52:27] main.INFO: Broken reference: the 'messages' element cannot be added as child to 'page.messages', because the latter doesn't exist [] []
[2020-07-13 05:52:27] main.INFO: Broken reference: the 'page.actions.toolbar' element cannot be added as child to 'page.main.actions', because the latter doesn't exist [] []
[2020-07-13 05:52:27] main.INFO: Broken reference: the 'legal' element cannot be added as child to 'footer', because the latter doesn't exist [] []
[2020-07-13 05:52:27] main.INFO: Broken reference: the 'notification_area' element cannot be added as child to 'notifications', because the latter doesn't exist [] []
[2020-07-13 05:52:27] main.INFO: Broken reference: the 'unread_system_messages' element cannot be added as child to 'notifications', because the latter doesn't exist [] []
[2020-07-13 05:52:27] main.INFO: Broken reference: the 'notification_window' element cannot be added as child to 'notifications', because the latter doesn't exist [] []
[2020-07-13 05:52:27] main.INFO: Broken reference: the 'notification.messages' element cannot be added as child to 'header', because the latter doesn't exist [] []
[2020-07-13 05:52:27] main.INFO: Broken reference: the 'header.inner.left' element cannot be added as child to 'header', because the latter doesn't exist [] []
[2020-07-13 05:52:27] main.INFO: Broken reference: the 'header.inner.right' element cannot be added as child to 'header', because the latter doesn't exist [] []
[2020-07-13 05:52:27] main.INFO: Broken reference: the 'logo' tries to reorder itself towards '', but their parents are different: 'header' and '' respectively. [] []
[2020-07-13 05:52:27] main.INFO: Broken reference: the 'global.search' tries to reorder itself towards 'logo', but their parents are different: 'header' and '' respectively. [] []
[2020-07-13 05:52:27] main.INFO: Broken reference: the 'user' tries to reorder itself towards '', but their parents are different: 'header' and '' respectively. [] []
[2020-07-13 05:52:27] main.INFO: Broken reference: the 'page.actions.toolbar' tries to reorder itself towards '', but their parents are different: 'page.main.actions' and '' respectively. [] []
[2020-07-13 05:52:27] main.INFO: Broken reference: the 'notification.messages' tries to reorder itself towards 'user', but their parents are different: 'header' and '' respectively. [] []
[2020-07-13 05:52:27] main.INFO: Broken reference: the 'header.inner.left' tries to reorder itself towards '', but their parents are different: 'header' and '' respectively. [] []
[2020-07-13 05:52:27] main.INFO: Broken reference: the 'header.inner.right' tries to reorder itself towards 'header.inner.left', but their parents are different: 'header' and ''
respectively. [] []
[2020-07-13 05:52:54] main.INFO: Broken reference: the 'product.reviews' element cannot be added as child to 'product_tabs', because the latter doesn't exist [] []

Preconditions (*)

  1. Magento 2.3.5-p1
  2. Mysql Ver 15.1 Distrib 10.2.32-MariaDB, for Linux (x86_64) using readline 5.1
  3. Nginx & PHP-FPM
  4. Redis as cache/page_cache & session
  5. Centos 7

Steps to reproduce (*)

  1. Visit admin panel
  2. Click Content
  3. Click Pages

OR

  1. Visit admin panel
  2. Click Catalog
  3. Click Product/Categories

OR

  1. Visit admin panel
  2. Click Catalog
  3. Click Product
  4. Click Add Product

Expected result (*)

  1. I should be able to view the products from sample Data
  2. I should be able to view the current pages I have
  3. I should be able to add a new product

Actual result (*)

  1. Screenshot # 1
  2. Screenshot #2

Can anyone please help me here?

I feel like Iā€™ve seen this before. Could you trying flushing everything through just as Iā€™ve referenced in this post:

Hey, thanks for replying. I have tried all these commands step by step. and just now I installed 2.3.4 via composer to check if that issue was with 2.3.5-p1, but it seems i have this issue with 2.3.4 as well.

So i tried above commands on 2.3.4 unfortunately it did not work. I canā€™t create new product or even view current pages. Its blank. I am so tired of Magento now, its bug after bug, and I have been fixing for past 1 week : (

@digitalstartup before installation via cli, what permissions do i need to give to dir & files other than:

find var generated vendor pub/static pub/media app/etc -type f -exec chmod g+w {} +
find var generated vendor pub/static pub/media app/etc -type d -exec chmod g+ws {} +
chmod u+x bin/magento

AJAX/XHR (Server Config)

Hmm, I know Iā€™ve run into this beforeā€¦ Reminds me of the time I tried to implement a CDN for my assets but the server (apache) was not setup correctly to accept Control Policies (or something like that).

Open up your Browsers Console and Network tabs and refresh the page. If itā€™s what I think it might be, then the output should generate some decent leads to follow. I donā€™t think itā€™s a JS block, but something like an AJAX/XHR call or something. This is whatā€™s respsonsible for generating the information in the tables as this is the method to query the database. My memory is sketchy.

Permissions

As for permissions, they look fine. Although you havenā€™t specified whom the Files/Directories belong to. But I donā€™t think itā€™s that otherwise the CLI probably would have generated an error. You might find this post of use, How to diagnose and fix Ownerships and Permission issues. However, my money is on server config rather than Magento/Permissions.

Iā€™ll be back on later. Let me know how you get on.

I just uninstalled it, and then instead of composer I installed it via downloadable file 2.3.5-p1 (sample data). After installing I was able to view the categories this time. (I enabled Magento_csp this time) However product/new product and pages remain the same. Also network tab gives me nothing, but JS console does give me ā€œRefused to Loadā€ error.

Every time I click ā€œAdd attributeā€ in products, it generated following line of error.

[Error] [Report Only] Refused to load https://amcglobal.sc.omtrdc.net/b/ss/amc.global.prod,amc.mag.admin.prod/1/JS-2.15.0-LATI/s14928902371395?AQB=1&ndh=1&pf=1&t=13%2F6%2F2020%2016%3A16%3A7%201%20-300&mid=22339363847118116693016294324884045110&aamlh=7&ce=UTF-8&cdp=3&fpCookieDomainPeriods=3&g=https%3A%2F%2Fwww.domain.com%2Fdomaincpanel%2Fcatalog%2Fproduct%2Fnew%2Fset%2F4%2Ftype%2Fsimple%2Fkey%2Fda6a66b459c4ddd5d131688414a1da4a4f9d6f74d556bfd1c5d6a3c6fb09fd2e%2F&c.&event.&feature=na&element=Add%20Attribute&type=button&action=click&widget.&name=Add%20Attribute&type=button&.widget&.event&.c&cc=USD&pe=lnk_o&pev2=Add%20Attribute&s=1440x900&c=24&j=1.6&v=Y&k=Y&bw=1439&bh=410&mcorgid=8F99160E571FC0427F000101%40AdobeOrg&lrt=167&AQE=1 because it does not appear in the img-src directive of the Content Security Policy.

In categories when i open sub category and finally click a product, it generated following error among other several CSP errors.

[Report Only] Refused to load data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7 because it does not appear in the img-src directive of the Content Security Policy.

I am using Nginx, and I created a new user with group ā€˜nginxā€™ and created a php pool for it. so that seems fine to me.

My Nginx configuration file is: https://pastebin.com/raw/b1qXjaWB

Everything in content is blank.

Affected page are:

Admin > Customers > All Customers > Add New Customer
Admin > Catalog > Product
Admin > Catalog > Categories

Admin > Content > Themes
Admin > Content > Configuration
Admin > Content > Pages
Admin > Content > Blocks

Not Affected in these tabs:

Admin > Content > Schedule
Admin > Content > Widgets

Ignore the ones that start ā€œ[Report Only] Refused to loadā€ (Magento_csp), I have a video going up about that soon. Itā€™s not related to your issue.

Maybe I was thinking of ā€œcross-originā€ errors. If this is the issue, look into ā€œEnable CORS in Nginxā€. My Nginx knowledge is rusty at best.

Also, in your Browser Network Tab, are there any assets that arenā€™t returning a 200 Status. If so, what are some of those assets and what is the error being generated?

I have taken a screenshot, all i see is a 404 for page_speed but i donā€™t think page_speed has to do something with it. I normally disable CPS module of Magento. I have enabled CORS by adding add_header 'Access-Control-Allow-Origin' '*'; to nginx configuration file. Can you please inspect it? if I share the credentials?

@digitalstartup guess whatā€¦ It was because of ngx_page_speed moduleā€¦ I disabled it in nginx and now everything is working smoothly.

My question, why is page_speed not working with Magento 2? Even though the google page insight increases the speed with page speed module.

Aha, I knew it was web server related :smiley:

No idea why page_speed isnā€™t supported. Last time I think I used that module was post-2018 on an old M1 install. I didnā€™t realise it was still a thing to be honest. As I mentioned before, I havenā€™t used Nginx in while.

1 Like

This topic was automatically closed 2 days after the last reply. New replies are no longer allowed.