2

Good evening, my site is https://www.emporiobit.com.br it is not yet in production.
I use magento 2.2.5 with varnish and redis
I configured 4G for Varnish and 4G for php memory_limit, my VPS has 12gb ram
When I open the site there is a slow but when the site is open it loads everything at once, I believe because of the cache
The ping from Brazil where my public is located until the server is around 220~290ms, using cloudflare is around 130~140ms
I took a test at www.webpagetest.org and the TTFB scored 2,502s, I think it's a bit high
Could you help me sort out how slow to open?
Report site webpagetest

  • your first bit response time it 2.502 second means your application has some issue for this reason,it is taking at time – Amit Bera Aug 30 '18 at 4:50
  • 2,502s basically says "cache me". How did you configure Varnish? Have you selected "Varnish Cache" in admin settings? Have you applied the Varnish software to the server and Magento VCL file for it? Finally, make sure that you have enabled caches via bin/magento cache:enable – Danila Vershinin Aug 30 '18 at 7:52
  • @AmitBera The TTFB is high, how to diagnose to achieve a better performance? I generated a report in csv of the magento profile but I could not find out where the problem is – guilhermetb Aug 30 '18 at 17:40
  • @DanielV.varnish is running with 4G ram and as for vcl I exported it from console admin magento2 – guilhermetb Aug 30 '18 at 17:45
2

You can follow some steps below :

  • Merge Css
  • Merge javascript
  • Put store to production mode
  • Enable all cache

Then check speed of your store

Good luck !

  • Hi, all these procedures were done. – guilhermetb Aug 30 '18 at 4:06
  • Your store still slow or speed up ? – Vu Tran Kien Aug 30 '18 at 7:18
0

All related items are OK except for PHP-FPM that I do not have installed. With this php-fpm is there performance gain?

  • yes and no, you need to test it, probably you have some issues with php code in your templates – MagenX Sep 1 '18 at 8:32
-1

Use the latest Magento 2.2* supports php 7.1 or not. Please below link Refere and check PHP 7.1 Support or not.

==> http://devdocs.magento.com/guides/v2.2/install-gde/prereq/php-ubuntu.html

==> After It it is supported then you install this PHP plugin.

sudo apt-get install php7.1 php7.1-xml php7.1-dom php7.1-intl php7.1-imap

==> If you running multiple PHP versions set 7.1 to the as default Using this command.

==> sudo update-alternatives --set php /usr/bin/php7.1

Set to Developer Mode php -f bin/magento deploy:mode:show

php -f bin/magento deploy:mode:set developer

==> Check Magento cache is enabled Or not It's FPC Not Enabled please enabled FPC cache. Then check cache status.

php -f bin/magento cache:status

If it is not enabled (cache status of 1's)

php -f bin/magento cache:enable

then you will Enable JS/CSS bundling

Stores -> Configuration -> Advanced -> Developer

==> Template Configuration

Minify HTML ==> set to Yes Javascript Settings

Merge JS files ==> set to Yes

Enable JS Bundling ==> set to Yes

Minify JS files ==> set to Yes

CSS Configuration

Merge CSS = set to Yes Minify CSS = set to Yes

you will Do the cache flush after every step flush the cache.

php -f bin/magento cache:flush

==>Use Redis

sudo apt-get update sudo apt-get install build-essential tcl8.5 sudo apt-get install make wget http://download.redis.io/redis-stable.tar.gz tar xvzf redis-stable.tar.gz cd redis-stable made cd utils/ sudo ./install_server.sh

Edit var/www/html/MagentoFoldername/app/etc/env.php

'cache' => 
  array (
    'frontend' => 
    array (
      'default' => 
      array (
        'backend' => 'Cm_Cache_Backend_Redis',
        'backend_options' => 
        array (
          'server' => '127.0.0.1',
          'database' => '0',
          'port' => '6379',
        ),
      ),
      'page_cache' => 
      array (
        'backend' => 'Cm_Cache_Backend_Redis',
        'backend_options' => 
        array (
          'server' => '127.0.0.1',
          'port' => '6379',
          'database' => '1',
          'compress_data' => '0',
        ),
      ),
    ),
  ),

==> Use PHP-FPM

apt-get install php7.1-fpm a2enmod proxy_fcgi setenvif a2enconf php7.1-fpm sudo service php7.1-fpm restart sudo service apache2 restart

==>Enable opcache in PHP

Edit this file /etc/php/7.1/apache2/php.ini find opcache.enable

opcache.enable=1
  • 1
    not sure if your copy-paste related to his issues.... – MagenX Sep 1 '18 at 8:33

Your Answer

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

Not the answer you're looking for? Browse other questions tagged or ask your own question.