Welcome! Log In Create A New Profile

Advanced

Unable to access GFH after editing fw_setenv environment

Posted by cohortcw 
Unable to access GFH after editing fw_setenv environment
June 27, 2012 06:33AM
Hi,

I need help. My GFH was booting fine with a Debian Squeeze usb-stick but I was unable to get Debian installed in the SATA drive using Jeff's script. After I rebooted I am unable to enter into the SATA HDD w/o the USB stick. I changed my uBoot environment to accept boot from SATA as below.


fw_setenv sata_boot 'ide reset; mw 0x800000 0 1; ext2load ide 0:1 0x800000 /boot/uImage; if ext2load ide 0:1 0x1100000 /boot/uInitrd; then bootm 0x800000 0x1100000; else bootm 0x800000; fi'
fw_setenv sata_bootcmd 'run usb_set_bootargs; run sata_boot'
fw_setenv bootcmd 'usb start; run force_rescue_bootcmd; run ubifs_bootcmd; run usb_bootcmd; usb stop; run sata_bootcmd; run rescue_bootcmd; run pogo_bootcmd; reset'

I am still unable to Boot from SATA but ok with a usb-stick. Thinking that the changes in uBoot environment did not work I removed my entire uBoot environment and re-update back to its original environment.

However, I think i did not update properly. Now all I can see is the greenlight kept flashing. And the LAN port on GFH indicates an orange light instead of flashing green.

I did not setup the netconsole environment. Is there anyway to rescue my unit?

Pls help. Many thanks in advance.
Re: Unable to access GFH after editing fw_setenv environment
June 27, 2012 03:11PM
Are you sure, your Kernel can boot from SATA ?
With my Goflex Net it din't work (even from USB the installation done by Jeff's script didn't boot). Now I have an 3.3.2 Kernel that works.
When you try do boot from SATA with the Kernel installed by Jeffs script (install-debian-squeeze.sh) it is a 2.6 Kernel. I tried it the last two weeks - without success. (June 11 to 23 2012)
No matter which uboot version I tried or install-script for debian (Jeff,shyd) I tried.

The only working way that I found was to follow the instructions in Vlad's Howto: Create Debian rootfs image for your GoFlex/Dockstar via debootstrap on a Ubuntu/Debian PC and use the Kernel from Davygravy (see Linux 3.3.2 kernel for Dockstar, GoFlex and many others) in the 'GoFlex section' at the End of Vlad's step-by-step howto.
My current uBoot is
U-Boot 2011.12 (Apr 18 2012 - 23:08:20)
Seagate GoFlexNet
arm-none-linux-gnueabi-gcc (Sourcery G++ Lite 2009q3-67) 4.4.1
GNU ld (Sourcery G++ Lite 2009q3-67) 2.19.51.20090709

Here are some lines from my fw_printenv:
bootcmd=usb start; usb reset; run force_rescue_bootcmd; run usb_bootcmd; usb stop; run sata_bootcmd; run rescue_bootcmd; reset
sata_boot=ide reset; mw 0x800000 0 1; ext2load ide 0:1 0x800000 /boot/uImage; if ext2load ide 0:1 0x1100000 /boot/uInitrd; then bootm 0x800000 0x1100000; else bootm 0x800000; fi
sata_bootcmd=run sata_set_bootargs; run sata_boot
sata_set_bootargs=setenv bootargs $usb_custom_params console=$console root=LABEL=ssd rootdelay=8 rootfstype=ext2 $mtdparts
I inserted usb reset; because of the 'EHCI timed out on TD - token=0x...' I get when my WD ELements HD's are attached. So normally, you can skip this.
I've got "root=LABEL=ssd" in my sata_set_bootargs because there were problems in mounting the rootfs and the second SATA device as the same dev/sd.. with different numbers of USB-devices attached at reboot. (My root filesystem is on a Transcend 4G SSD SATA-Card TS4GSSD25H-M)
So I decided to "tune2fs -L ssd /dev/sd?1" on the rootfs and put the LABEL in my bootargs. (this kernel doesn't require "rootfs" as Label for the rootfs, as I found out. And I don't have to worry about testing another rootfs/kernel on USB in the future, which can then be labelled "rootfs") All actions I used to do with /dev/sda1, /dev/sde2 etc. I now do with LABEL="..." or UUID=.

edit: ---

Greets
Phil



Edited 2 time(s). Last edit at 06/27/2012 09:59PM by punxsutawney-phil.
Re: Unable to access GFH after editing fw_setenv environment
June 27, 2012 08:52PM
This sounds a bit like what I did to mine. If you have the original uBoot installed you can recover.

Read through the thread HERE and follow the directions about resetting the GFH to factory and starting over.

I eventually installed serial connections to mine. This makes the whole project much easier. It is not necessary though.
Re: Unable to access GFH after editing fw_setenv environment
June 27, 2012 10:35PM
Oh,
I missed the part where you write, that you've removed your uBoot environment and replaced it with the original one..
thought you can still boot from USB.

In that case you can - in addition to optim's hint - read this thread.

Or did you mean the default environment of the replacement (non-Seagate) uBoot?
In this case the reset button trick to restore Seagate-firmware will not work.

I don' know if it helps you, but when I was in a similar situation - thinking my GFH was bricked - I read that by default the uBoot would send the netconsole output to 10.10.10.5. I checked with wireshark. There was traffic from 10.10.10.6 to 10.10.10.5 on port 6666.

Follow the steps in davygravy's post to read the kwb-file for mtd0 over tftp after you succeeded in getting nc access to work.
That's the way, I got the original uBoot back an was able to revert to the original Seagate stuff on my GFH. (at present I'm trying to get debian to work on my GFN and running my GFH@stock firmware)
But keep in mind if something goes wrong you can whack your device!

Phil
Re: Unable to access GFH after editing fw_setenv environment
June 28, 2012 08:28AM
Initially, I was able to get my unit to boot with a USB stick running a 3.3.2 kernel. I ran Jeff's script first and the script had updated my uBoot environment to the latest version. I did
install a rescue boot nor did I setup netconsole as I am not sure how to setup the netconsole part.

Thanks for all the help. I am not sure if I really need to get one of those serial convertor in order to salvage my unit. I did not setup my netconsole. So I do not think I can send a netconsole command to my unit during bootup. In anyway, I will give it a shot on the suggestions you folks had given me. I do hoped my unit is not bricked. I am not able to ssh via LAN as I did not see any valid IP address. All the unit does it a flashing green light on its front.
Re: Unable to access GFH after editing fw_setenv environment
June 29, 2012 04:57AM
Is there any way to recover my GFH unit if I have messed up my uBoot environment?

I've edited my uBoot environment with a modified fw_setenv but I think it was not edited properly. I does not seems to be able to boot up now.
Re: Unable to access GFH after editing fw_setenv environment
June 29, 2012 05:54AM
IF you have the original uBoot still installed

http://support.goflexhome.hipserv.com/en/reflash/index.html

this will put it back to factory fresh and you can start over.

If not, you will need a serial connection to grab control of it.
Re: Unable to access GFH after editing fw_setenv environment
June 29, 2012 10:05AM
Thanks, I guessed I have no other choice as I had also tried the reflashing of the original uBoot and it did not work.

Are there any guides on step of how to recover or reflash my uBoot via serial connection? I am pretty new to this.
Re: Unable to access GFH after editing fw_setenv environment
June 29, 2012 11:20AM
http://forum.doozan.com/read.php?3,6965

Im not sure if you have a serial cable yet or not. For the usb cable I bought 2 of These and once I found the right driver and did a little soldering they worked great.

I also bought a bunch of These and installed one right in the box, and put a standard mini stereo headphone jack (from radio shack) on the end of the wire and can serial in whenever I need to.
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: