Welcome! Log In Create A New Profile

Advanced

How to unbrick GoFlex Home?

Posted by shayan123 
Re: How to unbrick GoFlex Home?
July 14, 2018 04:29AM
balanga Wrote:
-------------------------------------------------------
> shayan123 Wrote:
> -------------------------------------------------------
> > It's the internet mate, everything's there,
> just
> > takes a bit of searching! Check this one out:
> > 10-pin
> > connector on AliExpress
(and its barely a
> > dollar)
>
>
> Thanks. As I said you need to know what you are
> looking for...
>
> I don't know the diameter of the pins (or holes)
> and the spacing between them, or type of
> connector.
>
> I would probably be able to find someting here:-
> http://www.jst.com/home8.html
> but it's like looking for a needle in a haystack.
>
>
> .....
>
> After rummaging about in my old computer cables
> drawer I found some old cables which happened to
> have 5x2 connectors which fitted perfectly and
> created a much more solid connection.

Hey, I suppose you've got a GoFlex Home. Do you mind posting your envs so I can take a look at it?
Re: How to unbrick GoFlex Home?
July 14, 2018 11:58AM
The following is the output of fw_printenv on my working Seagate GoFLEX Home NAS. It is currently running debian buster/sid. I hope it will help you.
[root@debian:/root 1%] # fw_printenv
bootcmd_exec=run load_uimage; if run load_initrd; then if run load_dtb; then bootm $load_uimage_addr $load_initrd_addr $load_dtb_addr; else bootm $load_uimage_addr $load_initrd_addr; fi; else if run load_dtb; then bootm $load_uimage_addr - $load_dtb_addr; else bootm $load_uimage_addr; fi; fi
bootcmd=run bootcmd_uenv; run scan_disk; run set_bootargs; run bootcmd_exec
bootcmd_uenv=run uenv_load; if test $uenv_loaded -eq 1; then run uenv_import; fi
bootdelay=10
bootdev=usb
device=0:1
devices=usb ide mmc
disks=0 1 2 3
ethact=egiga0
if_netconsole=ping $serverip
led_error=orange blinking
led_exit=green off
led_init=green blinking
load_dtb_addr=0x1c00000
load_initrd_addr=0x1100000
load_uimage_addr=0x800000
load_dtb=echo loading DTB $dtb_file ...; load $bootdev $device $load_dtb_addr $dtb_file
load_initrd=echo loading uInitrd ...; load $bootdev $device $load_initrd_addr /boot/uInitrd
load_uimage=echo loading uImage ...; load $bootdev $device $load_uimage_addr /boot/uImage
machid=0x831
mainlineLinux=yes
mtdids=nand0=orion_nand
mtdparts=mtdparts=orion_nand:1M(u-boot),4M(uImage),32M(rootfs),-(data)
partition=nand0,2
scan_disk=echo running scan_disk ...; scan_done=0; setenv scan_usb "usb start";  setenv scan_ide "ide reset";  setenv scan_mmc "mmc rescan"; for dev in $devices; do if test $scan_done -eq 0; then echo Scan device $dev; run scan_$dev; for disknum in $disks; do if test $scan_done -eq 0; then echo device $dev $disknum:1; if load $dev $disknum:1 $load_uimage_addr /boot/uImage 1; then scan_done=1; echo Found bootable drive on $dev $disknum; setenv device $disknum:1; setenv bootdev $dev; fi; fi; done; fi; done
set_bootargs=setenv bootargs console=ttyS0,115200 root=LABEL=rootfs rootdelay=10 $mtdparts $custom_params
stderr=serial
stdin=serial
stdout=serial
uenv_addr=0x810000
uenv_import=echo importing envs ...; env import -t $uenv_addr $filesize
uenv_init_devices=setenv init_usb "usb start";  setenv init_ide "ide reset";  setenv init_mmc "mmc rescan"; for devtype in $devices; do run init_$devtype; done;
uenv_load=run uenv_init_devices; setenv uenv_loaded 0; for devtype in $devices;  do for disknum in 0; do run uenv_read_disk; done; done;
uenv_read_disk=if test $devtype -eq mmc; then if $devtype part; then run uenv_read;  fi; else if $devtype part $disknum; then run uenv_read; fi;  fi
uenv_read=echo loading envs from $devtype $disknum ...; if load $devtype $disknum:1 $uenv_addr /boot/uEnv.txt; then setenv uenv_loaded 1; fi
usb_ready_retry=15
arcNumber=3338
serverip=192.168.1.87
preboot=run if_netconsole start_netconsole
ipaddr=192.168.1.89
start_netconsole=setenv ncip $serverip; setenv bootdelay 3; setenv stdin nc; setenv stdout nc; setenv stderr nc; version;
dtb_file=/boot/dts/kirkwood-goflexhome.dtb
ethaddr=00:10:75:09:0b:3a
[root@debian:/root 2%] #
[root@debian:/root 3%] # cat /etc/debian_version 
buster/sid
[root@debian:/root 4%] # uname -a
Linux debian 4.12.1-kirkwood-tld-1 #1 PREEMPT Sat Jul 15 21:40:50 PDT 2017 armv5tel GNU/Linux
[root@debian:/root 5%] # cat /boot/uEnv.txt 
dtb_file=/boot/dts/kirkwood-goflexhome.dtb
devices=usb ide
disks=0 1 2 3 4 5 6 7
[root@debian:/root 6%] #
Re: How to unbrick GoFlex Home?
July 14, 2018 04:43PM
@habibie,

shayan123 needs stock u-boot envs, the new envs won't help.

@ shayan123,

Sorry, I could not find my old notes with the GFHome stock envs (I probably removed them accidentally). You need somebody who has a GF Home with stock u-boot still installed, to get these envs.

This is the time when you can kwboot the box then everything is solved! so try that again.

-bodhi
===========================
Forum Wiki
bodhi's corner (buy bodhi a beer)
Re: How to unbrick GoFlex Home?
July 17, 2018 05:01PM
bodhi Wrote:
-------------------------------------------------------
> This is the time when you can kwboot the box then
> everything is solved! so try that again.


Alright, I gave kwboot another try. This time on Ubuntu instead of MacOS, which fixed my previous issue ("stuck at Please Reboot Target")..
However, this is what happens now:
ubuntu@ubuntu:~/Downloads$ sudo ./kwboot -t -B 115200 /dev/ttyUSB0 -b '/home/ubuntu/Downloads/uboot.2017.07-tld-1.goflexhome.mtd0.kwb' 
Sending boot message. Please reboot the target.../
Sending boot image...
  0 % [+xmodem: Protocol error

Trying to rule out the possible causes:
  1. This is where I got kwboot from: Precompiled binary for Ubuntu (x64) - davygravy
  2. This is where I got the uboot image from Updated 06 Dec 2017
  3. I've verified that serial console works properly and I am able to interrupt the boot (no issues there)
  4. My envs are all wrong and uboot says "Bad CRC or NAND"
  5. My soldering is a little messy and I think the solder from Rx (pin 8) is accidentally touching pin 3 (no idea what pin 3 is for) [See Image]

Are any of these points related to the above error? Or is this caused by something else? Is there a way to fix this error?



Edited 1 time(s). Last edit at 07/17/2018 05:03PM by shayan123.
Attachments:
open | download - IMG_9376.jpg (230.5 KB)
Re: How to unbrick GoFlex Home?
July 17, 2018 05:54PM
shayan123,

That's the wrong command syntax to use. The correct one is:

sudo ./kwboot -t -B 115200 /dev/ttyUSB0 -b /home/ubuntu/Downloads/uboot.2017.07-tld-1.goflexhome.mtd0.kwb -p

-bodhi
===========================
Forum Wiki
bodhi's corner (buy bodhi a beer)
Re: How to unbrick GoFlex Home?
July 18, 2018 11:45AM
bodhi Wrote:
-------------------------------------------------------
> shayan123,
>
> That's the wrong command syntax to use. The
> correct one is:
>
>
> sudo ./kwboot -t -B 115200 /dev/ttyUSB0 -b
> /home/ubuntu/Downloads/uboot.2017.07-tld-1.goflexhome.mtd0.kwb
> -p
>

My bad. Alright, I'm able to send the boot image now, but the new boot image is expecting a uEnvs.txt which I don't have. (The whole point of this thread is that I don't have envs.)
Also, is there something I'm supposed to be putting on a USB? Maybe a uImage or something? Because this is what my kwboot terminal output looks like:

Sending boot message. Please reboot the target...\
Sending boot image...
  0 % [......................................................................]
	/* Removed for brevity */
 99 % [....................................]
[Type Ctrl-\ + c to quit]


U-Boot 2017.07-tld-1 (Sep 05 2017 - 00:21:31 -0700)
Seagate GoFlex Home

SoC:   Kirkwood 88F6281_A1
DRAM:  128 MiB
WARNING: Caches not enabled
NAND:  256 MiB
*** Warning - bad CRC, using default environment

In:    serial
Out:   serial
Err:   serial
Net:   egiga0
88E1116 Initialized on egiga0
Hit any key to stop autoboot:  0 
starting USB...
USB0:   USB EHCI 1.00
scanning bus 0 for devices... 1 USB Device(s) found
       scanning usb for storage devices... 0 Storage Device(s) found

Reset IDE: ide_preinit failed
## Unknown partition table type 0

## Unknown partition table type 0

## Unknown partition table type 0

## Unknown partition table type 0

## Unknown partition table type 0

## Unknown partition table type 0

## Unknown partition table type 0
loading envs from usb 0 ...
** Bad device usb 0 **

no IDE devices available
running scan_disk ...
Scan device usb
device usb 0:1
** Bad device usb 0 **
device usb 1:1
** Bad device usb 1 **
device usb 2:1
** Bad device usb 2 **
device usb 3:1
** Bad device usb 3 **
Scan device ide

Reset IDE: ide_preinit failed
device ide 0:1
** Bad device ide 0 **
device ide 1:1
** Bad device ide 1 **
device ide 2:1
** Bad device ide 2 **
device ide 3:1
** Bad device ide 3 **
loading uImage ...
** Bad device usb 0 **
loading uInitrd ...
** Bad device usb 0 **
loading DTB /boot/dts/kirkwood-goflexhome.dtb ...
** Bad device usb 0 **
Unknown command 'bootm0x800000' - try 'help'
resetting ...


	 -- NAS EXPLORER --
 _   _     ____              _
| | | |   | __ )  ___   ___ | |_ 
| | | |___|  _ \ / _ \ / _ \| __| 
| |_| |___| |_) | (_) | (_) | |_ 
 \___/    |____/ \___/ \___/ \__| 
 ** QSI BOARD: NAS-PLUG LE 

U-Boot 1.1.4 (Sep 26 2011 - 13:01:13) Marvell version: 3.4.27
QSI NAS version: 1.0.6

U-Boot code: 00600000 -> 0067FFF0  BSS: -> 006CFB00

Soc: 88F6281 A1 (DDR2)
CPU running @ 1200Mhz L2 running @ 400Mhz
SysClock = 400Mhz , TClock = 200Mhz 

DRAM CAS Latency = 5 tRP = 5 tRAS = 18 tRCD=6
DRAM CS[0] base 0x00000000   size 128MB 
DRAM Total size 128MB  16bit width
Addresses 8M - 0M are saved for the U-Boot usage.
Mem malloc Initialization (8M - 7M): Done
NAND:NAND READID : MID=0x98, DID=0xda
256 MB
*** Warning - bad CRC or NAND, using default environment

Flash:  0 kB

CPU : Marvell Feroceon (Rev 1)

Streaming disabled 
Write allocate disabled


USB 0: host mode
PEX 0: interface detected no Link.
Net:   egiga0 [PRIME]
Hit any key to stop autoboot:  0 
Using egiga0 device
TFTP from server 169.254.254.254; our IP address is 169.254.254.253
Filename 'uImage'.
Load address: 0x2000000
Loading: T T T T T T T T T T 
Retry count exceeded; starting again
## Booting image at 02000000 ...
Bad Magic Number
Unknown command '<NULL>' - try 'help'
NAS>>

Edit 1: Since kwboot is able to send the boot image, does this mean I can proceed with creating rootfs and writing the image to the NAND? (If this is even necessary, that is.)



Edited 1 time(s). Last edit at 07/18/2018 11:48AM by shayan123.
Re: How to unbrick GoFlex Home?
July 19, 2018 12:15AM
shayan123,

> My bad. Alright, I'm able to send the boot image
> now, but the new boot image is expecting a
> uEnvs.txt which I don't have.

That's the default behavior. It does not mean that uEnv.txt is required.

> (The whole point of
> this thread is that I don't have envs.)

kwboot will help you booting into Debian rootfs on USB. After that you can flash new u-boot and its default envs image. That will solve your problem.

> Also, is there something I'm supposed to be
> putting on a USB?

> Edit 1: Since kwboot is able to send the boot
> image, does this mean I can proceed with creating
> rootfs

> and writing the image to the NAND? (If this
> is even necessary, that is.)

No NAND involved in creating rootfs on USB.

Follow instructon in the realease thread:
https://forum.doozan.com/read.php?2,12096

to create rootfs Debian-4.12.1-kirkwood-tld-1-rootfs-bodhi.tar.bz2 on USB flash drive. Scroll down to

Quote

Updated 24 Jul 2017:

Basic Debian stretch Kirkwood rootfs for most Kirwood plugs:

- tarball size: 188M
- install size: 488M
- The init system used in this rootfs is sysvinit . To boot with systemd, see note 2 below.
- Installed packages: nano, avahi, ntp, busybox-syslogd (log to RAM), htop, isc-dhcp-client, dialog, bzip2, nfs server/client, iperf, ethtool, sysvinit-core, sysvinit, and sysvinit-utils.
- see LED controls in /etc/rc.local, and /etc/init.d/halt
- see some useful aliases in /root/.profile
- root password: root

Download at Dropbox:

Debian-4.12.1-kirkwood-tld-1-rootfs-bodhi.tar.bz2

md5:
bf3d29569943875df348fb5ca03b348c
sha256:
4ed5714fdb123cdb40e973f3d0754e91cd199b75a9874018f2b5dc9cfa8ae8bb

And try booting with kwboot while this USB rootfs is plugged in.

-bodhi
===========================
Forum Wiki
bodhi's corner (buy bodhi a beer)
Re: How to unbrick GoFlex Home?
July 19, 2018 04:05PM
bodhi Wrote:
-------------------------------------------------------
> kwboot will help you booting into Debian rootfs on
> USB. After that you can flash new u-boot and its
> default envs image. That will solve your problem.

Yes! Debian boots perfectly from rootfs with kwboot! Now I assume I need to flash the uboot.2017.07 for GoFlexHome as described by this post?
https://forum.doozan.com/read.php?3,12381

Would this be the part I’m supposed to be focusing on? :
Quote
bodhi
A. Flashing Instruction:


Installation is the same for each u-Boot image, the instruction below is written to include all boxes. So choose the platform name that you are installing for, and copy/paste the appropriate commands.

If you are running kernel that do not provide mtd-utils and uboot-tools (fw_setenv, fw_printenv, flash_erase, nandwrite), you can download the NAND and U-Boot tools binaries here in this thread.

1. uBoot envs config should be defined as followed in your /etc/fw_env.config

cat /etc/fw_env.config
# MTD device name Device offset Env. size Flash sector size Number of sectors
/dev/mtd0 0xc0000 0x20000 0x20000

- And your mtd partitions should be:
Re: How to unbrick GoFlex Home?
July 19, 2018 04:43PM
shayan123,

> Yes! Debian boots perfectly from rootfs with
> kwboot! Now I assume I need to flash the
> uboot.2017.07 for GoFlexHome as described by this
> post?
> https://forum.doozan.com/read.php?3,12381
>

Correct.


> Would this be the part I’m supposed to be
> focusing on? :

> A. Flashing Instruction:

Yes. This instruction was written to cover all Kirkwood boxes. So if it seems too much, for clarity, you could copy them to a notepad and prepare the commands that specific to GoFlex Home only.

-bodhi
===========================
Forum Wiki
bodhi's corner (buy bodhi a beer)
Re: How to unbrick GoFlex Home?
July 20, 2018 04:10PM
Alright, I tried what's described in the guide and i'm having a few issues:

  1. Since my stock envs are bad and im booting off of rootfs, do I still need to save the outputs of fw_printenv?
    If so, fw_printenv has no mention of mtdparts
      root@debian:~# fw_printenv mtdparts  Warning: Bad CRC, using default environment  ## Error: "mtdparts" not defined

    The guide mentions to set mtdparts in the envs after flashing. If they aren't listed by fw_printenv do I leave it blank or can I set the value by looking into the output of /proc/mtd?
      dev: size erasesize name  mtd0: 00100000 00020000 "u-boot"  mtd1: 00600000 00020000 "uImage"  mtd2: 0d800000 00020000 "root"  
  2. I can't find the commands nanddump, flash_erase and nandwrite:
      root@debian:~# nanddump --noecc --omitoob -l 0x80000 -f mtd0 /dev/mtd0  -bash: nanddump: command not found
    I've searched the bin and sbin folders in / , /usr and /usr/local but haven't found these commands. Should they be installed via apt-get?
Re: How to unbrick GoFlex Home?
July 20, 2018 05:09PM
shayan123,


> The guide mentions to set mtdparts in the envs
> after flashing. If they aren't listed by
> fw_printenv do I leave it blank

mtdparts can be set after flashing the envs image. In the normal case, you see it in your current envs, but yours were corrupted! It can be found in the envs text file from the tarball.

Quote

uboot.2016.05-tld-1.environment (the content of the default envs in text format)

It looks like this:
mtdparts=mtdparts=orion_nand:1M(u-boot),4M(uImage),32M(rootfs),-(data)

So
fw_setenv mtdparts 'mtdparts=orion_nand:1M(u-boot),4M(uImage),32M(rootfs),-(data)'

Regarding the tool, the instruction mentioned this:

Quote

If you are running kernel that do not provide mtd-utils and uboot-tools (fw_setenv, fw_printenv, flash_erase, nandwrite), you can download the NAND and U-Boot tools binaries here in this thread.

However, since you are already running the Debian rootfs, you can install it:
apt-get install mtd-utils

-bodhi
===========================
Forum Wiki
bodhi's corner (buy bodhi a beer)
Re: How to unbrick GoFlex Home?
July 21, 2018 12:08PM
bodhi,

Thank you for all the support. I can now successfully boot Debian on my GoFlex Home!

However, just out of curiosity, is it possible to write stock firmware to the NAND?
The firmware provided by Seagate includes 3 files:
  1. uImage
  2. initrd
  3. hipserv2_seagateplug-20120508.ubi

If so, how would this be done on the GoFlex Home via serial console?
Re: How to unbrick GoFlex Home?
July 21, 2018 05:24PM
shayan123,

> Thank you for all the support. I can now
> successfully boot Debian on my GoFlex Home!

Cool!

> If so, how would this be done on the GoFlex Home
> via serial console?

Yes it is a given, that you can run stock. But I would not spend time to make it work.

If you want a rescue system then look at the Rescue System subforum and pick one that you like to install.

And also check the Wiki thread:

Quote

Rescue Systems

Rescue System V2 (Original)
MacPlug & SMBPLug
Rescue System Pogo V3
Rescue System V4, using a custom LEDE firmware (BETA)
Rescue System for Pogo E02 using LEDE

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



Edited 1 time(s). Last edit at 07/21/2018 05:26PM by bodhi.
Re: How to unbrick GoFlex Home?
August 02, 2018 06:04AM
shayan123 Wrote:
-------------------------------------------------------
> bodhi,
>
> Thank you for all the support. I can now
> successfully boot Debian on my GoFlex Home!
>
> However, just out of curiosity, is it possible to
> write
> stock
> firmware
to the NAND?
> The firmware provided by Seagate includes 3
> files:
>
    >
  1. uImage
    >
  2. initrd
    >
  3. hipserv2_seagateplug-20120508.ubi
    >
>
> If so, how would this be done on the GoFlex Home
> via serial console?

Actually, this is something I would like to try. If you manage it can you say what you did?
Re: How to unbrick GoFlex Home?
August 08, 2018 06:06AM
balanga Wrote:
-------------------------------------------------------
> shayan123 Wrote:
> -------------------------------------------------------
> > bodhi,
> >
> > Thank you for all the support. I can now
> > successfully boot Debian on my GoFlex Home!
> >
> > However, just out of curiosity, is it possible
> to
> > write
> >
> stock
> > firmware
to the NAND?
> > The firmware provided by Seagate includes 3
> > files:
> >
    > >
  1. uImage
    > >
  2. initrd
    > >
  3. hipserv2_seagateplug-20120508.ubi
    > >
> >
> > If so, how would this be done on the GoFlex
> Home
> > via serial console?
>
> Actually, this is something I would like to try.
> If you manage it can you say what you did?

If you have a stock GoFlex Home, then you want to backup stock mtds on the stock unit and then restore those mtds to the 2nd GFH.

So you want to:

- boot the stock GFHome. Log into stock OS, dump the stock mtds using nanddump.
- Copy those nand-dumped files to a USB drive.
- Boot the GFH box that has Arch or Debian running. Log in, and mount the USB drive that hold the mtd dumps.
- Use flash_erase and nandwrite to restore those file to mtds.

That's it. The 2nd GFH now has the stock MTDs, i.e. stock u-boot and OS, just ike the stock GFH.

It's very similar to this procedure here (written for the Pogo V4, so the MTDs layout is different from the GFH):
https://forum.doozan.com/read.php?3,16789,16789#msg-16789

-bodhi
===========================
Forum Wiki
bodhi's corner (buy bodhi a beer)
Re: How to unbrick GoFlex Home?
August 10, 2018 11:37AM
Just to explain why I want to do this.. I've broken into the GFH unit which has the original Stock system installed and I have a good connector for the pins which makes all the difference for using serial connections. This does make a hell of a difference because I previously used three badly fitting wires and had to keep holding them in place whilst using a serial connection. The slightest movement would cause a hang or some other disruption. Basically using a serial connector became a PITA. So, I want to use this unit for testing/learning, but I also want a unit which can be used as a simple NAS with an embedded OS. The other unit is still intact (physically) although it has ArchLinux installed which I want to restore to its original state.

In order to do

- boot the stock GFHome. Log into stock OS, dump the stock mtds using nanddump.
- Copy those nand-dumped files to a USB drive.

Presumably this is what I should run:-

cd /tmp 
mkdir usb 
mount /dev/sda1 /tmp/usb 
wget http://plugapps.com/os/pogoplug/uboot/nanddump 
chmod +x nanddump 
./nanddump -nf usb/mtd0 /dev/mtd0 
./nanddump -nf usb/mtd1 /dev/mtd1 
./nanddump -nf usb/mtd2 /dev/mtd2 
umount /dev/sda1

Just for clarification, should I (a) ssh into the system or (b) access it via the serial port and if (b) do I stop it during the boot process, or should I login at the login prompt?

Also is the version of nanddump mentioned above the correct one?
Re: How to unbrick GoFlex Home?
August 11, 2018 01:05AM
Here is a better tools binaries tarball to download:

https://forum.doozan.com/read.php?3,27280

And before backing up the mtds you need to list them in stock OS (not Arch system):

cat /proc/mtd


cd /tmp 
mkdir usb 
mount /dev/sda1 /tmp/usb 
cd /tmp/usb


And then use this format:

nanddump --noecc --omitoob -f mtd0 /dev/mtd0
nanddump --noecc --omitoob -f mtd1 /dev/mtd1

...
so on

2. And then write them to the Arch-running box

And before flashing the mtds you need to list them in Arch OS

cat /proc/mtd
If they match with stock OS, then go ahead. If not, you will need to adjust the mtds to the stock definition, reboot. And verify

Once the mtds are the same in stock OS and Arch. Flash the backup to the Arch box:
flash_erase /dev/mtd0
nandwrite -on /dev/mtd0 mtd0

flash_erase /dev/mtd1
nandwrite -on /dev/mtd1 mtd1
.....

so on

-bodhi
===========================
Forum Wiki
bodhi's corner (buy bodhi a beer)
Re: How to unbrick GoFlex Home?
August 11, 2018 02:46AM
bodhi Wrote:
-------------------------------------------------------
> Here is a better tools binaries tarball to
> download:
>
> https://forum.doozan.com/read.php?3,27280
>
> And before backing up the mtds you need to list
> them in stock OS (not Arch system):
>
>
> cat /proc/mtd
>

bash-3.2# cat /proc/mtd
dev: size erasesize name
mtd0: 00100000 00020000 "u-boot"
mtd1: 00600000 00020000 "uImage"
mtd2: 0f900000 00020000 "root"

Is this OK?
Re: How to unbrick GoFlex Home?
August 11, 2018 02:49AM
balanga Wrote:
-------------------------------------------------------
> bodhi Wrote:
> -------------------------------------------------------
> > Here is a better tools binaries tarball to
> > download:
> >
> > https://forum.doozan.com/read.php?3,27280
> >
> > And before backing up the mtds you need to list
> > them in stock OS (not Arch system):
> >
> >
> > cat /proc/mtd
> >
>
> bash-3.2# cat /proc/mtd
> dev: size erasesize name
> mtd0: 00100000 00020000 "u-boot"
> mtd1: 00600000 00020000 "uImage"
> mtd2: 0f900000 00020000 "root"
>
> Is this OK?

Yes it does look ok. You can nanddump all 3 mtds.

-bodhi
===========================
Forum Wiki
bodhi's corner (buy bodhi a beer)
Re: How to unbrick GoFlex Home?
August 11, 2018 07:20AM
bodhi Wrote:
-------------------------------------------------------
>
> Yes it does look ok. You can nanddump all 3 mtds.

How does this look?

bash-3.2# ls -al mtd
total 262424
drwxr-xr-x 2 root root 4096 Aug 11 12:15 .
drwxr-xr-x 5 root root 4096 Aug 11 12:04 ..
-rw-r--r-- 1 root root 1048576 Aug 11 12:15 mtd0
-rw-r--r-- 1 root root 6291456 Aug 11 12:15 mtd1
-rw-r--r-- 1 root root 261095424 Aug 11 12:17 mtd2
Re: How to unbrick GoFlex Home?
August 11, 2018 07:42AM
bodhi Wrote:
-------------------------------------------------------
> 2. And then write them to the Arch-running box
>
> And before flashing the mtds you need to list them
> in Arch OS
>
>
> cat /proc/mtd
>
> If they match with stock OS, then go ahead. If
> not, you will need to adjust the mtds to the stock
> definition, reboot. And verify


On Arch box:

[root@alarm ~]# cat /proc/mtd
dev: size erasesize name
mtd0: 00100000 00020000 "u-boot"
mtd1: 0ff00000 00020000 "rootfs"
Re: How to unbrick GoFlex Home?
August 11, 2018 11:39AM
> On Arch box:
>
> [root@alarm ~]# cat /proc/mtd
> dev: size erasesize name
> mtd0: 00100000 00020000 "u-boot"
> mtd1: 0ff00000 00020000 "rootfs"

It does not match. We need to change mtdparts back to stock definition.

So please get the envs listing at the prompt [root@alarm ~]

fw_printenv

-bodhi
===========================
Forum Wiki
bodhi's corner (buy bodhi a beer)
Re: How to unbrick GoFlex Home?
August 11, 2018 12:46PM
bodhi Wrote:
-------------------------------------------------------
>
> fw_printenv
>

baudrate=115200
bootcmd=ide reset; usb start; setenv letter 9;for type in ide usb; do for disk in 0; do if ${type} part ${disk};then setexpr letter $letter + 1;run load;fi;done;done;
bootdelay=3
bootm=echo Booting from ${disk} ...; run setargs; bootm ${loadaddr};
bootz=echo Booting from ${disk} ...; run setargs; bootz ${loadaddr} - ${fdt_addr};
console=ttyS0
ethact=egiga0
fdt_addr=0x800000
fdt_file=/boot/dtbs/kirkwood-goflexnet.dtb
importbootenv=echo Importing environment (uEnv.txt)...; env import -t $loadaddr $filesize
load=echo Attempting to boot from ${type} ${disk}:1...;if run loadbootenv; then run importbootenv;fi;echo Checking if uenvcmd is set ...;if test -n $uenvcmd; then echo Running uenvcmd ...;run uenvcmd;fi;echo Running default loadzimage ...;if run loadzimage; then run loadfdt;run bootz;fi;echo Running default loaduimage ...;if run loaduimage; then run bootm;fi;
loadaddr=0x810000
loadbootenv=load ${type} ${disk}:1 ${loadaddr} /boot/uEnv.txt
loadfdt=load ${type} ${disk}:1 ${fdt_addr} ${fdt_file}
loaduimage=load ${type} ${disk}:1 ${loadaddr} ${uimage}
loadzimage=load ${type} ${disk}:1 ${loadaddr} ${zimage}
mtdids=nand0=orion_nand
mtdparts=mtdparts=orion_nand:1M(u-boot),-(rootfs)
setargs=setenv bootargs console=${console},${baudrate} ${optargs} root=/dev/sd${letter}1 rw rootwait ${mtdparts}
uimage=/boot/uImage
zimage=/boot/zImage
ethaddr=00:10:75:2C:A9:58

Just out of interest will the MAC address for the Arch box remain as it is?
Re: How to unbrick GoFlex Home?
August 11, 2018 01:44PM
balanga,

> Just out of interest will the MAC address for the
> Arch box remain as it is?

It should be the MAC address of the stock box. So save this ethaddr=00:10:75:2C:A9:58. You need to change the ethaddr env on this box after flashing the mtds.

One more info to get. Log in to the stock GFH, or if you have serial console connected, get the envs listing of this stock GFH.

- in serial console
printenv

- in stock OS
fw_printenv

-bodhi
===========================
Forum Wiki
bodhi's corner (buy bodhi a beer)
Re: How to unbrick GoFlex Home?
August 11, 2018 02:04PM
bodhi Wrote:
-------------------------------------------------------
> - in stock OS
>
> fw_printenv
>

baudrate=115200
loads_echo=0
ipaddr=169.254.254.253
serverip=169.254.254.254
rootpath=/mnt/ARM_FS/
netmask=255.255.0.0
run_diag=yes
CASset=min
MALLOC_len=1
ethprime=egiga0
bootargs_end=:::DB88FXX81:eth0:none
image_name=uImage
standalone=fsload 0x2000000 $(image_name);setenv bootargs $(console) root=/dev/mtdblock0 rw ip=$(ipaddr):$(serverip)$(bootargs_end) $(mvPhoneConfig); bootm 0x2000000;
ethmtu=1500
usb0Mode=host
nandEcc=1bit
netretry=no
rcvrip=169.254.100.100
loadaddr=0x02000000
autoload=no
ethact=egiga0
rtc_mode=active
vm_ver_smt=1.1.3
pcba_sn=JA8P05390
console=console=ttyS0,115200
rtc_tz=PST
ntp_default=pool.ntp.org
smt_tag=10:08:28:06:07:50:25
ethaddr=00:10:75:28:CC:00
explrpk=PGBW-DQHB-MXJU-KKDK
explrsn=NA1Y6EYJ
asm1_tag=10:08:28:06:09:49:06
stdin=serial
stdout=serial
stderr=serial
mainlineLinux=no
enaMonExt=no
enaCpuStream=no
enaWrAllo=no
pexMode=RC
disL2Cache=no
setL2CacheWT=yes
disL2Prefetch=yes
enaICPref=yes
enaDCPref=yes
sata_dma_mode=yes
netbsd_en=no
vxworks_en=no
bootdelay=3
disaMvPnp=no
enaAutoRecovery=no
pcieTune=no
filesize=33AA2E
bootargs=console=ttyS0,115200 root=/dev/ram0 rw ramdisk=0x01100000,8M install_type=nand
bootargs_root=ubi.mtd=2,2048 root=ubi0:rootfs rootfstype=ubifs init=/linuxrc
console2=console=ttyS0,115200
bootcmd=nand read.e 0x800000 0x100000 0x600000; setenv bootargs $(console2) $(bootargs_root); bootm 0x800000
Re: How to unbrick GoFlex Home?
August 12, 2018 04:24AM
balanga

I expected the envs contains mtdparts definition, so we don't have to calculate it. But it was apparently not available so I need to define the layout.

-bodhi
===========================
Forum Wiki
bodhi's corner (buy bodhi a beer)
Re: How to unbrick GoFlex Home?
August 12, 2018 05:22AM
What is preventing me re-installing Stock from a USB stick?

http://support.goflexhome.hipserv.com/en/reflash/index.html
Re: How to unbrick GoFlex Home?
August 12, 2018 07:51AM
balanga Wrote:
-------------------------------------------------------
> What is preventing me re-installing Stock from a
> USB stick?
>
> http://support.goflexhome.hipserv.com/en/reflash/index.html

Have you tried that factory restore?

-bodhi
===========================
Forum Wiki
bodhi's corner (buy bodhi a beer)
Re: How to unbrick GoFlex Home?
August 12, 2018 08:10AM
bodhi Wrote:
-------------------------------------------------------
> balanga Wrote:
> -------------------------------------------------------
> > What is preventing me re-installing Stock from
> a
> > USB stick?
> >
> >
> http://support.goflexhome.hipserv.com/en/reflash/index.html
>
> Have you tried that factory restore?

Not yet, I was scared of breaking something.
Re: How to unbrick GoFlex Home?
August 12, 2018 11:30AM
balanga Wrote:
-------------------------------------------------------
> bodhi Wrote:
> -------------------------------------------------------
> > balanga Wrote:
> >
> -------------------------------------------------------
> > > What is preventing me re-installing Stock
> from
> > a
> > > USB stick?
> > >
> > >
> >
> http://support.goflexhome.hipserv.com/en/reflash/index.html
> >
> > Have you tried that factory restore?
>
> Not yet, I was scared of breaking something.

I just tried and it would not restore, but thankfully did not beak anything.
Author:

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: