[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: New discussion: ppc64 installer -- ext2 /boot partition to keep yaboot happy.



On 10/08/2017 06:13 PM, Frank Scheiner wrote:
> I today tried the installation of Debian Sid on my Power Mac G5 (11,2) with the
> latest installer image ([1] from today 12:56h) and I saw that the HFS partition
> is not formatted when using GRUB as boot loader.

Of course not. I haven't implemented this particular mechanism yet. That's why
I need people like you to test the mechanism so I can implement it later.

If it already worked, there wasn't anything to do in the first place :).

> I think this is because only when yaboot is chosen as boot loader, the `hfsutils` package is actually installed:

Yes, this mechanism is part of the yaboot-installer script.

> With GRUB selected (note the time stamps, this actually happened earlier
> than the yaboot installation, so the `hfsutils` package wasn't already installed at
> this time but is really no dependency of Grub!):

Of course, it isnt'. As I said, the mechanism isn't there yet. We have to
implement it first.

> I don't know, why the HFS partition is not formatted at the end of the
> partitioning step, which would IMHO make more sense.

Because it hasn't been implemented yet and the current mechanism is that the
formatting happens in yaboot-installer.

> I also saw the following message during GRUB installation:
> ```
> It seems that this computer is configured to boot via EFI, but maybe that
> configuration will not work for booting from the hard drive. Some EFI firmware
> implementations do not meet the EFI specification (i.e. they are buggy!) and
> do not support proper configuration of boot options from system hard drives.
> 
> A workaround for this problem is to install an extra copy of the EFI version
> of the GRUB boot loader to a fallback location, the "removable media path". Almost
> all EFI systems, no matter how buggy, will boot GRUB that way.
> 
> Warning: If the installer failed to detect another operating system that is
> present on your computer that also depends on this fallback, installing GRUB there
> will make that operating system temporarily unbootable. GRUB can be manually
> configured later to boot it if necessary.
> 
> Force GRUB installation to the EFI removable media path?
> 
> <Go Back>     <Yes>    <No>
> ```
> 
> I always used the "No" option.

This error message is bogus. You don't have EFI on PowerPC Macs. You can ignore it.

> As Rick also mentioned, 8 MB - as proposed by me - seems to be too small for a
> default installation of GRUB - although it seemed to be just big enough for all
> installed files in an earlier try today, but only a few KiB were left. Hence we
> should maybe use more in any case. The question is, how this should work on IBM
> machines with PReP partition and the 8 MB limit?

The answer is that on PReP, GRUB works differently. I have already successfully
installed GRUB on my POWER7 machine with an 8 MiB PReP partition. PReP boot
partitions also aren't focus of this discussion as I can easily test PReP
myself. Please ignore PReP.

> So I modified `/lib/partman/recipes-ppc64-powermac_newworld/30atomic`
> to use 10 MB as minimum size:

Why not simply partition the hard disk manually?

> ```
> ...and restarted from the "Partition disks" step. Then first installed yaboot as
> boot loader, to get the `/dev/sda2` partition formatted with HFS, then mounted
> `/dev/sda2` to `/target/boot/grub` and then installed GRUB as boot loader.
> Although the space on the HFS FS was sufficient:
> 
> ```
> /target/boot/grub # ls -la
> drwxr-xr-x    1 root     root             9 Oct  8 15:29 .
> drwxr-xr-x    3 root     root          4096 Oct  8 15:28 ..
> drwxr-xr-x    1 root     root             3 Oct  8 15:29 fonts
> -rw-r--r--    1 root     root          1024 Oct  8 15:29 grubenv
> drwxr-xr-x    1 root     root            40 Oct  8 15:29 locale
> -rw-r--r--    1 root     root          2858 Oct  8  2017 ofboot.b
> drwxr-xr-x    1 root     root           212 Oct  8 15:29 powerpc-ieee1275
> -rw-r--r--    1 root     root        198212 Oct  8  2017 yaboot
> -rw-r--r--    1 root     root           681 Oct  8  2017 yaboot.conf
> 
> /target/boot/grub # df -h
> Filesystem                Size      Used Available Use% Mounted on
> none                    891.1M      1.6M    889.6M   0% /run
> devtmpfs                  4.1G         0      4.1G   0% /dev
> /dev/sda3               907.5G      1.1G    860.2G   0% /target
> /dev/sda3               907.5G      1.1G    860.2G   0% /dev/.static/dev
> devtmpfs                  4.1G         0      4.1G   0% /target/dev
> /dev/sda2                 9.5M      8.4M      1.1M  88% /target/boot/grub
> /dev/sr0                225.3M    225.3M         0 100% /cdrom
> ```
> 
> ...the installation of GRUB failed with the following messages:
> ```
> Oct  8 15:29:29 grub-installer: info: Installing grub on 'dummy'
> Oct  8 15:29:30 grub-installer: info: grub-install does not support --no-floppy
> Oct  8 15:29:41 grub-installer: info: Running chroot /target grub-install  --force "dummy"
> Oct  8 15:29:41 grub-installer: Installing for powerpc-ieee1275 platform.
> 
> Oct  8 15:29:45 grub-installer: grub-install: error: cannot find a GRUB drive for dummy.  Check your device.map.

grub-installer doesn't have any mechanism yet to find the boot partition on
NewWorld Macs. We need to implement that. On supported systems, grub-installer
will prompt with a list of possible target devices. The device name "dummy" also
gives it away.

Just switch to a shell and try to install GRUB with grub-install providing
the proper target device.

Adrian

-- 
 .''`.  John Paul Adrian Glaubitz
: :' :  Debian Developer - glaubitz@debian.org
`. `'   Freie Universitaet Berlin - glaubitz@physik.fu-berlin.de
  `-    GPG: 62FF 8A75 84E0 2956 9546  0006 7426 3B37 F5B5 F913


Reply to: