MacOS – APFS – Catalina – Increase the size of a container

apfsfilesystemmacos

I have a 4TB external SSD. Running Diskutil I get

/dev/disk3 (external, physical):
   #:                       TYPE NAME                    SIZE       IDENTIFIER
   0:      GUID_partition_scheme                        *4.0 TB     disk3
   1:                        EFI EFI                     209.7 MB   disk3s1
   2:                 Apple_APFS Container disk7         2.2 TB     disk3s2
   3:                 Apple_Boot                         650.0 MB   disk3s6
   4:                 Apple_APFS Container disk4         1.8 TB     disk3s4

/dev/disk4 (synthesized):
   #:                       TYPE NAME                    SIZE       IDENTIFIER
   0:      APFS Container Scheme -                      +1.8 TB     disk4
                                 Physical Store disk3s4
   1:                APFS Volume SSD 1015 - Data         1.6 TB     disk4s1
   2:                APFS Volume Preboot                 87.0 MB    disk4s2
   3:                APFS Volume Recovery                528.9 MB   disk4s3
   4:                APFS Volume VM                      19.3 GB    disk4s4

/dev/disk7 (synthesized):
   #:                       TYPE NAME                    SIZE       IDENTIFIER
   0:      APFS Container Scheme -                      +2.2 TB     disk7
                                 Physical Store disk3s2

My goal is to have /dev/disk4 be the combined size (~4TB). It is now about 1/2 the size of the physical disk. 4TB is the size of the physical drive size, but it got split into 2 partitions as i was upgrading from Mojave to Catalina (long story as I couldn't just upgrade because the SSD was originally HFS). I did get rid of the HFS partition and converted to APFS. /dev/disk7 is now blank. /dev/disk4 is now my boot drive.

I really don't want to have to reformat the SSD (boot disk) if at all possible. I tried

sudo diskutil apfs resizeContainer disk4 0

but that didn't work.

Is this possible? I also tried using disk utility, but it didn't seem to want to resize up either.

Can someone steer me in the right direction? — Thanks

Best Answer

Things digressed after the posting. Without doing anything, the size of the physical disk also changed. I think there was corruption in the file system, although Disk Util found nothing. I saved everything, and reformatted the SSD. All seems OK now with proper sizes showing up.