Mirrorcopy

[Edit 20160224] Thanks to jPV I was able to correct some errors. You can read the manual with “more” and you shouldn’t use NOSOFT when copying system files.

If you remember my last post I wrote about some viruses I got and took care of. But it got me thinking about doing something I have been putting off for years: backing up and organizing everything. When you have a couple of terrabytes of stuff counting to hundreds of thousands of individual files then you can guess what I’ve been doing these last two months.

First I got myself a used PC with an external 5 TB hard drive. This serves as my backup unit and is connected via network. It’s not a NAS, as I don’t want the process to be automatic. I got several other external hard drives and USB sticks that also serves as backups in one way or another.

I have two 1 TB hard drives (FAT32 formatted) where one is connected to my Mac Mini and the other serves as a backup. This 1 TB hard drive contains all my pictures, documents, mp3:s etc. Everything except my videos, except for a few that I really don’t want to lose.

Then I also have my 3 TB hard drive where all my movies goes. Because movies can sometimes be larger than 4 GB (which is the limit for FAT32 formatted drives) this drive is NTFS formatted. This hard drive is connected to my media player and is also reachable via network. My 5 TB hard drive serves as a backup for everything on my second computer (also NTFS formatted).

One of the main problems with backups is replacing old files with new files. The easiest way is to just overwriting everything from Disk A to Disk B, but when you have hundreds of gigabytes of data this will take forever to overwrite. Especially if you do it via the slower USB 2.0, which is actually all I got on all my computers. There are backup programs that can do this, but the problem with those is that they will probably save in such a way that you can’t easily access the files, which is something I want to do.

With Windows I recommend Synchredible. It’s free for personal use and mirrors drives and/or folders from one place to another. That is, it only copies new and changed files (but it has plenty of options). There is also actually a pretty good program for doing the same in MorphOS. It’s called Mirrorcopy.

Mirrorcopy does what it sounds like: it looks at Disk A and Disk B and add new files to Disk B plus overwrite old files with new ones (just like Synchredible). You can download it here.

Unpack it to RAM: and look into the folder:

160223_001_ram

In the folder c you will find the program Mirrorcopy:

160223_002_mirrorcopy

Copy it to C:

Don’t bother reading the mirrorcopy.readme in docs as it’s not really helpful at all:

160223_003_crappy_documentation

[Edit] There is an error in the text file making MorphOS not recognise it properly. Use the “more” tool in Shell to view the documentation.

This is actually the biggest drawback with Mirrorcopy: it got terrible documentation. Start a Shell and type mirrorcopy ? and you will get this:

160223_004_mirrorcopy_questionmark

I can’t say I get much of it. I can guess what some of it does but I don’t feel secure enough to do anything on my own. Geit was nice enough to tell us what parametres we should use at Morphzone, which I’m going to reproduce here.

As the process of mirrorcopying stuff from one drive to another is identical for everything, I’ve decided to demonstrate it by backing up my System and Work drive to a freshly FAT32 formatted USB stick (because that is the likely format if you buy it new). Because I want to use it as a MorphOS backup I rather use MorphOS own file system SFS rather than Windows FAT32. So we have to reformat it.

I start by inserting the USB. It shows up in Ambient:

160223_005_new_usb_stick

Next I go to System:Tools:

160223_006_system_tools

I click on HDConfig:

160223_007_usb_with_errors

There seems to be something wrong with this disk (the yellow at the bottom). No matter, as we will format it anyway. I click on Repair and let it do it’s thing (clicking Yes until it’s done).

I press Save in the red area (I click OK when asked if it’s OK that it will lose all it’s data):

160223_008_usb_stick_fixed

Now I right click on the grey which says Free: 29.45 GB FAT32L. Chose remove partition and click Yes. Now we have no file system at all on the disk:

160223_009_free_pre_sfs

Right click on the grey area as above and we will get this menu:

160223_010_mbr_mac

We change MBR to MAC (I guess because I use a Mac Mini) and accept the loss of data. Then we left click on the grey area again. It asks me in Swedish how many partitions I want to format it as:

160223_011_number_of_partitions

I press One (29.45 GB). Now you can see that the drive uses the SFS file system.

160223_012_new_sfs

Next I left click on the grey area yet again and get this:

160223_013_dh0_rename

I rename the device from DH0 to Mos_Backup_2 (I already have a drive called Mos_Backup):

160223_014_new_name_mos_backup_2

I press OK and then Save once again in the red area (and accept once again data loss). Next we quit HDConfig and go to System:Tools again and start Format:

160223_015_format

I click on the Mos_Backup_2 part:

160223_016_format_mos_backup_2

I rename it to Mos_Backup_2 and press Quick Format:

160223_017_format_quick_format

It will now show up in Ambient:

160223_018_sfs_drive_in_ambient

We open it and create one folder called System and one called Work:

160223_019_system_work

Next we start a Shell and type this:

MirrorCopy ALL CNT NOSOFT NOHARD FROM SYS: TO Mos_Backup_2:System

It starts by scanning the System folder:

160223_020_mirrorcopy_start

[Edit] You shouldn’t use the NOSOFT option if you are copying system files.

Then it scans Mos_Backup_2:, but since it’s empty it’s over instantly and moves on to analysing what needs to be copied or changed:

160223_021_scanning_mos_backup_2

After a while it’s done and starts to apply the changes:

160223_022_applying_changes

Now there isn’t much to do but drinking coffee or something as copying some 140.000 files is going to take a while. This session took about 40 minutes but was finished without any problems:

160223_023_mirrorcopy_finished

Then I do the same for Work: by typing:

MirrorCopy ALL CNT NOSOFT NOHARD FROM Work: TO Mos_Backup_2:Work

The process is the same as with System: so I don’t have to show it here.

And now we have a perfect backup (or more precisely a mirrored version of the system disk). The first time one does this it will take it’s sweet time if you got plenty of stuff to copy. But let’s see what happens if I mirrorcopy the system drive again:

160223_024_mirrorcopy_again

Yep, it’s much much quicker. And now I know that what I got in the original place I also got in the new place. This of course means that things I delete from the original place also gets deleted in the new place so you need to keep that in mind. There is an option called NODEL (no delete) which I guess don’t delete anything in the destination place but I haven’t tried it.

Backing up everything was a very good move it turned out. A couple of weeks after I got my backups in order my USB hub started to glitch. When adding some new files it started to unplug and replug itself during a copy session which corrupted a bunch of files. By having them all backed up and neatly organized it was easy to replace the damaged files. Thinking about how many unreplaceable files I could have lost there makes my feet crawl …

Advertisements
This entry was posted in Uncategorized and tagged . Bookmark the permalink.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s