Magento 2 var/generation cannot be deleted warning

You may also like...

5 Responses

  1. Chieu says:

    Hi,
    I ‘ve tried to run the magento command: php bin/magento, got the following errors:
    “We’re sorry, an error occurred. Try clearing the cache and code generation directories. By default, they are: var/cache, var/di, var/generation, and var/page_cache.

    [Exception]
    Deprecated Functionality: The each() function is deprecated. This message will be suppressed on further calls in /var/www/ html/vendor/magento/zendframework1/library/Zend/Cache/Backend.php on line 79”

    Even I’ve already flushed the caches, but does not solve the issue. I cannot run any magento command. Any help would be appreciated. Thanks

  2. Alston says:

    $ php bin/magento setup:static-content:deploy

    PHP Fatal error: Uncaught Error: Class ‘DOMDocument’ not found in /home/ubuntu/dnmp/www/magento/vendor/magento/framework/Config/Dom.php:384
    Stack trace:

    $ php –version
    PHP 7.0.22-0ubuntu0.16.04.1 (cli) ( NTS )

  3. James Harrington says:

    Perfect thanks so much. Im so ready to be done with this magento crap. Glad this was an easy one

Leave a Reply

Your email address will not be published. Required fields are marked *