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

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 (1) Thread Tools Display Modes
  #11 (permalink)  
Old 05-29-2007, 12:37 PM
Special Member
 
Posts: 145
Question

Hi all,

New to all of this, so please bear with me

Could someone please post a "Backup Basics" for the Open Source edition?

I found the zmbackup command in the manuals and have a few questions...
  • What is the first step in backing up? Do I have to shut down any services? Will the services restart after the backup?
  • Is there an indicator that the backup was successful?
  • I notice the backups go to zimbra_home/backup directory. Is it OK to manually copy the contents of this directory to a network drive on another server? Will the next backup overwrite or will there be two backups in the zimbra_home/backup directory?
  • Does the zmbackup command cover everything needed for a restore? Or do I have to do other backups for things such as MySql etc?

Thanks,
Rob
Reply With Quote
  #12 (permalink)  
Old 05-29-2007, 02:48 PM
Zimbra Consultant
 
Posts: 5,784
Default

if you have the open source version the essential's are
su zimbra
zmcontrol stop (if you want you can check your processes to be sure they stopped)
copy, tar, etc the /opt/zimbra folder (and if you made links or mounts to the store, index, etc elsewhere backup those too)
Backing up and restoring Zimbra (Open Source Version) - ZimbraWiki

zmbackup is for the NE version:
CLI - zmbackup Network Edition Only - ZimbraWiki

now there are a few threads on backup scripts and ways to backup the open source edition live...but if your new to linux...probably a little over your head
regarding cold & hot, full and incramental backups of open source version:
Full Server Backup and Restore of “open source version”
__________________
-Mike Morse (MCode151)

ZCS-to-ZCS Migrations & Moves | Admin Tools & Tidbits » ZimbraBlog.com | ZimbraCommunity.com

Last edited by phoenix : 05-30-2007 at 10:25 AM. Reason: typo on link
Reply With Quote
  #13 (permalink)  
Old 05-30-2007, 12:42 AM
Zimbra-Yahoo Consultant
 
Posts: 294
Default

Quote:
Originally Posted by sternfan View Post
Hi all,

New to all of this, so please bear with me

Could someone please post a "Backup Basics" for the Open Source edition?

I found the zmbackup command in the manuals and have a few questions...
  • What is the first step in backing up? Do I have to shut down any services? Will the services restart after the backup?
  • Is there an indicator that the backup was successful?
  • I notice the backups go to zimbra_home/backup directory. Is it OK to manually copy the contents of this directory to a network drive on another server? Will the next backup overwrite or will there be two backups in the zimbra_home/backup directory?
  • Does the zmbackup command cover everything needed for a restore? Or do I have to do other backups for things such as MySql etc?
Thanks,
Rob
Hi Rob,

Zimbra Open Source does not come with the zmbackup command. "zmbackup" is bundled with Zimbra Network Edition.

You need not stop Zimbra if you use zmbackup, however, from all the known strategies for backing up Zimbra Open Source, you must stop Zimbra (that is, take a Cold backup).

If you use zmbackup, the indicator is the name of backup given by the command on STDOUT (If there are any errors, they are reported, too). If you do a Cold backup of Zimbra Open Source, you are using system utilities (such as, "rsync") and thus, the errors will be reported by these utilities.

If you are using zmbackup, you can also list out the completed backups by using the command zmbackupquery. For Cold backup of Zimbra Open Source, you have no such utility (except, the "ls" command).

zmbackup, done from command-line includes everything - no need to backup MySQL, etc. separately. Cold backup also includes everything.

Cold Backup Basics:

1. Stop all Zimbra Services
2. Ensure all services are stopped or kill them gracefully (don't use kill -9)
3. Once all Zimbra services are stopped, rsync them (/opt/zimbra) to some other path - maintaining ownerships, permissions, symlinks, hard links, etc.
4. Start Zimbra
5. Done!

Cold Backup Restoration Basics:

1. Stop Zimbra
2. mv _OR_ rm -rf /opt/zimbra
3. Copy the backed up Zimbra directory to /opt/zimbra
4. Start Zimbra

Common Issues:
If something doesn't start, run /opt/zimbra/libexec/zmfixperms
This will fix all permissions.

If Tomcat doesn't start, please check /opt/zimbra/tomcat/logs/catalina.out
The log in this is generally understandable.

Make sure:
1. The hostname of the system on which restoration is to be done is the same as the hostname of the system on which backup was taken.

2. Zimbra is installed on the system on which restoration is to be done. If not, restoration will not work.

Others:
I am not aware if rsync-ing to the same backup directory more than once, will works. This must be tested. So, I would add, backup to a different directory everytime and rotate backups to save space.
__________________
Regards,

Chintan Zaveri
(Yet another ZIMBRAN!)

"Dhundhne par Bhagwan bhi ..."
Reply With Quote
  #14 (permalink)  
Old 05-30-2007, 10:11 AM
Special Member
 
Posts: 145
Default

Thanks for all the replies:

Mmorse: - the first link you have ended up with an empty page (There is currently no text in this page).

I am planning to do a backup after business hours friday. Just to be clear..

- I su zimbra
- zmcontrol stop
- verify services have stopped (I am assuming Server Status?)
- copy the contents of /opt/zimbra to a network drive
- Start services? zmcontrol start?

czaveri

- I've never used rsync before. Will what I mentioned above work?

Right now my /opt/zimbra directory is about 3gb - so it should be a fast backup.

Also - do the users need to logoff their email accounts?

Thanks,
Rob
Reply With Quote
  #15 (permalink)  
Old 05-30-2007, 10:24 AM
Zimbra Consultant & Moderator
 
Posts: 11,327
Default

Quote:
Originally Posted by sternfan View Post
Mmorse: - the first link you have ended up with an empty page (There is currently no text in this page).
There was a typing error on that link, try it again.
__________________
Regards


Bill
Reply With Quote
  #16 (permalink)  
Old 05-30-2007, 10:36 AM
Zimbra Consultant
 
Posts: 5,784
Default

Thanks pheonix

sternfan,
Doing zmcontrol stop will essentially end their sessions anyway. -it shuts down everything.
You will have to do the backup as root (otherwise you'll miss a few files).
However you need to keep the files that are assigned zimbra.zimbra assigned to the zimbra user.
Do an ls -la inside /opt/zimbra and you'll see what I mean.
Now, there is a script to run if you mess up permissions
>/opt/zimbra/libexec/zmfixperms
-however to save yourself the hassle; Tar, zip, etc the folder first or use a copy (cp) command that saves permissions.
__________________
-Mike Morse (MCode151)

ZCS-to-ZCS Migrations & Moves | Admin Tools & Tidbits » ZimbraBlog.com | ZimbraCommunity.com

Last edited by mmorse : 05-30-2007 at 10:38 AM.
Reply With Quote
  #17 (permalink)  
Old 05-31-2007, 02:20 PM
Special Member
 
Posts: 145
Question

Thanks for all the replies - my first backup will be at the end of the workday tomorrow.

And I've been thinking about future backups...

Since the server has to go down, I have to do this at off-hours. I have a helpdesk tech that can help with this, who works some of these off-hours (I am thinking every saturday when 90% of the users are gone). However, he is totally unfamiliar with Linux in any way, hates it, and basically I do not want him pecking around with the command line on my freshly installed Zimbra box. In fact, I am terrified of him logging directly into the server as ROOT.

So - would webmin interfere with Zimbra? Using it just for the backup module? I can set him up at his desk (not physically touching the server) - I'll create a how-to with screenshots - test it and he should be OK? I just checked the webmin module, and it does TAR formats.

Thanks,
Rob
Reply With Quote
  #18 (permalink)  
Old 05-31-2007, 02:39 PM
Zimbra Consultant & Moderator
 
Posts: 11,327
Default

Webmin works fine on my Zimbra server box, you should have no problems with it.
__________________
Regards


Bill
Reply With Quote
  #19 (permalink)  
Old 06-02-2007, 11:36 AM
Special Member
 
Posts: 145
Question

Hi Phoenix,

Just finished my first backup using webmin. Looks like all went well. One quick question though...

During the backup, I am getting things like:

tar: /opt/zimbra/postfix-2.2.9/spool/private/smtp-amavis: socket ignored

I got about 20 of these - all in the opt/zimbra/postfix directory. I googled webmin "socket ignored" and it looks like when the backup meets a virtual directory (I am assuming this is what this is) that it ignores it.

Does this look right to you?

Thanks,
Rob
Reply With Quote
  #20 (permalink)  
Old 06-02-2007, 12:48 PM
Zimbra Consultant & Moderator
 
Posts: 11,327
Default

Yes, it's a harmless message that's telling you it's something that can't be backed up.
__________________
Regards


Bill
Reply With Quote
Reply


Thread Tools
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.

Zimbrablog.com




 

Search Engine Optimization by vBSEO 3.1.0