Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.debian.user > #239548 > unrolled thread
| Started by | David Christensen <dpchrist@holgerdanske.com> |
|---|---|
| First post | 2021-09-01 00:40 +0200 |
| Last post | 2021-09-11 17:40 +0200 |
| Articles | 10 — 6 participants |
Back to article view | Back to linux.debian.user
Install Debian 10 amd64 onto USB flash drive with and for Macintosh David Christensen <dpchrist@holgerdanske.com> - 2021-09-01 00:40 +0200
Re: Install Debian 10 amd64 onto USB flash drive with and for Macintosh Dan Ritter <dsr@randomstring.org> - 2021-09-01 01:00 +0200
Re: Install Debian 10 amd64 onto USB flash drive with and for Macintosh David Christensen <dpchrist@holgerdanske.com> - 2021-09-01 02:40 +0200
Re: Install Debian 10 amd64 onto USB flash drive with and for Macintosh Keith Bainbridge <keithrboz@gmail.com> - 2021-09-01 06:00 +0200
Re: Install Debian 10 amd64 onto USB flash drive with and for Macintosh didier gaumet <didier.gaumet@gmail.com> - 2021-09-01 10:20 +0200
Re: Install Debian 10 amd64 onto USB flash drive with and for Macintosh David Christensen <dpchrist@holgerdanske.com> - 2021-09-02 01:10 +0200
Re: Install Debian 10 amd64 onto USB flash drive with and for Macintosh David Wright <deblis@lionunicorn.co.uk> - 2021-09-03 02:40 +0200
Re: Install Debian 10 amd64 onto USB flash drive with and for Macintosh David Christensen <dpchrist@holgerdanske.com> - 2021-09-03 07:40 +0200
Re: Install Debian 10 amd64 onto USB flash drive with and for Macintosh David Wright <deblis@lionunicorn.co.uk> - 2021-09-09 05:50 +0200
Re: Install Debian 10 amd64 onto USB flash drive with and for Macintosh Andrei POPESCU <andreimpopescu@gmail.com> - 2021-09-11 17:40 +0200
| From | David Christensen <dpchrist@holgerdanske.com> |
|---|---|
| Date | 2021-09-01 00:40 +0200 |
| Subject | Install Debian 10 amd64 onto USB flash drive with and for Macintosh |
| Message-ID | <CSkAa-1fV-9@gated-at.bofh.it> |
debian-user:
I have an Apple MacBook Pro (Retina, 15-inch, Mid 2015) with an Intel
Core i7-4770HQ processor, 16 GB memory, and 256 GB SSD:
https://support.apple.com/kb/SP719?viewlocale=en_US&locale=en_US
https://en.wikipedia.org/wiki/MacBook_Pro
The laptop has two USB 3.0 ports.
I would like to install Debian 10 onto a USB flash drive as a
self-contained, bootable, full, live installation that I use with this
and other Intel-based Macintosh computers.
I downloaded the following Debian Installer files, verified the
checksums, and verified the signature:
https://cdimage.debian.org/cdimage/archive/10.10.0/amd64/jigdo-cd/
SHA256SUMS*
SHA256SUMS.sign*
debian-10.10.0-amd64-xfce-CD-1.iso*
debian-10.10.0-amd64-xfce-CD-1.jigdo*
I assembled the ISO file, verified the checksum, and burned it to a
blank USB flash drive:
debian-10.10.0-amd64-xfce-CD-1.iso
I downloaded the following firmware files, verified the checksums,
verified the signature, expanded the archive, and copied the firmware
files to a vfat USB flash drive:
https://cdimage.debian.org/cdimage/unofficial/non-free/firmware/buster/10.10.0/
SHA256SUMS*
SHA256SUMS.sign*
firmware.tar.gz*
I powered off the Mac, inserted the Debian Installer USB flash drive,
powered up the Mac, pressed and held the Option key, selected the left
"EFI Boot" disk:
Debian GNU/Linux 10.10.0
Debian GNU/Linux UEFI Installer menu -> Install
Language -> C
Continent or region -> North America
Country, territory or area -> United States
Keymap to use -> American English
Detect network hardware
<insert firmware USB flash drive>
<install Wi-Fi adapter firmware>
<remove firmware USB flash drive>
<insert blank USB flash drive>
Configure the network ->
Wireless network -> wifi.tracy.holgerdanske.com
Wireless network type for w1p3s0 -> WPA/WPA2 PSK
WPA/WPA2 passphrase for wireless device w1p3s0 -> ********
Hostname -> buster-mac
Domain name -> localdomain
Root password -> ********
Re-enter password to verify -> ********
Full name for the new user -> debian
Username for your account -> debian
Choose a password for the new user -> ********
Re-enter password to verify -> ********
Select your time zone -> Pacific
Partitioning method -> Manual
<create partition table on blank USB flash drive>
<create "1 GB" EFI System Partition>
<create "1 GB" swap partition>
<create "13 GB" root partition>
Use a network mirror -> Yes
Debian archive mirror country -> United States
Debian archive mirror -> deb.debian.org
HTTP proxy information -> <blank>
Participate in the package usage survey -> No
Choose software to install ->
Debian desktop environment
Xfce
print server
SSH server
standard system utilities
Installation complete -> Continue
The machine rebooted into Debian. I logged in, created a default Xfce
panel, looked around briefly, and shutdown the machine.
Note that I was not prompted for the location for installing GRUB.
If I now power up the machine with the buster-mac USB flash drive
installed, Debian starts.
If I now power up the machine without the buster-mac USB flash drive
installed, I see:
GNU GRUB version 2.02+dfsg1-20+deb10u4
Minimal BASH-like line editing is supported. For the first word, TAB
lists possible command completions. Anywhere else TAB lists possible
device or file completions.
grub>
If I now power up the machine without the buster-mac USB flash drive
installed and hold the Option key, I see the MacBook firmware disk
window showing the internal SSD. Selecting the internal SSD starts macOS.
If I now power up the machine without the buster-mac USB flash drive
installed and hold the Command-R keys, I see the MacBook firmware POST
screen, then the MacBook firmware utilities window. Selecting Disk
Utility and View -> Show All Devices, I see:
Internal
APPLE SSD SM0256G Media
Container disk3
dpchrist-mbp
dpchrist-mbp - Data
If I select APPLE SSD SM0256G Media, Container disk3, dpchrist-mbp, or
dpchrist-mbp - Data and click First Aid, Disk Utility detects no errors.
Booting the buster-mac USB flash drive and looking around, it appears
that GRUB was installed on the internal SSD and not on the USB flash drive:
2021-08-31 14:56:11 root@buster-mac ~
# fdisk -l
Disk /dev/sda: 233.8 GiB, 251000193024 bytes, 490234752 sectors
Disk model: APPLE SSD SM0256
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disklabel type: gpt
Disk identifier: 3B3CDB05-D771-4CA5-A9B0-1C47A5652B20
Device Start End Sectors Size Type
/dev/sda1 40 409639 409600 200M EFI System
/dev/sda2 409640 490234711 489825072 233.6G unknown
Disk /dev/sdb: 14.9 GiB, 16008609792 bytes, 31266816 sectors
Disk model: Ultra Fit
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disklabel type: gpt
Disk identifier: 8F392ECB-7E30-46D7-ABAB-DBBCB659863C
Device Start End Sectors Size Type
/dev/sdb1 2048 1953791 1951744 953M EFI System
/dev/sdb2 1953792 3907583 1953792 954M Linux swap
/dev/sdb3 3907584 29298687 25391104 12.1G Linux filesystem
2021-08-31 15:09:59 root@buster-mac ~
# mount | egrep '/dev/sd.[0-9]'
/dev/sdb3 on / type ext4 (rw,relatime,errors=remount-ro)
/dev/sda1 on /boot/efi type vfat
(rw,relatime,fmask=0077,dmask=0077,codepage=437,iocharset=ascii,shortname=mixed,utf8,errors=remount-ro)
2021-08-31 15:13:35 root@buster-mac ~
# df | egrep 'Filesystem|.dev.sd.[0-9]'
Filesystem 1M-blocks Used Available Use% Mounted on
/dev/sdb3 12140M 3589M 7915M 32% /
/dev/sda1 197M 12M 186M 6% /boot/efi
2021-08-31 15:14:40 root@buster-mac ~
# tree /boot/efi
/boot/efi
|-- BOOTLOG
`-- EFI
|-- APPLE
| |-- CACHES
| | `-- CAFEBEEF
| `-- FIRMWARE
| `-- MBP114.fd
`-- debian
|-- BOOTX64.CSV
|-- fbx64.efi
|-- grub.cfg
|-- grubx64.efi
|-- mmx64.efi
`-- shimx64.efi
2021-08-31 15:11:12 root@buster-mac ~
# ls -l /boot/efi
total 2
-rwx------ 1 root root 520 Aug 31 14:16 BOOTLOG
drwx------ 4 root root 512 Aug 31 14:16 EFI
The goal is to have a self-contained Debian installation on the USB
flash drive. This means GRUB needs to be installed onto the USB flash
drive.
Suggestions?
David
[toc] | [next] | [standalone]
| From | Dan Ritter <dsr@randomstring.org> |
|---|---|
| Date | 2021-09-01 01:00 +0200 |
| Subject | Re: Install Debian 10 amd64 onto USB flash drive with and for Macintosh |
| Message-ID | <CSkTw-1mB-3@gated-at.bofh.it> |
| In reply to | #239548 |
David Christensen wrote: > debian-user: > > I have an Apple MacBook Pro (Retina, 15-inch, Mid 2015) with an Intel Core > i7-4770HQ processor, 16 GB memory, and 256 GB SSD: > > > If I now power up the machine with the buster-mac USB flash drive installed, > Debian starts. > > > > If I now power up the machine without the buster-mac USB flash drive > installed and hold the Option key, I see the MacBook firmware disk window > showing the internal SSD. Selecting the internal SSD starts macOS. > > > If I now power up the machine without the buster-mac USB flash drive > installed and hold the Command-R keys, I see the MacBook firmware POST > screen, then the MacBook firmware utilities window. Selecting Disk Utility > and View -> Show All Devices, I see: I am pretty sure you didn't want to install GRUB at all -- the Mac's own EFI booter should work on your USB stick; it's invoked by holding down option at boot time. -dsr-
[toc] | [prev] | [next] | [standalone]
| From | David Christensen <dpchrist@holgerdanske.com> |
|---|---|
| Date | 2021-09-01 02:40 +0200 |
| Subject | Re: Install Debian 10 amd64 onto USB flash drive with and for Macintosh |
| Message-ID | <CSmsh-2nH-1@gated-at.bofh.it> |
| In reply to | #239549 |
On 8/31/21 3:53 PM, Dan Ritter wrote:
> David Christensen wrote:
>> debian-user:
>>
>> I have an Apple MacBook Pro (Retina, 15-inch, Mid 2015) with an Intel Core
>> i7-4770HQ processor, 16 GB memory, and 256 GB SSD:
>>
>>
>> If I now power up the machine with the buster-mac USB flash drive installed,
>> Debian starts.
>>
>>
>>
>> If I now power up the machine without the buster-mac USB flash drive
>> installed and hold the Option key, I see the MacBook firmware disk window
>> showing the internal SSD. Selecting the internal SSD starts macOS.
>>
>>
>> If I now power up the machine without the buster-mac USB flash drive
>> installed and hold the Command-R keys, I see the MacBook firmware POST
>> screen, then the MacBook firmware utilities window. Selecting Disk Utility
>> and View -> Show All Devices, I see:
>
> I am pretty sure you didn't want to install GRUB at all -- the
> Mac's own EFI booter should work on your USB stick; it's invoked
> by holding down option at boot time.
Thank you for the reply. :-)
If I now power up the machine with the buster-mac USB flash drive
installed and hold the Option key, I see the MacBook firmware disk
window showing the internal SSD only; the target USB flash drive with
the Debian instance is not shown.
Perhaps the debian-10.10.0-amd64-xfce-CD-1 Debian Installer USB flash
drive holds a clue, as the MacBook firmware Option key disk window
displays two "EFI Boot" disks:
2021-08-31 16:56:36 root@buster-mac ~
# fdisk -l /dev/sdd
Disk /dev/sdd: 3.6 GiB, 3887595520 bytes, 7592960 sectors
Disk model: USB Flash Drive
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disklabel type: dos
Disk identifier: 0x08fe9327
Device Boot Start End Sectors Size Id Type
/dev/sdd1 * 0 1425407 1425408 696M 0 Empty
/dev/sdd2 7272 12199 4928 2.4M ef EFI (FAT-12/16/32)
2021-08-31 16:57:10 root@buster-mac ~
# mount -o ro /dev/sdd2 /mnt
2021-08-31 16:58:30 root@buster-mac ~
# tree /mnt
/mnt
`-- efi
|-- boot
| |-- bootx64.efi
| `-- grubx64.efi
`-- debian
`-- grub.cfg
3 directories, 3 files
2021-08-31 17:01:22 root@buster-mac ~
# file /mnt/efi/boot/bootx64.efi
/mnt/efi/boot/bootx64.efi: PE32+ executable (EFI application) x86-64
(stripped to external PDB), for MS Windows
2021-08-31 17:01:35 root@buster-mac ~
# file /mnt/efi/boot/grubx64.efi
/mnt/efi/boot/grubx64.efi: PE32+ executable (EFI application) x86-64
(stripped to external PDB), for MS Windows
2021-08-31 17:01:46 root@buster-mac ~
# file /mnt/efi/debian/grub.cfg
/mnt/efi/debian/grub.cfg: ASCII text
2021-08-31 17:01:59 root@buster-mac ~
# cat /mnt/efi/debian/grub.cfg
search --file --set=root /.disk/info
set prefix=($root)/boot/grub
source $prefix/x86_64-efi/grub.cfg
My guess is that efi/boot/bootx64.efi and efi/boot/grubx64.efi
correspond to the two "EFI Boot" disks displayed by the MacBook firmware
Option key disk window (?).
I also noted that the ESP partition on the target USB flash drive is empty:
2021-08-31 17:02:02 root@buster-mac ~
# umount /mnt
2021-08-31 17:06:43 root@buster-mac ~
# mount -o ro /dev/sdb1 /mnt
2021-08-31 17:07:08 root@buster-mac ~
# ls -alF /mnt
total 8
drwxr-xr-x 2 root root 4096 Dec 31 1969 ./
drwxr-xr-x 19 root root 4096 Aug 31 00:09 ../
I expect it needs the equivalent of boot/bootx64.efi, boot/grubx64.efi,
and/or debian/grub.conf as found on the Debian Installer USB flash
drive, but I very much doubt that simply copying those files from the
Debian Installer USB flash drive to the target USB flash drive would
work, given the "hybrid ISO" layout, overlapping partitions, etc., of
the Debian Installer USB stick.
Here is the ESP partition of the MacBook SSD again for comparison:
2021-08-31 17:33:40 root@buster-mac ~
# tree /boot/efi
/boot/efi
|-- BOOTLOG
`-- EFI
|-- APPLE
| |-- CACHES
| | `-- CAFEBEEF
| `-- FIRMWARE
| `-- MBP114.fd
`-- debian
|-- BOOTX64.CSV
|-- fbx64.efi
|-- grub.cfg
|-- grubx64.efi
|-- mmx64.efi
`-- shimx64.efi
6 directories, 8 files
Maybe if I copied the EFI/debian tree to the target USB flash drive ESP
partition, reworked /etc/fstab, and/or reworked whatever other system
configuration files are involved (?), the target USB flash device would
be self-booting (?).
Booting the debian-10.10.0-amd64-xfce-CD-1 Debian Installer USB flash
drive, I see
-> Advanced options...
-> Expert install
Maybe if I do an expert install, I will be given the opportunity to
install GRUB and related onto the target USB flash drive (?).
Alternatively:
-> Advanced options...
-> Rescue mode
May if I knew enough, I could enter the right commands in a rescue shell
and fix the target USB flash drive (?).
I'll wait and see if anyone else has more information.
David
[toc] | [prev] | [next] | [standalone]
| From | Keith Bainbridge <keithrboz@gmail.com> |
|---|---|
| Date | 2021-09-01 06:00 +0200 |
| Subject | Re: Install Debian 10 amd64 onto USB flash drive with and for Macintosh |
| Message-ID | <CSpzP-4uT-1@gated-at.bofh.it> |
| In reply to | #239550 |
On 1/9/21 10:39, David Christensen wrote: > If I now power up the machine with the buster-mac USB flash drive > installed and hold the Option key, I see the MacBook firmware disk > window showing the internal SSD only; the target USB flash drive with > the Debian instance is not shown. David I'ts been at least a decade since I did this, but I recall aomething called rEFInd I had to install to help the process. There is also a boot option to hold another key to specify which alternate storeage device you wanted to boot. c was CD - the only device I used. Maybe u will get you to your USB. My other suggestion: is there a boot flag on the USB somewhere, perhaps the efi partition? -- All the best Keith Bainbridge keith.bainbridge.3216@gmail.com 0447 667 468
[toc] | [prev] | [next] | [standalone]
| From | didier gaumet <didier.gaumet@gmail.com> |
|---|---|
| Date | 2021-09-01 10:20 +0200 |
| Subject | Re: Install Debian 10 amd64 onto USB flash drive with and for Macintosh |
| Message-ID | <CStDr-7gp-5@gated-at.bofh.it> |
| In reply to | #239548 |
Hello, Le mardi 31 août 2021 à 15:31 -0700, David Christensen a écrit : [...] > I would like to install Debian 10 onto a USB flash drive as a > self-contained, bootable, full, live installation that I use with > this > and other Intel-based Macintosh computers. You should even be able to use it on any x86-64 PC if you install most firmwares [...] > If I now power up the machine with the buster-mac USB flash drive > installed, Debian starts. > > > If I now power up the machine without the buster-mac USB flash drive > installed, I see: > > GNU GRUB version 2.02+dfsg1-20+deb10u4 > > Minimal BASH-like line editing is supported. For the first word, > TAB > lists possible command completions. Anywhere else TAB lists > possible > device or file completions. > > grub> [...] I do not know where Grub has been installed but it has probably not been installed with the right option(s) - If I recall correctly, an expert install will ask you where to install grub and if it is a removable media - Booting the installation media with the rescue option will probably offer the possibility to reinstall grub with the desired option(s) - And you could simply boot your newly created Debian USB stick and reinstall Grub at the right place (specify the USB stick) with the right option(s). see grub-install manpage, options --removable and if not sufficient -- force-extra-removable
[toc] | [prev] | [next] | [standalone]
| From | David Christensen <dpchrist@holgerdanske.com> |
|---|---|
| Date | 2021-09-02 01:10 +0200 |
| Subject | Re: Install Debian 10 amd64 onto USB flash drive with and for Macintosh |
| Message-ID | <CSHwK-7s4-9@gated-at.bofh.it> |
| In reply to | #239553 |
On 9/1/21 1:15 AM, didier gaumet wrote:
> Hello,
Hello. :-)
> Le mardi 31 août 2021 à 15:31 -0700, David Christensen a écrit :
> [...]
>> I would like to install Debian 10 onto a USB flash drive as a
>> self-contained, bootable, full, live installation that I use with
>> this
>> and other Intel-based Macintosh computers.
> - Booting the installation media with the rescue option will probably
> offer the possibility to reinstall grub with the desired option(s)
<POINT_A, see below>
<Insert debian-10.10.0-amd64-xfce-CD-1 USB flash drive>
<Power up>
Debian GNU/Linux 10.10.0
Debian GNU/Linux UEFI Installer menu -> Advanced options... -> Rescue mode
Language -> C
Continent or region -> North America
Country, territory or area -> United States
Keymap to use -> American English
Load missing firmward from removable media?
<insert USB flash drive with Debian 10.10.0 firmware>
-> Yes
Load missing firmware from removable media?
<remove USB flash drive with Debian 10.10.0 firmware>
<insert USB flash drive with Debian instance>
-> No
Wireless network -> wifi.tracy.holgerdanske.com
Wireless network type for w1p3s0 -> WPA/WPA2 PSK
WPA/WPA2 passphrase for wireless device w1p3s0 -> ********
Hostname -> dpchrist-mbp
Domain name -> tracy.holgerdanske.com
Select your time zone -> Pacific
<POINT_B, see below>
Device to use as a root file system -> /dev/sdb3
The installed system appears to use a separate /boot/efi partition.
It is normally a good idea to mount it as it will allow operations such
as reinstalling the boot loader. However, if the file system on
/boot/efi is corrupt then you may want o avoid mounting it.
Mount separate /boot/efi partition? -> No
Rescue operations -> Execute shell in /dev/sda3
Executing a shell -> Continue
# blkid /dev/sdb1
/dev/sdb1: UUID-"D19A-5B1E" TYPE="vfat" PARTLABEL="buster-mac-esp"
PARTUUID="447e5600-211c-4abd-ba38-c03969160b28"
# vi /etc/fstab
<comment out existing /boot/efi line>
<add the following line>
UUID=D19A-5B1E /boot/efi vfat umask=0077 0 1
# mount /boot/efi
# exit
Rescue operations -> Reinstall GRUB boot loader
Device for boot loader installation -> /dev/sdb1
Rescue operations -> Reboot the system
GNU GRUB version 2.02+dfsg1-20+deb10u4 -> Debian GNU/Linux
<Debian 10 graphical login screen>
-> Shutdown
<Wait for system to power off>
<Remove debian-10.10.0-amd64-xfce-CD-1 USB flash drive>
Boot debian-mac and login as root via SSH:
2021-09-01 15:03:56 root@buster-mac ~
# mount | grep '.dev.sd'
/dev/sdb3 on / type ext4 (rw,relatime,errors=remount-ro)
/dev/sdb1 on /boot/efi type vfat
(rw,relatime,fmask=0077,dmask=0077,codepage=437,iocharset=ascii,shortname=mixed,utf8,errors=remount-ro)
Mount device for /boot/efi is wrong -- still using internal SSD, not USB
flash drive.
Troubleshoot:
2021-09-01 15:05:09 root@buster-mac ~
# blkid /dev/sda1 /dev/sdb1
/dev/sda1: LABEL_FATBOOT="EFI" LABEL="EFI" UUID="67E3-17ED" TYPE="vfat"
PARTLABEL="EFI System Partition"
PARTUUID="78155464-748d-48f6-938c-a1341b1ae49a"
/dev/sdb1: UUID="D19A-5B1E" TYPE="vfat" PARTLABEL="buster-mac-esp"
PARTUUID="447e5600-211c-4abd-ba38-c03969160b28"
2021-09-01 15:05:34 root@buster-mac ~
# grep efi /etc/fstab
# /boot/efi was on /dev/sda1 during installation
#UUID=67E3-17ED /boot/efi vfat umask=0077 0 1
UUID=D19A-5B1E /boot/efi vfat umask=0077 0 1
Shutdown. Remove buster-mac USB flash drive. Boot
debian-10.10.0-amd64-xfce-CD-1 USB flash drive. Follow above steps
POINT_A through POINT_B, above, then continue:
Device to use as a root file system -> /dev/sdd3
Mount separate /boot/efi partition? -> No
Rescue operations -> Force GRUB installation to the EFI removable media path
Force GRUB installation to the EFI removable media path? -> Yes
Rescue operations-> Reboot system
GNU GRUB version 2.02+dfsg1-20+deb10u4 -> Debian GNU/Linux
<Debian 10 graphical login screen>
-> Shutdown
<Wait for system to power off>
<Remove debian-10.10.0-amd64-xfce-CD-1 USB flash drive>
Boot debian-mac and login as root via SSH:
2021-09-01 15:22:28 root@buster-mac ~
# mount | grep '.dev.sd'
/dev/sdb3 on / type ext4 (rw,relatime,errors=remount-ro)
/dev/sdb1 on /boot/efi type vfat
(rw,relatime,fmask=0077,dmask=0077,codepage=437,iocharset=ascii,shortname=mixed,utf8,errors=remount-ro)
Wrong -- internal SSD ESP is mounted at /boot/efi.
Shutdown Debian USB flash drive instance.
Power up. Press and hold Option. Disk window now shows internal SSD
and "EFI Boot" disk. Select "EFI Boot". Debian instance boots. Login
as root via SSH:
2021-09-01 15:26:26 root@buster-mac ~
# mount | grep '.dev.sd'
/dev/sdb3 on / type ext4 (rw,relatime,errors=remount-ro)
/dev/sdb1 on /boot/efi type vfat
(rw,relatime,fmask=0077,dmask=0077,codepage=437,iocharset=ascii,shortname=mixed,utf8,errors=remount-ro)
Correct -- USB flash drive ESP is mounted at /boot/efi.
Shutdown, remove buster-mac USB flash drive, and power up -- macOS boots.
So, now macOS boots by default if the debian-mac USB flash drive is not
inserted, I can boot the debian-mac USB flash drive using the flash
drive ESP if I use Option, but the internal SSD ESP will be used if I
insert the debian-mac USB flash drive and boot without Option.
Boot debian-mac USB flash drive via Option. Mount the SSD ESP. Move
aside the "debian" tree:
2021-09-01 15:34:50 root@buster-mac ~
# mount /dev/sda1 /mnt
2021-09-01 15:34:57 root@buster-mac ~
# mount | grep sda
/dev/sda1 on /mnt type vfat
(rw,relatime,fmask=0022,dmask=0022,codepage=437,iocharset=ascii,shortname=mixed,utf8,errors=remount-ro)
2021-09-01 15:35:42 root@buster-mac ~
# mv /mnt/EFI/debian /mnt/EFI/debian-disabled
Shutdown.
Power up with debian-mac USB flash drive inserted. Do not press Option.
buster-mac boots. /dev/sdb1 is mounted at /boot/efi. Shutdown.
2021-09-01 15:50:03 root@buster-mac ~
# mount | grep '.dev.sd'
/dev/sdb3 on / type ext4 (rw,relatime,errors=remount-ro)
/dev/sdb1 on /boot/efi type vfat
(rw,relatime,fmask=0077,dmask=0077,codepage=437,iocharset=ascii,shortname=mixed,utf8,errors=remount-ro)
2021-09-01 15:50:08 root@buster-mac ~
# t /boot/efi
/boot/efi
`-- EFI
|-- BOOT
| |-- BOOTX64.EFI
| |-- fbx64.efi
| `-- grubx64.efi
`-- debian
|-- BOOTX64.CSV
|-- fbx64.efi
|-- grub.cfg
|-- grubx64.efi
|-- mmx64.efi
`-- shimx64.efi
3 directories, 9 files
2021-09-01 15:50:16 root@buster-mac ~
# cat /etc/fstab
# /etc/fstab: static file system information.
#
# Use 'blkid' to print the universally unique identifier for a
# device; this may be used with UUID= as a more robust way to name devices
# that works even if disks are added and removed. See fstab(5).
#
# <file system> <mount point> <type> <options> <dump> <pass>
# / was on /dev/sdd3 during installation
UUID=a2ecf948-c990-44fe-a098-b2df2d3ff0d7 / ext4
errors=remount-ro 0 1
# /boot/efi was on /dev/sda1 during installation
#UUID=67E3-17ED /boot/efi vfat umask=0077 0 1
UUID=D19A-5B1E /boot/efi vfat umask=0077 0 1
# swap was on /dev/sdd2 during installation
UUID=04ac272d-2680-49a1-b0a9-e59c917c1286 none swap sw
0 0
Remove debian-mac USB flash drive. Power up. macOS boots.
Thank you for your help. :-)
David
[toc] | [prev] | [next] | [standalone]
| From | David Wright <deblis@lionunicorn.co.uk> |
|---|---|
| Date | 2021-09-03 02:40 +0200 |
| Subject | Re: Install Debian 10 amd64 onto USB flash drive with and for Macintosh |
| Message-ID | <CT5pn-61K-11@gated-at.bofh.it> |
| In reply to | #239578 |
[Multipart message — attachments visible in raw view] — view raw
On Wed 01 Sep 2021 at 16:00:13 (-0700), David Christensen wrote: [three long posts] That was very useful. I've condensed it into a file (attached) for my own use. The footnotes are notes, guesses and queries. My main question is — there are three identical listings taken at different times; all say: > # mount | grep '.dev.sd' > /dev/sdb3 on / type ext4 (rw,relatime,errors=remount-ro) > /dev/sdb1 on /boot/efi type vfat (rw,relatime,fmask=0077,dmask=0077,codepage=437,iocharset=ascii,shortname=mixed,utf8,errors=remount-ro) and yet two are labelled as wrong, and the third as correct. I found the device letters a bit confusing when you're running the rescue system. AFAICT, sda is always the SSD. So I was perplexed by "Rescue operations -> Execute shell in /dev/sda3" because your SSD only appeared to have two partitions in the OP. What seems to be missing from the account is any consideration of the so-called NVRAM variables, about which I know nothing. I'm still working through how hiding the EFI/debian tree makes the option-less booting suddenly work, but then, I don't know how closely the Option key corresponds to pressing F12 on, say, a Dell PC, which is how you set the device boot order. (I haven't touched a Mac since the last century when they were in a little AiO box.) Cheers, David.
[toc] | [prev] | [next] | [standalone]
| From | David Christensen <dpchrist@holgerdanske.com> |
|---|---|
| Date | 2021-09-03 07:40 +0200 |
| Subject | Re: Install Debian 10 amd64 onto USB flash drive with and for Macintosh |
| Message-ID | <CTa5I-W2-3@gated-at.bofh.it> |
| In reply to | #239604 |
On 9/2/21 5:37 PM, David Wright wrote:
> On Wed 01 Sep 2021 at 16:00:13 (-0700), David Christensen wrote:
>
> [three long posts]
>
> That was very useful. I've condensed it into a file (attached) for
> my own use. The footnotes are notes, guesses and queries.
I tried to file a bug report against the debian-installer complaining
about the "Install" option not allowing me to choose where to put GRUB,
thereby breaking macOS; but I don't see it yet on bugs.debian.org.
STFW there are some resources for installing Debian onto a Macintosh
internal SSD, but nothing recent for installing Debian onto a Macintosh
external drive -- USB, SD card, or Thunderbolt.
> My main question is — there are three identical listings taken at
> different times; all say:
>
>> # mount | grep '.dev.sd'
>> /dev/sdb3 on / type ext4 (rw,relatime,errors=remount-ro)
>> /dev/sdb1 on /boot/efi type vfat (rw,relatime,fmask=0077,dmask=0077,codepage=437,iocharset=ascii,shortname=mixed,utf8,errors=remount-ro)
>
> and yet two are labelled as wrong, and the third as correct.
Thank you for your sharp eyes.
Without repeating those many hours of unpleasant work to confirm or deny
the console sessions and/or the intermediate conclusions, at this point
it does appear that I misread the output from the first two runs of the
following command in my post of 9/1/21 4:00 PM:
# mount | grep '.dev.sd'
As always, I will have to be careful when making decisions based upon a
single letter.
RTFM mount(8), it talks about feeding UUID's into mount as command-line
arguments; but I do not see a way to have mount output UUID's (?).
> I found the device letters a bit confusing when you're running the
> rescue system. AFAICT, sda is always the SSD. So I was perplexed
> by "Rescue operations -> Execute shell in /dev/sda3" because
> your SSD only appeared to have two partitions in the OP.
The Debian Installer sessions were manually transcribed, and could
easily contain typographical errors.
> What seems to be missing from the account is any consideration of
> the so-called NVRAM variables, about which I know nothing.
My Debian posts did not include my prior ordeals making a bootable macOS
installation USB flash drive, logging out of Apple services, erasing the
SSD, resetting NVRAM, installing macOS Big Sur, etc., per the following
Apple URL's and lots more STFW:
https://support.apple.com/en-us/HT201372
https://support.apple.com/en-us/HT201065
https://support.apple.com/en-us/HT208496
(I never did figure out how to do a Secure Erase of the SSD.)
> I'm
> still working through how hiding the EFI/debian tree makes the
> option-less booting suddenly work, but then, I don't know how
> closely the Option key corresponds to pressing F12 on, say, a
> Dell PC, which is how you set the device boot order.
> (I haven't touched a Mac since the last century when they were
> in a little AiO box.)
The contents of the SSD ESP filesystem are not ideal and I still do not
understand how the MacBook Pro firmware finds and/or chooses between
boot loaders.
David
[toc] | [prev] | [next] | [standalone]
| From | David Wright <deblis@lionunicorn.co.uk> |
|---|---|
| Date | 2021-09-09 05:50 +0200 |
| Subject | Re: Install Debian 10 amd64 onto USB flash drive with and for Macintosh |
| Message-ID | <CVjey-2gf-5@gated-at.bofh.it> |
| In reply to | #239607 |
On Thu 02 Sep 2021 at 22:29:34 (-0700), David Christensen wrote: > On 9/2/21 5:37 PM, David Wright wrote: > > On Wed 01 Sep 2021 at 16:00:13 (-0700), David Christensen wrote: > > > > [three long posts] > > > > That was very useful. I've condensed it into a file (attached) for > > my own use. The footnotes are notes, guesses and queries. > > > > My main question is — there are three identical listings taken at > > different times; all say: > > > > > # mount | grep '.dev.sd' > > > /dev/sdb3 on / type ext4 (rw,relatime,errors=remount-ro) > > > /dev/sdb1 on /boot/efi type vfat (rw,relatime,fmask=0077,dmask=0077,codepage=437,iocharset=ascii,shortname=mixed,utf8,errors=remount-ro) > > > > and yet two are labelled as wrong, and the third as correct. > > Thank you for your sharp eyes. Just a consequence of rewriting it for my own use, which meant crosschecking everything. > Without repeating those many hours of unpleasant work to confirm or > deny the console sessions and/or the intermediate conclusions, at this > point it does appear that I misread the output from the first two runs > of the following command in my post of 9/1/21 4:00 PM: > > # mount | grep '.dev.sd' > > As always, I will have to be careful when making decisions based upon > a single letter. Yes, I try to make it possible to use collateral information as a check. For example, years ago I would make all my partitions have slightly different sizes, because sizes were typically reported (and LABELs, PARTLABELs, UUIDs etc weren't). > RTFM mount(8), it talks about feeding UUID's into mount as > command-line arguments; but I do not see a way to have mount output > UUID's (?). I think you have to use a command like lsblk -l --fs or lsblk -l -o NAME,PARTUUID,PARTLABEL to get whatever you might want. If you only have busybox, then I think you're stuck with looking through the output from ls -lR /dev/disk for what you want. > (I never did figure out how to do a Secure Erase of the SSD.) I guess one can sacrifice a write-cycle and just zero the whole thing. > The contents of the SSD ESP filesystem are not ideal and I still do > not understand how the MacBook Pro firmware finds and/or chooses > between boot loaders. I read things like this: "With the introduction of System Integrity Protection in OS X 10.11 (El Capitan), Apple has locked down some of the things you can do with the nvram command. "Specifically, you can no longer set any variables that belong to the Efi GUID, like BootOrder. …"¹ but as I said, they don't mean a lot to me. ¹ https://wikileaks.org/ciav7p1/cms/page_26968084.html Cheers, David.
[toc] | [prev] | [next] | [standalone]
| From | Andrei POPESCU <andreimpopescu@gmail.com> |
|---|---|
| Date | 2021-09-11 17:40 +0200 |
| Subject | Re: Install Debian 10 amd64 onto USB flash drive with and for Macintosh |
| Message-ID | <CWdgJ-4pU-5@gated-at.bofh.it> |
| In reply to | #239607 |
[Multipart message — attachments visible in raw view] — view raw
On Jo, 02 sep 21, 22:29:34, David Christensen wrote: > > The contents of the SSD ESP filesystem are not ideal and I still do not > understand how the MacBook Pro firmware finds and/or chooses between boot > loaders. From my limited understanding of EFI the stick should have its own ESP with grub on it, preferably installed in the "removable path", so that it's always considered for booting. This should all be doable from the installer, possibly in expert mode. Hope this helps, Andrei -- http://wiki.debian.org/FAQsFromDebianUser
[toc] | [prev] | [standalone]
Back to top | Article view | linux.debian.user
csiph-web