Welcome! Log In Create A New Profile

Advanced

Issues after hardware replacement

Posted by micha11 
Issues after hardware replacement
January 08, 2016 02:27PM
Hi!

I have a problem with my Seagate Freeagent Dockstar booting from an external 2.5" HDD

My first Dockstar died after more than 5 years of making a good job. As the attached HDD worked well and still does, I thought, it might be possible, to just take a new Dockstar (I had lying around) and flash uBoot, attach the existing HDD and everything would be fine.
Unfortunately it is not.

The new Dockstar boots to uboot without problems, when no HDD is connected during startup.
It just keeps flickering green, when the HDD is connected during startup.
I already run fsck on the HDD, but I persume that is not the problem.

When connecting the HDD after the device booted, I can see the it correctly:
Pogoplug:~$ fdisk -l

Disk /dev/sda: 250.0 GB, 250059350016 bytes
255 heads, 63 sectors/track, 30401 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

   Device Boot      Start         End      Blocks  Id System
/dev/sda1   *           1       27964   224620798+ 83 Linux
/dev/sda2           27965       30401    19575202+ 82 Linux swap

fw_printenv outputs:

Pogoplug:~$ /usr/sbin/fw_printenv 
ethact=egiga0
bootdelay=3
baudrate=115200
mainlineLinux=yes
console=ttyS0,115200
led_init=green blinking
led_exit=green off
led_error=orange blinking
mtdparts=mtdparts=orion_nand:1M(u-boot),4M(uImage),32M(rootfs),-(data)
mtdids=nand0=orion_nand
partition=nand0,2
stdin=serial
stdout=serial
stderr=serial
rescue_installed=0
rescue_set_bootargs=setenv bootargs console=$console ubi.mtd=2 root=ubi0:rootfs ro rootfstype=ubifs $mtdparts $rescue_custom_params
rescue_bootcmd=if test $rescue_installed -eq 1; then run rescue_set_bootargs; nand read.e 0x800000 0x100000 0x400000; bootm 0x800000; else run pogo_bootcmd; fi
pogo_bootcmd=if fsload uboot-original-mtd0.kwb; then go 0x800200; fi
force_rescue=0
force_rescue_bootcmd=if test $force_rescue -eq 1 || ext2load usb 0:1 0x1700000 /rescueme 1 || fatload usb 0:1 0x1700000 /rescueme.txt 1; then run rescue_bootcmd; fi
ubifs_mtd=3
ubifs_set_bootargs=setenv bootargs console=$console ubi.mtd=$ubifs_mtd root=ubi0:rootfs rootfstype=ubifs $mtdparts $ubifs_custom_params
ubifs_bootcmd=run ubifs_set_bootargs; if ubi part data && ubifsmount rootfs && ubifsload 0x800000 /boot/uImage && ubifsload 0x1100000 /boot/uInitrd; then bootm 0x800000 0x1100000; fi
usb_scan=usb_scan_done=0;for scan in $usb_scan_list; do run usb_scan_$scan; if test $usb_scan_done -eq 0 && ext2load usb $usb 0x800000 /boot/uImage 1; then usb_scan_done=1; echo "Found bootable drive on usb $usb"; setenv usb_device $usb; setenv usb_root /dev/$dev; fi; done
usb_scan_list=1 2 3 4
usb_scan_1=usb=0:1 dev=sda1
usb_scan_2=usb=1:1 dev=sdb1
usb_scan_3=usb=2:1 dev=sdc1
usb_scan_4=usb=3:1 dev=sdd1
usb_init=run usb_scan
usb_device=0:1
usb_root=/dev/sda1
usb_rootfstype=ext2
usb_rootdelay=10
usb_set_bootargs=setenv bootargs console=$console root=$usb_root rootdelay=$usb_rootdelay rootfstype=$usb_rootfstype $mtdparts $usb_custom_params
usb_bootcmd=run usb_init; run usb_set_bootargs; run usb_boot
usb_boot=mw 0x800000 0 1; ext2load usb $usb_device 0x800000 /boot/uImage; if ext2load usb $usb_device 0x1100000 /boot/uInitrd; then bootm 0x800000 0x1100000; else bootm 0x800000; fi
bootcmd=usb start; run force_rescue_bootcmd; run ubifs_bootcmd; run usb_bootcmd; usb stop; run rescue_bootcmd; run pogo_bootcmd; reset
ethaddr=00:10:75:1A:DE:FB
arcNumber=2097


I'm a bit stuck at the moment and would like to avoid a reinstall of the Debian on the HDD with all services etc.
Am I missing something or doing some stupid things?

Unfortunately I don't have a console cable and did not yet tried netconsole, so I don't know, what exactly is going on there.

Maybe someone can help me anyway?

Thanks in advance
Michael
Re: Issues after hardware replacement
January 08, 2016 09:21PM
Michael,


Boot without USB, mount the USB HDD and get the output of

(assuming the USB HDD is mounted at /media/sda1)

uname -a
mount
ls -latr /media/sda1
ls -latr /media/sda1/boot

BTW, if your HDD does not contain anything important, you could reformat it and load the 3.16 rootfs as recommended in this post:
http://forum.doozan.com/read.php?4,23425,23427#msg-23427

But first, let's figure out what is wrong with the existing rootfs.

After you got 3.16 rootfs running, consider upgrading u-boot:
http://forum.doozan.com/read.php?3,12381

-bodhi
===========================
Forum Wiki
bodhi's corner (buy bodhi a beer)



Edited 3 time(s). Last edit at 01/08/2016 10:11PM by bodhi.
Re: Issues after hardware replacement
January 10, 2016 01:30PM
Hi Bodhi,

so here is the output as asked for:
Pogoplug:~$ uname -a
Linux Pogoplug 2.6.22.18 #57 Mon Aug 31 16:31:01 PDT 2009 armv5tejl unknown
Is this the latest version? I installed u-boot just a few days ago.

I remounted / as rw
Pogoplug:~$ mount
rootfs on / type rootfs (rw)
/dev/root on / type jffs2 (rw)
none on /proc type proc (rw)
none on /sys type sysfs (rw)
none on /dev/pts type devpts (rw)
none on /tmp type tmpfs (rw)
/dev/sda1 on /media/sda1 type ext2 (rw)

ls -latr /media/sda1
Pogoplug:~$ ls -latr /media/sda1
drwxr-xr-x    2 root     root         4096 Jul 21  2010 selinux
drwxr-xr-x    2 root     root         4096 Nov 13  2010 proc
drwxr-xr-x    2 root     root         4096 Nov 13  2010 mnt
drwxr-xr-x    2 root     root         4096 Nov 14  2010 sys
drwx------    2 root     root        16384 Dec 14  2010 lost+found
drwxr-xr-x    2 root     root         4096 Dec 14  2010 srv
drwxr-xr-x   13 root     root         4096 Dec 14  2010 var
drwxr-xr-x   10 root     root         4096 Dec 14  2010 usr
drwxr-xr-x    2 root     root         4096 Dec 14  2010 media
drwxr-xr-x    5 root     root         4096 Dec 14  2010 dev
lrwxrwxrwx    1 root     root           30 Dec 14  2010 vmlinuz -> boot/vmlinuz-2.6.32-5-kirkwood
lrwxrwxrwx    1 root     root           33 Dec 14  2010 initrd.img -> boot/initrd.img-2.6.32-5-kirkwood
drwxrwxrwt    2 root     root         4096 Dec 14  2010 tmp
drwxr-xr-x    3 root     root         4096 Dec 14  2010 opt
drwxr-xr-x    2 root     root         4096 Oct 16  2012 sbin
drwxr-xr-x   22 root     root         4096 Oct 24  2012 .
drwxr-xr-x    8 root     root         4096 Jan 14  2013 home
drwxr-xr-x    5 root     root         4096 Jun 11  2013 repositories
drwxr-xr-x    2 root     root         4096 Feb 18  2014 bin
drwxr-xr-x   10 root     root         8192 Feb 18  2014 lib
drwxr-xr-x    2 root     root         4096 Feb 18  2014 boot
drwxr-xr-x   58 root     root         4096 Feb 18  2014 etc
drwx------    4 root     root         4096 May 21  2015 root
drwxr-xr-x    3 root     root            0 Jan 10 19:21 ..

and finally the boot directory. I already tried to make a new kernel a few days ago.
-rw-r--r--    1 root     root      1431936 Jan 28  2011 uImage.bak
-rw-r--r--    1 root     root      4739095 Jan 28  2011 uInitrd.bak
drwxr-xr-x   22 root     root         4096 Oct 24  2012 ..
-rw-r--r--    1 root     root      1435632 Sep 25  2013 vmlinuz-2.6.32-5-kirkwood
-rw-r--r--    1 root     root        84134 Sep 25  2013 config-2.6.32-5-kirkwood
-rw-r--r--    1 root     root      1006219 Sep 25  2013 System.map-2.6.32-5-kirkwood
-rw-r--r--    1 root     root      4537884 Feb 18  2014 initrd.img-2.6.32-5-kirkwood
drwxr-xr-x    2 root     root         4096 Feb 18  2014 .
-rw-r--r--    1 root     root      1435696 Jan  5 20:25 uImage
-rw-r--r--    1 root     root      4537948 Jan  5 20:25 uInitrd

Thanks again
Michael
Re: Issues after hardware replacement
January 10, 2016 11:40PM
Everything looks good, especially you already did fsck. It should have booted into Debian. However, since you don't have serial console, it is hard to see if something went wrong during the kernel booting.

So the next step would be what I suggested above:
http://forum.doozan.com/read.php?3,25123,25124#msg-25124

Create the 3.16 rootfs on a USB thumb drive and boot with it. After you can run Debian, it is easier to see what's wrong with your current rootfs.

And the latest u-boot is here:
http://forum.doozan.com/read.php?3,12381

-bodhi
===========================
Forum Wiki
bodhi's corner (buy bodhi a beer)
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: