Hi,
after I encountered this problem I uninstalled and reinstalled migrate, migrate_upgrade and migrate_drupal. When trying to "Rerun" import via UI (/upgrade) I get the following errors:
Warning: mt_rand(): max(-1) is smaller than min(0) in Drupal\Core\Database\Database::parseConnectionInfo() (line 217 of core/lib/Drupal/Core/Database/Database.php).
Notice: Undefined offset: 0 in Drupal\Core\Database\Database::parseConnectionInfo() (line 217 of core/lib/Drupal/Core/Database/Database.php).
Notice: Undefined index: driver in Drupal\Core\Database\Database::openConnection() (line 369 of core/lib/Drupal/Core/Database/Database.php).
Notice: Undefined index: driver in Drupal\migrate_upgrade\Form\MigrateUpgradeForm->validateCredentialForm() (line 986 of modules/migrate_upgrade/src/Form/MigrateUpgradeForm.php).
Resolve the issue below to continue the upgrade. Driver not specified for this database connection: upgrade
I have not specified a database called "upgrade". This is what's in my settings.php:
$databases['drupal6_kupf']['default'] = array (
'database' => 'drupal6_kupf',
'username' => 'drupal6_kupf',
'password' => 'secret',
'prefix' => '',
'host' => 'localhost',
'port' => '3306',
'namespace' => 'Drupal\\Core\\Database\\Driver\\mysql',
'driver' => 'mysql',
);
$databases['default']['default'] = array (
'database' => 'drupal8_kupf',
'username' => 'kupf8',
'password' => 'secret',
'prefix' => '',
'host' => 'localhost',
'port' => '3306',
'namespace' => 'Drupal\\Core\\Database\\Driver\\mysql',
'driver' => 'mysql',
);
I there a way to change/set the database settings used for the upgrade process?
Comments
Comment #2
quietone commentedComment #3
Anonymous (not verified) commentedWhen using migrate_upgrade you input the database credentials in the UI and it adds another database keyed as "upgrade" (I believe it used to be called 'migrate' or 'migration' in past iterations). It does not show in settings.php but it is configured in the DB in the same way.
I was able to get around a similar error by defining that database using a similar syntax to what you currently have in settings.php:
You currently have:
$databases['drupal6_kupf']['default'] = array (I think you may be able to change it to:
$databases['upgrade']['default'] = array (... and this should override any previous database credentials you have entered in the UI. Of course this isn't a solution... it is a potential workaround.
Comment #5
mikeryanRerun is no longer part of the core UI.