My old hard drive with Linux Mint 15 Olivia refused to boot yesterday: kernel panic etc. I tried to
repair the file system and now some shared libraries are missing.

On this computer, I have a brand new second hard drive with Kubuntu 13.10 freshly installed. From
this OS, I can access the first OS hierarchy.

My files are in a safe place, but I had 3 email accounts configured (with imap) in Kontact.

I can't figure out how to recover my 3 accounts settings and use them in kontact in Kubuntu.

Can somebody help me in the linux and unix forum ?

Dani AI

Generated

A short, practical recovery checklist that builds on what started and on ’s follow‑up: copying KDE PIM data can repopulate accounts, but a safe restore should handle three things separately — the Akonadi cache/database, the resource/config files, and the wallet that holds passwords. The steps below assume the broken drive is mounted and the new Kubuntu home is writable.

Stop Akonadi, back up the new system, copy the old Akonadi DB and resource configs, repair and restart Akonadi. Do not copy files while Akonadi is running. Example (replace the placeholders with actual paths/usernames):

# stop Akonadi first
akonadictl stop

# backup current configs before touching anything
tar -czf ~/kde-pim-backup.tgz ~/.config ~/.local

# copy Akonadi database and resources from the old-home to your current home (preserve ownership)
sudo rsync -aHAX --numeric-ids /mount/old-home/AKONADI_DIR/ /home/you/AKONADI_DIR/
sudo rsync -a /mount/old-home/OLD_KDE_CONFIG_DIR/akonadi_*rc /home/you/NEW_KDE_CONFIG_DIR/

# fix ownership
sudo chown -R you:yourgroup /home/you/AKONADI_DIR /home/you/NEW_KDE_CONFIG_DIR

# check and repair, then start
akonadictl fsck
akonadictl start

Stopping/starting and using fsck is the supported workflow for Akonadi administration; the server also documents the commands above. (manpages.debian.org)

Passwords are usually kept in KDE Wallet; restore or open that wallet with KWalletManager (or export/import the wallet) so Kontact can read saved passwords again. For settings-only moves, the PIM Data Exporter can import/export identities and resource configuration, but it does not restore Akonadi’s cached database — Akonadi will re‑sync from the servers after you restore configs. (docs.kde.org)

Troubleshooting notes: keep KDE PIM versions compatible to avoid schema mismatches; ensure ownership and permissions match the target user; if Akonadi reports “dirty” items or missing local mail, follow the KMail procedure to back up local mail, clear local-mail cache, then force a resync. And because the accounts were IMAP, message content normally re-syncs from the server (so the worst case is re‑download, not permanent loss). (docs.kde.org)

If the above fails, capture Akonadi logs and the output of akonadictl status/fsck before making more changes — that makes it much easier to pinpoint a corrupt resource or index.

Recommended Answers

All 3 Replies

Did you try to see what you could do with the instructions on Migrating your KMail/Kontact setup to a new distro? I think that just copying all those config files/folders from the old distro (Mint) to your new system should do the trick, at least, that's what it's intended for. But to be safe, you should back up your Kubuntu configs before overwriting them with the configs from your Mint drive.

All I could see is that you might have some issues with is if the versions of the KDE suite are very different between the distros, or if you use different user-name / accounts. In that case, you might have to manually edit those files to make the repairs. Usually, those kinds of config files are just simple text files with lots of fields and stuff (but maybe emails / contact-lists are encrypted). So, it is usually quite easy to open them up in a text editor and just modify them accordingly (e.g., just open a "fresh" Kubuntu config file and the corresponding Mint config file, and it should be quite obvious what you need to change to make the Mint config work on the Kubuntu system). But I don't think that this will be a problem.

commented: good help +14

Thanks for your help mike, unfortunately it didn't work. I added some files because the list seems out of date: I have kmail2 files like kmail2rc etc. I think a part of the problem is that kmail and kontact use akonadi to store their data instead of files and directories. Akonadi stores data in a database. There is a discussion here about .
I have some data in the old ~/.local/share/akonadi, but I am not going to learn akonadi's storage structure and API now!

I'm going to reparameter kontact from zero. Fortunately, my accounts were imap accounts which minimizes the risk of loosing data.

Happy end: mike_2000_17's suggestion worked partially. It seemed that kmail recovered some account information but it only showed when I tried to add imap accounts. Then kontact opened pre-filled forms with most of my accounts data. I had te reenter the passwords.

I also found most of the account configs in akonadi's files such as ~/.kde/share/config/akonadi_imap_resource_2rc.

Thanks.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.