Problem with Intial Server Response Time with Magento 2.4.1 and AWS Lightsail Hosting

Keywords: Magento - AWS - Technical issue - Permissions
bnsupport ID: 1caecc81-2d26-f91f-44d4-e8c800a76fe3
Description:
Hi,
We have created an Magento Instance in the AWS Light sail platform and successfully installed our purchased theme. I have enabled Varnish cache and Elasticsearch suit. And While loading home page it is taking more time to load. i have run bitnami support tool and the id is

1caecc81-2d26-f91f-44d4-e8c800a76fe3

Further I tried to fix the folder permissions and i didnt find any file with name fixPermissions.sh in the hosting panel.

Hence i request you to look into the matter and resolve the Initial Server response time and [Folder permissions issue if any].

Hello @phanikumar1666,

This is our guide to troubleshoot performance issues:
https://docs.bitnami.com/aws/faq/troubleshooting/troubleshoot-server-performance/

Let me also share this previous similar topic in case it helps:

This script is no longer present in our Magento solution. The support tool did not gather the permissions from your Magento folder. Could you please share with us the output of this command?

ls -larthR /bitnami/magento

Regards

1.zip (2.9 MB) 2.zip (3.9 MB) Hi, Thank you for responding. I run that command and results are attached here. Further while implementing AWS CDN it is showing CROS error for html page. Please guide me in this issue also. I have read that in 2.4.1 there is an issue with CROS.

Hello @phanikumar1666,

Both links seem to be broken. Could you please share it again with us? Maybe you can use some alternatives like Google Drive or Dropbox.

Regards

Hi,
Google drive Link is here
Output File Link

Hello @phanikumar1666,

It seems the output is not totally completed. What I can see seems to be correct.

I would like to know the permissions for /bitnami/magento/app/etc/config.php. They should look like below:

ls -larth /bitnami/magento/app/etc/config.php
-rw-rw-r-- 1 daemon daemon 14K Jun 10 08:26 /bitnami/magento/app/etc/config.php

Anyway, this documentation helps to troubleshoot permission issues:
https://docs.bitnami.com/aws/apps/magento/troubleshooting/debug-errors/

We also recommend to flush the cache:
https://docs.bitnami.com/aws/apps/magento/administration/use-cache/

This site helps you to analyze your server performance:
https://gtmetrix.com/

Please let us know if this helps, and share a new support output in case you continue facing issues.

Regards

-rw-rw-r-- 1 bitnami daemon 27K Jun 8 02:42 /bitnami/magento/app/etc/config.php

the abov is the result after running the query

Hi @phanikumar1666,
That seems to be correct. Please check the rest of documents and sources that David sent you.

Permissions command result

magento profiler result
profiler.zip (13.0 KB)

Hi @phanikumar1666,
The ZIP file link is broken.
Did you try flushing the cache as David suggested?

https://drive.google.com/file/d/1OblCGB2RTIXx68j38mPz11eQBBgaI93R/view

cache is enabled. but still issue exists. Google Drive link is also working. i checked.

Hi @phanikumar1666,
We know the cache is enabled, but did you try flushing it?

The permissions on the file seems to be correct.

Yes i am flushing cache.

Hi @phanikumar1666,
With the information we have it is really difficult to provide a solution. I strongly recommend you to check a tool like https://gtmetrix.com/ in order to identify why the server response is slow.
If you enabled Elasticsearch and Varnish probably the instance is consuming more resources and it could make it slower too.

Do you mean elastic search and varnish to be disabled??

In top command I am seeing more number of PHP and php-fpm commands consuming 100%of CPU and Memory

Hi @phanikumar1666,
Can you identify if those PHP processes are expected? If they are, probably your instance could need more resources. If they are not expected, then we would need to figure out where do they come from.