Magento2过时的问题

时间:2018-01-14 05:24:15

标签: magento magento2.2

我正在为magento2创建一个docker容器。使一切准备就绪,现在我从正在运行的容器中收到此错误。

  

以前通过更改权限修复了权限问题   对于所需的目录,我得到了他的错误。

我尝试了 ./ bin / magento setup:upgrade ,但没有解决问题。

1 exception(s):
Exception #0 (Magento\Framework\Exception\LocalizedException): Please update your modules: Run "composer install" from the Magento root directory.
The following modules are outdated:
Magento_Directory db schema version: defined in codebase - 2.0.1, currently installed - 2.0.2
Magento_Directory db data version: defined in codebase - 2.0.1, currently installed - 2.0.2
Magento_Catalog db schema version: defined in codebase - 2.2.3, currently installed - 2.2.4
Magento_Catalog db data version: defined in codebase - 2.2.3, currently installed - 2.2.4
Magento_Sales db schema version: defined in codebase - 2.0.7, currently installed - 2.0.9
Magento_Sales db data version: defined in codebase - 2.0.7, currently installed - 2.0.9

Exception #0 (Magento\Framework\Exception\LocalizedException): Please update your modules: Run "composer install" from the Magento root directory.
The following modules are outdated:
Magento_Directory db schema version: defined in codebase - 2.0.1, currently installed - 2.0.2
Magento_Directory db data version: defined in codebase - 2.0.1, currently installed - 2.0.2
Magento_Catalog db schema version: defined in codebase - 2.2.3, currently installed - 2.2.4
Magento_Catalog db data version: defined in codebase - 2.2.3, currently installed - 2.2.4
Magento_Sales db schema version: defined in codebase - 2.0.7, currently installed - 2.0.9
Magento_Sales db data version: defined in codebase - 2.0.7, currently installed - 2.0.9
#0 /var/www/html/magento2/lib/internal/Magento/Framework/Interception/Interceptor.php(121): Magento\Framework\Module\Plugin\DbStatusValidator->beforeDispatch(Object(Magento\Framework\App\FrontController\Interceptor), Object(Magento\Framework\App\Request\Http))
#1 /var/www/html/magento2/app/code/Magento/PageCache/Model/App/FrontController/BuiltinPlugin.php(73): Magento\Framework\App\FrontController\Interceptor->Magento\Framework\Interception\{closure}(Object(Magento\Framework\App\Request\Http))
#2 /var/www/html/magento2/lib/internal/Magento/Framework/Interception/Interceptor.php(135): Magento\PageCache\Model\App\FrontController\BuiltinPlugin->aroundDispatch(Object(Magento\Framework\App\FrontController\Interceptor), Object(Closure), Object(Magento\Framework\App\Request\Http))
#3 /var/www/html/magento2/lib/internal/Magento/Framework/Interception/Interceptor.php(153): Magento\Framework\App\FrontController\Interceptor->Magento\Framework\Interception\{closure}(Object(Magento\Framework\App\Request\Http))
#4 /var/www/html/magento2/generated/code/Magento/Framework/App/FrontController/Interceptor.php(26): Magento\Framework\App\FrontController\Interceptor->___callPlugins('dispatch', Array, Array)
#5 /var/www/html/magento2/lib/internal/Magento/Framework/App/Http.php(135): Magento\Framework\App\FrontController\Interceptor->dispatch(Object(Magento\Framework\App\Request\Http))
#6 /var/www/html/magento2/generated/code/Magento/Framework/App/Http/Interceptor.php(24): Magento\Framework\App\Http->launch()
#7 /var/www/html/magento2/lib/internal/Magento/Framework/App/Bootstrap.php(256): Magento\Framework\App\Http\Interceptor->launch()
#8 /var/www/html/magento2/pub/index.php(37): Magento\Framework\App\Bootstrap->run(Object(Magento\Framework\App\Http\Interceptor))
#9 {main}

1 个答案:

答案 0 :(得分:3)

这是Magento的错误消息传递

The following modules are outdated:
Magento_Directory db schema version: 
    defined in codebase - 2.0.1, currently installed - 2.0.2

更好的错误消息可能是“您的系统数据库配置了代码库中的模块之前的模块。

不知何故,系统上的module.xml文件。

#File: vendor/magento/module-directory/etc/module.xml
<config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:framework:Module/etc/module.xsd">
    <module name="Magento_Directory" setup_version="2.0.1">
        <sequence>
            <module name="Magento_Store"/>
        </sequence>
    </module>
</config>

有一个版本号,但MySQL中的安装表中的数据(或从此表中读取的缓存值)

mysql> SELECT * FROM setup_module WHERE module = 'Magento_Directory';
+-------------------+----------------+--------------+
| module            | schema_version | data_version |
+-------------------+----------------+--------------+
| Magento_Directory | 2.0.2          | 2.0.2        |
+-------------------+----------------+--------------+

不知何故,您已使用一组模块文件更新了系统,但实际为您提供文件的系统仍然是较旧的系统。