Comprehensive data protection for all workloads
Post Reply
Archvile
Novice
Posts: 6
Liked: never
Joined: Jan 11, 2011 10:41 am
Full Name: Alexander Zorin
Contact:

Linux guest file system freeze

Post by Archvile »

Hi !

We are using Veeam Backup & Replication 4.1 to backup Linux and Win2000 guests. Guest VM is not powered off during backup; "VMware Tools Quiescence" is enabled in job properties. So, the question is - do we get filesystem-consistent backup this way ? For example, is file system flushed before freeze, and by what means ? Does this mean that VMware tools should support guest FS (FAT, ext3, XFS etc.) ? Should we have vmware vmsync module up and running to flush filesystem properly ? (as I suppose, this module is used by VCB and is not installed by default).
Vitaliy S.
VP, Product Management
Posts: 27055
Liked: 2710 times
Joined: Mar 30, 2009 9:13 am
Full Name: Vitaliy Safarov
Contact:

Re: Linux guest file system freeze

Post by Vitaliy S. »

Hello Alexander,

Yes, you do, but you need to make sure you have application-consistent backups as well.

As you know in order to use VMware Quiescence, you should have VMware tools deployed on each of your VMs. The file system quiescence is performed by a SYNC driver (installed with VMware Tools).

I wouldn't recommend relying on VMware quiescence alone, without pre/post scripts, as there were some cases when guest databases were corrupted with this approach.

Provided that you want to have consistent backups, then you do need to use pre-freeze and post-thaw scripts to quiesce application before the snapshot is taken, and resume immediately after. You may search the forums for some application-specific scripts examples if you need more information on that.

Thanks!
Archvile
Novice
Posts: 6
Liked: never
Joined: Jan 11, 2011 10:41 am
Full Name: Alexander Zorin
Contact:

Re: Linux guest file system freeze

Post by Archvile »

Thanks for your reply !
Vitaliy S. wrote:All the quiescence is performed by a SYNC driver (installed with VMware Tools).
I've just created test RedHat VM on ESX and tried to install vmware tools, but no SYNC driver was installed. Then, I checked vmware-tools-config.pl and found this:
........
# configure the Linux-only drivers
if ( vmware-product() eq 'tools-for-linux') {
# configure_vmsync(); # See bugs 299856/296354
configure_vmci();
........

So, as I suppose, vmsync is just turned off in their installer, and it means there is no FS sync support ?
May be we should manually issue linux "sync" command in shell before each backup ?
Vitaliy S. wrote:Yes, you do, but you need to make sure you have application-consistent backups either.
Yes, we just use our own shutdown/startup scripts
Gostev
Chief Product Officer
Posts: 31457
Liked: 6648 times
Joined: Jan 01, 2006 1:01 am
Location: Baar, Switzerland
Contact:

Re: Linux guest file system freeze

Post by Gostev »

Some people on this forum shared before that they are using sync;sync;sync; for their Linux pre-freeze scripts. This cannot hurt for sure :D
tsightler
VP, Product Management
Posts: 6009
Liked: 2843 times
Joined: Jun 05, 2009 12:57 pm
Full Name: Tom Sightler
Contact:

Re: Linux guest file system freeze

Post by tsightler »

Gostev wrote:Some people on this forum shared before that they are using sync;sync;sync; for their Linux pre-freeze scripts. This cannot hurt for sure :D
This "sync;sync;sync" command is mostly just classic Unix folklore (and actually probably incorrect even then) from days gone by and shouldn't really be required in modern Unix or Linux variants. But sure, it doesn't hurt. I'll admit that some of my scripts still contain this command.
ashw1ns
Lurker
Posts: 1
Liked: never
Joined: Feb 09, 2012 5:04 am
Full Name: Ashwin

Re: Linux guest file system freeze

Post by ashw1ns »

I faced a similar issue when using custom pre-freeze and post-thaw in linux.
I basically touch a file in pre-freeze-script and remove it in post-thaw-script. To identify if my vm is running from a backup or not.
What I found is that the file is missing when I restore the backup/quiesced snapshot.

Thanks to this forum, after adding the "sync" command the files are now consistently available in the snapshot.(I use SLES 11 SP1 as my guest VM)

I know this is a bit old thread but hopefully it helps anyone new who faces a similar issue.
cby
Expert
Posts: 109
Liked: 6 times
Joined: Feb 24, 2009 5:02 pm
Contact:

Re: Linux guest file system freeze

Post by cby »

sync may be old hat but is still relevant for command line geezers ;) Try copying a large file to a mounted USB stick. Hit return and the shell prompt will appear almost immediately, before the copy is finished. Issue sync and there will be a noticeable, real-time delay as the data gets written to USB before the shell prompt appears again. It prevents yanking the stick on the false assumption that the copy has finished when it clearly hasn't.
Post Reply

Who is online

Users browsing this forum: No registered users and 139 guests