Synchronizing with a Disk Image create a disk image (or DMG) and then set up ChronoSync to synchronize to it

Synchronizing with a Disk Image

*** This guide applies to ChronoSync v4.6.7 and earlier.

ChronoSync can perform a synchronization (or backup) between any block device that can be mounted on your desktop. This usually means USB, FireWire, Thunderbolt, Flash and SD drives, or file servers. Another form of mountable “media” that is easy to overlook, however, is a Disk Image.

Disk Images are usually referred to by their filename extension, “DMG”. They are basically data files that mimic storage devices. The contents of these files are complete file systems and macOS can mount these file systems as regular volumes.

Typically, disk images are used to distribute data and applications (such as ChronoSync). However, you can create your own disk image and make it writable, thus allowing it to be specified as a destination target. Furthermore, ChronoSync identifies a disk image as removable media so you can have ChronoSync mount it automatically and unmount it when finished. You can even schedule a “sync-on-mount” to be performed whenever you manually mount a disk image file.

ATTRIBUTES OF DISK IMAGES

Why a Disk Image? There are actually many situations where using a disk image is advantageous – too many, in fact, to list here. We’ll touch upon some uses at the end of this guide. First, however, you must understand the two most useful attributes of disk images.

Disk Images Can Be Formatted As HFS+

The file system that macOS prefers to use is HFS+ (also called HFS Extended). It offers the ability to store and manage files in a distinctly Mac way, i.e. very long file names, few character restrictions, hidden extensions, rich meta data, resource forks, etc. Sometimes, however, you are forced to synchronize with a non HFS+ file system, such as Windows. This imposes many restrictions – you can either live with them, or create a disk image and place it on your non-HFS+ file system. You then won’t have any problems copying your data to an alien file system.

DMGS Can Be Mounted With Full Access Privileges

The default method for mounting disk images will result in the user having full ownership privileges of all the files and folders contained therein. Thus when scanning a mounted disk image, and copying data to/from it, there will be no permission related errors. The implications of this become huge when you realize that anyone who mounts a DMG will have full access. This allows you to share your data with other users without having to worry about access restrictions. This can be invaluable when synchronizing with a “central repository” that you need several users to have access to.

CREATE A DMG

Several utilities are available, but the one that comes with macOS, Disk Utility, is what we will use.

Launch Disk Utility from /Applications/Utilities. Choose “File->New Image->Blank Image…”. In the dialog that appears, you must specify a few pieces of information:

  • The name and location are completely up to you. A disk image, once created, can be copied anywhere.
  • The volume size should be large enough to handle the data you are synchronizing or backing up. For this guide, we’re choosing 4.7 GB, which is a typical DVD capacity.
  • The format should be “macOS Extended (Journaled)”, the Mac native filesystem.
  • The image format should be “Sparse disk image”. This indicates that the file itself will NOT be 4.7 GB in size, and will only grow as necessary.
  • Choose Encryption if you want to password-protect your data inside and prevent unauthorized access to your files. Encrypting your data will convert the data into unreadable code. Note: This password can be added to your keychain.

Click “Save” when ready.

disk image

MAKE SURE THE NEW DISK IMAGE HAS BEEN MOUNTED

Disk Utility should have mounted the disk image automatically after creating it. A new volume with the name you specified should appear on the desktop. If not, simply locate the disk image file you just created and double click its icon in the Finder.

SETUP YOUR TARGETS

Launch ChronoSync and specify your targets as you would normally do. In this example, we are creating a unidirectional sync with the source (left) target being the users “Documents” folder, and the destination (right) target being the newly created disk image.

SPECIFY MOUNTING OPTIONS

You’ll notice that the “Options” button is available for the disk image target. This is because ChronoSync identifies the disk image as removable media. You can thus specify the same mounting options you would have if this media resided on a removable device.

Depending on the nature of your backup, you may not need or want to modify any of the mounting options. In this case, we will instruct ChronoSync NOT to prompt for insertion, and to “eject” the disk image when synchronization is complete.

The “Prompt to insert media” option is disabled because we don’t want to be asked to insert the media if it is not mounted. ChronoSync will attempt to automatically mount the DMG before prompting for insertion so, if that fails, the DMG simply isn’t available.

The “Eject media after synchronization” option is turned on because we will only be using this media for backup. When backup is complete, we want to immediately unmount it. This will prevent the user from “tinkering” with the contents of the disk image. In a shared environment, this will also allow the DMG to be mounted by another user.

RUN YOUR SYNCHRONIZATION

If the DMG is not mounted when synchronization begins, ChronoSync will attempt to mount it. Assuming this happens successfully, the mounted volume will appear on the desktop and synchronization will proceed as normal. When complete, the disk image will be ejected and the mounted volume will disappear from the desktop.

WHAT IS IT GOOD FOR?

Synchronizing to Windows or Linux file servers which do not support the HFS+ file system. This allows you to preserve all file attributes, including Mac-style filenames such as “Research ƒ”.

Sharing data with other users on a file server, or even your own machine (if you have multiple accounts). Normally, synchronizing to a common folder doesn’t work because files retain the ownership of those who created them. Thus other users may be able to view your files but might not be able to modify them. With a DMG, whoever mounts the disk becomes the “owner” of all files.

Burning to CD or DVD. By choosing a DMG size that matches the capacity of a CD or DVD, you can quickly burn the disk image and be sure all your data will fit. This isn’t the case if burning from a folder. Also, it’s easy to setup a post-synchronization AppleScript that will do this automatically!

Safeguarding your data. By enabling encryption, you can restrict access to your data. This will protect the data from users who you want to block and, also, keep the data safe in the event of theft.

WHEN THINGS GO WRONG

For most people, the above steps will work flawlessly for creating a disk image and synchronizing to it. However, we live in an imperfect world and sometimes things just don’t work out as expected. If you encounter any problems following this tutorial, here are some tips that may help you get back on track:

Apple Help

From the “Help” menu in Finder, you can try the following search terms (minus the quotes):

  • “Create a disk image using Disk Utility”

Technical Support

Contact our technical support team and just ask! We don’t mind — we’re here to help!

Shopping cart0
There are no products in the cart!
Continue shopping
0