2

I am searching a complement of this question How to update Thunderbird 78 to 91 on Ubuntu 20.04?.

I install/uninstall Thunderbird 91 (with Snap) and Thunderbird 78 (with APT) many times. I always recover my data with 78, not with 91

How to recover old data of Thunderbird 78 (with APT) with Thunderbird 91 (with Snap) ? Where are stocked the data of 91 ?

I tried to modify the .thunderbird/profiles.ini unsuccessfully.

After uninstalling 91, I have a second icon of TB on my app list but not in snap list

Thanks

Flimm
  • 44,031
Estay
  • 21

2 Answers2

3

This answer addresses the procedure for migrating any apt version of Thunderbird to a snap version. I've tested this on several desktops running various versions of Ubuntu.

If you're running the latest apt version of Thunderbird the exporting procedure on the Mozilla web site will not work. I believe TB v91 is the last release before Ubuntu shifted to the snap distro method and the export function is not in that release.

I'm no Thunderbird expert but I have fooled with this some and think I have a migration procedure that works reliably well.

For simplicity sake I am going to assume that your profile is username.default and not the random-generated-number.default name created when Thunderbird was first started. If this is not the case, it's easy enough to rename the default folder and edit profile.ini

From the Ubuntu file manager, use the copy to command to copy the current Thunderbird settings to a backup folder. Do NOT use the terminal shell cp command. This can be done on the local machine or on a remote desktop and then later copied to the target using filezilla.

Everything you need is in

$HOME/.thunderbird

NOTE: It's always best to back up before doing any destructive operation.

Remove the old apt version of Thunderbird:

sudo apt-get remove thunderbird

Install the snap version of Thunderbird:

sudo snap install thunderbird

To create the files needed to run Thunderbird: Start and then exit Thunderbird

Again, using the file manager and not a terminal shell cp command do a copy to: from the contents of your backup directory to the Thunderbird snap directory:

Example:

From:

$HOME/backups/thunderbird/username.default and profile.ini

Where the above directory is where you saved a backup of your Thunderbird settings

To:

$HOME/snap/thunderbird/common/.thunderbird/

Edit profile.ini to point to the correct directory:

[InstallFDC34C9F024745EB]
Default=username.default

[Profile0] Name=default IsRelative=1 Path=username.default Default=1

[General] StartWithLastProfile=1 Version=2

Start Thunderbird.

Thunderbird should come up fully migrated and at the latest snap version of the app.

This procedure works fine on 22.04.1 LTS

jones0610
  • 2,514
2

On Ubuntu 23.10, this is what I did:

  1. I uninstalled the APT version of Thunderbird (115.10.1+build1-0ubuntu0.23.10.1):

    sudo apt remove thunderbird
    
  2. I then installed the Snap version of Thunderbird (115.10.1-1):

    sudo snap install thunderbird
    
  3. I then launched the Snap version of Thunderbird:

    /snap/bin/thunderbird
    
  4. You will notice that Thunderbird takes a very long time to launch, depending on how big your old ~/.thunderbird directory is. This is because, in the background, it is copying ~/.thunderbird into the correct location for the Snap thunderbird. You can see this by running this ps command:

    $ ps aux | grep -i thunderbird
    flimm      137941  0.1  0.0   2912  1792 ?        S    08:19   0:00 /bin/sh /snap/thunderbird/470/thunderbird.launcher
    flimm      138116 26.7  0.0   4408  2304 ?        R    08:19   0:15 cp -a /home/flimm/.thunderbird/54nho.default /home/flimm/.thunderbird/Crash Reports /home/flimm/.thunderbird/Pending Pings /home/flimm/.thunderbird/installs.ini /home/flimm/.thunderbird/l1980k.default-release /home/flimm/.thunderbird/profiles.ini /home/flimm/snap/thunderbird/common/.thunderbird/
    

Sadly, the Canonical developers did not think to display feedback to the user while this background process happens, see this bug report and mark yourself as affected.

  1. Once Thunderbird is launched (the snap version), verify that the data has been copied correctly by looking at the interface and checking that your accounts and mail are all there. You can also look at the size of the relevant directories, by running these commands:

    $ du -s --si ~/.thunderbird ~/snap/thunderbird/common/.thunderbird
    24G  /home/flimm/.thunderbird
    24G  /home/flimm/snap/thunderbird/common/.thunderbird
    
  2. You can now delete the old ~/.thunderbird directory or put in the rubbish bin:

    trash ~/.thunderbird
    
Flimm
  • 44,031