Discussion:
Kmail1 to Kmail2 folder import
ianseeks
2011-08-05 07:19:18 UTC
Permalink
Hi

I've got my current Kmail1 stype /home/???/Mail folders referenced as a "Kmail
Maildir" in Kmail2. - How can i import them into kmail2 format so i can get
rid of the "Kmail Maildir" configuration? There is no import option for
converting the folders directly unless you have previously exported them to a
kmail archive file. As i now running kmail2 i can't export my folders.

I did a test of just moving a test folder from kmail1 to kmail2, it popped up
a message saying that you can't do it but it did move it anyway and deleted
the contents of that folder.

Any ideas?

Thanks

Ian
_______________________________________________
KDE PIM mailing list kde-***@kde.org
https://mail.kde.org/mailman/listinfo/kde-pim
KDE PIM home page at http://pim.kde.org/
Darknight
2011-08-05 07:56:59 UTC
Permalink
Post by ianseeks
Hi
I've got my current Kmail1 stype /home/???/Mail folders referenced as a
"Kmail Maildir" in Kmail2. - How can i import them into kmail2 format so i
can get rid of the "Kmail Maildir" configuration? There is no import
option for converting the folders directly unless you have previously
exported them to a kmail archive file. As i now running kmail2 i can't
export my folders.
I did a test of just moving a test folder from kmail1 to kmail2, it popped
up a message saying that you can't do it but it did move it anyway and
deleted the contents of that folder.
In theory you should do nothing. The behaviour is intended.
You could drag & drop your kmail folders in your local folders (my
kmail2/akonadi keeps adding these even if I don't need them and delete them)
but the "kmail maildir" is a convenient way to import folders without having
to move them around your hard disk.
O. Sinclair
2011-08-05 23:08:15 UTC
Permalink
Post by Darknight
Post by ianseeks
Hi
I've got my current Kmail1 stype /home/???/Mail folders referenced as a
"Kmail Maildir" in Kmail2. - How can i import them into kmail2 format so i
can get rid of the "Kmail Maildir" configuration? There is no import
option for converting the folders directly unless you have previously
exported them to a kmail archive file. As i now running kmail2 i can't
export my folders.
I did a test of just moving a test folder from kmail1 to kmail2, it popped
up a message saying that you can't do it but it did move it anyway and
deleted the contents of that folder.
In theory you should do nothing. The behaviour is intended.
You could drag& drop your kmail folders in your local folders (my
kmail2/akonadi keeps adding these even if I don't need them and delete them)
but the "kmail maildir" is a convenient way to import folders without having
to move them around your hard disk.
I can sort of understand the concept but after my short stint with
KMail2 I ask: why?

Why transfer/import old email to a special "mixed maildir" category
instead of straight to "new maildir"? Is there any difference even
except for me/you/one getting a folder structure extra?

This I just do not understand - and I also like a "tidy" structure
myself where all my emails, old or recent, are in the same tree.

So the question is very valid I think.

/Sinclair
Darknight
2011-08-08 07:30:29 UTC
Permalink
Post by O. Sinclair
Why transfer/import old email to a special "mixed maildir" category
instead of straight to "new maildir"? Is there any difference even
except for me/you/one getting a folder structure extra?
Maybe, and just maybe, because kmail allowed for mixed maildir and mbox, which
I took advantage of, using mbox for archival purposes reducing the number of
files around my file system. A regular maildir doesn't allow this.
Also, I think they didn't want to copy possibily huge amounts of data during
the migration, but you can if you want to. As I said I suppose you can move
your old mail where you want it to be with drag & drop of entire folders and
maybe entire subtrees, haven't tried.
O. Sinclair
2011-08-08 08:06:19 UTC
Permalink
Post by Darknight
Post by O. Sinclair
Why transfer/import old email to a special "mixed maildir" category
instead of straight to "new maildir"? Is there any difference even
except for me/you/one getting a folder structure extra?
Maybe, and just maybe, because kmail allowed for mixed maildir and mbox, which
I took advantage of, using mbox for archival purposes reducing the number of
files around my file system. A regular maildir doesn't allow this.
Also, I think they didn't want to copy possibily huge amounts of data during
the migration, but you can if you want to. As I said I suppose you can move
your old mail where you want it to be with drag& drop of entire folders and
maybe entire subtrees, haven't tried.
my short stint with KMail2 told me I have to wait for a more
production-ready version. But nevermind: in my KMail I can use maildir
or mbox folders. I have no "mixed maildir" alternative, that came with
KMail2. And as much as I do understand the reason not to move Gb of
maildata (have around 2 Gb myself I think) why not just let the new
akonadi resource simply point to the existing maildir without naming it
as something special? They are still "Local Folders" as opposed to IMAP,
so why name them "KMail Folders" and then add a new "Local Folders" etc?

Still not getting that one

Sinclair
Darknight
2011-08-08 08:35:59 UTC
Permalink
Post by O. Sinclair
They are still "Local Folders" as opposed to IMAP,
so why name them "KMail Folders" and then add a new "Local Folders" etc?
Still not getting that one
Agreed, it's kind of awkward.
I have TWO sets of local folders for some reason, even if there's only one
resource. I tried to delete the resource but it's recreated immediately...
I'd wipe akonadi but it took many hours to sync my imap accounts... I'll keep
the current configuration until I can do without mail for a day or two.
Kevin Krammer
2011-08-16 15:30:45 UTC
Permalink
Post by O. Sinclair
Post by Darknight
Post by O. Sinclair
Why transfer/import old email to a special "mixed maildir" category
instead of straight to "new maildir"? Is there any difference even
except for me/you/one getting a folder structure extra?
Maybe, and just maybe, because kmail allowed for mixed maildir and mbox,
which I took advantage of, using mbox for archival purposes reducing the
number of files around my file system. A regular maildir doesn't allow
this. Also, I think they didn't want to copy possibily huge amounts of
data during the migration, but you can if you want to. As I said I
suppose you can move your old mail where you want it to be with drag&
drop of entire folders and maybe entire subtrees, haven't tried.
my short stint with KMail2 told me I have to wait for a more
production-ready version. But nevermind: in my KMail I can use maildir
or mbox folders. I have no "mixed maildir" alternative, that came with
KMail2. And as much as I do understand the reason not to move Gb of
maildata (have around 2 Gb myself I think) why not just let the new
akonadi resource simply point to the existing maildir without naming it
as something special?
That is exactly what's happening.
The Mixed Maildir resource just points to the data used by any previous
version of KMail, thus not requiring importing or moving.
Mixed Maildir is the internal term describing a directory tree structure of
maildir and mbox folders. The visible string "KMail Folders" should indicate
that this is the local mail storage that KMail had been using, assuming that
it would be easier to undestand than "mixed maildir".
Post by O. Sinclair
They are still "Local Folders" as opposed to IMAP,
so why name them "KMail Folders" and then add a new "Local Folders" etc?
"Local Folders" as opposed to "Server based storage", e.g. folders like
outbox.
If the associated directory tree does not contain any mail when the migrator
is run, it will try to register the folders provided by the KMail Folders
resource to fullfil these special roles, removing "Local Folders" in the
process.

Cheers,
Kevin
--
Kevin Krammer, KDE developer, xdg-utils developer
KDE user support, developer mentoring
O. Sinclair
2011-08-17 10:22:45 UTC
Permalink
Post by Kevin Krammer
Post by O. Sinclair
Post by Darknight
Post by O. Sinclair
Why transfer/import old email to a special "mixed maildir" category
instead of straight to "new maildir"? Is there any difference even
except for me/you/one getting a folder structure extra?
Maybe, and just maybe, because kmail allowed for mixed maildir and mbox,
which I took advantage of, using mbox for archival purposes reducing the
number of files around my file system. A regular maildir doesn't allow
this. Also, I think they didn't want to copy possibily huge amounts of
data during the migration, but you can if you want to. As I said I
suppose you can move your old mail where you want it to be with drag&
drop of entire folders and maybe entire subtrees, haven't tried.
my short stint with KMail2 told me I have to wait for a more
production-ready version. But nevermind: in my KMail I can use maildir
or mbox folders. I have no "mixed maildir" alternative, that came with
KMail2. And as much as I do understand the reason not to move Gb of
maildata (have around 2 Gb myself I think) why not just let the new
akonadi resource simply point to the existing maildir without naming it
as something special?
That is exactly what's happening.
The Mixed Maildir resource just points to the data used by any previous
version of KMail, thus not requiring importing or moving.
Mixed Maildir is the internal term describing a directory tree structure of
maildir and mbox folders. The visible string "KMail Folders" should indicate
that this is the local mail storage that KMail had been using, assuming that
it would be easier to undestand than "mixed maildir".
Post by O. Sinclair
They are still "Local Folders" as opposed to IMAP,
so why name them "KMail Folders" and then add a new "Local Folders" etc?
"Local Folders" as opposed to "Server based storage", e.g. folders like
outbox.
If the associated directory tree does not contain any mail when the migrator
is run, it will try to register the folders provided by the KMail Folders
resource to fullfil these special roles, removing "Local Folders" in the
process.
I get the Local Folders as opposed to Server based, sure. Still do not
get why I ended up with KMail Folders and Local Folders as to me these
are the same. I guess simply the migrator did not do its job (I also
ended up with some other odd resources).
Kevin Krammer
2011-08-17 10:34:36 UTC
Permalink
Post by O. Sinclair
Post by Kevin Krammer
Post by O. Sinclair
They are still "Local Folders" as opposed to IMAP,
so why name them "KMail Folders" and then add a new "Local Folders" etc?
"Local Folders" as opposed to "Server based storage", e.g. folders like
outbox.
If the associated directory tree does not contain any mail when the
migrator is run, it will try to register the folders provided by the
KMail Folders resource to fullfil these special roles, removing "Local
Folders" in the process.
I get the Local Folders as opposed to Server based, sure. Still do not
get why I ended up with KMail Folders and Local Folders as to me these
are the same. I guess simply the migrator did not do its job (I also
ended up with some other odd resources).
The Local Folders resource is created by the mail dispatcher agent as it needs
some folders to work on (outbox, sent-mail).
When the migrator runs it analyzes the folders of this resource to see if it
can divert the usage to the KMail Folders resource it created.
If it can it registers the respective folders of KMail Folders for mail
dispatchers use cases and removes the Local Folders one.
If it can't (e.g. already mail in Local Folders) it will leave that part of
the setup untouched.

It seems that in your case one of the safeguards in the migrator prevented it
from removing the Local Folders resource.
If you are sure you that no harm is done by it being removed, you can manually
register [1] the mixed maildir resource in
$HOME/.kde/share/config/specialmailcollectionsrc (or $HOME/.kde4 if you have a
patched KDE [2]) and then remove the Local Folders resource.

Cheers,
Kevin

[1] DefaultResourceId needs to be the identifier of the mixed maildir
resource, e.g. by looking at commandline of the process in system monitor, ps
x output, or in $HOME/.config/akonadi/agentsrc

[2] see kde4-config --localprefix
--
Kevin Krammer, KDE developer, xdg-utils developer
KDE user support, developer mentoring
O. Sinclair
2011-08-17 12:06:47 UTC
Permalink
Well..
Post by Kevin Krammer
Post by O. Sinclair
Post by Kevin Krammer
Post by O. Sinclair
They are still "Local Folders" as opposed to IMAP,
so why name them "KMail Folders" and then add a new "Local Folders" etc?
"Local Folders" as opposed to "Server based storage", e.g. folders like
outbox.
If the associated directory tree does not contain any mail when the
migrator is run, it will try to register the folders provided by the
KMail Folders resource to fullfil these special roles, removing "Local
Folders" in the process.
I get the Local Folders as opposed to Server based, sure. Still do not
get why I ended up with KMail Folders and Local Folders as to me these
are the same. I guess simply the migrator did not do its job (I also
ended up with some other odd resources).
The Local Folders resource is created by the mail dispatcher agent as it needs
some folders to work on (outbox, sent-mail).
When the migrator runs it analyzes the folders of this resource to see if it
can divert the usage to the KMail Folders resource it created.
If it can it registers the respective folders of KMail Folders for mail
dispatchers use cases and removes the Local Folders one.
If it can't (e.g. already mail in Local Folders) it will leave that part of
the setup untouched.
It seems that in your case one of the safeguards in the migrator prevented it
from removing the Local Folders resource.
If you are sure you that no harm is done by it being removed, you can manually
register [1] the mixed maildir resource in
$HOME/.kde/share/config/specialmailcollectionsrc (or $HOME/.kde4 if you have a
patched KDE [2]) and then remove the Local Folders resource.
You see here is where it sort of goes wrong in the logic for me. I am
not saying my thinking is right/better/correct, just not the one applied
by KMail2.
As I would have thought to do it my existing Local Folders in KMail1
stays where they are, KMail2 migrator creates a "maildir resource" (or
mixed if necessary, not in my case) and points it to existing Local
Folders. The already existing "outbox", ""sent-mail", "wastebin" et al
stay where they are already and is used by KMail "akonadi transport" and
whatever might need it.

At a later stage one might create a "move local folders to standard
resourde directory" or such if one wants to move from present
/home/user/.kde... to /home/user/.local...

I guess the discussion is sort of "too late anyhow" as the migrator does
not seem to work that way, just trying to figure it out and happy you
are willing to enlighten me/us.

Best,
Sinclair
Kevin Krammer
2011-08-17 12:21:15 UTC
Permalink
Post by O. Sinclair
You see here is where it sort of goes wrong in the logic for me. I am
not saying my thinking is right/better/correct, just not the one applied
by KMail2.
As I would have thought to do it my existing Local Folders in KMail1
stays where they are,
They do
Post by O. Sinclair
KMail2 migrator creates a "maildir resource" (or
mixed if necessary, not in my case) and points it to existing Local
Folders.
It does
Post by O. Sinclair
The already existing "outbox", ""sent-mail", "wastebin" et al
stay where they are already
They do
Post by O. Sinclair
and is used by KMail "akonadi transport" and
whatever might need it.
Exactly.
Quoting from my previous mail ("it" being the migrator):
"If it can it registers the respective folders of KMail Folders for mail
dispatchers use cases and removes the Local Folders one."

Cheers,
Kevin
--
Kevin Krammer, KDE developer, xdg-utils developer
KDE user support, developer mentoring
O. Sinclair
2011-08-17 12:33:54 UTC
Permalink
Post by Kevin Krammer
Post by O. Sinclair
You see here is where it sort of goes wrong in the logic for me. I am
not saying my thinking is right/better/correct, just not the one applied
by KMail2.
As I would have thought to do it my existing Local Folders in KMail1
stays where they are,
They do
Post by O. Sinclair
KMail2 migrator creates a "maildir resource" (or
mixed if necessary, not in my case) and points it to existing Local
Folders.
It does
Post by O. Sinclair
The already existing "outbox", ""sent-mail", "wastebin" et al
stay where they are already
They do
Post by O. Sinclair
and is used by KMail "akonadi transport" and
whatever might need it.
Exactly.
"If it can it registers the respective folders of KMail Folders for mail
dispatchers use cases and removes the Local Folders one."
In which case I rest my case and take it that something went belly up
during migration so I ended up with both "KMail Folders" and "Local
Folders" for unknown reason.

Due to other headaches (mainly the frequent freeze due to "conflicts" on
some incoming emails) I gave up and went back to KMail1. Hope next
upgrade "the real thing" will go smoother.
Alan McKinnon
2011-08-17 18:10:22 UTC
Permalink
Post by Kevin Krammer
It seems that in your case one of the safeguards in the migrator
prevented it from removing the Local Folders resource.
If you are sure you that no harm is done by it being removed, you
can manually register [1] the mixed maildir resource in
$HOME/.kde/share/config/specialmailcollectionsrc (or $HOME/.kde4 if
you have a patched KDE [2]) and then remove the Local Folders
resource.
Does the migrator generate a plain language list (in summary form) of
what it did and what choices it made?

I don't recall ever seeing such a thing, but such would be immensely
helpful.
--
alan dot mckinnon at gmail dot com
Kevin Krammer
2011-08-18 07:20:03 UTC
Permalink
Post by Alan McKinnon
Post by Kevin Krammer
It seems that in your case one of the safeguards in the migrator
prevented it from removing the Local Folders resource.
If you are sure you that no harm is done by it being removed, you
can manually register [1] the mixed maildir resource in
$HOME/.kde/share/config/specialmailcollectionsrc (or $HOME/.kde4 if
you have a patched KDE [2]) and then remove the Local Folders
resource.
Does the migrator generate a plain language list (in summary form) of
what it did and what choices it made?
I don't recall ever seeing such a thing, but such would be immensely
helpful.
It does write a log to its data directory $HOME/.kde/share/apps/kmail-migrator
but it could probably be more verbose.

Cheers,
Kevin
--
Kevin Krammer, KDE developer, xdg-utils developer
KDE user support, developer mentoring
Loading...