From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from list by lists.gnu.org with archive (Exim 4.71) id 1QApNT-0003hY-RH for mharc-grub-devel@gnu.org; Fri, 15 Apr 2011 16:12:27 -0400 Received: from eggs.gnu.org ([140.186.70.92]:54490) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QApNR-0003hO-Gl for grub-devel@gnu.org; Fri, 15 Apr 2011 16:12:26 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1QApNQ-00046w-KU for grub-devel@gnu.org; Fri, 15 Apr 2011 16:12:25 -0400 Received: from mail-ww0-f49.google.com ([74.125.82.49]:48080) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QApNQ-00041H-G9 for grub-devel@gnu.org; Fri, 15 Apr 2011 16:12:24 -0400 Received: by wwb39 with SMTP id 39so3114610wwb.30 for ; Fri, 15 Apr 2011 13:12:23 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:message-id:date:from:user-agent:mime-version:to :subject:references:in-reply-to:x-enigmail-version:content-type; bh=WUd0uBxMFiAGlJLKweUp+3XRJyXZYV5dMTBazvdR5Eg=; b=Rc26TTvqVCeWD/MtFaP8z98inzxN/0sRpXBjtX9OnnD7Hj//I54y6y0vQvJMlq9io5 cheGqfCym+nMCxPIn9PKA4Ta38YUmncz2ThOk8VuOo7V4Yb4wAYR3FCVDOQjpN3+1IoK GRLAA2QsNMAnLEqTjByNEG8OO/1LmjWrItr1c= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=message-id:date:from:user-agent:mime-version:to:subject:references :in-reply-to:x-enigmail-version:content-type; b=kTxhMdjIRIeuE6buHXMFhkrRABPO5B3DBKLOzlxNBFSWNsag63qifB/cRjXYKhMzb4 tpCXKsd3ipCY2Ly+g2QJpdxO1pddvnm/ZHtiaVuprhotLXxFNnTH47RTmvO4eNnUp0+Y TQGSj3/sbuP+TKAf5GeUqRiV8LXWxhlxbAmnA= Received: by 10.227.168.68 with SMTP id t4mr2403695wby.26.1302898343542; Fri, 15 Apr 2011 13:12:23 -0700 (PDT) Received: from debian.x201.phnet (gprs55.swisscom-mobile.ch [193.247.250.55]) by mx.google.com with ESMTPS id o6sm1815263wbo.54.2011.04.15.13.12.21 (version=TLSv1/SSLv3 cipher=OTHER); Fri, 15 Apr 2011 13:12:22 -0700 (PDT) Message-ID: <4DA8A69E.1020001@gmail.com> Date: Fri, 15 Apr 2011 22:12:14 +0200 From: =?UTF-8?B?VmxhZGltaXIgJ8+GLWNvZGVyL3BoY29kZXInIFNlcmJpbmVua28=?= User-Agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.2.15) Gecko/20110402 Iceowl/1.0b2 Icedove/3.1.9 MIME-Version: 1.0 To: grub-devel@gnu.org Subject: Re: Make grub treat a virtual hard disk as a physical hard disk References: <20110415194151.GP343@caffeine.csclub.uwaterloo.ca> In-Reply-To: <20110415194151.GP343@caffeine.csclub.uwaterloo.ca> X-Enigmail-Version: 1.1.2 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="------------enig61DEC90E647DC0E2C5D1499E" X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 2) X-Received-From: 74.125.82.49 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: Fri, 15 Apr 2011 20:12:26 -0000 This is an OpenPGP/MIME signed message (RFC 2440 and 3156) --------------enig61DEC90E647DC0E2C5D1499E Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable On 15.04.2011 21:41, Lennart Sorensen wrote: > On Fri, Apr 15, 2011 at 03:37:32PM -0400, Swapnesh Chaubal wrote: >> I am working on booting a physical machine using VHD files (regarding = which >> I have not accomplished much) and I believe one way to go about it wou= ld be >> to make grub treat a virtual hard disk as physical hard disk. This way= , the >> physical machine does not need to know what it is booting from and the= rest >> of the booting and running should proceed as it normally does. >> >> Is there any way to achieve this? > And who is going to map the VHD file to the physical disk for the syste= m > running from the VHD file? > > You probably could convince grub to read a filesystem, find a vhd file,= > teach grub how to parse it and figure out how to find the right offsets= > in it to read its filesystem and find the kernel to boot that way, This part is done and supported (loopback command) as long as the disk format is raw (I don't know whether VHD is raw or not). > but > you still have the larger problem of then making that kernel work with > a VHD file rather than direct hardware access (in fact it would have to= > do both. Read the physical device and filesystem to get at the vhd and= > read that). This part is OS-specific. In case of GNU/Linux, FreeBSD, GNU/kFreeBSD, NetBSD, OpenBSD, xnu-based Systems (Darwin and MacOSX), Solaris and probably some other multiboot systems you can have a small initial ramdisk which is used as root at first and has a sole purpose of finding the other root and mounting it accordingly. --=20 Regards Vladimir '=CF=86-coder/phcoder' Serbinenko --------------enig61DEC90E647DC0E2C5D1499E Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.11 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iF4EAREKAAYFAk2opqUACgkQNak7dOguQgk4cAD+JY/HLOYSQmabopV1PasoYjrh qgJ2btn31W4rKMmSjE4A/0yZ0pw6jWLn3NQupLgv2hsUdGe1t02XnVfa34JBz6sK =11BT -----END PGP SIGNATURE----- --------------enig61DEC90E647DC0E2C5D1499E--