Welcome! Log In Create A New Profile

Advanced

Dockstar stops working

Posted by Paul 
Dockstar stops working
October 25, 2010 12:51PM
My Dockstar has both Rescue System and readonly emdebian on NAND installed. Both systems worked well before. Also I used rescue system to build a couple of USB flash (4GB) Debian Lenny system, because I need large space to run Asterisk. Today, I used Rescue system to build another Debian Lenny on flash drive. After complete installation, I typed “Y” to restart the Docksatr. However, It stuck there and I can not get its IP address through router. If boot it from flash drive or just from Rescue system (without flash drive attached) , the light goes: green flash --> orange solid --> green solid, then keeping solid green light forever. Did anybody encounter this problems? I need your help. Thanks.
Re: Dockstar stops working
October 25, 2010 06:06PM
Configure netconsole and watch the boot log. It should show you where things are going wrong. If you're still having trouble, post your netconsole log.

-- Jeff
Re: Dockstar stops working
October 25, 2010 06:56PM
Thanks, Jeff.
I don't know if my Dockstar is okay to use IP address.However, the Dockstar's IP is not showed on my routewr and my PC's IP address is displayed on my router. Meanwhile, I can not access the Dockstar with Putty. Can I get the netconsole log in this situation?
Re: Dockstar stops working
October 25, 2010 07:48PM
Yes, you can still use netconsole. With netconsole, you tell the Dockstar what IP address to use, instead of letting it get one from your router.

-- Jeff
Re: Dockstar stops working
October 25, 2010 11:20PM
Hi, Jeff,
1. How to do "With netconsole, you tell the Dockstar what IP address to use..."? At PC side?
2. where to apply these below commands ( I mean how I can apply these commands to Dockstar because SSH doesn't work)
fw_setenv serverip 192.168.1.2
fw_setenv ipaddr 192.168.1.100
fw_setenv if_netconsole 'ping $serverip' 
......



Edited 1 time(s). Last edit at 10/26/2010 07:33PM by Paul.
Re: Dockstar stops working
October 26, 2010 09:03AM
I'm sorry, I misread your original post.

It sounds like your Dockstar may be getting hung up while attempting to boot from your nand installation. If that's the case, you can force it to boot the rescue system by creating an empty file named 'rescueme' on the root of your ext2 formatted USB drive. Make sure that drive is the only thing connected to the Dockstar and then reboot. With any luck, that will get you into the rescue system and you can use that to configure netconsole.

-- Jeff
Re: Dockstar stops working
October 26, 2010 01:39PM
"It sounds like your Dockstar may be getting hung up while attempting to boot from your nand installation. If that's the case, you can force it to boot the rescue system by creating an empty file named 'rescueme' on the root of your ext2 formatted USB drive. ....."

Hi, Jeff,
You are right! The Dockstar booted successfully from Rescue System with the USB drive attached. Without USB drive attached, Dockstar still doesn't work. The netconsole log is below:
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
** Block device usb 0 not supported

** Invalid boot device **
Creating 1 MTD partitions on "nand0":
0x000002500000-0x000010000000 : "mtd=3"
UBI: attaching mtd1 to ubi0
UBI: physical eraseblock size:   131072 bytes (128 KiB)
UBI: logical eraseblock size:    129024 bytes
UBI: smallest flash I/O unit:    2048
UBI: sub-page size:              512
UBI: VID header offset:          512 (aligned 512)
UBI: data offset:                2048
UBI: attached mtd1 to ubi0
UBI: MTD device name:            "mtd=3"
UBI: MTD device size:            219 MiB
UBI: number of good PEBs:        1752
UBI: number of bad PEBs:         0
UBI: max. allowed volumes:       128
UBI: wear-leveling threshold:    4096
UBI: number of internal volumes: 1
UBI: number of user volumes:     1
UBI: available PEBs:             0
UBI: total number of reserved PEBs: 1752
UBI: number of PEBs reserved for bad PEB handling: 17
UBI: max/mean erase counter: 1/0
UBIFS: recovery needed
UBIFS: recovery deferred
UBIFS: mounted UBI device 0, volume 0, name "rootfs"
UBIFS: mounted read-only
UBIFS: file system size:   221921280 bytes (216720 KiB, 211 MiB, 1720 LEBs)
UBIFS: journal size:       11096064 bytes (10836 KiB, 10 MiB, 86 LEBs)
UBIFS: media format:       w4/r0 (latest is w4/r0)
UBIFS: default compressor: LZO
UBIFS: reserved for root:  5182151 bytes (5060 KiB)
Loading file '/boot/uImage' to addr 0x00800000 with size 1438876 (0x0015f49c)...
Done
Loading file '/boot/uInitrd' to addr 0x01100000 with size 4873789 (0x004a5e3d)...
Done
## Booting kernel from Legacy Image at 00800000 ...
   Image Name:   Linux-2.6.32-dockstar
   Image Type:   ARM Linux Kernel Image (uncompressed)
   Data Size:    1438812 Bytes = 1.4 MiB
   Load Address: 00008000
   Entry Point:  00008000
   Verifying Checksum ... OK
## Loading init Ramdisk from Legacy Image at 01100000 ...
   Image Name:   initramfs-2.6.32-dockstar
   Image Type:   ARM Linux RAMDisk Image (gzip compressed)
   Data Size:    4873725 Bytes = 4.6 MiB
   Load Address: 00000000
   Entry Point:  00000000
   Verifying Checksum ... OK
   Loading Kernel Image ... OK
OK

Starting kernel ...



Edited 1 time(s). Last edit at 10/26/2010 07:34PM by Paul.
Re: Dockstar stops working
October 26, 2010 01:46PM
If attach a USB drive that has Debian installed before, the Dockstar still doesn't work. The netconsole log is:
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... 1 Storage Device(s) found
Loading file "/rescueme" from usb device 0:1 (usbda1)
** File not found /rescueme
reading /rescueme.txt

** Unable to read "/rescueme.txt" from usb 0:1 **
Creating 1 MTD partitions on "nand0":
0x000002500000-0x000010000000 : "mtd=3"
UBI: attaching mtd1 to ubi0
UBI: physical eraseblock size:   131072 bytes (128 KiB)
UBI: logical eraseblock size:    129024 bytes
UBI: smallest flash I/O unit:    2048
UBI: sub-page size:              512
UBI: VID header offset:          512 (aligned 512)
UBI: data offset:                2048
UBI: attached mtd1 to ubi0
UBI: MTD device name:            "mtd=3"
UBI: MTD device size:            219 MiB
UBI: number of good PEBs:        1752
UBI: number of bad PEBs:         0
UBI: max. allowed volumes:       128
UBI: wear-leveling threshold:    4096
UBI: number of internal volumes: 1
UBI: number of user volumes:     1
UBI: available PEBs:             0
UBI: total number of reserved PEBs: 1752
UBI: number of PEBs reserved for bad PEB handling: 17
UBI: max/mean erase counter: 1/0
UBIFS: recovery needed
UBIFS: recovery deferred
UBIFS: mounted UBI device 0, volume 0, name "rootfs"
UBIFS: mounted read-only
UBIFS: file system size:   221921280 bytes (216720 KiB, 211 MiB, 1720 LEBs)
UBIFS: journal size:       11096064 bytes (10836 KiB, 10 MiB, 86 LEBs)
UBIFS: media format:       w4/r0 (latest is w4/r0)
UBIFS: default compressor: LZO
UBIFS: reserved for root:  5182151 bytes (5060 KiB)
Loading file '/boot/uImage' to addr 0x00800000 with size 1438876 (0x0015f49c)...
Done
Loading file '/boot/uInitrd' to addr 0x01100000 with size 4873789 (0x004a5e3d)...
Done
## Booting kernel from Legacy Image at 00800000 ...
   Image Name:   Linux-2.6.32-dockstar
   Image Type:   ARM Linux Kernel Image (uncompressed)
   Data Size:    1438812 Bytes = 1.4 MiB
   Load Address: 00008000
   Entry Point:  00008000
   Verifying Checksum ... OK
## Loading init Ramdisk from Legacy Image at 01100000 ...
   Image Name:   initramfs-2.6.32-dockstar
   Image Type:   ARM Linux RAMDisk Image (gzip compressed)
   Data Size:    4873725 Bytes = 4.6 MiB
   Load Address: 00000000
   Entry Point:  00000000
   Verifying Checksum ... OK
   Loading Kernel Image ... OK
OK

Starting kernel ...



Edited 1 time(s). Last edit at 10/26/2010 07:35PM by Paul.
Re: Dockstar stops working
October 26, 2010 02:31PM
It doesn't look like you have any problems with your uBoot config. It's loading and booting the system on nand just fine. The line
Starting kernel ... 
is where the kernel takes over and stops sending netconsole messages.

Unfortunately, something happens after the kernel takes over. The default kernel doesn't support netconsole, so unless you attach a serial cable it's going to be very difficult to diagnose. The fact that the LED turns green usually means that everything booted properly and the network is up and running. Are you sure the device isn't just getting a different IP address?

The good news is that you can use the rescue system to get to your ubifs partition:
ubiattach /dev/ubi_ctrl -m 3
mkdir /tmp/ubifs
mount -t ubifs ubi0:rootfs /tmp/ubifs

You can try altering config files to see if you can get it to boot, however, without a serial cable that's probably going to be very frustrating work.

The Debian flash drive does not boot because uBoot tries to boot from nand first. If you'd like to just go back to booting from the flash drives, you can disable your nand partition by mounting it as above and then renaming /tmp/ubifs/boot/uImage to something else. This way uBoot will fail when trying to boot from nand and will then try to boot from the USB drive.

-- Jeff
Re: Dockstar stops working
October 26, 2010 04:42PM
Got errors:
rescue:/# ubiattach /dev/ubi_ctrl -m 3
libubi: error!: cannot open "/dev/ubi_ctrl"
        error! 2 (No such file or directory)
ubiattach: error!: cannot attach mtd3
           error 2 (No such file or directory)



Edited 1 time(s). Last edit at 10/26/2010 07:37PM by Paul.
Re: Dockstar stops working
October 26, 2010 06:44PM
Looks like you'll have to manually create the ubi_ctrl device. Try this

mount -o remount,rw /
mknod /dev/ubi_ctrl c 10 62
mount -o remount,ro /

ubiattach /dev/ubi_ctrl -m 3
mkdir /tmp/ubifs
mount -t ubifs ubi1:rootfs /tmp/ubifs

-- Jeff
Re: Dockstar stops working
October 26, 2010 08:19PM
Hi, Jeff,

The Dockstar works now. I appreciate you help.
Re: Dockstar stops working
October 26, 2010 09:02PM
I'm glad you got it fixed. Out of curiosity, did you figure out what was wrong with your nand partition? Or did you just switch to USB booting?
Re: Dockstar stops working
October 26, 2010 09:36PM
"...you can disable your nand partition by mounting it as above and then renaming /tmp/ubifs/boot/uImage to something else"...

After disabling the nand partition, both Rescue System and USB booting work correctly. It's enough to satisfy my work. Thank you again, Jeff!

By the way, can we duplicate the bootable USB drive (including ALL application files in it)?



Edited 1 time(s). Last edit at 10/26/2010 09:41PM by Paul.
Wolfgang
Re: Dockstar stops working
October 27, 2010 07:58AM
Paul Wrote:
-------------------------------------------------------
> By the way, can we duplicate the bootable USB
> drive (including ALL application files in it)?

There's a short guide for that on http://www.rudiswiki.de/wiki/DockStarDebian

Cheers,
Wolfgang
Re: Dockstar stops working
October 27, 2010 08:37AM
I use:
tar \
--exclude=/lost+found \
--exclude=/tmp \
--exclude=/sys \
--exclude=/proc \
-zcf /tmp/backup.tgz

Just remember to re-create the tmp, sys, and proc directories if you ever extract it to an empty drive.
Re: Dockstar stops working
October 27, 2010 04:31PM
Thank you, Wolfgang and Jeff! You save my time.

I followed the guide on http://www.rudiswiki.de/wiki/DockStarDebian and have duplicated my workable USB drive.
Kevin Ko
Re: Dockstar stops working
January 10, 2011 12:06AM
Hi Jeff, I got into similar situation (Dockstar stopped booting with initramfs prompt if an external drive is attached). I found out I need to move the USB external drive (not the bootable one) to the USB socket next to RESET button, then my Dockstar can boot up fine again.
Author:

Your Email:


Subject:


Spam prevention:
Please, enter the code that you see below in the input field. This is for blocking bots that try to post this form automatically. If the code is hard to read, then just try to guess it right. If you enter the wrong code, a new image is created and you get another chance to enter it right.
Message: