On Wed, May 14, 2008 at 08:58:47AM -0700, Ramgopal Kota wrote:
> Now I want to have the rootfs (jffs) on flash. Is there any document
> which tells me how to do that ?
As a learning exercise you could start by reading the Filesystem
Hierarchy Standard: http://www.pathname.com/fhs/. This is a great
document to give you some insight into a Unix filesystem.
With that basic knowledge you can start to build your own
filesystem. It's not that hard. Just use a standard Debian
(that's what I did) mipsel installation and copy everything you
need from it to your own filesystem.
What do you need and what not? Well, you start with /sbin/init,
since that is the very first process the Linux kernel starts when
it is done with itself. So make sure that is in place. Next use
ldd to find out what libraries it needs. Copy those in place too.
Run ldd too for every library, to get it's dependings too.
Next you put /etc/inittab in place. Read it carefully and follow
all its scripts in it. Of course copy those in place too and all
the tools all those scripts need. Again, for all the tools run
ldd to find the libraries needed. In the start it looks like a
lot, but you'll soon find out most basic pieces of the system use
the same libraries over and over again.
You can also copy the /dev directory from the Debian installation
to your own filesystem.
This way you will build a very basic and clean system and more
important you will learn how a Linux system boots. For me back
then it was a real eye opener when I read the aforementioned FHS
document and just started by following all scripts mentioned in
/etc/inittab. It takes some time, but it's worth the exercise!
$ cat ~/.signature
Freddy Spierenburg <email@example.com> http://freddy.snarl.nl/
GnuPG: 0x7941D1E1=C948 5851 26D2 FA5C 39F1 E588 6F17 FD5D 7941 D1E1
$ # Please read http://www.ietf.org/rfc/rfc2015.txt before complain!
Description: Digital signature