Welcome! Log In Create A New Profile

Advanced

[solved]Goflex wheezy (with 3.16 kernel) not seeing sata drives

Posted by bturrie 
[solved]Goflex wheezy (with 3.16 kernel) not seeing sata drives
October 01, 2014 02:52PM
I have a working debian wheezy system on my goflex.net. I'm running on a ext2 formatted usb drive. The uboot I am using came from here: http://projects.doozan.com/uboot/ today. The kernel I am running is 3.2.0-4-kirkwood. Unfortunately when I plug in a sata drive it is not seen by the system. I see a few lines about bad erase block in my syslog but nothing about sata drives. I've been fighting with this for quite a while but I'm not making any progress.

From what I've read it seems that the kernel I'm running doesn't work properly on a goflex. I'm not sure what the best way forward is. It looks like I can install the recovery console and load a wheezy system with a newer kernel version. But is there a simpler way forward given that I already have a working wheezy system?



Edited 3 time(s). Last edit at 10/06/2014 07:47AM by bturrie.
Re: Goglex wheezy not seeing sata drives
October 01, 2014 03:40PM
bturrie,

You can install the latest kernel: linux-3.16.0-kirkwood-tld-3 (28 Sept 2014) from here:
http://forum.doozan.com/read.php?2,12096

-bodhi
===========================
Forum Wiki
bodhi's corner (buy bodhi a beer)
Re: Goglex wheezy not seeing sata drives
October 02, 2014 09:12AM
Bodhi, thanks for the response. I installed the new kernel and rebooted per the instructions. uname -r shows:

3.16.0-kirkwood-tld-3

Unfortunately I still don't see either of my sata drives. I ran blkid and only my boot drive shows. I looked in /dev and as expected there was only sda1. I saw a message saying i needed to run fsck in syslog which I did offline, but when I rebooted the goflex there was, no difference.

Here are the only errors I see in syslog

Dec 31 18:00:27 goflex1 kernel: [ 9.502354] Scanning device for bad blocks
Dec 31 18:00:27 goflex1 kernel: [ 9.643735] Bad eraseblock 1285 at 0x00000a0a0000
Dec 31 18:00:27 goflex1 kernel: [ 9.668910] Bad eraseblock 1477 at 0x00000b8a0000
Dec 31 18:00:27 goflex1 kernel: [ 9.698789] Bad eraseblock 1713 at 0x00000d620000

I have no idea what to try next.
Re: Goglex wheezy not seeing sata drives
October 02, 2014 10:03AM
If it helps, strings /dev/mtd0 | grep U-Boot gives

U-Boot 2011.12 (Apr 18 2012 - 23:08:20)
U-Boot
** Invalid partition type "%.32s" (expect "U-Boot")
U-Boot BUG at %s:%d!
Re: Goglex wheezy not seeing sata drives
October 02, 2014 03:56PM
bturrie,

> U-Boot 2011.12 (Apr 18 2012 - 23:08:20)

You are running an older u-boot, but it should work fine for SATA.

You should set up netconsole (if you don't have serial console). The instruction is here: http://forum.doozan.com/read.php?3,14

After having netconsole, boot the box, interrupt netconsole and at the prompt, run :
ide reset

It should show the HDD initialization and whether it failed to do that. Please post the entire boot log here.

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



Edited 1 time(s). Last edit at 10/02/2014 03:57PM by bodhi.
Re: Goglex wheezy not seeing sata drives
October 03, 2014 09:46AM
Bodhi,

Thanks again. I didn't have a copy of /etc/fw_env.config so none of the programs like fw_printenv would run. I used the one from here: http://forum.doozan.com/read.php?2,11663,page=3. Is that correct?
Here's what I used:
# MTD device name Device offset Env. size Flash sector size Number of sectors
/dev/mtd0 0xc0000 0x20000 0x20000

fw_printenv now seems to work so it's probably okay. Still,I don't think running fw_setenv is a good Idea until I've checked it. I do notice that my arcNumber is 2097 instead of 3089 which may be significant. Anyway here's what fw_printenv showed:

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:26:51:A3
arcNumber=2097

If I can convince myself that the /etc/fw_env.config file is correct for my goflex net then my plan is to change the arcNumber and reboot. If the system still doesn't recognize the sata drives I'll install netconsole and follow your instructions. Otherwise I'll wait to see if you are sure my config file is correct.

-bturrie
Re: Goglex wheezy not seeing sata drives
October 03, 2014 11:24AM
bturrie,

> If I can convince myself that the
> /etc/fw_env.config file is correct for my goflex
> net then my plan is to change the arcNumber and
> reboot. If the system still doesn't recognize the
> sata drives I'll install netconsole and follow
> your instructions. Otherwise I'll wait to see if
> you are sure my config file is correct.

Don't change u-boot envs without setting up netconsole first! If you can list u-boot envs w/o error, then it is safe to set up netconsole. arcNumber, otoh, is more drastic, because the kernel must support it (you could get locked out of the box). You are running vanilla kernel, so 2097 is the safe one to use. 3089 most likely won't work.

See my signature for latest rootfs, and latest u-boot. You can upgrade after you set up netconsole (best to do it on a clone of your USB thumb drive first).

-bodhi
===========================
Forum Wiki
bodhi's corner (buy bodhi a beer)
Re: Goflex wheezy (with 3.16 kernel) not seeing sata drives
October 03, 2014 12:16PM
bodhi,

I missed your warning and changed arcNumber fortunately it worked. I did a hexdump of /dev/mtd0 to a file and convinced myself that I had the right config file. Then I set the arcNumber to 3089 and rebooted, the good thing is my sata drive is now visible. Thanks for all your help...I'll mark this thing solved later this evening.

bturrie



Edited 1 time(s). Last edit at 10/03/2014 12:42PM by bturrie.
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: