Skip to contentSkip to conversation

ramdisk image question

U-Boot-Users Alexander Povolotsky 2 participants 2 messages Sep 20, 2004

lore
Share & tools
lore
#0 lore raw

Yes, Wolfgang -

I am using U-Boot - but do I need somehow create ramdisk image first (please note that I am building kernel in cygwin Windows XP environment) ?

Firstly I tried to use root file system using NFS server on the same Windows XP machine where I am building via cygwin - by copying pre-made root file system from Arabella CD-ROM to my windows disk drive - this did not work because hard links were not preserved during copying ... bootargs=root /dev/nfs rw nfsroot=192.168.1.100:/home/apovolot/fadsroot
-I was getting during the kernel boot:
...
Looking up port of RPC 100003/2 on 192.168.1.100
Looking up port of RPC 100005/1 on 192.168.1.100
VFS: Mounted root (nfs filesystem).
Freeing unused kernel memory: 272k init
Warning: unable to open an initial console.

Kernel panic: No init found.  Try passing init= option to kernel.
 <0>Rebooting in 180 seconds..

Then I tried to use to NFS mount (read only) onto the Arabella CD-ROM itself (within my Windows XP):

bootargs=root /dev/nfs ro nfsroot=192.168.1.100:/E/fadsroot

This caused kernel booting hanging:

...
Looking up port of RPC 100003/2 on 192.168.1.100
Looking up port of RPC 100005/1 on 192.168.1.100
VFS: Mounted root (nfs filesystem).
Freeing unused kernel memory: 272k init
*********** hanging **********

Finally I tried:

bootargs=root=/dev/ram rw devfs=nomount init=/bin/sh

bootm 200000
## Booting image at
16 08:49:38 EDT 2004
PQ2 ADS Portame: Linux
68.1.103
PID hash table entries: 256 (order 8: 2048 bytes)
Warning: real time clock seems stuck!
Dentry cache hash table entries: 8192 (order: 3, 32768 bytes) Inode-cache hash table entries: 4096 (order: 2, 16384 bytes)
Memory: 30432k available (1348k kernel code, 324k data, 272k init, 0k highmem) Calibrating delay loop... 131.07 BogoMIPS
Mount-cache hash table entries: 512 (order: 0, 4096 bytes)
NET: Registered protocol family 16
PCI: Probing PCI hardware
Generic RTC Driver v1.07
Serial: CPM driver $Revision: 0.01 $
ttyCPM0 at MMIO 0xf0011a00 (irq = 40) is a CPM UART
RAMDISK driver initialized: 16 RAM disks of 32768K size 1024 blocksize
loop: loaded (max 8 devices)
eth0: FCC ENET Version 0.3, 08:00:17:40:00:03
NET: Registered protocol family 2
IP: routing cache hash table of 512 buckets, 4Kbytes
TCP: Hash tables configured (established 2048 bind 4096)
NET: Registered protocol family 1
NET: Registered protocol family 17
Sending DHCP requests ...... timed out!
Sending DHCP requests ...... timed out!
...

So what is the real solution ?

Thanks,
Alex
************************
In message <[email protected]> you

Quoted 4 lines · wrote:

Are there any h/w architecture and board specific details to be
taken in account while coding/building the ramdisk ?
If so, does the ramdisk explanation in the book covers those details > for PPC (Freescale's PQ2FADS-VR 82xx board with MPC8275)?

All the details you may collect here and there are completely misleading and irrelevant as you wrote you were using U-Boot, which has it's own way of handling ramdisk images, which is independent of the architecture or the kernel version.

Best regards,

Wolfgang Denk

Signature · 9 lines
Software Engineering:  Embedded and Realtime Systems,  Embedded Linux
Phone: (+49)-8142-4596-87  Fax: (+49)-8142-4596-88  Email: wd at denx.de
Mistakes are often the stepping stones to utter failure.


________________________________________________________________
Get your name as your email address.
Includes spam protection, 1GB storage, no ads and more
Only $1.99/ month - visit http://www.mysite.com/name today!
#1 lore raw
Quoted 4 lines · In message <[email protected]> you wrote:

I am using U-Boot - but do I need somehow create ramdisk image first (please note that I am building kernel in cygwin Windows XP environment) ?

Please don't cross-post extensively. One list is enough.

------- Forwarded Message

Date:    Mon, 20 Sep 2004 22:22:28 +0200
From:    Wolfgang Denk <[email protected]>
To:      "Alexander Povolotsky" <[email protected]>
Subject: Re: ramdisk image question 
Quoted 2 lines · In message <[email protected]> you wrote:

I am using U-Boot - but do I need somehow create ramdisk image first

The build order is completely arbitrary. You can first build the Linux kernel, and then the ramdisk image, or vice versa - as you like it. Both images are completeley independent of each other.

Quoted 2 lines

(please note that I am building kernel in cygwin Windows XP environment) ?

This does not matter.

Quoted 1 line

Firstly I tried to use root file system using NFS server on the same Windows

XP

Quoted 3 lines

machine where I am building via cygwin - by copying pre-made root file system

from Arabella CD-ROM to my windows disk drive - this did not work because har

d

Quoted 1 line

links were not preserved during copying ...

Then your method of copying was wrong. I hope youa re aware that you cannot easily use a windows system as NFS server for a Linux root filesystem? Linux uses a lot of things (concepts like device files
owner, file and directory permissions, etc.) which cannot be
represented in a windoze filesystem.

Use a Linux NFS server instead. [You may also want to use a Linux build host - it is _much_ faster.]

Quoted 3 lines

Warning: unable to open an initial console.

Kernel panic: No init found.  Try passing init= option to kernel.
 <0>Rebooting in 180 seconds..

This means that your root filesystem was incomplete or bad.

Quoted 4 lines

Then I tried to use to NFS mount (read only) onto the Arabella CD-ROM itself (within my Windows XP):

bootargs=root /dev/nfs ro nfsroot=192.168.1.100:/E/fadsroot

You cannot use a windows filesystem as NFS root.

Quoted 7 lines

NET: Registered protocol family 1
NET: Registered protocol family 17
Sending DHCP requests ...... timed out!
Sending DHCP requests ...... timed out!
...

So what is the real solution ?

In this case it seems you configured the kernel for IP
autoconfiguration, but missed to set up a DHCP server.

Ummm... I have two recommendations for you:

1) Forget about using a windoze system as development host for embedded Linux. It is just wasted effort.

2) Have a look at the DULG at http://www.denx.de/twiki/bin/view/DULG/Manual
It describes in detail how to set up the build and development environment, and how to configure, install, and use U-Boot and Linux.

Best regards,

Wolfgang Denk

Signature · 6 lines
Software Engineering:  Embedded and Realtime Systems,  Embedded Linux
Phone: (+49)-8142-4596-87  Fax: (+49)-8142-4596-88  Email: wd at denx.de
Real Programmers always confuse Christmas and Halloween because
OCT 31 == DEC 25 !  - Andrew Rutherford (andrewr at ucs.adelaide.edu.au)

------- End of Forwarded Message