Zimbra offers Open Source email server software and shared calendar for Linux and the Mac
Go Back   Zimbra :: Forums > Zimbra Collaboration Suite > Migration

Welcome to the Zimbra :: Forums!
Welcome, if you would like to post a comment please register. We also encourage you to explore all things Zimbra with our team and members of the community.

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 06-20-2009, 07:15 AM
Member
 
Posts: 14
Default REST Interface - imported mails do not have correct timestamp

I have tried to import .eml files using the REST interface (example as follows)

Code:
omain.com:password --upload-file /opt/zimbra/test/A http://server//home/user@domain.com/inbox
It works except that the "received" timestamp show the import time rather that the actual time in the mail. Is there any trick that the timestamp can be set to the actual date-time when the mails were first received?
Reply With Quote
  #2 (permalink)  
Old 06-20-2009, 06:53 PM
Member
 
Posts: 14
Default X-Zimbra-Received

I figured out that adding the X-Zimbra-Received to the mail headers in the eml file will fix the problem.

I used the following sed to add the X-Zimbra-Received. It replicates the Date line in the message and replace the Date with X-Zimbra-Received.

Code:
sed 's/\(^Date\:\)\(.*\)/X-Zimbra-Received\:\2\n\1\2/' <infile> > <newfile>
Reply With Quote
Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes


Similar Threads

Why Join?

Registering let's you ask questions, makes it easier to search, displays any files attached to posts, and notifies you about replies.

blog.zimbra.com




 

SEO by vBSEO ©2011, Crawlability, Inc.