• Home
  • Help
  • Search
  • Login
  • Register
Pages: [1]
Author Topic: Debian upgrade gone wrong.  (Read 1486 times)
jabjoe
Newbie
*

Karma: 1
Posts: 18


View Profile
« on: March 27, 2010, 05:12:11 AM »

Help!

I just tried to upgrade to Debian. I bought a class 6 sd card and figured I'd use that.
I was following http://www.cyrius.com/debian/kirkwood/sheevaplug/unpack.html

Looked simple enough. Upgraded uboot fine.

The only difference is I didn't want swap yet. So I didn't do a swap partition and removed it from the fstab on the sd card.
(Plan is swap and /var are on a USB disk).

I got to the point that while connected to uboot via ttyUSB0 I saw it finish decompressing kernel and then it stopped....

Now I can't do anything with the box, with or without the SD card! No ethernet connection and no ttyUSB0....

The ethernet lights seam to be flashing like something is happening, but it doesn't seam to ever get a IP address from my router (openwrt).

Ideas?

Is there a way to reset the uboot to factory settings? Tried powering up with reset held in.
As it looks alive, is there away to force the host machine (ubuntu) to have a ttyUSB0 that can use?
Logged

jabjoe
Newbie
*

Karma: 1
Posts: 18


View Profile
« Reply #1 on: March 27, 2010, 05:21:38 AM »

Ok got /dev/ttyUSB0 back. Can connect to it with cu and get "Connected."
Logged

jabjoe
Newbie
*

Karma: 1
Posts: 18


View Profile
« Reply #2 on: March 27, 2010, 08:13:10 AM »

Ok, I can connect via ttyUSB0 and I've gone through it all again. But still I can't get it to boot into Debian (not given up yet and tried to return to Ubuntu)

I'm wondering if it's something about the size of the SD card not matching up the card in the example. I made the first partition (boot) match the one in the example.

Any help would be greatly appreciated!

Below is what I see and it never gets further:


U-Boot 1.1.4 (Dec 27 2009 - 22:03:21) Marvell version: 3.4.27

U-Boot code: 00600000 -> 0067FFF0  BSS: -> 006CFEE0

Soc: 88F6281 A0 (DDR2)
CPU running @ 1200Mhz L2 running @ 400Mhz
SysClock = 400Mhz , TClock = 200Mhz

DRAM CAS Latency = 5 tRP = 5 tRAS = 18 tRCD=6
DRAM CS[0] base 0x00000000   size 256MB
DRAM CS[1] base 0x10000000   size 256MB
DRAM Total size 512MB  16bit width
Addresses 8M - 0M are saved for the U-Boot usage.
Mem malloc Initialization (8M - 7M): Done
NAND:512 MB
Flash:  0 kB

CPU : Marvell Feroceon (Rev 1)

Streaming disabled
Write allocate disabled


USB 0: host mode
PEX 0: interface detected no Link.
Net:   egiga0 [PRIME]
Hit any key to stop autoboot:  0
SDHC found. Card desciption is:
Manufacturer:       0x1b, OEM "SM"
Product name:       "00000", revision 1.0
Serial number:      2975634896
Manufacturing date: 7/2009
CRC:                0x00, b0 = 0

4480111 bytes read

1820384 bytes read
## Booting image at 00800000 ...
   Image Name:   Debian kernel
   Created:      2009-11-23  17:25:02 UTC
   Image Type:   ARM Linux Kernel Image (uncompressed)
   Data Size:    1820320 Bytes =  1.7 MB
   Load Address: 00008000
   Entry Point:  00008000
   Verifying Checksum ... OK
OK
## Loading Ramdisk Image at 01100000 ...
   Image Name:   Debian ramdisk
   Created:      2009-11-23  17:25:04 UTC
   Image Type:   ARM Linux RAMDisk Image (gzip compressed)
   Data Size:    4480047 Bytes =  4.3 MB
   Load Address: 00000000
   Entry Point:  00000000
   Verifying Checksum ... OK

Starting kernel ...

Uncompressing Linux... done, booting the kernel.

Logged

jabjoe
Newbie
*

Karma: 1
Posts: 18


View Profile
« Reply #3 on: March 27, 2010, 09:51:17 AM »

Went through again and now it works..... I think what was different is I started trying the installer on a usb pen, but when back to the SD card tarball technique. Perhaps that set something that was required. Anyway, up and running and happy now. :-)
Logged

jabjoe
Newbie
*

Karma: 1
Posts: 18


View Profile
« Reply #4 on: March 28, 2010, 02:32:26 PM »

Nope! It wasn't using the boot partition mmcblk0p1...

So I started to play......Now I get what I was before.

1820384 bytes read
## Booting image at 00800000 ...
   Image Name:   Debian kernel
   Created:      2009-11-23  17:25:02 UTC
   Image Type:   ARM Linux Kernel Image (uncompressed)
   Data Size:    1820320 Bytes =  1.7 MB
   Load Address: 00008000
   Entry Point:  00008000
   Verifying Checksum ... OK
OK
## Loading Ramdisk Image at 01100000 ...
   Image Name:   Debian ramdisk
   Created:      2009-11-23  17:25:04 UTC
   Image Type:   ARM Linux RAMDisk Image (gzip compressed)
   Data Size:    4480047 Bytes =  4.3 MB
   Load Address: 00000000
   Entry Point:  00000000
   Verifying Checksum ... OK

Starting kernel ...

Uncompressing Linux... done, booting the kernel.


Then nothing.

Tried a new changes to uboot:

setenv bootargs_root 'root=/dev/mmcblk0p2 rootdelay=10 rootfstype=ext2'
setenv bootcmd_mmc 'mmcinit; mmcinit; ext2load mmc 0 0x01100000 /uInitrd; ext2load mmc 0 0x00800000 /uImage'

but still nothing.  Here a print out of my uboot setup:

Marvell>> printenv
baudrate=115200
loads_echo=0
ipaddr=10.4.50.165
serverip=10.4.50.5
rootpath=/mnt/ARM_FS/
netmask=255.255.255.0
console=console=ttyS0,115200 mtdparts=nand_mtd:0xc0000@0(uboot)ro,0x1ff00000@0x100000(root)
CASset=min
MALLOC_len=1
ethprime=egiga0
bootargs_end=:::DB88FXX81:eth0:none
image_name=uImage
standalone=fsload 0x2000000 $(image_name);setenv bootargs $(console) root=/dev/mtdblock0 rw ip=$(ipaddr):$(serverip)$(bootargs_end) $(mvPhoneConfig); bootm 0x2000000;
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
mtdpartitions=mtdparts=orion_nand:0x400000@0x100000(uImage),0x1fb00000@0x500000(rootfs)
ethaddr=00:50:43:01:62:66
recover1=setenv mainlineLinux yes; setenv arcNumber 2097; setenv bootcmd run recover2; saveenv; reset
recover2=run recover3; setenv bootcmd $(real_bootcmd); saveenv; setenv bootargs $(bootargs_console) $(mtdpartitions) root=/dev/ram0 rw ramdisk=0x01100000,8M install_type=nand; bootm 0x00800000 0x01100000
recover3=run recover4; nand erase clean 0x00100000 0x00400000; nand write.e 0x00800000 0x00100000 0x00400000
recover4=usb start; fatload usb 0 0x00800000 uImage; fatload usb 0 0x01100000 initrd
bootargs_root_nand=ubi.mtd=1 root=ubi0:rootfs rootfstype=ubifs
bootcmd_nand=setenv bootargs $(bootargs_console) $(mtdpartitions) $(bootargs_root_nand); nand read.e 0x00800000 0x00100000 0x00400000; bootm 0x00800000
bootargs_root_mmc=root=/dev/mmcblk0p2 rootdelay=5
real_bootcmd=run bootcmd_mmc; run bootcmd_nand
ineLinux=yes
ineLinux=no
Ext=no
ux=no
bootargs_gs=console=ttyS0,115200 root=/dev/nfs rw
ineLinux=yes
ineLinux=no
filesize=1BC6E0
Ext=no
ux=no
x=no
boargs_end)=mv_phone_config=dev0:fxs,dev1:fxs
=no
bootargs_console=console=ttyS0,115200
arcNumber=2097
ainlineLinux=yes
ainlineLinux=no
inlineLinux=no
bootargs=console=ttyS0,115200 root=/dev/mmcblk0p2 rootdelay=10
nlineLinux=no
bootargs_root=root=/dev/mmcblk0p2 rootdelay=10 rootfstype=ext2
bootcmd_mmc=mmcinit; mmcinit; ext2load mmc 0 0x01100000 /uInitrd; ext2load mmc 0 0x00800000 /uImage
bootcmd=setenv bootargs $(bootargs_console) $(bootargs_root); run bootcmd_mmc; bootm 0x0800000
lineLinux=no
stdin=serial
stdout=serial
stderr=serial
nandEnvBase=
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
pcieTune=no

Environment size: 2600/131068 bytes



So I'm stuck again, any ideas anyone?
Logged

tbm
Full Member
***

Karma: 7
Posts: 121



View Profile WWW
« Reply #5 on: March 29, 2010, 04:42:53 AM »

You have mainlineLinux=no, which is not going to work.  Run these commands and it will work:

Code:
setenv mainlineLinux yes
setenv arcNumber 2097
saveenv
reset
Logged

jabjoe
Newbie
*

Karma: 1
Posts: 18


View Profile
« Reply #6 on: March 29, 2010, 08:40:03 AM »

Damn it! Should have seen that! That would have been better! What I did was the nuke u-boot to factory settings and went through the debian tarball u-boot commands again. It's working, but I still can't get it to use a more recent kernel.

I'm doing:

mkimage -A arm -O linux -T kernel -C none -a 0x80008000 -e 0x80008000 -n "Debian kernel" -d ./vmlinuz-2.6.32-2-kirkwood ./uImage
mkimage -A arm -O linux -T ramdisk -C gzip -a 0x00000000 -e 0x00000000 -n "Debian ramdisk" -d ./initrd.img-2.6.32-2-kirkwood ./uInitrd


but when I try and boot I get:

Starting kernel ...

software interrupt
pc : [<90000004>]      lr : [<00649bd4>]
sp : 005ff1b8  ip : 00000079    fp : 006735d8
r10: 00000003  r9 : 00000000    r8 : 005fffcc
r7 : 015db03e  r6 : 01100040    r5 : 00000154  r4 : 00000000
r3 : 80008000  r2 : 00000100    r1 : 00000831  r0 : deadbeef
Flags: Nzcv  IRQs off  FIQs off  Mode SVC_32
Resetting CPU ...


So I set it to use the backup uImage + uInitrd and it boots fine.

Any idea what I'm doing wrong here?
Logged

jabjoe
Newbie
*

Karma: 1
Posts: 18


View Profile
« Reply #7 on: March 29, 2010, 01:43:55 PM »

I see. I should use:

mkimage -A arm -O linux -T kernel -C none -a 0x80000 -e 0x80000 -n "Test Image" -d ./vmlinuz ./uImage
mkimage -A arm -O linux -T ramdisk -C gzip -a 0x0 -e 0x0 -n "Test RamDisk -d ./initrd.img ./uInitrd


Ok, all sorted. Smiley
Logged

tbm
Full Member
***

Karma: 7
Posts: 121



View Profile WWW
« Reply #8 on: March 29, 2010, 01:45:09 PM »

btw, flash-kernel does all of this for you.
Logged

jabjoe
Newbie
*

Karma: 1
Posts: 18


View Profile
« Reply #9 on: March 30, 2010, 02:49:27 AM »

Figured there should be something. But Debian pulled down 2.6.32-2 but the uImage and uInitrd where left 2.6.30

Now I know what to look for, found this:

"During the upgrade process, new kernel packages will be installed automatically and a ramdisk is generated. The SheevaPlug doesn't boot those files directly though and requires special images for u-boot. These images are generated by the tool flash-kernel under Debian. However, due to a bug, flash-kernel is currently not ran automatically when you install a kernel, so you have to run it manually."

http://www.cyrius.com/debian/kirkwood/sheevaplug/faq.html

Least now I know the manual way.  Wink
Logged

Pages: [1]
Print
Jump to: