• We value your experience with Plesk during 2024
    Plesk strives to perform even better in 2025. To help us improve further, please answer a few questions about your experience with Plesk Obsidian 2024.
    Please take this short survey:

    https://pt-research.typeform.com/to/AmZvSXkx
  • The Horde webmail has been deprecated. Its complete removal is scheduled for April 2025. For details and recommended actions, see the Feature and Deprecation Plan.
  • We’re working on enhancing the Monitoring feature in Plesk, and we could really use your expertise! If you’re open to sharing your experiences with server and website monitoring or providing feedback, we’d love to have a one-hour online meeting with you.

Forwarded to devs Mail importing option does not preserve messages' timestamps

Denis Gomes Franco

Regular Pleskian
TITLE:
Mail importing option does not preserve messages' timestamps
PRODUCT, VERSION, OPERATING SYSTEM, ARCHITECTURE:
Plesk Obsidian Version 18.0.20 Update #2, Ubuntu 18
PROBLEM DESCRIPTION:
Did a site migration today which included mailboxes. The mail importing option is quite handy and works like a charm (it took about several minutes to move a ~25 GB mailbox) but it did not preserve the original timestamps, eg. all the messages were stored as 'received today @ <hh:mm>' where hh:mm is the time of the migration.

I had to delete the mailbox and do the migration again using another tool, specifically goodbye.host, an online service. It will take much, much longer to finish but at least timestamps are being preserved.

On another note, I've seen another tool being mentioned a lot for mailbox migrations: IMAPSYNC. Not sure if Plesk uses it but there is a Cpanel module that implements IMAPSYNC with a user-friendly GUI (IMAPSYNC is a CLI tool) that is simply fantastic.

If Plesk does not use it, why not use it now? And if it does, why timestamps are all wrong?​
STEPS TO REPRODUCE:
1. Create a mailbox
2. Run the Mail importing option
3. Enter the remote mailbox credentials
4. Wait for the importing to finish
5. Open Roundcube and log in to the new mailbox​
ACTUAL RESULT:
Notice that the messages have timestamps from the date and time of importing, and not the original timestamps​
EXPECTED RESULT:
The messages should retain their original timestamps​
ANY ADDITIONAL INFORMATION:
YOUR EXPECTATIONS FROM PLESK SERVICE TEAM:
Confirm bug
 
Here's something else I remembered today.

Mail messages are stored as plain textfiles and if I'm not wrong, their respective date and time of receiving are stored *inside* each file. Roundcube on the other hand pulls in those dates and times from *the file system*. This usually does not cause problems since under normal operation the mail message is written to the disk the same time it's received, so both the timestamp of the file and the timestamp inside the file are the same.

However it seems that during the mail importing operation Plesk is not parsing the messages to get their dates and times of receipt so it can 'touch' the files and save them with the correct date and time.

So I believe there are two solutions to the above problem:
- Improve the mail importing option to change the date and time of the files while they are written
- Create a script to parse message files, extracting dates and times and using the TOUCH command in Linux to change their timestamps
 
Back
Top