HaC-Mini icon indicating copy to clipboard operation
HaC-Mini copied to clipboard

Preinstall fails to find device with RAID

Open Super-Genius opened this issue 4 years ago • 13 comments

Describe the bug Install to existing hard drive

Expected behavior Installer preinstall.sh shouldn't fail with Device not Found

Environment:

  • Running OSX version: 10.14.6
  • Target drive OSX version: 10.15.6
  • HaC Mini installer version:

Additional context Add any other context about the problem here.

Logs 2020-08-20 16:35:42-07 installd[886]: ./preinstall: Mounting ESP to /Volumes/Macintosh_SSD/private/tmp/EFIROOTDIR 2020-08-20 16:35:42-07 installd[886]: ./preinstall: Target volume /Volumes/Macintosh_SSD on disk2 is APFS on physical store s disk1s2, disk0s2 2020-08-20 16:35:42-07 installd[886]: ./preinstall: Target volume /Volumes/Macintosh_SSD on is RAID on physical store 2020-08-20 16:35:43-07 installd[886]: ./preinstall: Error: invalid device name '' 2020-08-20 16:35:43-07 installd[886]: ./preinstall: Partition is , not GUID_partition_scheme!

Installer errors out. I think the sed isn't parsing something

Super-Genius avatar Aug 21 '20 00:08 Super-Genius

Partition is , not GUID_partition_scheme!

Please follow the guide closely.

osy avatar Aug 21 '20 00:08 osy

It seems the script is looking for Apple raid type, when this system is a Fusion Raid (which combines the 2 M2 sticks into one drive) and is bootable.

Super-Genius avatar Aug 21 '20 00:08 Super-Genius

It is a GUID_Partition by the way, the script just thinks it's an Apple raid and the command 'diskutil ar list' doesn't return anything since it is a fusion disk. I built it as a fusion disk, because previous OSX wouldn't boot apple raid disks.

Super-Genius avatar Aug 21 '20 00:08 Super-Genius

I’ve never tried it with RAID before. Will have to look more into it.

osy avatar Aug 21 '20 00:08 osy

You can't create a RAID set on your startup disk; you must first start up your computer from another disk.

https://support.apple.com/guide/disk-utility/create-a-disk-set-dskua23150fd/mac#:~:text=In%20the%20Disk%20Utility%20app,your%20computer%20from%20another%20disk.

So I built a fusion disk, which you can boot with and combined 2 -2TB M2 drives to make one big 4TB drive.

APFS Container (1 found) | +-- Container disk2 308F7608-CA73-44A2-94CC-966721EF5C70 ==================================================== APFS Container Reference: disk2 (Fusion) Size (Capacity Ceiling): 4096396984320 B (4.1 TB) Capacity In Use By Volumes: 897684713472 B (897.7 GB) (21.9% used) Capacity Not Allocated: 3198712270848 B (3.2 TB) (78.1% free) |

+-< Physical Store disk1s2 6B154C02-ADBA-48A7-94E6-DCC0366528FD
APFS Physical Store Disk: disk1s2 (Secondary, Designated Aux Use)
Size: 2048198492160 B (2.0 TB)
+-< Physical Store disk0s2 A9DDA3EC-2F2B-4062-99AB-F124F95691B7
|   -----------------------------------------------------------
|   APFS Physical Store Disk:   disk0s2 (Main)
|   Size:                       2048198492160 B (2.0 TB)
|
+-> Volume disk2s1 3603AD2D-1AE7-4B92-9EBD-828A272D019F
|   ---------------------------------------------------
|   APFS Volume Disk (Role):   disk2s1 (No specific role)
|   Name:                      Macintosh_SSD (Case-insensitive)
|   Mount Point:               /
|   Capacity Consumed:         887933030400 B (887.9 GB)
|   FileVault:                 No
|
+-> Volume disk2s2 375BFA9D-57C8-4F44-A366-F9A3D6CBBD0B
|   ---------------------------------------------------
|   APFS Volume Disk (Role):   disk2s2 (Preboot)
|   Name:                      Preboot (Case-insensitive)
|   Mount Point:               Not Mounted
|   Capacity Consumed:         44437504 B (44.4 MB)
|   FileVault:                 No
|
+-> Volume disk2s3 8AA9CE92-FCBD-4804-A39A-84FDC012D392
|   ---------------------------------------------------
|   APFS Volume Disk (Role):   disk2s3 (Recovery)
|   Name:                      Recovery (Case-insensitive)
|   Mount Point:               Not Mounted
|   Capacity Consumed:         510246912 B (510.2 MB)
|   FileVault:                 No
|
+-> Volume disk2s4 609D4C9F-6860-4319-BD38-B6C84C6CAAC1
    ---------------------------------------------------
    APFS Volume Disk (Role):   disk2s4 (VM)
    Name:                      VM (Case-insensitive)
    Mount Point:               /private/var/vm
    Capacity Consumed:         20480 B (20.5 KB)
    FileVault:                 No

Super-Genius avatar Aug 21 '20 00:08 Super-Genius

Followed instructions here:

https://www.econtechnologies.com/chronosync/TN-CS-APFS-Fusion-Drive.html

Super-Genius avatar Aug 21 '20 00:08 Super-Genius

I guess as a quick fix, I can install to USB and then mount the EFI drive and copy the USB EFI to the HDD EFI?

Super-Genius avatar Aug 21 '20 00:08 Super-Genius

As macOS does not support it, there is no plans to support RAID.

osy avatar Dec 28 '20 02:12 osy

I'm also using a Fusion drive to merge two 1TB NVMe drives into 2TB of contiguous space. The initial setup is a PITA, but after that it works like a charm, including the latest software update to Big Sur 11.5.2.

I want to update OC/KEXTs using the HaC-Mini installer, but it fails as above because mount_esp.sh is looking for "Physical Store $part" whereas diskutil shows the plural "Physical Stores $part1, $part2" (and then look for an EFI partition on each disk). If that's too much work, can we instead have the script accept an environment variable override that specifies the EFI partition, so we can open --env EFI_DISK=disk0s1 HaCMini.pkg?

My partitions look like this:

$ diskutil list
/dev/disk0 (internal, physical):
   #:                       TYPE NAME                    SIZE       IDENTIFIER
   0:      GUID_partition_scheme                        *1.0 TB     disk0
   1:                        EFI ⁨EFI⁩                     209.7 MB   disk0s1
   2:                 Apple_APFS ⁨Container disk2⁩         1000.0 GB  disk0s2

/dev/disk1 (internal, physical):
   #:                       TYPE NAME                    SIZE       IDENTIFIER
   0:                                                   *1.0 TB     disk1

/dev/disk2 (synthesized):
   #:                       TYPE NAME                    SIZE       IDENTIFIER
   0:      APFS Container Scheme -                      +2.0 TB     disk2
                                 Physical Stores disk1, disk0s2
   1:                APFS Volume ⁨Macintosh HD - Data⁩     1.8 TB     disk2s1
   2:                APFS Volume ⁨Macintosh HD⁩            15.3 GB    disk2s2
   3:              APFS Snapshot ⁨com.apple.os.update-...⁩ 15.3 GB    disk2s2s1
   4:                APFS Volume ⁨Preboot⁩                 303.1 MB   disk2s3
   5:                APFS Volume ⁨Recovery⁩                633.7 MB   disk2s4
   6:                APFS Volume ⁨VM⁩                      1.1 MB     disk2s5

diskdude avatar Sep 12 '21 00:09 diskdude

I think this issue should be reopened per @diskdude 's comments. This isn't RAID per se and is a Fusion Drive that is supported by APFS and boot.

@diskdude I tried to get the OpenCore part to work, but it wouldn't see my drive. Tried adding MinDate, -1, MinVersion -1 because it is on Catalina, but when booting it just showed the Apple logo and not even the usual OpenCore menu and hung.

Did you do anything special to get OpenCore to work and see your drives?

Right now I'm stuck with Clover Boot (it does seem to work for Catalina). But I probably need to upgrade some of the patches

SuperGNUS avatar Oct 14 '21 16:10 SuperGNUS

I want to update OC/KEXTs using the HaC-Mini installer, but it fails as above because mount_esp.sh is looking for "Physical Store $part" whereas diskutil shows the plural "Physical Stores $part1, $part2" (and then look for an EFI partition on each disk). If that's too much work, can we instead have the script accept an environment variable override that specifies the EFI partition, so we can open --env EFI_DISK=disk0s1 HaCMini.pkg?

Just a little bit more information. Both drives have an EFI partition, so it might be difficult to figure out which one is the actual boot drive and which EFI partition to use. The second option would solve that.

here's my disk arrangement.

/dev/disk0 (internal, physical):
   #:                       TYPE NAME                    SIZE       IDENTIFIER
   0:      GUID_partition_scheme                        *2.0 TB     disk0
   1:                        EFI EFI                     209.7 MB   disk0s1
   2:                 Apple_APFS Container disk2         2.0 TB     disk0s2

/dev/disk1 (internal, physical):
   #:                       TYPE NAME                    SIZE       IDENTIFIER
   0:      GUID_partition_scheme                        *2.0 TB     disk1
   1:                        EFI EFI                     209.7 MB   disk1s1
   2:                 Apple_APFS Container disk2         2.0 TB     disk1s2

/dev/disk2 (synthesized):
   #:                       TYPE NAME                    SIZE       IDENTIFIER
   0:      APFS Container Scheme -                      +4.1 TB     disk2
                                 Physical Stores disk0s2, disk1s2
   1:                APFS Volume Macintosh_SSD - Data    1.0 TB     disk2s1
   2:                APFS Volume Preboot                 35.9 MB    disk2s2
   3:                APFS Volume Recovery                18.7 MB    disk2s3
   4:                APFS Volume VM                      1.1 GB     disk2s4
   5:                APFS Volume Macintosh_SSD           11.1 GB    disk2s5

SuperGNUS avatar Oct 14 '21 16:10 SuperGNUS

@diskdude I tried to get the OpenCore part to work, but it wouldn't see my drive. Tried adding MinDate, -1, MinVersion -1 because it is on Catalina, but when booting it just showed the Apple logo and not even the usual OpenCore menu and hung.

Did you do anything special to get OpenCore to work and see your drives?

Might be good idea to get off Clover and onto OC and use Big Sur and above. I found that Fusion Drives using two equal sized SSDs on prior macOS versions would eventually lead to lots of "no space left on device" failures when about 50% of the combined space was used: my guess is that one SSD filled up and there was a bug preventing files being moved to the other SSD because they were both similar speeds? (i.e. not the usual HDD + SSD Fusion Drive.) In any case, that bug seems to have been fixed on Big Sur: I've been using a two-SSD Fusion Drive (with File Vault) for many months now without any problems (2TB total, with about 200GB free).

To boot into a Fusion Drive, you need an EFI partition. @GVTopCoder has two (presumably one is sitting idle), but I am using only one so I don't waste any disk space. You can see my partition layout in my last post above. I manually created that layout in the Terminal on the macOS install boot image.

Otherwise my OC config has the following that relate to the filesystem:

  • UEFI > APFS > EnableJumpstart
  • UEFI > Drivers > apfs.efi (where the .efi file was copied from a macOS install into $OC/Drivers/apfs.efi on the EFI partition and where $OC is where the OC config.plist file lives.)

You probably need just one of the above OC configs: I can't remember if I added the apfs.efi driver because Jumpstart didn't work with the Fusion Drive, or if it was left over from an older OC config from before Jumpstart was supported. I didn't need anything else to boot a Fusion Drive with OC.

diskdude avatar Oct 28 '21 01:10 diskdude

@diskdude I tried to get the OpenCore part to work, but it wouldn't see my drive. Tried adding MinDate, -1, MinVersion -1 because it is on Catalina, but when booting it just showed the Apple logo and not even the usual OpenCore menu and hung. Did you do anything special to get OpenCore to work and see your drives?

Might be good idea to get off Clover and onto OC and use Big Sur and above. I found that Fusion Drives using two equal sized SSDs on prior macOS versions would eventually lead to lots of "no space left on device" failures when about 50% of the combined space was used: my guess is that one SSD filled up and there was a bug preventing files being moved to the other SSD because they were both similar speeds? (i.e. not the usual HDD + SSD Fusion Drive.) In any case, that bug seems to have been fixed on Big Sur: I've been using a two-SSD Fusion Drive (with File Vault) for many months now without any problems (2TB total, with about 200GB free).

To boot into a Fusion Drive, you need an EFI partition. @GVTopCoder has two (presumably one is sitting idle), but I am using only one so I don't waste any disk space. You can see my partition layout in my last post above. I manually created that layout in the Terminal on the macOS install boot image.

Otherwise my OC config has the following that relate to the filesystem:

  • UEFI > APFS > EnableJumpstart
  • UEFI > Drivers > apfs.efi (where the .efi file was copied from a macOS install into $OC/Drivers/apfs.efi on the EFI partition and where $OC is where the OC config.plist file lives.)

You probably need just one of the above OC configs: I can't remember if I added the apfs.efi driver because Jumpstart didn't work with the Fusion Drive, or if it was left over from an older OC config from before Jumpstart was supported. I didn't need anything else to boot a Fusion Drive with OC.

Thanks for that I got it working, but had to install to USB, boot into EFI terminal and copy the directory to the SSD EFI Directory and then everything worked. I think I did change a couple of the setting you mentioned as well and everything is working now. Just upgrades are going to have to be manual, which is a shame.

SuperGNUS avatar Feb 08 '22 20:02 SuperGNUS