Can you reboot to a different drive other than the target drive after Casper Imaging is complete?

ccheyne
New Contributor

I know in casper imaging there is the check box to reboot to the drive the image was just pushed to but is there a way to make it reboot to a different drive? My goal is to do all the imaging at night when the users are not here and then migrate their user accounts the next night so after imaging is complete the machine needs to boot back into the original drive so they can work in the morning.

3 REPLIES 3

Bauer
New Contributor

I don't think there's a way to set that via natively via Imaging.

I bet you could package up a script to bless the drive you want to reboot to, and set that package to install to the boot volume at imaging time. Set the package with a low enough priority that it'll run last, and you should end up with a configuration that would image your computer and reboot to the drive of your choice when it completes.

stevewood
Honored Contributor II
Honored Contributor II

Matt beat me to it. :-) Only difference in the method I would use is just that I would do it in my postflight script, or post install script and not in an actual package. I have a postinstall script that sets the clock and does other things, and as one of the last things it did I would have it bless that drive.

The trick will be knowing which partition you want to bless, so you have to know the name of the partition, and that name would need to be static (i.e. not changeable by the user).

Bauer
New Contributor

Steve's right. I had it in my head for some reason that packages ran after scripts, so I was suggesting to pack it up instead of just using the script itself.

Scripts do run last, and their order is based on alphanumeric order of the script's filename, so you could just name the script with something like zz_scriptname.sh or something similar so it will be the last to run after the other scripts (if you have any). I would set the bless script as the last one before Casper's reboot and you should be good to go.