Shopware installation error: Identifier DB not initialized yet
Asked Answered
O

1

6

After installation wizard is finished I get this error.

Slim Application Error The application could not run because of the following error:

Details

Type: RuntimeException
Message: Identifier DB not initialized yet
File: /.../recovery/install/src/ContainerProvider.php
Line: 162

Is there is some configuration file where I can set DB params? I had insert all params via installation wizard.

Odette answered 11/8, 2017 at 13:58 Comment(9)
There are 2 versions of shopware. From git repo and zip version from official website. Which one do you have?Nanine
Zip version from official site. . . Is version can be different depending on zip or git?Odette
Zip version is more like for show off to see how shopware looks like. And git version is for further development. So for zip version you need to create a database and you need to have a user for database who has all rights on to it. And then you can start the installationNanine
I had only created database without new user, only root. This look to me as problem? Can it be?Odette
Not 100% sure. But try to create a new user and grant all rights to that databaseNanine
Did you make it?Nanine
@Nanine I had remove php and reinstall again. This had done job. Mysql user was not problem.Odette
Btw, after composer install, project not working again. It is working with ziped vendor folder.Odette
Yeah I had a lot of problems too.... zip version breaks with any composer command. You need to git clone the version from git repo and install ant and then it will workNanine
M
9

In file recovery/install/src/ContainerProvider.php Add 2 strings:

  1. In use-section

use Shopware\Recovery\Update\Utils;

2.Inside the register-function:

$container['db'] = function ($c) {
            $conn = Utils::getConnection(SW_PATH);

            return $conn;
        };
Matsuyama answered 10/1, 2019 at 11:0 Comment(3)
Would you mind submitting that as a Merge Request to the Shopware Code? It does seem like a nice fixGaptoothed
I was facing the same issue and this suggestion helped me install Shopware on my hosting provider! Any reason why we would not have this fix in in the Shopware source code?Kinnard
This helped a lot, it still was a problem in the current shopware6-versionLitigation

© 2022 - 2024 — McMap. All rights reserved.