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 04-17-2014, 12:49 AM   #1
david_8274
Member
 
Registered: Jun 2013
Location: California
Distribution: Ubuntu, Fedora
Posts: 74

Rep: Reputation: Disabled
load real filesystem from initramfs


Hi,

I am working on an embedded linux system.
I am using kernel 2.6. Based on what I have read, the 2.6 kernel always use initramfs. My question is, what modification I need to make and where should I make them so initramfs will load and pass control to a real filesystem?(the real filesystem is in one of the partitions in and external NAND flash)

Thanks,
Wei Xu
 
Old 04-17-2014, 06:26 PM   #2
Emerson
LQ Guru
 
Registered: Nov 2004
Location: Saint Amant, Acadiana
Distribution: Gentoo ~arch
Posts: 5,872

Rep: Reputation: Disabled
Are you talking about initramfs or initrd?
 
Old 04-17-2014, 07:02 PM   #3
david_8274
Member
 
Registered: Jun 2013
Location: California
Distribution: Ubuntu, Fedora
Posts: 74

Original Poster
Rep: Reputation: Disabled
@Emerson,

I am using kernel 2.6 so it will be initramfs.

Thanks,
Wei
 
Old 04-17-2014, 08:57 PM   #4
syg00
LQ Veteran
 
Registered: Aug 2003
Location: Australia
Distribution: Lots ...
Posts: 14,838

Rep: Reputation: 1822Reputation: 1822Reputation: 1822Reputation: 1822Reputation: 1822Reputation: 1822Reputation: 1822Reputation: 1822Reputation: 1822Reputation: 1822Reputation: 1822
An initramfs is always created, but you don't have to use it - by default it's empty. If you can build all the support you need into the kernel, just pretend the initramfs doesn't exist.

If you need to wait for the flash drive to come ready before proceeding, you might need to build the archive - have a look in ../Documentation/filesystems/ramfs-rootfs-initramfs.txt in your kernel source tree. It has good explanation, aad some extra references at the bottom.
 
Old 04-18-2014, 01:34 AM   #5
rknichols
Senior Member
 
Registered: Aug 2009
Distribution: CentOS
Posts: 2,959

Rep: Reputation: 1268Reputation: 1268Reputation: 1268Reputation: 1268Reputation: 1268Reputation: 1268Reputation: 1268Reputation: 1268Reputation: 1268
The magic of switching from an initramfs to a new root filesystem is done by the pivot_root command and system call. See "man 8 pivot_root" and "man 2 pivot_root" for details.
 
  


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
not able to load filesystem into nand flash ranjana kumari Linux - General 10 01-03-2013 09:37 AM
RHEL 6 : module load order changed in initramfs neo3matrix Linux - Kernel 3 09-12-2012 11:00 AM
nginx load balancer use real ip? VanDaMe Linux - Software 0 09-19-2008 01:58 AM
knfsd won't support map_static, where can I get me a real network filesystem? cyent Linux - Server 0 05-27-2008 02:12 AM
Real newbie/nead to load SUSE with XP frogjuice Linux - Newbie 1 08-19-2006 03:17 PM


All times are GMT -5. The time now is 04:49 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