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

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 08-09-2007, 01:14 PM
Project Contributor
 
Posts: 67
Default help with zmmailbox addMessage

Hi,

I'm facing an already discussed problem here in forums, but without any answers found (at least by me): I'm trying to use zmmailbox addMessage command to import messages in maildir format into a zimbra account (there is no imap). The problem is that the time/date of messages are set to the copy time/dates, and not the data from "Date:" header.

I've already tried to put a "X-Zimbra-Received" header along with other message headers, without success.

Any known solution?
__________________
hugo ribeiro
Reply With Quote
  #2 (permalink)  
Old 08-09-2007, 06:11 PM
Zimbra Employee
 
Posts: 1,434
Default -d <date-msec>

Use the -d switch to zmmailbox addmessage. The date is measured in milliseconds since the epoch (1/1/1970).
__________________
Bugzilla - Wiki - Downloads - Before posting... Search!
Reply With Quote
  #3 (permalink)  
Old 08-10-2007, 03:06 PM
Active Member
 
Posts: 36
Default

Quote:
Originally Posted by dkarp View Post
Use the -d switch to zmmailbox addmessage. The date is measured in milliseconds since the epoch (1/1/1970).
If you were able to acomplish this can u share your command statements with us. I am doing the same thing and dont what is the valu for <arg> on the am for for the -d switch

Thanks
Reply With Quote
  #4 (permalink)  
Old 08-10-2007, 07:23 PM
Zimbra Employee
 
Posts: 1,434
Default

The date is measured in milliseconds since the epoch (1/1/1970).
__________________
Bugzilla - Wiki - Downloads - Before posting... Search!
Reply With Quote
  #5 (permalink)  
Old 08-11-2007, 05:47 PM
Active Member
 
Posts: 36
Default

I need to have X-Zimbra-Received: date not this 631170000000 on the Received Date for the email.

Are you saying I need to script this to open each message, grep X-Zimbra-Received out and feed -d <arg> with that value?

Not to efficient I guess
Reply With Quote
  #6 (permalink)  
Old 08-12-2007, 07:54 AM
Zimbra Employee
 
Posts: 1,434
Default

If you have the X-Zimbra-Received date already in the message header and you're adding to the Inbox, you could just use zmlmtpinject.

Otherwise, you're stuck converting to UNIX time (perl should do this for you) and multiplying by 1000. If you'd like to see zmmailbox -d take a Date-style header, please file a bug in bugzilla and we'll try to get to it soon.
__________________
Bugzilla - Wiki - Downloads - Before posting... Search!
Reply With Quote
  #7 (permalink)  
Old 08-12-2007, 09:00 AM
Active Member
 
Posts: 36
Default

Ok
zmlmtpinject is only for Inbox so I create a filter to load into another folder. this takes care of the Recieved date issue. But all messages are shown as been not read which is not True. That is why I was trying with zmmailbox -> am cause the status of the message is the right one.
Am i corrected on this?
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.