Submit Hint Search The Forums LinksStatsPollsHeadlinesRSS
14,000 hints and counting!

10.4: Increase the max size of a FileVault directory System 10.4
Tiger only hintFileVault protected home directories are nothing more than a special usage of sparse disk images, like the ones you can create with Disk Utility. Sparse disk images only use as much space as they currently need to, but they do have a maximum capacity, determined at the time of their creation. Thus, FileVault protected home directories can run out of space, even if your hard drive has free space. This hint will explain how to increase the maximum capacity. You will need a copy of the latest version of Carbon Copy Cloner.

First, you will need a separate admin account on your system. Let's say the name of your FileVault protected user is foobar, and the name of your admin user is admin. Log in as admin, and navigate to /Users. Select the foobar folder, and select File: Get Info. Go to the Ownership & Permissions section of the Info window, and open the Details. Temporarily change the Owner to admin.

Now, open the /Users/foobar/ folder. Inside should be foobar.sparseimage. Select that file, and then do File: Get Info. As before, temporarily change the owner to admin. Now, before doing anything else, make a copy of the foobar.sparseimage file in a safe place in order to back it up.

Next, rename foobar.sparseimage to foobar_old.sparseimage. Double-click it to mount it. You will be prompted for foobar's password. Enter it, and a drive image named foobar should mount. Rename the drive image to foobar_old.

Open Disk Utility. You can inspect the mounted foobar_old to see what its current maximum size is, in order to help you decide how big to make the new maximum capacity. Select File: New: Blank Disk Image. Set the Format to sparse disk image, the Encryption to AES-128, and the Size to your new desired maximum capacity. Save the new image in /Users/foobar/ as foobar.sparseimage. When prompted for a password, you must enter foobar's password, otherwise the home directory will not mount properly when foobar logs in.

Once the new foobar.sparseimage is created, double click it to mount it. Now, launch Carbon Copy Cloner, and copy everything from foobar_old to foobar. Finally, unmount foobar and foobar_old. Remove foobar_old.sparseimage from /Users/foobar, and keep it someplace safe as a backup. Select the new foobar.sparseimage, and choose File: Get Info. Set the Owner to foobar. Do the same for the /Users/foobar directory to return ownership to foobar.

Now, log out of admin and log back in to foobar. That's it! You now have more available space in your FileVault protected home directory. If anything went wrong, you can restore your backup foobar.sparseimage into /Users/foobar using your admin account.

NOTE: When I followed this procedure, there was one hiccup. Suddenly any time I tried to delete a file that resided in my FileVault protected home directory, I would get a message telling me it would be deleted immediately, instead of simply being placed in the trash can. The problem was that the ".Trash" directory was missing from my home directory, and you can find the fix in this hint.
  • Currently 2.00 / 5
  • 1
  • 2
  • 3
  • 4
  • 5
  (2 votes cast)

10.4: Increase the max size of a FileVault directory | 7 comments | Create New Account
Click here to return to the '10.4: Increase the max size of a FileVault directory' hint
The following comments are owned by whoever posted them. This site is not responsible for what they say.
10.4: Increase the max size of a FileVault directory
Authored by: Tomster on Mar 22, '06 08:52:53AM

Isn't this a rather convoluted way of doing it? If maximum capacity has been reached by the sparse image, something I've not yet experienced, then why not just do the following two steps?

1.Turn off FileVault, thereby copying off all of the files in ~/ and removing the sparse image.

2. Turn on FileVault thus creating a new sparse image of the correct size and copy on all of the ~/ files.

[ Reply to This | # ]
10.4: Increase the max size of a FileVault directory
Authored by: PanicRoom on Mar 22, '06 11:40:11AM

In my experience, once the size of the Home folder exceeds a certain percentage of the total HDD size (over 60%[?? -- someone please correct me here]), it is no longer able to encrypt/decrypt. You get an error message saying that there is not enough available space on the drive to complete the procedure. This may have since changed under 10.4, but under 10.3 on my iBook I had to copy GBs of media files to a firewire drive, log out (which adjusted the sparse disk image size back down), log back in, then turn off FileVault and finally reimport my data back.

[ Reply to This | # ]
10.4: Increase the max size of a FileVault directory
Authored by: lincd0 on Mar 22, '06 01:26:15PM

Because that would defeat the purpose of FileVault, which is to avoid writing your files to disk in the clear. Deleting a file merely removes the directory entry, not the data.

[ Reply to This | # ]
10.4: Increase the max size of a FileVault directory
Authored by: murali1080 on Mar 22, '06 04:00:07PM

You can use something like 'secure erase' to overcome the data being left behind even after a transfer to an encyrpted sparseimage. There is an option for it while you choose filevault for an account.

[ Reply to This | # ]
10.4: Increase the max size of a FileVault directory
Authored by: kaih on Mar 22, '06 01:24:07PM

What about the recovery password?
With FileVault, you can have a machine Master Password - so that if you forget your user password, you can still use the machine master password to access the encrypted file vault image.
Now, creating your own encrypted sparse image - does anyone know if this sets a master password as well, or if you lose your login password, is all the data lost?


[ Reply to This | # ]
10.4: Increase the max size of a FileVault directory
Authored by: rspeed on Mar 22, '06 09:33:45PM


There is a MUCH better way to accomplish this! Apple includes a command-line application for disk image manipulation called hdiutil. It works perfectly even with encrypted images. You don't need any extra space to build a new image, the disk image doesn't need to be mounted and the process is MUCH faster. The command for resizing is something like this:

hdiutil resize 40g /Users/foobar.sparseimage

The "40g" is the new maximum size. You can set it to anything larger than the current used space, or "max" to make it as big as possible.


[ Reply to This | # ]
10.4: Increase the max size of a FileVault directory
Authored by: kren2000 on May 12, '06 09:27:18AM
The grammar of the hdiutil command is slightly different from what was given above. It should be:
hdiutil resize -size 200g MyFile.sparseimage 

This works for expanding the capacity of regular sparseimages as well. Who knows why this isn't built into DiskUtility?

[ Reply to This | # ]