Hi,

First, i'm french, so please excuse my english.

I'm trying to developed a little Bash script which backup mailboxes and restore on an another Zimbra.

I try :

Code:
sudo -u zimbra /opt/zimbra/bin/zmmailbox -z -m admin@domaine.com getRestURL "//?fmt=tgz" > admin.tgz
When i extract the tgz, i have many .eml and .meta. Now, i'm trying to recreate the tgz :

Code:
tar -cf admin.tgz *
I'm trying to import on the other Zimbra :

Code:
sudo -u zimbra /opt/zimbra/bin/zmmailbox -z -m admin@domaine.com postRestURL "//?fmt=tgz&resolve=reset" admin.tgz
Zmmailbox don't show any error, but in mailbox.log i have this one :

Code:
2012-01-05 16:12:19,626 WARN  [btpool0-25://mta.reseau.loc/home/admin@domaine.com/?fmt=tgz&resolve=reset] [name=admin@domaine.com;mid=19;ip=192.168.2.48;] misc - missing item blob for meta: path=/Sent/
com.zimbra.cs.service.formatter.FormatterServiceException: missing item blob for meta
ExceptionId:btpool0-25://mta.reseau.loc/home/admin@domaine.com/?fmt=tgz&resolve=reset:1325776339626:2f42c4e6bdd963ce
Code:formatter.MISSING_BLOB Arg:(path, STR, "/Sent/")
        at com.zimbra.cs.service.formatter.FormatterServiceException.MISSING_BLOB(FormatterServiceException.java:78)
        at com.zimbra.cs.service.formatter.ArchiveFormatter.addItem(ArchiveFormatter.java:1006)
        at com.zimbra.cs.service.formatter.ArchiveFormatter.saveCallback(ArchiveFormatter.java:855)
        at com.zimbra.cs.service.formatter.Formatter.save(Formatter.java:144)
        at com.zimbra.cs.service.UserServlet.doPost(UserServlet.java:481)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:725)
        at com.zimbra.cs.servlet.ZimbraServlet.service(ZimbraServlet.java:208)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:814)
        at org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:511)
        at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1166)
        at com.zimbra.cs.servlet.SetHeaderFilter.doFilter(SetHeaderFilter.java:79)
        at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1157)
        at org.mortbay.servlet.UserAgentFilter.doFilter(UserAgentFilter.java:81)
        at org.mortbay.servlet.GzipFilter.doFilter(GzipFilter.java:155)
        at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1157)
        at org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:388)
        at org.mortbay.jetty.security.SecurityHandler.handle(SecurityHandler.java:218)
        at org.mortbay.jetty.servlet.SessionHandler.handle(SessionHandler.java:182)
        at org.mortbay.jetty.handler.ContextHandler.handle(ContextHandler.java:765)
        at org.mortbay.jetty.webapp.WebAppContext.handle(WebAppContext.java:422)
        at org.mortbay.jetty.handler.ContextHandlerCollection.handle(ContextHandlerCollection.java:230)
        at org.mortbay.jetty.handler.HandlerCollection.handle(HandlerCollection.java:114)
        at org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:152)
        at org.mortbay.jetty.handler.rewrite.RewriteHandler.handle(RewriteHandler.java:230)
        at org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:152)
        at org.mortbay.jetty.handler.DebugHandler.handle(DebugHandler.java:77)
        at org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:152)
        at org.mortbay.jetty.Server.handle(Server.java:326)
        at org.mortbay.jetty.HttpConnection.handleRequest(HttpConnection.java:543)
        at org.mortbay.jetty.HttpConnection$RequestHandler.content(HttpConnection.java:946)
        at org.mortbay.jetty.HttpParser.parseNext(HttpParser.java:756)
        at org.mortbay.jetty.HttpParser.parseAvailable(HttpParser.java:212)
        at org.mortbay.jetty.HttpConnection.handle(HttpConnection.java:405)
        at org.mortbay.io.nio.SelectChannelEndPoint.run(SelectChannelEndPoint.java:410)
        at org.mortbay.thread.BoundedThreadPool$PoolThread.run(BoundedThreadPool.java:451)
I think Zimbra is gzip or doing something at the tgz which send me. But, no way to recreate this tgz !

Is there a way to extract my mailbox.tgz, rsync on the other server, compress and import ?

Cheers,