• External SSD woes

    From John Hill@21:1/5 to All on Wed Jun 12 09:08:17 2024
    I seem to have wrecked an external Sandisk SSD drive experimenting with File Vault, at least so far as my iMac is concerned. It seems to sort of mount but cannot be ejected. Nor can Disk Utility do anything with it - it just locks
    up. And I cannot eject it.

    It is formatted APFS, so AIUI Disk Warrior cannot handle it.

    Is there any app that might possibly rescue it, or is it likely to be effectively a brick? Obviously any rescue would have to cost less than the value of the drive!

    I have no need to rescue any of the content, just to erase and reformat the drive.

    Old John.

    --
    An infinitely complex system can fail in an infinite number of ways.

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From David Brooks@21:1/5 to John Hill on Wed Jun 12 10:24:24 2024
    On 12/06/2024 10:08, John Hill wrote:
    I seem to have wrecked an external Sandisk SSD drive experimenting with File
    Vault, at least so far as my iMac is concerned. It seems to sort of mount but cannot be ejected. Nor can Disk Utility do anything with it - it just locks up. And I cannot eject it.

    It is formatted APFS, so AIUI Disk Warrior cannot handle it.

    Is there any app that might possibly rescue it, or is it likely to be effectively a brick? Obviously any rescue would have to cost less than the value of the drive!

    I have no need to rescue any of the content, just to erase and reformat the drive.


    Hello Old John 🙂

    You could try this product:- https://en.wikipedia.org/wiki/Disk_Drill

    (I have bought and paid for a licence in days gone by. It *works*!)

    Product website here:- https://www.cleverfiles.com/

    Kind regards,

    David

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Alan B@21:1/5 to John Hill on Wed Jun 12 09:21:31 2024
    On 2024-06-12, John Hill <watcombeman@yahoo.co.uk> wrote:
    I seem to have wrecked an external Sandisk SSD drive experimenting with File Vault, at least so far as my iMac is concerned. It seems to sort of mount but cannot be ejected. Nor can Disk Utility do anything with it - it just locks up. And I cannot eject it.

    It is formatted APFS, so AIUI Disk Warrior cannot handle it.

    Is there any app that might possibly rescue it, or is it likely to be effectively a brick? Obviously any rescue would have to cost less than the value of the drive!

    I have no need to rescue any of the content, just to erase and reformat the drive.

    I've occasionally had problems with DU being unable to erase drives. I've found that using the command line sometimes, but only sometimes, works.

    Assuming the drive mounts OK, use 'diskutil list' to get its drive number. Then use 'sudo diskutil eraseDisk APFS Untitled diskn' to erase it, where 'Untitled' is the
    volume name which you can set as you wish of course. Replace 'n' with the number
    shown in the 'diskutil list' command. Be very, very careful to get the value of 'n'
    correct or you could have a disaster!

    --
    Cheers, Alan

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Jaimie Vandenbergh@21:1/5 to All on Wed Jun 12 11:14:42 2024
    On 12 Jun 2024 at 10:08:17 BST, "John Hill" <watcombeman@yahoo.co.uk>
    wrote:

    I seem to have wrecked an external Sandisk SSD drive experimenting with File Vault, at least so far as my iMac is concerned. It seems to sort of mount but cannot be ejected. Nor can Disk Utility do anything with it - it just locks up. And I cannot eject it.

    It is formatted APFS, so AIUI Disk Warrior cannot handle it.

    Is there any app that might possibly rescue it, or is it likely to be effectively a brick? Obviously any rescue would have to cost less than the value of the drive!

    I have no need to rescue any of the content, just to erase and reformat the drive.

    Wanging it into a PC (Windows or Linux) and doing it there, in an OS
    that doesn't comprehend Apple filesystems at all and won't get all
    wedged up trying to mount them, would be an easy way - if you have
    access to one.

    Cheers - Jaimie
    --
    'It's one of those irregular verbs, isn't it? `I protect the
    lives and property of my citizens; you keep the public
    safe from an unreasonable and trouble-generating
    minority; he maintains a totalitarian regime of
    thought control.' -- Bernard, Yes Minister

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Alan B@21:1/5 to Alan B on Wed Jun 12 12:07:46 2024
    On 2024-06-12, Alan B <alanrichardbarker@gmail.com.invalid> wrote:
    On 2024-06-12, Jaimie Vandenbergh <jaimie@usually.sessile.org> wrote:
    On 12 Jun 2024 at 10:08:17 BST, "John Hill" <watcombeman@yahoo.co.uk>
    wrote:

    I seem to have wrecked an external Sandisk SSD drive experimenting with File
    Vault, at least so far as my iMac is concerned. It seems to sort of mount but
    cannot be ejected. Nor can Disk Utility do anything with it - it just locks >>> up. And I cannot eject it.

    It is formatted APFS, so AIUI Disk Warrior cannot handle it.

    Is there any app that might possibly rescue it, or is it likely to be
    effectively a brick? Obviously any rescue would have to cost less than the >>> value of the drive!

    I have no need to rescue any of the content, just to erase and reformat the >>> drive.

    Wanging it into a PC (Windows or Linux) and doing it there, in an OS
    that doesn't comprehend Apple filesystems at all and won't get all
    wedged up trying to mount them, would be an easy way - if you have
    access to one.

    Yep saves messing with the CLI as per my OTT suggestion! Would that work with a Window$ or Linux VM running on a Mac?

    To partially answer my question, I can certainly erase/reformat APFS
    formatted USB sticks with gparted running in a Ubuntu VM via Parallels.

    --
    Cheers, Alan

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Alan B@21:1/5 to Jaimie Vandenbergh on Wed Jun 12 11:26:11 2024
    On 2024-06-12, Jaimie Vandenbergh <jaimie@usually.sessile.org> wrote:
    On 12 Jun 2024 at 10:08:17 BST, "John Hill" <watcombeman@yahoo.co.uk>
    wrote:

    I seem to have wrecked an external Sandisk SSD drive experimenting with File
    Vault, at least so far as my iMac is concerned. It seems to sort of mount but
    cannot be ejected. Nor can Disk Utility do anything with it - it just locks >> up. And I cannot eject it.

    It is formatted APFS, so AIUI Disk Warrior cannot handle it.

    Is there any app that might possibly rescue it, or is it likely to be
    effectively a brick? Obviously any rescue would have to cost less than the >> value of the drive!

    I have no need to rescue any of the content, just to erase and reformat the >> drive.

    Wanging it into a PC (Windows or Linux) and doing it there, in an OS
    that doesn't comprehend Apple filesystems at all and won't get all
    wedged up trying to mount them, would be an easy way - if you have
    access to one.

    Yep saves messing with the CLI as per my OTT suggestion! Would that work with a Window$ or Linux VM running on a Mac?

    --
    Cheers, Alan

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Theo@21:1/5 to Alan B on Wed Jun 12 14:04:41 2024
    Alan B <alanrichardbarker@gmail.com.invalid> wrote:
    On 2024-06-12, John Hill <watcombeman@yahoo.co.uk> wrote:
    I seem to have wrecked an external Sandisk SSD drive experimenting with File
    Vault, at least so far as my iMac is concerned. It seems to sort of mount but
    cannot be ejected. Nor can Disk Utility do anything with it - it just locks up. And I cannot eject it.

    It is formatted APFS, so AIUI Disk Warrior cannot handle it.

    Is there any app that might possibly rescue it, or is it likely to be effectively a brick? Obviously any rescue would have to cost less than the value of the drive!

    I have no need to rescue any of the content, just to erase and reformat the drive.

    I've occasionally had problems with DU being unable to erase drives. I've found
    that using the command line sometimes, but only sometimes, works.

    Assuming the drive mounts OK, use 'diskutil list' to get its drive number. Then
    use 'sudo diskutil eraseDisk APFS Untitled diskn' to erase it, where 'Untitled' is the
    volume name which you can set as you wish of course. Replace 'n' with the number
    shown in the 'diskutil list' command. Be very, very careful to get the value of 'n'
    correct or you could have a disaster!

    A cruder approach is just to nuke everything on it, not even using diskutil.

    Run 'diskutil list' to get the drive number as above. eg 'disk2'.
    It will definitely not be disk0 (that's your internal SSD) and perhaps not disk1.

    Then run:
    sudo dd if=/dev/zero of=/dev/rdisk2 bs=104857600

    It'll take a long time (maybe hours) but you'll have a completely zeroed out device, no volumes, no APFS, no partitions, nothing. You can then try to
    set it up from scratch again.

    If you want a progress report while dd is running, press Ctrl-T in the
    terminal window.

    Theo

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Alan B@21:1/5 to Theo on Wed Jun 12 13:35:01 2024
    Theo <theom+news@chiark.greenend.org.uk> wrote:
    Alan B <alanrichardbarker@gmail.com.invalid> wrote:
    On 2024-06-12, John Hill <watcombeman@yahoo.co.uk> wrote:
    I seem to have wrecked an external Sandisk SSD drive experimenting with File
    Vault, at least so far as my iMac is concerned. It seems to sort of mount but
    cannot be ejected. Nor can Disk Utility do anything with it - it just locks >>> up. And I cannot eject it.

    It is formatted APFS, so AIUI Disk Warrior cannot handle it.

    Is there any app that might possibly rescue it, or is it likely to be
    effectively a brick? Obviously any rescue would have to cost less than the >>> value of the drive!

    I have no need to rescue any of the content, just to erase and reformat the >>> drive.

    I've occasionally had problems with DU being unable to erase drives. I've found
    that using the command line sometimes, but only sometimes, works.

    Assuming the drive mounts OK, use 'diskutil list' to get its drive number. Then
    use 'sudo diskutil eraseDisk APFS Untitled diskn' to erase it, where 'Untitled' is the
    volume name which you can set as you wish of course. Replace 'n' with the number
    shown in the 'diskutil list' command. Be very, very careful to get the value of 'n'
    correct or you could have a disaster!

    A cruder approach is just to nuke everything on it, not even using diskutil.

    Run 'diskutil list' to get the drive number as above. eg 'disk2'.
    It will definitely not be disk0 (that's your internal SSD) and perhaps not disk1.

    Then run:
    sudo dd if=/dev/zero of=/dev/rdisk2 bs=104857600

    It'll take a long time (maybe hours) but you'll have a completely zeroed out device, no volumes, no APFS, no partitions, nothing. You can then try to
    set it up from scratch again.

    If you want a progress report while dd is running, press Ctrl-T in the terminal window.

    Or add status=progress to the command maybe?

    --
    Cheers, Alan

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Theo@21:1/5 to Alan B on Wed Jun 12 14:49:55 2024
    Alan B <alanrichardbarker@gmail.com.invalid> wrote:
    Theo <theom+news@chiark.greenend.org.uk> wrote:
    If you want a progress report while dd is running, press Ctrl-T in the terminal window.

    Or add status=progress to the command maybe?

    That doesn't work on the MacOS 'dd':

    % dd if=/dev/zero of=/dev/null status=progress
    dd: unknown operand status

    It does work on Linux, and you can install the Linux dd via Homebrew, but most people don't have that.

    Ctrl-T sends SIGINFO which prints progress on any version of dd.

    Theo

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Bernd Froehlich@21:1/5 to All on Thu Jun 13 06:46:13 2024
    On 12. Jun 2024 at 11:08:17 CEST, "John Hill" <watcombeman@yahoo.co.uk>
    wrote:

    I seem to have wrecked an external Sandisk SSD drive experimenting with File Vault, at least so far as my iMac is concerned.

    Sandisk?
    Better throw it away:

    <https://arstechnica.com/gadgets/2023/08/sandisk-extreme-ssds-are-worthless-multiple-lawsuits-against-wd-say/>

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From John Hill@21:1/5 to All on Thu Jun 13 10:59:58 2024
    On 12 Jun 2024 at 14:04:41 BST, "Theo" <theom+news@chiark.greenend.org.uk> wrote:

    Alan B <alanrichardbarker@gmail.com.invalid> wrote:
    On 2024-06-12, John Hill <watcombeman@yahoo.co.uk> wrote:
    I seem to have wrecked an external Sandisk SSD drive experimenting with File
    Vault, at least so far as my iMac is concerned. It seems to sort of mount but
    cannot be ejected. Nor can Disk Utility do anything with it - it just locks >>> up. And I cannot eject it.

    It is formatted APFS, so AIUI Disk Warrior cannot handle it.

    Is there any app that might possibly rescue it, or is it likely to be
    effectively a brick? Obviously any rescue would have to cost less than the >>> value of the drive!

    I have no need to rescue any of the content, just to erase and reformat the >>> drive.

    I've occasionally had problems with DU being unable to erase drives. I've found
    that using the command line sometimes, but only sometimes, works.

    Assuming the drive mounts OK, use 'diskutil list' to get its drive number. Then
    use 'sudo diskutil eraseDisk APFS Untitled diskn' to erase it, where
    'Untitled' is the
    volume name which you can set as you wish of course. Replace 'n' with the
    number
    shown in the 'diskutil list' command. Be very, very careful to get the value >> of 'n'
    correct or you could have a disaster!

    A cruder approach is just to nuke everything on it, not even using diskutil.

    Run 'diskutil list' to get the drive number as above. eg 'disk2'.
    It will definitely not be disk0 (that's your internal SSD) and perhaps not disk1.

    Then run:
    sudo dd if=/dev/zero of=/dev/rdisk2 bs=104857600

    It'll take a long time (maybe hours) but you'll have a completely zeroed out device, no volumes, no APFS, no partitions, nothing. You can then try to
    set it up from scratch again.

    If you want a progress report while dd is running, press Ctrl-T in the terminal window.

    Theo

    I tried Alan B's suggestion and it ran OK. But…

    A bit of explanation.
    The disk was originally a 1TB drive, divided into two equal separate containers. OK, not a good idea in retrospect. But what's done, is done.
    One of these was used to hold a bootable system, generated by the system recovery mechanism, and on which the Data drive was kept up to date by Carbon Copy Cloner at regular intervals. The System drive was updated by booting from it and using Software Update. All perfectly standard.
    The other was partitioned into two by the approved Disk Utility method and
    each held a CCC copy of my data disk, updated on alternate weeks.

    Alan's technique produced a single volume - but it was only 500GB. It looks as though one of the two containers has been obliterated. So I thought that I would try Theo's method, to see if it would recover the whole space.

    But when I tried it, I got the response "dd: /dev/rdisk2: Resource busy".

    Is there a remedy for this? Or should I quit on the basis that half a drive is better than no drive?

    I must make it clear that I am totally ignorant as far as Terminal is
    concerned ☹️

    Old John.

    You're not an old dog until you can't learn new tricks.

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Alan B@21:1/5 to John Hill on Thu Jun 13 11:46:33 2024
    On 2024-06-13, John Hill <watcombeman@yahoo.co.uk> wrote:
    On 12 Jun 2024 at 14:04:41 BST, "Theo" <theom+news@chiark.greenend.org.uk> wrote:

    Alan B <alanrichardbarker@gmail.com.invalid> wrote:
    On 2024-06-12, John Hill <watcombeman@yahoo.co.uk> wrote:
    I seem to have wrecked an external Sandisk SSD drive experimenting with File
    Vault, at least so far as my iMac is concerned. It seems to sort of mount but
    cannot be ejected. Nor can Disk Utility do anything with it - it just locks
    up. And I cannot eject it.

    It is formatted APFS, so AIUI Disk Warrior cannot handle it.

    Is there any app that might possibly rescue it, or is it likely to be
    effectively a brick? Obviously any rescue would have to cost less than the >>>> value of the drive!

    I have no need to rescue any of the content, just to erase and reformat the
    drive.

    I've occasionally had problems with DU being unable to erase drives. I've found
    that using the command line sometimes, but only sometimes, works.

    Assuming the drive mounts OK, use 'diskutil list' to get its drive number. Then
    use 'sudo diskutil eraseDisk APFS Untitled diskn' to erase it, where
    'Untitled' is the
    volume name which you can set as you wish of course. Replace 'n' with the >>> number
    shown in the 'diskutil list' command. Be very, very careful to get the value
    of 'n'
    correct or you could have a disaster!

    A cruder approach is just to nuke everything on it, not even using diskutil. >>
    Run 'diskutil list' to get the drive number as above. eg 'disk2'.
    It will definitely not be disk0 (that's your internal SSD) and perhaps not >> disk1.

    Then run:
    sudo dd if=/dev/zero of=/dev/rdisk2 bs=104857600

    It'll take a long time (maybe hours) but you'll have a completely zeroed out >> device, no volumes, no APFS, no partitions, nothing. You can then try to
    set it up from scratch again.

    If you want a progress report while dd is running, press Ctrl-T in the
    terminal window.

    Theo

    I tried Alan B's suggestion and it ran OK. But…

    A bit of explanation.
    The disk was originally a 1TB drive, divided into two equal separate containers. OK, not a good idea in retrospect. But what's done, is done.
    One of these was used to hold a bootable system, generated by the system recovery mechanism, and on which the Data drive was kept up to date by Carbon Copy Cloner at regular intervals. The System drive was updated by booting from
    it and using Software Update. All perfectly standard.
    The other was partitioned into two by the approved Disk Utility method and each held a CCC copy of my data disk, updated on alternate weeks.

    Alan's technique produced a single volume - but it was only 500GB. It looks as
    though one of the two containers has been obliterated. So I thought that I would try Theo's method, to see if it would recover the whole space.

    But when I tried it, I got the response "dd: /dev/rdisk2: Resource busy".

    It needs to be unmounted -> 'diskutil unmountDisk disk2' ought to do that, then retry Theo's command.

    It might be useful to see the output of the 'diskutil list' command with the drive inserted and hence mounted before you try again.

    --
    Cheers, Alan

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Alan B@21:1/5 to John Hill on Fri Jun 14 07:13:02 2024
    John Hill <watcombeman@yahoo.co.uk> wrote:
    On 13 Jun 2024 at 12:46:33 BST, "Alan B" <alanrichardbarker@gmail.com.invalid>
    wrote:

    On 2024-06-13, John Hill <watcombeman@yahoo.co.uk> wrote:
    On 12 Jun 2024 at 14:04:41 BST, "Theo" <theom+news@chiark.greenend.org.uk> >>> wrote:

    Alan B <alanrichardbarker@gmail.com.invalid> wrote:
    On 2024-06-12, John Hill <watcombeman@yahoo.co.uk> wrote:
    I seem to have wrecked an external Sandisk SSD drive experimenting with File
    Vault, at least so far as my iMac is concerned. It seems to sort of mount but
    cannot be ejected. Nor can Disk Utility do anything with it - it just locks
    up. And I cannot eject it.

    It is formatted APFS, so AIUI Disk Warrior cannot handle it.

    Is there any app that might possibly rescue it, or is it likely to be >>>>>> effectively a brick? Obviously any rescue would have to cost less than the
    value of the drive!

    I have no need to rescue any of the content, just to erase and reformat the
    drive.

    I've occasionally had problems with DU being unable to erase drives. I've found
    that using the command line sometimes, but only sometimes, works.

    Assuming the drive mounts OK, use 'diskutil list' to get its drive number. Then
    use 'sudo diskutil eraseDisk APFS Untitled diskn' to erase it, where >>>>> 'Untitled' is the
    volume name which you can set as you wish of course. Replace 'n' with the >>>>> number
    shown in the 'diskutil list' command. Be very, very careful to get the value
    of 'n'
    correct or you could have a disaster!

    A cruder approach is just to nuke everything on it, not even using diskutil.

    Run 'diskutil list' to get the drive number as above. eg 'disk2'.
    It will definitely not be disk0 (that's your internal SSD) and perhaps not >>>> disk1.

    Then run:
    sudo dd if=/dev/zero of=/dev/rdisk2 bs=104857600

    It'll take a long time (maybe hours) but you'll have a completely zeroed out
    device, no volumes, no APFS, no partitions, nothing. You can then try to >>>> set it up from scratch again.

    If you want a progress report while dd is running, press Ctrl-T in the >>>> terminal window.

    Theo

    I tried Alan B's suggestion and it ran OK. But…

    A bit of explanation.
    The disk was originally a 1TB drive, divided into two equal separate
    containers. OK, not a good idea in retrospect. But what's done, is done. >>> One of these was used to hold a bootable system, generated by the system >>> recovery mechanism, and on which the Data drive was kept up to date by Carbon
    Copy Cloner at regular intervals. The System drive was updated by booting from
    it and using Software Update. All perfectly standard.
    The other was partitioned into two by the approved Disk Utility method and >>> each held a CCC copy of my data disk, updated on alternate weeks.

    Alan's technique produced a single volume - but it was only 500GB. It looks as
    though one of the two containers has been obliterated. So I thought that I >>> would try Theo's method, to see if it would recover the whole space.

    But when I tried it, I got the response "dd: /dev/rdisk2: Resource busy". >>
    It needs to be unmounted -> 'diskutil unmountDisk disk2' ought to do that, then
    retry Theo's command.

    It might be useful to see the output of the 'diskutil list' command with the >> drive inserted and hence mounted before you try again.

    I get

    Last login: Fri Jun 14 07:33:24 on ttys000
    johnhill@Johns-iMac ~ % diskutil list
    /dev/disk0 (internal, physical):
    #: TYPE NAME SIZE IDENTIFIER
    0: GUID_partition_scheme *500.3 GB disk0
    1: EFI EFI 314.6 MB disk0s1
    2: Apple_APFS Container disk1 500.0 GB disk0s2

    /dev/disk1 (synthesized):
    #: TYPE NAME SIZE IDENTIFIER
    0: APFS Container Scheme - +500.0 GB disk1
    Physical Store disk0s2
    1: APFS Volume Big Sur - Data 451.7 GB disk1s1
    2: APFS Volume Preboot 2.1 GB disk1s2
    3: APFS Volume Recovery 1.2 GB disk1s3
    4: APFS Volume VM 3.2 GB disk1s4
    5: APFS Volume John's HD 9.3 GB disk1s5
    6: APFS Snapshot com.apple.os.update-... 9.3 GB disk1s5s1

    /dev/disk2 (external, physical):
    #: TYPE NAME SIZE IDENTIFIER
    0: GUID_partition_scheme *500.1 GB disk2
    1: EFI EFI 209.7 MB disk2s1
    2: Apple_APFS Container disk3 499.9 GB disk2s2

    /dev/disk3 (synthesized):
    #: TYPE NAME SIZE IDENTIFIER
    0: APFS Container Scheme - +499.9 GB disk3
    Physical Store disk2s2
    1: APFS Volume Untitled 1.2 MB disk3s1

    johnhill@Johns-iMac ~ %


    So it clearly is disk2

    So I reckon the following terminal 2 commands should zap the SSD:

    1) diskutil unmountDisk disk2

    Followed by Theo’s suggestion:

    2) sudo dd if=/dev/zero of=/dev/rdisk2 bs=104857600

    You should then be able to reformat the SSD using the Disk Utility
    application.

    I tried this out with a 64GB USB3 memory stick and it seemed to work OK.
    Sure it takes a long time but maybe you can cancel the dd command after a
    short while unless you want to completely zeroise the SSD?

    --
    Cheers, Alan

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From John Hill@21:1/5 to All on Fri Jun 14 06:49:55 2024
    On 13 Jun 2024 at 12:46:33 BST, "Alan B" <alanrichardbarker@gmail.com.invalid> wrote:

    On 2024-06-13, John Hill <watcombeman@yahoo.co.uk> wrote:
    On 12 Jun 2024 at 14:04:41 BST, "Theo" <theom+news@chiark.greenend.org.uk> >> wrote:

    Alan B <alanrichardbarker@gmail.com.invalid> wrote:
    On 2024-06-12, John Hill <watcombeman@yahoo.co.uk> wrote:
    I seem to have wrecked an external Sandisk SSD drive experimenting with File
    Vault, at least so far as my iMac is concerned. It seems to sort of mount but
    cannot be ejected. Nor can Disk Utility do anything with it - it just locks
    up. And I cannot eject it.

    It is formatted APFS, so AIUI Disk Warrior cannot handle it.

    Is there any app that might possibly rescue it, or is it likely to be >>>>> effectively a brick? Obviously any rescue would have to cost less than the
    value of the drive!

    I have no need to rescue any of the content, just to erase and reformat the
    drive.

    I've occasionally had problems with DU being unable to erase drives. I've found
    that using the command line sometimes, but only sometimes, works.

    Assuming the drive mounts OK, use 'diskutil list' to get its drive number. Then
    use 'sudo diskutil eraseDisk APFS Untitled diskn' to erase it, where
    'Untitled' is the
    volume name which you can set as you wish of course. Replace 'n' with the >>>> number
    shown in the 'diskutil list' command. Be very, very careful to get the value
    of 'n'
    correct or you could have a disaster!

    A cruder approach is just to nuke everything on it, not even using diskutil.

    Run 'diskutil list' to get the drive number as above. eg 'disk2'.
    It will definitely not be disk0 (that's your internal SSD) and perhaps not >>> disk1.

    Then run:
    sudo dd if=/dev/zero of=/dev/rdisk2 bs=104857600

    It'll take a long time (maybe hours) but you'll have a completely zeroed out
    device, no volumes, no APFS, no partitions, nothing. You can then try to >>> set it up from scratch again.

    If you want a progress report while dd is running, press Ctrl-T in the
    terminal window.

    Theo

    I tried Alan B's suggestion and it ran OK. But…

    A bit of explanation.
    The disk was originally a 1TB drive, divided into two equal separate
    containers. OK, not a good idea in retrospect. But what's done, is done.
    One of these was used to hold a bootable system, generated by the system
    recovery mechanism, and on which the Data drive was kept up to date by Carbon
    Copy Cloner at regular intervals. The System drive was updated by booting from
    it and using Software Update. All perfectly standard.
    The other was partitioned into two by the approved Disk Utility method and >> each held a CCC copy of my data disk, updated on alternate weeks.

    Alan's technique produced a single volume - but it was only 500GB. It looks as
    though one of the two containers has been obliterated. So I thought that I >> would try Theo's method, to see if it would recover the whole space.

    But when I tried it, I got the response "dd: /dev/rdisk2: Resource busy".

    It needs to be unmounted -> 'diskutil unmountDisk disk2' ought to do that, then
    retry Theo's command.

    It might be useful to see the output of the 'diskutil list' command with the drive inserted and hence mounted before you try again.

    I get

    Last login: Fri Jun 14 07:33:24 on ttys000
    johnhill@Johns-iMac ~ % diskutil list
    /dev/disk0 (internal, physical):
    #: TYPE NAME SIZE IDENTIFIER
    0: GUID_partition_scheme *500.3 GB disk0
    1: EFI EFI 314.6 MB disk0s1
    2: Apple_APFS Container disk1 500.0 GB disk0s2

    /dev/disk1 (synthesized):
    #: TYPE NAME SIZE IDENTIFIER
    0: APFS Container Scheme - +500.0 GB disk1
    Physical Store disk0s2
    1: APFS Volume Big Sur - Data 451.7 GB disk1s1
    2: APFS Volume Preboot 2.1 GB disk1s2
    3: APFS Volume Recovery 1.2 GB disk1s3
    4: APFS Volume VM 3.2 GB disk1s4
    5: APFS Volume John's HD 9.3 GB disk1s5
    6: APFS Snapshot com.apple.os.update-... 9.3 GB disk1s5s1

    /dev/disk2 (external, physical):
    #: TYPE NAME SIZE IDENTIFIER
    0: GUID_partition_scheme *500.1 GB disk2
    1: EFI EFI 209.7 MB disk2s1
    2: Apple_APFS Container disk3 499.9 GB disk2s2

    /dev/disk3 (synthesized):
    #: TYPE NAME SIZE IDENTIFIER
    0: APFS Container Scheme - +499.9 GB disk3
    Physical Store disk2s2
    1: APFS Volume Untitled 1.2 MB disk3s1

    johnhill@Johns-iMac ~ %


    So it clearly is disk2

    Old John.

    --
    Classic computing: Computers do what you tell them to do, not what you want them to do.
    Modern computing: Computers do what they want to do, no matter what you tell them to do.

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Theo@21:1/5 to Alan B on Fri Jun 14 12:10:26 2024
    Alan B <alanrichardbarker@gmail.com.invalid> wrote:
    So I reckon the following terminal 2 commands should zap the SSD:

    1) diskutil unmountDisk disk2

    Followed by Theo’s suggestion:

    2) sudo dd if=/dev/zero of=/dev/rdisk2 bs=104857600

    You should then be able to reformat the SSD using the Disk Utility application.

    I tried this out with a 64GB USB3 memory stick and it seemed to work OK.
    Sure it takes a long time but maybe you can cancel the dd command after a short while unless you want to completely zeroise the SSD?

    GPT stores a backup partition table at the end of the disc, so a full wipe nukes this too, otherwise it may still be hanging around and tools could
    decide to 'fix' things by restoring it. However just wiping the
    beginning may be enough to prevent APFS/Disk Utility from trying to use the disc and so causing the reported problems.

    It would be fair to let dd run for a little while, then stop it, unplug and replug the drive and see if it fixed the problem. If the problem remains,
    then try a full wipe by letting dd run to completion (eg overnight).

    Theo

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Alan B@21:1/5 to Theo on Fri Jun 14 11:19:42 2024
    Theo wrote:


    Alan B <alanrichardbarker@gmail.com.invalid> wrote:
    So I reckon the following terminal 2 commands should zap the SSD:

    1) diskutil unmountDisk disk2

    Followed by Theo’s suggestion:

    2) sudo dd if=/dev/zero of=/dev/rdisk2 bs=104857600

    You should then be able to reformat the SSD using the Disk Utility
    application.

    I tried this out with a 64GB USB3 memory stick and it seemed to work OK.
    Sure it takes a long time but maybe you can cancel the dd command after a
    short while unless you want to completely zeroise the SSD?

    GPT stores a backup partition table at the end of the disc ...

    Yes I should have known that!

    ... so a full wipe
    nukes this too, otherwise it may still be hanging around and tools could decide to 'fix' things by restoring it. However just wiping the
    beginning may be enough to prevent APFS/Disk Utility from trying to use the disc and so causing the reported problems.

    I certainly found that to be the case when I zapped my USB stick, so
    worth a try.

    It would be fair to let dd run for a little while, then stop it, unplug and replug the drive and see if it fixed the problem. If the problem remains, then try a full wipe by letting dd run to completion (eg overnight).

    --
    Cheers, Alan

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From John Hill@21:1/5 to All on Fri Jun 14 18:02:37 2024
    On 14 Jun 2024 at 12:10:26 BST, "Theo" <theom+news@chiark.greenend.org.uk> wrote:

    Alan B <alanrichardbarker@gmail.com.invalid> wrote:
    So I reckon the following terminal 2 commands should zap the SSD:

    1) diskutil unmountDisk disk2

    Followed by Theo’s suggestion:

    2) sudo dd if=/dev/zero of=/dev/rdisk2 bs=104857600

    You should then be able to reformat the SSD using the Disk Utility
    application.

    I tried this out with a 64GB USB3 memory stick and it seemed to work OK.
    Sure it takes a long time but maybe you can cancel the dd command after a
    short while unless you want to completely zeroise the SSD?

    GPT stores a backup partition table at the end of the disc, so a full wipe nukes this too, otherwise it may still be hanging around and tools could decide to 'fix' things by restoring it. However just wiping the
    beginning may be enough to prevent APFS/Disk Utility from trying to use the disc and so causing the reported problems.

    It would be fair to let dd run for a little while, then stop it, unplug and replug the drive and see if it fixed the problem. If the problem remains, then try a full wipe by letting dd run to completion (eg overnight).

    Theo

    The run completed OK and faster than I anticipated. USB3 makes such a difference. I have formatted the drive and it is now at nominal capacity.
    There is still a question in my mind - whether to continue using it as an off-site backup drive as before, or use a Crucial drive as possibly being more reliable. My eldest son reinforces the opinion that ScanDisk drives are not
    the last word in reliability, and a backup drive must be trustworthy.
    Thank you all for helping me with this problem. I shall keep the instructionsjust in case.

    Old John.

    --
    God made the integers; all else is the work of man.

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From David Brooks@21:1/5 to John Hill on Fri Jun 14 19:36:22 2024
    On 14/06/2024 19:02, John Hill wrote:
    [....]
    The run completed OK and faster than I anticipated. USB3 makes such a difference. I have formatted the drive and it is now at nominal capacity. There is still a question in my mind - whether to continue using it as an off-site backup drive as before, or use a Crucial drive as possibly being more
    reliable. My eldest son reinforces the opinion that ScanDisk drives are not the last word in reliability, and a backup drive must be trustworthy.
    Thank you all for helping me with this problem. I shall keep the instructionsjust in case.


    Well done, Old John! 🙂

    Have you considered running Disk Drill to determine just what is still recoverable on your disk?

    Might be a bit of fun!

    --
    David

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Alan B@21:1/5 to John Hill on Fri Jun 14 18:19:36 2024
    John Hill wrote:


    On 14 Jun 2024 at 12:10:26 BST, "Theo" <theom+news@chiark.greenend.org.uk> wrote:

    Alan B <alanrichardbarker@gmail.com.invalid> wrote:
    So I reckon the following terminal 2 commands should zap the SSD:

    1) diskutil unmountDisk disk2

    Followed by Theo’s suggestion:

    2) sudo dd if=/dev/zero of=/dev/rdisk2 bs=104857600

    You should then be able to reformat the SSD using the Disk Utility
    application.

    I tried this out with a 64GB USB3 memory stick and it seemed to work OK. >>> Sure it takes a long time but maybe you can cancel the dd command after a >>> short while unless you want to completely zeroise the SSD?

    GPT stores a backup partition table at the end of the disc, so a full wipe >> nukes this too, otherwise it may still be hanging around and tools could
    decide to 'fix' things by restoring it. However just wiping the
    beginning may be enough to prevent APFS/Disk Utility from trying to use the >> disc and so causing the reported problems.

    It would be fair to let dd run for a little while, then stop it, unplug and >> replug the drive and see if it fixed the problem. If the problem remains, >> then try a full wipe by letting dd run to completion (eg overnight).

    Theo

    The run completed OK and faster than I anticipated. USB3 makes such a difference. I have formatted the drive and it is now at nominal capacity. There is still a question in my mind - whether to continue using it as an off-site backup drive as before, or use a Crucial drive as possibly being more
    reliable. My eldest son reinforces the opinion that ScanDisk drives are not the last word in reliability, and a backup drive must be trustworthy.
    Thank you all for helping me with this problem. I shall keep the instructionsjust in case.

    Glad to hear the drive is in good order now :) Like Bernd mentioned
    earlier, I've seen reports of problems with large capacity SanDisk SSDs.
    I've some smaller capacity SanDisk SSDs (250 & 500GB) and they seem OK
    but I'll think twice before purchasing any larger size drives from them.

    --
    Cheers, Alan

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)