In my Magento 2, I can't enable/disable cache In System -> Cache Management, the two options are missing from the dropdown menu. what went wrong?
It's in Production mode.
I can only enable / disable cache via CLI.
Magento Stack Exchange is a question and answer site for users of the Magento e-Commerce platform. It only takes a minute to sign up.Sign up to join this community
It looks like it is meant to be like this in Magento 2.2 when production mode enabled
Intended for deployment on a production system, this mode:
Does not show exceptions to the user (exceptions are written to logs only).
Serves static view files from cache only. Prevents automatic code file compilation.
New or updated files are not written to the file system.
Does not allow you to enable or disable cache types in Magento Admin.
Magento is happy for you to enable/disable the cache using the commandline while in production mode:
[user@host ~/public_html]$ php bin/magento cache:enable
[user@host ~/public_html]$ php bin/magento cache:disable
IMO its silly not to be able to switch the cache on/off in Magento admin while running in production mode. Its handy for troubleshooting and switching from production to developer mode is way overkill to simply enable/ disable cache as it causes downtime during the switch and drastically reduced performance. It would be a much better idea to simply warn magento users if any part of the cache is disabled with a notification than to completely remove all actions from the cache management screen.
Just my two satoshis.