auto-maximize a logical partition with ext3

auto-maximize a logical partition with ext3

Ira Abramov Lists-Linux-IL at ira.abramov.org
Sun Apr 3 20:19:54 IDT 2011


Quoting guy keren, from the post of Sun, 03 Apr:
>
> if it is the last partition, how about using expect (or similar) to  
> automate 'fidk' on the device (probably need to set a loop device on the  
> image file first), delete the partition and re-create it? as far as i  
> remember, when you create a partition via fdisk's interactive prompt, by  
> default it suggest to use all the available extra space.
>
> if it's a logical partition - you'll need to delete the underlying  
> logical part as well, i assume.

that solution has come to mind, and I have seen one case where it was
used (to create, not resize). there's no need even for expect, you can
simply redirect the input because the interaction is well known in
advance, but it's a very ugly solution I hope not to have to implement
for a dozen reasons. At the moment I'm taking all the information I can
with greps and awk, dumping with SFDISK, making the corrections and
loading back. c'est la vie.

Happily, my next task is a bit more interesting. making vmbuilder work
with logical partitions...


-- 
Good omen
Ira Abramov
http://ira.abramov.org/email/



More information about the Linux-il mailing list