Get rid of “Resource Busy” message on Mac OS X The 2019 Stack Overflow Developer Survey...

Can I visit the Trinity College (Cambridge) library and see some of their rare books

Is there a writing software that you can sort scenes like slides in PowerPoint?

How to type a long/em dash `—`

Could an empire control the whole planet with today's comunication methods?

How to read αἱμύλιος or when to aspirate

How did the audience guess the pentatonic scale in Bobby McFerrin's presentation?

Can each chord in a progression create its own key?

Can we generate random numbers using irrational numbers like π and e?

The following signatures were invalid: EXPKEYSIG 1397BC53640DB551

Using dividends to reduce short term capital gains?

different output for groups and groups USERNAME after adding a username to a group

Is 'stolen' appropriate word?

Does Parliament need to approve the new Brexit delay to 31 October 2019?

Are spiders unable to hurt humans, especially very small spiders?

Deal with toxic manager when you can't quit

What is the role of 'For' here?

1960s short story making fun of James Bond-style spy fiction

should truth entail possible truth

What's the point in a preamp?

Are there continuous functions who are the same in an interval but differ in at least one other point?

Can the Right Ascension and Argument of Perigee of a spacecraft's orbit keep varying by themselves with time?

University's motivation for having tenure-track positions

ELI5: Why do they say that Israel would have been the fourth country to land a spacecraft on the Moon and why do they call it low cost?

Would an alien lifeform be able to achieve space travel if lacking in vision?



Get rid of “Resource Busy” message on Mac OS X



The 2019 Stack Overflow Developer Survey Results Are In
Announcing the arrival of Valued Associate #679: Cesar Manara
Planned maintenance scheduled April 17/18, 2019 at 00:00UTC (8:00pm US/Eastern)Get Rid of Error Messagezpool: pool I/O is currently suspendedCan't access external harddrive in OSXMounting Safecopy Image in Kali (Or any other OS)Recovering a lost partition table on Windows 8iMac 21.5-Inch (Mid-2011) + Boot Camp = Blinking CursorMac OS X This Disk doesn't use the GUID partition Scheme when upgrading to Mac OS SierraBad magic number in super-block / Invalid argument while trying to open /dev/sda12Dual boot computer partitions missing after force shut down during hibernateRecovery from encrypted lvm disk/partition





.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty,.everyoneloves__bot-mid-leaderboard:empty{ height:90px;width:728px;box-sizing:border-box;
}







11















I am trying to repair a lost HSF+ partition table an iMac by running the i command inside of sudo pdisk /dev/rdisk1. Once I try running the i command, I get an error message saying that the resource is busy:




pdisk: can't open file '/dev/rdisk1' for writing (Resource busy)




i command in pdisk /dev/rdisk1



I get the same result when using /dev/disk1, /dev/rdisk2, and /dev/disk2.



I also tried running sudo gpt /dev/(r)disk(1-3). Interestingly enough, the I only get a result from /dev/rdisk3:



sudo gpt /dev/(r)disk(1-3). /dev/rdisk3 gives a result



So, I try to see what is using the resource by running sudo lsof /dev/rdisk1, as well as sudo lsof /dev/disk1. Nothing shows up:



lsof on /dev/disk1 and /dev/rdisk1



I've also tried unmounting the device by running sudo umount /dev/disk1 as well as sudo umount /dev/rdisk1. I get a message saying that the device is not currently mounted:



unmounting /dev/rdisk1 and /dev/disk1



Here's a list of all of the disks connected to the computer, found by running sudo DiskUtil list:



DiskUtil list command




/dev/disk0 - The disk of the computer that the iMac is connected to.



/dev/disk1 - The HDD of the iMac.



/dev/disk2 - The SSD of the iMac.



/dev/disk3 - I don't know what this is. I would assume it is the combined HDD and SSD of the iMac.



/dev/disk4 - An external hard drive.



/dev/disk5 - I have no clue what this is either. Maybe utilities for /dev/disk4?




The iMac has a fusion drive, and /dev/disk1 is the HDD. I've tried with the SSD, /dev/disk2, but I get the same result.



I have the iMac plugged into another computer via thunderbolt, and by holding t when the iMac started up, the Macintosh HD showed up as an external device on the other computer.



How could I get rid of this message? I've tried restarting both the iMac and the computer that it is connected to.










share|improve this question

























  • discussions.apple.com/message/19120776#19120776

    – Ali786
    Apr 29 '15 at 5:38






  • 1





    This question could be better asked on Ask Different... Anyway: Is that single user mode that you are using? What are you booted into right now?

    – TheBro21
    May 4 '15 at 13:59


















11















I am trying to repair a lost HSF+ partition table an iMac by running the i command inside of sudo pdisk /dev/rdisk1. Once I try running the i command, I get an error message saying that the resource is busy:




pdisk: can't open file '/dev/rdisk1' for writing (Resource busy)




i command in pdisk /dev/rdisk1



I get the same result when using /dev/disk1, /dev/rdisk2, and /dev/disk2.



I also tried running sudo gpt /dev/(r)disk(1-3). Interestingly enough, the I only get a result from /dev/rdisk3:



sudo gpt /dev/(r)disk(1-3). /dev/rdisk3 gives a result



So, I try to see what is using the resource by running sudo lsof /dev/rdisk1, as well as sudo lsof /dev/disk1. Nothing shows up:



lsof on /dev/disk1 and /dev/rdisk1



I've also tried unmounting the device by running sudo umount /dev/disk1 as well as sudo umount /dev/rdisk1. I get a message saying that the device is not currently mounted:



unmounting /dev/rdisk1 and /dev/disk1



Here's a list of all of the disks connected to the computer, found by running sudo DiskUtil list:



DiskUtil list command




/dev/disk0 - The disk of the computer that the iMac is connected to.



/dev/disk1 - The HDD of the iMac.



/dev/disk2 - The SSD of the iMac.



/dev/disk3 - I don't know what this is. I would assume it is the combined HDD and SSD of the iMac.



/dev/disk4 - An external hard drive.



/dev/disk5 - I have no clue what this is either. Maybe utilities for /dev/disk4?




The iMac has a fusion drive, and /dev/disk1 is the HDD. I've tried with the SSD, /dev/disk2, but I get the same result.



I have the iMac plugged into another computer via thunderbolt, and by holding t when the iMac started up, the Macintosh HD showed up as an external device on the other computer.



How could I get rid of this message? I've tried restarting both the iMac and the computer that it is connected to.










share|improve this question

























  • discussions.apple.com/message/19120776#19120776

    – Ali786
    Apr 29 '15 at 5:38






  • 1





    This question could be better asked on Ask Different... Anyway: Is that single user mode that you are using? What are you booted into right now?

    – TheBro21
    May 4 '15 at 13:59














11












11








11


1






I am trying to repair a lost HSF+ partition table an iMac by running the i command inside of sudo pdisk /dev/rdisk1. Once I try running the i command, I get an error message saying that the resource is busy:




pdisk: can't open file '/dev/rdisk1' for writing (Resource busy)




i command in pdisk /dev/rdisk1



I get the same result when using /dev/disk1, /dev/rdisk2, and /dev/disk2.



I also tried running sudo gpt /dev/(r)disk(1-3). Interestingly enough, the I only get a result from /dev/rdisk3:



sudo gpt /dev/(r)disk(1-3). /dev/rdisk3 gives a result



So, I try to see what is using the resource by running sudo lsof /dev/rdisk1, as well as sudo lsof /dev/disk1. Nothing shows up:



lsof on /dev/disk1 and /dev/rdisk1



I've also tried unmounting the device by running sudo umount /dev/disk1 as well as sudo umount /dev/rdisk1. I get a message saying that the device is not currently mounted:



unmounting /dev/rdisk1 and /dev/disk1



Here's a list of all of the disks connected to the computer, found by running sudo DiskUtil list:



DiskUtil list command




/dev/disk0 - The disk of the computer that the iMac is connected to.



/dev/disk1 - The HDD of the iMac.



/dev/disk2 - The SSD of the iMac.



/dev/disk3 - I don't know what this is. I would assume it is the combined HDD and SSD of the iMac.



/dev/disk4 - An external hard drive.



/dev/disk5 - I have no clue what this is either. Maybe utilities for /dev/disk4?




The iMac has a fusion drive, and /dev/disk1 is the HDD. I've tried with the SSD, /dev/disk2, but I get the same result.



I have the iMac plugged into another computer via thunderbolt, and by holding t when the iMac started up, the Macintosh HD showed up as an external device on the other computer.



How could I get rid of this message? I've tried restarting both the iMac and the computer that it is connected to.










share|improve this question
















I am trying to repair a lost HSF+ partition table an iMac by running the i command inside of sudo pdisk /dev/rdisk1. Once I try running the i command, I get an error message saying that the resource is busy:




pdisk: can't open file '/dev/rdisk1' for writing (Resource busy)




i command in pdisk /dev/rdisk1



I get the same result when using /dev/disk1, /dev/rdisk2, and /dev/disk2.



I also tried running sudo gpt /dev/(r)disk(1-3). Interestingly enough, the I only get a result from /dev/rdisk3:



sudo gpt /dev/(r)disk(1-3). /dev/rdisk3 gives a result



So, I try to see what is using the resource by running sudo lsof /dev/rdisk1, as well as sudo lsof /dev/disk1. Nothing shows up:



lsof on /dev/disk1 and /dev/rdisk1



I've also tried unmounting the device by running sudo umount /dev/disk1 as well as sudo umount /dev/rdisk1. I get a message saying that the device is not currently mounted:



unmounting /dev/rdisk1 and /dev/disk1



Here's a list of all of the disks connected to the computer, found by running sudo DiskUtil list:



DiskUtil list command




/dev/disk0 - The disk of the computer that the iMac is connected to.



/dev/disk1 - The HDD of the iMac.



/dev/disk2 - The SSD of the iMac.



/dev/disk3 - I don't know what this is. I would assume it is the combined HDD and SSD of the iMac.



/dev/disk4 - An external hard drive.



/dev/disk5 - I have no clue what this is either. Maybe utilities for /dev/disk4?




The iMac has a fusion drive, and /dev/disk1 is the HDD. I've tried with the SSD, /dev/disk2, but I get the same result.



I have the iMac plugged into another computer via thunderbolt, and by holding t when the iMac started up, the Macintosh HD showed up as an external device on the other computer.



How could I get rid of this message? I've tried restarting both the iMac and the computer that it is connected to.







macos unix partition-recovery file-recovery






share|improve this question















share|improve this question













share|improve this question




share|improve this question








edited Apr 30 '15 at 2:53







Jojodmo

















asked Apr 27 '15 at 1:51









JojodmoJojodmo

108117




108117













  • discussions.apple.com/message/19120776#19120776

    – Ali786
    Apr 29 '15 at 5:38






  • 1





    This question could be better asked on Ask Different... Anyway: Is that single user mode that you are using? What are you booted into right now?

    – TheBro21
    May 4 '15 at 13:59



















  • discussions.apple.com/message/19120776#19120776

    – Ali786
    Apr 29 '15 at 5:38






  • 1





    This question could be better asked on Ask Different... Anyway: Is that single user mode that you are using? What are you booted into right now?

    – TheBro21
    May 4 '15 at 13:59

















discussions.apple.com/message/19120776#19120776

– Ali786
Apr 29 '15 at 5:38





discussions.apple.com/message/19120776#19120776

– Ali786
Apr 29 '15 at 5:38




1




1





This question could be better asked on Ask Different... Anyway: Is that single user mode that you are using? What are you booted into right now?

– TheBro21
May 4 '15 at 13:59





This question could be better asked on Ask Different... Anyway: Is that single user mode that you are using? What are you booted into right now?

– TheBro21
May 4 '15 at 13:59










3 Answers
3






active

oldest

votes


















4














First off, the pdisk command is used to modify drives that are partitioned using an Apple Partition Map. Only PowerPC-based Macs use those.



Secondly, your umount commands above are failing because /dev/disk1 and /dev/disk2 are not mounted. Typically only partitions are mounted (e.g. /dev/disk0s3), although in your case, you have a Fusion Drive. You are absolutely correct that /dev/disk3 is not a 'real' disk. It is the combined capacity of /dev/disk1s2 and /dev/disk2s2. If you type umount /dev/disk3, that should work. Of course, nothing is mounted on /dev/disk1 or /dev/disk2, so you will have to issue a diskutil unmountdisk /dev/diskN for those. That should free them up so the gpt command will stop giving you the resource busy error.



Fusion Drives use Apple CoreStorage partitions as containers, which is sort of analogous to Microsoft's Dynamic Disks. Unfortunately, they make manipulating the partitions more difficult, and take many disk/partition recovery products off the table.



However, aside from the issues above, I'm not exactly sure what the problem is. You mention that the partition table is lost, but the output from diskutil list suggests your partition tables seem to be OK.



Can you elaborate a little more about the problem you were having?






share|improve this answer


























  • I just updated the question. I'm assuming gpt would be the correct tool to use in place of pdisk?

    – Jojodmo
    Apr 30 '15 at 2:54











  • Correct. I updated my answer to reflect the additional info you posted.

    – Wes Sayeed
    May 1 '15 at 6:30











  • You can forget about the lost partition, the important thing is why I'm getting this message

    – Jojodmo
    May 2 '15 at 18:07



















1














try this:
diskutil unmountDisk force /dev/disk0 (or whatever your disk is)






share|improve this answer
























  • This doesn't work.

    – adib
    Jan 5 '18 at 12:35











  • @adib I just so happened to run in a similar problem (kept getting "Resource Busy" even though lsof showed nothing) and diskutil unmountDisk force /dev/disk<#> did work for me! 👍

    – RocketNuts
    Mar 27 at 15:51



















0














I had a similar issue to the OP so I thought I would share what I found. My scenario was different in that;



1) I had bought a brand new Sandisk 32GB USB Stick which I needed to use on a different unix distro later. The USB came pre-formatted as they usually do, with the FAT filesystem and some files for backup etc



2) I only have a Macbook Pro (MacOS 10.14.4) to hand, but I needed to format the stick to ext2 which is not as straight forward as you might like.



When plugging in my new USB stick, I was indeed met with the following;



Filesystem    512-blocks      Used Available Capacity iused               ifree %iused  Mounted on
/dev/disk1s1 489825072 422619568 51147752 90% 2408063 9223372036852367744 0% /
devfs 673 673 0 100% 1164 0 100% /dev
/dev/disk1s4 489825072 14680896 51147752 23% 7 9223372036854775800 0% /private/var/vm
map -hosts 0 0 0 100% 0 0 100% /net
map auto_home 0 0 0 100% 0 0 100% /home
map -fstab 0 0 0 100% 0 0 100% /Network/Servers
/dev/disk1s3 489825072 1021032 51147752 2% 30 9223372036854775777 0% /Volumes/Recovery
/dev/disk2s1 60033120 26976 60006144 1% 0 0 100% /Volumes/SANDISK32GB



Running e2fsprogs to format the USB stick resulted in the following;



sudo $(brew --prefix e2fsprogs)/sbin/mkfs.ext2 /dev/disk2

mke2fs 1.44.5 (15-Dec-2018)
/dev/disk2: Resource busy while setting up superblock


What I needed to do was unmount the FAT partition from the Mac so that I could format it in ext2 as required;



diskutil unmountdisk /dev/disk2s1


Then run the original e2fsprogs command to format the USB disk.



Notice the difference between the filesystem name and the mounted filesystem name



/dev/disk2s1 mounted vs /dev/disk2 device.






share|improve this answer








New contributor




Chris Gillatt is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.





















    Your Answer








    StackExchange.ready(function() {
    var channelOptions = {
    tags: "".split(" "),
    id: "3"
    };
    initTagRenderer("".split(" "), "".split(" "), channelOptions);

    StackExchange.using("externalEditor", function() {
    // Have to fire editor after snippets, if snippets enabled
    if (StackExchange.settings.snippets.snippetsEnabled) {
    StackExchange.using("snippets", function() {
    createEditor();
    });
    }
    else {
    createEditor();
    }
    });

    function createEditor() {
    StackExchange.prepareEditor({
    heartbeatType: 'answer',
    autoActivateHeartbeat: false,
    convertImagesToLinks: true,
    noModals: true,
    showLowRepImageUploadWarning: true,
    reputationToPostImages: 10,
    bindNavPrevention: true,
    postfix: "",
    imageUploader: {
    brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
    contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
    allowUrls: true
    },
    onDemand: true,
    discardSelector: ".discard-answer"
    ,immediatelyShowMarkdownHelp:true
    });


    }
    });














    draft saved

    draft discarded


















    StackExchange.ready(
    function () {
    StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fsuperuser.com%2fquestions%2f906513%2fget-rid-of-resource-busy-message-on-mac-os-x%23new-answer', 'question_page');
    }
    );

    Post as a guest















    Required, but never shown

























    3 Answers
    3






    active

    oldest

    votes








    3 Answers
    3






    active

    oldest

    votes









    active

    oldest

    votes






    active

    oldest

    votes









    4














    First off, the pdisk command is used to modify drives that are partitioned using an Apple Partition Map. Only PowerPC-based Macs use those.



    Secondly, your umount commands above are failing because /dev/disk1 and /dev/disk2 are not mounted. Typically only partitions are mounted (e.g. /dev/disk0s3), although in your case, you have a Fusion Drive. You are absolutely correct that /dev/disk3 is not a 'real' disk. It is the combined capacity of /dev/disk1s2 and /dev/disk2s2. If you type umount /dev/disk3, that should work. Of course, nothing is mounted on /dev/disk1 or /dev/disk2, so you will have to issue a diskutil unmountdisk /dev/diskN for those. That should free them up so the gpt command will stop giving you the resource busy error.



    Fusion Drives use Apple CoreStorage partitions as containers, which is sort of analogous to Microsoft's Dynamic Disks. Unfortunately, they make manipulating the partitions more difficult, and take many disk/partition recovery products off the table.



    However, aside from the issues above, I'm not exactly sure what the problem is. You mention that the partition table is lost, but the output from diskutil list suggests your partition tables seem to be OK.



    Can you elaborate a little more about the problem you were having?






    share|improve this answer


























    • I just updated the question. I'm assuming gpt would be the correct tool to use in place of pdisk?

      – Jojodmo
      Apr 30 '15 at 2:54











    • Correct. I updated my answer to reflect the additional info you posted.

      – Wes Sayeed
      May 1 '15 at 6:30











    • You can forget about the lost partition, the important thing is why I'm getting this message

      – Jojodmo
      May 2 '15 at 18:07
















    4














    First off, the pdisk command is used to modify drives that are partitioned using an Apple Partition Map. Only PowerPC-based Macs use those.



    Secondly, your umount commands above are failing because /dev/disk1 and /dev/disk2 are not mounted. Typically only partitions are mounted (e.g. /dev/disk0s3), although in your case, you have a Fusion Drive. You are absolutely correct that /dev/disk3 is not a 'real' disk. It is the combined capacity of /dev/disk1s2 and /dev/disk2s2. If you type umount /dev/disk3, that should work. Of course, nothing is mounted on /dev/disk1 or /dev/disk2, so you will have to issue a diskutil unmountdisk /dev/diskN for those. That should free them up so the gpt command will stop giving you the resource busy error.



    Fusion Drives use Apple CoreStorage partitions as containers, which is sort of analogous to Microsoft's Dynamic Disks. Unfortunately, they make manipulating the partitions more difficult, and take many disk/partition recovery products off the table.



    However, aside from the issues above, I'm not exactly sure what the problem is. You mention that the partition table is lost, but the output from diskutil list suggests your partition tables seem to be OK.



    Can you elaborate a little more about the problem you were having?






    share|improve this answer


























    • I just updated the question. I'm assuming gpt would be the correct tool to use in place of pdisk?

      – Jojodmo
      Apr 30 '15 at 2:54











    • Correct. I updated my answer to reflect the additional info you posted.

      – Wes Sayeed
      May 1 '15 at 6:30











    • You can forget about the lost partition, the important thing is why I'm getting this message

      – Jojodmo
      May 2 '15 at 18:07














    4












    4








    4







    First off, the pdisk command is used to modify drives that are partitioned using an Apple Partition Map. Only PowerPC-based Macs use those.



    Secondly, your umount commands above are failing because /dev/disk1 and /dev/disk2 are not mounted. Typically only partitions are mounted (e.g. /dev/disk0s3), although in your case, you have a Fusion Drive. You are absolutely correct that /dev/disk3 is not a 'real' disk. It is the combined capacity of /dev/disk1s2 and /dev/disk2s2. If you type umount /dev/disk3, that should work. Of course, nothing is mounted on /dev/disk1 or /dev/disk2, so you will have to issue a diskutil unmountdisk /dev/diskN for those. That should free them up so the gpt command will stop giving you the resource busy error.



    Fusion Drives use Apple CoreStorage partitions as containers, which is sort of analogous to Microsoft's Dynamic Disks. Unfortunately, they make manipulating the partitions more difficult, and take many disk/partition recovery products off the table.



    However, aside from the issues above, I'm not exactly sure what the problem is. You mention that the partition table is lost, but the output from diskutil list suggests your partition tables seem to be OK.



    Can you elaborate a little more about the problem you were having?






    share|improve this answer















    First off, the pdisk command is used to modify drives that are partitioned using an Apple Partition Map. Only PowerPC-based Macs use those.



    Secondly, your umount commands above are failing because /dev/disk1 and /dev/disk2 are not mounted. Typically only partitions are mounted (e.g. /dev/disk0s3), although in your case, you have a Fusion Drive. You are absolutely correct that /dev/disk3 is not a 'real' disk. It is the combined capacity of /dev/disk1s2 and /dev/disk2s2. If you type umount /dev/disk3, that should work. Of course, nothing is mounted on /dev/disk1 or /dev/disk2, so you will have to issue a diskutil unmountdisk /dev/diskN for those. That should free them up so the gpt command will stop giving you the resource busy error.



    Fusion Drives use Apple CoreStorage partitions as containers, which is sort of analogous to Microsoft's Dynamic Disks. Unfortunately, they make manipulating the partitions more difficult, and take many disk/partition recovery products off the table.



    However, aside from the issues above, I'm not exactly sure what the problem is. You mention that the partition table is lost, but the output from diskutil list suggests your partition tables seem to be OK.



    Can you elaborate a little more about the problem you were having?







    share|improve this answer














    share|improve this answer



    share|improve this answer








    edited May 1 '15 at 6:29

























    answered Apr 29 '15 at 19:10









    Wes SayeedWes Sayeed

    10.9k42758




    10.9k42758













    • I just updated the question. I'm assuming gpt would be the correct tool to use in place of pdisk?

      – Jojodmo
      Apr 30 '15 at 2:54











    • Correct. I updated my answer to reflect the additional info you posted.

      – Wes Sayeed
      May 1 '15 at 6:30











    • You can forget about the lost partition, the important thing is why I'm getting this message

      – Jojodmo
      May 2 '15 at 18:07



















    • I just updated the question. I'm assuming gpt would be the correct tool to use in place of pdisk?

      – Jojodmo
      Apr 30 '15 at 2:54











    • Correct. I updated my answer to reflect the additional info you posted.

      – Wes Sayeed
      May 1 '15 at 6:30











    • You can forget about the lost partition, the important thing is why I'm getting this message

      – Jojodmo
      May 2 '15 at 18:07

















    I just updated the question. I'm assuming gpt would be the correct tool to use in place of pdisk?

    – Jojodmo
    Apr 30 '15 at 2:54





    I just updated the question. I'm assuming gpt would be the correct tool to use in place of pdisk?

    – Jojodmo
    Apr 30 '15 at 2:54













    Correct. I updated my answer to reflect the additional info you posted.

    – Wes Sayeed
    May 1 '15 at 6:30





    Correct. I updated my answer to reflect the additional info you posted.

    – Wes Sayeed
    May 1 '15 at 6:30













    You can forget about the lost partition, the important thing is why I'm getting this message

    – Jojodmo
    May 2 '15 at 18:07





    You can forget about the lost partition, the important thing is why I'm getting this message

    – Jojodmo
    May 2 '15 at 18:07













    1














    try this:
    diskutil unmountDisk force /dev/disk0 (or whatever your disk is)






    share|improve this answer
























    • This doesn't work.

      – adib
      Jan 5 '18 at 12:35











    • @adib I just so happened to run in a similar problem (kept getting "Resource Busy" even though lsof showed nothing) and diskutil unmountDisk force /dev/disk<#> did work for me! 👍

      – RocketNuts
      Mar 27 at 15:51
















    1














    try this:
    diskutil unmountDisk force /dev/disk0 (or whatever your disk is)






    share|improve this answer
























    • This doesn't work.

      – adib
      Jan 5 '18 at 12:35











    • @adib I just so happened to run in a similar problem (kept getting "Resource Busy" even though lsof showed nothing) and diskutil unmountDisk force /dev/disk<#> did work for me! 👍

      – RocketNuts
      Mar 27 at 15:51














    1












    1








    1







    try this:
    diskutil unmountDisk force /dev/disk0 (or whatever your disk is)






    share|improve this answer













    try this:
    diskutil unmountDisk force /dev/disk0 (or whatever your disk is)







    share|improve this answer












    share|improve this answer



    share|improve this answer










    answered Sep 23 '17 at 15:15









    user774082user774082

    211




    211













    • This doesn't work.

      – adib
      Jan 5 '18 at 12:35











    • @adib I just so happened to run in a similar problem (kept getting "Resource Busy" even though lsof showed nothing) and diskutil unmountDisk force /dev/disk<#> did work for me! 👍

      – RocketNuts
      Mar 27 at 15:51



















    • This doesn't work.

      – adib
      Jan 5 '18 at 12:35











    • @adib I just so happened to run in a similar problem (kept getting "Resource Busy" even though lsof showed nothing) and diskutil unmountDisk force /dev/disk<#> did work for me! 👍

      – RocketNuts
      Mar 27 at 15:51

















    This doesn't work.

    – adib
    Jan 5 '18 at 12:35





    This doesn't work.

    – adib
    Jan 5 '18 at 12:35













    @adib I just so happened to run in a similar problem (kept getting "Resource Busy" even though lsof showed nothing) and diskutil unmountDisk force /dev/disk<#> did work for me! 👍

    – RocketNuts
    Mar 27 at 15:51





    @adib I just so happened to run in a similar problem (kept getting "Resource Busy" even though lsof showed nothing) and diskutil unmountDisk force /dev/disk<#> did work for me! 👍

    – RocketNuts
    Mar 27 at 15:51











    0














    I had a similar issue to the OP so I thought I would share what I found. My scenario was different in that;



    1) I had bought a brand new Sandisk 32GB USB Stick which I needed to use on a different unix distro later. The USB came pre-formatted as they usually do, with the FAT filesystem and some files for backup etc



    2) I only have a Macbook Pro (MacOS 10.14.4) to hand, but I needed to format the stick to ext2 which is not as straight forward as you might like.



    When plugging in my new USB stick, I was indeed met with the following;



    Filesystem    512-blocks      Used Available Capacity iused               ifree %iused  Mounted on
    /dev/disk1s1 489825072 422619568 51147752 90% 2408063 9223372036852367744 0% /
    devfs 673 673 0 100% 1164 0 100% /dev
    /dev/disk1s4 489825072 14680896 51147752 23% 7 9223372036854775800 0% /private/var/vm
    map -hosts 0 0 0 100% 0 0 100% /net
    map auto_home 0 0 0 100% 0 0 100% /home
    map -fstab 0 0 0 100% 0 0 100% /Network/Servers
    /dev/disk1s3 489825072 1021032 51147752 2% 30 9223372036854775777 0% /Volumes/Recovery
    /dev/disk2s1 60033120 26976 60006144 1% 0 0 100% /Volumes/SANDISK32GB



    Running e2fsprogs to format the USB stick resulted in the following;



    sudo $(brew --prefix e2fsprogs)/sbin/mkfs.ext2 /dev/disk2

    mke2fs 1.44.5 (15-Dec-2018)
    /dev/disk2: Resource busy while setting up superblock


    What I needed to do was unmount the FAT partition from the Mac so that I could format it in ext2 as required;



    diskutil unmountdisk /dev/disk2s1


    Then run the original e2fsprogs command to format the USB disk.



    Notice the difference between the filesystem name and the mounted filesystem name



    /dev/disk2s1 mounted vs /dev/disk2 device.






    share|improve this answer








    New contributor




    Chris Gillatt is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
    Check out our Code of Conduct.

























      0














      I had a similar issue to the OP so I thought I would share what I found. My scenario was different in that;



      1) I had bought a brand new Sandisk 32GB USB Stick which I needed to use on a different unix distro later. The USB came pre-formatted as they usually do, with the FAT filesystem and some files for backup etc



      2) I only have a Macbook Pro (MacOS 10.14.4) to hand, but I needed to format the stick to ext2 which is not as straight forward as you might like.



      When plugging in my new USB stick, I was indeed met with the following;



      Filesystem    512-blocks      Used Available Capacity iused               ifree %iused  Mounted on
      /dev/disk1s1 489825072 422619568 51147752 90% 2408063 9223372036852367744 0% /
      devfs 673 673 0 100% 1164 0 100% /dev
      /dev/disk1s4 489825072 14680896 51147752 23% 7 9223372036854775800 0% /private/var/vm
      map -hosts 0 0 0 100% 0 0 100% /net
      map auto_home 0 0 0 100% 0 0 100% /home
      map -fstab 0 0 0 100% 0 0 100% /Network/Servers
      /dev/disk1s3 489825072 1021032 51147752 2% 30 9223372036854775777 0% /Volumes/Recovery
      /dev/disk2s1 60033120 26976 60006144 1% 0 0 100% /Volumes/SANDISK32GB



      Running e2fsprogs to format the USB stick resulted in the following;



      sudo $(brew --prefix e2fsprogs)/sbin/mkfs.ext2 /dev/disk2

      mke2fs 1.44.5 (15-Dec-2018)
      /dev/disk2: Resource busy while setting up superblock


      What I needed to do was unmount the FAT partition from the Mac so that I could format it in ext2 as required;



      diskutil unmountdisk /dev/disk2s1


      Then run the original e2fsprogs command to format the USB disk.



      Notice the difference between the filesystem name and the mounted filesystem name



      /dev/disk2s1 mounted vs /dev/disk2 device.






      share|improve this answer








      New contributor




      Chris Gillatt is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
      Check out our Code of Conduct.























        0












        0








        0







        I had a similar issue to the OP so I thought I would share what I found. My scenario was different in that;



        1) I had bought a brand new Sandisk 32GB USB Stick which I needed to use on a different unix distro later. The USB came pre-formatted as they usually do, with the FAT filesystem and some files for backup etc



        2) I only have a Macbook Pro (MacOS 10.14.4) to hand, but I needed to format the stick to ext2 which is not as straight forward as you might like.



        When plugging in my new USB stick, I was indeed met with the following;



        Filesystem    512-blocks      Used Available Capacity iused               ifree %iused  Mounted on
        /dev/disk1s1 489825072 422619568 51147752 90% 2408063 9223372036852367744 0% /
        devfs 673 673 0 100% 1164 0 100% /dev
        /dev/disk1s4 489825072 14680896 51147752 23% 7 9223372036854775800 0% /private/var/vm
        map -hosts 0 0 0 100% 0 0 100% /net
        map auto_home 0 0 0 100% 0 0 100% /home
        map -fstab 0 0 0 100% 0 0 100% /Network/Servers
        /dev/disk1s3 489825072 1021032 51147752 2% 30 9223372036854775777 0% /Volumes/Recovery
        /dev/disk2s1 60033120 26976 60006144 1% 0 0 100% /Volumes/SANDISK32GB



        Running e2fsprogs to format the USB stick resulted in the following;



        sudo $(brew --prefix e2fsprogs)/sbin/mkfs.ext2 /dev/disk2

        mke2fs 1.44.5 (15-Dec-2018)
        /dev/disk2: Resource busy while setting up superblock


        What I needed to do was unmount the FAT partition from the Mac so that I could format it in ext2 as required;



        diskutil unmountdisk /dev/disk2s1


        Then run the original e2fsprogs command to format the USB disk.



        Notice the difference between the filesystem name and the mounted filesystem name



        /dev/disk2s1 mounted vs /dev/disk2 device.






        share|improve this answer








        New contributor




        Chris Gillatt is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
        Check out our Code of Conduct.










        I had a similar issue to the OP so I thought I would share what I found. My scenario was different in that;



        1) I had bought a brand new Sandisk 32GB USB Stick which I needed to use on a different unix distro later. The USB came pre-formatted as they usually do, with the FAT filesystem and some files for backup etc



        2) I only have a Macbook Pro (MacOS 10.14.4) to hand, but I needed to format the stick to ext2 which is not as straight forward as you might like.



        When plugging in my new USB stick, I was indeed met with the following;



        Filesystem    512-blocks      Used Available Capacity iused               ifree %iused  Mounted on
        /dev/disk1s1 489825072 422619568 51147752 90% 2408063 9223372036852367744 0% /
        devfs 673 673 0 100% 1164 0 100% /dev
        /dev/disk1s4 489825072 14680896 51147752 23% 7 9223372036854775800 0% /private/var/vm
        map -hosts 0 0 0 100% 0 0 100% /net
        map auto_home 0 0 0 100% 0 0 100% /home
        map -fstab 0 0 0 100% 0 0 100% /Network/Servers
        /dev/disk1s3 489825072 1021032 51147752 2% 30 9223372036854775777 0% /Volumes/Recovery
        /dev/disk2s1 60033120 26976 60006144 1% 0 0 100% /Volumes/SANDISK32GB



        Running e2fsprogs to format the USB stick resulted in the following;



        sudo $(brew --prefix e2fsprogs)/sbin/mkfs.ext2 /dev/disk2

        mke2fs 1.44.5 (15-Dec-2018)
        /dev/disk2: Resource busy while setting up superblock


        What I needed to do was unmount the FAT partition from the Mac so that I could format it in ext2 as required;



        diskutil unmountdisk /dev/disk2s1


        Then run the original e2fsprogs command to format the USB disk.



        Notice the difference between the filesystem name and the mounted filesystem name



        /dev/disk2s1 mounted vs /dev/disk2 device.







        share|improve this answer








        New contributor




        Chris Gillatt is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
        Check out our Code of Conduct.









        share|improve this answer



        share|improve this answer






        New contributor




        Chris Gillatt is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
        Check out our Code of Conduct.









        answered yesterday









        Chris GillattChris Gillatt

        11




        11




        New contributor




        Chris Gillatt is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
        Check out our Code of Conduct.





        New contributor





        Chris Gillatt is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
        Check out our Code of Conduct.






        Chris Gillatt is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
        Check out our Code of Conduct.






























            draft saved

            draft discarded




















































            Thanks for contributing an answer to Super User!


            • Please be sure to answer the question. Provide details and share your research!

            But avoid



            • Asking for help, clarification, or responding to other answers.

            • Making statements based on opinion; back them up with references or personal experience.


            To learn more, see our tips on writing great answers.




            draft saved


            draft discarded














            StackExchange.ready(
            function () {
            StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fsuperuser.com%2fquestions%2f906513%2fget-rid-of-resource-busy-message-on-mac-os-x%23new-answer', 'question_page');
            }
            );

            Post as a guest















            Required, but never shown





















































            Required, but never shown














            Required, but never shown












            Required, but never shown







            Required, but never shown

































            Required, but never shown














            Required, but never shown












            Required, but never shown







            Required, but never shown







            Popular posts from this blog

            Couldn't open a raw socket. Error: Permission denied (13) (nmap)Is it possible to run networking commands...

            VNC viewer RFB protocol error: bad desktop size 0x0I Cannot Type the Key 'd' (lowercase) in VNC Viewer...

            Why not use the yoke to control yaw, as well as pitch and roll? Announcing the arrival of...