Evolution mbox export broken

Bug #996646 reported by Olivier Le Merdy
14
This bug affects 2 people
Affects Status Importance Assigned to Milestone
evolution (Ubuntu)
Confirmed
Undecided
Unassigned

Bug Description

Following Ubuntu suggestions and getting rid of Evolution which is painfully slow on my computer, I am trying to migrate to Thunderbird, using the "mbox export" feature available in Evolution.

Unfortunately, the feature seems to be broken in Evolution 3.2, as reported here: https://bugzilla.gnome.org/show_bug.cgi?id=667576. Short version is: each mail in the exported mailbox encapsulates the whole mail bundle plus their attachments, which make a few hundred mails take 1 GiB.

The bug is marked fixed as of Evolution 3.3.5, which has not been bundled in last Ubuntu update. Evolution team send pack to distribution provider to include the corresponding patch (http://git.gnome.org/browse/evolution/commit/?id=df3495a6ec99d53beeaac6b9a2fde8dfd356c439) in prior versions of Evolution.

I tried a number of workarounds, including installing a beta distribution in a VM with a current version of Evolution to use its export feature but, in addition to being a painfully long process, it simply does not work as Evolution 3.3.9 does not seem to correctly handle my 1.4 GiB archive file and miss half the mails bundled. For the few ones which made it through the archive/restore/export/import process, the result is perfectly OK though.

Manually exporting thousands of mails (yes, 10+ years ;)) does not seem reasonnable to me either.

Is there a plan to include this patch to help me and other people migrating to LTS 12.04 to use this feature?
Thanks by advance!

ProblemType: Bug
DistroRelease: Ubuntu 12.04
Package: evolution 3.2.3-0ubuntu6
ProcVersionSignature: Ubuntu 3.2.0-24.37-generic 3.2.14
Uname: Linux 3.2.0-24-generic i686
NonfreeKernelModules: nvidia
ApportVersion: 2.0.1-0ubuntu7
Architecture: i386
Date: Tue May 8 18:50:32 2012
ProcEnviron:
 LANGUAGE=fr_FR:fr:en_GB:en
 TERM=xterm
 PATH=(custom, user)
 LANG=fr_FR.UTF-8
 SHELL=/bin/bash
SourcePackage: evolution
UpgradeStatus: Upgraded to precise on 2012-04-27 (11 days ago)

Revision history for this message
Olivier Le Merdy (olivier-lemerdy) wrote :
Revision history for this message
Launchpad Janitor (janitor) wrote :

Status changed to 'Confirmed' because the bug affects multiple users.

Changed in evolution (Ubuntu):
status: New → Confirmed
Revision history for this message
AntoineM (antoine-merle) wrote :

Hi everyone,
I used the patch provided by the evolution team (http://git.gnome.org/browse/evolution/commit/id=df3495a6ec99d53beeaac6b9a2fde8dfd356c439) to fix the problem and backported it to the evolution version of ubuntu 12.04 "evolution_3.2.3-0ubuntu6". It turns out that only the package "libevolution_3.2.3-0ubuntu6" needs to be updated.

Here is how i proceded.

1. Uninstall libevolution and all related packages
   sudo apt-get remove libevolution

1.1 For me other packages were removed : evolution evolution-plugins libevolution

2. Get the evolution package source
   mkdir patch_evolution; cd patch_evolution
   sudo apt-get source evolution

3. Apply patch (be sure to download it first)
    patch -p0 < patch_libevolution

4. Build evolution's debian packages (some other packages may need to be installed first)
    sudo apt-get -b source evolution

4.1 Here is what I obtained
ls -1sh
total 40M
4,0K evolution-3.2.3
4,0K evolution_3.2.3-0ubuntu6_amd64.changes
704K evolution_3.2.3-0ubuntu6_amd64.deb
 96K evolution_3.2.3-0ubuntu6.debian.tar.gz
4,0K evolution_3.2.3-0ubuntu6.dsc
 12M evolution_3.2.3.orig.tar.xz
 15M evolution-common_3.2.3-0ubuntu6_all.deb
7,9M evolution-dbg_3.2.3-0ubuntu6_amd64.deb
864K evolution-dev_3.2.3-0ubuntu6_amd64.deb
748K evolution-plugins_3.2.3-0ubuntu6_amd64.deb
556K evolution-plugins-experimental_3.2.3-0ubuntu6_amd64.deb
2,8M libevolution_3.2.3-0ubuntu6_amd64.deb
4,0K patch_libevolution

5. install the new libevolution package (be sure to use the file you builded)
    sudo dpkg -i libevolution_3.2.3-0ubuntu6_amd64.deb

6. re-install previously removed packages
    sudo apt-get install evolution evolution-plugins

I tested this on some of my emails ...
708M test_1.mbox
 21M test_3_libev.mbox
... with success

Hope this helps,
Antoine

PS : This should definitely be included in an updated version of the package in the repository.

Revision history for this message
AntoineM (antoine-merle) wrote :

Here is the updated version of the libevolution package (for amd64 arch).

Revision history for this message
Ubuntu Foundations Team Bug Bot (crichton) wrote :

The attachment "Patch for the file evolution-3.2.3/mail/e-mail-folder-utils.c" of this bug report has been identified as being a patch. The ubuntu-reviewers team has been subscribed to the bug report so that they can review the patch. In the event that this is in fact not a patch you can resolve this situation by removing the tag 'patch' from the bug report and editing the attachment so that it is not flagged as a patch. Additionally, if you are member of the ubuntu-reviewers team please also unsubscribe the team from this bug report.

[This is an automated message performed by a Launchpad user owned by Brian Murray. Please contact him regarding any issues with the action taken in this bug report.]

tags: added: patch
Revision history for this message
Max_E (maxxedout) wrote :

The Precise release is coming close to EOL, so I'm sure some people (like me) are panicking and trying to migrate their email to new systems before April. Therefore, I'd like to report how I worked around this issue in case anyone finds it useful. It's based on a modified version of the directions in comment #3.

However, if you happen to need a 32-bit version of the fixed libevolution package, then just install the one I've attached. If you need a 64-bit version, then AntoineM has built one in comment #4 (although I haven't tested it.) The rest of this is just in case you need to build your own fixed package.

First of all, here's a direct link to the upstream patch to fix the issue: [1] the link in AntoineM's post doesn't work anymore; I think due to a hash collision in Evolution's git history, it goes to the wrong commit. But this link seems to work for me, for anyone who needs the patch. However, if it still doesn't work for you, look through their commit logs for commits during Febuary 2, 2012. The one you want is called "Bug 667576 - Junk between messages after saving an mbox file."

Second of all, between when Evolution 3.2.3 was released and when the bugfix was written, the Evolution team appear to have moved their files around. In the older version, the e-mail-folder-utils.c file is in the "mail" directory instead of in "libemail-engine." So to patch it I did
    cd evolution-3.2.3/mail
    patch -p2 <patch_file.diff

Third of all, in order to make the source package build, I had to add the following lines to evolution-3.2.3/configure.ac:
    AM_PROG_AR
    AM_INIT_AUTOMAKE([-Wno-portability])
But without the indentation of course. I added them right before line 137.

Fourth of all, I had better luck building the package with the following commands (instead of apt-get -b):
    cd evolution-3.2.3
    dpkg-buildpackage -b

Finally, it's not necessary to uninstall anything. All you have to do is call dpkg -i on your new libevolution package (which should be in the parent directory to evolution-3.2.3.) It should replace the existing libevolution package. No other evolution-related packages need to be uninstalled or reinstalled.

I hope that helps someone!

[1] https://git.gnome.org/browse/evolution/patch/?id=df3495a6ec99d53beeaac6b9a2fde8dfd356c439

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.