bug-grub
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Supporting non-block device installs Linux


From: Sam Mason
Subject: Supporting non-block device installs Linux
Date: Mon, 15 Dec 2003 11:56:22 +0000
User-agent: Mutt/1.5.4i

Hi All,

I've been playing around with GRUB, trying to get it to install itself
onto a disk image I've made.  I kept on getting strange error
messages, so I had a delve into the code and came up with the included
patch.  The problem with the current code, is that when you're
installing under Linux it assumes that the partitions will always be
broken out into their own files.  If, for example, I'm installing to
"disk.img", it will try and access the first partition as a file
called "disk.img1" (note the '1' at the end); rather than from the
same file.  This (arguably) does the right thing when installing to a
disk under Linux; but doesn't do the right thing if you're working
with images.

The included patch adds a check in the appropriate place and handles
both block devices and regular files appropriately.  I'm not too sure
if it does the right thing, but it appears to work for me. . .

Hope that all makes sense,
  Sam

Attachment: grub-nonblock-devices.patch
Description: Text document


reply via email to

[Prev in Thread] Current Thread [Next in Thread]