Forked from Kyborg2011/repaire-damaged-ext-drive.sh
Created
January 25, 2022 16:25
-
-
Save kabacs/302a50b00ce19a3fd8e22594edb679b8 to your computer and use it in GitHub Desktop.
Repairing damaged external drive (flash drive) on OS X
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
# If "Disk Utility" can't erase a demaged disk and throw errors, like these: | |
# a) "-69888: Couldn't unmount disk"; | |
# b) "Couldn't modify partition map". | |
# You can repair disk (if it is damaged partially, just by a program error, while changing partition map of a disk in) by | |
# FULL ERASING OF A DISK - you can do that ONLY in A COMMAND LINE, using "diskutil" command (on OS X) | |
# 1. Firstly you must get path of a drive in a system, like this: | |
diskutil list | |
# Than complete erasing of a disk: | |
diskutil eraseDisk free EMPTY /dev/disk4 | |
# where "/dev/disk4" is a disk path, gotten on a previous step! | |
#For more information, you can look to the source of a method: https://discussions.apple.com/thread/8132218 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
This helped a lot (nothing else worked). Thanks.