[Akonadi] [Bug 354536] Akonadi fails to migrate database from version 30 (foreign key constraint fails)

2016-03-10 Thread Daniel Vrátil via KDE Bugzilla
https://bugs.kde.org/show_bug.cgi?id=354536

--- Comment #9 from Daniel Vrátil  ---
There seem to be more and more people affected by this as distros slowly adopt
KF5-based KDE PIM and I now realized that you can't possibly run akonadictl
fsck when Akonadi is not running because your DB is inconsistent :) so I merged
the patch from Lukas.

I like the idea about automatically running fsck before schema upgrade, I'll
see if we can implement it for 16.04.

Thanks for the patch Lukas!

-- 
You are receiving this mail because:
You are the assignee for the bug.
___
Kdepim-bugs mailing list
Kdepim-bugs@kde.org
https://mail.kde.org/mailman/listinfo/kdepim-bugs


[Akonadi] [Bug 354536] Akonadi fails to migrate database from version 30 (foreign key constraint fails)

2016-03-10 Thread Daniel Vrátil via KDE Bugzilla
https://bugs.kde.org/show_bug.cgi?id=354536

Daniel Vrátil  changed:

   What|Removed |Added

  Latest Commit||http://commits.kde.org/akon
   ||adi/989f7eba0d1b093e00730a8
   ||444a9c088a3805ffd
   Version Fixed In||15.12.3

--- Comment #8 from Daniel Vrátil  ---
Git commit 989f7eba0d1b093e00730a8444a9c088a3805ffd by Daniel Vrátil, on behalf
of Lukáš Karas.
Committed on 11/03/2016 at 00:10.
Pushed by dvratil into branch 'Applications/15.12'.

Clean orphaned relations when upgrading DB schema to r31

Commit 54e1f097 introduced automatic recovery of missing foreign keys during
startup (this has been accompanied by DB schema upgrade to revision 31). If
they FKs were previously missing MySQL will fail to create the keys and Akonadi
startup will fail.

To make sure there are no inconsistencies in DB we manually delete all orphaned
relations before proceeding with the DB check.
FIXED-IN: 15.12.3

M  +60   -0src/server/storage/dbupdate.xml

http://commits.kde.org/akonadi/989f7eba0d1b093e00730a8444a9c088a3805ffd

-- 
You are receiving this mail because:
You are the assignee for the bug.
___
Kdepim-bugs mailing list
Kdepim-bugs@kde.org
https://mail.kde.org/mailman/listinfo/kdepim-bugs


[Akonadi] [Bug 354536] Akonadi fails to migrate database from version 30 (foreign key constraint fails)

2016-01-04 Thread Lukáš Karas via KDE Bugzilla
https://bugs.kde.org/show_bug.cgi?id=354536

--- Comment #7 from Lukáš Karas  ---
Good to know that. What about automatic fsck operation before every schema
upgrade? We can avoid similar situations in the future. But we should trust
fsck code and keep it updated then...

-- 
You are receiving this mail because:
You are the assignee for the bug.
___
Kdepim-bugs mailing list
Kdepim-bugs@kde.org
https://mail.kde.org/mailman/listinfo/kdepim-bugs


[Akonadi] [Bug 354536] Akonadi fails to migrate database from version 30 (foreign key constraint fails)

2016-01-03 Thread Daniel Vrátil via KDE Bugzilla
https://bugs.kde.org/show_bug.cgi?id=354536

Daniel Vrátil  changed:

   What|Removed |Added

 Resolution|--- |FIXED
 CC||dvra...@kde.org
 Status|UNCONFIRMED |RESOLVED

--- Comment #6 from Daniel Vrátil  ---
Running "akonadictl fsck" will make sure that are no duplicate or invalid
entriers. After that the update from revision 30 should be OK.

Note that although "akonadictl fsck" returns immediatelly, the actual task,
which is running on the Server may take couple minutes to complete (this was
fixed in 15.12)

-- 
You are receiving this mail because:
You are the assignee for the bug.
___
Kdepim-bugs mailing list
Kdepim-bugs@kde.org
https://mail.kde.org/mailman/listinfo/kdepim-bugs


[Akonadi] [Bug 354536] Akonadi fails to migrate database from version 30 (foreign key constraint fails)

2015-12-30 Thread Teemu Rytilahti via KDE Bugzilla
https://bugs.kde.org/show_bug.cgi?id=354536

Teemu Rytilahti  changed:

   What|Removed |Added

 CC||t...@iki.fi

--- Comment #5 from Teemu Rytilahti  ---
I can confirm this on Arch with Mariadb, with Akonadi 15.12.0-1 and Mariadb
10.1.10-1.

-- 
You are receiving this mail because:
You are the assignee for the bug.
___
Kdepim-bugs mailing list
Kdepim-bugs@kde.org
https://mail.kde.org/mailman/listinfo/kdepim-bugs


[Akonadi] [Bug 354536] Akonadi fails to migrate database from version 30 (foreign key constraint fails)

2015-12-21 Thread via KDE Bugzilla
https://bugs.kde.org/show_bug.cgi?id=354536

aux...@gmail.com changed:

   What|Removed |Added

 CC||aux...@gmail.com

--- Comment #4 from aux...@gmail.com ---
I have the same problem now that I upgraded akonadi to 15.12 on openSUSE Leap
42.1. I fixed it by deleting the non-matching rows with the patch in comment #2
(by the way, the second delete misses "AS id" after flag_id).

-- 
You are receiving this mail because:
You are the assignee for the bug.
___
Kdepim-bugs mailing list
Kdepim-bugs@kde.org
https://mail.kde.org/mailman/listinfo/kdepim-bugs


[Akonadi] [Bug 354536] Akonadi fails to migrate database from version 30 (foreign key constraint fails)

2015-12-20 Thread George L . Emigh via KDE Bugzilla
https://bugs.kde.org/show_bug.cgi?id=354536

George L. Emigh  changed:

   What|Removed |Added

 CC||ab...@georgelemigh.com

-- 
You are receiving this mail because:
You are the assignee for the bug.
___
Kdepim-bugs mailing list
Kdepim-bugs@kde.org
https://mail.kde.org/mailman/listinfo/kdepim-bugs


[Akonadi] [Bug 354536] Akonadi fails to migrate database from version 30 (foreign key constraint fails)

2015-12-13 Thread Martin Bednar via KDE Bugzilla
https://bugs.kde.org/show_bug.cgi?id=354536

Martin Bednar  changed:

   What|Removed |Added

 CC||seraf...@gmail.com

--- Comment #3 from Martin Bednar  ---
I think I just got hit by this.
Log here : https://paste.kde.org/paxixlmnn

Using a system-wide mysql server. (also used for web development)

-- 
You are receiving this mail because:
You are the assignee for the bug.
___
Kdepim-bugs mailing list
Kdepim-bugs@kde.org
https://mail.kde.org/mailman/listinfo/kdepim-bugs


[Akonadi] [Bug 354536] Akonadi fails to migrate database from version 30 (foreign key constraint fails)

2015-10-30 Thread Lukáš Karas via KDE Bugzilla
https://bugs.kde.org/show_bug.cgi?id=354536

--- Comment #2 from Lukáš Karas  ---
Created attachment 95224
  --> https://bugs.kde.org/attachment.cgi?id=95224=edit
dbupdate.patch

This patch with extra update queries fixes migration for me.

-- 
You are receiving this mail because:
You are the assignee for the bug.
___
Kdepim-bugs mailing list
Kdepim-bugs@kde.org
https://mail.kde.org/mailman/listinfo/kdepim-bugs


[Akonadi] [Bug 354536] Akonadi fails to migrate database from version 30 (foreign key constraint fails)

2015-10-29 Thread Lukáš Karas via KDE Bugzilla
https://bugs.kde.org/show_bug.cgi?id=354536

--- Comment #1 from Lukáš Karas  ---
This bug was probably solved for PostgreSQL backend by commit
54e1f0979a894d289110a1a71618ce7be54fe595 (
https://quickgit.kde.org/?p=akonadi.git=commit=54e1f0979a894d289110a1a71618ce7be54fe595
). In commit message Dan mentions that it should not happen with mysql backend. 

This problem did not affect MySQL which creates the FKs as part of CREATE TABLE
queries, or SQLite because we don't support FKs there (yet). 

I don't know why, but I don't have these FK in my database... What changes that
FK check works now? Should we add similar DELETE commands to dbupdate.xml for
mysql backend? For which db version? 31?

-- 
You are receiving this mail because:
You are the assignee for the bug.
___
Kdepim-bugs mailing list
Kdepim-bugs@kde.org
https://mail.kde.org/mailman/listinfo/kdepim-bugs