From owner-freebsd-current@FreeBSD.ORG Tue Sep 16 23:19:53 2014 Return-Path: Delivered-To: freebsd-current@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 2E4FD6B4; Tue, 16 Sep 2014 23:19:53 +0000 (UTC) Received: from mail-ig0-x230.google.com (mail-ig0-x230.google.com [IPv6:2607:f8b0:4001:c05::230]) (using TLSv1 with cipher ECDHE-RSA-RC4-SHA (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id DB362BCC; Tue, 16 Sep 2014 23:19:52 +0000 (UTC) Received: by mail-ig0-f176.google.com with SMTP id hn15so283603igb.9 for ; Tue, 16 Sep 2014 16:19:52 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:in-reply-to:references:from:date:message-id :subject:to:cc:content-type; bh=EJiYDimaY4FbrwOEb52SuYWqRdQUY0gumVmw+6DN8MQ=; b=wMT4U0B+uQLr1xCFiEG+PDWA/pCazlEwmsPnxAfcvLlnosKdQTTcnzliq2lRKNKHQN YTA3dd7aTAeCzPNSrkrBk0y2ZGSp78z+oFgRTWmO4qAAVBP3Vigv1zg3gbkhyoDSDupw 1q1z9V1tWXVIUj2E2smkZarUJF/6bPufyQp0X9yNK2RffiN/P504RdI/decY4rTGTuh8 +A3ilCX2b6oMBQ5Bcg+xsCHrXoFWwNbQ+SL/u5gdFF1Xgk1UI437ZpQuwHwigJpS/uSW TYxKfc/rYe3tcS0fda/vXZ79vYHlBCEJhYfilN154+4HJkv18DkI3fC0OhXXRSaCY/ad SMLw== X-Received: by 10.50.88.98 with SMTP id bf2mr34961731igb.11.1410909592215; Tue, 16 Sep 2014 16:19:52 -0700 (PDT) MIME-Version: 1.0 Sender: carpeddiem@gmail.com Received: by 10.107.44.196 with HTTP; Tue, 16 Sep 2014 16:19:32 -0700 (PDT) In-Reply-To: <20140917002524.5852fe14.ohartman@zedat.fu-berlin.de> References: <20140916020541.03c18d04.ohartman@zedat.fu-berlin.de> <54178607.1060305@freebsd.org> <541786BE.6010105@freebsd.org> <20140916075121.29989a53.ohartman@zedat.fu-berlin.de> <5417E20D.8070607@freebsd.org> <20140916230348.189e80cd.ohartman@zedat.fu-berlin.de> <20140917002524.5852fe14.ohartman@zedat.fu-berlin.de> From: Ed Maste Date: Tue, 16 Sep 2014 19:19:32 -0400 X-Google-Sender-Auth: 7NMG3rqRwXLUjcSkL-DX5PnDxqk Message-ID: Subject: Re: CURRENT: EFI boot failure To: "O. Hartmann" Content-Type: text/plain; charset=UTF-8 Cc: FreeBSD Current , Nathan Whitehorn , Allan Jude X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 16 Sep 2014 23:19:53 -0000 On 16 September 2014 18:25, O. Hartmann wrote: > > Besides, checking both boot1.efi and loader.efi with file() shows something like > loader.efi: PE32+ executable (EFI application) x86-64 (stripped to external PDB), for MS > Windows. So both are PECOFF format files? That is correct. >> >> boot1.efifat is a FAT filesystem image that contains a copy of >> boot1.efi as /EFI/BOOT/BOOTX64.EFI. It exists so that the installer >> can treat it as opaque bootcode, like other boot schemes. It's >> certainly possible to create a partition, use newfs_msdos to format >> it, and copy in boot1.efi instead. > > All right, here you lost me ... sorry. The partition created by the installes with type > "efi" is then the /EFI/ partition, which then contains a folder BOOT and in which the > boot1.efi is located? > As I understand, I can manually mount this partition as FAT and copy boot1.efi as > BOOTX64.EFI into it? This knowledge could come in handy if something goes very bad. Sorry, not quite; an ESP is a separate partition formatted with FAT. The file system in that partition has EFI/ in the root directory, BOOT/ under that, and BOOTX64.EFI in there. We don't (yet) mount the ESP inside of FreeBSD by default. At least some Linuxes do mount the ESP at /boot/efi, so you end up with /boot/efi/EFI/BOOT/BOOTX64.EFI. We might start doing something similar when fleshing out dual-boot configuration support. boot1.efifat is a copy (image) of the ESP, as it exists on the disk. You can see what's inside: # mdconfig -a -f /boot/boot1.efifat md0 # mount_msdosfs /dev/md0 /mnt # ls -l /mnt/efi/boot/BOOTx64.efi -rwxr-xr-x 1 root wheel 65536 Apr 26 20:43 /mnt/efi/boot/BOOTx64.efi # umount /mnt # mdconfig -d -u 0