LinuxQuestions.org
Latest LQ Deal: Linux Power User Bundle
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 01-28-2014, 02:47 AM   #1
vinayak099
Member
 
Registered: Jan 2014
Posts: 31

Rep: Reputation: Disabled
How to build unionfs. what needs to be done


Hi,

I have downloaded unionfs from http://download.filesystems.org/unionfs/unionfs-2.x/
and applied the patch on ubuntu using command
patch -p1 < unionfs.diff

after that I did not get how to compile/build unionfs source files.

I went inside the fs/unionfs directory and gave "make" but it says
make: *** No targets. Stop.

what to do for this ? What changes required ? Do I need to change any configuration settings ?

Please help on the same..
 
Old 01-28-2014, 05:57 AM   #2
gengisdave
Member
 
Registered: Dec 2013
Location: Turin, Italy
Distribution: slackware
Posts: 326

Rep: Reputation: 73
this is a patch for the kernel, you must apply to the kernel sources; 'cd' in your kernel source and apply the patch, then compile the kernel. if you're not into kernel compiling, we'll do step by step
 
Old 01-28-2014, 06:47 AM   #3
vinayak099
Member
 
Registered: Jan 2014
Posts: 31

Original Poster
Rep: Reputation: Disabled
What I have done is..

I have downloaded source code for ubuntu 13.10 which is around 113Mb..

Later I had applied patch using

patch -p1 < unionfs.diff

patch applied successfully and I can see the unionfs directory created under fs.

then

after gave command "make", got error telling that can't find config file

so I ran "make oldconfig", it had asked for y/n/m options for newly found files, then I gave "y" for unionfs and other.

All files compiled and I can see the "*.o" files in unionfs and other directories but cant find "*.ko" files for unionfs and other fs.

Searched for the same stating from the /. but did not find it.

Tried "mount -t unionfs -o dirs=dir1/=rw:dir2/ unionfs union" thinking that it will be installed somewhere else.

but unionfs was not detected.

Where I am wrong ? and what is correct procedure ?

Last edited by vinayak099; 01-28-2014 at 06:48 AM.
 
Old 01-28-2014, 06:52 AM   #4
gengisdave
Member
 
Registered: Dec 2013
Location: Turin, Italy
Distribution: slackware
Posts: 326

Rep: Reputation: 73
it seems modules are not yet built, force a 'make modules', then 'make install' and 'make modules_install' to copy the modules built under /lib/modules, then restart, if mount blame again about an unsupported fs, check with "lsmod | grep union", if empty load with "modprobe unionfs" or whatever it's named
 
Old 01-28-2014, 09:37 AM   #5
vinayak099
Member
 
Registered: Jan 2014
Posts: 31

Original Poster
Rep: Reputation: Disabled
Thanks for the reply..

have followed all the steps you said.

but unionfs is still not installed.

can not even locate unionfs.ko in any directory.

even lsmod | grep ext is also not showing anything.

and when I do

cd /lib/modules/3.11.0/kernel/fs

only ext2.ko is there . cannot locate ext4 and unionfs.ko.
 
Old 01-28-2014, 09:55 AM   #6
gengisdave
Member
 
Registered: Dec 2013
Location: Turin, Italy
Distribution: slackware
Posts: 326

Rep: Reputation: 73
you said "y" to unionfs, support is kernel built-in, for module you must choose "m", "cat /proc/filesystems | grep union" will show you if unionfs is kernel supported
 
Old 01-28-2014, 11:01 PM   #7
vinayak099
Member
 
Registered: Jan 2014
Posts: 31

Original Poster
Rep: Reputation: Disabled
Thanks for your patience. I think I am dragging this discussion much. I want to know about the things. Thats why.

Is there anyway through which I can go for option "m" now. I was not knowing the meaning of "y/n/m".

Can you please elaborate what is the meaning of options "y/n/m"

Can I recompile it changing the config file ? if Yes, where I have to change ?

if I select "m" option, then I can say .ko for it ?
 
Old 01-29-2014, 02:58 AM   #8
gengisdave
Member
 
Registered: Dec 2013
Location: Turin, Italy
Distribution: slackware
Posts: 326

Rep: Reputation: 73
yes, "m" is for module (while "y" is for built-in and "n" for none), unless unionfs is the / fs, you can compile it modular (otherwise a initrd is required)

there are two graphical tool to help you "make menuconfig" is the ncurses version, "make xconfig" is the qt version (or gtk, i don't remember)

in both cases, on the main menu, File systems --> Unionfs ("y" for built-in, marked as "*", "m" for module, "n" for exclude) save the configuration, make && make install && make modules_install
 
Old 01-29-2014, 07:45 AM   #9
vinayak099
Member
 
Registered: Jan 2014
Posts: 31

Original Poster
Rep: Reputation: Disabled
...

Cannot see unionfs in File systems after "make menuconfig".

I have give the option "m" while doing "make oldconfig" but its not reflecting in "make menuconfig".

But I can see below lines in .config which is in linux-3.11 directory

CONFIG_UNION_FS=m
CONFIG_UNION_FS_XATTR=y
CONFIG_UNION_FS_DEBUG=y

Not understanding whats wrong.
 
Old 01-29-2014, 07:50 AM   #10
vinayak099
Member
 
Registered: Jan 2014
Posts: 31

Original Poster
Rep: Reputation: Disabled
I applied the patch again on new branch then also "make menuconfig" is not listing it in File systems menu..
 
Old 01-29-2014, 09:04 AM   #11
gengisdave
Member
 
Registered: Dec 2013
Location: Turin, Italy
Distribution: slackware
Posts: 326

Rep: Reputation: 73
i applied the patch, options are in File systems --> Miscellaneous Filesystems --> Unionfs (just before Apple fs); module unionfs.ko is in fs/unionfs (tried on kernel 3.13 and unionfs-2.5.12_for_3.13.0-rc2)
 
Old 01-29-2014, 10:56 PM   #12
vinayak099
Member
 
Registered: Jan 2014
Posts: 31

Original Poster
Rep: Reputation: Disabled
Dont know whats wrorng.

I have downloaded diferent new source and applied the patch. Now its showing.

I will compile it again and lets see whether I can able mount it this time or not.

BTW

Do I need to do "make" again

OR

make module directly ?
 
Old 01-30-2014, 04:19 AM   #13
vinayak099
Member
 
Registered: Jan 2014
Posts: 31

Original Poster
Rep: Reputation: Disabled
Hi,

I have compiled the things again by making modifications to menuconfig.

Still the error exists "mount: unknown filesystem type 'unionfs'".

But the .ko is present in
/lib/modules/3.11.0/kernel/fs/unionfs#

ls -l unionfs.ko
-rw-r--r-- 1 root root 3144979 Jan 30 15:29 unionfs.ko

Even the time and date is also showing right.

Do we need to set anything else in menuconfig ?

Do we need to set anything related to ENVIRONMENT VARIABLE ?

Whats really going wrong ? not able to figure it out ..

Last edited by vinayak099; 01-30-2014 at 04:23 AM. Reason: Missed to add content
 
Old 01-30-2014, 04:36 AM   #14
gengisdave
Member
 
Registered: Dec 2013
Location: Turin, Italy
Distribution: slackware
Posts: 326

Rep: Reputation: 73
"lsmod | grep union" then "modprobe unionfs"
 
Old 01-30-2014, 07:55 AM   #15
vinayak099
Member
 
Registered: Jan 2014
Posts: 31

Original Poster
Rep: Reputation: Disabled
I have done all those things.

but

modprobe union
FATAL: Module union not found.
 
  


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
unionfs CVS how to? android6011 Linux - General 1 01-29-2007 04:26 PM
unionfs for kernel 2.6.19 linx win Debian 6 12-19-2006 09:08 PM
unionfs Sayoji Linux - General 3 11-19-2006 04:34 PM
unionfs not in kernel devavictrix Linux - Newbie 1 07-15-2006 10:30 AM
use unionfs to build packages? uselpa Slackware 1 07-14-2006 02:27 PM


All times are GMT -5. The time now is 04:34 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
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration