> On Fri, Aug 3, 2012 at 3:09 PM, Torfinn Ingolfsen > <torfinn.ingolfsen@getmail.no> wrote: > > Just a short update on this machine (Acer Aspire X1470) and the GPT / UEFI situation.> > Today I set up another partition, EFI system partition. The partyitions now looks like this: > > root@kg-vm2# gpart show ada0 > > => 34 250069613 ada0 GPT (119G) > > 34 128 1 freebsd-boot (64k) > > 162 119537664 2 freebsd-ufs (57G) > > 119537826 8388608 3 freebsd-swap (4.0G) > > 127926434 121634816 4 freebsd-ufs (58G) > > 249561250 204800 5 efi (100M) > > 249766050 303597 - free - (148M)> > I formatted the partition like this: > > root@kg-vm2# newfs_msdos -F32 /dev/ada0p5 > > newfs_msdos: trim 50 sectors to adjust to a multiple of 63 > > /dev/ada0p5: 204512 sectors in 12782 FAT32 clusters (8192 bytes/cluster) > > BytesPerSec=512 SecPerClust=16 ResSectors=32 FATs=2 Media=0xf0 SecPerTrack=63 Heads=16 HiddenSecs=0 HugeSectors=204750 FATsecs=100 RootCluster=2 FSInfo=1 > +Backup=2> > I have tried putting an EFI shell on it (I got the idea from this[1] page, I have tried both the 1.0 and 2.0 x64 shell), like this: > > root@kg-vm2# mount -t msdosfs /dev/ada0p5 /mnt > > root@kg-vm2# ls -l /mnt > > total 848 > > drwxr-xr-x 1 root wheel 8192 Aug 3 14:30 EFI > > drwxr-xr-x 1 root wheel 8192 Aug 3 16:21 boot > > -rwxr-xr-x 1 root wheel 847232 Aug 3 14:56 shellx64.efi > > root@kg-vm2# ls -l /mnt/boot > > total 760 > > -rwxr-xr-x 1 root wheel 771072 Aug 3 16:23 bootx64.efi > > root@kg-vm2# ls -l /mnt/EFI > > total 16 > > drwxr-xr-x 1 root wheel 8192 Aug 3 14:30 FreeBSD > > drwxr-xr-x 1 root wheel 8192 Aug 3 15:06 boot > > root@kg-vm2# ls -l /mnt/EFI/boot > > total 760 > > -rwxr-xr-x 1 root wheel 771072 Aug 3 15:29 bootx64.efi> > but no dice - it is not working, it still prints "ERROR: No boot disk has been detected or the disk has failed." > > when I try to boot from this disk. > > How do I figure out where this UEFI firmware that Acer has put in this machine is getting it's boot manager and or boot loader from? > > I tried running 'strings -f' on the BIOS file (sorry, UEFI firmware), that got me all the EFI error messages, but nothing useful. > > Googling didn't help either.> > References: > > 1) https://wiki.archlinux.org/index.php/Unified_Extensible_Firmware_Interface> It's not clear from your message, but did you use the gpart bootcode > command to write the protective MBR and the gptboot code as documented > in the gpart(8) man page? > -- > R. Kevin Oberman, Network Engineer > E-mail: kob6558@gmail.comThe gpart bootcode command is quite apart from and unrelated to (as far as I can tell) the EFI partition. I think the EFI partition is supposed to be the first partition on a GPT-partitioned disk. I have installed FreeBSD to a USB stick, GPT-partitioned with three partitions: boot, root and swap. I used gpart bootcode command to make the USB stick bootable, there was no EFI partition in this case. This is good if FreeBSD is the only OS installed to a disk. EFI partition is to allow sharing a hard drive with multiple OS installations. Tom
On Sat, 04 Aug 2012 03:10:52 -0400 Thomas Mueller <mueller23@insightbb.com> wrote:> > On Fri, Aug 3, 2012 at 3:09 PM, Torfinn Ingolfsen > > <torfinn.ingolfsen@getmail.no> wrote: > > > Just a short update on this machine (Acer Aspire X1470) and the GPT / UEFI situation. > > > > Today I set up another partition, EFI system partition. The partyitions now looks like this: > > > root@kg-vm2# gpart show ada0 > > > => 34 250069613 ada0 GPT (119G) > > > 34 128 1 freebsd-boot (64k) > > > 162 119537664 2 freebsd-ufs (57G) > > > 119537826 8388608 3 freebsd-swap (4.0G) > > > 127926434 121634816 4 freebsd-ufs (58G) > > > 249561250 204800 5 efi (100M) > > > 249766050 303597 - free - (148M) > > > > I formatted the partition like this: > > > root@kg-vm2# newfs_msdos -F32 /dev/ada0p5 > > > newfs_msdos: trim 50 sectors to adjust to a multiple of 63 > > > /dev/ada0p5: 204512 sectors in 12782 FAT32 clusters (8192 bytes/cluster) > > > BytesPerSec=512 SecPerClust=16 ResSectors=32 FATs=2 Media=0xf0 SecPerTrack=63 Heads=16 HiddenSecs=0 HugeSectors=204750 FATsecs=100 RootCluster=2 FSInfo=1 > > +Backup=2 > > > > I have tried putting an EFI shell on it (I got the idea from this[1] page, I have tried both the 1.0 and 2.0 x64 shell), like this: > > > root@kg-vm2# mount -t msdosfs /dev/ada0p5 /mnt > > > root@kg-vm2# ls -l /mnt > > > total 848 > > > drwxr-xr-x 1 root wheel 8192 Aug 3 14:30 EFI > > > drwxr-xr-x 1 root wheel 8192 Aug 3 16:21 boot > > > -rwxr-xr-x 1 root wheel 847232 Aug 3 14:56 shellx64.efi > > > root@kg-vm2# ls -l /mnt/boot > > > total 760 > > > -rwxr-xr-x 1 root wheel 771072 Aug 3 16:23 bootx64.efi > > > root@kg-vm2# ls -l /mnt/EFI > > > total 16 > > > drwxr-xr-x 1 root wheel 8192 Aug 3 14:30 FreeBSD > > > drwxr-xr-x 1 root wheel 8192 Aug 3 15:06 boot > > > root@kg-vm2# ls -l /mnt/EFI/boot > > > total 760 > > > -rwxr-xr-x 1 root wheel 771072 Aug 3 15:29 bootx64.efi > > > > but no dice - it is not working, it still prints "ERROR: No boot disk has been detected or the disk has failed." > > > when I try to boot from this disk. > > > How do I figure out where this UEFI firmware that Acer has put in this machine is getting it's boot manager and or boot loader from? > > > I tried running 'strings -f' on the BIOS file (sorry, UEFI firmware), that got me all the EFI error messages, but nothing useful. > > > Googling didn't help either. > > > > References: > > > 1) https://wiki.archlinux.org/index.php/Unified_Extensible_Firmware_Interface > > > It's not clear from your message, but did you use the gpart bootcode > > command to write the protective MBR and the gptboot code as documented > > in the gpart(8) man page? > > -- > > R. Kevin Oberman, Network Engineer > > E-mail: kob6558@gmail.com > > The gpart bootcode command is quite apart from and unrelated to (as far as I can tell) the EFI partition.Yes, this is what I have found out too.> I think the EFI partition is supposed to be the first partition on a GPT-partitioned disk.This is not required by the specification as far as I can tell, but there are writings on the net saying that some implementations requires this (MS Win7 for example).> I have installed FreeBSD to a USB stick, GPT-partitioned with three partitions: boot, root and swap.FWIW, I also use GPT-partitoned disks on many of my other machines; they work fine. It is (so far) only this machine which has this problem.> > EFI partition is to allow sharing a hard drive with multiple OS installations.The EFI system partition is also the place where (U)EFI firmwae will look for boot loaders, in order to load operating systems. YMMV. -- Torfinn Ingolfsen <torfinn.ingolfsen@getmail.no>
On Sat, Aug 4, 2012 at 9:23 AM, Torfinn Ingolfsen <torfinn.ingolfsen@getmail.no> wrote:>> The gpart bootcode command is quite apart from and unrelated to (as far as I can tell) the EFI partition. > > Yes, this is what I have found out too. > >> I think the EFI partition is supposed to be the first partition on a GPT-partitioned disk. > > This is not required by the specification as far as I can tell, but there are writings on the net saying that some implementations > requires this (MS Win7 for example). > >http://msdn.microsoft.com/en-us/windows/hardware/gg463525.aspx Microsoft wants the GPT Disks partitions layouted as: Extensible Firmware Interface System Partition (ESP) ~100MB OEM Partition (optional) Microsoft Reserved Partition (MSR) [Drive <16GB - MSR = 32MB, Drive>= 16GB - MSR = 128MB]- used to reserve space that is later broken in to smaller partition for use by meta data (i.e. dynamic disks) Data Partitions (FAT, NTFS, ...) If these partitions (ESP, OEM and MSR) were mixed in with the Data Partions, then you would be unable to grow the filesystems. Scot