Windows partition disappeared using Boot Camp on Mojave

I have a 2017 MacBook Pro with 250GB SSD. I created a Windows partition some time ago but stopped using Windows, so I wanted to remove it and restore the 40GB allocated to the partition back to my main partition.


According to the Boot Camp instructions, I am supposed to be able to restore the space back to my mac, but it seems that I did something wrong, since now the Windows partition has disappeared but the space is not back on my main partition.


Here is the output for the "diskutil list" and "diskutil cs list" commands:


Last login: Sun Mar  3 21:42:53 on console
bysja@mbp:~|⇒  diskutil list
/dev/disk0 (internal):
   #:                       TYPE NAME                    SIZE       IDENTIFIER
   0:      GUID_partition_scheme                         251.0 GB   disk0
   1:                        EFI EFI                     314.6 MB   disk0s1
   2:                 Apple_APFS Container disk1         210.0 GB   disk0s2

/dev/disk1 (synthesized):
   #:                       TYPE NAME                    SIZE       IDENTIFIER
   0:      APFS Container Scheme -                      +210.0 GB   disk1
                                 Physical Store disk0s2
   1:                APFS Volume Macintosh HD            140.3 GB   disk1s1
   2:                APFS Volume Preboot                 82.7 MB    disk1s2
   3:                APFS Volume Recovery                1.6 GB     disk1s3
   4:                APFS Volume VM                      3.2 GB     disk1s4

bysja@mbp:~|⇒  diskutil cs list
No CoreStorage logical volume groups found


Is there a way for me to get these 40GB back?

MacBook Pro 13", macOS 10.14

Posted on Mar 3, 2019 2:29 PM

Reply

Similar questions

3 replies

Mar 4, 2019 9:20 AM in response to Loner T

Wow, thank you! This command completely resolved the issue in less than 30 seconds. The SSD is now back at full capacity.


bysja@mbp:~|⇒  diskutil apfs resizeContainer disk1 0g
Started APFS operation
Aligning grow delta to 40.685.187.072 bytes and targeting a new physical store size of 250.685.575.168 bytes
Determined the maximum size for the targeted physical store of this APFS Container to be 250.684.547.072 bytes
Resizing APFS Container designated by APFS Container Reference disk1
The specific APFS Physical Store being resized is disk0s2
Verifying storage system
Using live mode
Performing fsck_apfs -n -x -l -S /dev/disk0s2
Checking the container superblock
Checking the EFI jumpstart record
Checking the space manager
Checking the space manager free queue trees
Checking the object map
Checking volume
Checking the APFS volume superblock
The volume Macintosh HD was formatted by newfs_apfs (748.1.46) and last modified by apfs_kext (945.241.4)
Checking the object map
Checking the snapshot metadata tree
Checking the snapshot metadata
Checking the extent ref tree
Checking the fsroot tree
Checking volume
Checking the APFS volume superblock
The volume Preboot was formatted by newfs_apfs (748.1.46) and last modified by apfs_kext (945.241.4)
Checking the object map
Checking the snapshot metadata tree
Checking the snapshot metadata
Checking the extent ref tree
Checking the fsroot tree
Checking volume
Checking the APFS volume superblock
The volume Recovery was formatted by newfs_apfs (748.1.46) and last modified by apfs_kext (945.241.4)
Checking the object map
Checking the snapshot metadata tree
Checking the snapshot metadata
Checking the extent ref tree
Checking the fsroot tree
Checking volume
Checking the APFS volume superblock
The volume VM was formatted by newfs_apfs (748.1.47) and last modified by apfs_kext (945.241.4)
Checking the object map
Checking the snapshot metadata tree
Checking the snapshot metadata
Checking the extent ref tree
Checking the fsroot tree
Verifying allocated space
Performing deferred repairs
The volume /dev/disk0s2 appears to be OK
Storage system check exit code is 0
Growing APFS Physical Store disk0s2 from 210.000.388.096 to 250.685.575.168 bytes
Modifying partition map
Growing APFS data structures
Finished APFS operation

This thread has been closed by the system or the community team. You may vote for any posts you find helpful, or search the Community for additional answers.

Windows partition disappeared using Boot Camp on Mojave

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple Account.