Operating System - HP-UX
1753338 Members
4940 Online
108792 Solutions
New Discussion юеВ

Backing up a snapshot File System

 
Kristofferson Fagan
Occasional Contributor

Backing up a snapshot File System

I am fairly new to the Unix environment. Can someone please comfirm whether or not Fbackup can be used to perform backup within an OnlineJFS environment?

Thanks
7 REPLIES 7
Sridhar Bhaskarla
Honored Contributor

Re: Backing up a snapshot File System

Hi,

I guess you meant backing up a snapshot filesystem (available with OnlineJFS) with fbackup.

If so, yes. You can use fbackup. fbackup can span multiple media and supports incremental backup.

-Sri
You may be disappointed if you fail, but you are doomed if you don't try
Bernhard Mueller
Honored Contributor

Re: Backing up a snapshot File System

Hi,

if you refer to OnlineJFS "snapshot" mounts which you want to backup, then the answer is no, you cannot use fbackup because it needs write access and your OnlineJFS snapshot is a read-only filesystem.

So you could use tar, cpio, dd ... (which all have their restrictions, e.g. 2GB wise)

Regards,
Bernhard
Steven E. Protter
Exalted Contributor

Re: Backing up a snapshot File System

fbackup can not easily be used to back up any open "database". These snapshots have processes open on them and will not back up well with fbackup.

If there is a way to tell OnlineJFS to make new snapshots you might be able to get the previous version. I'm new with OnlineJFS and have yet to figure that out.

SEP
Steven E Protter
Owner of ISN Corporation
http://isnamerica.com
http://hpuxconsulting.com
Sponsor: http://hpux.ws
Twitter: http://twitter.com/hpuxlinux
Founder http://newdatacloud.com
A. Clay Stephenson
Acclaimed Contributor

Re: Backing up a snapshot File System

Fbackup can certainly be used to backup snapshot filesystems "read-only" or not.

It is possible to make multiple snapshots at different points in time on a vxfs filesystem. Each snapshot will be current as of its snapshot time. There is, of course, additional overhead associated with each snapshot image so for busy filesystems I would not exceed one without knowing the impact.

Snapshots, with regard to databases, are not intended to used as hotbackups. The idea is to shutdown; snapshot; restart the database and then backup the snapshot. No files are then active and fbackup works like a charm. You get almost all the uptime of a hotbackup with all the safety of a cold backup for about two minutes of downtime.

One thing that is not obvious is that you should mirror (or have alternate paths if a RAID) the snapshot buffer lvol. If you suffer a disk failure in the snapshot buffer device, the original filesystem can hang --- not often considered a desirable thing. A typical generous size for a snapshot buffer is about 15% of the original.
If it ain't broke, I can fix that.
John Waller
Esteemed Contributor

Re: Backing up a snapshot File System

A few years ago Bernhards answer would have been correct, it was the case that you could not use fbackup to backup a snapshot volume. Following the previous convincing answer I've re-tried and yes it now does work. I have to presume that a patch has been released which fixed the problem so depending on your patch level you may have a problem. Best advice is to manually run a small test using a single file after making a snapshot of a temporary created lvol. Unlike windows it is unlikely you will crash your system, at worst you will just get an error informing you that the backup has failed.
Tim D Fulford
Honored Contributor

Re: Backing up a snapshot File System

tar will do it, fbackup wont as it modifies the i-nodes (unless your snap LV is the same size as the data on the original imaged LV).

The way a snap works is that it freezes ALL activity on a filesystem. The filesystem is allowed to continue, but every time a file is modified the original i-node is copied to a reserved piece of space. Usually 10% is chosen. Thus you can back-up the original "frozen" filesystem. Unfortunately fbackup "touches" each i-node as it backs it up. Thus the reserved LV will eventually contain as much data as the original.

Tim
-
A. Clay Stephenson
Acclaimed Contributor

Re: Backing up a snapshot File System

Nonsense again. Fbackup will certainly backup snapshots and because snapshots operate at the block level only changed blocks are transferred to the snapshot buffer. It is extremely unlikely that all the blocks in all the files will be modified (and only the FIRST block update counts), a 15% or so snapshot buffer is usually more than adequate.
If it ain't broke, I can fix that.