PDA

View Full Version : Best Practices Before Doing a Backup



phkhgh
04-08-2007, 02:20 AM
I've looked on this site and searched the web (a lot) trying to find a consensus on what steps to take before doing backups on a PC (XP). I'm still looking.

Can anyone direct me to some "authority" articles or even books about all the steps to do before doing a backup. Some say run Scandisk, delete unwanted files, defrag, etc., then backup.

Others say, "OH NO! Never defrag before backing up." And just about everything in between.

So, if anyone's got some good ideas for reference sources, I'd appreciate it.

PrntRhd
04-08-2007, 02:28 AM
Well I can tell you NTFS does not need many defrags. I use CCleaner to remove Temp Files and Temporary Internet Files.
Just back it up regularly and you are set.

Sylvander
04-08-2007, 03:03 AM
What kind of backups do you make?

1. I make...
a. Image backups [using "Image for DOS"] of the Windows and also all the data partitions.
b. "SyncBack" synchronisations of all the data partitions.

1b only saves folders & files [those that can be seen by Windows];doesn't save the fragmentation state etc.

1a makes cluster for cluster copies, so it saves almost everything [including the state of fragmentation and lost folder/file clusters and chains]; don't think it saves areas of the partitions holding deleted or erased files or folders.
I normally image my Windows partition in a "Hibernation" state.

2. All I do is make sure that the software is in a normal healthy state before making a backup or synchronisation, because any faults would be preserved and restored and that is undesirable.
e.g. Normal good maintenance practices:
a. Scan the file system on all partitions to eliminate faults.
My [Win2000Pro] partitions are FAT32, your XP partitions may be NTFS.
To scan & fix NTFS use chkdsk.
To scan NTFS & FAT32 and fix only FAT32 use MS Scandisk [I use the version on the "Emergency Boot CD"].
b. Since my partitions are FAT32 I defragment; I see others say that NTFS doesn't need any/many defragmentations.

Paul Komski
04-08-2007, 03:29 AM
Don't know of any "authority" articles unless you are more specific. Backing-up covers a wide range of techniques you see. Reading any relevant software documentation for specific products is always a good starting point - and is a thing often neglected.

In general this involves:

Backing-up Data Files, Installers, The Registry and Hardware Drivers, etc as straight copies.
Backing-up the same but as compressed archive files.
Keeping constant duplicated hard drive data as a mirrored RAID array.
Backing -up whole partitions as straight copies or as compressed image files.


Disk-checking and defragmentation need to be used from a rational standpoint and not as an ALWAYS or NEVER standpoint - though I would say ALWAYS run a disk-check app such as chkdsk prior to defragging a volume, since defragging a compromised file system is a great way of losing data. It is also a wise move prior to using utilities that manipulate partitions by changing their size, location or format on any given hard drive. If you are moving files to a new partition then its wise to not by-pass running a disk check as part of the partitioning routine.

Disk-checking covers two main areas; the integrity of the file system and the integrity of the disk surface so just think if either or both would be a good idea depending on what is important in terms of what you are doing.

Remember too that copying/cloning of partitions can be done in two main ways; by copying files or by copying hard drive sectors. Utilities that do the latter (such as BiNG) are generally faster. Personally I like to use image files rather than identical cloned partitions and with important data (whether on a CD or another drive) would always verify the copy after imaging.

Post back for any further elaboration or specifics.

Paul Komski
04-08-2007, 03:36 AM
don't think it saves areas of the partitions holding deleted or erased files or folders.I have been told by terabyteunlimited that their img files are true clones and can be used to restore an exact replica. The compression algorithms would take care of sectors containing repetitive data such as FF or 00 in a very simple manner - and that would not include deleted files - though it would include erased files (which would be gone anyway).

Sylvander
04-08-2007, 06:30 AM
Having difficulty understanding...

"that would not include deleted files - though it would include erased files"
Does that mean it backs up and restores areas of the drive holding...
Erased files...
But not deleted files?

So the effect is that none of these files would be [practically] recoverable after a restore?
So all files deleted by me before a backup/restore of a partition would be unable to be "un-deleted"?
And only files deleted SINCE the restore could be "un-deleted"?

Paul Komski
04-08-2007, 10:46 AM
Erased files would have repetitive data (often zeros) and so would be included in the algorithms. Non-repetitive data would be "uncompressed" or raw inside the image file. On restoration both the erased areas and deleted files would be reinstated. The non-repetitive data as was and the compressed areas as decompressed.

Or as I said "their img files are true clones and can be used to restore an exact replica".

Sylvander
04-08-2007, 01:01 PM
Now understood.

I like it. :)

phkhgh
04-08-2007, 05:18 PM
OK...where do I start?

1st, I wasn't asking about the actual backing up process, but I'll take the info on that, as well.

I was referring to specific steps or tasks to perform, as a matter of precaution, before doing the backup.

PrntRhd - Don't know whether NTFS needs less defragging than say, Win 98, but on my PC, it still needs it sometimes. More on the XP partition than others.

Back to my original question: other than anecdotal wisdom, do any major backup software co's, MS, or respected books, etc., discuss defragging (for instance) before backups; or that you should backup, then defrag? I haven't found any yet.

Although a lot of users seem to have strong opinions, I haven't come across anything from anyone that's actually done research on it.

Thanks for the input.

Paul Komski
04-08-2007, 05:52 PM
I'll ask again. What methods of backing-up do you envisage using?

There is a lot of difference between using XXcopy to copy all the files from one partition to another and using ImageForDOS or Norton's Ghost to create an image of a partition.

An example. Simply copying files from an old to a newly formatted FAT partition would de facto create a defragmented file system since all files would be written de novo and would thus all be contiguous. It doesn't take a reference to a scholarly article to find this out. Just do it.

There are valid reasons for defragging prior to moving, compressing, resizing partitions and such like - but the reasons are generally to allow for a faster imaging process or with Linux/Unix dd to create files that it is easier to compress more effectively.

The list goes on and on - so without some specifics the answers can only be generalisations. On a broader front defragmentation or the lack of it is a performance issue more than anything else to do with data integrity - if that is what is the main concern.

Sylvander
04-09-2007, 07:10 AM
Just realised that if one were to "erase" unused space on a partition [which would overwrite "deleted" files with patterns of 0's and/or 1's], the image backup would then be smaller [when using the compression algorithms of BiNG and IforD]. :)

Paul Komski
04-09-2007, 07:43 AM
Just realised that if one were to "erase" unused space on a partitionIt all depends on what software is used and what its algorithms are. If you want to use dd under linux to clone a partition and then gzip or make a tar-ball it can be important to use literal zeros to erase unused areas of the disk first since only they are included in the algorithms - so with a very "dirty" partition the compressed file will not be very small. It is also worth noting that compression can actually result in files that are larger than the uncompressed version if not much compression is possible in the first place and the algorithms themselves take up more space than the "empty" areas.


Back to my original question: other than anecdotal wisdom, do any major backup software co's, MS, or respected books, etc., discuss defragging (for instance) before backups; or that you should backup, then defrag? I haven't found any yet.
I think the reason there is little mention of defragmentation in association with backing-up, per se, is that it is largely a non-issue. Defragmentation (http://en.wikipedia.org/wiki/Defragmentation) and its benefits are often misunderstood or overstated and file systems are designed to work with fragmented partitions. The main effects of defragmentation are to do with performance and some wear and tear of the hard drive. On modern software and hardware this is even less of an issue than on legacy stuff. I had a search through the whole of MSDN 2003 and could only find one article that alluded to backup and defragment in the same section. It was the article Troubleshooting Poor Performance in Microsoft Backup (http://support.microsoft.com/?kbid=137942) and it is noteworthy that it is a legacy OS and that the only reason to defrag was a performance issue that was not even unique to MS backup's program.

I would turn the question on its head and say please post any articles on defragmentation with respect to backup and we can see if those articles hold any water.

malcore
04-10-2007, 02:11 AM
I don't have a link to an article or a book suggestion. Just thought I would offer some info.

The only time defragging before backing up would be a bad idea is if doing "incremental" backups. Some imaging software, such as Acronis, have the ability to set up a partition for backups which is hidden from Windows and where one can do incremental backups to an image file, only adding new data to the image. As the image is created sector by sector, if one were to defragment between backups, then it would seem to the imaging program that there is so much new data (although in reality there isn't, it's just a lot of the old data has been moved somewhere else on the physical drive) that it would commence to create an entirely new image. No data lost, just time.

I have never heard anyone suggesting defragging was a bad idea before backing up other than in the above scenario.

Paul Komski
04-10-2007, 03:14 AM
Some imaging software, such as Acronis, have the ability to set up a partition for backups which is hidden from Windows and where one can do incremental backups to an image file.I don't know about Acronis but the incremental backups utilised by the latest versions of Norton's Ghost certainly use the file system and not drive sectors to identify new content. Bear in mind too that defragging doesn't move/alter the directory structure of the "folders" in either FAT or NTFS partitions - it just shifts around the data that the directory tree refers to.

The original versions of Ghost (prior to the acquisition of PQ's Drive Image) did create "literal sector by sector cloned images" as do the TBU utilities nowadays but the new Ghost is an "upgrade" of PQ's DI, which always looked at the file system. It did for example never copy the page file into its images as a way of making its image files even more compressed.

I would suspect that both Acronis and Ghost's incremental backups use a method of injecting files into a "container" akin to an iso or a WinImage img File. Shouldn't be too hard to sus out with a hex editor prior to and after such an "injection".