Skip to content
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

Error upgrading from version 0.2.7 to version 0.4.5 #561

Closed
migu opened this issue Jun 27, 2016 · 6 comments
Closed

Error upgrading from version 0.2.7 to version 0.4.5 #561

migu opened this issue Jun 27, 2016 · 6 comments
Labels

Comments

@migu
Copy link

migu commented Jun 27, 2016

This is similar to issue #530 but not identical.

Upgrading Baïkal from version 0.2.7 to version 0.4.5
Errors
Uncaught exception during upgrade: exception 'PDOException' with message 'SQLSTATE[42S01]: > Base table or view already exists: 1050 Table 'calendarchanges' already exists' in /var/www/baikal/Core/Frameworks/BaikalAdmin/Controller/Install/VersionUpgrade.php:183 Stack trace: #0 /var/www/baikal/Core/Frameworks/BaikalAdmin/Controller/Install/VersionUpgrade.php(183): PDO->exec('\n ...') #1 /var/www/baikal/Core/Frameworks/BaikalAdmin/Controller/Install/VersionUpgrade.php(61): BaikalAdmin\Controller\Install\VersionUpgrade->upgrade('0.2.7', '0.4.5') #2 /var/www/baikal/Core/Frameworks/Flake/Core/Render/Container.php(71): BaikalAdmin\Controller\Install\VersionUpgrade->render() #3 /var/www/baikal/Core/Frameworks/Flake/Controller/Page.php(85): Flake\Core\Render\Container->renderBlocks() #4 /var/www/baikal/html/admin/install/index.php(83): Flake\Controller\Page->render() #5 {main}

Successful operations
synctoken was added to calendars
ctag was removed from calendars

Error Baïkal has not been upgraded. See the section 'Errors' for details.

I found out how to workaround this. Drop the following four tables before opening the admin page:

  • addressbookchanges
  • calendarchanges
  • calendarsubscriptions
  • propertystorage

After this, the upgrade is successful.

Successful operations
synctoken was added to calendars
ctag was removed from calendars
calendarchanges was created
synctoken was added to addressbooks
ctag was removed from addressbooks
addressbookchanges was created
calendarsubscriptions was created
etag and size were added to cards
uid was added to calendarobjects
schedulingobjects was created
propertystorage was created
etag and size was recalculated for cards
uid was recalculated for calendarobjects
vcardurl was migrated to the propertystorage system

@evert
Copy link
Member

evert commented Jun 27, 2016

The only reason this would work if you attempted a previous upgrade, and that upgrade failed halfway through.

I'm closing this ticket, because without information about the original failure, there's not really anything sensible we can do about this.

@evert evert closed this as completed Jun 27, 2016
@migu
Copy link
Author

migu commented Jun 27, 2016

You're right. I should have provided more information. Next time.
Meanwhile my upgrade succeeded.

@evert
Copy link
Member

evert commented Jun 27, 2016

Hi @migu , just in case: it wasn't meant as a sort of criticism, and I did appreciate the report. It's just not something I can do something about ;)

@evert evert added the wontfix label Jun 27, 2016
@L45eMy
Copy link

L45eMy commented Nov 13, 2016

Had the same problem. The reason was that the config file was not writable by the web server and the version number could not be updated. So the update succeeded the first time, but trying to access the admin panel would try another database upgrade. I rolled back the database and fixed the rights for the two config php files in the Specific folder. Would be nice to get an error if the config file could not be written.

@zachow
Copy link

zachow commented Mar 3, 2019

I found out how to workaround this. Drop the following four tables before opening the admin page:

* addressbookchanges

* calendarchanges

* calendarsubscriptions

* propertystorage

could you please shortly explain what is meant by "drop the following 4 tables"?

I would like to try this.

Thx

@zachow
Copy link

zachow commented Mar 3, 2019

OK, got it. I deleted the four tables within the db and tried again:

However, I still receive an error (see below):

Errors
Uncaught exception during upgrade: Exception: Baikal\Model\Config->parseConfig(): constant 'BAIKAL_CARD_BASEURI' has been found multiple times in the config file; stopping execution in /mnt/web418/a3/03/5498703/htdocs/baikal/Core/Frameworks/Baikal/Model/Config.php:114 Stack trace: #0 /mnt/web418/a3/03/5498703/htdocs/baikal/Core/Frameworks/Baikal/Model/Config.php(40): Baikal\Model\Config->parseConfig('__construct('/mnt/web418/a3/...') #2 /mnt/web418/a3/03/5498703/htdocs/baikal/Core/Frameworks/BaikalAdmin/Controller/Install/VersionUpgrade.php(382): BaikalAdmin\Controller\Install\VersionUpgrade->updateConfiguredVersion('0.4.6') #3 /mnt/web418/a3/03/5498703/htdocs/baikal/Core/Frameworks/BaikalAdmin/Controller/Install/VersionUpgrade.php(61): BaikalAdmin\Controller\Install\VersionUpgrade->upgrade('0.2.7', '0.4.6') #4 /mnt/web418/a3/03/5498703/htdocs/baikal/Core/Frameworks/Flake/Core/Render/Container.php(71): BaikalAdmin\Controller\Install\VersionUpgrade->render() #5 /mnt/web418/a3/03/5498703/htdocs/baikal/Core/Frameworks/Flake/Controller/Page.php(85): Flake\Core\Render\Container->renderBlocks() #6 /mnt/web418/a3/03/5498703/htdocs/baikal/html/admin/install/index.php(83): Flake\Controller\Page->render() #7 {main}
Successful operations
synctoken was added to calendars
ctag was removed from calendars
calendarchanges was created
synctoken was added to addressbooks
ctag was removed from addressbooks
addressbookchanges was created
calendarsubscriptions was created
etag and size were added to cards
uid was added to calendarobjects
schedulingobjects was created
propertystorage was created
etag and size was recalculated for cards
uid was recalculated for calendarobjects
vcardurl was migrated to the propertystorage system

Error Baïkal has not been upgraded. See the section 'Errors' for details.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

4 participants