Casper Imaging from NetBoot appliance NilObject exception when "Erase Target Drive" selected

New Contributor III

I recently started having an issue with using Casper Imaging.

When using NetBoot to our NetBoot Appliance, or using a USB drive with Casper imaging loaded on it, if I have "Erase Target Drive" selected, Imaging will fail with NilObject Exception.

if I don't check that, imaging will complete, but not create the recovery HD like we would like.

@franton had some questions in another thread, and not wanting to totally hijack it, I thought I would create this thread .
That can be down to a bunch of things usually:
1) can the distribution point be mounted from inside the netboot environment?
2) is your netboot server set to use diskless mode?
3) did you select the replace rc.netboot file option in autocaspernbi ?

It's usually one of those.

1)Yes, all of our DPs are mountable.
2)We're using the Netboot Appliance, and it is diskless as I can unmount the drive, and wipe it manually.
3)I haven't selected that option. Are you saying selecting can cause or Help with the issue?

If I wipe the drive before imaging and do NOT select the wipe drive, it works just fine.


Honored Contributor III
Honored Contributor III

@MarkPetersonURMC what version of Casper Imaging? It might be worth trying another one.

New Contributor III


I've tried 9.51, 9.32, same result.


Did you figure this out? We just stated to have the same issue. We are running NetBoot/Sus appliance 3.0.1 and JSS 9.60.

Just before the issue started, we ran out of disk space on the appliance, due to Apple updates downloading. I have free up some disk space, but still having the issue.

Valued Contributor II

Usually when I run into this, the issue is that the NetBoot image isn't booting disklessly and it's using the internal drive for swap space. And, when you attempt to unmount the swap volume, it can't and Casper Imaging pukes.

If you quit Casper Imaging and attempt to dismount the internal hard drive, does it allow you? If not, there's your problem, if so, well, can you use Disk Utility to wipe the drive before re-imaging, and try again? But usually it's the former problem...

Valued Contributor II

I would agree it's the NetBoot image not booting disklessly... I think the answer at the end of this thread will fix it : )


Valued Contributor II

You can achieve that as one of the options in @bentoms' wonderful AutoCasperNBI. But I haven't had to use that lately. Different story with Mountain Lion Server, which had a bug/issue with wrong permissions on the shadow files which tended to break NetBoot (wrote a launchdaemon/script to work around that one 😉