Magento 2.2.6更新到Magento 2.3失败

问题描述 投票:2回答:3

前提条件

Magento 2.2.6当前PHP版本:PHP 7.1.22

重现步骤

  1. 进入系统> Web设置向导
  2. 单击系统升级
  3. 开始更新过程。

更新过程将在步骤2停止,并显示以下错误消息:检查组件依赖关系我们发现了冲突的组件依赖关系。隐藏细节

命令“update”失败:使用包信息加载composer存储库更新依赖项(包括require-dev)无法将您的需求解析为可安装的软件包集。

问题1 - magento/product-community-edition 2.3.0 requires magento/magento2-base 2.3.0 -> satisfiable by magento/magento2-base[2.3.0]. - Conclusion: don't install symfony/console v2.8.38 - Conclusion: don't install symfony/console v4.1.6|install symfony/console v2.8.38 - Conclusion: don't install symfony/console v4.1.7|install symfony/console v2.8.38 - Conclusion: don't install symfony/console v4.1.8|install symfony/console v2.8.38 - Conclusion: don't install symfony/console v3.4.19|install symfony/console v4.1.6|install symfony/console v4.1.7|install symfony/console v4.1.8 - Conclusion: don't install symfony/console v4.1.2|install symfony/console v2.8.38|install symfony/console v3.4.19 - Conclusion: don't install symfony/console v4.1.3|install symfony/console v2.8.38|install symfony/console v3.4.19 - Conclusion: don't install symfony/console v4.1.4|install symfony/console v2.8.38|install symfony/console v3.4.19 - Installation request for magento/product-community-edition 2.3.0 -> satisfiable by magento/product-community-edition[2.3.0]. - Conclusion: don't install symfony/console v4.1.5|install symfony/console v2.8.38|install symfony/console v3.4.19 - Installation request for sebastian/phpcpd 2.0.4 -> satisfiable by sebastian/phpcpd[2.0.4]. - Conclusion: don't install symfony/console v3.4.18|install symfony/console v4.1.2|install symfony/console v4.1.3|install symfony/console v4.1.4|install symfony/console v4.1.5|install symfony/console v4.1.6|install symfony/console v4.1.7|install symfony/console v4.1.8 - sebastian/phpcpd 2.0.4 requires symfony/console ~2.7|^3.0 -> satisfiable by symfony/console[v2.7.0, v2.7.1, v2.7.10, v2.7.11, v2.7.12, v2.7.13, v2.7.14, v2.7.15, v2.7.16, v2.7.17, v2.7.18, v2.7.19, v2.7.2, v2.7.20, v2.7.21, v2.7.22, v2.7.23, v2.7.24, v2.7.25, v2.7.26, v2.7.27, v2.7.28, v2.7.29, v2.7.3, v2.7.30, v2.7.31, v2.7.32, v2.7.33, v2.7.34, v2.7.35, v2.7.36, v2.7.37, v2.7.38, v2.7.39, v2.7.4, v2.7.40, v2.7.41, v2.7.42, v2.7.43, v2.7.44, v2.7.45, v2.7.46, v2.7.47, v2.7.48, v2.7.49, v2.7.5, v2.7.6, v2.7.7, v2.7.8, v2.7.9, v2.8.0, v2.8.1, v2.8.10, v2.8.11, v2.8.12, v2.8.13, v2.8.14, v2.8.15, v2.8.16, v2.8.17, v2.8.18, v2.8.19, v2.8.2, v2.8.20, v2.8.21, v2.8.22, v2.8.23, v2.8.24, v2.8.25, v2.8.26, v2.8.27, v2.8.28, v2.8.29, v2.8.3, v2.8.30, v2.8.31, v2.8.32, v2.8.33, v2.8.34, v2.8.35, v2.8.36, v2.8.37, v2.8.38, v2.8.39, v2.8.4, v2.8.40, v2.8.41, v2.8.42, v2.8.43, v2.8.44, v2.8.45, v2.8.46, v2.8.47, v2.8.48, v2.8.5, v2.8.6, v2.8.7, v2.8.8, v2.8.9, v3.0.0, v3.0.1, v3.0.2, v3.0.3, v3.0.4, v3.0.5, v3.0.6, v3.0.7, v3.0.8, v3.0.9, v3.1.0, v3.1.1, v3.1.10, v3.1.2, v3.1.3, v3.1.4, v3.1.5, v3.1.6, v3.1.7, v3.1.8, v3.1.9, v3.2.0, v3.2.1, v3.2.10, v3.2.11, v3.2.12, v3.2.13, v3.2.14, v3.2.2, v3.2.3, v3.2.4, v3.2.5, v3.2.6, v3.2.7, v3.2.8, v3.2.9, v3.3.0, v3.3.1, v3.3.10, v3.3.11, v3.3.12, v3.3.13, v3.3.14, v3.3.15, v3.3.16, v3.3.17, v3.3.18, v3.3.2, v3.3.3, v3.3.4, v3.3.5, v3.3.6, v3.3.7, v3.3.8, v3.3.9, v3.4.0, v3.4.1, v3.4.10, v3.4.11, v3.4.12, v3.4.13, v3.4.14, v3.4.15, v3.4.16, v3.4.17, v3.4.18, v3.4.19, v3.4.2, v3.4.3, v3.4.4, v3.4.5, v3.4.6, v3.4.7, v3.4.8, v3.4.9]. - Can only install one of: symfony/console[v4.1.0, v2.7.0]. - Can only install one of: symfony/console[v4.1.0, v2.7.1]. - Can only install one of: symfony/console[v4.1.0, v2.7.10]. - Can only install one of: symfony/console[v4.1.0, v2.7.11]. - Can only install one of: symfony/console[v4.1.0, v2.7.12]. - Can only install one of: symfony/console[v4.1.0, v2.7.13]. - Can only install one of: symfony/console[v4.1.0, v2.7.14]. - Can only install one of: symfony/console[v4.1.0, v2.7.15]. - Can only install one of: symfony/console[v4.1.0, v2.7.16]. - Can only install one of: symfony/console[v4.1.0, v2.7.17]. - Can only install one of: symfony/console[v4.1.0, v2.7.18]. - Can only install one of: symfony/console[v4.1.0, v2.7.19]. - Can only install one of: symfony/console[v4.1.0, v2.7.2]. - Can only install one of: symfony/console[v4.1.0, v2.7.20]. - Can only install one of: symfony/console[v4.1.0, v2.7.21]. - Can only install one of: symfony/console[v4.1.0, v2.7.22]. - Can only install one of: symfony/console[v4.1.0, v2.7.23]. - Can only install one of: symfony/console[v4.1.0, v2.7.24]. - Can only install one of: symfony/console[v4.1.0, v2.7.25]. - Can only install one of: symfony/console[v4.1.0, v2.7.26]. - Can only install one of: symfony/console[v4.1.0, v2.7.27]. - Can only install one of: symfony/console[v4.1.0, v2.7.28]. - Can only install one of: symfony/console[v4.1.0, v2.7.29]. - Can only install one of: symfony/console[v4.1.0, v2.7.3]. - Can only install one of: symfony/console[v4.1.0, v2.7.30]. - Can only install one of: symfony/console[v4.1.0, v2.7.31]. - Can only install one of: symfony/console[v4.1.0, v2.7.32]. - Can only install one of: symfony/console[v4.1.0, v2.7.33]. - Can only install one of: symfony/console[v4.1.0, v2.7.34]. - Can only install one of: symfony/console[v4.1.0, v2.7.35]. - Can only install one of: symfony/console[v4.1.0, v2.7.36]. - Can only install one of: symfony/console[v4.1.0, v2.7.37]. - Can only install one of: symfony/console[v4.1.0, v2.7.38]. - Can only install one of: symfony/console[v4.1.0, v2.7.39]. - Can only install one of: symfony/console[v4.1.0, v2.7.4]. - Can only install one of: symfony/console[v4.1.0, v2.7.40]. - Can only install one of: symfony/console[v4.1.0, v2.7.41]. - Can only install one of: symfony/console[v4.1.0, v2.7.42]. - Can only install one of: symfony/console[v4.1.0, v2.7.43]. - Can only install one of: symfony/console[v4.1.0, v2.7.44]. - Can only install one of: symfony/console[v4.1.0, v2.7.45]. - Can only install one of: symfony/console[v4.1.0, v2.7.46]. - Can only install one of: symfony/console[v4.1.0, v2.7.47]. - Can only install one of: symfony/console[v4.1.0, v2.7.48]. - Can only install one of: symfony/console[v4.1.0, v2.7.49]. - Can only install one of: symfony/console[v4.1.0, v2.7.5]. - Can only install one of: symfony/console[v4.1.0, v2.7.6]. - Can only install one of: symfony/console[v4.1.0, v2.7.7]. - Can only install one of: symfony/console[v4.1.0, v2.7.8]. - Can only install one of: symfony/console[v4.1.0, v2.7.9]. - Can only install one of: symfony/console[v4.1.0, v2.8.0]. - Can only install one of: symfony/console[v4.1.0, v2.8.1]. - Can only install one of: symfony/console[v4.1.0, v2.8.10]. - Can only install one of: symfony/console[v4.1.0, v2.8.11]. - Can only install one of: symfony/console[v4.1.0, v2.8.12]. - Can only install one of: symfony/console[v4.1.0, v2.8.13]. - Can only install one of: symfony/console[v4.1.0, v2.8.14]. - Can only install one of: symfony/console[v4.1.0, v2.8.15]. - Can only install one of: symfony/console[v4.1.0, v2.8.16]. - Can only install one of: symfony/console[v4.1.0, v2.8.17]. - Can only install one of: symfony/console[v4.1.0, v2.8.18]. - Can only install one of: symfony/console[v4.1.0, v2.8.19]. - Can only install one of: symfony/console[v4.1.0, v2.8.2]. - Can only install one of: symfony/console[v4.1.0, v2.8.20]. - Can only install one of: symfony/console[v4.1.0, v2.8.21]. - Can only install one of: symfony/console[v4.1.0, v2.8.22]. - Can only install one of: symfony/console[v4.1.0, v2.8.23]. - Can only install one of: symfony/console[v4.1.0, v2.8.24]. - Can only install one of: symfony/console[v4.1.0, v2.8.25]. - Can only install one of: symfony/console[v4.1.0, v2.8.26]. - Can only install one of: symfony/console[v4.1.0, v2.8.27]. - Can only install one of: symfony/console[v4.1.0, v2.8.28]. - Can only install one of: symfony/console[v4.1.0, v2.8.29]. - Can only install one of: symfony/console[v4.1.0, v2.8.3]. - Can only install one of: symfony/console[v4.1.0, v2.8.30]. - Can only install one of: symfony/console[v4.1.0, v2.8.31]. - Can only install one of: symfony/console[v4.1.0, v2.8.32]. - Can only install one of: symfony/console[v4.1.0, v2.8.33]. - Can only install one of: symfony/console[v4.1.0, v2.8.34]. - Can only install one of: symfony/console[v4.1.0, v2.8.35]. - Can only install one of: symfony/console[v4.1.0, v2.8.36]. - Can only install one of: symfony/console[v4.1.0, v2.8.37]. - Can only install one of: symfony/console[v4.1.0, v2.8.39]. - Can only install one of: symfony/console[v4.1.0, v2.8.4]. - Can only install one of: symfony/console[v4.1.0, v2.8.40]. - Can only install one of: symfony/console[v4.1.0, v2.8.41]. - Can only install one of: symfony/console[v4.1.0, v2.8.42]. - Can only install one of: symfony/console[v4.1.0, v2.8.43]. - Can only install one of: symfony/console[v4.1.0, v2.8.44]. - Can only install one of: symfony/console[v4.1.0, v2.8.45]. - Can only install one of: symfony/console[v4.1.0, v2.8.46]. - Can only install one of: symfony/console[v4.1.0, v2.8.47]. - Can only install one of: symfony/console[v4.1.0, v2.8.48]. - Can only install one of: symfony/console[v4.1.0, v2.8.5]. - Can only install one of: symfony/console[v4.1.0, v2.8.6]. - Can only install one of: symfony/console[v4.1.0, v2.8.7]. - Can only install one of: symfony/console[v4.1.0, v2.8.8]. - Can only install one of: symfony/console[v4.1.0, v2.8.9]. - Can only install one of: symfony/console[v4.1.0, v3.0.0]. - Can only install one of: symfony/console[v4.1.0, v3.0.1]. - Can only install one of: symfony/console[v4.1.0, v3.0.2]. - Can only install one of: symfony/console[v4.1.0, v3.0.3]. - Can only install one of: symfony/console[v4.1.0, v3.0.4]. - Can only install one of: symfony/console[v4.1.0, v3.0.5]. - Can only install one of: symfony/console[v4.1.0, v3.0.6]. - Can only install one of: symfony/console[v4.1.0, v3.0.7]. - Can only install one of: symfony/console[v4.1.0, v3.0.8]. - Can only install one of: symfony/console[v4.1.0, v3.0.9]. - Can only install one of: symfony/console[v4.1.0, v3.1.0]. - Can only install one of: symfony/console[v4.1.0, v3.1.1]. - Can only install one of: symfony/console[v4.1.0, v3.1.10]. - Can only install one of: symfony/console[v4.1.0, v3.1.2]. - Can only install one of: symfony/console[v4.1.0, v3.1.3]. - Can only install one of: symfony/console[v4.1.0, v3.1.4]. - Can only install one of: symfony/console[v4.1.0, v3.1.5]. - Can only install one of: symfony/console[v4.1.0, v3.1.6]. - Can only install one of: symfony/console[v4.1.0, v3.1.7]. - Can only install one of: symfony/console[v4.1.0, v3.1.8]. - Can only install one of: symfony/console[v4.1.0, v3.1.9]. - Can only install one of: symfony/console[v4.1.0, v3.2.0]. - Can only install one of: symfony/console[v4.1.0, v3.2.1]. - Can only install one of: symfony/console[v4.1.0, v3.2.10]. - Can only install one of: symfony/console[v4.1.0, v3.2.11]. - Can only install one of: symfony/console[v4.1.0, v3.2.12]. - Can only install one of: symfony/console[v4.1.0, v3.2.13]. - Can only install one of: symfony/console[v4.1.0, v3.2.14]. - Can only install one of: symfony/console[v4.1.0, v3.2.2]. - Can only install one of: symfony/console[v4.1.0, v3.2.3]. - Can only install one of: symfony/console[v4.1.0, v3.2.4]. - Can only install one of: symfony/console[v4.1.0, v3.2.5]. - Can only install one of: symfony/console[v4.1.0, v3.2.6]. - Can only install one of: symfony/console[v4.1.0, v3.2.7]. - Can only install one of: symfony/console[v4.1.0, v3.2.8]. - Can only install one of: symfony/console[v4.1.0, v3.2.9]. - Can only install one of: symfony/console[v4.1.0, v3.3.0]. - Can only install one of: symfony/console[v4.1.0, v3.3.1]. - Can only install one of: symfony/console[v4.1.0, v3.3.10]. - Can only install one of: symfony/console[v4.1.0, v3.3.11]. - Can only install one of: symfony/console[v4.1.0, v3.3.12]. - Can only install one of: symfony/console[v4.1.0, v3.3.13]. - Can only install one of: symfony/console[v4.1.0, v3.3.14]. - Can only install one of: symfony/console[v4.1.0, v3.3.15]. - Can only install one of: symfony/console[v4.1.0, v3.3.16]. - Can only install one of: symfony/console[v4.1.0, v3.3.17]. - Can only install one of: symfony/console[v4.1.0, v3.3.18]. - Can only install one of: symfony/console[v4.1.0, v3.3.2]. - Can only install one of: symfony/console[v4.1.0, v3.3.3]. - Can only install one of: symfony/console[v4.1.0, v3.3.4]. - Can only install one of: symfony/console[v4.1.0, v3.3.5]. - Can only install one of: symfony/console[v4.1.0, v3.3.6]. - Can only install one of: symfony/console[v4.1.0, v3.3.7]. - Can only install one of: symfony/console[v4.1.0, v3.3.8]. - Can only install one of: symfony/console[v4.1.0, v3.3.9]. - Can only install one of: symfony/console[v4.1.0, v3.4.0]. - Can only install one of: symfony/console[v4.1.0, v3.4.1]. - Can only install one of: symfony/console[v4.1.0, v3.4.10]. - Can only install one of: symfony/console[v4.1.0, v3.4.11]. - Can only install one of: symfony/console[v4.1.0, v3.4.12]. - Can only install one of: symfony/console[v4.1.0, v3.4.13]. - Can only install one of: symfony/console[v4.1.0, v3.4.14]. - Can only install one of: symfony/console[v4.1.0, v3.4.15]. - Can only install one of: symfony/console[v4.1.0, v3.4.16]. - Can only install one of: symfony/console[v4.1.0, v3.4.17]. - Can only install one of: symfony/console[v4.1.0, v3.4.2]. - Can only install one of: symfony/console[v4.1.0, v3.4.3]. - Can only install one of: symfony/console[v4.1.0, v3.4.4]. - Can only install one of: symfony/console[v4.1.0, v3.4.5]. - Can only install one of: symfony/console[v4.1.0, v3.4.6]. - Can only install one of: symfony/console[v4.1.0, v3.4.7]. - Can only install one of: symfony/console[v4.1.0, v3.4.8]. - Can only install one of: symfony/console[v4.1.0, v3.4.9].

修复

我运行以下命令:composer require --dev phpunit/phpunit:~6.2.0 friendsofphp/php-cs-fixer:~2.10.1 lusitanian/oauth:~0.8.10 pdepend/pdepend:2.5.2 sebastian/phpcpd:~3.0.0 squizlabs/php_codesniffer:3.2.2 --no-update

这解决了问题,我能够从后端将Magento升级到2.3,但它又产生了另一个问题:服务暂时不可用由于维护停机或容量问题,服务器暂时无法为您的请求提供服务。请稍后再试。

我试着运行这个命令:

bin/magento setup:static-content:deploy

我在SSH上收到此错误:

#0 /chroot/home/[MY ROOT]/vendor/zendframework/zend-servicemanager/src/Config.php(137): Zend\ServiceManager\ServiceManager->addAbstractFactory('Zend\\Mvc\\Contro...')
#1 /chroot/home/[MY ROOT]/vendor/zendframework/zend-modulemanager/src/Listener/ServiceListener.php(225): Zend\ServiceManager\Config->configureServiceManager(Object(Zend\Mvc\Controller\ControllerManager))
#2 [internal function]: Zend\ModuleManager\Listener\ServiceListener->onLoadModulesPost(Object(Zend\ModuleManager\ModuleEvent))
#3 /chroot/home[MY ROOT]/vendor/zendframework/zend-eventmanager/src/EventManager.php(490): call_user_func(Array, Object(Zend\ModuleManager\ModuleEvent))

我该如何解决这个问题?

php symfony magento2 magento2.2
3个回答
1
投票

升级到版本2.3.0时,我也面临同样的问题。然后我尝试进行一些更改,然后再升级到2.3.0版

以下是升级到2.3.0版的步骤

第1步:启用开发者模式

php bin/magento deploy:mode:set developer

第2步:在升级到Magento 2.3之前,您需要运行以下命令

composer config preferred-install dist
composer config sort-packages true
composer config prefer-stable true

第3步:现在您需要将composer.json文件修复到Magento 2.3版本

composer require --dev friendsofphp/php-cs-fixer:~2.10.0 --no-update

第4步:升级到Magento 2.3.0

composer require --dev sebastian/phpcpd:~3.0.0 --no-update

步骤5:运行以下命令

php -r '$autoload=json_decode(file_get_contents("composer.json"), true); $autoload["autoload"]["psr-4"]["Zend\\Mvc\\Controller\\"]= "setup/src/Zend/Mvc/Controller/"; file_put_contents("composer.json", json_encode($autoload, JSON_PRETTY_PRINT|JSON_UNESCAPED_SLASHES));'

步骤6:运行升级命令

composer update

第7步:升级命令

php bin/magento setup:upgrade

0
投票

Magento2有问题。您无法使用Web安装向导来更新其版本。你应该直接运行命令:

cd to_your_magento_root_dir
composer install
php bin/magento s:up 

但是如果你安装了一些自定义模块,你将面临许多错误。


0
投票

this

这样就可以了

php -f pre_composer_update_2.3.php -- --root='/var/www/html' --repo=https://repo.magento.com/
© www.soinside.com 2019 - 2024. All rights reserved.