New IT forum
27 June 2022, 05:11:27 am *
Welcome, %1$s. Please login or register.

: PiHub now in stock.
 
Pages: [1] 2

Author Topic: GuruPlug don't boot the kernel anymore after re-flasing  (Read 31766 times)

Aces

  • Newbie
  • *
  • Posts: 6
GuruPlug don't boot the kernel anymore after re-flasing
« on: 15 February 2011, 02:10:07 pm »

Hello,

I have received last Friday my « GuruPlug Server Plus ». I followed this tutorial in order to update the GuruPlug:
http://www.plugcomputer.org/plugwiki/index.php/New_Plugger_How_To

A lot of errors occurred during the update process, and after the reboot of the device I was unable to access the GuruPlug via SSH anymore.
I also bought a JTAG board for the GuruPlug, so I follow this tutorial thinking making a factory reset:
http://plugcomputer.org/plugwiki/index.php/Reflashing_images_on_the_GuruPlug

I follow the tutorial step by step, but after resetting the device, it doesn’t launch anymore:
Code: [Select]
U-Boot 2009.11-rc1-00602-g28a9c08-dirty (Feb 09 2010 - 18:15:21)
Marvell-Plug2L

SoC:   Kirkwood 88F6281_A0
DRAM:  512 MB
NAND:  512 MiB
In:    serial
Out:   serial
Err:   serial
Net:   egiga0, egiga1
88E1121 Initialized on egiga0
88E1121 Initialized on egiga1
Hit any key to stop autoboot:  0
(Re)start USB...
USB:   Register 10011 NbrPorts 1
USB EHCI 1.00
scanning bus for devices... 3 USB Device(s) found
       scanning bus for storage devices... Device NOT ready
   Request Sense returned 02 3A 00
1 Storage Device(s) found

NAND read: device 0 offset 0x100000, size 0x400000
 4194304 bytes read: OK
## Booting kernel from Legacy Image at 06400000 ...
   Image Name:   Linux-2.6.33.2-00003-g4b82fc0
   Image Type:   ARM Linux Kernel Image (uncompressed)
   Data Size:    2688524 Bytes =  2.6 MB
   Load Address: 00008000
   Entry Point:  00008000
   Verifying Checksum ... OK
   Loading Kernel Image ... OK
OK

Starting kernel ...

Uncompressing Linux... done, booting the kernel.

I waited for several minutes (even hour) but nothing happened! I tried to re-launching the “re-flashing” process three times, always the same issue. I notice the following error during the re-flashing, which occurs the three times:
Code: [Select]
Marvell>> nand erase 0x500000 0x1fb00000

NAND erase: device 0 offset 0x500000, size 0x1fb00000
Skipping bad block at  0x09a20000
Skipping bad block at  0x155c0000
Erasing at 0x1ffe0000 -- 100% complete.
OK
Marvell>> nand write.e 0x6400000 0x500000 0xb940000

NAND write: device 0 offset 0x500000, size 0xb940000
Skip bad block 0x09a20000
 194248704 bytes written: OK

Is it the reason of my issue?

Following is the entire process I make to re-flash the GuruPlug (I just hide the public IP address and cut some ####### lines  ;) ):
Code: [Select]
U-Boot 2009.11-rc1-00602-g28a9c08-dirty (Feb 09 2010 - 18:15:21)
Marvell-Plug2L

SoC:   Kirkwood 88F6281_A0
DRAM:  512 MB
NAND:  512 MiB
In:    serial
Out:   serial
Err:   serial
Net:   egiga0, egiga1
88E1121 Initialized on egiga0
88E1121 Initialized on egiga1
Hit any key to stop autoboot:  0
Marvell>> setenv ipaddr x.x.x.140
Marvell>> setenv serverip x.x.x.83
Marvell>> tftp 0x6400000 uImage-guruplug
Using egiga0 device
TFTP from server x.x.x.83; our IP address is x.x.x.140
Filename 'uImage-guruplug'.
Load address: 0x6400000
Loading: #################################################################
         #################################################################
         ######################################################
done
Bytes transferred = 2688588 (29064c hex)
Marvell>> nand erase 0x100000 0x400000

NAND erase: device 0 offset 0x100000, size 0x400000
Erasing at 0x4e0000 -- 100% complete.
OK
Marvell>> nand write.e 0x6400000 0x100000 0x400000

NAND write: device 0 offset 0x100000, size 0x400000
 4194304 bytes written: OK
Marvell>> <INTERRUPT>
Marvell>> tftp 0x6400000 rootfs.ubi.img
Using egiga0 device
TFTP from server x.x.x.83; our IP address is x.x.x.140
Filename 'rootfs.ubi.img'.
Load address: 0x6400000
Loading: #################################################################
         #################################################################
         #################################################################
[...]
         #################################################################
         ######################################################
         91 MB received
         #################################################################
         #################################################################
[...]
         #################################################################
         ######################################################
         183 MB received
         #################################################################
         #############################################################
done
Bytes transferred = 194248704 (b940000 hex)
Marvell>> nand erase 0x500000 0x1fb00000

NAND erase: device 0 offset 0x500000, size 0x1fb00000
Skipping bad block at  0x09a20000
Skipping bad block at  0x155c0000
Erasing at 0x1ffe0000 -- 100% complete.
OK
Marvell>> nand write.e 0x6400000 0x500000 0xb940000

NAND write: device 0 offset 0x500000, size 0xb940000
Skip bad block 0x09a20000
 194248704 bytes written: OK
Marvell>> setenv x_bootcmd_usb 'usb start'
Marvell>> setenv x_bootcmd_kernel 'nand read.e 0x6400000 0x100000 0x400000'
Marvell>> setenv x_bootargs_root 'ubi.mtd=2 root=ubi0:rootfs rootfstype=ubifs'
Marvell>> setenv x_bootargs 'console=ttyS0,115200'
Marvell>> setenv x_bootcmd '$(x_bootcmd_usb); $(x_bootcmd_kernel); setenv bootargs $(x_bootargs) $(x_bootargs_root) ;bootm 0x6400000;'
Marvell>> setenv bootcmd 'run x_bootcmd'
Marvell>> saveenv
Saving Environment to NAND...
Erasing Nand...
Erasing at 0x40000 -- 100% complete.
Writing to Nand... done
Marvell>> reset
resetting ...


U-Boot 2009.11-rc1-00602-g28a9c08-dirty (Feb 09 2010 - 18:15:21)
Marvell-Plug2L
[...]


What did I make wrong?
Logged

NewIT_Marcus

  • Hero Member
  • *****
  • Posts: 960
Re: GuruPlug don't boot the kernel anymore after re-flasing
« Reply #1 on: 15 February 2011, 07:24:54 pm »

Hello,

I have received last Friday my « GuruPlug Server Plus ». I followed this tutorial in order to update the GuruPlug:
http://www.plugcomputer.org/plugwiki/index.php/New_Plugger_How_To

A lot of errors occurred during the update process, and after the reboot of the device I was unable to access the GuruPlug via SSH anymore.

That page was written originally for the Sheevaplug (which runs Ubuntu, not Debian like the Guruplug). Sections such as that titled "Fixing the existing Ubuntu install" don't apply to the Guruplug. What errors did you see, in response to what commands (was it just the package upgrades)?

I also bought a JTAG board for the GuruPlug, so I follow this tutorial thinking making a factory reset:
http://plugcomputer.org/plugwiki/index.php/Reflashing_images_on_the_GuruPlug

I follow the tutorial step by step, but after resetting the device, it doesn’t launch anymore:
Code: [Select]
U-Boot 2009.11-rc1-00602-g28a9c08-dirty (Feb 09 2010 - 18:15:21)


NAND read: device 0 offset 0x100000, size 0x400000
 4194304 bytes read: OK
## Booting kernel from Legacy Image at 06400000 ...
   Image Name:   Linux-2.6.33.2-00003-g4b82fc0
   Image Type:   ARM Linux Kernel Image (uncompressed)
   Data Size:    2688524 Bytes =  2.6 MB
   Load Address: 00008000
   Entry Point:  00008000
   Verifying Checksum ... OK
   Loading Kernel Image ... OK
OK

Starting kernel ...

Uncompressing Linux... done, booting the kernel.



Your version of U-Boot looks OK. But on my original Guruplug I have this kernel:
Code: [Select]
NAND read: device 0 offset 0x100000, size 0x400000
 4194304 bytes read: OK
## Booting kernel from Legacy Image at 06400000 ...
   Image Name:   Linux-2.6.32-00007-g56678ec
   Image Type:   ARM Linux Kernel Image (uncompressed)
   Data Size:    2789756 Bytes =  2.7 MB
   Load Address: 00008000
   Entry Point:  00008000
   Verifying Checksum ... OK
   Loading Kernel Image ... OK
OK

Starting kernel ...

Uncompressing Linux.............................................................
Linux version 2.6.32-00007-g56678ec ([email protected]) (gcc ver0

I can't see anything obviously wrong in what you copied & pasted. The bad blocks are normal. Did you change any environment variables?
Logged

Aces

  • Newbie
  • *
  • Posts: 6
Re: GuruPlug don't boot the kernel anymore after re-flasing
« Reply #2 on: 16 February 2011, 12:16:02 am »

Thanks Marcus for your answer :)

That page was written originally for the Sheevaplug (which runs Ubuntu, not Debian like the Guruplug). Sections such as that titled "Fixing the existing Ubuntu install" don't apply to the Guruplug. What errors did you see, in response to what commands (was it just the package upgrades)?
Ok, that's why all modifications in section "Fixing the existing Ubuntu install" were already done. I just launched the following command:
Code: [Select]
apt-get update
apt-get dist-upgrade
apt-get autoremove
I made the same thing on a previous GuruPlug and everything was ok. BTW, I didn't note the errors which occurred, and I didn't remember...

Your version of U-Boot looks OK. But on my original Guruplug I have this kernel:
Code: [Select]
NAND read: device 0 offset 0x100000, size 0x400000
 4194304 bytes read: OK
## Booting kernel from Legacy Image at 06400000 ...
   Image Name:   Linux-2.6.32-00007-g56678ec
   Image Type:   ARM Linux Kernel Image (uncompressed)
   Data Size:    2789756 Bytes =  2.7 MB
   Load Address: 00008000
   Entry Point:  00008000
   Verifying Checksum ... OK
   Loading Kernel Image ... OK
OK
Yes, I noticed this thing (I have 3 GuruPlug, one "old", upgraded with previous command, and another new one,  but I have to give it to the man who give me the first one, so I can't modify it... Complicated story ;) )
BTW, I also try to deploy the Linux-2.6.32.7 kernel, found on that website (http://sheeva.with-linux.com/sheeva/2.6.32.7/), but it is also for Sheevaplug. I thought it could work... no :(

So I use my unmodified GuruPlug in order to copy the kernel, and I deployed it on my BrokenPlug!
Code: [Select]
dd if=/dev/mtdblock1 of=uImageIt works! The kernel is decompressed and launched successfully. I can access the GuruPlug via SSH.
But the RootFs image I used seems to be the wrong one (I use this one: http://openplug.org/index.php/us/resources/downloads?func=fileinfo&id=78) because some errors occurs at the end of the launch. I think this is the same trouble: RootFs image is probably for sheevaplug?
Code: [Select]
INIT: version 2.86 booting
Starting the hotplug events dispatcher: udevd.
Synthesizing the initial hotplug events...done.
Waiting for /dev to be fully populated...done.
Setting the system clock.
scsi 1:0:0:0: Direct-Access     Generic  STORAGE DEVICE   9909 PQ: 0 ANSI: 0
sd 1:0:0:0: Attached scsi generic sg0 type 0
sd 1:0:0:0: [sda] Attached SCSI removable disk
scsi 1:0:0:1: Direct-Access     Generic  STORAGE DEVICE   9909 PQ: 0 ANSI: 0
sd 1:0:0:1: Attached scsi generic sg1 type 0
sd 1:0:0:1: [sdb] Attached SCSI removable disk
Activating swap...done.
Setting the system clock.
Cleaning up ifupdown....
Loading kernel modules...FATAL: Could not load /lib/modules/2.6.32-00007-g56678ec/modules.dep: No such file or directory
Checking file systems...fsck 1.41.3 (12-Oct-2008)
done.
Setting kernel variables (/etc/sysctl.conf)...done.
Mounting local filesystems...done.
Activating swapfile swap...done.
Setting up networking....
Configuring network interfaces...done.
Starting portmap daemon....
Setting up ALSA...done (none loaded).
INIT: Entering runlevel: 2
Starting enhanced syslogd: rsyslogd.
Starting system message bus: dbus.
Starting OpenBSD Secure Shell server: sshd.
Starting MySQL database server: mysqld.
Checking for corrupt, not cleanly closed and upgrade needing tables..
Starting MTA: exim4.
ALERT: exim paniclog /var/log/exim4/paniclog has non-zero size, mail system possibly broken failed!
Starting Network Interface Plugging Daemon: eth0 eth1.
Starting web server: lighttpd.
Starting Samba daemons: nmbd smbd.
Starting file alteration monitor: FAM.
Starting NTP server: ntpd.
warning: `ntpd' uses 32-bit capabilities (legacy support in use)
Starting periodic command scheduler: crond.
uap0: error fetching interface information: Device not found
FATAL: Could not load /lib/modules/2.6.32-00007-g56678ec/modules.dep: No such file or directory
SIOCSIFADDR: No such device
uap0: ERROR while getting interface flags: No such device
uap0: ERROR while getting interface flags: No such device
No such device
ERR:UAPHOSTCMD is not supported by uap0
ERR:Command sending failed!
No such device
ERR:UAPHOSTCMD is not supported by uap0
ERR:Command sending failed!
FATAL: Could not load /lib/modules/2.6.32-00007-g56678ec/modules.dep: No such file or directory
iptables v1.4.2: can't initialize iptables table `nat': iptables who? (do you need to insmod?)
Perhaps iptables or your kernel needs to be upgraded.
FATAL: Could not load /lib/modules/2.6.32-00007-g56678ec/modules.dep: No such file or directory
iptables v1.4.2: can't initialize iptables table `nat': iptables who? (do you need to insmod?)
Perhaps iptables or your kernel needs to be upgraded.
Starting very small DHCP server: udhcpd (v0.9.9-pre) started
Unable to open /var/lib/udhcpd.leases for reading
SIOCGIFADDR failed, is the interface up and configured?: No such device
Starting DNS forwarder and DHCP server: dnsmasq.
FATAL: Could not load /lib/modules/2.6.32-00007-g56678ec/modules.dep: No such file or directory
iptables v1.4.2: can't initialize iptables table `filter': iptables who? (do you need to insmod?)
Perhaps iptables or your kernel needs to be upgraded.
ERROR: Module btmrvl_sdio does not exist in /proc/modules
ERROR: Module btmrvl does not exist in /proc/modules
Starting bluetooth:eth0: link up, 1000 Mb/s, full duplex, flow control disabled
 bluetoothd.
FATAL: Could not load /lib/modules/2.6.32-00007-g56678ec/modules.dep: No such file or directory
Can't open HCI socket.: Address family not supported by protocol
Can't open HCI socket.: Address family not supported by protocol
ls: cannot access /sys/class/leds/guruplug:green:health/brightness: No such file or directory
ls: cannot access /sys/class/leds/guruplug:green:health/brightness: No such file or directory
/root/init_setup.sh: line 32: `eval ls /sys/class/leds/guruplug\:green\:health/brightness`: ambiguous redirect
ls: cannot access /sys/class/leds/guruplug:green:wmode/brightness: No such file or directory
ls: cannot access /sys/class/leds/guruplug:green:wmode/brightness: No such file or directory
/root/init_setup.sh: line 33: `eval ls /sys/class/leds/guruplug\:green\:wmode/brightness`: ambiguous redirect

Debian GNU/Linux 5.0 guruplug-debian ttyS0

guruplug-debian login: root
Do you know where I can find the right "rootfs" image?


I can't see anything obviously wrong in what you copied & pasted. The bad blocks are normal. Did you change any environment variables?
Yes, I made some modifications of environment variables. I set all values to the default one, using this post (http://www.newit.co.uk/forum/index.php/topic,400.0.html), except the first one, bootcmd, because uboot failed when I try to set it, due to too many parameters (16max.).

I use the following command line instead:
Code: [Select]
setenv bootcmd '$(x_bootcmd_usb); $(x_bootcmd_kernel); setenv bootargs $(x_bootargs) $(x_bootargs_root); bootm 0x6400000;'I don't think it is problematic...


Thanks in advance,
Sylvain
Logged

NewIT_Marcus

  • Hero Member
  • *****
  • Posts: 960
Re: GuruPlug don't boot the kernel anymore after re-flasing
« Reply #3 on: 16 February 2011, 08:35:01 am »


But the RootFs image I used seems to be the wrong one (I use this one: http://openplug.org/index.php/us/resources/downloads?func=fileinfo&id=78) because some errors occurs at the end of the launch. I think this is the same trouble: RootFs image is probably for sheevaplug?
Code: [Select]
Loading kernel modules...FATAL: Could not load /lib/modules/2.6.32-00007-g56678ec/modules.dep: No such file or directory
FATAL: Could not load /lib/modules/2.6.32-00007-g56678ec/modules.dep: No such file or directory
Do you know where I can find the right "rootfs" image?

You used the right rootfs. It's linked to from here . The module errors are "normal". Perform a kernel upgrade, using the sheeva.with-linux kernel, and using the script provided, and the errors will go away.
Logged

Aces

  • Newbie
  • *
  • Posts: 6
Re: GuruPlug don't boot the kernel anymore after re-flasing
« Reply #4 on: 16 February 2011, 10:39:32 am »

You used the right rootfs. It's linked to from here . The module errors are "normal". Perform a kernel upgrade, using the sheeva.with-linux kernel, and using the script provided, and the errors will go away.
Yes, I found the link for the rootfs image on this topic (Reflashing_images_on_the_GuruPlug), but I also found the kernel image on this topic and it seems it is not the good one!
I don't really understand what should I do to upgrade the device! Should I replace the kernel copied from my "clean" GuruPlug with a kernel found on sheeva.with-linux? I already try to deploy kernels from this site (sheeva-2.6.33.2-uImage and sheeva-2.6.32.7-uImage) but it didn't worked, the guru was blocked during boot:
Code: [Select]
Starting kernel ...

Uncompressing Linux... done, booting the kernel.
Which version of the kernel should I use, and what is the script you are talking about?


I just see I have a new trouble with the guruPlug: the MAC address is not configure in Linux:
Code: [Select]
guruplug-debian:~# ifconfig
eth0      Link encap:Ethernet  HWaddr 00:00:00:00:00:00
          inet addr:x.x.98.39  Bcast:x.x.127.255  Mask:255.255.128.0
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:321 errors:0 dropped:0 overruns:0 frame:0
          TX packets:85 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:29500 (28.8 KiB)  TX bytes:5782 (5.6 KiB)
          Interrupt:11

eth1      Link encap:Ethernet  HWaddr 00:00:00:00:00:00
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:0 (0.0 B)  TX bytes:0 (0.0 B)
          Interrupt:15

lo        Link encap:Local Loopback
          inet addr:127.0.0.1  Mask:255.0.0.0
          UP LOOPBACK RUNNING  MTU:16436  Metric:1
          RX packets:12 errors:0 dropped:0 overruns:0 frame:0
          TX packets:12 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0
          RX bytes:680 (680.0 B)  TX bytes:680 (680.0 B)

guruplug-debian:
Consequently, the guruPlug does not receive the correct IP address with the DHCP. Is this issue caused by the kernel copied from my another device?

Thx,
Sylvain
Logged

NewIT_Marcus

  • Hero Member
  • *****
  • Posts: 960
Re: GuruPlug don't boot the kernel anymore after re-flasing
« Reply #5 on: 16 February 2011, 05:50:17 pm »

You used the right rootfs. It's linked to from here . The module errors are "normal". Perform a kernel upgrade, using the sheeva.with-linux kernel, and using the script provided, and the errors will go away.
Yes, I found the link for the rootfs image on this topic (Reflashing_images_on_the_GuruPlug), but I also found the kernel image on this topic and it seems it is not the good one!
I don't really understand what should I do to upgrade the device! Should I replace the kernel copied from my "clean" GuruPlug with a kernel found on sheeva.with-linux? I already try to deploy kernels from this site (sheeva-2.6.33.2-uImage and sheeva-2.6.32.7-uImage) but it didn't worked, the guru was blocked during boot:
Code: [Select]
Starting kernel ...

Uncompressing Linux... done, booting the kernel.
Which version of the kernel should I use, and what is the script you are talking about?

The kernel upgrade scripts at sheeva.with-linux have names README-<kernel-version>

I just see I have a new trouble with the guruPlug: the MAC address is not configure in Linux:
Code: [Select]
guruplug-debian:~# ifconfig
eth0      Link encap:Ethernet  HWaddr 00:00:00:00:00:00
          inet addr:x.x.98.39  Bcast:x.x.127.255  Mask:255.255.128.0
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:321 errors:0 dropped:0 overruns:0 frame:0
          TX packets:85 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:29500 (28.8 KiB)  TX bytes:5782 (5.6 KiB)
          Interrupt:11

eth1      Link encap:Ethernet  HWaddr 00:00:00:00:00:00
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:0 (0.0 B)  TX bytes:0 (0.0 B)
          Interrupt:15

lo        Link encap:Local Loopback
          inet addr:127.0.0.1  Mask:255.0.0.0
          UP LOOPBACK RUNNING  MTU:16436  Metric:1
          RX packets:12 errors:0 dropped:0 overruns:0 frame:0
          TX packets:12 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0
          RX bytes:680 (680.0 B)  TX bytes:680 (680.0 B)

guruplug-debian:
Consequently, the guruPlug does not receive the correct IP address with the DHCP. Is this issue caused by the kernel copied from my another device?

Thx,
Sylvain

I cannot possibly imagine how ifconfig can report 2 ethernet devices, both with MAC address 00:00:00:00:00:00. Check your environment variables, specifically ethaddr and eth1addr. These 2 environment variables should have the same values as the MAC addresses shown on the underside of your plug.

Suffice to say, if you look at the READMEs at sheeva.with-linux you will discover how the kernel can be updated, and by attempting that, you'll know the answer to your final question. Since you appear not to have any networking capability, you'll have to use a USB stick or similar to transport the files.
Logged

Aces

  • Newbie
  • *
  • Posts: 6
Re: GuruPlug don't boot the kernel anymore after re-flasing
« Reply #6 on: 17 February 2011, 12:31:43 am »

 >:( The tutorial Reflashing images on the GuruPlug contains several big errors...

I successfully fixed my issue with MAC address! I think the solution could be useful for other Guruplug's users. In fact, the network chip does not "known" the MAC address reserved for the 2 gigabit interfaces of the GuruPlug. The addresses are inferred from the environment variables of u-boot ethaddr and eth1addr. But it is not really understandable when simply looking at the bootcmd environment variable (here for example).

When I tried to re-flashing the Guruplug, I modified the environment variables according to the "re-flashing Guruplug" tutorial on the plugcomputer wiki. For example:
Code: [Select]
setenv x_bootcmd '$(x_bootcmd_usb); $(x_bootcmd_kernel); setenv bootargs $(x_bootargs) $(x_bootargs_root) ;bootm 0x6400000;'
setenv bootcmd 'run x_bootcmd'

Following your advices, I then tried to reinitialize the variables, but an error occurred (Too many arguments, 16 max.) with the following command:
Code: [Select]
setenv bootcmd 'setenv ethact egiga0; ${x_bootcmd_ethernet}; setenv ethact egiga1; ${x_bootcmd_ethernet}; ${x_bootcmd_usb}; ${x_bootcmd_kernel}; setenv bootargs ${x_bootargs} ${x_bootargs_root}; bootm 0x6400000;'
So I deleted a part of the command, thinking it was not important (pinging 192.168.2.1 has no interest!!!  ;D):
Code: [Select]
setenv bootcmd '${x_bootcmd_usb}; ${x_bootcmd_kernel}; setenv bootargs ${x_bootargs} ${x_bootargs_root}; bootm 0x6400000;'In fact, that is these commands which allow the network card driver to successfully getting the right MAC addresses. In order to restore the right value of bootcmd environment variable, editenv command must be used, not setenv.

I will try tomorrow to use the files from sheeva.with-linux website (too late for today ;) ), but I have a last (stupid! ::) (sorry, I and my brain are very tired...) ) question: after setting the environment variables according to the README file, the script must be launched from u-boot or from Linux?  :-[
« Last Edit: 17 February 2011, 12:38:30 am by Aces »
Logged

NewIT_Marcus

  • Hero Member
  • *****
  • Posts: 960
Re: GuruPlug don't boot the kernel anymore after re-flasing
« Reply #7 on: 17 February 2011, 08:30:56 am »

I will try tomorrow to use the files from sheeva.with-linux website (too late for today ;) ), but I have a last (stupid! ::) (sorry, I and my brain are very tired...) ) question: after setting the environment variables according to the README file, the script must be launched from u-boot or from Linux?  :-[

From linux.
Logged

Aces

  • Newbie
  • *
  • Posts: 6
Re: GuruPlug don't boot the kernel anymore after re-flasing
« Reply #8 on: 17 February 2011, 01:36:40 pm »

I will try tomorrow to use the files from sheeva.with-linux website (too late for today ;) ), but I have a last (stupid! ::) (sorry, I and my brain are very tired...) ) question: after setting the environment variables according to the README file, the script must be launched from u-boot or from Linux?  :-[

From linux.

Thks Marcus.
I still have a question...  :-[ ! I used 2.6.37 kernel from sheeva.with-linux.com following this tutorial: Install_Prebuilt_Kernels_From_sheeva.with-linux.com. I did not used 2.6.32.7 because the readme file of this version does not contains note for guruplug, unlike for version 2.6.34.2+.

The only differences between the tutorial and what I did are:
  • launching the script from the Linux of the GuruPlug:
Code: [Select]
./README-2.6.37 --nandkernel
  • Modification of environment variables (according to "# setenv arcNumber 2659 # for guruplugs" in README-2.6.37)
Code: [Select]
setenv arcNumber 2659
My problem is the last command:
Code: [Select]
####### change bootargs, replace nand_mtd with orion_nand and add rootfstype=jffs2
# setenv bootargs rootfstype=jffs2 console=ttyS0,115200 mtdparts=orion_nand:[email protected](uImage),[email protected](rootfs) rw root=/dev/mtdblock1 rw ip=192.168.1.9:192.168.1.4:192.168.1.4:255.255.255.0:DB88FXX81:eth0:none
# saveenv

My environment variables are as following, so I do not see how to modify it...
Code: [Select]
x_bootargs=console=ttyS0,115200
x_bootargs_root=ubi.mtd=2 root=ubi0:rootfs rootfstype=ubifs

I tried several things (with and without modifications of the env. variables), but each time the booting process is blocked when the GuruPlug tries to boot the kernel... I think I must not modifying rootfstype because mine is ubifs but not sure... And I have no mtdparts variable :( .

The solution seems very close, but...

Thanks,
Sylvain
Logged

NewIT_Marcus

  • Hero Member
  • *****
  • Posts: 960
Re: GuruPlug don't boot the kernel anymore after re-flasing
« Reply #9 on: 17 February 2011, 05:41:14 pm »

The instruction to change the environment variables is for Sheevaplugs. Ignore it. Don't change the environment variables, except for

Code: [Select]
setenv mainlineLinux yes
setenv arcNumber 2659
saveenv
reset

If it doesn't boot, you must post your bootlog, as far as it does boot, and your environment variables.
Logged

Aces

  • Newbie
  • *
  • Posts: 6
Re: GuruPlug don't boot the kernel anymore after re-flasing
« Reply #10 on: 19 February 2011, 09:28:50 pm »

In fact, it seems that my u-boot version (=default version provided on the GuruPlug, 2009.11-rc1) is not compatible with the kernel provided on the official website.

I'm not sure there is no risk to upgrade the u-boot program, so I searched another solution.

I have temporarily another guruPlug, unmodified, so I used this other device to retrieve some files:
Code: [Select]
dd if=/dev/mtdblock1 of=uImage-GuruUnmodified
Code: [Select]
tar cvf /home/guru-2.6.32-00007-g56678ec.tar /lib/firmware/ /lib/modules/ /sys/class/leds/ /root/init_setup.sh /root/uap8xxx.ko /root/wlan.sh /usr/bin/mute-agent /var/lib/udhcpd.leases /usr/include/dbus-1.0/ /usr/lib/libdbus-* /usr/lib/pkgconfig/dbus-python.pc /usr/lib/python-support/python-dbus/ /usr/share/doc/libdbus-glib-1-2/ /usr/share/doc/python-dbus/ /usr/share/python-support/python-dbus/ /var/lib/dpkg/info/libdbus-* /var/lib/dpkg/info/python-dbus.* /var/lib/python-support/python2.5/dbus* /var/lib/python-support/python2.5/_dbus*
It is now possible for me to restore my broken GuruPlug. It is probably not the best solution but it seems working :)

When I have time, I would try to update the kernel and the u-boot version.

Regards,
Sylvain


Logged

marxjohnson

  • Newbie
  • *
  • Posts: 7
Re: GuruPlug don't boot the kernel anymore after re-flasing
« Reply #11 on: 03 April 2011, 09:58:59 pm »

I followed the instructions on http://www.openplug.org/plugwiki/index.php/Reflashing_images_on_the_GuruPlug to re-flash my plug, and now get this when attempting to boot:
Code: [Select]
U-Boot 2009.11-rc1-00602-g8e6db3d (Dec 24 2009 - 03:11:17)
Marvell-Plug2

SoC:   Kirkwood 88F6281_A0
DRAM:  512 MB
NAND:  512 MiB
In:    serial
Out:   serial
Err:   serial
Net:   egiga0
88E1121 Initialized on egiga0
Hit any key to stop autoboot:  0
(Re)start USB...
USB:   Register 10011 NbrPorts 1
USB EHCI 1.00
scanning bus for devices... 2 USB Device(s) found
       scanning bus for storage devices... 0 Storage Device(s) found

NAND read: device 0 offset 0x100000, size 0x400000
 4194304 bytes read: OK
## Booting kernel from Legacy Image at 06400000 ...
   Image Name:   Linux-2.6.33.2-00003-g4b82fc0
   Image Type:   ARM Linux Kernel Image (uncompressed)
   Data Size:    2688524 Bytes =  2.6 MB
   Load Address: 00008000
   Entry Point:  00008000
   Verifying Checksum ... OK
   Loading Kernel Image ... OK
OK

Starting kernel ...

Uncompressing Linux... done, booting the kernel.
After which it hangs.

The instruction to change the environment variables is for Sheevaplugs. Ignore it. Don't change the environment variables, except for

Code: [Select]
setenv mainlineLinux yes
setenv arcNumber 2659
saveenv
reset

If it doesn't boot, you must post your bootlog, as far as it does boot, and your environment variables.
(edit):
Here's my environment variables:
Code: [Select]
Marvell>> printenv
bootdelay=3
baudrate=115200
x_bootcmd_ethernet=ping 192.168.2.1
ethact=egiga0
ethaddr=F0:AD:4E:FF:11:65
filesize=B940000
fileaddr=6400000
ipaddr=192.168.0.9
serverip=192.168.0.2
x_bootcmd_usb=usb start
x_bootcmd_kernel=nand read.e 0x6400000 0x100000 0x400000
x_bootargs_root=ubi.mtd=2 root=ubi0:rootfs rootfstype=ubifs
x_bootargs=console=ttyS0,115200
x_bootcmd=$(x_bootcmd_usb); $(x_bootcmd_kernel); setenv bootargs $(x_bootargs) $(x_bootargs_root) ;bootm 0x6400000;
bootcmd=run x_bootcmd
mainlineLinux=yes
arcNumber=2659
stdin=serial
stdout=serial
stderr=serial

Environment size: 563/131068 bytes

Many Thanks
Mark
« Last Edit: 03 April 2011, 10:10:03 pm by marxjohnson »
Logged

NewIT_Marcus

  • Hero Member
  • *****
  • Posts: 960
Re: GuruPlug don't boot the kernel anymore after re-flasing
« Reply #12 on: 04 April 2011, 07:21:06 am »

The arcNumber change is only relevant if you are using a kernel that is not the original kernel.

If you use the original kernel, neither arcNumber not mainlineLinux should not be set.

If you use a sheeva.with-linux kernel, they should be set as previously mentioned.
Logged

marxjohnson

  • Newbie
  • *
  • Posts: 7
Re: GuruPlug don't boot the kernel anymore after re-flasing
« Reply #13 on: 04 April 2011, 03:52:09 pm »

Thanks Marcus,
I must admit, I've found the instructions in this thread quite confusing.
I initially re-flashed and set the environment up as described on the PlugWiki page, and experienced the problem I described.
I then saw your post saying those instructions were only for sheevaplugs, and arcNumber and mainlineLinux needed setting (I didn't realise that this was only for the kernel mentioned in another post), so I set them, but to no avail.

Should I try setting the environment back to match this post? http://www.newit.co.uk/forum/index.php/topic,400.0.html
If so, how do I unset the variables that I've set erronously?

Many Thanks
Mark
Logged

NewIT_Marcus

  • Hero Member
  • *****
  • Posts: 960
Re: GuruPlug don't boot the kernel anymore after re-flasing
« Reply #14 on: 04 April 2011, 04:55:31 pm »

Should I try setting the environment back to match this post? http://www.newit.co.uk/forum/index.php/topic,400.0.html
If so, how do I unset the variables that I've set erronously?

If you are trying to rest the Guruplug to a condition similar to its original ex-factory settings, then yes, you should also reset the environment variables.

To clear an erroneous environment variable:

Code: [Select]
setenv arcNumber

will clear arcNumber, for instance. Often you must saveenv before attempting to boot (I don't actually know when this is required and when it's not required, therefore I mention it so that you can be aware).
Logged
Pages: [1] 2
 
 

Powered by MySQL Powered by PHP SMF 2.0.10 | SMF © 2015, Simple Machines Valid XHTML 1.0! Valid CSS!