Skip to main content
Question

Lion Recovery Partition Deletion Script?

  • August 30, 2011
  • 4 replies
  • 19 views

Forum|alt.badge.img+20

Has anyone here developed a script to remove the hidden Lion Recovery Partition???

--
Matt Lee, CCA/ACMT/ACPT/ACDT
Senior IT Analyst / Desktop Architecture Team / Apple S.M.E / JAMF Casper Administrator
Fox Networks Group

4 replies

Forum|alt.badge.img+7
  • Contributor
  • August 30, 2011

Script, no, but diskutil should do what you need.


  • August 31, 2011

You'd need to put Disk Utility into debug mode to be able to see the Lion partition to then be able to remove it.

Diskutil –list will show "Recovery HD" however.

GL.

Rhys.


Forum|alt.badge.img+21
  • Contributor
  • May 30, 2012

I know this post is old, but I figured it was worth putting the info here anyway. This was my quick and dirty script and only applies if the OS is loaded on the main disk. Use at your own risk.

#!/bin/sh
/usr/sbin/asr adjust -target /dev/disk0s3 -settype Apple_HFS
/usr/sbin/diskutil mergePartitions HFS+ 'Macintosh HD' disk0s2 disk0s3

Forum|alt.badge.img+21
  • Contributor
  • May 30, 2012

And as well I will link back to martin's other post as well, which is better than my script. Tidying things up here.

https://jamfnation.jamfsoftware.com/discussion.html?id=3075