If you need to copy emails from one mailbox to another, even if they are located on different servers, you can use the imapsync utility. You just need to install and run it in the console with parameters. Naturally, you need to know the passwords for both mailboxes.
Fluentbit can follow and parse logs and send them to different systems, for example, Newrelic or Elasticsearch. But you may notice, that for some reason it does not follow files or stops follow ones.
As you know, Varnish is a powerful caching system and it is a must-have on every Magento setup, even at the development workstation. But there is a little trick that very few people know about. It is the Transient cache, which I explain below.
You should know the memory limit of your container (not the whole host) when packing applications there. For example and simplicity, let’s imagine you are creating customized redis, memcached or varnish image and you wish to know available memory when the container starts to set it as the memory limit for your application.
Magento is very demanding on component settings. Everything has to be carefully configured, especially the opCache in PHP. It is opCache that is mainly responsible for PHP’s performance.
It is because the default value of index.mapping.total_fields.limit is 1000. To increase it for some index to 2000 just run curl request:
curl -s -XPUT http://elasticsearch:9200/magento2_product_1_v3/_settings -H 'Content-Type: application/json' -d '{"index.mapping.total_fields.limit": 2000}'
Show disk usage ignoring mounts
If you wish to know how much space uses some dir in Linux, you can use du -hs /some-folder. But what if you have a lot of mixed mounts in that folder and you want to know how much exactly this folder consumes at root disk storage?
It is very simple:
for i in */ .*/ ; do
echo -n $i": " ;
(find "$i" -type f | wc -l) ;
done
PHP 7.4 preloading feature for Magento
PHP 7.4 introduces the opcache preloading function. Its meaning is to load all the necessary scripts into memory at the stage of starting the PHP daemon. Let’s see if this feature is worth using in Magento?
Reload Varnish VCL using varnishadm
You can reload Varnish config without losing your cache. To do this, you should use the standard varnishadm CLI utility.