I run the command php bin/magento many times a day, so I'd like to know if I can optimize the execution of this one?

For example:

php bin/magento cache:flush

1 Answer 1


You can improve the memory limit and create an alias as well, like that:

alias mage="php -d memory_limit=-1 -f bin/magento"

Then run the command below in your root installation folder:

mage cache:flush

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.