Everhart, Glenn From: Glenn C. Everhart [Everhart@gce.com] Sent: Wednesday, March 10, 1999 7:44 PM To: Info-VAX@Mvb.Saic.Com Subject: Re: Backing up a live shadowed disk It will be necessary for full safety to stop the application for a moment. Might as well dismount the shadowset as well at that point. True, you lose a safety measure for a few minutes but you get a clean backup. The issue here is that you have, in general, no way to know what the application considers a single transaction. Suppose it were writing a file structure, just for illustration. When writing to such a thing, you need in general to update a storage map of some kind, an index structure or structures, and data. (The same happens for database managers.) If your app is inclined to cache indices in memory, it might update data on disk but not the index on disk till it reaches whatever it considers a synchronizing point. It might be like what would happen if writes to a storage bitmap were deferred, or worse, writes to an index file. This kind of thing is totally application driven and unless the app is designed to work no matter when the plug might get pulled, taking a backup by unshadowing is equivalent to pulling the plug suddenly. The disk will look like it did at some instant of time, but the apps that were running may have all sorts of transactions partly done and by the way will be thinking all was well so they may blow away logging info you'd need to recover them. You are in general far better off stopping the app momentarily to ensure it writes things out to disk before you split the shadow set. Otherwise you may wind up with a totally corrupt application storage area even though the disk as a file structure may be completely sensible. Something that would shadow all writes to a file that started before starting an online /ignore=interlock backup, and that stopped after this was done, could allow you to have between the backup and the shadow journal an image of the disk at the instant the journal finished. The DEC snapshot capability gives something more complex but equivalent...that you can buy. However, getting a single-instant snapshot of the disk is only part of the problem. Getting a snapshot of application storage that can be used by the app if you ever have to restore it is the other and more difficult problem. I've backed up lots of disks with /ign=inter and been able to use the backups fine, but I also do it a LOT and figure that any database I might be running during this activity can be possible toast. If you aren't willing for this to be the case and to maybe have to go WAY back to find a good copy, shut the thing down before backup. Where I've had to work with DBMS systems, I either did this or figured I wasn't backing up the DBMS that time out. Even a DBMS that claims it's fine if the plug is pulled at any instant could have problems unless your snapshot includes ALL of whatever it uses for journals in its storage. If the journal is on another disk, your image may not match anything that's left in the journal and you might as well start over. Loss of resilience during backup is a tiny issue. Data integrity of apps that may use many disk read/write operations in a single transaction is a huge one. Have fun. ;-) Glenn Everhart POWERS John wrote: > > Hi. > > I have received a request to do an image backup of a disk that has files > always open on it. The users do not wish to stop the application that > opens the files. The disk is shadowed. They have asked if it is possible > to unshadow the disk, then backup the copy of the disk on the shadow and > then re-shadow the disk, without interruption to any processes running > using files on the disk. > > I have pointed out that while the disk is unshadowed they would lose the > resilience that is the reason they shadowed, but they are prepared to > live with that for the time it takes to backup, if this will work. Has > anybody tried this idea, and will it work? The problem with using the > simple /IGNORE=INTERLOCK, is that different files will be backed up > at different times, and they are worried the backup will be unreliable. > Unshadowing the disk, they hope, will mean all the files are in the > same state. Has anybody got any advice, a pointer to the page in the > great white wall, or any horror stories of people who tried this and > came unstuck, that I can use to talk them out of it. > > Many thanks for any help. > > John.