David Cottrill wrote:
Thanks - I need to get out of having a "representative" disk because
I'll be working with many, many applications and disks.
You still haven't actually specifically said what your goal is. :)
For example, my goal, in the technique I described, is to take any size
disk, make a standard sized /dev/sda1 and use the rest of the disk for
/dev/sda2. (Which sounded to me like what you might be interested in.)
Do you have a specific set of partitions and then a "rest-of" partition?
Or an unknown set of partitions and a "rest-of" partition, etc? It is
not clear what your goals/parameters are.
I guess I'll
have to settle for working out how to extract the information I need
from 'sfdisk -lm '
I said "representative disk" to describe the original partitioning
method, but really I suppose I meant "representative partitioning". I
apply that sfdisk file to *any size* disk and it gives me the layout I
want (~512MB /dev/sda1 and rest of the disk for /dev/sda2).
I was suggesting that you take a disk (any size), and set up your
partitions how you like them, then dump the partitioning, remove the
"size=xxx" from the dump file, etc.
Also, if you really must parse, you might have more accuracy with
"sfdisk -d", since that gives you the output in integer sectors, rather
than cylinders (which might be fractional). Plus, it is intended for
parsing (by sfdisk, anyway. :)
Jordan
--
To UNSUBSCRIBE, email to [email protected]
with a subject of "unsubscribe". Trouble? Contact [email protected]