From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from list by lists.gnu.org with archive (Exim 4.71) id 1aBoOT-0008CL-Ih for mharc-grub-devel@gnu.org; Wed, 23 Dec 2015 13:44:13 -0500 Received: from eggs.gnu.org ([2001:4830:134:3::10]:58859) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aBoOQ-0008Ai-Jg for grub-devel@gnu.org; Wed, 23 Dec 2015 13:44:11 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1aBoOP-00015c-Jw for grub-devel@gnu.org; Wed, 23 Dec 2015 13:44:10 -0500 Received: from mail-lb0-x22e.google.com ([2a00:1450:4010:c04::22e]:35350) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aBoOK-00014v-A1; Wed, 23 Dec 2015 13:44:04 -0500 Received: by mail-lb0-x22e.google.com with SMTP id bc4so50726295lbc.2; Wed, 23 Dec 2015 10:44:03 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=subject:to:references:from:message-id:date:user-agent:mime-version :in-reply-to:content-type:content-transfer-encoding; bh=C3DMiroWEs8XDaTdXkOrJQaa5/R2unH6IO6DTWdag+U=; b=UoVXHsKgJiwjZrlRCTeThwswoX3F6BpMU/w8xB2UCjTPW+P7QJlHUGttsClPitJ1fi mlXLN/MTvo7HpPIWwV+HD+0PMN6UtGa6iXDDKqaN13XwFAuUHsXnSj1DtPbOWKIKab4Z mHXp5E+kL6oc/b9KZxFI9mHfM0KmOLFnd9pL9o8khR/pt6zr0q61o8g/6wbDPZRzqRUA Dp11yqAVQz6LstjCnOJm+vb6Dw6wB4F0RjGmO8JVMjiANg4T+jNDJpJEn0aHN3ibDMR1 lJ4J2ahQ8fhXOqVGB8eyp6cp9ozQUUhTnzY7+0y2Fxk/PENZ9mgybIuZyxdUFFEgYZSG 1ydg== X-Received: by 10.112.138.135 with SMTP id qq7mr11040149lbb.21.1450896242992; Wed, 23 Dec 2015 10:44:02 -0800 (PST) Received: from [192.168.1.41] (ppp91-76-25-247.pppoe.mtu-net.ru. [91.76.25.247]) by smtp.gmail.com with ESMTPSA id k189sm6652821lfd.12.2015.12.23.10.44.01 (version=TLSv1/SSLv3 cipher=OTHER); Wed, 23 Dec 2015 10:44:02 -0800 (PST) Subject: Re: grub-mkrescue does not boot on older Macs as USB stick To: The development of GNU GRUB , bug-xorriso@gnu.org References: <5679AC5E.2080300@gmail.com> From: Andrei Borzenkov X-Enigmail-Draft-Status: N1110 Message-ID: <567AEB71.7020208@gmail.com> Date: Wed, 23 Dec 2015 21:44:01 +0300 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Thunderbird/38.4.0 MIME-Version: 1.0 In-Reply-To: <5679AC5E.2080300@gmail.com> Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 2a00:1450:4010:c04::22e X-BeenThere: grub-devel@gnu.org X-Mailman-Version: 2.1.14 Precedence: list Reply-To: The development of GNU GRUB List-Id: The development of GNU GRUB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 23 Dec 2015 18:44:11 -0000 22.12.2015 23:02, Andrei Borzenkov пишет: > I tested stock grub-mkrescue on MacBook 3,1 (late 2007, Core 2 Duo) and > iMac 9.1 (2009, same CPU) as USB stick. Neither boots; moreover, > inserting USB stick when boot manager is shown hangs system (it stops > reacting to mouse/keyboard); if stick is inserted during boot it never > gets as far as even showing boot manager. > > Alexander reported something similar for 2007 Macs. > > Stick is not detected even when inserted under OS X. MacBook runs 10.7 > and reports that USB stick is not readable and suggests to iniitialize > it; iMac runs 10.9 and simply ignores it (may be I do not know where to > look). > > I tried two different USB and one of them boots fine here on Dell > Latitude E5450 as EFI so I do not think both of them are defect. Of > course, they are not of finest quality ... > > Same image as CD boots (I tried only MacBook but do not have reasons to > think that iMac will not boot). It presents three choices - two EFI and > one Windows. Windows ends up in presenting 1, 2 menu (without any > additional explanation) and not accepting any input. This is known > problem with legacy El Torito boot. First EFI boots; checking $cmdpath > it boots from HFS+ partition. Second EFI does not boot and falls through > to default boot order. When I try to chainload bootx64.efi manually (I > have dual OS X/openSUSE on it) it actually boots fine. I /think/ it > tries to load \EFI\Boot\boot.efi which is 32 bit only. I need to test > with removed boot.efi and with fat image. > It is red herring. Mac correctly loads bootx64.efi and does not need or use startup.nsh (I do not think it even has EFI Shell which interprets this file). > I do not know if mkrescue image ever booted as USB on Mac. Alexander > says it does on modern Mac; anyone ever tried it on earlier models? > OK, it turned out to be not related to xorriso, but for the record ... Mac does not like FAT created by mformat. I can reproduce it easily by creating single MSDOS partition on USB stick of type 0xef size 2880K, formatting it with same options as grub-mkrescue: sudo mformat -C -f 2880 -L 16 -i /dev/sdb1 :: and copying bootx64.efi into \EFI\BOOT on it. The same partition formatted with mkfs -t fat works like a charm. Both Porteus and openSUSE CD (which correctly boot) have ESP created by mkfs.fat. TBH I think that precreating FAT once and shipping image with GRUB is the most simple solution. It can be empty, we can dd files later. Ideas?