New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Installation: when upgrading from 2.0.3 and reusing existing tables during install, sql error #4631
Comments
In d0e5faa: refs #4631 started to work on installing updates during installation in case we reuse existing tables. Problem: In case there are updates available and one of those updates writes a config the installer thinks we are already done. Therefore we do now create the config file as early as possible and before the install the updates. We create the config file once we have the database information. Also allows us to remove the db_infos session hack. While installation is in progress we set a flag in General currently named install_in_progress (tbd) |
Nice approach to fixing this! Feedback:
|
Done and should work. I've tested loads of different possibilities. Hope did not miss a special use case... |
…tallation in case we reuse existing tables. Problem: In case there are updates available and one of those updates writes a config the installer thinks we are already done. Therefore we do now create the config file as early as possible and before the install the updates. We create the config file once we have the database information. Also allows us to remove the db_infos session hack. While installation is in progress we set a flag in General currently named install_in_progress (tbd)
…cy, make sure the remove the install_in_progress key after successful installation
…already present during installation. This was not working before and removed it again after it is not that easy and not really doable with the current installer.
This ticket goal is to fix the installer in the use case of reinstalling over the same DB and reusing Piwik tables, as to not lose any data.
Use case:
There was an error when adding the Super User:
The reason is that the DB is still in version 2.0.3 and so the new column added in 2.0.4-b3 is not yet in the DB.
Solution:
As soon as "reuse tables" during the installation, we should run the Updater process (in the background), and report any error that may have occured during the update, as part of the installation process. If it was successful, maybe we write the message "The database was successfully updated from 2.0 to 2.0.4!"
Maybe in this case we could rename step 5 from "Creating the Tables" to "Reusing the Tables".
The text was updated successfully, but these errors were encountered: