RuntimeException: The specified "/var/www/html/magento/var/generation/Magento/Store/Model/ResourceModel/Group/CollectionFactory.php.22573" file could not be written Warning!file_put_contents(/var/www/html/magento/var/generation/Magento/Store/Model/ResourceModel/Group/CollectionFactory.php.22573): failed to open stream: Permission denied in /var/www/html/magento/vendor/magento/framework/Code/Generator.php:115 Stack trace: #0 /var/www/html/magento/vendor/magento/framework/Code/Generator/Autoloader.php(35): Magento\Framework\Code\Generator->generateClass('Magento\\Store\\M...') #1 [internal function]: Magento\Framework\Code\Generator\Autoloader->load('Magento\\Store\\M...') #2 [internal function]: spl_autoload_call('Magento\\Store\\M...') #3 /var/www/html/magento/vendor/magento/framework/Code/Reader/ClassReader.php(29): ReflectionParameter->getClass() #4 /var/www/html/magento/vendor/magento/framework/ObjectManager/Definition/Runtime.php(44): Magento\Framework\Code\Reader\ClassReader->getConstructor('Magento\\Store\\M...') #5 /var/www/html/magento/vendor/magento/framework/ObjectManager/Factory/Dynamic/Developer.php(71): Magento\Framework\ObjectManager\Definition\Runtime->getParameters('Magento\\Store\\M...') #6 /var/www/html/magento/vendor/magento/framework/ObjectManager/ObjectManager.php(71): Magento\Framework\ObjectManager\Factory\Dynamic\Developer->create('Magento\\Store\\M...') #7 /var/www/html/magento/vendor/magento/framework/ObjectManager/Factory/AbstractFactory.php(126): Magento\Framework\ObjectManager\ObjectManager->get('Magento\\Store\\M...') #8 /var/www/html/magento/vendor/magento/framework/ObjectManager/Factory/Dynamic/Developer.php(53): Magento\Framework\ObjectManager\Factory\AbstractFactory->resolveArgument(Array, 'Magento\\Store\\A...', NULL, 'groupRepository', 'Magento\\Store\\M...') #9 /var/www/html/magento/vendor/magento/framework/ObjectManager/Factory/Dynamic/Developer.php(82): Magento\Framework\ObjectManager\Factory\Dynamic\Developer->_resolveArguments('Magento\\Store\\M...', Array, Array) #10 /var/www/html/magento/vendor/magento/framework/ObjectManager/ObjectManager.php(71): Magento\Framework\ObjectManager\Factory\Dynamic\Developer->create('Magento\\Store\\M...') #11 /var/www/html/magento/var/generation/Magento/Store/Model/StoreManagerInterface/Proxy.php(84): Magento\Framework\ObjectManager\ObjectManager->get('Magento\\Store\\M...') #12 /var/www/html/magento/var/generation/Magento/Store/Model/StoreManagerInterface/Proxy.php(135): Magento\Store\Model\StoreManagerInterface\Proxy->_getSubject() #13 /var/www/html/magento/vendor/magento/module-store/Model/Resolver/Website.php(30): Magento\Store\Model\StoreManagerInterface\Proxy->getWebsite('1') #14 /var/www/html/magento/vendor/magento/framework/App/Config/ScopeCodeResolver.php(49): Magento\Store\Model\Resolver\Website->getScope('1') #15 /var/www/html/magento/vendor/magento/module-config/App/Config/Source/RuntimeConfigSource.php(82): Magento\Framework\App\Config\ScopeCodeResolver->resolve('websites', '1') #16 /var/www/html/magento/vendor/magento/module-config/App/Config/Source/RuntimeConfigSource.php(58): Magento\Config\App\Config\Source\RuntimeConfigSource->loadConfig() #17 /var/www/html/magento/vendor/magento/framework/App/Config/ConfigSourceAggregated.php(40): Magento\Config\App\Config\Source\RuntimeConfigSource->get('') #18 /var/www/html/magento/var/generation/Magento/Framework/App/Config/ConfigSourceAggregated/Proxy.php(95): Magento\Framework\App\Config\ConfigSourceAggregated->get('') #19 /var/www/html/magento/vendor/magento/module-config/App/Config/Type/System.php(98): Magento\Framework\App\Config\ConfigSourceAggregated\Proxy->get() #20 /var/www/html/magento/vendor/magento/framework/App/Config.php(139): Magento\Config\App\Config\Type\System->get('default/web/sec...') #21 /var/www/html/magento/vendor/magento/framework/App/Config.php(90): Magento\Framework\App\Config->get('system', 'default/web/sec...') #22 /var/www/html/magento/vendor/magento/framework/App/Config.php(103): Magento\Framework\App\Config->getValue('web/secure/use_...', 'default', NULL) #23 /var/www/html/magento/vendor/magento/module-store/Model/HeaderProvider/Hsts.php(48): Magento\Framework\App\Config->isSetFlag('web/secure/use_...') #24 /var/www/html/magento/vendor/magento/framework/App/Response/HeaderManager.php(41): Magento\Store\Model\HeaderProvider\Hsts->canApply() #25 /var/www/html/magento/vendor/magento/framework/Interception/Interceptor.php(123): Magento\Framework\App\Response\HeaderManager->beforeSendResponse(Object(Magento\Framework\App\Response\Http\Interceptor)) #26 /var/www/html/magento/var/generation/Magento/Framework/App/Response/Http/Interceptor.php(117): Magento\Framework\App\Response\Http\Interceptor->___callPlugins('sendResponse', Array, Array) #27 /var/www/html/magento/vendor/magento/framework/App/Http.php(185): Magento\Framework\App\Response\Http\Interceptor->sendResponse() #28 /var/www/html/magento/vendor/magento/framework/App/Http.php(156): Magento\Framework\App\Http->handleDeveloperMode(Object(Magento\Framework\App\Bootstrap), Object(ReflectionException)) #29 /var/www/html/magento/vendor/magento/framework/App/Bootstrap.php(263): Magento\Framework\App\Http->catchException(Object(Magento\Framework\App\Bootstrap), Object(ReflectionException)) #30 /var/www/html/magento/index.php(39): Magento\Framework\App\Bootstrap->run(Object(Magento\Framework\App\Http)) #31 {main} Next ReflectionException: Class Magento\Store\Model\ResourceModel\Group\CollectionFactory does not exist in /var/www/html/magento/vendor/magento/framework/Code/Reader/ClassReader.php:29 Stack trace: #0 /var/www/html/magento/vendor/magento/framework/Code/Reader/ClassReader.php(29): ReflectionParameter->getClass() #1 /var/www/html/magento/vendor/magento/framework/ObjectManager/Definition/Runtime.php(44): Magento\Framework\Code\Reader\ClassReader->getConstructor('Magento\\Store\\M...') #2 /var/www/html/magento/vendor/magento/framework/ObjectManager/Factory/Dynamic/Developer.php(71): Magento\Framework\ObjectManager\Definition\Runtime->getParameters('Magento\\Store\\M...') #3 /var/www/html/magento/vendor/magento/framework/ObjectManager/ObjectManager.php(71): Magento\Framework\ObjectManager\Factory\Dynamic\Developer->create('Magento\\Store\\M...') #4 /var/www/html/magento/vendor/magento/framework/ObjectManager/Factory/AbstractFactory.php(126): Magento\Framework\ObjectManager\ObjectManager->get('Magento\\Store\\M...') #5 /var/www/html/magento/vendor/magento/framework/ObjectManager/Factory/Dynamic/Developer.php(53): Magento\Framework\ObjectManager\Factory\AbstractFactory->resolveArgument(Array, 'Magento\\Store\\A...', NULL, 'groupRepository', 'Magento\\Store\\M...') #6 /var/www/html/magento/vendor/magento/framework/ObjectManager/Factory/Dynamic/Developer.php(82): Magento\Framework\ObjectManager\Factory\Dynamic\Developer->_resolveArguments('Magento\\Store\\M...', Array, Array) #7 /var/www/html/magento/vendor/magento/framework/ObjectManager/ObjectManager.php(71): Magento\Framework\ObjectManager\Factory\Dynamic\Developer->create('Magento\\Store\\M...') #8 /var/www/html/magento/var/generation/Magento/Store/Model/StoreManagerInterface/Proxy.php(84): Magento\Framework\ObjectManager\ObjectManager->get('Magento\\Store\\M...') #9 /var/www/html/magento/var/generation/Magento/Store/Model/StoreManagerInterface/Proxy.php(135): Magento\Store\Model\StoreManagerInterface\Proxy->_getSubject() #10 /var/www/html/magento/vendor/magento/module-store/Model/Resolver/Website.php(30): Magento\Store\Model\StoreManagerInterface\Proxy->getWebsite('1') #11 /var/www/html/magento/vendor/magento/framework/App/Config/ScopeCodeResolver.php(49): Magento\Store\Model\Resolver\Website->getScope('1') #12 /var/www/html/magento/vendor/magento/module-config/App/Config/Source/RuntimeConfigSource.php(82): Magento\Framework\App\Config\ScopeCodeResolver->resolve('websites', '1') #13 /var/www/html/magento/vendor/magento/module-config/App/Config/Source/RuntimeConfigSource.php(58): Magento\Config\App\Config\Source\RuntimeConfigSource->loadConfig() #14 /var/www/html/magento/vendor/magento/framework/App/Config/ConfigSourceAggregated.php(40): Magento\Config\App\Config\Source\RuntimeConfigSource->get('') #15 /var/www/html/magento/var/generation/Magento/Framework/App/Config/ConfigSourceAggregated/Proxy.php(95): Magento\Framework\App\Config\ConfigSourceAggregated->get('') #16 /var/www/html/magento/vendor/magento/module-config/App/Config/Type/System.php(98): Magento\Framework\App\Config\ConfigSourceAggregated\Proxy->get() #17 /var/www/html/magento/vendor/magento/framework/App/Config.php(139): Magento\Config\App\Config\Type\System->get('default/web/sec...') #18 /var/www/html/magento/vendor/magento/framework/App/Config.php(90): Magento\Framework\App\Config->get('system', 'default/web/sec...') #19 /var/www/html/magento/vendor/magento/framework/App/Config.php(103): Magento\Framework\App\Config->getValue('web/secure/use_...', 'default', NULL) #20 /var/www/html/magento/vendor/magento/module-store/Model/HeaderProvider/Hsts.php(48): Magento\Framework\App\Config->isSetFlag('web/secure/use_...') #21 /var/www/html/magento/vendor/magento/framework/App/Response/HeaderManager.php(41): Magento\Store\Model\HeaderProvider\Hsts->canApply() #22 /var/www/html/magento/vendor/magento/framework/Interception/Interceptor.php(123): Magento\Framework\App\Response\HeaderManager->beforeSendResponse(Object(Magento\Framework\App\Response\Http\Interceptor)) #23 /var/www/html/magento/var/generation/Magento/Framework/App/Response/Http/Interceptor.php(117): Magento\Framework\App\Response\Http\Interceptor->___callPlugins('sendResponse', Array, Array) #24 /var/www/html/magento/vendor/magento/framework/App/Http.php(185): Magento\Framework\App\Response\Http\Interceptor->sendResponse() #25 /var/www/html/magento/vendor/magento/framework/App/Http.php(156): Magento\Framework\App\Http->handleDeveloperMode(Object(Magento\Framework\App\Bootstrap), Object(ReflectionException)) #26 /var/www/html/magento/vendor/magento/framework/App/Bootstrap.php(263): Magento\Framework\App\Http->catchException(Object(Magento\Framework\App\Bootstrap), Object(ReflectionException)) #27 /var/www/html/magento/index.php(39): Magento\Framework\App\Bootstrap->run(Object(Magento\Framework\App\Http)) #28 {main} Next ReflectionException: Class Magento\Store\Model\ResourceModel\Group\CollectionFactory does not exist in /var/www/html/magento/vendor/magento/framework/Code/Reader/ClassReader.php:37 Stack trace: #0 /var/www/html/magento/vendor/magento/framework/ObjectManager/Definition/Runtime.php(44): Magento\Framework\Code\Reader\ClassReader->getConstructor('Magento\\Store\\M...') #1 /var/www/html/magento/vendor/magento/framework/ObjectManager/Factory/Dynamic/Developer.php(71): Magento\Framework\ObjectManager\Definition\Runtime->getParameters('Magento\\Store\\M...') #2 /var/www/html/magento/vendor/magento/framework/ObjectManager/ObjectManager.php(71): Magento\Framework\ObjectManager\Factory\Dynamic\Developer->create('Magento\\Store\\M...') #3 /var/www/html/magento/vendor/magento/framework/ObjectManager/Factory/AbstractFactory.php(126): Magento\Framework\ObjectManager\ObjectManager->get('Magento\\Store\\M...') #4 /var/www/html/magento/vendor/magento/framework/ObjectManager/Factory/Dynamic/Developer.php(53): Magento\Framework\ObjectManager\Factory\AbstractFactory->resolveArgument(Array, 'Magento\\Store\\A...', NULL, 'groupRepository', 'Magento\\Store\\M...') #5 /var/www/html/magento/vendor/magento/framework/ObjectManager/Factory/Dynamic/Developer.php(82): Magento\Framework\ObjectManager\Factory\Dynamic\Developer->_resolveArguments('Magento\\Store\\M...', Array, Array) #6 /var/www/html/magento/vendor/magento/framework/ObjectManager/ObjectManager.php(71): Magento\Framework\ObjectManager\Factory\Dynamic\Developer->create('Magento\\Store\\M...') #7 /var/www/html/magento/var/generation/Magento/Store/Model/StoreManagerInterface/Proxy.php(84): Magento\Framework\ObjectManager\ObjectManager->get('Magento\\Store\\M...') #8 /var/www/html/magento/var/generation/Magento/Store/Model/StoreManagerInterface/Proxy.php(135): Magento\Store\Model\StoreManagerInterface\Proxy->_getSubject() #9 /var/www/html/magento/vendor/magento/module-store/Model/Resolver/Website.php(30): Magento\Store\Model\StoreManagerInterface\Proxy->getWebsite('1') #10 /var/www/html/magento/vendor/magento/framework/App/Config/ScopeCodeResolver.php(49): Magento\Store\Model\Resolver\Website->getScope('1') #11 /var/www/html/magento/vendor/magento/module-config/App/Config/Source/RuntimeConfigSource.php(82): Magento\Framework\App\Config\ScopeCodeResolver->resolve('websites', '1') #12 /var/www/html/magento/vendor/magento/module-config/App/Config/Source/RuntimeConfigSource.php(58): Magento\Config\App\Config\Source\RuntimeConfigSource->loadConfig() #13 /var/www/html/magento/vendor/magento/framework/App/Config/ConfigSourceAggregated.php(40): Magento\Config\App\Config\Source\RuntimeConfigSource->get('') #14 /var/www/html/magento/var/generation/Magento/Framework/App/Config/ConfigSourceAggregated/Proxy.php(95): Magento\Framework\App\Config\ConfigSourceAggregated->get('') #15 /var/www/html/magento/vendor/magento/module-config/App/Config/Type/System.php(98): Magento\Framework\App\Config\ConfigSourceAggregated\Proxy->get() #16 /var/www/html/magento/vendor/magento/framework/App/Config.php(139): Magento\Config\App\Config\Type\System->get('default/web/sec...') #17 /var/www/html/magento/vendor/magento/framework/App/Config.php(90): Magento\Framework\App\Config->get('system', 'default/web/sec...') #18 /var/www/html/magento/vendor/magento/framework/App/Config.php(103): Magento\Framework\App\Config->getValue('web/secure/use_...', 'default', NULL) #19 /var/www/html/magento/vendor/magento/module-store/Model/HeaderProvider/Hsts.php(48): Magento\Framework\App\Config->isSetFlag('web/secure/use_...') #20 /var/www/html/magento/vendor/magento/framework/App/Response/HeaderManager.php(41): Magento\Store\Model\HeaderProvider\Hsts->canApply() #21 /var/www/html/magento/vendor/magento/framework/Interception/Interceptor.php(123): Magento\Framework\App\Response\HeaderManager->beforeSendResponse(Object(Magento\Framework\App\Response\Http\Interceptor)) #22 /var/www/html/magento/var/generation/Magento/Framework/App/Response/Http/Interceptor.php(117): Magento\Framework\App\Response\Http\Interceptor->___callPlugins('sendResponse', Array, Array) #23 /var/www/html/magento/vendor/magento/framework/App/Http.php(185): Magento\Framework\App\Response\Http\Interceptor->sendResponse() #24 /var/www/html/magento/vendor/magento/framework/App/Http.php(156): Magento\Framework\App\Http->handleDeveloperMode(Object(Magento\Framework\App\Bootstrap), Object(ReflectionException)) #25 /var/www/html/magento/vendor/magento/framework/App/Bootstrap.php(263): Magento\Framework\App\Http->catchException(Object(Magento\Framework\App\Bootstrap), Object(ReflectionException)) #26 /var/www/html/magento/index.php(39): Magento\Framework\App\Bootstrap->run(Object(Magento\Framework\App\Http)) #27 {main}