Date: Fri, 29 May 2015 09:51:07 -0700 From: David Newman <dnewman@networktest.com> To: freebsd-questions@freebsd.org Subject: Re: Missing boot loader Message-ID: <556898FB.1080704@networktest.com> In-Reply-To: <alpine.BSF.2.20.1505290942330.2085@wonkity.com> References: <5522C5DE.1050005@networktest.com> <CA%2Bg%2BBvhB29m6w3DqrDoXmA%2Bj9VyvX_7xLRG_iKQAfVJS6ELjpQ@mail.gmail.com> <55687BE9.40803@networktest.com> <alpine.BSF.2.20.1505290942330.2085@wonkity.com>
next in thread | previous in thread | raw e-mail | index | archive | help
On 5/29/15 8:46 AM, Warren Block wrote: > On Fri, 29 May 2015, David Newman wrote: > >> On 4/6/15 9:28 PM, Olivier Nicole wrote: >> >>> My solution is >>> http://www.cs.ait.ac.th/~on/technotes/archives/2015/01/30/how-to_clone_a_freebsd_virtual_machine_on_vmware/index.html >>> >>> certainly not the best/fastest, but it works. >> >> Thanks for this. After following the clone instructions, restore appears >> to work, but the system comes up with a "Missing boot loader" error. >> >> This is perhaps because the next-to-last step from the live CD is: >> >> cd / >> mount -o rw /dev/da0p1 /mnt >> gpart bootcode -b /mnt/boot/pmbr -p /mnt/boot/gptboot -i 1 da0 >> >> And that returns "/dev/da0p1: Operation not permitted" even though da0p1 >> is the target system's root/boot partition. > > In this code, da0 is the source disk, where the bootcode files are read. > It is mounted on /mnt. So there are two reasons that gpart cannot write > bootcode to da0p1. First, it is mounted, and second, it is filesystem > partition, not a freebsd-boot partition. > > The target disk cannot be da0p1. Maybe it is a simple typo, and either > the second or third line was meant to be ada0 rather than da0. Thanks for your email. Backstory: This VM is a dump/restore clone of another machine that has no separate boot partition. Here's /etc/fstab from the source machine: /dev/ada0p2 / ufs rw 1 1 /dev/ada0p3 none swap sw 0 0 And on the new target VM: /dev/da0p1 / ufs rw 1 1 /dev/da0p2 none swap sw 0 0 I don't understand the bit about 'ada0', since 'gpart list' shows only da0 and two providers under it. The source machine has boot files in its root partition, under /boot. How can I get that working here? Thanks! dn
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?556898FB.1080704>