Results 1 to 2 of 2

Thread: export all mailboxes

  1. #1
    Join Date
    Jan 2010
    Posts
    10
    Rep Power
    5

    Default export all mailboxes

    I am familiar with the zmmailbox method of exporting an individuals mailbox including all folders such as calendar, etc. What I would like to do, is, from the command line, make a backup of ALL the usres mailboxes at once. Is this possible? Thank you.

  2. #2
    Join Date
    Mar 2009
    Posts
    10
    Rep Power
    6

    Default

    I found this script on the forums awhile ago, and modified it a bit to mount a Windows share to dump the TGZ backup files to ... I've only used it a few times, and it is slow, but it works:

    Make a bash script containing the following:

    Code:
    #!/bin/bash
    # get a list of all the accounts and create a script to
    # execute the baccount.sh script with the email address
    # of the user as a command line variable
    #use zmaccts and extract only the email address from the result
    #then concatenate the "/backup/./baccount.sh <emailaddress>" string for each account and write it to the file
    /opt/zimbra/bin/./zmaccts | grep "@" | awk '{print "/backup/./baccount.sh " $1}' > /backup/accountbackup.sh
    # change permissions on the newly created script
    chmod 755 /backup/accountbackup.sh
    # Execute the newly created script - this creates a tgz file for each account
    /backup/./accountbackup.sh
    # this mounts an SMB drive of a neighboring win machine and copies the backups over - could be anything
    mount -t smbfs -o username=backups,password=somePassWord //192.168.1.6/backups /backup/SomeWindowsMachine
    mv /backup/accounts/*.tgz /backup/SomeWindowsMachine

Similar Threads

  1. [SOLVED] my server stopped working???
    By cecil in forum Administrators
    Replies: 4
    Last Post: 04-20-2008, 09:07 AM
  2. installation error during ldap setup
    By ljramos in forum Installation
    Replies: 23
    Last Post: 08-10-2007, 11:48 PM
  3. unable to restart zimbra after reboot
    By droefs in forum Administrators
    Replies: 28
    Last Post: 04-16-2006, 03:33 PM
  4. Replies: 16
    Last Post: 01-05-2006, 09:55 AM
  5. After Succesfull Install, Cannot Start mta
    By bsimzer in forum Installation
    Replies: 26
    Last Post: 12-16-2005, 05:45 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •