On 13-04-07 03:00 AM, Stephan von Krawczynski wrote:
> On Sat, 06 Apr 2013 14:32:34 -0700
> Geoff Nordli <geo...@gnaa.net> wrote:
>
>> On 13-04-06 01:46 PM, Stephan von Krawczynski wrote:
>>> On Sat, 06 Apr 2013 10:50:13 -0700
>>> Geoff Nordli <geo...@gnaa.net> wrote:
>>>    
>>>> I would say that the vbox snapshots are not the path you want to take
>>>> for backups.  VBox snapshots are great when experimenting with software,
>>>> or creating a library using a base images.  If you do a VBox snapshot
>>>> online, then you also have a .sav file, and you have to wait for the
>>>> save/resume to complete before it can come back online.  If you can
>>>> afford downtime, then I would power off the VM to get a consistent state
>>>> of your data.
>>>>
>>>> Other people may be able to chime in here, but if you looking at using
>>>> it for backups, then pausing the machine, and using LVM may be something
>>>> that works, because after you take the backup, you delete the lvm
>>>> snapshot. You will need to delete the backup though because LVM doesn't
>>>> scale well for snapshots.  In the past I used LVM and raw disks to do this.
>>>>
>>>> Geoff
>>> Hm, but your script does suspend/resume the vm, too. I cannot see a big
>>> difference to a vm snapshot ... ?
>>>
>>>
>> The script uses the virsh suspend command which just pauses the VM
>> temporarily until it is resumed, which is pretty much instant.
>>
>> http://www.centos.org/docs/5/html/5.2/Virtualization/chap-Virtualization-Managing_guests_with_virsh.html
>>
>> Whereas the vbox "savestate" when doing a snapshot takes a lot longer,
>> because it writes out the active memory to a saved state file.
> Well, if you only suspend the guest, then take a backup from the vdi (with 
> whatever method) you will not end up in a consistent backup. Think of a mysql 
> database where you just suspended the guest right in between some write 
> action. your database file has a good chance to be corrupted that way.
> On the other hand, if you take a snapshot of the guest and backup this 
> chances are better you'll be able to resume the guest later on during 
> restore, not?
>

Yes, with LVM, I would prepare any hot applications for backup just to 
make sure.

Note, pausing the disk will flush vbox cache: 
https://www.virtualbox.org/pipermail/vbox-dev/2011-June/004207.html

For my MySQL maybe something like this: 
http://www.lenzg.net/mylvmbackup/ where they put a read lock on all the 
tables, and flush the cache.

For windows you want to use VSS.

You can execute scripts inside a guest os using guestcontrol, or use SSH 
before you pause the host.

I am worried less about corruption with ZFS because it writes data in 
transaction groups and uses a COW format so data is never overwritten.

Another note, you want to make sure you disable the "ignoreflush": 
http://www.virtualbox.org/manual/ch12.html#idp20230944











------------------------------------------------------------------------------
Minimize network downtime and maximize team effectiveness.
Reduce network management and security costs.Learn how to hire 
the most talented Cisco Certified professionals. Visit the 
Employer Resources Portal
http://www.cisco.com/web/learning/employer_resources/index.html
_______________________________________________
VBox-users-community mailing list
VBox-users-community@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/vbox-users-community
_______________________________________________
Unsubscribe:  
mailto:vbox-users-community-requ...@lists.sourceforge.net?subject=unsubscribe

Reply via email to