LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices



Reply
 
Search this Thread
Old 02-02-2012, 05:44 AM   #1
kostya
Member
 
Registered: Mar 2010
Location: Moscow, Russia
Distribution: Ubuntu Studio, antix(mepis), Fedora, FreeBSD
Posts: 172
Blog Entries: 5

Rep: Reputation: 17
Live Image mount: union FS overlay vs dmsetup overlay


Hi everyone,

I've been testing booting my installed Fedora 16 system from a squashfs'ed image (hosting all fs except my $HOME files). That seems to be a good option for many reasons and has good potentials of use, but for now it is just testing. I'll post more about it in another thread once finished...

I'm using AUFS to mount a writeable overlay, to which I then mount --bind my rw home. To be able to do that I installed a zen-kernel as Fedora includes no support for union filesystems.
Then, analyzing Fedora dracut boot modules I found, that it deals with this problem by using dmsetup like this:
Code:
dd if=/dev/null of=$OVERLAY_LOOPDEV bs=1024 count=1 seek=$((512*1024))
losetup $OVERLAY_LOOPDEV /overlay #this to create overlay image and mount it on loop device
echo 0 `blockdev --getsz $BASE_LOOPDEV` snapshot $BASE_LOOPDEV $OVERLAY_LOOPDEV p 8 | dmsetup create live-rw  #this unites them together, a ro image and rw overlay into the "live-rw" snapshot
While I'm using aufs like this:
Code:
mount -t aufs -o br:$overlay=rw:$squash_img_mnt=ro none $root_mount
mount --bind $HOME(rw) $root_mount/home
(the 200M $overlay is for the system writes and HOME is for me, didn't want to mix these together)

Now the question is: which is better and why?

Fedora doesn't include any union fs into kernel, but keeps using dmsetup for live images, and I prefer to use as much as possible the distro-provided tools to deal with an issue. Fedora is fine, but quite often prefers experimental features over those known for stability, as I have noticed (though it's been my distro of choice these last 3 years). This thread seems to touch upon some existing issues with dmsetup approach to live-img rw overlay, for example.

Then Debian-derived distros do include unionfs into kernel. And overall I couldn't find that much information about it all, except by hacking the initrd creating software in these distros...

Does anyone of you have any such experience? Maybe there are some general considerations as to why the one approach could be preferred over the other? Device-mapper approach over union filesystem mount and vice versa?
I'll keep studying it myself, meantime every thought will be greatly appreciated .

Thanks in advance,
Kostya
 
Old 02-02-2012, 04:08 PM   #2
kostya
Member
 
Registered: Mar 2010
Location: Moscow, Russia
Distribution: Ubuntu Studio, antix(mepis), Fedora, FreeBSD
Posts: 172
Blog Entries: 5

Original Poster
Rep: Reputation: 17
It seems, here is given a very good and detailed answer.
So generally, my question answered.
 
Old 02-16-2012, 07:38 AM   #3
kostya
Member
 
Registered: Mar 2010
Location: Moscow, Russia
Distribution: Ubuntu Studio, antix(mepis), Fedora, FreeBSD
Posts: 172
Blog Entries: 5

Original Poster
Rep: Reputation: 17
OK mark as SOLVED.

Thanks to everyone )
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] unable to create persistent overlay with fc-15 live-usb schneidz Fedora 4 10-31-2011 09:38 AM
fedora-14 live usb - overlay persistent file space issues schneidz Fedora 5 12-12-2010 07:21 PM
How do I boot DSL as a live USB with a persistent overlay without unetbootin and... This is my username DamnSmallLinux 1 08-30-2009 03:48 PM
LXer: Enhance image overlay maps in Google Earth with altitude attributes LXer Syndicated Linux News 0 09-26-2008 02:00 AM
persistent image overlay --live usb fedora 9 kalabharath Linux - Newbie 1 08-05-2008 08:10 AM


All times are GMT -5. The time now is 03:53 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration