gaubert / gmvault

gmail backup software
http://www.gmvault.org
GNU Affero General Public License v3.0
3.57k stars 285 forks source link

export folders growing after each export #146

Open stp-ip opened 11 years ago

stp-ip commented 11 years ago

Used command: gmvault export -d /folder /folder

I noticed that after running the export command multiple times the size grew after each export, not just by the size of the new mails, but in the end it was almost 8 times bigger than after removing the folders and exporting again. I assume about 8 exports were run. Know issue? Did I do something wrong?

superalino commented 10 years ago

If you have e-mails that have more than one label I suppose that the export command put a copy of every e-mail in all directory with that labels name. example:

2334.eml.gz -> 2234.meta -> labels: ["\Inbox", "\Important", "\Lucky", "\Love"]

When you launch export command you will have the e-mail 2334.eml on 4 different folders: ./Inbox ./Important ./Lucky ./Love

stp-ip commented 10 years ago

@superalino That was not what I meant. I was saying that if you already have an mbox export and you redo it ontop of the files. The export doubles in size roughly.

  1. run: mbox/test -> 10mb
  2. run: mbox/test -> 19mb

My solution is to remove the files before I run the export command. But it still seems like a bug.

abides commented 7 years ago

@stp-ip I realize this while im exporting to dovecot. Its not replace the email already exported before, its just create new one. So every export all emails are created again. Probably thats why its keep growing. I asked if there is skip option (#294) because its hard to delete all before export when you have 40k emails in gmail.