Created
April 9, 2017 17:46
-
-
Save rtrouton/1adf016fc5306ccc6d7308813609f1b0 to your computer and use it in GitHub Desktop.
diskutil repairDisk script for fixing a VM boot disk's partition map.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# Fix VM boot disk's partition map. This is necessary | |
# to allow the boot drive to grow after cloning a VMDK. | |
# | |
# Issue documented here: | |
# https://kb.vmware.com/kb/2069255 | |
# http://osxadmin.blogspot.com/2014/03/expand-os-x-virtual-disk-in-esxi.html | |
# repairDisk asks for a y/n confirmation before running, | |
# so the yes command is piped into the command to answer | |
# "yes" to the confirmation dialog. | |
/usr/bin/yes | /usr/sbin/diskutil repairDisk /dev/disk0 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment