• Home
  • Help
  • Search
  • Login
  • Register
Pages: [1]
Author Topic: Bad Magic Number with uImage.sheeva.040309 and NFS  (Read 4943 times)
theRealBigP
Newbie
*

Karma: 0
Posts: 22


View Profile
« on: May 02, 2009, 08:32:44 AM »

I'm trying to get NFS boot working with my SheevaPlug, and I keep getting a "Bad Magic Number" error after it loads the kernel from my TFTP server:

Code:
Using egiga0 device

TFTP from server 192.168.1.139; our IP address is 192.168.1.119

Filename 'uImage.sheeva.040309'.

Load address: 0x200000

Loading: *##################################################################

#################################################################

#################################################################

#################################################################

#################################################################

#################################################################

###############

done

Bytes transferred = 2070316 (1f972c hex)

## Booting image at 02000000 ...

Bad Magic Number



I am just using the pre-compiled uImage.sheeva.040309 kernel provided on the website, and I believe my NFS share of the root filesystem is setup correctly because if I boot the SheevaPlug from the internal flash, I can mount it and read the files. I think there must be something wrong with my uBoot parameters, but I can't make sense of all the hex values and why everyone seems to have different numbers. Here is my uBoot environment.

Code:
baudrate=115200

loads_echo=0

CASset=min

MALLOC_len=1

ethprime=egiga0

standalone=fsload 0x2000000 $(image_name);setenv bootargs $(console) root=/dev/mtdblock0 rw ip=$(ipaddr):$(serverip)$(bootargs_end) $(mvPhoneConfig); bootm 0x2000000;

ethaddr=00:50:43:7d:2d:1f

ethmtu=1500

mvPhoneConfig=mv_phone_config=dev0:fxs,dev1:fxs

mvNetConfig=mv_net_config=(00:11:88:0f:62:81,0:1:2:3),mtu=1500

usb0Mode=host

yuk_ethaddr=00:00:00:EE:51:81

nandEcc=1bit

netretry=no

rcvrip=169.254.100.100

loadaddr=0x02000000

autoload=no

ethact=egiga0

run_diag=no

rootpath=/root/rootfsv1.0

image_name=uImage.sheeva.040309

console=console=ttyS0,115200 mtdparts=nand_mtd:0x200000@0x100000(uImage)ro,0x1f800000@0x30000(rootfs)rw

bootargs_root=root=/dev/nfs rw

bootargs_end=:::DB88FXX81:eth0:none

bootcmd=tftpboot 0x200000 $(image_name);setenv bootargs $(console) $(bootargs_root) nfsroot=$(serverip):$(rootpath) ip=$(ipaddr):$(serverip)$(bootargs_end); bootm 0x2000000

stdin=serial

stdout=serial

stderr=serial

mainlineLinux=no

enaMonExt=no

enaCpuStream=no

enaWrAllo=no

pexMode=RC

disL2Cache=no

setL2CacheWT=yes

disL2Prefetch=yes

enaICPref=yes

enaDCPref=yes

sata_dma_mode=yes

netbsd_en=no

vxworks_en=no

bootdelay=3

disaMvPnp=no

enaAutoRecovery=yes

filesize=1f972c

fileaddr=200000

netmask=255.255.255.0

ipaddr=192.168.1.119

serverip=192.168.1.139

bootargs=console=ttyS0,115200 mtdparts=nand_mtd:0x200000@0x100000(uImage)ro,0x1f800000@0x30000(rootfs)rw root=/dev/nfs rw nfsroot=192.168.1.139:/root/rootfsv1.0 ip=192.168.1.119:192.168.1.139:::DB88FXX81:eth0:none


I would appreciate any insight anyone can offer, as I would really like to get NFS boot going before messing around with the filesystem. Thanks.
Logged

kilowatt
Global Moderator
Full Member
*****

Karma: 3
Posts: 106


View Profile
« Reply #1 on: May 02, 2009, 08:47:53 AM »

your asking the tftpboot to put the image at 0x200000 and then trying to run it (bootm) at 0x2000000.

These numbers need to be the same.

Add a zero to the first one.

Mark
Logged

kilowatt
Global Moderator
Full Member
*****

Karma: 3
Posts: 106


View Profile
« Reply #2 on: May 02, 2009, 08:54:59 AM »

Also there is a problem with your mtdparts definition.
Quote
console=console=ttyS0,115200 mtdparts=nand_mtd:0x200000@0x100000(uImage)ro,0x1f800000@0x30000(rootfs)rw


You are defining the start of the rootfs in the middle of the u-boot partition.  Be careful you could corrupt your u-Boot.

Change 0x30000(rootfs) to 0x300000(rootfs)

Mark
Logged

theRealBigP
Newbie
*

Karma: 0
Posts: 22


View Profile
« Reply #3 on: May 02, 2009, 09:41:50 AM »

Yes! Thank you so much; that fixed things and I can now boot via NFS! One more question, and it's one that I'm embarrassed to ask: what is a decent terminal program for Linux (particularly Ubuntu 8.10) that has copy & paste functionality? I am pulling my hair out trying different ones like Putty and gtkterm, but neither of them seems to have this basic functionality, which would make entering these long commands a lot less error-prone. Thanks again for your help.
Logged

kilowatt
Global Moderator
Full Member
*****

Karma: 3
Posts: 106


View Profile
« Reply #4 on: May 02, 2009, 10:20:52 AM »

Sorry, I can't help you there.  I've been using putty on a windows box for my console connection.
Logged

DanielQuinn
Newbie
*

Karma: 0
Posts: 9


View Profile
« Reply #5 on: May 02, 2009, 11:45:33 AM »

A good console program for Gnome is xterm, and if you're using KDE, try konsole.
Logged

theRealBigP
Newbie
*

Karma: 0
Posts: 22


View Profile
« Reply #6 on: May 02, 2009, 03:08:53 PM »

Thanks for the suggestions, but I couldn't find anything in the help (for xterm at least) that indicates how you could make a connection over a serial port. Tera Term offers this capability, as well as copy and paste, but I think it's only for Windows.
Logged

cbxbiker61
Global Moderator
Sr. Member
*****

Karma: 38
Posts: 497


View Profile
« Reply #7 on: May 02, 2009, 04:18:03 PM »

You need a serial communications program such as minicom.  Kermit also works.  As far as copy and paste go that's a function of the terminal program you're using.  I would be surprised if shift-insert and control-insert dont' work, these special key combinations seem to work in just about everything for copy/paste.
Logged

Skywalker
Newbie
*

Karma: 0
Posts: 19


View Profile
« Reply #8 on: May 03, 2009, 08:02:54 AM »

GtkTerm, does have copy&paste functionality, but you need to use correct keyboard combination (I am also a newby, I had to search the internet for it):
copy: ctrl + insert
paste: shift + insert
cut: shift + delete

it worked for me, and I am a happy GTKTerm user now.

Luke
Logged

theRealBigP
Newbie
*

Karma: 0
Posts: 22


View Profile
« Reply #9 on: May 04, 2009, 11:30:07 AM »

Skywalker, that makes perfect sense. I kept trying Ctrl-C,Ctrl-V like in Windows, and when that didn't work and there was no menu option to do it either, I figured it simply wasn't supported. I should have tried those key combos as well, as I think I've seen them listed in the menus of other Linux programs I use. Thanks!
Logged

hooray-for-me
Newbie
*

Karma: 0
Posts: 1


View Profile
« Reply #10 on: November 25, 2009, 06:37:02 AM »

For serial port connections I would highly recommend Cutecom its easy to use and allows copy/paste functionality.
http://cutecom.sourceforge.net/
https://help.ubuntu.com/community/Cutecom

In Gnome terminal copy/paste is assigned to CTRL+SHIFT+C/V which is a bit confusing but you can change the shortcuts in the terminal settings.
Logged

Pages: [1]
Print
Jump to: