OS 10.1 - how to back up system and files?

Andy Hughes

Registered
I have a 20 GB hard drive that has my 10.1 system and files, and a 60 GB drive I can back up to. I have my files in the normal folder locations (applications, docs, etc.). How can I back up my whole main disk to my backup drive such that if my main disk ever crashed I could get things back? I am willing to run a script from the command line, or drag the files to the second drive, but I am concerned about restoring things if the drag and copy doesn't keep the unix files in their correct form. I'd also consider a commercial package to do this, but I assumed unix users have had to do this for a long time. Simple, step by step set of instructions would be great, or a URL where this is explained. I think this would be of great use to other OS X users now that disk space is relatively inexpensive. I am willing to some loss of data if I don't do the backup regularly myself, or if a cron job could do this it would be nice.

Ideally, I would have a script named "backitup" that I or a cron job would run it, and I would just have to get that script and modify it to give some volume name of my second hard drive. Then if I ever lost my main disk to a crash, I could reformat it with a OS X CD or get a new drive, and run a "reinstallit" script from the second drive that would put things back as the were at the last backup.

Show me the power!

Andy Hughes
(long time unix and mac user... never been root...'til now)
 
ATTENTION: Read all of this before doing a backup job in this manner.

You could just do a simple command line copy over, since command line copies copy invisible contents as well, I believe.

Mount your 60 GB drive, and just do a cp, by using the format:

"cp directorytocopy targetdir"

where "directorytocopy" is the path to the directory you want to copy over, and "targetdir" is the path to the folder where you want the contents to go on your 60 gig hard drive.

USE EXTREME CAUTION, though:

DO NOT do a "cp / /Volumes/60gigharddrive", because, for obvious reasons, this will be an infinitely looping copy, since /Volumes/60gigharddrive IS on /, so it will copy all contents onto the backup again, but then it has to copy THOSE again, and so on and so forth.

Because of the way UNIX works, volumes are mounted in the /Volumes directory, but the partition/hard drive you are currently running off of is the root folder, or / . An example:

I have 2 partitions, and an iPod. I run OS X off of C3P0, and OS 9 off of HAL 9000. When running OS X, / will be all the contents of C3P0, and all the contents of HAL 9000 will be in /Volumes/HAL 9000/ . When I connect my iPod, it appears in /Volumes/simmy's iPod/. This is inherent to UNIX.

My reason for telling you all of this is that you REALLY don't want to copy the contents of /Volumes, so you'll have to do a manual copy of everything else, which might be like 50 copy commands, since there are some invisible files that you will need to copy from the root folder (use the command "ls -a" to see all invisible files -- "." is the current folder and ".." is an alias to the previous folder, so those you don't need to worry about).

Another thing: the cp command only copies the data fork, I believe. So you'll actually have to use the "cpmac" command. To use this, you must have the latest Developer Tools installed. If you have the 10.1 Developer Tools CD, you can install it from there -- if not, you can download them for free (with free ADC member activation) from http://connect.apple.com/ .

You might want to do some tests with cpmac, as I really haven't been using it all that much.

If anyone has any more info about backing up in the manner I have described, I would be really interested in how effective this is.

I think there are still some problems with the OS so that Dantz has been unable to release Retrospect X. But 10.1 is a big improvement, and hopefully 10.1.1 has fixed these problems. So I really don't know of any commercial backup software that will work with OS X.

UPDATE: One thing I forgot to say is that there may be special characters in some of your file names or folder names in the root folder. One of them is the space character. To get around this, you can just drag the folder from the Finder onto the Terminal window, and the path to that folder will automatically be added to that window, complete with all the little things needed to make sure that spaces and other special characters get interpreted as part of the filename.

I hope I made myself clear on all of this -- if not, just reply back.
 
I have a solution that does not take as long to explain (even though that is a thorough and workable UNIX-esq solution) ...

Step 1) Reboot under OS 9 with little/no extensions for simplicity and safety.

Step 2) Run Disk Copy 6.4 (v. 6.3 does not seem to have this feature). Select "Clone" option from menu.

Step 3) Chose SOURCE volume when prompted (must be smaller than destination volume by atleast 10MB for safety).

Step 4) Chose DESTINATION/TARGET volume when prompted.

Step 5) Click "Begin", "Clone", or whatever button.

... relax and wait ... (and wait cuz it'll copy your WHOLE drive including invisible files -- resulting in an IDENTICAL drive (with extra space left over) that can even be booted up from!)
 
While that sure sounds like an elegant solution, I have yet to see Apple release DiskCopy 6.4. Until then, I stand by my original UNIX-esque backup solution as the best one so far, even though it is complicated.
 
Apple has failed to deliver the December developer tools, as far as I can tell -- at least to people with free membership on the Apple Developer Connection. At http://connect.apple.com/, under the "Mac OS X" section of the Downloads, the latest release is October 2001. I have reloaded the page, and it still says October. I have been anticipating this download ALSO because it has AppleScript Studio which sounds awesome. But alas, they are not there. And in the October 2001 developer tools, there is no such DiskCopy 6.4. I wish there was.
 
I STILL can't seem to find it. I actually have downloaded the disk image before, and insntalled those developer tools, but Disk Copy 6.4 still hasn't been installed, and it doesn't seem to be on the disk image. Are you SURE it is there?
 
I just redownloaded the October developer tools and am installing them now. I will tell you if I find it, but I am kind of doubting it because I did install them before, and Disk Copy 6.4 hasn't shown up. I'm not so dumb that I can't do a simple Sherlock search for Disk Copy to find it.

I'll tell you if I find it in these Developer tools. About the Developer Tools CD, did Disk Copy 6.4 come on the Mac OS X 10.0 Developer Tools CD, cause that's what I have... I bought OS X as soon as it came out. :) I remember installing those, too, but I have never seen a Disk Copy 6.4.

Watch for my update to this post.
 
I finished reinstalling the Developer Tools from October 2001 that I redownloaded, and Disk Copy 6.4 is NOT in there. I have checked multiple times, and it is definitely not there.

GadgetLover, are you SURE that paid members of the ADC do not receive a different copy of the Developer Tools disk image? That would definitely explain the problem.

Solaris: I suspect that dump would not copy resource forks, which are essential when copying.
 
Make SURE that you download the FREE copy, not the one that you might get from your ADC membership, cause that might make the difference. Even though you might find it in your developer tools, it's definitely not in mine, I can tell you that, unless I've VASTLY overlooked something and Sherlock is acting up.
 
Found this while trying to find Disk Copy 6.4 ...
(don't know if this is still valid, but who knows) . . .

Originally posted by Ed010
There is a copy in my public folder at apple i-tools.
My user name is ed010. If you haven't used i-tools open an account sign on and you will see directions for finding public folders.
I think I also saw it on carracho.

Originally posted by Paul Derby
Ed010, thanks for making Disk Copy 6.4 available. I've used it to CLONE 22GB of 9.2/10.1 files from a 48GB drive to an 80GB drive and back. It worked flawlessly. I did notice when running Disk Warrior on the just cloned target disk that the directory was quite fragmented. A quick pass with Disk Warrior cleaned up the directory nicely.

Where do you get copies of Disk Copy? I'd love to keep up with this utility as Apple adds features. Are there plans to put the CLONE capability in the OS X version?

Thanks for helping those of us that want to backup. This is a great solution for my situation. I work/live in 3 different locations and have a large external FireWire drive in each location. Now I can make an exact copy of my PowerBook's internal drive as I move from location to location for backup/disaster recovery.

Originally posted by Paul Derby
I was able to get a copy of Disk Copy 6.4 with the new CLONE command. It does a great job of cloning my internal drive to an external FireWire drive. I've booted both 9.2 and OS X 10.1 from the external drive with no problems. So now I have a way to make backups (gosh I wish there was something like Retrospect for OS X that supported stand alone machine incremental backups).

===

Unrelated: While plowing through the Mac OS X 10.1 Developer Tools, I was reminded of one of the reasons why I first spoke to Apple about the tool set. Burried deep within the package (Applications "Extras", I believe) is a nifty little hidden gem (among other great utilities all power-OSX-users should have): a carbonized version of SimpleText. It's a must have; that way if ever you open up a simple text document (not TextEdit) it won't boot up that damn Classic Environment which some of us don't use all the time. Cool, eh?
 
Thanks to all who replied. I got disk copy 6.4 from ed010's itools public folder, and will try the "clone" method, and also play with the unix cp command provided here.

What a great forum!

Andy Hughes
 
Just a word of advice IF anyone decides to use the command line to do a cp...
cp will NOT copy resource forks if you so happen to have any apps that are Classic apps they will be damaged.

the way to copy to be sure that resource forks stay intact is.

diito -v -rsrcFrok (target) (destination)

please remember what the prior poster said about looping.
SimX Wrote
DO NOT do a "cp / /Volumes/60gigharddrive", because, for obvious reasons, this will be an infinitely looping copy, since /Volumes/60gigharddrive IS on /, so it will copy all contents onto the backup again, but then it has to copy THOSE again, and so on and so forth.

Because of the way UNIX works, volumes are mounted in the /Volumes directory, but the partition/hard drive you are currently running off of is the root folder, or / . An example:


cheers
 
I'm sorry, I forget where i found this out. It may have been an Apple til.
And yes I did spell it wrong... thanks for catching that.

Cheers
 
if you run the command "ditto" in the CLI, without any variables, (i.e., just "ditto") you get the following usage guide (this applies for all UNIX commands, the usage guide):

Usage: ditto [-v] [-V] [-arch archVal] [-bom bomFile] [-rsrcFork] src [ ... src] dst
-v print a line of output for each src copied
-V print a line of output for every file copied
-arch archVal fat files will be thinned to specified archVal
multiple -arch options can be specified
archVal should be one of "m68k", "i386", "hppa", "sparc", etc
-bom bomFile only files present in the specified bom are copied
-rsrc copy preserving resource forks
 
Back
Top