The image is split into chunks of multiples of 4096 bytes. So this is obviously a sparse image of some type, since its size is smaller than the actual filesystem size. Gz sudo dd of=/dev/disk2s1 bs=1mSparse bundle disk image is an optimized form of the sparse disk image. 0, Total of 25-byte output blocks in 60 input chunks. The image is split into chunks of multiples of 4096 bytes. So this is obviously a sparse image of some type, since its size is smaller than the actual filesystem size. Gz sudo dd of=/dev/disk2s1 bs=1mSparse bundle disk image is an optimized form of the sparse disk image. 0, Total of 25-byte output blocks in 60 input chunks.
- Sparse Image Vs Sparse Bundle
- Apple Sparse Bundle Disk Image Media Tool
- Apple Sparse Bundle Disk Image Media
The String of Bugs Continues in APFS. |
---|
Just after the month of releasing macOS High Sierra and new file system (APFS), Mac users experienced a bug that exposed the encrypted APFS passwords via the password hint feature. The issue affected Macs with APFS file-system and users who had entered a password hint. Apple soon issued an emergency patch to fix the Password Leak Disk Encryption Utility.
Earlier this year, Apple tackled a bug – a specific character in the Indian language Telugu – which caused crashing of apps and system in iPhone, iPad, and Mac. Apple released updates for all its devices (iPhones, iPads, Apple Watch, Apple TV & Mac) to fix the ‘Telugu’ bug.
Unlike these instances of bug reports, Apple suffered from an APFS bug vulnerability that leads to data loss in macOS High Sierra. Mike Bombich, the creator of Carbon Copy Cloner (a Mac backup application) uncovered the ‘’sparsebundle disk images’’ flaw in APFS-formatted Mac.
Data Writing Flaw in APFS
Disk images are useful to take necessary backup of sensitive files to network volumes and for disk cloning operations. Sparse disk image is basically a disk image file that contains the structure of a disk volume which mounts on your Mac and is treated as a physically connected drive.
Sparse disk image shows available space which permits you to utilize the free space available. However, there is a mismatch in the values of APFS sparse disk image ‘free disk space’ and the ‘actual free disk space’ which results in data loss.
The bug came to light when Bombich reported that his sparsebundle disk image showed sufficient free space and when he copied a video file to disk image volume it got corrupt. Here’s what he experienced:
“Earlier this week I noticed that an APFS-formatted sparsebundle disk image volume showed ample free space, despite that the underlying disk was completely full. Curious, I copied a video file to the disk image volume to see what would happen. The whole file copied without error! I opened the file, verified that the video played back start to finish, checksummed the file – as far as I could tell, the file was intact and whole on the disk image. When I unmounted and remounted the disk image, however, the video was corrupted. If you’ve ever lost data, you know the kick-in-the-gut feeling that would have ensued. Thankfully, I was just running some tests and the file that disappeared was just test data. Taking a closer look, I discovered two bugs in macOS’s “diskimages-helper” service that lead to this result.”
![Apple Apple](https://upload.wikimedia.org/wikipedia/en/thumb/c/c2/FileVault.png/64px-FileVault.png)
Source:https://bombich.com/blog/2018/02/15/macos-may-lose-data-on-apfs-formatted-disk-images
The following example illustrates data loss due to file system bug:
- Suppose you create a 100 GB APFS-formatted sparse disk image
- You copy 80 GB data to the sparse disk image
- The APFS-formatted sparsebundle disk image file is not updated and continues to show 100 GB of free space
- You copy another 50 GB of files to the sparse disk image
- You even access the files after transferring the files
- Remount the disk image, transferred files become corrupt and 30 GB of data disappears
The file system bug affects only the APFS-formatted sparsebundle disk image and not the startup volume. Bombich further identified two issues:
- The APFS-formatted sparse disk image doesn’t update the free space available
- The user does not receive any ‘no more space’ notification
The video illustrating the sparse disk image bug in macOS High Sierra
Stellar Data Recovery Professional for Mac : your trusted recovery tool
Although Bombich lost a test file, you might lose important files and folders due to the file system bug. Apple hard drive reader. As of now, Carbon Copy Cloner has dropped the support for APFS-formatted sparse disk image until the bug is resolved; however, if you lose your files, you can recover it back using Stellar Data Recovery Professional for Mac software.
The software recovers data lost due to file system bug as it supports Apple Time Capsule on sparse bundle disk images. Also, as you’re concerned about the lost data, its intuitive user-interface and easy layout provide relief to you and delivers favorable outcomes. Apple video android.
Stellar Data Recovery Professional for Mac is easy to understand and easy to run. You do not need to spend time getting familiar with its functionality, simply make your selection and recover data efficiently and effortlessly.
The recovery steps are as follows:
- Run Stellar Data Recovery Professional for Mac and toggle-on ‘Recover Everything’ tab. Click Next (You can even customize your selection)
- Select the sparsebundle disk image and click Scan
- The software scans the disk image for recoverable files
- Once the scanning is complete, all the recoverable files are listed hierarchically
- Preview the files before saving them
- Select the files, click Recover, specify the destination folder and click Save
Conclusion
Sparse Image Vs Sparse Bundle
Apple is known for challenging status quo by producing magical experiences through its exemplary products. With every update, Apple introduces ground breaking innovations and steps up the game. The same pattern is followed with the new file system (APFS), Mac users get a good deal of reasons to sink their teeth into this.
Although there will be some performance hiccups and random bugs but the Cupertino-based tech giant always resolves the issue at the earliest. But when your data is at stake, you should take an extra step in protecting it as the case with the sparse disk image bug. This is when Stellar Data Recovery Professional for Mac proves worthwhile. Until there is a macOS update to resolve the bug, you can count on the software to recover data after the bug attack and continue with the magical Mac experience.
In the latest releases of both my ebooks on backups (“Take Control of Mac OS X Backups” and “Take Control of Easy Backups in Leopard“), I include sidebars titled “(Sparse) Bundles of Joy,” in which I describe Leopard’s new sparse bundle disk image format, used by Time Machine for network backups. Because this format is quite interesting, has potentially broad application, and hasn’t received much attention, I’d like to say a bit more about it here.
Managing Your Image — By way of review, a disk image is a special file that can also behave like a disk – that is, if you double-click the image, a new volume appears in the Finder; this volume can contain any number of files and folders, and you can open or copy them just as you would do with the contents of any other volume. Disk images typically have the extension .dmg and are often used to distribute software. Unlike ordinary folders, disk images can be compressed, encrypted, and/or made read-only, and can be opened on any Mac, all without the use of any third-party software. If you want to distribute a whole set of files and be sure that they remain perfectly intact on the other end, using a disk imageis an excellent way to do so.
Over the years, Apple has created a variety of different formats for disk images. The sparse image (extension .sparseimage), for example, was an improvement over the .dmg format in that it could grow automatically in size as needed (up to a preset maximum). Prior to Leopard, Mac OS X used sparse images for things like local copies of your iDisk (if you have iDisk Sync turned on in the MobileMe pane of System Preferences) and FileVault (which used an encrypted sparse image). In both cases, the images could begin relatively small, rather than occupying lots of unused space on your disk even when they contained little data.
But sparse images, like .dmg images, had a problem. Making any change to their contents marked the entire image file as changed. If you were doing incremental backups that included a large disk image file, say, this meant that even the tiniest change would result in the entire file having to be backed up again. For example, I used to store private documents on a 10 GB encrypted .dmg disk image. But I couldn’t back up the disk image file itself, because it changed every day and I’d rapidly run out of disk space if I kept backing it up. So instead, I had to separately back up the contents of the mounted image to an encrypted archive, which was an inconvenience.
Bundle Up — When I upgraded to Mac OS X 10.5 Leopard the first time, one thing I noticed immediately was that a copy of my local iDisk sparse disk image was sitting on my Desktop, while a new disk image, this time with the extension .sparsebundle, was stored in a subfolder of ~/Library/FileSync. Leopard had taken the liberty of converting my iDisk image to a new format – a sparse bundle – and put the old one on my Desktop as a backup, presumably in case anything had gone wrong during the conversion. So what’s with the new format and why should you care? Macbook pro 13 retina for programming.
A sparse bundle looks and acts just like a sparse image – it can grow in size, can optionally be compressed or encrypted, and so on. What’s different is that it isn’t actually a single file, as all previous disk image formats were. It’s a bundle (also known as a package) – a folder that Mac OS X treats as a single file, which is also true of applications. (To verify this, you can Control-click or right-click a sparse bundle, choose Show Package Contents from the pop-up menu, and browse through its contents.) Inside that package is a folder full of bands – files that are each 8 MB in size, as many as are needed to hold the image’s data.
What’s cool about this is that if you change something on a sparse bundle (adding or modifying a file, for instance), only the band(s) containing that data change, not the whole bundle. As a result, assuming your backup software treats the contents of bundles as individual files, you no longer have to back up a huge disk image just because a tiny file changed. Your backup software only has to copy the 8 MB band(s) containing any of that file’s data (often only one). So I converted my encrypted sparse image to an encrypted sparse bundle, and now I can include it along with all my other files in my ordinary backups.
Nuts and Bolts — You can create and modify disk image files (of whichever sort) using Disk Utility, located in /Applications/Utilities, or with the command-line tool diskutil if you’re so inclined. For example, to create a new, encrypted sparse bundle, you’d follow these steps:
- In Disk Utility, choose File > New > Blank Disk Image.
- Fill in the filename, location, volume name, and maximum size; leave the format as Mac OS Extended (Journaled).
- Choose either 128-bit or 256-bit AES encryption from the Encryption pop-up menu. Leave Partitions set as it is.
- From the Image Format pop-up menu, choose Sparse Bundle Disk Image.
- Click Create. Enter and verify a password and click OK.
Although Disk Utility can also convert one format to another (using the Images > Convert command), I’ve had some trouble with this method, and I’ve generally found it more reliable to create a new image from scratch and copy the contents of the old image manually.
Apple Sparse Bundle Disk Image Media Tool
The Future of Sparse Bundles — As I mentioned earlier, Time Machine stores your backups in sparse bundles when you’re backing up over a network (to another Mac running Leopard, or to a Time Capsule). The Leopard version of FileVault also uses the sparse bundle format now, which may decrease its susceptibility to disk errors. (I’m still no fan of FileVault, though, because apart from the threat of losing data to file corruption, I prefer much greater control over what is, and isn’t, encrypted.) But what I find most exciting about sparse bundles is the problems they could potentially solve, if more developers used them.
Let’s go back to the problem of backing up huge files that change frequently. If you use Parallels Desktop or VMware Fusion to run Windows on your Mac, this is still an issue, because those programs still store all their data in monolithic disk image files. Similarly, Microsoft Entourage uses a single big database file to store all your email, contacts, and calendar information. So conventional wisdom says you should exclude files like these from Time Machine or other backup programs that run frequently, because otherwise your backups will take an excessively long time and require tons of disk space. Unfortunately, that also means you have to find some other, more cumbersome way to back up that data – or leave it unprotected.
If Parallels, VMware, and Microsoft were to adopt the sparse bundle format for their respective data storage needs, at least as an option, this problem could disappear. (This approach would work only under Leopard, however.) In fact, I know of at least one attempt to trick Entourage into using a sparse bundle, though the process is rather elaborate and geeky, and I haven’t tried it myself. Similar acrobatics could possibly be performed with virtualization programs, basically forcing them to store their existing disk images on sparse bundles, but it would be better by far if users didn’t have to jump through such hoops.
Apple Sparse Bundle Disk Image Media
Although Entourage and virtualization programs are among the most prominent examples, undoubtedly many other applications that deal with very large files could also benefit from using sparse bundles. For all I know, perhaps developers are already hard at work bundling up their images, or perhaps technical problems I’m unaware of (beyond the requirement for Leopard) make it harder than I imagine. But for the sake of speedy and space-efficient backups, I certainly hope the sparse bundle rapidly becomes a favorite format for storing large amounts of data.