You are not logged in.

#1 2015-06-05 17:04:20

jwhendy
Member
Registered: 2010-04-01
Posts: 621

Trying to boot arch from win7 with EasyBCD; "boot device not found"

EDIT: title was 'Dual boot with Win7, easybcd + syslinux, getting "Boot error"'. Narrowed down the issue to something unrelated to Arch, and felt this was more accurate. The Arch install is sound, it's getting win7/EasyBCD to load it that's the issue.

I got a new work computer and am trying to recreate my formerly successful setup, which I documented here some time ago. Unfortunately... I'm having issues. Just a note up front from scouring the internet for ideas: I cannot use syslinux (or any other bootloader) to chainload Win7 vs. the other way around! The computer drive is encrypted with McAfee Endpoint Encryption, and doing anything whatsoever with the MBR from outside of Windows will brick my computer. Just wanted to add that, as almost all issues involving dual boot inevitably bring about the suggestion to "just chainload windows from grub/syslinux/etc."

With that out of the way, here's the process I used:

drive setup

Here's the partition scheme:
- /dev/sda1: SYSTEM (pre-existing)
- /dev/sda2: C:, Win7 (pre-existing)
- /dev/sda3: /boot, ext2 (created)
- /dev/sda4: /, encrypted Arch root, cryptsetup/ext4 (created)

My process for creating the partitions is as follows:
- shrunk C: down from the Win7 built-in partition utility
- created two unformatted partitions with no drive letter using Minitool Partition Wizard, setting the partition ID to 0x83 for both
- booted from USB drive of the Arch installation .iso (downloaded Friday 5/29)
- booted x86_64 arch

# fdisk -l
Disk /dev/sda: 238.5 GiB, 256060514304 bytes, 500118192 sectors
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: 0x1e6513b3

Device     Boot     Start       End   Sectors   Size Id Type
/dev/sda1  *         2048   2101247   2099200     1G  7 HPFS/NTFS/exFAT
/dev/sda2         2101248 177278975 175177728  83.5G  7 HPFS/NTFS/exFAT
/dev/sda3       177278976 177541119    262144   128M 83 Linux
/dev/sda4       177541120 500103167 322562048 153.8G 83 Linux

# modprobe dm_crypt
# cryptsetup -c aes-xts-plain64 -s 512 -h sha512 -i 5000 -y luksFormat /dev/sda4
# cryptsetup open /dev/sda4 root
# mkfs.ext4 /dev/mapper/root
# mkfs.ext2 /dev/sda3

installation

I just followed the Arch installation guide but documented my steps to a text file just to be sure...

# mount /dev/mapper/root /mnt
# mkdir /mnt/boot
# mount /dev/sda3 /mnt/boot

### connect to internet
# pacstrap /mnt base

# genfstab -p /mnt >> /mnt/etc/fstab

# arch-chroot /mnt

# echo arch_zbook > /etc/hostname

# ln -sf /usr/share/zoneinfo/America/Chicago /etc/localtime

### uncomment en_US.utf-8 in /etc/locale.gen
# locale-gen
# echo LANG=en_US.UTF-8 > /etc/locale.conf

### add encrypt before "filesystem" in /etc/mkinitcpio.conf hooks
# mkinitcpio -p linux

# passwd

# pacman -S syslinux
# cp -r /usr/lib/syslinux/bios/*.c32 /boot/syslinux
# extlinux -i /boot
### the above echoes "/boot is device /dev/sda3"

Then I edited /boot/syslinux/syslinux.cfg:

LABEL arch
	MENU LABEL Arch Linux
	LINUX ../vmlinuz-linux
	APPEND root=/dev/mapper/root cryptdevice=/dev/sda4:root crypto=sha512:aes-xts-plain64:512:: rw
	INITRD ../initramfs-linux.img

---
EDIT: I deleted the contents of /boot, reinstalled syslinux, linux, and mkinitcpio, and repeated the above with `extlinux -i /boot/syslinux`, noting that syslinux.cfg points to ../vmlinuz-linux. Same result.
---

Just to double check proper syslinux setup, here's the dir contents:

# ls /boot
initramfs-linux-fallback.img
initramfs-linux.img
ldlinux.c32
ldlinux.sys
lost+found
syslinux
vmlinuz-linux

# ls /boot/syslinux
cat.c32
chain.c32
cmd.c32
cmenu.c32
config.c32
cptime.c32
cpu.c32
cpuid.c32
cpuidtest.c32
debug.c32
dhcp.c32
disk.c32
dmi.c32
dmitest.c32
elf.c32
ethersel.c32
gfxboot.c32
gpxecmd.c32
hdt.c32
hexdump.c32
host.c32
ifcpu64.c32
ifcpu.c32
ifmemdsk.c32
ifplop.c32
kbdmap.c32
kontron_wdt.c32
ldlinux.c32
lfs.c32
libcom32.c32
libgpl.c32
liblua.c32
libmenu.c32
libutil.c32
linux.c32
ls.c32
lua.c32
mboot.c32
meminfo.c32
menu.c32
pci.c32
pcitest.c32
pmload.c32
poweroff.c32
prdhcp.c32
pwd.c32
pxechn.c32
reboot.c32
rosh.c32
sanboot.c32
sdi.c32
sysdump.c32
syslinux.c32
syslinux.cfg
vesa.c32
vesainfo.c32
vesamenu.c32
vpdtest.c32
whichsys.c32
zzjson.c32

EasyBCD and boot attempt

At this point, exited the arch-chroot, unmounted/closed my partitions, and rebooted into Win7. Using EasyBCD, I added a entry for a syslinux bootloader, pointing it to "Partition 3 (Linux - 128MiB)."

I reboot, get the EasyBCD menu, but then the lone words "Boot error" on a black screen. Any key press takes me to some sort of BIOS boot thingy which tells me to "Please install an operating system!" I think this is something built into the laptop BIOS, not anything from the syslinux side. Selecting "Boot existing OS" from the Arch install USB doesn't give me any options at all.

From what I can tell, I'm using the same procedure that I ended up with on this former troubleshooting exercise.

Thoughts

I'm really struggling to understand what I'm doing wrong. I originally had a couple variations on logical/extended partitions since I need my eventual setup to hold a shared TrueCrypt partition so I can access my work files from both Win7 and arch. I tried /boot as primary and Arch/TC as logicals, as well as a primary TC partition with boot/root as a logical drive combination. I've simplified to just primary partitions (as shown above) to troubleshoot.

It's quite difficult to troubleshoot as I don't know if this is an installation issue or an EasyBCD one. Is there a way to manually try and boot my HD arch install from the install USB? I wanted to try that using the "Boot existing OS" option, but am wondering if it fails since only /dev/sda1 features a bootable flag and it's encrypted so only the HP BIOS can handle it? I thought about making /dev/sda3 bootable, but from my reading I can only have one bootable flag on a Windows system.

On that note, I checked my BIOS settings and the MBR is set to "Legacy mode" vs. the othe UEFI alternatives, so I don't think that's an issue. I also used blkid to confirm that it's using an MBR (output was "dos").

I will try UUIDs in /etc/fstab and syslinux next, as there are some other posts (example) talking about this as a potential issue (and, indeed, I sometimes get my HD as /dev/sdb* when booting from the arch USB drive. I can also try grub2 in case it's a syslinux issue.

Thanks for any ideas/suggestions. Does anything look awry in my description/setup above? I can chroot and do stuff just fine... so I think the install appears to be sound; it's just booting it!

Last edited by jwhendy (2015-06-06 04:38:09)

Offline

#2 2015-06-05 18:34:12

jwhendy
Member
Registered: 2010-04-01
Posts: 621

Re: Trying to boot arch from win7 with EasyBCD; "boot device not found"

Follow up inquiries:

- would it be recommended to pursue on with syslinux? I looked into using grub2 as I have no experience with it, and it sounds like installing to a partition (which is what I have to do) is discouraged.
- how might I use my Arch usb disk to try and manually boot /dev/sda3? I tried TAB on the x86_64 entry, but don't recognize the format or some of the options. What is the install USB bootloader, and can I tweak it's default entry to make a analog of my syslinux settings (root=blah cryptdevice=blah etc)?

If I can track down another drive big enough, I'll install to a flash drive as I did above and test that. Unfortunately, this computer doesn't have an optical drive so I need to do USB -> USB. That's another way I can do a sanity check on the above.

I'd like to pinpoint my issue to either syslinux/arch install or EasyBCD. If I can boot the system successfully, I'll leave all you nice Arch folks alone and go try the EasyBCD forums instead. The activity rate is much lower over there, so I don't anticipate a prompt response like I tend to get here... Thanks!

Offline

#3 2015-06-06 01:45:06

jwhendy
Member
Registered: 2010-04-01
Posts: 621

Re: Trying to boot arch from win7 with EasyBCD; "boot device not found"

Another update... I tried to further simplify by ditching encryption (for now), wiping the dedicated boot partition, and just installing Arch to /dev/sda3 (mounted to /mnt and following the same procedure above). I get the same result, and now know the error is coming from the computer itself (as in BIOS/HP/whatever), not syslinux. When I press a key at the "Boot error" screen, I'm taken to another screen which says "BootDevice not found," like this.

So, it looks like whatever it's thinking should be there isn't. I'm really out of my league on this, having no experience with BIOS/low-level stuff. In googling around, this error comes up in forums for HP-owning folks (this is an HP Zbook 15), and especially those trying to install an SSD... so experiences are seeming to jive. Solutions/suggestions include:
- Setting BIOS to legacy vs. UEFI (mine is in legacy mode already)
- Setting the drive mode to RAID (vs. AHCI)
- Switching a cable connecting the SSD (youtube link in last post here

My next step will be to install syslinux to a thumb drive and see if I can boot to it and point it at my HD partition. If that works (and I can't resolve the issues above), I guess I'll just workaround by having a dedicated boot drive, or more likely trying to install syslinux to an sdcard that I'll leave permanently in the computer. No idea what I'm doing at this point, just trying stuff!

Suggestions are more than welcome if anything comes to mind!

Offline

#4 2015-06-06 04:24:23

jwhendy
Member
Registered: 2010-04-01
Posts: 621

Re: Trying to boot arch from win7 with EasyBCD; "boot device not found"

A bit of progress, though this couldn't be much more awful in my opinion. Installed Arch to an sdcard to use as a bootloader, only to find that I can't boot from an sdcard, even though the HP docs say there's an sdcard boot option in the BIOS (which there's not). If the BIOS were in UEFI mode, there is an sdcard option listed in the boot order, but not in legacy mode. Sigh.

I don't have another sdcard laying around that's big enough to install Arch on, as I'm using my sole 8g drive for the installation media (and no optical drive). Sigh.

I did, however, through trial and error get my sdd arch install to boot using the installation drive's "boot existing OS" option! Took me a while to figure it out. In my opinion the drive/partition numbering is quite odd. Using the Hardware Information tool, the usb stick shows up as the first drive (so I'd assume hd0), but it can't be as "hd0 3" got me into the sdd installation. I'd have assumed hd0 0 was /dev/sda1, but that must be incorrect, as hd0 3 is /dev/sda3.

So, where I'm at now:
- going to re-partition how I originally intended (with truecrypt shared storage as a primary partition and boot/root as logical partitions)
- reinstall arch
- try to boot using the above procedure from the installation media

If that goes well, I'll try to find some teensy tiny usb stick to use as a bootloader device unless someone has any insights on why I can't boot by chainloading from Windows. I think at this point I've narrowed it down to a BIOS or drive numbering or EasyBCD issue, so maybe this post isn't a good fit for the Arch forums after all. Sorry for all the noise/updates... just wanted to provide the updated information as I uncovered it.

Thanks if you have any ideas or things I could try.

Offline

Board footer

Powered by FluxBB