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

Re: [dm-devel] Persistent Overlay COW Full: Flipped the Invalid bit in a hexdump; how do I grow it now?



On Tue, Jun 3, 2014 at 9:20 AM, Rahul Nabar <rpnabar gmail com> wrote:
I accidentally managed to fill up the persistent COW snapshot overlay
on my Fedora20 USB & it got flagged Invalid thus rendering the Live
USB unbootable since the root filesystem couldn't be mounted.

dmsetup status
live-rw 0 8388608 snapshot Invalid.

 Subsequently I used a 2011 thread(link below) on the dm-devel mailing
list ( Alasdair Kergon, Frederick Grose etc.) and flipped the invalid
bit in the overlay file by booting a different system and attaching
the USB stick to it.

Like so:  echo $'\x01' | dd
of=/run/media..../liveuser/LIVE.../overlay-LIVE-17F4-055A  bs=1
count=1 seek=4 conv=notrunc

hexdump of the file verified the flipped 5th byte. Now the LiveUSB
boots & I can successfully see my data but it's hard to do anything
more since it gets full almost immediately after I boot.

Is there a way to grow the overlay file? Would this work?

 dd if=/dev/zero of=overlay-LIVE-17F4-055A seek=overlay_size count=size_increase

How do I compute the number overlay_size?

blockdev -q --getsz <overlay/device/path or overlay/file/path>​

or the denominator in the 

dmsetup status

for the live-rw snapshot

(Units are 512 byte sectors.)

I suppose size_increase can
be some large number?

Or are more steps needed to expand the overlay?


http://thread.gmane.org/gmane.linux.kernel.device-mapper.devel/14644

See

     --Fred

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