Re: RN104 bricked September 20, 2020 06:27PM |
Registered: 3 years ago Posts: 25 |
Quote
since you can log in stock OS with the HDD rootfs, why not let stock OS reinstall the FW for you? there must be a way to do that.
Quote
./nanddump --help
./nandwrite --help
root@nas-36-66-02:/media/tools/tools# ./nanddump --help Usage: nanddump [OPTIONS] MTD-device Dumps the contents of a nand mtd partition. -h --help Display this help and exit --version Output version information and exit --bb=METHOD Choose bad block handling method (see below). -a --forcebinary Force printing of binary data to tty -c --canonicalprint Print canonical Hex+ASCII dump -f file --file=file Dump to file -l length --length=length Length -n --noecc Read without error correction --omitoob Omit OOB data (default) -o --oob Dump OOB data -p --prettyprint Print nice (hexdump) -q --quiet Don't display progress and status messages -s addr --startaddress=addr Start address --bb=METHOD, where METHOD can be `padbad', `dumpbad', or `skipbad': padbad: dump flash data, substituting 0xFF for any bad blocks dumpbad: dump flash data, including any bad blocks skipbad: dump good data, completely skipping any bad blocks (default) root@nas-36-66-02:/media/tools/tools# ./nandwrite --help Usage: nandwrite [OPTION] MTD_DEVICE [INPUTFILE|-] Writes to the specified MTD device. -a, --autoplace Use auto OOB layout -m, --markbad Mark blocks bad if write fails -n, --noecc Write without ecc -N, --noskipbad Write without bad block skipping -o, --oob Input contains oob data -O, --onlyoob Input contains oob data and only write the oob part -s addr, --start=addr Set output start address (default is 0) -p, --pad Pad writes to page size -b, --blockalign=1|2|4 Set multiple of eraseblocks to align to --input-skip=length Skip |length| bytes of the input file --input-size=length Only read |length| bytes of the input file -q, --quiet Don't display progress messages -h, --help Display this help and exit --version Output version information and exit
Re: RN104 bricked September 20, 2020 07:35PM |
Registered: 7 years ago Posts: 181 |
Quote
Removed OS HDD
Starting the boot process... Detected system type: RN104 Loading kernel modules...done Boot mode: Normal [ 4.382673] ubi0 error: ubi_io_read: error -74 (ECC error) while reading 64 bytes from PEB 0:0, read 64 bytes [ 4.394049] ubi0 error: ubi_io_read: error -74 (ECC error) while reading 64 bytes from PEB 1:0, read 64 bytes ... [ 5.744448] ubi0 error: ubi_io_read: error -74 (ECC error) while reading 64 bytes from PEB 122:0, read 64 bytes [ 22.023591] ubi0 error: ubi_io_read: error -74 (ECC error) while reading 64 bytes from PEB 917:0, read 64 bytes UBI device number 0, total 919 LEBs (116690944 bytes, 111.3 MiB), available 11 LEBs (1396736 bytes, 1.3 MiB), LEB size 126976 bytes (124.0 KiBI don't know what happened here, but it may be failing to open the last mtd partition. After boot completes, you may issue the command
dmesgon both boxes to figure out what happened and what should happen 4.4 seconds into kernel boot. Maybe it failed to open the last of the 5 mtd-partitions.
Bringing up network...eth0.done ERROR: Resolving timed out after 10008 milliseconds command failed: /usr/bin/rnutil firmware_updateeth1 is the prime Ethernet connection, so the time out may be because it tries to connect on this connector first, but only succeeds wen it falls back to eth0. Also, since you have cloned the U-Boot environment from your good box, you must only power up one at a time for now since they will have the same mac address. All kinds of issues may be observed when there are two boxes with equal mac addresses on the same network.
ping update.readynas.com PING update.readynas.com (206.16.42.180) 56(84) bytes of data.
mdadm: array /dev/md0 started. mke2fs 1.42.13 (17-May-2015) Discarding device blocks: done Creating filesystem with 1047552 4k blocks and 1048576 inodes Filesystem UUID: f47add44-1aef-48ae-8b95-ba14d8873a22 Superblock backups stored on blocks: 32768, 98304, 163840, 229376, 294912, 819200, 884736 Allocating group tables: done Writing inode tables: done Creating journal (16384 blocks): done Writing superblocks and filesystem accounting information: doneThis looks to me that the box successfully creates an empty ext3 file system (ext2 + journaling) on the first RAID partition, but maybe it is created on the USB-stick in stead since you removed all disks?
Extracting root image...ERROR: Could not mount boot flash [/dev/ubi0_0] (Invalid argument) command failed: mdev -sI may be wrong, but this might be where the newly created file system should have been populated with files extracted and uncompressed from the last mtd partition.
Re: RN104 bricked September 20, 2020 08:57PM |
Admin Registered: 13 years ago Posts: 18,821 |
./nanddump --noecc --omitoob -f mtd0.u-boot.rn104 /dev/mtd0 ./nanddump --noecc --omitoob -f mtd1.u-boot-env.rn104 /dev/mtd1 ./nanddump --noecc --omitoob -f mtd2.uImage.rn104 /dev/mtd2 ./nanddump --noecc --omitoob -f mtd3.minirootfs.rn104 /dev/mtd3 ./nanddump --noecc --omitoob -f mtd4.ubifs.rn104 /dev/mtd4
./nandwrite --noecc /dev/mtd0 mtd0.u-boot.rn104 ./nandwrite --noecc /dev/mtd1 mtd1.u-boot-env.rn104 ./nandwrite --noecc /dev/mtd2 mtd2.uImage.rn104 ./nandwrite --noecc /dev/mtd3 mtd3.minirootfs.rn104 ./nandwrite --noecc /dev/mtd4 mtd4.ubifs.rn104
printenvI expect the bootargs need to be revised here, so you can post the output, boot into HDD OS again, and wait for my next post.
Re: RN104 bricked September 22, 2020 09:38PM |
Registered: 3 years ago Posts: 25 |
Re: RN104 bricked September 22, 2020 11:35PM |
Admin Registered: 13 years ago Posts: 18,821 |
Quote
The Wiki thread:
Quote
https://forum.doozan.com/read.php?2,23630
Unbricking with Serial Console & JTAG console
Repair Pogo E02 with Raspberry PI (JTAG) and OpenOCD
Serial Port connector - what are people using to make it work
Serial Console hookup - GoFlex Net (external link)
Serial Console hookup - Pogoplug E02 and Pogoplug Pro V3 (external link)
OSX Serial/Net Console
Use Phone Jack - Phone Jack Serial Console Pics
Adding serial connector to Pogoplug Mobile (external link)
WD Mycloud EX2100/4100 Serial Console pic1, also pic2, pic3
Dreamplug Serial Console
How to unbrick your box using serial console with kwboot
kwboot on Mac OSX 10
Unbrick a Pogoplug Pro v3 OXNAS by flashing u-boot in serial console
Unbricking Synology Diskstation DS414 - See also the working thread for this unbricking session
You would start kwboot from where you run serial console (use the kwboot command in that distribution would suffice)
If the mtd0 nanddump file is mtd0_backup_file:
kwboot -t -B 115200 /dev/ttyUSB0 -b mtd0_backup_file -p
And then power up the RN102 box. If kwboot handshakes with the RN102 BootROM successfully, it will start sending the mtd0_backup_file binary. When it completed, the RN102 BootROM will run this u-boot. And the rest is similar to a typicall serial console session.
Re: RN104 bricked September 22, 2020 11:43PM |
Registered: 3 years ago Posts: 25 |
Quote
Did you try reflashing stock mtd3 and mtd4? and how did you do that? i.e. usually ubifs need to be flashed with different command, not nand write.
If root.tlz is an mtd4 nanddump, then flash with nand write. But if it is a rootfs backup, you would need to create UBIFS volume, write it ,.... in UBIFS way (look at documentation how Netgear flash this).
-bodhi
===========================
alxvt:
yep,
i did it with nand write but it is a rootfs backup
from what i understand (tarred with lzma),
so i am going to try recreating the UBIFS
Re: RN104 bricked September 22, 2020 11:52PM |
Registered: 3 years ago Posts: 25 |
root@nas-36-66-02:~# lsblk NAME MAJ:MIN RM SIZE RO TYPE MOUNTPOINT sda 8:0 0 149G 0 disk ├─sda1 8:1 0 4G 0 part │ └─md0 9:0 0 4G 0 raid1 / ├─sda2 8:2 0 512M 0 part │ └─md1 9:1 0 511.4M 0 raid1 [SWAP] └─sda3 8:3 0 144.5G 0 part └─md127 9:127 0 144.4G 0 raid1 /data mtdblock0 31:0 0 1.5M 1 disk mtdblock1 31:1 0 512K 1 disk mtdblock2 31:2 0 6M 1 disk mtdblock3 31:3 0 4M 1 disk mtdblock4 31:4 0 116M 1 disk
root@nas-36-66-02:/dev# cat /proc/mtd dev: size erasesize name mtd0: 00180000 00020000 "u-boot" mtd1: 00080000 00020000 "u-boot-env" mtd2: 00600000 00020000 "uImage" mtd3: 00400000 00020000 "minirootfs" mtd4: 07400000 00020000 "ubifs"
Extracting root image...ERROR: Could not mount boot flash [/dev/ubi0_0] (Invalid argument)
Re: RN104 bricked September 23, 2020 12:15AM |
Admin Registered: 13 years ago Posts: 18,821 |
Quote
Extracting root image...ERROR: Could not mount boot flash [/dev/ubi0_0] (Invalid argument)
Re: RN104 bricked September 23, 2020 12:42AM |
Registered: 3 years ago Posts: 25 |
printenv Marvell>> printenv AC_Power_fail_detect=open CASset=min HW_version=MVT MALLOC_len=5 Manufacturer=NETGEAR NANDboot=nand read.e 0x2000000 0x200000 0x400000;nand read.e 0x1000000 0x7e00000 0x20000;nand read.e 0x3000000 0x800000 0x400000;bootz 0x2000000 0x3000000 0x1000000 Product=ReadyNAS 104 SKUNum=RN104 Startup=Normal USBboot=fatload usb 0:1 0x2000000 /zImage-recovery;fatload usb 0:1 0x1000000 /RN104-recovery.dtb;fatload usb 0:1 0x3000000 /initrd-recovery.gz;bootz 0x2000000 0x3000000 0x1000000 Version=V1.0 autoload=no baudrate=115200 bootargs=console=ttyS0,115200 bootargs_end=:10.4.50.254:255.255.255.0:KW40:eth0:none bootargs_root=root=/dev/nfs rw bootcmd=nand read 0x2000000 0x200000 0x400000; nand read 0x3000000 0x800000 0x400000; bootm 0x2000000 0x3000000 0x1000000 bootcmd_fdt=tftpboot 0x2000000 $image_name;tftpboot $fdtaddr $fdtfile;setenv bootargs $console $mtdparts $bootargs_root nfsroot=$serverip:$rootpath ip=$ipaddr:$serverip$bootargs_end $mvNetConfig video=dovefb:lcd0:$lcd0_params clcd.lcd0_enable=$lcd0_enable clcd.lcd_panel=$lcd_panel; bootz 0x2000000 - $fdtaddr; bootcmd_ubi=ubi part ubifs; ubifsmount rootfs; ubifsload 0x2000000 kernel; ubifsload 0x3000000 initrd.gz; bootm 0x2000000 0x3000000 0x1000000 bootdelay=0 cacheShare=no check_usb=usb start; fatload usb 0:1 0x2000000 /NTGR_USBBOOT_INFO.txt console=console=ttyS0,115200 disL2Cache=yes disaMvPnp=no eeeEnable=no enaAutoRecovery=yes enaClockGating=yes enaFPU=no enaWrAllo=no envver=3 eth1addr=00:50:43:02:00:00 eth1mtu=1500 ethact=egiga1 ethaddr=00:50:43:02:02:00 ethmtu=1500 ethprime=egiga1 fdt_skip_update=no fdtaddr=0x1000000 fdtfile=armada-370-db.dtb image_name=uImage initrd_high=0xFFFFFFFF initrd_name=uInitrd ipaddr=192.168.82.234 loadaddr=0x02000000 loads_echo=0 mtdids=nand0=armada-nand mtdparts=mtdparts=armada-nand:0x180000@0(u-boot),0x20000@0x180000(u-boot-env),0x600000@0x200000(uImage),0x400000@0x800000(minirootfs),-(ubifs) mvNetConfig=switch_config=none mv_pon_addr=00:50:43:00:00:02 nandEcc=1bit netbsd_en=no netmask=255.255.255.0 netretry=no pcieTune=no pexMode=rc pxe_files_load=:default.arm-armada370-db:default.arm-armadaxp:default.arm pxefile_addr_r=3100000 rcvrip=169.254.100.100 rootpath=/srv/oneiric sata_delay_reset=0 sata_dma_mode=yes serverip=192.168.82.150 standalone=fsload 0x2000000 $image_name;setenv bootargs $console $mtdparts root=/dev/mtdblock0 rw ip=$ipaddr:$serverip$bootargs_end; bootm 0x2000000; stderr=serial stdin=serial stdout=serial usb0Mode=host usb1Mode=host usb2Mode=device usbActive=0 vxworks_en=no yuk_ethaddr=00:00:00:EE:51:81 Environment size: 2690/131068 bytes
| \/ | __ _ _ ____ _____| | | | |\/| |/ _` | '__\ \ / / _ \ | | | | | | (_| | | \ V / __/ | | |_| |_|\__,_|_| \_/ \___|_|_| _ _ ____ _ | | | | | __ ) ___ ___ | |_ | | | |___| _ \ / _ \ / _ \| __| | |_| |___| |_) | (_) | (_) | |_ \___/ |____/ \___/ \___/ \__| ** LOADER ** U-Boot 2011.12-gec25d27-dirty (Oct 26 2015 - 16:56:14) Marvell version: v2011.12 2014_T2.0p1 06/23/2015 ReadyNAS-104 V2.0 Board: DB-88F6710-BP SoC: MV6710 A1 CPU: Marvell PJ4B v7 UP (Rev 1) LE CPU @ 1200 [MHz] L2 @ 600 [MHz] TClock @ 200 [MHz] DDR @ 600 [MHz] DDR 16Bit Width, FastPath Memory Access DRAM: 512 MiB Map: Code: 0x1feef000:0x1ff9f514 BSS: 0x1ffef8a0 Stack: 0x1f9eeef8 Heap: 0x1f9ef000:0x1feef000 NAND: (ID 0xf1ad) 128 MiB MMC: MRVL_MMC: 0 Bad block table found at page 65472, version 0x01 Bad block table found at page 65408, version 0x01 nand_read_bbt: Bad block at 0x000002120000 nand_read_bbt: Bad block at 0x000004580000 nand_read_bbt: Bad block at 0x000007640000 Initialize and scan all PCI interfaces PEX unit.port(active IF[-first bus]): ------------------------------------------ PEX 0: Root Complex Interface, Detected Link X1, GEN 2.0 PEX 1: Root Complex Interface, Detected Link X1, GEN 2.0 FPU not initialized USB 0: Host Mode USB 1: Host Mode Shutting down unused interfaces: SDIO AUDIO TDM Modules/Interfaces Detected: RGMII0 Phy RGMII1 Phy PEX0 (Lane 0) PEX1 (Lane 1) SATA0 (Lane 2) SATA1 (Lane 3) Net: egiga0, egiga1 [PRIME] Power On! FDT loaded successfully Hit any key to stop autoboot: 0 NAND read: device 0 offset 0x200000, size 0x400000 4194304 bytes read: OK NAND read: device 0 offset 0x800000, size 0x400000 4194304 bytes read: OK Wrong Image Format for bootm command ERROR: can't get kernel image! Marvell>> Marvell>> setenv serverip 192.168.1.3 Marvell>> setenv ipaddr 192.168.1.2 Marvell>> setenv gatewayip 192.168.1.1 Marvell>> tftpboot 0x000000000000 uboot.bin Using egiga0 device TFTP from server 192.168.1.3; our IP address is 192.168.1.2 Filename 'uboot.bin'. Load address: 0x0 Loading: ############################################################# done Bytes transferred = 894280 (da548 hex) Marvell>> nand write 0x000000000000 0x000000020000 0x000000180000 NAND write: device 0 offset 0x20000, size 0x180000 1572864 bytes written: OK Marvell>> tftpboot 0x2000000 kernel.arm Using egiga0 device TFTP from server 192.168.1.3; our IP address is 192.168.1.2 Filename 'kernel.arm'. Load address: 0x2000000 Loading: ################################################################# ################################################################# ################################################################# ########################################## done Bytes transferred = 3474632 (3504c8 hex) Marvell>> nand write 0x2000000 0x200000 0x400000 NAND write: device 0 offset 0x200000, size 0x400000 4194304 bytes written: OK Marvell>> tftpboot 0x3000000 initrd.gz Using egiga0 device TFTP from server 192.168.1.3; our IP address is 192.168.1.2 Filename 'initrd.gz'. Load address: 0x3000000 Loading: ################################################################# ################################################################# ################################################################# ####################################### done Bytes transferred = 3425169 (344391 hex) Marvell>> nand write 0x3000000 0x800000 0x400000 NAND write: device 0 offset 0x800000, size 0x400000 4194304 bytes written: OK Marvell>> boot ## Booting kernel from Legacy Image at 02000000 ... Image Name: Linux-4.4.190.armada.1 Created: 2019-10-28 2:07:50 UTC Image Type: ARM Linux Kernel Image (uncompressed) Data Size: 3474568 Bytes = 3.3 MiB Load Address: 00008000 Entry Point: 00008000 Verifying Checksum ... OK ## Loading init Ramdisk from Legacy Image at 03000000 ... Image Name: initramfs Created: 2020-02-12 1:13:27 UTC Image Type: ARM Linux RAMDisk Image (lzma compressed) Data Size: 3425105 Bytes = 3.3 MiB Load Address: 00000000 Entry Point: 00000000 Verifying Checksum ... OK ## Flattened Device Tree blob at 01000000 Booting using the fdt blob at 0x01000000 Loading Kernel Image ... OK Loading Ramdisk to 1f6aa000, end 1f9ee351 ... OK Using Device Tree in place at 01000000, end 010068e5 Updating device tree successful Starting kernel ... Starting the boot process... Detected system type: RN104 Loading kernel modules...done Boot mode: Normal UBI device number 0, total 919 LEBs (116690944 bytes, 111.3 MiB), available 915 LEBs (116183040 bytes, 110.8 MiB), LEB size 126976 bytes (124.0 KiB) Searching for disks (5)... Bringing up network...done ERROR: Could not resolve host: update.readynas.com command failed: /usr/bin/rnutil firmware_update mdadm: array /dev/md0 started. mke2fs 1.42.13 (17-May-2015) Discarding device blocks: done Creating filesystem with 1047552 4k blocks and 1048576 inodes Filesystem UUID: 1ea9e77c-a133-4bd0-bb95-b6b9db536643 Superblock backups stored on blocks: 32768, 98304, 163840, 229376, 294912, 819200, 884736 Allocating group tables: done Writing inode tables: done Creating journal (16384 blocks): done Writing superblocks and filesystem accounting information: done Extracting root image...ERROR: Could not mount boot flash [/dev/ubi0_0] (Invalid argument) Welcome to ReadyNASOS nas-02-02-00 login: command failed: mdev -s command failed: /usr/sbin/telnetd Welcome to ReadyNASOS nas-02-02-00 login:
Re: RN104 bricked September 23, 2020 01:25AM |
Registered: 7 years ago Posts: 181 |
Quote
I have manage to create a recovery USB.
Re: RN104 bricked September 23, 2020 02:28AM |
Admin Registered: 13 years ago Posts: 18,821 |
UBI device number 0, total 919 LEBs (116690944 bytes, 111.3 MiB), available 915 LEBs (116183040 bytes, 110.8 MiB), LEB size 126976 bytes (124.0 KiB) Searching for disks (5)... Bringing up network...done ERROR: Could not resolve host: update.readynas.com command failed: /usr/bin/rnutil firmware_update
Marvell>> setenv serverip 192.168.1.3 Marvell>> setenv ipaddr 192.168.1.2 Marvell>> setenv gatewayip 192.168.1.1
ping 8.8.8.8
Welcome to ReadyNASOS nas-02-02-00 login:
ping 192.168.1.1 ping 8.8.8.8
/usr/bin/rnutil firmware_updateSee how it behaves, whether the stock FW can be upgraded this way,
Re: RN104 bricked September 23, 2020 04:01AM |
Registered: 7 years ago Posts: 181 |
Re: RN104 bricked September 23, 2020 04:52AM |
Admin Registered: 13 years ago Posts: 18,821 |
Quote
ERROR: Could not resolve host: update.readynas.com
command failed: /usr/bin/rnutil firmware_update
PING update.readynas.com (206.16.42.180): 56 data bytes Request timeout for icmp_seq 0 Request timeout for icmp_seq 1 Request timeout for icmp_seq 2 Request timeout for icmp_seq 3 Request timeout for icmp_seq 4 Request timeout for icmp_seq 5 Request timeout for icmp_seq 6
Re: RN104 bricked September 24, 2020 09:30PM |
Registered: 9 years ago Posts: 451 |
> PING update.readynas.com (206.16.42.180): 56 data > bytes > Request timeout for icmp_seq 0 > Request timeout for icmp_seq 1 > Request timeout for icmp_seq 2 > Request timeout for icmp_seq 3 > Request timeout for icmp_seq 4 > Request timeout for icmp_seq 5 > Request timeout for icmp_seq 6 >>
Forbidden You don't have permission to access this resource. Apache/2.4.25 (Debian) Server at update.readynas.com Port 80
Re: RN104 bricked September 28, 2020 02:01PM |
Registered: 7 years ago Posts: 181 |
Quote
rayknight
Except ping is not always a good indicator of whether or not a site is available
root@rn102:~# apt install -y binutils root@rn102:~# strings /usr/bin/rnutil | grep netgear https://my.netgear.com/ajax/Update/firmware/firmware?serial_number=%s&model=%s&firmware_version=%s root@rn102:~# rnutil firmware_update name: ReadyNASOS version: 6.10.3 verno: 6010003 time: 1581469513 arch: arm size: 77369344 md5sum: fe0afd1f70df930a070482a2ddbcee19 descr: ReadyNASOS Not downgrading firmware.So Netgear's firmware update service is active.
Re: RN104 bricked May 04, 2021 01:41PM |
Registered: 4 years ago Posts: 116 |
JF
Re: RN104 bricked July 23, 2021 06:35PM |
$ unzip ReadyNASOS-6.10.5-arm.zip Archive: ReadyNASOS-6.10.5-arm.zip inflating: ReadyNASOS-6.10.5-arm.img inflating: ReadyNASOS-6.10.5_Release_Notes.html
$ mkdir ReadyNASOS-6.10.5-arm $ 7z x -oReadyNASOS-6.10.5-arm ReadyNASOS-6.10.5-arm.img [ ... ] Extracting archive: ReadyNASOS-6.10.5-arm.img -- Path = ReadyNASOS-6.10.5-arm.img Type = tar Offset = 16384 Physical Size = 77291520 Headers Size = 13312 Code Page = UTF-8 Everything is Ok Files: 12 Size: 77275568 Compressed: 77307904
$ ls -ahlp ReadyNASOS-6.10.5-arm/ total 74M drwxr-xr-x 2 XXX XXX 280 Jul 23 23:13 ./ drwxrwxrwt 20 root root 620 Jul 23 23:13 ../ -rw-r--r-- 1 XXX XXX 551 Apr 22 07:16 csums.md5 -rw-r--r-- 1 XXX XXX 3.3M Apr 22 07:16 initrd.gz -rw-r--r-- 1 XXX XXX 3.4M Apr 22 07:16 kernel -rw-r--r-- 1 XXX XXX 3.3M Apr 22 07:16 kernel.alpine -rw-r--r-- 1 XXX XXX 0 Apr 22 07:16 kernel.arm -rw-r--r-- 1 XXX XXX 59M Apr 22 07:16 root.tlz -rw-r--r-- 1 XXX XXX 872K Apr 22 07:16 u-boot-rn102-2.0.img -rw-r--r-- 1 XXX XXX 874K Apr 22 07:16 u-boot-rn104-2.0.img -rw-r--r-- 1 XXX XXX 1.1M Apr 22 07:16 u-boot-rn202-1.2.img -rw-r--r-- 1 XXX XXX 1.1M Apr 22 07:16 u-boot-rn204-1.2.img -rw-r--r-- 1 XXX XXX 972K Apr 22 07:16 u-boot-rn2120-2.0.img -rw-r--r-- 1 XXX XXX 872K Apr 22 07:16 u-boot-rn25-2.0.img
$ /usr/sbin/mkfs.ubifs -v -r ReadyNASOS-6.10.5-arm -m 2048 -e 126976 -c 907 -o ReadyNASOS-6.10.5-arm.ubifs mkfs.ubifs root: ReadyNASOS-6.10.5-arm/ min_io_size: 2048 leb_size: 126976 max_leb_cnt: 907 output: ReadyNASOS-6.10.5-arm.ubifs jrn_size: 8388608 reserved: 0 compr: lzo keyhash: r5 fanout: 8 orph_lebs: 1 space_fixup: 0 selinux file: (null) super lebs: 1 master lebs: 2 log_lebs: 5 lpt_lebs: 2 orph_lebs: 1 main_lebs: 611 gc lebs: 1 index lebs: 5 leb_cnt: 622 UUID: F9374152-8713-46B4-901C-DEA723F62167 Success!
$ cp -v ReadyNASOS-6.10.5-arm.ubifs ReadyNASOS-6.10.5-arm/kernel ReadyNASOS-6.10.5-arm/initrd.gz /media/sdb1/ 'ReadyNASOS-6.10.5-arm.ubifs' -> '/media/sdb1/ReadyNASOS-6.10.5-arm.ubifs' 'ReadyNASOS-6.10.5-arm/kernel' -> '/media/sdb1/kernel' 'ReadyNASOS-6.10.5-arm/initrd.gz' -> '/media/sdb1/initrd.gz'
Marvell>> usb start (Re)start USB... USB: Active port: 0 Register 10011 NbrPorts 1 USB EHCI 1.00 scanning bus for devices... 2 USB Device(s) found scanning bus for storage devices... 1 Storage Device(s) found Marvell>> usb tree Device Tree: 1 Hub (480 Mb/s, 0mA) | u-boot EHCI Host Controller | +-2 Mass Storage (480 Mb/s, 100mA) USB Flash Memory 0611132321190 Marvell>> fatls usb 0:1 78979072 readynasos-6.10.5-arm.ubifs 3479896 kernel 3427623 initrd.gz 3 file(s), 0 dir(s)
Marvell>> mtdparts device nand0 <armada-nand>, # parts = 5 #: name size offset mask_flags 0: u-boot 0x000000180000 0x000000000000 0 1: u-boot-env 0x000000020000 0x000000180000 0 2: uImage 0x000000600000 0x000000200000 0 3: minirootfs 0x000000400000 0x000000800000 0 4: ubifs 0x000007400000 0x000000c00000 0 active partition: nand0,0 - (u-boot) 0x000000180000 @ 0x000000000000 defaults: mtdids : none mtdparts: none Marvell>> nand erase uImage 0x000000600000 NAND erase: device 0 offset 0x200000, size 0x600000 Erasing at 0x7e0000 -- 100% complete. OK Marvell>> nand erase minirootfs 0x000000400000 NAND erase: device 0 offset 0x800000, size 0x400000 Erasing at 0xbe0000 -- 100% complete. OK Marvell>> nand erase ubifs 0x000007400000 NAND erase: device 0 offset 0xc00000, size 0x7400000 Skipping bad block at 0x07f00000 Skipping bad block at 0x07f20000 Skipping bad block at 0x07f40000 Skipping bad block at 0x07f60000 Skipping bad block at 0x07f80000 Skipping bad block at 0x07fa0000 Skipping bad block at 0x07fc0000 Skipping bad block at 0x07fe0000 OK
Marvell>> fatload usb 0:1 0x2000000 kernel reading kernel 3479896 bytes read Marvell>> nand write.trimffs 0x2000000 uImage 0x000000600000 NAND write: device 0 offset 0x200000, size 0x600000 6291456 bytes written: OK Marvell>> fatload usb 0:1 0x2000000 initrd.gz reading initrd.gz 3427623 bytes read Marvell>> nand write.trimffs 0x2000000 minirootfs 0x000000400000 NAND write: device 0 offset 0x800000, size 0x400000 4194304 bytes written: OK
Marvell>> ubi part ubifs Creating 1 MTD partitions on "nand0": 0x000000c00000-0x000008000000 : "mtd=4" UBI: attaching mtd1 to ubi0 UBI: physical eraseblock size: 131072 bytes (128 KiB) UBI: logical eraseblock size: 126976 bytes UBI: smallest flash I/O unit: 2048 UBI: VID header offset: 2048 (aligned 2048) UBI: data offset: 4096 UBI: attached mtd1 to ubi0 UBI: MTD device name: "mtd=4" UBI: MTD device size: 116 MiB UBI: number of good PEBs: 920 UBI: number of bad PEBs: 8 UBI: max. allowed volumes: 128 UBI: wear-leveling threshold: 4096 UBI: number of internal volumes: 1 UBI: number of user volumes: 0 UBI: available PEBs: 907 UBI: total number of reserved PEBs: 13 UBI: number of PEBs reserved for bad PEB handling: 9 UBI: max/mean erase counter: 1/1
Marvell>> ubi createvol rootfs No size specified -> Using max size (115167232) Creating dynamic volume rootfs of size 115167232 Marvell>> ubi info l UBI: volume information dump: UBI: vol_id 0 UBI: reserved_pebs 907 UBI: alignment 1 UBI: data_pad 0 UBI: vol_type 3 UBI: name_len 6 UBI: usable_leb_size 126976 UBI: used_ebs 907 UBI: used_bytes 115167232 UBI: last_eb_bytes 126976 UBI: corrupted 0 UBI: upd_marker 0 UBI: name rootfs UBI: volume information dump: UBI: vol_id 2147479551 UBI: reserved_pebs 2 UBI: alignment 1 UBI: data_pad 0 UBI: vol_type 3 UBI: name_len 13 UBI: usable_leb_size 126976 UBI: used_ebs 2 UBI: used_bytes 253952 UBI: last_eb_bytes 2 UBI: corrupted 0 UBI: upd_marker 0 UBI: name layout volume
Marvell>> fatload usb 0:1 0x2000000 readynasos-6.10.5-arm.ubifs reading readynasos-6.10.5-arm.ubifs 78979072 bytes read
Marvell>> ubi writevol 0x2000000 rootfs 0x4B52000 78979072 bytes written to volume rootfs
Marvell>> ubifsmount rootfs UBIFS: mounted UBI device 0, volume 0, name "rootfs" UBIFS: mounted read-only UBIFS: file system size: 113770496 bytes (111104 KiB, 108 MiB, 896 LEBs) UBIFS: journal size: 9023488 bytes (8812 KiB, 8 MiB, 72 LEBs) UBIFS: media format: w4/r0 (latest is w4/r0) UBIFS: default compressor: LZO UBIFS: reserved for root: 0 bytes (0 KiB) Marvell>> ubifsls 3427623 Thu Apr 22 05:16:56 2021 initrd.gz 3448616 Thu Apr 22 05:16:56 2021 kernel.alpine 1147028 Thu Apr 22 05:16:56 2021 u-boot-rn202-1.2.img 3479896 Thu Apr 22 05:16:56 2021 kernel 60950986 Thu Apr 22 05:16:48 2021 root.tlz 0 Thu Apr 22 05:16:56 2021 kernel.arm 551 Thu Apr 22 05:16:56 2021 csums.md5 995112 Thu Apr 22 05:16:56 2021 u-boot-rn2120-2.0.img 894280 Thu Apr 22 05:16:56 2021 u-boot-rn104-2.0.img 892032 Thu Apr 22 05:16:56 2021 u-boot-rn25-2.0.img 1146748 Thu Apr 22 05:16:56 2021 u-boot-rn204-1.2.img 892696 Thu Apr 22 05:16:56 2021 u-boot-rn102-2.0.img
Marvell>> ubifsumount Unmounting UBIFS volume rootfs!
Marvell>> printenv bootargs bootargs=console=ttyS0,115200 Marvell>> printenv bootcmd bootcmd=nand read 0x2000000 0x200000 0x600000; nand read 0x3000000 0x800000 0x400000; bootm 0x2000000 0x3000000 0x1000000 Marvell>> printenv mtdparts mtdparts=mtdparts=armada-nand:0x180000@0(u-boot),0x20000@0x180000(u-boot-env),0x600000@0x200000(uImage),0x400000@0x800000(minirootfs),-(ubif s)
Marvell>> reset resetting ...
Re: RN104 bricked July 23, 2021 08:28PM |
Admin Registered: 13 years ago Posts: 18,821 |
JF
Re: RN104 bricked July 24, 2021 04:11AM |
info::name=ReadyNASOS,version=6.10.5,time=1619067981,size=77307904,md5sum=0297d035d37792977d2f6b36dd53f31f,arch=arm,descr=ReadyNASOS
Marvell>> nand erase ubifs 0x000007400000 NAND erase: device 0 offset 0xc00000, size 0x7400000 Skipping bad block at 0x07f00000 Skipping bad block at 0x07f20000 Skipping bad block at 0x07f40000 Skipping bad block at 0x07f60000 Skipping bad block at 0x07f80000 Skipping bad block at 0x07fa0000 Skipping bad block at 0x07fc0000 Skipping bad block at 0x07fe0000 OK Marvell>> ubi part ubifs Creating 1 MTD partitions on "nand0": 0x000000c00000-0x000008000000 : "mtd=4" UBI: attaching mtd1 to ubi0 UBI: physical eraseblock size: 131072 bytes (128 KiB) UBI: logical eraseblock size: 126976 bytes UBI: smallest flash I/O unit: 2048 UBI: VID header offset: 2048 (aligned 2048) UBI: data offset: 4096 UBI: attached mtd1 to ubi0 UBI: MTD device name: "mtd=4" UBI: MTD device size: 116 MiB UBI: number of good PEBs: 920 UBI: number of bad PEBs: 8 UBI: max. allowed volumes: 128 UBI: wear-leveling threshold: 4096 UBI: number of internal volumes: 1 UBI: number of user volumes: 0 UBI: available PEBs: 907 UBI: total number of reserved PEBs: 13 UBI: number of PEBs reserved for bad PEB handling: 9 UBI: max/mean erase counter: 1/1
$ dd if=ReadyNASOS-6.10.5-arm.img of=ReadyNASOS-6.10.5-arm.tar bs=1024 skip=16 75480+0 records in 75480+0 records out 77291520 bytes (77 MB, 74 MiB) copied, 0.152685 s, 506 MB/s
$ mkdir ReadyNASOS-6.10.5-arm $ tar -C ReadyNASOS-6.10.5-arm -xvf ReadyNASOS-6.10.5-arm.tar csums.md5 initrd.gz kernel kernel.alpine kernel.arm root.tlz u-boot-rn102-2.0.img u-boot-rn104-2.0.img u-boot-rn202-1.2.img u-boot-rn204-1.2.img u-boot-rn2120-2.0.img u-boot-rn25-2.0.img
$ ls -ahilp ReadyNASOS-6.10.5-arm total 78M 502 drwxr-xr-x 2 XXX XXX 280 Jul 24 10:36 ./ 1 drwxrwxrwt 18 root root 520 Jul 24 10:36 ../ 503 -rw-r--r-- 1 XXX XXX 551 Apr 22 07:16 csums.md5 504 -rw-r--r-- 1 XXX XXX 3.3M Apr 22 07:16 initrd.gz 505 -rw-r--r-- 2 XXX XXX 3.4M Apr 22 07:16 kernel 506 -rw-r--r-- 1 XXX XXX 3.3M Apr 22 07:16 kernel.alpine 505 -rw-r--r-- 2 XXX XXX 3.4M Apr 22 07:16 kernel.arm 507 -rw-r--r-- 1 XXX XXX 59M Apr 22 07:16 root.tlz 508 -rw-r--r-- 1 XXX XXX 872K Apr 22 07:16 u-boot-rn102-2.0.img 509 -rw-r--r-- 1 XXX XXX 874K Apr 22 07:16 u-boot-rn104-2.0.img 510 -rw-r--r-- 1 XXX XXX 1.1M Apr 22 07:16 u-boot-rn202-1.2.img 511 -rw-r--r-- 1 XXX XXX 1.1M Apr 22 07:16 u-boot-rn204-1.2.img 512 -rw-r--r-- 1 XXX XXX 972K Apr 22 07:16 u-boot-rn2120-2.0.img 513 -rw-r--r-- 1 XXX XXX 872K Apr 22 07:16 u-boot-rn25-2.0.img
$ /usr/sbin/mkfs.ubifs --verbose --space-fixup --squash-uids --min-io-size=2048 --leb-size=126976 --max-leb-cnt=907 --root=ReadyNASOS-6.10.5-arm --output=ReadyNASOS-6.10.5-arm.ubifs mkfs.ubifs root: ReadyNASOS-6.10.5-arm/ min_io_size: 2048 leb_size: 126976 max_leb_cnt: 907 output: ReadyNASOS-6.10.5-arm.ubifs jrn_size: 8388608 reserved: 0 compr: lzo keyhash: r5 fanout: 8 orph_lebs: 1 space_fixup: 1 selinux file: (null) super lebs: 1 master lebs: 2 log_lebs: 5 lpt_lebs: 2 orph_lebs: 1 main_lebs: 611 gc lebs: 1 index lebs: 5 leb_cnt: 622 UUID: 2A0E76EA-D40D-402D-B241-0EB8ABD15B9C Success!
$ ubidump -l ReadyNASOS-6.10.5-arm.ubifs ==> ReadyNASOS-6.10.5-arm.ubifs <== -rw-r--r-- 1 0 0 3427623 2021-04-22 05:16:56 initrd.gz -rw-r--r-- 1 0 0 3448616 2021-04-22 05:16:56 kernel.alpine -rw-r--r-- 1 0 0 1147028 2021-04-22 05:16:56 u-boot-rn202-1.2.img -rw-r--r-- 2 0 0 3479896 2021-04-22 05:16:56 kernel -rw-r--r-- 1 0 0 60950986 2021-04-22 05:16:48 root.tlz -rw-r--r-- 2 0 0 3479896 2021-04-22 05:16:56 kernel.arm -rw-r--r-- 1 0 0 551 2021-04-22 05:16:56 csums.md5 -rw-r--r-- 1 0 0 995112 2021-04-22 05:16:56 u-boot-rn2120-2.0.img -rw-r--r-- 1 0 0 894280 2021-04-22 05:16:56 u-boot-rn104-2.0.img -rw-r--r-- 1 0 0 892032 2021-04-22 05:16:56 u-boot-rn25-2.0.img -rw-r--r-- 1 0 0 1146748 2021-04-22 05:16:56 u-boot-rn204-1.2.img -rw-r--r-- 1 0 0 892696 2021-04-22 05:16:56 u-boot-rn102-2.0.img
Marvell>> nand erase ubifs 0x000007400000
Marvell>> ubi part ubifs
Starting the boot process... Detected system type: RN102 Loading kernel modules...done Boot mode: Normal UBI device number 0, total 920 LEBs (116817920 bytes, 111.4 MiB), available 9 LEBs (1142784 bytes, 1.1 MiB), LEB size 126976 bytes (124.0 KiB)
JF
Re: RN104 bricked July 24, 2021 04:14AM |
Re: RN104 bricked July 24, 2021 05:17AM |
Admin Registered: 13 years ago Posts: 18,821 |
JF
Re: RN104 bricked July 24, 2021 05:25AM |
Re: RN104 bricked July 24, 2021 05:52AM |
Admin Registered: 13 years ago Posts: 18,821 |
Quote
Unbricking with Serial Console & JTAG console
How to unbrick your box using serial console with kwboot
Repair Pogo E02 with Raspberry PI (JTAG) and OpenOCD
Serial Port connector - what are people using to make it work
Serial Console hookup - GoFlex Net (external link)
Serial Console hookup - Pogoplug E02 and Pogoplug Pro V3 (external link)
OSX Serial/Net Console
Use Phone Jack - Phone Jack Serial Console Pics
Adding serial connector to Pogoplug Mobile (external link)
WD Mycloud EX2100/4100 Serial Console pic1, also pic2, pic3
Dreamplug Serial Console
kwboot on Mac OSX 10
Unbrick a Pogoplug Pro v3 OXNAS by flashing u-boot in serial console
Unbricking Synology Diskstation DS414 - See also the working thread for this unbricking session
Unbricking (Restore Factory Firmware) Netgear ReadyNAS RN102/104
JF
Re: RN104 bricked July 24, 2021 07:21AM |
Re: RN104 bricked July 24, 2021 03:57PM |
Admin Registered: 13 years ago Posts: 18,821 |
$ /usr/sbin/mkfs.ubifs --verbose --space-fixup --squash-uids --min-io-size=2048 --leb-size=126976 --max-leb-cnt=907 --root=ReadyNASOS-6.10.5-arm --output=ReadyNASOS-6.10.5-arm.ubifs
mkfs.ubifs -q -r /media/rootfs -m 2048 -e 131072 -c 728 -o rescue-v3.img
Re: RN104 bricked July 24, 2021 04:04PM |
Admin Registered: 13 years ago Posts: 18,821 |
JF
Re: RN104 bricked July 24, 2021 05:00PM |
Re: RN104 bricked July 26, 2021 07:35AM |
Registered: 3 years ago Posts: 8 |
Re: RN104 bricked July 26, 2021 04:37PM |
Admin Registered: 13 years ago Posts: 18,821 |