Welcome! Log In Create A New Profile

Advanced

Bricked Synology DS213 (Kirkwood) so close

Posted by itangoii 
Re: Bricked Synology DS213 (Kirkwood) so close
September 29, 2020 04:27PM
itangoii,

Very good progress! as I mentioned,

Quote

We only need to adjust the bootargs a bit. The error you saw at the end was the kernel could not mount the rootfs on USB drive.

So now we will need to adjust the envs so that the kernel will mount the rootfs properly. Normally we don't need to do this with the combination of new u-boot and new rootfs when booting the NSA325.

But since you preprared this this rootfs as if for booting with stock u-boot, which has no Flatten Device Tree (FDT). IOW, you did section 4. So the DTB file should not be loaded because it was embbeded inside uImage.

===

kwbboot again with the USB rootfs attached like currently. After u-boot started, interrupt u-boot at the countdown, and

setenv set_bootargs 'setenv bootargs console=ttyS0,115200 root=LABEL=rootfs rootdelay=10 earlyprintk=serial'
setenv dtb_file

and then boot

boot

This time it should boot all the way to the Debian prompt.

-bodhi
===========================
Forum Wiki
bodhi's corner
Re: Bricked Synology DS213 (Kirkwood) so close
September 29, 2020 06:18PM
bodhi Wrote:

> But since you preprared this this rootfs as if for
> booting with stock u-boot, which has no Flatten
> Device Tree (FDT). IOW, you did section 4. So the
> DTB file should not be loaded because it was
> embbeded inside uImage.

I redid the USB and fired it up. Apparently I've been making it harder than it needed to be ;-(

>
> kwbboot again with the USB rootfs attached like
> currently. After u-boot started, interrupt u-boot
> at the countdown, and
>
> boot

>
> This time it should boot all the way to the Debian
> prompt.

Yes it did ;-)

I take it I've gone as far as I can without the FW U-boot for the DS213?

I cannot thank you enough. I left a message on the Synology forums but there historically little help there.. I'll know next Monday if I can secure the other DS 213.
For now let me know what you think of that U-boot package I lined to. If that many u-boot files are in there and compilable it would be a gold mine for people with bricked Synology nas's.

istening on LPF/eth0/52:3b:20:9c:11:51
Sending on   LPF/eth0/52:3b:20:9c:11:51
Sending on   Socket/fallback
DHCPREQUEST for 192.168.0.15 on eth0 to 255.255.255.255 port 67
[   26.067744][ T1112] mv643xx_eth: Set the PHY back to auto-negotiation mode
[   29.746851][    C0] mv643xx_eth_port mv643xx_eth_port.0 eth0: link up, 1000 Mb/s, full duplex, flow control disabled
DHCPREQUEST for 192.168.0.15 on eth0 to 255.255.255.255 port 67
DHCPNAK from 192.168.0.1
DHCPDISCOVER on eth0 to 255.255.255.255 port 67 interval 8
DHCPOFFER of 192.168.0.217 from 192.168.0.1
DHCPREQUEST for 192.168.0.217 on eth0 to 255.255.255.255 port 67
DHCPACK of 192.168.0.217 from 192.168.0.1
bound to 192.168.0.217 -- renewal in 40143 seconds.
[   37.091446][ T1150] NET: Registered protocol family 10
[   37.098142][ T1150] Segment Routing with IPv6
done.
[ ok ] Starting RPC port mapper daemon: rpcbind.
[ ok ] Starting NFS common utilities: statd idmapd.
[ ok ] Cleaning up temporary files....
INIT: Entering runlevel: 2
[info] Using makefile-style concurrent boot in runlevel 2.
[....] Starting busybox' syslogd implementation : syslogdStarting /sbin/syslogd...
1344 (syslogd)
. ok 
[....] Starting busybox' klogd implementation : klogdStarting /sbin/klogd...
1371 (klogd)
. ok 
[ ok ] Starting system message bus: dbus.
[ ok ] Starting Avahi mDNS/DNS-SD Daemon: avahi-daemon.
[ ok ] Starting NFS common utilities: statd idmapd.
[warn] Not starting NFS kernel daemon: no exports. ... (warning).
[ ok ] Starting NTP server: ntpd.
[ ok ] Starting OpenBSD Secure Shell server: sshd.
[ ok ] Running local boot scripts (/etc/rc.local).

Debian GNU/Linux 10 debian ttyS0


debian login: root
Password: 
Last login: Wed Dec 31 16:02:34 PST 1969 from 192.168.0.100 on pts/0
Linux debian 5.2.9-kirkwood-tld-1 #1 PREEMPT Sat Aug 17 15:00:56 PDT 2019 armv5tel

The programs included with the Debian GNU/Linux system are free software;
the exact distribution terms for each program are described in the
individual files in /usr/share/doc/*/copyright.

Debian GNU/Linux comes with ABSOLUTELY NO WARRANTY, to the extent
permitted by applicable law.
root@debian:~# 
Re: Bricked Synology DS213 (Kirkwood) so close
September 30, 2020 12:27AM
itangoii,

> > kwbboot again with the USB rootfs attached like
> > currently. After u-boot started, interrupt
> u-boot
> > at the countdown, and
> >
> > boot
>
> >
> > This time it should boot all the way to the
> Debian
> > prompt.
>
> Yes it did ;-)

Awesome :)

But please post the entire boot log. So I can double check and see if any thing needs revised.

>
> I take it I've gone as far as I can without the FW
> U-boot for the DS213?

Yes. In fact, now that you can boot into the rootfs with Kirkwood kernel, you are home free in a way, even without the correct u-boot.

The important thing to do is to make permanent. And this box uses SPI flash. So even if you have to to flash the NSA325 u-boot, we'll have a little bit more works to do. If it all come to that, I might try to build a new u-boot for this DS213 box (no promise, though).

However, the immediate goal here is to restore stock FW to you can take advantage of Synology packages. So running Debian is a bonus, and a path to rescue.

> I cannot thank you enough. I left a message on
> the Synology forums but there historically little
> help there..

OK. That is expected. If there is no tech supports monitoring the forum, nothing will happen.


> For now let me know what you think of that U-boot
> package I lined to.
> If that many u-boot files are
> in there and compilable it would be a gold mine
> for people with bricked Synology nas's.


I need to find some free time to download and read that source. I'm a little bit busy with day job right now. Perhaps in the next couple days.

-bodhi
===========================
Forum Wiki
bodhi's corner
Re: Bricked Synology DS213 (Kirkwood) so close
October 01, 2020 12:17PM
As requested the full boot.


94 % [......................................................................]
 95 % [......................................................................]
 97 % [......................................................................]
 99 % [....................................]
[Type Ctrl-\ + c to quit]


U-Boot 2017.07-tld-1 (Sep 05 2017 - 00:42:03 -0700)
ZyXEL NSA325 2-Bay Power Media Server

SoC:   Kirkwood 88F6282_A1
DRAM:  512 MiB
WARNING: Caches not enabled
NAND:  0 MiB
*** Warning - readenv() failed, using default environment

In:    serial
Out:   serial
Err:   serial
Net:   egiga0
MV88E1318 PHY initialized on egiga0
Hit any key to stop autoboot:  0 
starting USB...
USB0:   USB EHCI 1.00
scanning bus 0 for devices... 4 USB Device(s) found
       scanning usb for storage devices... 
Use USB retry period from the environment: 15 second(s)

Use USB retry period from the environment: 15 second(s)
Device NOT ready
   Request Sense returned 02 3A 00

Use USB retry period from the environment: 15 second(s)
Device NOT ready
   Request Sense returned 02 3A 00
1 Storage Device(s) found

Reset IDE: ide_preinit failed

Partition Map for USB device 0  --   Partition Type: DOS

Part	Start Sector	Num Sectors	UUID		Type
  1	2048      	60602368  	ac0e13c9-01	83

## 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 ...
** File not found /boot/uEnv.txt **

no IDE devices available
running scan_disk ...
Scan device usb
device usb 0:1
1 bytes read in 692 ms (0 Bytes/s)
Found bootable drive on usb 0
loading uImage ...
4963680 bytes read in 977 ms (4.8 MiB/s)
loading uInitrd ...
EHCI timed out on TD - token=0xd8d80
9713936 bytes read in 6530 ms (1.4 MiB/s)
loading DTB /boot/dts/kirkwood-nsa325.dtb ...
14006 bytes read in 1553 ms (8.8 KiB/s)
## Booting kernel from Legacy Image at 00800000 ...
   Image Name:   Linux-5.2.9-kirkwood-tld-1
   Created:      2019-08-25   2:22:31 UTC
   Image Type:   ARM Linux Kernel Image (uncompressed)
   Data Size:    4963616 Bytes = 4.7 MiB
   Load Address: 00008000
   Entry Point:  00008000
   Verifying Checksum ... OK
## Loading init Ramdisk from Legacy Image at 01100000 ...
   Image Name:   initramfs-5.2.9-kirkwood-tld-1
   Created:      2019-08-25   2:22:50 UTC
   Image Type:   ARM Linux RAMDisk Image (gzip compressed)
   Data Size:    9713872 Bytes = 9.3 MiB
   Load Address: 00000000
   Entry Point:  00000000
   Verifying Checksum ... OK
## Flattened Device Tree blob at 01c00000
   Booting using the fdt blob at 0x1c00000
   Loading Kernel Image ... OK
   Loading Ramdisk to 1f1ca000, end 1fb0d8d0 ... OK
   Loading Device Tree to 1f1c3000, end 1f1c96b5 ... OK

Starting kernel ...

Uncompressing Linux... done, booting the kernel.
[    0.000000][    T0] Booting Linux on physical CPU 0x0
[    0.000000][    T0] Linux version 5.2.9-kirkwood-tld-1 (root@tldDebian) (gcc version 6.3.0 20170516 (Debian 6.3.0-18+deb9u1)) #1 PREEMPT Sat Aug 17 15:00:56 PDT 2019
[    0.000000][    T0] CPU: Feroceon 88FR131 [56251311] revision 1 (ARMv5TE), cr=0005397f
[    0.000000][    T0] CPU: VIVT data cache, VIVT instruction cache
[    0.000000][    T0] OF: fdt: Machine model: ZyXEL NSA325
[    0.000000][    T0] Memory policy: Data cache writeback
[    0.000000][    T0] Built 1 zonelists, mobility grouping on.  Total pages: 130048
[    0.000000][    T0] Kernel command line: console=ttyS0,115200 root=LABEL=rootfs rootdelay=10 mtdparts=orion_nand:0x100000(uboot),0x80000(stock_uboot_env),0x80000(key_store),0x80000(info),0xA00000(etc),0xA00000(kernel_1),0x2FC0000(rootfs1),0xA00000(kernel_2),0x2FC0000(rootfs2)
[    0.000000][    T0] Dentry cache hash table entries: 65536 (order: 6, 262144 bytes)
[    0.000000][    T0] Inode-cache hash table entries: 32768 (order: 5, 131072 bytes)
[    0.000000][    T0] Memory: 494676K/524288K available (9216K kernel code, 868K rwdata, 3400K rodata, 1024K init, 301K bss, 29612K reserved, 0K cma-reserved)
[    0.000000][    T0] random: get_random_u32 called from cache_alloc_refill+0x38c/0x928 with crng_init=0
[    0.000000][    T0] rcu: Preemptible hierarchical RCU implementation.
[    0.000000][    T0] 	Tasks RCU enabled.
[    0.000000][    T0] rcu: RCU calculated value of scheduler-enlistment delay is 10 jiffies.
[    0.000000][    T0] NR_IRQS: 16, nr_irqs: 16, preallocated irqs: 16
[    0.000000][    T0] clocksource: orion_clocksource: mask: 0xffffffff max_cycles: 0xffffffff, max_idle_ns: 9556302233 ns
[    0.000007][    T0] sched_clock: 32 bits at 200MHz, resolution 5ns, wraps every 10737418237ns
[    0.000039][    T0] Switching to timer-based delay loop, resolution 5ns
[    0.000587][    T0] Console: colour dummy device 80x30
[    0.000630][    T0] Calibrating delay loop (skipped), value calculated using timer frequency.. 400.00 BogoMIPS (lpj=2000000)
[    0.000650][    T0] pid_max: default: 32768 minimum: 301
[    0.000933][    T0] LSM: Security Framework initializing
[    0.001076][    T0] Mount-cache hash table entries: 1024 (order: 0, 4096 bytes)
[    0.001098][    T0] Mountpoint-cache hash table entries: 1024 (order: 0, 4096 bytes)
[    0.001756][    T0] *** VALIDATE proc ***
[    0.001973][    T0] *** VALIDATE cgroup1 ***
[    0.001995][    T0] *** VALIDATE cgroup2 ***
[    0.002077][    T0] CPU: Testing write buffer coherency: ok
[    0.003552][    T1] Setting up static identity map for 0x100000 - 0x100058
[    0.003795][    T1] mvebu-soc-id: MVEBU SoC ID=0x6282, Rev=0x1
[    0.004039][    T1] rcu: Hierarchical SRCU implementation.
[    0.006413][    T1] devtmpfs: initialized
[    0.011549][    T1] clocksource: jiffies: mask: 0xffffffff max_cycles: 0xffffffff, max_idle_ns: 19112604462750000 ns
[    0.011575][    T1] futex hash table entries: 256 (order: -1, 3072 bytes)
[    0.011788][    T1] xor: measuring software checksum speed
[    0.110097][    T1]    arm4regs  :  1799.600 MB/sec
[    0.210059][    T1]    8regs     :  1084.800 MB/sec
[    0.310057][    T1]    32regs    :  1577.200 MB/sec
[    0.310072][    T1] xor: using function: arm4regs (1799.600 MB/sec)
[    0.310089][    T1] prandom: seed boundary self test passed
[    0.312611][    T1] prandom: 100 self tests passed
[    0.312619][    T1] pinctrl core: initialized pinctrl subsystem
[    0.313828][    T1] NET: Registered protocol family 16
[    0.314235][    T1] DMA: preallocated 256 KiB pool for atomic coherent allocations
[    0.314830][    T1] audit: initializing netlink subsys (disabled)
[    0.315876][   T14] audit: type=2000 audit(0.310:1): state=initialized audit_enabled=0 res=1
[    0.315982][    T1] cpuidle: using governor ladder
[    0.316048][    T1] cpuidle: using governor menu
[    0.316463][    T1] Feroceon L2: Enabling L2
[    0.316504][    T1] Feroceon L2: Cache support initialised.
[    0.320703][    T1] No ATAGs?
[    2.560045][    C0] random: fast init done
[    3.878471][   T71] alg: No test for lzo-rle (lzo-rle-generic)
[    3.878741][   T73] alg: No test for lzo-rle (lzo-rle-scomp)
[    4.050674][    T1] raid6: int32x8  gen()   208 MB/s
[    4.220364][    T1] raid6: int32x8  xor()   142 MB/s
[    4.390209][    T1] raid6: int32x4  gen()   209 MB/s
[    4.560135][    T1] raid6: int32x4  xor()   137 MB/s
[    4.730107][    T1] raid6: int32x2  gen()   209 MB/s
[    4.900201][    T1] raid6: int32x2  xor()   151 MB/s
[    5.070274][    T1] raid6: int32x1  gen()   156 MB/s
[    5.240051][    T1] raid6: int32x1  xor()   108 MB/s
[    5.240059][    T1] raid6: using algorithm int32x4 gen() 209 MB/s
[    5.240064][    T1] raid6: .... xor() 137 MB/s, rmw enabled
[    5.240070][    T1] raid6: using intx1 recovery algorithm
[    5.240288][    T1] vgaarb: loaded
[    5.240677][    T1] SCSI subsystem initialized
[    5.241071][    T1] usbcore: registered new interface driver usbfs
[    5.241114][    T1] usbcore: registered new interface driver hub
[    5.241176][    T1] usbcore: registered new device driver usb
[    5.241306][    T1] pps_core: LinuxPPS API ver. 1 registered
[    5.241315][    T1] pps_core: Software ver. 5.3.6 - Copyright 2005-2007 Rodolfo Giometti <giometti@linux.it>
[    5.241334][    T1] PTP clock support registered
[    5.242321][    T1] clocksource: Switched to clocksource orion_clocksource
[    5.870594][    T1] VFS: Disk quotas dquot_6.6.0
[    5.870672][    T1] VFS: Dquot-cache hash table entries: 1024 (order 0, 4096 bytes)
[    5.877486][    T1] NET: Registered protocol family 2
[    5.878117][    T1] tcp_listen_portaddr_hash hash table entries: 512 (order: 0, 4096 bytes)
[    5.878147][    T1] TCP established hash table entries: 4096 (order: 2, 16384 bytes)
[    5.878202][    T1] TCP bind hash table entries: 4096 (order: 2, 16384 bytes)
[    5.878256][    T1] TCP: Hash tables configured (established 4096 bind 4096)
[    5.878331][    T1] UDP hash table entries: 256 (order: 0, 4096 bytes)
[    5.878354][    T1] UDP-Lite hash table entries: 256 (order: 0, 4096 bytes)
[    5.878529][    T1] NET: Registered protocol family 1
[    5.879041][    T1] RPC: Registered named UNIX socket transport module.
[    5.879051][    T1] RPC: Registered udp transport module.
[    5.879057][    T1] RPC: Registered tcp transport module.
[    5.879062][    T1] RPC: Registered tcp NFSv4.1 backchannel transport module.
[    5.879074][    T1] PCI: CLS 0 bytes, default 32
[    5.879260][    T1] Trying to unpack rootfs image as initramfs...
[    6.431070][    T1] Freeing initrd memory: 9488K
[    6.431209][    T1] NetWinder Floating Point Emulator V0.97 (double precision)
[    6.432188][    T1] Initialise system trusted keyrings
[    6.432233][    T1] Key type blacklist registered
[    6.432499][    T1] workingset: timestamp_bits=30 max_order=17 bucket_order=0
[    6.432584][    T1] zbud: loaded
[    6.433396][    T1] NFS: Registering the id_resolver key type
[    6.433419][    T1] Key type id_resolver registered
[    6.433425][    T1] Key type id_legacy registered
[    6.433439][    T1] nfs4filelayout_init: NFSv4 File Layout Driver Registering...
[    6.433453][    T1] Installing knfsd (copyright (C) 1996 okir@monad.swb.de).
[    6.433671][    T1] jffs2: version 2.2. (NAND) (SUMMARY)  © 2001-2006 Red Hat, Inc.
[    6.433838][    T1] fuse: init (API version 7.31)
[    6.434139][    T1] orangefs_debugfs_init: called with debug mask: :none: :0:
[    6.434271][    T1] orangefs_init: module version upstream loaded
[    6.434280][    T1] SGI XFS with ACLs, security attributes, realtime, scrub, no debug enabled
[    6.446783][    T1] async_tx: api initialized (async)
[    6.446804][    T1] Key type asymmetric registered
[    6.446811][    T1] Asymmetric key parser 'x509' registered
[    6.446873][    T1] Block layer SCSI generic (bsg) driver version 0.4 loaded (major 246)
[    6.447934][    T1] kirkwood-pinctrl f1010000.pin-controller: registered pinctrl driver
[    6.449324][    T1] mvebu-pcie mbus@f1000000:pcie@82000000: PCI host bridge to bus 0000:00
[    6.449343][    T1] pci_bus 0000:00: root bus resource [bus 00-ff]
[    6.449353][    T1] pci_bus 0000:00: root bus resource [mem 0xe0000000-0xefffffff]
[    6.449362][    T1] pci_bus 0000:00: root bus resource [io  0x1000-0xeffff]
[    6.449460][    T1] pci 0000:00:01.0: [11ab:6282] type 01 class 0x060400
[    6.449491][    T1] pci 0000:00:01.0: reg 0x38: [mem 0x00000000-0x000007ff pref]
[    6.450510][    T1] PCI: bus0: Fast back to back transfers disabled
[    6.450529][    T1] pci 0000:00:01.0: bridge configuration invalid ([bus 00-00]), reconfiguring
[    6.451485][    T1] PCI: bus1: Fast back to back transfers enabled
[    6.451502][    T1] pci_bus 0000:01: busn_res: [bus 01-ff] end is updated to 01
[    6.451635][    T1] pci 0000:00:01.0: BAR 6: assigned [mem 0xe0000000-0xe00007ff pref]
[    6.451647][    T1] pci 0000:00:01.0: PCI bridge to [bus 01]
[    6.452088][    T1] mv_xor f1060800.xor: Marvell shared XOR driver
[    6.512855][    T1] mv_xor f1060800.xor: Marvell XOR (Registers Mode): ( xor cpy intr )
[    6.514178][    T1] mv_xor f1060900.xor: Marvell shared XOR driver
[    6.572863][    T1] mv_xor f1060900.xor: Marvell XOR (Registers Mode): ( xor cpy intr )
[    6.574421][    T1] Serial: 8250/16550 driver, 2 ports, IRQ sharing disabled
[    6.575390][    T1] printk: console [ttyS0] disabled
[    6.575453][    T1] f1012000.serial: ttyS0 at MMIO 0xf1012000 (irq = 26, base_baud = 12500000) is a 16550A
[    7.425525][    T1] printk: console [ttyS0] enabled
[    7.435861][    T1] loop: module loaded
[    7.440181][    T1] sata_mv f1080000.sata: slots 32 ports 2
[    7.447767][    T1] scsi host0: sata_mv
[    7.452043][    T1] scsi host1: sata_mv
[    7.456167][    T1] ata1: SATA max UDMA/133 irq 32
[    7.460975][    T1] ata2: SATA max UDMA/133 irq 32
[    7.712347][    T1] nand: No NAND device found
[    7.717653][    T1] libphy: Fixed MDIO Bus: probed
[    7.723059][    T1] libphy: orion_mdio_bus: probed
[    7.738648][    T1] mv643xx_eth: MV-643xx 10/100/1000 ethernet driver version 1.4
[    7.746622][    T1] mv643xx_eth_port mv643xx_eth_port.0: DMA mask not set
[    7.754225][    T1] mv643xx_eth: Set the PHY to fix link down
[    7.754678][    T1] mv643xx_eth_port mv643xx_eth_port.0 eth0: port 0 with MAC address 52:3b:20:9c:11:51
[    7.770090][    T1] ehci_hcd: USB 2.0 'Enhanced' Host Controller (EHCI) Driver
[    7.777415][    T1] ehci-pci: EHCI PCI platform driver
[    7.782664][    T1] ehci-orion: EHCI orion driver
[    7.787532][    T1] orion-ehci f1050000.ehci: EHCI Host Controller
[    7.793793][  T112] ata1: SATA link down (SStatus 0 SControl F300)
[    7.800065][    T1] orion-ehci f1050000.ehci: new USB bus registered, assigned bus number 1
[    7.808607][    T1] orion-ehci f1050000.ehci: irq 30, io mem 0xf1050000
[    7.842342][    T1] orion-ehci f1050000.ehci: USB 2.0 started, EHCI 1.00
[    7.849288][    T1] usb usb1: New USB device found, idVendor=1d6b, idProduct=0002, bcdDevice= 5.02
[    7.858306][    T1] usb usb1: New USB device strings: Mfr=3, Product=2, SerialNumber=1
[    7.866269][    T1] usb usb1: Product: EHCI Host Controller
[    7.871862][    T1] usb usb1: Manufacturer: Linux 5.2.9-kirkwood-tld-1 ehci_hcd
[    7.879216][    T1] usb usb1: SerialNumber: f1050000.ehci
[    7.885101][    T1] hub 1-0:1.0: USB hub found
[    7.889592][    T1] hub 1-0:1.0: 1 port detected
[    7.894787][    T1] usbcore: registered new interface driver usb-storage
[    7.901778][    T1] mousedev: PS/2 mouse device common for all mice
[    7.908336][    T1] i2c /dev entries driver
[    7.913283][    T1] rtc-pcf8563 0-0051: pcf8563_write_block_data: err=-6 addr=0e, data=03
[    7.921496][    T1] rtc-pcf8563 0-0051: pcf8563_probe: write error
[    7.927777][    T1] rtc-pcf8563: probe of 0-0051 failed with error -5
[    7.934893][    T1] device-mapper: uevent: version 1.0.3
[    7.940440][    T1] device-mapper: ioctl: 4.40.0-ioctl (2019-01-18) initialised: dm-devel@redhat.com
[    7.949955][    T1] device-mapper: multipath round-robin: version 1.2.0 loaded
[    7.957263][    T1] device-mapper: multipath queue-length: version 0.2.0 loaded
[    7.964644][    T1] device-mapper: multipath service-time: version 0.3.0 loaded
[    7.972035][    T1] device-mapper: dm-log-userspace: version 1.3.0 loaded
[    7.978874][    T1] device-mapper: raid: Loading target version 1.14.0
[    7.986908][    T1] hidraw: raw HID events driver (C) Jiri Kosina
[    7.993319][    T1] drop_monitor: Initializing network drop monitor service
[    8.000527][    T1] NET: Registered protocol family 17
[    8.006016][    T1] Key type dns_resolver registered
[    8.011608][    T1] registered taskstats version 1
[    8.016450][    T1] Loading compiled-in X.509 certificates
[    8.022022][    T1] zswap: loaded using pool lzo/zbud
[    8.094637][    T1] Key type big_key registered
[    8.130202][    T1] Key type encrypted registered
[    8.136634][    T1] hctosys: unable to open rtc device (rtc0)
[    8.142488][  T114] ata2: SATA link down (SStatus 0 SControl F300)
[    8.161919][    T1] Freeing unused kernel memory: 1024K
[    8.167651][    T1] Checked W+X mappings: passed, no W+X pages found
[    8.174066][    T1] Run /init as init process
Loading, please wait...
[    8.262441][   T15] usb 1-1: new high-speed USB device number 2 using orion-ehci
Starting version 241
[    8.484258][   T15] usb 1-1: New USB device found, idVendor=05e3, idProduct=0608, bcdDevice=85.32
[    8.502596][   T15] usb 1-1: New USB device strings: Mfr=0, Product=1, SerialNumber=0
[    8.510472][   T15] usb 1-1: Product: USB2.0 Hub
[    8.544968][   T15] hub 1-1:1.0: USB hub found
[    8.553978][   T15] hub 1-1:1.0: 4 ports detected
[    8.892410][   T15] usb 1-1.3: new high-speed USB device number 3 using orion-ehci
[    9.054754][   T15] usb 1-1.3: New USB device found, idVendor=154b, idProduct=00ed, bcdDevice= 1.10
[    9.071781][   T15] usb 1-1.3: New USB device strings: Mfr=1, Product=2, SerialNumber=3
[    9.088315][   T15] usb 1-1.3: Product: USB 3.0 FD
[    9.097697][   T15] usb 1-1.3: Manufacturer: PNY
[    9.107460][   T15] usb 1-1.3: SerialNumber: 070001690020C088
[    9.119856][   T15] usb-storage 1-1.3:1.0: USB Mass Storage device detected
[    9.128917][   T15] scsi host2: usb-storage 1-1.3:1.0
[    9.140858][  T163] usbcore: registered new interface driver uas
Begin: Loading essential drivers ... done.
[    9.232351][   T15] usb 1-1.4: new high-speed USB device number 4 using orion-ehci
[    9.384358][   T15] usb 1-1.4: New USB device found, idVendor=05e3, idProduct=0726, bcdDevice=99.10
[    9.393468][   T15] usb 1-1.4: New USB device strings: Mfr=0, Product=1, SerialNumber=2
[    9.401522][   T15] usb 1-1.4: Product: USB Storage
[    9.406429][   T15] usb 1-1.4: SerialNumber: 000000009910
[    9.415816][   T15] usb-storage 1-1.4:1.0: USB Mass Storage device detected
[    9.425036][   T15] scsi host3: usb-storage 1-1.4:1.0
[   10.163568][    T7] scsi 2:0:0:0: Direct-Access     PNY      USB 3.0 FD       PMAP PQ: 0 ANSI: 6
[   10.176786][   T23] sd 2:0:0:0: [sda] 60604416 512-byte logical blocks: (31.0 GB/28.9 GiB)
[   10.190655][   T23] sd 2:0:0:0: [sda] Write Protect is off
[   10.196760][   T23] sd 2:0:0:0: [sda] Write cache: disabled, read cache: enabled, doesn't support DPO or FUA
[   10.256610][   T23]  sda: sda1
[   10.270518][   T23] sd 2:0:0:0: [sda] Attached SCSI removable disk
[   10.503564][   T23] scsi 3:0:0:0: Direct-Access     Generic  STORAGE DEVICE   9910 PQ: 0 ANSI: 0
[   10.513031][   T23] scsi 3:0:0:1: Direct-Access     Generic  STORAGE DEVICE   9910 PQ: 0 ANSI: 0
[   10.528287][    T7] sd 3:0:0:0: [sdb] Attached SCSI removable disk
[   10.537409][  T116] sd 3:0:0:1: [sdc] Attached SCSI removable disk
Begin: Running /scripts/init-premount ... done.
Begin: Mounting root file system ... Begin: Running /scripts/local-top ... done.
Begin: Running /scripts/local-premount ... done.
Begin: Will now check root file system ... fsck from util-linux 2.33.1
[/sbin/fsck.ext3 (1) -- /dev/sda1] fsck.ext3 -a -C0 /dev/sda1 
rootfs: clean, 15081/1896832 files, 349165/7575296 blocks
done.
[   24.408280][  T196] EXT4-fs (sda1): mounting ext3 file system using the ext4 subsystem
[   24.475461][  T196] EXT4-fs (sda1): mounted filesystem with ordered data mode. Opts: (null)
done.
Begin: Running /scripts/local-bottom ... done.
Begin: Running /scripts/init-bottom ... done.
INIT: version 2.93 booting
[info] Using makefile-style concurrent boot in runlevel S.
[ ok ] Starting hotplug events dispatcher: systemd-udevd.
[ ok ] Synthesizing the initial hotplug events (subsystems)...done.
[ ok [   26.884922][  T376] input: gpio_keys as /devices/platform/gpio_keys/input/input0
                                                           done.
[....] Waiting for /dev to be fully populated...[   26.934337][  T379] systemd-udevd[379]: Using default interface naming scheme 'v240'.
[   27.031484][  T379] systemd-udevd[379]: link_config: autonegotiation is unset or enabled, the speed and duplex are not writable.
[   27.125244][  T385] watchdog: f1020300.watchdog-timer: driver supplied timeout (4294967295) out of range
[   27.275904][  T385] watchdog: f1020300.watchdog-timer: falling back to default timeout (21)
[   27.356365][  T376] sd 2:0:0:0: Attached scsi generic sg0 type 0
[   27.385609][    C0] random: crng init done
[   27.402764][  T385] orion_wdt: Initial timeout 21 sec
[   27.418012][  T377] marvell-cesa f1030000.crypto: CESA device successfully registered
[   27.438119][  T376] sd 3:0:0:0: Attached scsi generic sg1 type 0
[   27.465107][  T376] sd 3:0:0:1: Attached scsi generic sg2 type 0
[   27.604136][  T375] systemd-udevd[375]: link_config: autonegotiation is unset or enabled, the speed and duplex are not writable.
done.
[ ok ] Setting hostname to 'debian'...done.
[ ok ] Activating swap:.
[   32.583961][  T588] EXT4-fs (sda1): re-mounted. Opts: errors=remount-ro
[info] Will now check all file systems.
fsck from util-linux 2.33.1
Checking all file systems.
LABEL=rootfs is mounted
[ ok ] Done checking file systems. A log is being saved in /var/log/fsck/checkfs if that location is writable..
[ ok ] Cleaning up temporary files...[....] Cleaning /tmp...done.
[ ok .
[ ok ] Will now mount local filesystems:.
[ ok ] Will now activate swapfile swap:done.
[ ok ] Checking minimum space in /tmp...done.
[ ok ] Cleaning up temporary files....
[ ok ] Starting Setting kernel variables: sysctl.
[ ok ] Initializing random number generator...done.
[....] Configuring network interfaces...Internet Systems Consortium DHCP Client 4.4.1
Copyright 2004-2018 Internet Systems Consortium.
All rights reserved.
For info, please visit https://www.isc.org/software/dhcp/

Listening on LPF/eth0/52:3b:20:9c:11:51
Sending on   LPF/eth0/52:3b:20:9c:11:51
Sending on   Socket/fallback
DHCPREQUEST for 192.168.0.217 on eth0 to 255.255.255.255 port 67
[   35.056851][ T1112] mv643xx_eth: Set the PHY back to auto-negotiation mode
[   38.784873][    C0] mv643xx_eth_port mv643xx_eth_port.0 eth0: link up, 1000 Mb/s, full duplex, flow control disabled
DHCPREQUEST for 192.168.0.217 on eth0 to 255.255.255.255 port 67
DHCPACK of 192.168.0.217 from 192.168.0.1
bound to 192.168.0.217 -- renewal in 38831 seconds.
[   59.792094][ T1142] NET: Registered protocol family 10
[   59.798793][ T1142] Segment Routing with IPv6
done.
[ ok ] Starting RPC port mapper daemon: rpcbind.
[ ok ] Starting NFS common utilities: statd idmapd.
[ ok ] Cleaning up temporary files....
INIT: Entering runlevel: 2
[info] Using makefile-style concurrent boot in runlevel 2.
[....] Starting busybox' syslogd implementation : syslogdStarting /sbin/syslogd...
1351 (syslogd)
. ok 
[....] Starting busybox' klogd implementation : klogdStarting /sbin/klogd...
1378 (klogd)
. ok 
[ ok ] Starting system message bus: dbus.
[ ok ] Starting Avahi mDNS/DNS-SD Daemon: avahi-daemon.
[ ok ] Starting NFS common utilities: statd idmapd.
[warn] Not starting NFS kernel daemon: no exports. ... (warning).
[ ok ] Starting NTP server: ntpd.
[ ok ] Starting OpenBSD Secure Shell server: sshd.
[ ok ] Running local boot scripts (/etc/rc.local).

Debian GNU/Linux 10 debian ttyS0

debian login: 

Re: Bricked Synology DS213 (Kirkwood) so close
October 01, 2020 11:25PM
itangoii,

OK. Here is how to boot the DS213 box properly.

Continuing from this post:
https://forum.doozan.com/read.php?3,108294,108619#msg-108619

Now after kwboot, and u-boot is running, interrupt serial console and:
setenv dtb_file /boot/dts/kirkwood-ds212.dtb
boot

The SPI flash and the rest of the DS213 box hardware should be detected correctly.

Please post serial console log.

-bodhi
===========================
Forum Wiki
bodhi's corner
Re: Bricked Synology DS213 (Kirkwood) so close
October 02, 2020 11:31AM
bodhi Wrote:
-------------------------------------------------------
> itangoii,
>
> OK. Here is how to boot the DS213 box properly.
>
> Continuing from this post:
> https://forum.doozan.com/read.php?3,108294,108619#msg-108619
>
> Now after kwboot, and u-boot is running, interrupt
> serial console and:
>
> setenv dtb_file /boot/dts/kirkwood-ds212.dtb
> boot
>
>
> The SPI flash and the rest of the DS213 box
> hardware should be detected correctly.
>
> Please post serial console log.

Hmmm. Lost the ethernet port under those circumstances.

 90 % [......................................................................]
 92 % [......................................................................]
 94 % [......................................................................]
 95 % [......................................................................]
 97 % [......................................................................]
 99 % [....................................]
[Type Ctrl-\ + c to quit]


U-Boot 2017.07-tld-1 (Sep 05 2017 - 00:42:03 -0700)
ZyXEL NSA325 2-Bay Power Media Server

SoC:   Kirkwood 88F6282_A1
DRAM:  512 MiB
WARNING: Caches not enabled
NAND:  0 MiB
*** Warning - readenv() failed, using default environment

In:    serial
Out:   serial
Err:   serial
Net:   egiga0
MV88E1318 PHY initialized on egiga0
Hit any key to stop autoboot:  0 
NSA325> setenv dtb_file /boot/dts/kirkwood-ds212.dtb
NSA325> boot
starting USB...
USB0:   USB EHCI 1.00
scanning bus 0 for devices... 4 USB Device(s) found
       scanning usb for storage devices... 
Use USB retry period from the environment: 15 second(s)

Use USB retry period from the environment: 15 second(s)
Device NOT ready
   Request Sense returned 02 3A 00

Use USB retry period from the environment: 15 second(s)
Device NOT ready
   Request Sense returned 02 3A 00
1 Storage Device(s) found

Reset IDE: ide_preinit failed

Partition Map for USB device 0  --   Partition Type: DOS

Part	Start Sector	Num Sectors	UUID		Type
  1	2048      	60602368  	ac0e13c9-01	83

## 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 ...
** File not found /boot/uEnv.txt **

no IDE devices available
running scan_disk ...
Scan device usb
device usb 0:1
1 bytes read in 692 ms (0 Bytes/s)
Found bootable drive on usb 0
loading uImage ...
4963680 bytes read in 976 ms (4.8 MiB/s)
loading uInitrd ...
EHCI timed out on TD - token=0xd8d80
9713936 bytes read in 6530 ms (1.4 MiB/s)
loading DTB /boot/dts/kirkwood-ds212.dtb ...
22000 bytes read in 3199 ms (5.9 KiB/s)
## Booting kernel from Legacy Image at 00800000 ...
   Image Name:   Linux-5.2.9-kirkwood-tld-1
   Created:      2019-08-25   2:22:31 UTC
   Image Type:   ARM Linux Kernel Image (uncompressed)
   Data Size:    4963616 Bytes = 4.7 MiB
   Load Address: 00008000
   Entry Point:  00008000
   Verifying Checksum ... OK
## Loading init Ramdisk from Legacy Image at 01100000 ...
   Image Name:   initramfs-5.2.9-kirkwood-tld-1
   Created:      2019-08-25   2:22:50 UTC
   Image Type:   ARM Linux RAMDisk Image (gzip compressed)
   Data Size:    9713872 Bytes = 9.3 MiB
   Load Address: 00000000
   Entry Point:  00000000
   Verifying Checksum ... OK
## Flattened Device Tree blob at 01c00000
   Booting using the fdt blob at 0x1c00000
   Loading Kernel Image ... OK
   Loading Ramdisk to 1f1ca000, end 1fb0d8d0 ... OK
   Loading Device Tree to 1f1c1000, end 1f1c95ef ... OK

Starting kernel ...

Uncompressing Linux... done, booting the kernel.
[    0.000000][    T0] Booting Linux on physical CPU 0x0
[    0.000000][    T0] Linux version 5.2.9-kirkwood-tld-1 (root@tldDebian) (gcc version 6.3.0 20170516 (Debian 6.3.0-18+deb9u1)) #1 PREEMPT Sat Aug 17 15:00:56 PDT 2019
[    0.000000][    T0] CPU: Feroceon 88FR131 [56251311] revision 1 (ARMv5TE), cr=0005397f
[    0.000000][    T0] CPU: VIVT data cache, VIVT instruction cache
[    0.000000][    T0] OF: fdt: Machine model: Synology DS212, DS212p v10, v20, DS213air v10, DS213 v10
[    0.000000][    T0] Memory policy: Data cache writeback
[    0.000000][    T0] Built 1 zonelists, mobility grouping on.  Total pages: 130048
[    0.000000][    T0] Kernel command line: console=ttyS0,115200 root=LABEL=rootfs rootdelay=10 mtdparts=orion_nand:0x100000(uboot),0x80000(stock_uboot_env),0x80000(key_store),0x80000(info),0xA00000(etc),0xA00000(kernel_1),0x2FC0000(rootfs1),0xA00000(kernel_2),0x2FC0000(rootfs2)
[    0.000000][    T0] Dentry cache hash table entries: 65536 (order: 6, 262144 bytes)
[    0.000000][    T0] Inode-cache hash table entries: 32768 (order: 5, 131072 bytes)
[    0.000000][    T0] Memory: 494644K/524288K available (9216K kernel code, 868K rwdata, 3400K rodata, 1024K init, 301K bss, 29644K reserved, 0K cma-reserved)
[    0.000000][    T0] random: get_random_u32 called from cache_alloc_refill+0x38c/0x928 with crng_init=0
[    0.000000][    T0] rcu: Preemptible hierarchical RCU implementation.
[    0.000000][    T0] 	Tasks RCU enabled.
[    0.000000][    T0] rcu: RCU calculated value of scheduler-enlistment delay is 10 jiffies.
[    0.000000][    T0] NR_IRQS: 16, nr_irqs: 16, preallocated irqs: 16
[    0.000000][    T0] clocksource: orion_clocksource: mask: 0xffffffff max_cycles: 0xffffffff, max_idle_ns: 9556302233 ns
[    0.000007][    T0] sched_clock: 32 bits at 200MHz, resolution 5ns, wraps every 10737418237ns
[    0.000039][    T0] Switching to timer-based delay loop, resolution 5ns
[    0.000611][    T0] Console: colour dummy device 80x30
[    0.000654][    T0] Calibrating delay loop (skipped), value calculated using timer frequency.. 400.00 BogoMIPS (lpj=2000000)
[    0.000674][    T0] pid_max: default: 32768 minimum: 301
[    0.000952][    T0] LSM: Security Framework initializing
[    0.001094][    T0] Mount-cache hash table entries: 1024 (order: 0, 4096 bytes)
[    0.001117][    T0] Mountpoint-cache hash table entries: 1024 (order: 0, 4096 bytes)
[    0.001779][    T0] *** VALIDATE proc ***
[    0.001999][    T0] *** VALIDATE cgroup1 ***
[    0.002020][    T0] *** VALIDATE cgroup2 ***
[    0.002105][    T0] CPU: Testing write buffer coherency: ok
[    0.003587][    T1] Setting up static identity map for 0x100000 - 0x100058
[    0.003845][    T1] mvebu-soc-id: MVEBU SoC ID=0x6282, Rev=0x1
[    0.004090][    T1] rcu: Hierarchical SRCU implementation.
[    0.006463][    T1] devtmpfs: initialized
[    0.013707][    T1] clocksource: jiffies: mask: 0xffffffff max_cycles: 0xffffffff, max_idle_ns: 19112604462750000 ns
[    0.013734][    T1] futex hash table entries: 256 (order: -1, 3072 bytes)
[    0.013952][    T1] xor: measuring software checksum speed
[    0.110096][    T1]    arm4regs  :  1806.800 MB/sec
[    0.210065][    T1]    8regs     :  1084.800 MB/sec
[    0.310060][    T1]    32regs    :  1577.200 MB/sec
[    0.310076][    T1] xor: using function: arm4regs (1806.800 MB/sec)
[    0.310093][    T1] prandom: seed boundary self test passed
[    0.312615][    T1] prandom: 100 self tests passed
[    0.312624][    T1] pinctrl core: initialized pinctrl subsystem
[    0.313815][    T1] NET: Registered protocol family 16
[    0.314224][    T1] DMA: preallocated 256 KiB pool for atomic coherent allocations
[    0.314844][    T1] audit: initializing netlink subsys (disabled)
[    0.315903][   T14] audit: type=2000 audit(0.310:1): state=initialized audit_enabled=0 res=1
[    0.316007][    T1] cpuidle: using governor ladder
[    0.316074][    T1] cpuidle: using governor menu
[    0.316507][    T1] Feroceon L2: Enabling L2
[    0.316549][    T1] Feroceon L2: Cache support initialised.
[    0.320811][    T1] No ATAGs?
[    2.560044][    C0] random: fast init done
[    3.878630][   T71] alg: No test for lzo-rle (lzo-rle-generic)
[    3.878897][   T73] alg: No test for lzo-rle (lzo-rle-scomp)
[    4.050673][    T1] raid6: int32x8  gen()   208 MB/s
[    4.220365][    T1] raid6: int32x8  xor()   142 MB/s
[    4.390135][    T1] raid6: int32x4  gen()   208 MB/s
[    4.560131][    T1] raid6: int32x4  xor()   137 MB/s
[    4.730086][    T1] raid6: int32x2  gen()   209 MB/s
[    4.900203][    T1] raid6: int32x2  xor()   151 MB/s
[    5.070275][    T1] raid6: int32x1  gen()   156 MB/s
[    5.240052][    T1] raid6: int32x1  xor()   108 MB/s
[    5.240059][    T1] raid6: using algorithm int32x2 gen() 209 MB/s
[    5.240064][    T1] raid6: .... xor() 151 MB/s, rmw enabled
[    5.240070][    T1] raid6: using intx1 recovery algorithm
[    5.240303][    T1] vgaarb: loaded
[    5.240688][    T1] SCSI subsystem initialized
[    5.241077][    T1] usbcore: registered new interface driver usbfs
[    5.241121][    T1] usbcore: registered new interface driver hub
[    5.241183][    T1] usbcore: registered new device driver usb
[    5.241308][    T1] pps_core: LinuxPPS API ver. 1 registered
[    5.241316][    T1] pps_core: Software ver. 5.3.6 - Copyright 2005-2007 Rodolfo Giometti <giometti@linux.it>
[    5.241334][    T1] PTP clock support registered
[    5.242317][    T1] clocksource: Switched to clocksource orion_clocksource
[    5.870562][    T1] VFS: Disk quotas dquot_6.6.0
[    5.870641][    T1] VFS: Dquot-cache hash table entries: 1024 (order 0, 4096 bytes)
[    5.877510][    T1] NET: Registered protocol family 2
[    5.878149][    T1] tcp_listen_portaddr_hash hash table entries: 512 (order: 0, 4096 bytes)
[    5.878178][    T1] TCP established hash table entries: 4096 (order: 2, 16384 bytes)
[    5.878234][    T1] TCP bind hash table entries: 4096 (order: 2, 16384 bytes)
[    5.878288][    T1] TCP: Hash tables configured (established 4096 bind 4096)
[    5.878361][    T1] UDP hash table entries: 256 (order: 0, 4096 bytes)
[    5.878385][    T1] UDP-Lite hash table entries: 256 (order: 0, 4096 bytes)
[    5.878558][    T1] NET: Registered protocol family 1
[    5.879063][    T1] RPC: Registered named UNIX socket transport module.
[    5.879073][    T1] RPC: Registered udp transport module.
[    5.879078][    T1] RPC: Registered tcp transport module.
[    5.879084][    T1] RPC: Registered tcp NFSv4.1 backchannel transport module.
[    5.879094][    T1] PCI: CLS 0 bytes, default 32
[    5.879279][    T1] Trying to unpack rootfs image as initramfs...
[    6.431393][    T1] Freeing initrd memory: 9488K
[    6.431534][    T1] NetWinder Floating Point Emulator V0.97 (double precision)
[    6.432599][    T1] Initialise system trusted keyrings
[    6.432649][    T1] Key type blacklist registered
[    6.432835][    T1] workingset: timestamp_bits=30 max_order=17 bucket_order=0
[    6.432917][    T1] zbud: loaded
[    6.433726][    T1] NFS: Registering the id_resolver key type
[    6.433761][    T1] Key type id_resolver registered
[    6.433767][    T1] Key type id_legacy registered
[    6.433781][    T1] nfs4filelayout_init: NFSv4 File Layout Driver Registering...
[    6.433795][    T1] Installing knfsd (copyright (C) 1996 okir@monad.swb.de).
[    6.434012][    T1] jffs2: version 2.2. (NAND) (SUMMARY)  © 2001-2006 Red Hat, Inc.
[    6.434180][    T1] fuse: init (API version 7.31)
[    6.434479][    T1] orangefs_debugfs_init: called with debug mask: :none: :0:
[    6.434613][    T1] orangefs_init: module version upstream loaded
[    6.434621][    T1] SGI XFS with ACLs, security attributes, realtime, scrub, no debug enabled
[    6.447187][    T1] async_tx: api initialized (async)
[    6.447207][    T1] Key type asymmetric registered
[    6.447214][    T1] Asymmetric key parser 'x509' registered
[    6.447277][    T1] Block layer SCSI generic (bsg) driver version 0.4 loaded (major 246)
[    6.448319][    T1] kirkwood-pinctrl f1010000.pin-controller: registered pinctrl driver
[    6.449762][    T1] mvebu-pcie mbus@f1000000:pcie@82000000: PCI host bridge to bus 0000:00
[    6.449779][    T1] pci_bus 0000:00: root bus resource [bus 00-ff]
[    6.449790][    T1] pci_bus 0000:00: root bus resource [mem 0xe0000000-0xefffffff]
[    6.449798][    T1] pci_bus 0000:00: root bus resource [io  0x1000-0xeffff]
[    6.449933][    T1] pci 0000:00:01.0: [11ab:6282] type 01 class 0x060400
[    6.449965][    T1] pci 0000:00:01.0: reg 0x38: [mem 0x00000000-0x000007ff pref]
[    6.450218][    T1] pci 0000:00:02.0: [11ab:6282] type 01 class 0x060400
[    6.450243][    T1] pci 0000:00:02.0: reg 0x38: [mem 0x00000000-0x000007ff pref]
[    6.451746][    T1] PCI: bus0: Fast back to back transfers disabled
[    6.451764][    T1] pci 0000:00:01.0: bridge configuration invalid ([bus 00-00]), reconfiguring
[    6.451782][    T1] pci 0000:00:02.0: bridge configuration invalid ([bus 00-00]), reconfiguring
[    6.453424][    T1] PCI: bus1: Fast back to back transfers enabled
[    6.453443][    T1] pci_bus 0000:01: busn_res: [bus 01-ff] end is updated to 01
[    6.454973][    T1] PCI: bus2: Fast back to back transfers enabled
[    6.454989][    T1] pci_bus 0000:02: busn_res: [bus 02-ff] end is updated to 02
[    6.455126][    T1] pci 0000:00:01.0: BAR 6: assigned [mem 0xe0000000-0xe00007ff pref]
[    6.455139][    T1] pci 0000:00:02.0: BAR 6: assigned [mem 0xe0100000-0xe01007ff pref]
[    6.455149][    T1] pci 0000:00:01.0: PCI bridge to [bus 01]
[    6.455166][    T1] pci 0000:00:02.0: PCI bridge to [bus 02]
[    6.455659][    T1] mv_xor f1060800.xor: Marvell shared XOR driver
[    6.512849][    T1] mv_xor f1060800.xor: Marvell XOR (Registers Mode): ( xor cpy intr )
[    6.514160][    T1] mv_xor f1060900.xor: Marvell shared XOR driver
[    6.572863][    T1] mv_xor f1060900.xor: Marvell XOR (Registers Mode): ( xor cpy intr )
[    6.574463][    T1] Serial: 8250/16550 driver, 2 ports, IRQ sharing disabled
[    6.575449][    T1] printk: console [ttyS0] disabled
[    6.575511][    T1] f1012000.serial: ttyS0 at MMIO 0xf1012000 (irq = 27, base_baud = 12500000) is a 16550A
[    7.479481][    T1] printk: console [ttyS0] enabled
[    7.484878][    T1] f1012100.serial: ttyS1 at MMIO 0xf1012100 (irq = 28, base_baud = 12500000) is a 16550A
[    7.499957][    T1] loop: module loaded
[    7.504425][    T1] sata_mv f1080000.sata: slots 32 ports 2
[    7.511973][    T1] scsi host0: sata_mv
[    7.516331][    T1] scsi host1: sata_mv
[    7.520400][    T1] ata1: SATA max UDMA/133 irq 34
[    7.525258][    T1] ata2: SATA max UDMA/133 irq 34
[    7.531391][    T1] m25p80 spi0.0: found n25q064, expected m25p80
[    7.537713][    T1] m25p80 spi0.0: n25q064 (8192 Kbytes)
[    7.543109][    T1] 6 fixed-partitions partitions found on MTD device spi0.0
[    7.550185][    T1] Creating 6 MTD partitions on "spi0.0":
[    7.555709][    T1] 0x000000000000-0x000000080000 : "RedBoot"
[    7.562505][    T1] 0x000000080000-0x000000280000 : "zImage"
[    7.569074][    T1] 0x000000280000-0x0000003c0000 : "rd.gz"
[    7.575586][    T1] 0x0000003c0000-0x0000003d0000 : "vendor"
[    7.582141][    T1] 0x0000003d0000-0x0000003f0000 : "RedBoot config"
[    7.589439][    T1] 0x0000003f0000-0x000000400000 : "FIS directory"
[    7.597466][    T1] libphy: Fixed MDIO Bus: probed
[    7.602884][    T1] libphy: orion_mdio_bus: probed
[    7.607885][    T1] mdio_bus f1072004.mdio-bus-mii: MDIO device at address 8 is missing.
[    7.616193][    T1] mdio_bus f1072004.mdio-bus-mii: MDIO device at address 9 is missing.
[    7.624463][    T1] mv643xx_eth: MV-643xx 10/100/1000 ethernet driver version 1.4
[    7.632302][    T1] mv643xx_eth_port mv643xx_eth_port.0: DMA mask not set
[    7.639277][    T1] ehci_hcd: USB 2.0 'Enhanced' Host Controller (EHCI) Driver
[    7.646611][    T1] ehci-pci: EHCI PCI platform driver
[    7.651817][    T1] ehci-orion: EHCI orion driver
[    7.656719][    T1] orion-ehci f1050000.ehci: EHCI Host Controller
[    7.662992][    T1] orion-ehci f1050000.ehci: new USB bus registered, assigned bus number 1
[    7.671501][    T1] orion-ehci f1050000.ehci: irq 32, io mem 0xf1050000
[    7.702342][    T1] orion-ehci f1050000.ehci: USB 2.0 started, EHCI 1.00
[    7.709295][    T1] usb usb1: New USB device found, idVendor=1d6b, idProduct=0002, bcdDevice= 5.02
[    7.718312][    T1] usb usb1: New USB device strings: Mfr=3, Product=2, SerialNumber=1
[    7.726274][    T1] usb usb1: Product: EHCI Host Controller
[    7.731868][    T1] usb usb1: Manufacturer: Linux 5.2.9-kirkwood-tld-1 ehci_hcd
[    7.739222][    T1] usb usb1: SerialNumber: f1050000.ehci
[    7.745119][    T1] hub 1-0:1.0: USB hub found
[    7.749613][    T1] hub 1-0:1.0: 1 port detected
[    7.754820][    T1] usbcore: registered new interface driver usb-storage
[    7.761844][    T1] mousedev: PS/2 mouse device common for all mice
[    7.768408][    T1] i2c /dev entries driver
[    7.773824][    T1] rtc-s35390a 0-0030: error resetting chip
[    7.779917][    T1] rtc-s35390a: probe of 0-0030 failed with error -5
[    7.786987][    T1] device-mapper: uevent: version 1.0.3
[    7.792603][    T1] device-mapper: ioctl: 4.40.0-ioctl (2019-01-18) initialised: dm-devel@redhat.com
[    7.802082][    T1] device-mapper: multipath round-robin: version 1.2.0 loaded
[    7.809405][    T1] device-mapper: multipath queue-length: version 0.2.0 loaded
[    7.816787][    T1] device-mapper: multipath service-time: version 0.3.0 loaded
[    7.824215][    T1] device-mapper: dm-log-userspace: version 1.3.0 loaded
[    7.831054][    T1] device-mapper: raid: Loading target version 1.14.0
[    7.838100][    T1] kirkwood-pinctrl f1010000.pin-controller: pin PIN21 already requested by f1080000.sata; cannot claim for gpio-leds-hdd-21-2
[    7.851078][    T1] kirkwood-pinctrl f1010000.pin-controller: pin-21 (gpio-leds-hdd-21-2) status -22
[    7.860288][  T112] ata1: SATA link down (SStatus 0 SControl F300)
[    7.866609][    T1] kirkwood-pinctrl f1010000.pin-controller: could not request pin 21 (PIN21) from group mpp21  on device f1010000.pin-controller
[    7.879861][    T1] leds-gpio gpio-leds-hdd-21-2: Error applying setting, reverse things back
[    7.888454][    T1] leds-gpio: probe of gpio-leds-hdd-21-2 failed with error -22
[    7.896089][    T1] hidraw: raw HID events driver (C) Jiri Kosina
[    7.902504][    T1] drop_monitor: Initializing network drop monitor service
[    7.909709][    T1] NET: Registered protocol family 17
[    7.915097][    T1] Key type dns_resolver registered
[    7.920682][    T1] registered taskstats version 1
[    7.925524][    T1] Loading compiled-in X.509 certificates
[    7.931099][    T1] zswap: loaded using pool lzo/zbud
[    8.003002][    T1] Key type big_key registered
[    8.038423][    T1] Key type encrypted registered
[    8.045038][    T1] hctosys: unable to open rtc device (rtc0)
[    8.122341][   T15] usb 1-1: new high-speed USB device number 2 using orion-ehci
[    8.225961][  T114] ata2: SATA link down (SStatus 0 SControl F300)
[    8.245412][    T1] Freeing unused kernel memory: 1024K
[    8.251049][    T1] Checked W+X mappings: passed, no W+X pages found
[    8.257454][    T1] Run /init as init process
Loading, please wait...
[    8.324283][   T15] usb 1-1: New USB device found, idVendor=05e3, idProduct=0608, bcdDevice=85.32
[    8.337161][   T15] usb 1-1: New USB device strings: Mfr=0, Product=1, SerialNumber=0
[    8.349372][   T15] usb 1-1: Product: USB2.0 Hub
[    8.359178][   T15] hub 1-1:1.0: USB hub found
[    8.368060][   T15] hub 1-1:1.0: 4 ports detected
Starting version 241
[    8.702411][   T15] usb 1-1.3: new high-speed USB device number 3 using orion-ehci
[    8.864784][   T15] usb 1-1.3: New USB device found, idVendor=154b, idProduct=00ed, bcdDevice= 1.10
[    8.881480][   T15] usb 1-1.3: New USB device strings: Mfr=1, Product=2, SerialNumber=3
[    8.897856][   T15] usb 1-1.3: Product: USB 3.0 FD
[    8.912446][   T15] usb 1-1.3: Manufacturer: PNY
[    8.917092][   T15] usb 1-1.3: SerialNumber: 070001690020C088
[    8.930457][   T15] usb-storage 1-1.3:1.0: USB Mass Storage device detected
[    8.948392][   T15] scsi host2: usb-storage 1-1.3:1.0
[    9.052407][   T15] usb 1-1.4: new high-speed USB device number 4 using orion-ehci
[    9.214531][   T15] usb 1-1.4: New USB device found, idVendor=05e3, idProduct=0726, bcdDevice=99.10
[    9.231593][   T15] usb 1-1.4: New USB device strings: Mfr=0, Product=1, SerialNumber=2
[    9.248940][   T15] usb 1-1.4: Product: USB Storage
[    9.254021][   T15] usb 1-1.4: SerialNumber: 000000009910
[    9.261019][   T15] usb-storage 1-1.4:1.0: USB Mass Storage device detected
[    9.268423][   T15] scsi host3: usb-storage 1-1.4:1.0
[    9.285100][  T170] usbcore: registered new interface driver uas
Begin: Loading essential drivers ... done.
[   10.003593][    T7] scsi 2:0:0:0: Direct-Access     PNY      USB 3.0 FD       PMAP PQ: 0 ANSI: 6
[   10.016808][   T23] sd 2:0:0:0: [sda] 60604416 512-byte logical blocks: (31.0 GB/28.9 GiB)
[   10.030928][   T23] sd 2:0:0:0: [sda] Write Protect is off
[   10.037033][   T23] sd 2:0:0:0: [sda] Write cache: disabled, read cache: enabled, doesn't support DPO or FUA
[   10.113767][   T23]  sda: sda1
[   10.124929][   T23] sd 2:0:0:0: [sda] Attached SCSI removable disk
[   10.343462][   T23] scsi 3:0:0:0: Direct-Access     Generic  STORAGE DEVICE   9910 PQ: 0 ANSI: 0
[   10.352937][   T23] scsi 3:0:0:1: Direct-Access     Generic  STORAGE DEVICE   9910 PQ: 0 ANSI: 0
[   10.367685][    T7] sd 3:0:0:0: [sdb] Attached SCSI removable disk
[   10.379171][   T23] sd 3:0:0:1: [sdc] Attached SCSI removable disk
Begin: Running /scripts/init-premount ... done.
Begin: Mounting root file system ... Begin: Running /scripts/local-top ... done.
Begin: Running /scripts/local-premount ... done.
Begin: Will now check root file system ... fsck from util-linux 2.33.1
[/sbin/fsck.ext3 (1) -- /dev/sda1] fsck.ext3 -a -C0 /dev/sda1 
rootfs: recovering journal
rootfs: clean, 15084/1896832 files, 349176/7575296 blocks
done.
[   29.755308][  T195] EXT4-fs (sda1): mounting ext3 file system using the ext4 subsystem
[   29.822638][  T195] EXT4-fs (sda1): mounted filesystem with ordered data mode. Opts: (null)
done.
Begin: Running /scripts/local-bottom ... done.
Begin: Running /scripts/init-bottom ... done.
INIT: version 2.93 booting
[info] Using makefile-style concurrent boot in runlevel S.
[ ok ] Starting hotplug events dispatcher: systemd-udevd.
[ ok ] Synthesizing the initial hotplug events (subsystems)...done.
[....] Synthesizing the initial hotplug events (devices)...[   32.067165][    C0] random: crng init done
done.
[   32.217264][  T377] gpio-fan gpio-fan-100-15-35-1: GPIO fan initialized
[....] Waiting for /dev to be fully populated...[   32.512726][  T378] watchdog: f1020300.watchdog-timer: driver supplied timeout (4294967295) out of range
[   32.602570][  T378] watchdog: f1020300.watchdog-timer: falling back to default timeout (21)
[   32.726272][  T378] orion_wdt: Initial timeout 21 sec
[   32.733174][  T397] sd 2:0:0:0: Attached scsi generic sg0 type 0
[   32.789072][  T397] sd 3:0:0:0: Attached scsi generic sg1 type 0
[   32.826719][  T377] marvell-cesa f1030000.crypto: CESA device successfully registered
[   32.844638][  T397] sd 3:0:0:1: Attached scsi generic sg2 type 0
[   32.931568][  T377] systemd-udevd[377]: link_config: autonegotiation is unset or enabled, the speed and duplex are not writable.
done.
[ ok ] Setting hostname to 'debian'...done.
[ ok ] Activating swap:.
[   34.105811][  T590] EXT4-fs (sda1): re-mounted. Opts: errors=remount-ro
[info] Will now check all file systems.
fsck from util-linux 2.33.1
Checking all file systems.
LABEL=rootfs is mounted
[ ok ] Done checking file systems. A log is being saved in /var/log/fsck/checkfs if that location is writable..
[ ok ] Cleaning up temporary files...[....] Cleaning /tmp...done.
[ ok .
[ ok ] Will now mount local filesystems:.
[ ok ] Will now activate swapfile swap:done.
[ ok ] Checking minimum space in /tmp...done.
[ ok ] Cleaning up temporary files....
[ ok ] Starting Setting kernel variables: sysctl.
[ ok ] Initializing random number generator...done.
[....] Configuring network interfaces...Internet Systems Consortium DHCP Client 4.4.1
Copyright 2004-2018 Internet Systems Consortium.
All rights reserved.
For info, please visit https://www.isc.org/software/dhcp/

Cannot find device "eth0"
Failed to get interface index: No such device

If you think you have received this message due to a bug rather
than a configuration issue please read the section on submitting
bugs on either our web page at www.isc.org or in the README file
before submitting a bug.  These pages explain the proper
process and the information we find helpful for debugging.

exiting.
ifup: failed to bring up eth0
failed.
[....] Starting RPC port mapper daemon: rpcbind[   37.624793][ T1172] NET: Registered protocol family 10
[   37.630855][ T1172] Segment Routing with IPv6
. ok 
[ ok ] Starting NFS common utilities: statd idmapd.
[ ok ] Cleaning up temporary files....
INIT: Entering runlevel: 2
[info] Using makefile-style concurrent boot in runlevel 2.
[....] Starting busybox' syslogd implementation : syslogdStarting /sbin/syslogd...
1312 (syslogd)
. ok 
[....] Starting busybox' klogd implementation : klogdStarting /sbin/klogd...
1339 (klogd)
. ok 
[ ok ] Starting system message bus: dbus.
[ ok ] Starting Avahi mDNS/DNS-SD Daemon: avahi-daemon.
[ ok ] Starting NFS common utilities: statd idmapd.
[warn] Not starting NFS kernel daemon: no exports. ... (warning).
[ ok ] Starting NTP server: ntpd.
[ ok ] Starting OpenBSD Secure Shell server: sshd.
[ ok ] Running local boot scripts (/etc/rc.local).

Debian GNU/Linux 10 debian ttyS0

debian login:    
Re: Bricked Synology DS213 (Kirkwood) so close
October 02, 2020 01:15PM
Digging further I find that my ubuntu box picks up enp0s3 for the net interface, but the u-boot is picking up the traditional eth0. From my research this may be an issue with the boot USB using an older version of the OS?

Edit: This may explain it.

https://superuser.com/questions/1345623/network-adapter-missing-in-ubuntu-18-04-after-migration-from-virtualbox-to-hyper



Edited 1 time(s). Last edit at 10/02/2020 02:35PM by itangoii.
Re: Bricked Synology DS213 (Kirkwood) so close
October 02, 2020 02:36PM
itangoii,

> Digging further I find that my ubuntu box picks up
> enp0s3 for the net interface, but the u-boot is
> picking up the traditional eth0. From my research
> this may be an issue with the boot USB using an
> older version of the OS?

That's not the reason. You Ubuntu is most likely running systemd, with the new naming scheme so the port is enp0sx. On sysvinit, which is this rootfs runs, the Ethernet device uses the legacy naming so it is eth0, instead of enp0s0.

This lost of network is most likely due to the mix of NSA325 u-boot and DS213 kernel.

In previous run, you have the NSA325 kernel running, so it was consistent. Now what u-boot passed to the kernel probably caused it to be confused a bit.

Try:

At serial console, log into Debian as root, see if the network link can be brought up this way.

ifdown eth0
ifup eth0

===

Edited: Typos.

-bodhi
===========================
Forum Wiki
bodhi's corner



Edited 1 time(s). Last edit at 10/02/2020 06:11PM by bodhi.
Re: Bricked Synology DS213 (Kirkwood) so close
October 02, 2020 02:59PM
bodhi Wrote:
-
> Try:
>
> At serial console, log into Debian as root, see if
> the network link can be brought up this way.
>
>
> ifdown eth0
> ifup eth0
>

results
root@debian:~# ifdown eth0
ifdown: interface eth0 not configured
root@debian:~# ifup eth0
Internet Systems Consortium DHCP Client 4.4.1
Copyright 2004-2018 Internet Systems Consortium.
All rights reserved.
For info, please visit https://www.isc.org/software/dhcp/

Cannot find device "eth0"
Failed to get interface index: No such device

If you think you have received this message due to a bug rather
than a configuration issue please read the section on submitting
bugs on either our web page at www.isc.org or in the README file
before submitting a bug.  These pages explain the proper
process and the information we find helpful for debugging.

exiting.
ifup: failed to bring up eth0
root@debian:~# ifup enp0s3
ifup: unknown interface enp0s3
root@debian:~# 
Re: Bricked Synology DS213 (Kirkwood) so close
October 02, 2020 03:37PM
itangoii,

To filter out the network driver activity and compare to the previous boot with NSA325 kernel.

Please post both output (just to summarize the situation so we don't need to scroll back and forth):
dmesg | grep mv643xx_eth


On the bright side, looks like everything else is OK. Most importantly, the SPI flash was intialized correctly:
[    7.531391][    T1] m25p80 spi0.0: found n25q064, expected m25p80
[    7.537713][    T1] m25p80 spi0.0: n25q064 (8192 Kbytes)
[    7.543109][    T1] 6 fixed-partitions partitions found on MTD device spi0.0
[    7.550185][    T1] Creating 6 MTD partitions on "spi0.0":
[    7.555709][    T1] 0x000000000000-0x000000080000 : "RedBoot"
[    7.562505][    T1] 0x000000080000-0x000000280000 : "zImage"
[    7.569074][    T1] 0x000000280000-0x0000003c0000 : "rd.gz"
[    7.575586][    T1] 0x0000003c0000-0x0000003d0000 : "vendor"
[    7.582141][    T1] 0x0000003d0000-0x0000003f0000 : "RedBoot config"
[    7.589439][    T1] 0x0000003f0000-0x000000400000 : "FIS directory"

This is another path to recovery. With a little more adjustment in bootargs, we can flash the good mtds backup to this broken box from inside Debian now.

-bodhi
===========================
Forum Wiki
bodhi's corner
Re: Bricked Synology DS213 (Kirkwood) so close
October 03, 2020 02:42PM
bodhi Wrote:
-------------------------------------------------------
> itangoii,
>
> To filter out the network driver activity and
> compare to the previous boot with NSA325 kernel.
>
> Please post both output (just to summarize the
> situation so we don't need to scroll back and
> forth):
>
> dmesg | grep mv643xx_eth
>
>

Straight boot.

root@debian:~# dmesg | grep mv643xx_eth
[    7.738730] mv643xx_eth: MV-643xx 10/100/1000 ethernet driver version 1.4
[    7.746701] mv643xx_eth_port mv643xx_eth_port.0: DMA mask not set
[    7.754307] mv643xx_eth: Set the PHY to fix link down
[    7.754758] mv643xx_eth_port mv643xx_eth_port.0 eth0: port 0 with MAC address 52:3b:20:9c:11:51
[   28.787613] mv643xx_eth: Set the PHY back to auto-negotiation mode
[   32.433386] mv643xx_eth_port mv643xx_eth_port.0 eth0: link up, 1000 Mb/s, full duplex, flow control disabled
root@debian:~#

Boot after directing to the DS213.dtb

root@debian:~# dmesg | grep mv643xx_eth
[    7.624509] mv643xx_eth: MV-643xx 10/100/1000 ethernet driver version 1.4
[    7.632377] mv643xx_eth_port mv643xx_eth_port.0: DMA mask not set
root@debian:~# 

Re: Bricked Synology DS213 (Kirkwood) so close
October 03, 2020 04:16PM
itangoii,

Quote

[ 7.754307] mv643xx_eth: Set the PHY to fix link down

I see.

This was a patch that I added to the kernel to activate the network for the NSA325 box. This network chip 88E1318 on NSA325 has a quirk that we need to do that. So the DS213 and NSA325 have the same behavior (they have the same SoC 88F6282, and 88E1318 is internal to this SoC).

That explains why running as NSA325, the network is OK. But using the DS213 DTB, the network failed to be activated.

If we want to run Debian on this box, then I need to add DS213 to that the kernel patch.

===
edited: clarity

-bodhi
===========================
Forum Wiki
bodhi's corner



Edited 1 time(s). Last edit at 10/04/2020 04:06PM by bodhi.
Re: Bricked Synology DS213 (Kirkwood) so close
October 08, 2020 04:35PM
Should I be able to acquire a working DS213 is there a procedure somewhere to extracting the necessary files from it?

Is there anything else I can do with this one at this time?

Thanks
Re: Bricked Synology DS213 (Kirkwood) so close
October 08, 2020 05:57PM
itangoii,

> Should I be able to acquire a working DS213 is
> there a procedure somewhere to extracting the
> necessary files from it?

Yes. See example in the HP T5325 installation (this box has SPI flash similar to the DS213):

Quote

2. Save your current u-boot envs and backup your current stock mtds for future restoration, should you decide to go back to stock

cd /tmp/sdb1/boot
fw_printenv > current_envs.text
dd if=/dev/mtd0 of=t5325.mtd0 bs=64k conv=sync
dd if=/dev/mtd3 of=t5325.mtd3 bs=512k conv=sync

Quote

4. Flash u-boot to mtd3

cd /tmp/sdb1/boot
flash_unlock /dev/mtd3
flashcp -v uboot.2017.07-tld-1.t5325.mtd0.kwb /dev/mtd3

Now this DS213 box MTDs definition is quite different, so we need a set of dd and flashcp commands specific to the DS213. I will help with that when you are ready.

> Is there anything else I can do with this one at
> this time?

You got as far as you can at the moment. If you do want to see the network running in Debian, we'll need to either :

- After booted in to Debian, run a script (it is in the NSA325 stock FW). I do believe I saved it somewhere.
- I build a new kernel that has a minor patch that recognize the DS213 and bring the network up (similar to NSA325).

-bodhi
===========================
Forum Wiki
bodhi's corner
Re: Bricked Synology DS213 (Kirkwood) so close
October 08, 2020 06:23PM
bodhi Wrote:
-------------------------------------------------------
> itangoii,
>
> > Should I be able to acquire a working DS213 is
> > there a procedure somewhere to extracting the
> > necessary files from it?



> Now this DS213 box MTDs definition is quite
> different, so we need a set of dd and flashcp
> commands specific to the DS213. I will help with
> that when you are ready.
>


Well, I was able to get a DS213 two days faster than I thought, so I have a working one with no hard drives in it. It is recognized by the Synology software and receives a DHCP address and starts the setup process but I have not proceeded
Re: Bricked Synology DS213 (Kirkwood) so close
October 08, 2020 11:17PM
itangoii Wrote:
-------------------------------------------------------
> bodhi Wrote:
> -------------------------------------------------------
> > itangoii,
> >
> > > Should I be able to acquire a working DS213
> is
> > > there a procedure somewhere to extracting the
> > > necessary files from it?
>
>
>
> > Now this DS213 box MTDs definition is quite
> > different, so we need a set of dd and flashcp
> > commands specific to the DS213. I will help
> with
> > that when you are ready.
> >
>
>
> Well, I was able to get a DS213 two days faster
> than I thought, so I have a working one with no
> hard drives in it. It is recognized by the
> Synology software and receives a DHCP address and
> starts the setup process but I have not proceeded

Go ahead and do the usual stuff to setup stock. After that, log in stock OS through ssh or serial console, at command line,

dmesg
cat /proc/mtd
fw_printenv


The last command might fail if stock does not setup to expose the uboot envs. In that case, at serial console (if connected) do:

printenv

-bodhi
===========================
Forum Wiki
bodhi's corner
Re: Bricked Synology DS213 (Kirkwood) so close
October 09, 2020 04:10PM
You were right, the last command would not work from an ssh session so I had to crack the case and hook up the serial connection. The information you asked for is below. Part from the ssh session and printenv from serial termninal.


root@Diskstation1:~# dmesg
[    0.000000] Linux version 2.6.32.12 (root@build4) (gcc version 4.6.4 (Marvell GCC release 20150204-c4af733b 64K MAXPAGESIZE ALIGN CVE-2015-0235) ) #25426 Tue May 12 04:42:15 CST 2020
[    0.000000] CPU: Feroceon 88FR131 [56251311] revision 1 (ARMv5TE), cr=00053977
[    0.000000] CPU: VIVT data cache, VIVT instruction cache
[    0.000000] Machine: Synology 6282 board
[    0.000000] Using UBoot passing parameters structure
[    0.000000] Sys Clk = 200000000, Tclk = 166666667
[    0.000000] Synology Board ID: 27
[    0.000000] Memory policy: ECC disabled, Data cache writeback
[    0.000000] On node 0 totalpages: 131072
[    0.000000] free_area_init_node: node 0, pgdat c03f39bc, node_mem_map c1001000
[    0.000000]   Normal zone: 1024 pages used for memmap
[    0.000000]   Normal zone: 0 pages reserved
[    0.000000]   Normal zone: 130048 pages, LIFO batch:31
[    0.000000] Built 1 zonelists in Zone order, mobility grouping off.  Total pages: 130048
[    0.000000] Kernel command line: console=ttyS0,115200 ip=off initrd=0x00800040,8M root=/dev/md0 rw syno_hw_version=DS213v10 ihd_num=2 netif_num=1 flash_size=8
[    0.000000] Synology Hardware Version: DS213v10-j
[    0.000000] Internal HD num: 2
[    0.000000] Internal netif num: 1
[    0.000000] Flash Memory Size: 8 MB
[    0.000000] PID hash table entries: 2048 (order: 1, 8192 bytes)
[    0.000000] Dentry cache hash table entries: 65536 (order: 6, 262144 bytes)
[    0.000000] Inode-cache hash table entries: 32768 (order: 5, 131072 bytes)
[    0.000000] Memory: 512MB = 512MB total
[    0.000000] Memory: 502784KB available (3656K code, 519K data, 124K init, 0K highmem)
[    0.000000] Hierarchical RCU implementation.
[    0.000000] NR_IRQS:128
[    0.000000] Console: colour dummy device 80x30
[    0.000000] Calibrating delay loop... 1985.74 BogoMIPS (lpj=9928704)
[    0.250000] Mount-cache hash table entries: 512
[    0.250000] CPU: Testing write buffer coherency: ok
[    0.250000] devtmpfs: initialized
[    0.250000] xor: measuring software checksum speed
[    0.300000]    arm4regs  :  1810.800 MB/sec
[    0.350000]    8regs     :  1086.400 MB/sec
[    0.400000]    32regs    :  1402.400 MB/sec
[    0.400000] xor: using function: arm4regs (1810.800 MB/sec)
[    0.400000] NET: Registered protocol family 16
[    0.400000] Feroceon L2: Enabling L2
[    0.400000] Feroceon L2: Cache support initialised, in WT override mode.

[    0.420000] CPU Interface
[    0.420000] -------------
[    0.420000] SDRAM_CS0 ....base 00000000, size 512MB
[    0.420000] SDRAM_CS1 ....disable
[    0.420000] SDRAM_CS2 ....disable
[    0.420000] SDRAM_CS3 ....disable
[    0.420000] PEX0_MEM ....base e0000000, size 128MB
[    0.420000] PEX0_IO ....base f2000000, size   1MB
[    0.420000] PEX1_MEM ....base e8000000, size 128MB
[    0.420000] PEX1_IO ....base f2100000, size   1MB
[    0.420000] INTER_REGS ....base f1000000, size   1MB
[    0.420000] NFLASH_CS ....base fa000000, size   2MB
[    0.420000] SPI_CS ....base f4000000, size  16MB
[    0.420000] BOOT_ROM_CS ....no such
[    0.420000] DEV_BOOTCS ....no such
[    0.420000] CRYPT_ENG ....base f0000000, size   2MB
[    0.420000]  Detected Tclk 200000000 and SysClk 500000000
[    0.420000] Apply DS 212 GPIO
[    0.420000] Synology 6282 1, 2 bay GPIO Init
[    0.920000] PEX0 interface detected no Link.
[    1.420000] PEX1 interface detected Link X1
[    1.420000] PCI: bus0: Fast back to back transfers enabled
[    1.420000] pci 0000:01:01.0: reg 10 64bit mmio: [0x98000000-0x98001fff]
[    1.420000] pci 0000:01:01.0: PME# supported from D0 D3hot
[    1.420000] pci 0000:01:01.0: PME# disabled
[    1.420000] PCI: bus1: Fast back to back transfers disabled
[    1.430000] bio: create slab <bio-0> at 0
[    1.430000] vgaarb: loaded
[    1.430000] SCSI subsystem initialized
[    1.430000] libata version 3.00 loaded.
[    1.600000] raid6: int32x1    146 MB/s
[    1.770000] raid6: int32x2    211 MB/s
[    1.940000] raid6: int32x4    216 MB/s
[    2.110000] raid6: int32x8    238 MB/s
[    2.110000] raid6: using algorithm int32x8 (238 MB/s)
[    2.110000] Switching to clocksource kw_clocksource
[    2.110000] NET: Registered protocol family 2
[    2.110000] IP route cache hash table entries: 4096 (order: 2, 16384 bytes)
[    2.110000] TCP established hash table entries: 16384 (order: 5, 131072 bytes)
[    2.110000] TCP bind hash table entries: 16384 (order: 4, 65536 bytes)
[    2.110000] TCP: Hash tables configured (established 16384 bind 16384)
[    2.110000] TCP reno registered
[    2.110000] NET: Registered protocol family 1
[    2.110000] RPC: Registered udp transport module.
[    2.110000] RPC: Registered tcp transport module.
[    2.110000] RPC: Registered tcp NFSv4.1 backchannel transport module.
[    2.110000] Trying to unpack rootfs image as initramfs...
[    4.490000] rootfs image is not initramfs (no cpio magic); looks like an initrd
[    4.520000] Freeing initrd memory: 8192K
[    4.520000] XOR registered 4 channels
[    4.520000] XOR 2nd invalidate WA enabled
[    4.520000] VFS: Disk quotas dquot_6.5.2
[    4.520000] Dquot-cache hash table entries: 1024 (order 0, 4096 bytes)
[    4.520000] msgmni has been set to 998
[    4.520000] alg: No test for md5 (md5-generic)
[    4.520000] alg: No test for des (des-generic)
[    4.520000] alg: No test for des3_ede (des3_ede-generic)
[    4.520000] alg: No test for stdrng (krng)
[    4.520000] Block layer SCSI generic (bsg) driver version 0.4 loaded (major 254)
[    4.520000] io scheduler noop registered
[    4.520000] io scheduler anticipatory registered (default)
[    4.530000] Serial: 8250/16550 driver, 4 ports, IRQ sharing disabled
[    4.530000] serial8250.0: ttyS0 at MMIO 0xf1012000 (irq = 33) is a 16550A
[    4.540000] console [ttyS0] enabled
[    4.550000] serial8250.1: ttyS1 at MMIO 0xf1012100 (irq = 34) is a 16550A
[    4.560000] brd: module loaded
[    4.560000] sata_mv sata_mv.0: version 1.28
[    4.570000] sata_mv sata_mv.0: slots 32 ports 2
[    4.570000] scsi0 : sata_mv
[    4.570000] scsi1 : sata_mv
[    4.580000] ata1: SATA max UDMA/133 irq 21
[    4.580000] ata2: SATA max UDMA/133 irq 21
[   13.130000] ata1: link is slow to respond, please be patient (ready=0)
[   17.630000] ata1: SRST failed (errno=-16)
[   17.630000] ata1: SRST fail, set srst fail flag
[   20.120000] ata1: SATA link up 3.0 Gbps (SStatus 123 SControl F300)
[   20.120000] ata1: link reset sucessfully clear error flags
[   20.170000] ata1.00: ATA-8: Hitachi HUS724030ALE641, MJ8OA5F0, max UDMA/133
[   20.170000] ata1.00: 5860533168 sectors, multi 0: LBA48 NCQ (depth 31/32)
[   20.240000] ata1.00: configured for UDMA/133
[   20.260000] scsi 0:0:0:0: Direct-Access     Hitachi  HUS724030ALE641          MJ8O PQ: 0 ANSI: 5
[   20.260000] sd 0:0:0:0: [sda] 5860533168 512-byte logical blocks: (3.00 TB/2.72 TiB)
[   20.270000] sd 0:0:0:0: [sda] 4096-byte physical blocks
[   20.280000] sd 0:0:0:0: [sda] Write Protect is off
[   20.280000] sd 0:0:0:0: [sda] Mode Sense: 00 3a 00 00
[   20.280000] sd 0:0:0:0: [sda] Write cache: enabled, read cache: enabled, doesn't support DPO or FUA
[   20.290000]  sda: sda1 sda2 sda5
[   20.340000] sd 0:0:0:0: [sda] Attached SCSI disk
[   23.340000] Delay 5 seconds to wait for disk 2 ready.
[   28.690000] ata2: SATA link down (SStatus 0 SControl F300)
[   28.690000] physmap platform flash device: 00400000 at f8000000
[   28.700000] SPI Serial flash detected @ 0xf8000000, 8192KB (128sec x 64KB)
[   28.710000] Searching for RedBoot partition table in SYNOMTD-0 at offset 0x7f0000
[   28.720000] 6 RedBoot partitions found on MTD device SYNOMTD-0
[   28.730000] SYNOMTD flash bank 0: Using RedBoot partition definition
[   28.730000] Creating 6 MTD partitions on "SYNOMTD-0":
[   28.740000] 0x000000000000-0x000000090000 : "RedBoot"
[   28.750000] 0x000000090000-0x000000390000 : "zImage"
[   28.750000] 0x000000390000-0x0000007d0000 : "rd.gz"
[   28.760000] 0x0000007d0000-0x0000007e0000 : "vendor"
[   28.760000] vender Mac1 checksum error ucSum:0x00 Buf:0xff Sum:0.
[   28.770000] vender Mac2 checksum error ucSum:0x00 Buf:0xff Sum:0.
[   28.770000] vender Mac3 checksum error ucSum:0x00 Buf:0xff Sum:0.
[   28.780000] serial number='C8L5N07423'
[   28.780000] 0x0000007e0000-0x0000007f0000 : "RedBoot Config"
[   28.790000] 0x0000007f0000-0x000000800000 : "FIS directory"
[   28.800000] SPI Serial flash detected @ 0xf4000000, 8192KB (128sec x 64KB)
[   28.800000] cmdlinepart partition parsing not available
[   28.810000] Loading Marvell Ethernet Driver:
[   28.820000]   o Cached descriptors in DRAM
[   28.820000]   o DRAM SW cache-coherency
[   28.820000]   o 2 Giga ports supported
[   28.830000]   o Single RX Queue support - ETH_DEF_RXQ=0
[   28.830000]   o Single TX Queue support - ETH_DEF_TXQ=0
[   28.840000]   o TCP segmentation offload (TSO) supported
[   28.840000]   o Receive checksum offload supported
[   28.850000]   o Transmit checksum offload supported
[   28.850000]   o SKB Recycle supported - (Enabled)
[   28.860000]   o Rx descripors: q0=128
[   28.860000]   o Tx descripors: q0=532
[   28.860000]   o Loading network interface(s):
[   28.870000]     o  register under mv88fx_eth platform
[   28.880000]     o eth0, ifindex = 2, GbE port = 0
[   28.880000]     o eth0, phy chipid = 1410e90, Support WOL = 32

[   28.890000] md: linear personality registered for level -1
[   28.890000] md: raid0 personality registered for level 0
[   28.900000] md: raid1 personality registered for level 1
[   28.900000] md: raid10 personality registered for level 10
[   28.910000] md: raid6 personality registered for level 6
[   28.910000] md: raid5 personality registered for level 5
[   28.920000] md: raid4 personality registered for level 4
[   28.930000] device-mapper: ioctl: 4.15.0-ioctl (2009-04-01) initialised: dm-devel@redhat.com
[   28.930000] cpuidle: using governor ladder
[   28.940000] TCP cubic registered
[   28.940000] NET: Registered protocol family 17
[   28.950000] NET: Registered protocol family 15
[   28.950000] registered taskstats version 1
[   28.960000] md: Waiting for all devices to be available before autodetect
[   28.960000] md: If you don't use raid, use raid=noautodetect
[   28.970000] md: Autodetecting RAID arrays.
[   29.010000] md: invalid raid superblock magic on sda5
[   29.010000] md: sda5 does not have a valid v0.90 superblock, not importing!
[   29.020000] md: Scanned 3 and added 2 devices.
[   29.030000] md: autorun ...
[   29.030000] md: considering sda1 ...
[   29.030000] md:  adding sda1 ...
[   29.030000] md: sda2 has different UUID to sda1
[   29.040000] md: created md0
[   29.040000] md: bind<sda1>
[   29.040000] md: running: <sda1>
[   29.050000] raid1: raid set md0 active with 1 out of 2 mirrors
[   29.050000] md0: detected capacity change from 0 to 2549940224
[   29.060000] md: considering sda2 ...
[   29.060000] md:  adding sda2 ...
[   29.070000] md: created md1
[   29.070000] md: bind<sda2>
[   29.070000] md: running: <sda2>
[   29.080000] raid1: raid set md1 active with 1 out of 2 mirrors
[   29.080000] md1: detected capacity change from 0 to 2147418112
[   29.090000] md: ... autorun DONE.
[   29.090000] RAMDISK: lzma image found at block 0
[   31.690000] VFS: Mounted root (ext2 filesystem) on device 1:0.
[   31.940000] usbcore: registered new interface driver usbfs
[   31.940000] usbcore: registered new interface driver hub
[   31.980000] usbcore: registered new interface driver ethub
[   31.980000] usbcore: registered new device driver usb
[   32.050000] ehci_hcd: USB 2.0 'Enhanced' Host Controller (EHCI) Driver
[   32.060000] orion-ehci orion-ehci.0: Marvell Orion EHCI
[   32.070000] orion-ehci orion-ehci.0: new USB bus registered, assigned bus number 1
[   32.100000] orion-ehci orion-ehci.0: irq 19, io mem 0xf1050000
[   32.120000] orion-ehci orion-ehci.0: USB 2.0 started, EHCI 1.00
[   32.120000] usb usb1: configuration #1 chosen from 1 choice
[   32.150000] hub 1-0:1.0: USB hub found
[   32.150000] hub 1-0:1.0: 1 port detected
[   32.230000] ohci_hcd: USB 1.1 'Open' Host Controller (OHCI) Driver
[   32.290000] xhci_hcd 0000:01:01.0: xHCI Host Controller
[   32.300000] xhci_hcd 0000:01:01.0: new USB bus registered, assigned bus number 2
[   32.310000] xhci_hcd 0000:01:01.0: irq 10, io mem 0xe8000000
[   32.320000] usb usb2: No SuperSpeed endpoint companion for config 1  interface 0 altsetting 0 ep 129: using minimum values
[   32.350000] usb usb2: configuration #1 chosen from 1 choice
[   32.350000] xHCI xhci_add_endpoint called for root hub
[   32.350000] xHCI xhci_check_bandwidth called for root hub
[   32.350000] hub 2-0:1.0: USB hub found
[   32.360000] hub 2-0:1.0: 4 ports detected
[   32.470000] usb 1-1: new high speed USB device using orion-ehci and address 2
[   32.500000] ds213_synobios: module license 'Synology Inc.' taints kernel.
[   32.510000] Disabling lock debugging due to kernel taint
[   32.570000] correction with 0x0f
[   32.620000] 2020-10-9 17:6:50 UTC
[   32.620000] synobios: load, major number 201
[   32.630000] Brand: Synology
[   32.630000] Model: DS-213
[   32.630000] This is default settings: set group disks wakeup number to 1, spinup time deno 1
[   32.640000] synobios cpu_arch proc entry initialized
[   32.650000] synobios crypto_hw proc entry initialized
[   32.650000] synobios syno_platform proc entry initialized
[   32.660000] synobios open /dev/ttyS1 success
[   32.680000] synobios: unload
[   32.750000] Got empty serial number. Generate serial number from product.
[   32.760000] usb 1-1: configuration #1 chosen from 1 choice
[   32.760000] hub 1-1:1.0: USB hub found
[   32.790000] hub 1-1:1.0: 4 ports detected
[   32.790000]  md0: unknown partition table
[   33.080000] usb 1-1.4: new high speed USB device using orion-ehci and address 3
[   33.220000] usb 1-1.4: configuration #1 chosen from 1 choice
[   34.130000] EXT4-fs (md0): barriers disabled
[   34.140000] EXT4-fs (md0): mounted filesystem with ordered data mode
[   36.600000] EXT3-fs: md0: couldn't mount because of unsupported optional features (240).
[   36.600000] EXT2-fs: md0: couldn't mount because of unsupported optional features (240).
[   36.630000] EXT4-fs (md0): barriers disabled
[   36.640000] EXT4-fs (md0): mounted filesystem with ordered data mode
[   36.640000] VFS: Mounted root (ext4 filesystem) on device 9:0.
[   36.650000] Trying to move old root to /initrd ... okay
[   36.650000] Freeing init memory: 124K
[   44.450000] sd 0:0:0:0: Attached scsi generic sg0 type 0
[   45.210000]  md1: unknown partition table
[   45.370000] Adding 2097080k swap on /dev/md1.  Priority:-1 extents:1 across:2097080k
[   48.010000] NET: Registered protocol family 10
[   48.010000] lo: Disabled Privacy Extensions
[   48.060000] IPv6 over IPv4 tunneling driver
[   48.070000] sit0: Disabled Privacy Extensions
[   49.430000] init: syno-auth-check main process (1383) killed by TERM signal
[   50.200000] <30>systemd-udevd[1534]: starting version 204
[   51.500000] cpufreq: Init kirkwood cpufreq driver
[   51.500000] cpufreq: High frequency: 2000000KHz - Low frequency: 500000KHz
[   53.820000] alg: No test for aes (aes-generic)
[   53.940000] alg: No test for stdrng (ansi_cprng)
[   54.040000] alg: No test for crc32c (crc32c-generic)
[   55.180000] cesadev_init(bf192000)
[   55.290000] mvCesaInit: sessions=10240, queue=64, pSram=f0000000
[   55.980000] alg: No test for sha1 (sha1-generic)
[   56.230000] alg: No test for sha224 (sha224-generic)
[   56.240000] alg: No test for sha256 (sha256-generic)
[   56.450000] encryptfs using the OCF package.
[   58.000000] alg: No test for arc4 (arc4-generic)
[   58.180000] fuse init (API version 7.13)
[   59.220000] exFAT: Version 1.2.9
[   59.950000] sky2 driver version 1.25
[   60.550000] correction with 0x0f
[   60.600000] 2020-10-9 17:7:18 UTC
[   60.600000] synobios: load, major number 201
[   60.610000] Brand: Synology
[   60.610000] Model: DS-213
[   60.610000] This is default settings: set group disks wakeup number to 1, spinup time deno 1
[   60.620000] synobios cpu_arch proc entry initialized
[   60.630000] synobios crypto_hw proc entry initialized
[   60.630000] synobios syno_platform proc entry initialized
[   60.640000] synobios open /dev/ttyS1 success
[   63.450000] eth0: mac address changed
[   66.100000] eth0: link down
[   66.100000] eth0: started
[   67.450000] ADDRCONF(NETDEV_UP): eth0: link is not ready
[   67.740000] eth0: link up, full duplex, speed 1 Gbps
[   67.750000] ADDRCONF(NETDEV_CHANGE): eth0: link becomes ready
[   79.150000] init: dhcp-client (eth0) main process (4004) killed by TERM signal
[   82.670000] md: md2 stopped.
[   82.690000] md: bind<sda5>
[   82.710000] raid1: raid set md2 active with 1 out of 1 mirrors
[   82.710000] md2: detected capacity change from 0 to 2995645906944
[   82.730000]  md2: unknown partition table
[   93.270000] EXT4-fs (dm-0): barriers disabled
[   94.050000] EXT4-fs (dm-0): mounted filesystem with writeback data mode
[  111.180000] Initializing USB Mass Storage driver...
[  111.590000] scsi2 : SCSI emulation for USB Mass Storage devices
[  111.600000] usbcore: registered new interface driver usb-storage
[  111.600000] USB Mass Storage support registered.
[  111.610000] usb-storage: device found at 3
[  111.610000] usb-storage: waiting for device to settle before scanning
[  111.960000] usbcore: registered new interface driver usblp
[  112.690000] usbcore: registered new interface driver hiddev
[  112.690000] usbcore: registered new interface driver usbhid
[  112.700000] usbhid: v2.6:USB HID core driver
[  113.240000] loop: module loaded
[  115.480000] Slow work thread pool: Starting up
[  116.230000] Slow work thread pool: Ready
[  116.630000] scsi 2:0:0:0: Direct-Access     Generic  STORAGE DEVICE           9910 PQ: 0 ANSI: 0
[  116.640000] sd 2:0:0:0: Attached scsi generic sg1 type 0
[  116.720000] sd 2:0:0:0: [sdq] Attached SCSI removable disk
[  116.840000] scsi 2:0:0:1: Direct-Access     Generic  STORAGE DEVICE           9910 PQ: 0 ANSI: 0
[  116.840000] sd 2:0:0:1: Attached scsi generic sg2 type 0
[  116.850000] sd 2:0:0:1: [sdr] Attached SCSI removable disk
[  117.090000] usb-storage: device scan complete
[  117.680000] iSCSI: init_io_buffer_head(833) LUN-backup: 512 buffers allocated, total 2097152 bytes successfully
[  125.170000] ata1.00: configured for UDMA/133
[  125.170000] ata1: EH complete
[  126.210000] warning: `nginx' uses 32-bit capabilities (legacy support in use)
[  137.400000] findhostd uses obsolete (PF_INET,SOCK_PACKET)
[  138.940000] init: syno_disk_latency_monitor faild on spawn stage, stopped
[  144.570000] eth0: link down
[  144.580000] eth0: link up, full duplex, speed 1 Gbps
[  152.150000] init: dhcp-client (eth0) main process (4185) killed by TERM signal
[  152.930000] init: nmbd main process (7453) killed by TERM signal
[  160.910000] init: dhcp-client (eth0) main process (7528) killed by TERM signal
[  198.220000] init: nmbd main process (9391) killed by TERM signal
[  235.090000] init: nmbd main process (11507) killed by TERM signal
[ 1247.430000] init: sshd main process (14259) killed by TERM signal

root@Diskstation1:~# cat /proc/mtd
dev:    size   erasesize  name
mtd0: 00090000 00010000 "RedBoot"
mtd1: 00300000 00010000 "zImage"
mtd2: 00440000 00010000 "rd.gz"
mtd3: 00010000 00010000 "vendor"
mtd4: 00010000 00010000 "RedBoot Config"
mtd5: 00010000 00010000 "FIS directory"
mtd6: 00800000 00010000 "spi_flash"

Marvell>> printenv
bootcmd=bootm F8090000 F8390000
baudrate=115200
loads_echo=0
ipaddr=192.168.1.154
serverip=192.168.1.155
rootpath=/mnt/ARM_FS/
netmask=255.255.254.0
run_diag=yes
stdin=serial
stdout=serial
stderr=serial
console=console=ttyS0,115200 mtdparts=spi_flash:0x80000@0(uboot)ro,0x700000@0x100000(root)
mainlineLinux=no
enaMonExt=no
enaCpuStream=no
enaWrAllo=no
pexMode=RC
disL2Cache=no
setL2CacheWT=yes
disL2Prefetch=yes
enaICPref=yes
enaDCPref=yes
sata_dma_mode=yes
MALLOC_len=1
ethprime=egiga0
netbsd_en=no
vxworks_en=no
bootargs_root=root=/dev/nfs rw
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;
lcd0_enable=0
lcd0_params=640x480-16@60
bootdelay=3
disaMvPnp=no
ethaddr=00:50:43:3c:3b:5d
ethmtu=1500
mvPhoneConfig=mv_phone_config=dev[0]:fxs,dev[1]:fxo
mvNetConfig=mv_net_config=(00:11:88:0f:62:81,0:1:2:3),mtu=1500
usb0Mode=host
pcieTune=no
pcieTune1=no
bootargs=console=ttyS0,115200 ip=off initrd=0x00800040,8M root=/dev/md0 rw syno_hw_version=DS213v10 ihd_num=2 netif_num=1 flash_size=8
ethact=egiga0

Environment size: 1173/4092 bytes
Marvell>>


Re: Bricked Synology DS213 (Kirkwood) so close
October 10, 2020 05:50PM
I will modify this post as I am adding more details.

--------------------------------------------------------------------

How to unbrick (backup and restore DS213 SPI mtds)

Prerequisite

Serial console must be connected on the bricked DS213.

Steps

1. Backup SPI mtds

Log in to stock OS on a good DS213 box.

1.a. Verify that the mtds are like below

cat /proc/mtd
dev:    size   erasesize  name
mtd0: 00090000 00010000 "RedBoot"
mtd1: 00300000 00010000 "zImage"
mtd2: 00440000 00010000 "rd.gz"
mtd3: 00010000 00010000 "vendor"
mtd4: 00010000 00010000 "RedBoot Config"
mtd5: 00010000 00010000 "FIS directory"
mtd6: 00800000 00010000 "spi_flash"


1.b. Dump SPI mtds

dd if=/dev/mtd0 of=ds213.mtd0 bs=576k conv=sync
dd if=/dev/mtd1 of=ds213.mtd1 bs=3072k conv=sync
dd if=/dev/mtd2 of=ds213.mtd2 bs=4352k conv=sync
dd if=/dev/mtd3 of=ds213.mtd3 bs=64k conv=sync
dd if=/dev/mtd4 of=ds213.mtd4 bs=64k conv=sync
dd if=/dev/mtd5 of=ds213.mtd5 bs=64k conv=sync
dd if=/dev/mtd6 of=ds213.mtd6 bs=8192k conv=sync

1.c. Check the files size

ls -l ds213.mtd?
ls -lh ds213.mtd?
They must be exactly the sizes in step 1.b (in Kbytes). If they are not, then stop and post question.

1.d. Create the Kirkwood rootfs Debian-5.2.9-kirkwood-tld-1-rootfs-bodhi.tar.bz2 on a USB drive.

https://forum.doozan.com/read.php?2,12096

This 1.d step can be performed on any Linux host that you can log in as root (or become root).

1.e. Mount the USB rootfs drive on the good DS213, and copy the SPI mtd backup files (ds213.mtd*) to /boot folder on the USB rootfs drive.

1.d Sync and remove the USB rootfs drive.


2. Restore the backup SPI mtds to a bricked box

2.a. From another Linux box (we'll refer to this box as the Linux host), download the NSA325 u-boot from the release thread:

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

The correct tarball is

uboot.2017.07-tld-1.nsa325.bodhi.tar

Extract the tarball to get the binary uboot.2017.07-tld-1.nsa325.mtd0.kwb


2.b Run kwboot from the Linux host to load and run NSA325 u-boot image to boot the USB rootfs

Connect serial console module converter to the Linux host and run kwboot to start the NSA325 u-boot.

./kwboot -t -B 115200 /dev/ttyUSB0 -b uboot.2017.07-tld-1.nsa325.mtd0.kwb -p

And then power up the brick DS213.

After the NSA325 u-boot has loaded and started, interrupt serial console at countdown, and insert the USB rootfs Debian-5.2.9-kirkwood-tld-1-rootfs-bodhi.tar.bz2 to the bricked DS213.

And then set the envs for booting:
setenv set_bootargs 'setenv bootargs console=ttyS0,115200 root=LABEL=rootfs rootdelay=10 earlyprintk=serial'
setenv dtb_file '/boot/dts/kirkwood-ds212.dtb'
boot


2.b. After the booting completed, at the Debian prompt, log in using credential root/root


3. Flashing backup mtds to SPI flash

3.1. Check the mtd partitions

cat /proc/mtd

Expected output:
dev:    size   erasesize  name
mtd0: 00090000 00010000 "RedBoot"
mtd1: 00300000 00010000 "zImage"
mtd2: 00440000 00010000 "rd.gz"
mtd3: 00010000 00010000 "vendor"
mtd4: 00010000 00010000 "RedBoot Config"
mtd5: 00010000 00010000 "FIS directory"

3.2. Flash the mtd files

cd /boot 
flash_unlock /dev/mtd0
flashcp -v ds213.mtd0 /dev/mtd0
flash_unlock /dev/mtd0
flashcp -v ds213.mtd1 /dev/mtd1
flash_unlock /dev/mtd2
flashcp -v ds213.mtd2 /dev/mtd2
flash_unlock /dev/mtd3
flashcp -v ds213.mtd3 /dev/mtd3
flash_unlock /dev/mtd4
flashcp -v ds213.mtd4 /dev/mtd4
flash_unlock /dev/mtd5
flashcp -v ds213.mtd5 /dev/mtd5

If you see flash_unlock error, then ignore it (we might not need to unlock each mtd partition before flashing).

3.3. Prepare to boot the box with newly restored mtds.

3.3.1 Shutdown the bricked DS213 box

shutdown -h now

And remove the USB rootfs.

3.3.2. Restart the bricked DS213

At this point if the good DS213 s running, shutdown this box to avoid interference. And then power up the bricked DS213 box.

Watch serial console (at this point Linux host still have the kwboot session running, but only as a serial console terminal). Save the entire serial console log for reference later.


DONE.

-bodhi
===========================
Forum Wiki
bodhi's corner



Edited 2 time(s). Last edit at 10/13/2020 11:55PM by bodhi.
Re: Bricked Synology DS213 (Kirkwood) so close
October 10, 2020 05:53PM
itangoii,

So do the Steps until 2a. If successful, get a listing of the commands and the envs:

help
printenv
And please post the entire serial console kwboot log here.

-bodhi
===========================
Forum Wiki
bodhi's corner



Edited 1 time(s). Last edit at 10/10/2020 05:55PM by bodhi.
Re: Bricked Synology DS213 (Kirkwood) so close
October 10, 2020 08:54PM
Everything went well with a couple of notes for the instructions. Did you want the console log showing the results of your instructions, or the results for the hep and printenv commands?

1. You may want to advise where the files are saved as the user may not assume that they are in the current working directory.

2. The user will need to know how to mount the USB for file copy at the command line in the terminal (I'm not suggesting including that, they can research it or already know).

3. File sizes over Kilobyte are rounded. So, 653K is stated as such, 8456123 is stated as 8.4m in the ls listing. So with that method it is not possible to be totally accurate.

I noticed that on mtd6 it was over 81xxxxx but listed as 8.0m Hopefully that is not a problem.


root@Diskstation1:~# help
GNU bash, version 4.3.48(1)-release (armle-unknown-linux-gnu)
These shell commands are defined internally.  Type `help' to see this list.
Type `help name' to find out more about the function `name'.
Use `info bash' to find out more about the shell in general.
Use `man -k' or `info' to find out more about commands not in this list.

A star (*) next to a name means that the command is disabled.

 job_spec [&]                           history [-c] [-d offset] [n] or his>
 (( expression ))                       if COMMANDS; then COMMANDS; [ elif >
 . filename [arguments]                 jobs [-lnprs] [jobspec ...] or jobs>
 :                                      kill [-s sigspec | -n signum | -sig>
 [ arg... ]                             let arg [arg ...]
 [[ expression ]]                       local [option] name[=value] ...
 alias [-p] [name[=value] ... ]         logout [n]
 bg [job_spec ...]                      mapfile [-n count] [-O origin] [-s >
 bind [-lpsvPSVX] [-m keymap] [-f fil>  popd [-n] [+N | -N]
 break [n]                              printf [-v var] format [arguments]
 builtin [shell-builtin [arg ...]]      pushd [-n] [+N | -N | dir]
 caller [expr]                          pwd [-LP]
 case WORD in [PATTERN [| PATTERN]...>  read [-ers] [-a array] [-d delim] [>
 cd [-L|[-P [-e]] [-@]] [dir]           readarray [-n count] [-O origin] [->
 command [-pVv] command [arg ...]       readonly [-aAf] [name[=value] ...] >
 compgen [-abcdefgjksuv] [-o option] >  return [n]
 complete [-abcdefgjksuv] [-pr] [-DE]>  select NAME [in WORDS ... ;] do COM>
 compopt [-o|+o option] [-DE] [name .>  set [-abefhkmnptuvxBCHP] [-o option>
 continue [n]                           shift [n]
 coproc [NAME] command [redirections]>   shopt [-pqsu] [-o] [optname ...]
 declare [-aAfFgilnrtux] [-p] [name[=>  source filename [arguments]
 dirs [-clpv] [+N] [-N]                 suspend [-f]
 disown [-h] [-ar] [jobspec ...]        test [expr]
 echo [-neE] [arg ...]                  time [-p] pipeline
 enable [-a] [-dnps] [-f filename] [n>  times
 eval [arg ...]                         trap [-lp] [[arg] signal_spec ...]
 exec [-cl] [-a name] [command [argum>  true
 exit [n]                               type [-afptP] name [name ...]
 export [-fn] [name[=value] ...] or e>  typeset [-aAfFgilrtux] [-p] name[=v>
 false                                  ulimit [-SHabcdefilmnpqrstuvxT] [li>
 fc [-e ename] [-lnr] [first] [last] >  umask [-p] [-S] [mode]
 fg [job_spec]                          unalias [-a] name [name ...]
 for NAME [in WORDS ... ] ; do COMMAN>  unset [-f] [-v] [-n] [name ...]
 for (( exp1; exp2; exp3 )); do COMMA>  until COMMANDS; do COMMANDS; done
 function name { COMMANDS ; } or name>  variables - Names and meanings of s>
 getopts optstring name [arg]           wait [-n] [id ...]
 hash [-lr] [-p pathname] [-dt] [name>  while COMMANDS; do COMMANDS; done
 help [-dms] [pattern ...]              { COMMANDS ; }
root@Diskstation1:~# clear
root@Diskstation1:~# help
GNU bash, version 4.3.48(1)-release (armle-unknown-linux-gnu)
These shell commands are defined internally.  Type `help' to see this list.
Type `help name' to find out more about the function `name'.
Use `info bash' to find out more about the shell in general.
Use `man -k' or `info' to find out more about commands not in this list.

A star (*) next to a name means that the command is disabled.

 job_spec [&]                           history [-c] [-d offset] [n] or his>
 (( expression ))                       if COMMANDS; then COMMANDS; [ elif >
 . filename [arguments]                 jobs [-lnprs] [jobspec ...] or jobs>
 :                                      kill [-s sigspec | -n signum | -sig>
 [ arg... ]                             let arg [arg ...]
 [[ expression ]]                       local [option] name[=value] ...
 alias [-p] [name[=value] ... ]         logout [n]
 bg [job_spec ...]                      mapfile [-n count] [-O origin] [-s >
 bind [-lpsvPSVX] [-m keymap] [-f fil>  popd [-n] [+N | -N]
 break [n]                              printf [-v var] format [arguments]
 builtin [shell-builtin [arg ...]]      pushd [-n] [+N | -N | dir]
 caller [expr]                          pwd [-LP]
 case WORD in [PATTERN [| PATTERN]...>  read [-ers] [-a array] [-d delim] [>
 cd [-L|[-P [-e]] [-@]] [dir]           readarray [-n count] [-O origin] [->
 command [-pVv] command [arg ...]       readonly [-aAf] [name[=value] ...] >
 compgen [-abcdefgjksuv] [-o option] >  return [n]
 complete [-abcdefgjksuv] [-pr] [-DE]>  select NAME [in WORDS ... ;] do COM>
 compopt [-o|+o option] [-DE] [name .>  set [-abefhkmnptuvxBCHP] [-o option>
 continue [n]                           shift [n]
 coproc [NAME] command [redirections]>   shopt [-pqsu] [-o] [optname ...]
 declare [-aAfFgilnrtux] [-p] [name[=>  source filename [arguments]
 dirs [-clpv] [+N] [-N]                 suspend [-f]
 disown [-h] [-ar] [jobspec ...]        test [expr]
 echo [-neE] [arg ...]                  time [-p] pipeline
 enable [-a] [-dnps] [-f filename] [n>  times
 eval [arg ...]                         trap [-lp] [[arg] signal_spec ...]
 exec [-cl] [-a name] [command [argum>  true
 exit [n]                               type [-afptP] name [name ...]
 export [-fn] [name[=value] ...] or e>  typeset [-aAfFgilrtux] [-p] name[=v>
 false                                  ulimit [-SHabcdefilmnpqrstuvxT] [li>
 fc [-e ename] [-lnr] [first] [last] >  umask [-p] [-S] [mode]
 fg [job_spec]                          unalias [-a] name [name ...]
 for NAME [in WORDS ... ] ; do COMMAN>  unset [-f] [-v] [-n] [name ...]
 for (( exp1; exp2; exp3 )); do COMMA>  until COMMANDS; do COMMANDS; done
 function name { COMMANDS ; } or name>  variables - Names and meanings of s>
 getopts optstring name [arg]           wait [-n] [id ...]
 hash [-lr] [-p pathname] [-dt] [name>  while COMMANDS; do COMMANDS; done
 help [-dms] [pattern ...]              { COMMANDS ; }

root@Diskstation1:~# printenv
SHELL=/bin/ash
TERM=vt102
LC_ALL=en_US.utf8
USER=root
SUDO_USER=admin
SUDO_UID=1024
USERNAME=root
PAGER=more
COLUMNS=79
MAIL=/var/mail/root
PATH=/sbin:/bin:/usr/sbin:/usr/bin:/usr/syno/sbin:/usr/syno/bin:/usr/local/sbin:/usr/local/bin
PWD=/root
LANG=en_US.utf8
LINES=24
SHLVL=1
SUDO_COMMAND=/bin/ash
HOME=/root
TERMINFO=/usr/share/terminfo
LOGNAME=root
PGDATA=/var/services/pgsql
SUDO_GID=100
_=/bin/printenv



Edited 3 time(s). Last edit at 10/10/2020 09:31PM by itangoii.
Re: Bricked Synology DS213 (Kirkwood) so close
October 10, 2020 10:04PM
itangoii,

I've updated the post above:

https://forum.doozan.com/read.php?3,108294,109109#msg-109109

Quote
bodhi
> And please post the entire serial console kwboot
> log here.

It meant the serial console log from the kwboot command until the last thing you see on the screen at the end of Step 2.a.

-bodhi
===========================
Forum Wiki
bodhi's corner
Re: Bricked Synology DS213 (Kirkwood) so close
October 10, 2020 11:07PM
itangoii ,

And also post the entire log for the back up session here.

Quote

1. Backup SPI mtds

The output of this session will be used to beef up the instruction.

-bodhi
===========================
Forum Wiki
bodhi's corner
Re: Bricked Synology DS213 (Kirkwood) so close
October 11, 2020 12:14PM
I went to the file listing to check size, but still seeing a discrepancy on file size so stopped there.

 97 % [......................................................................]
 99 % [....................................]
[Type Ctrl-\ + c to quit]


U-Boot 2017.07-tld-1 (Sep 05 2017 - 00:42:03 -0700)
ZyXEL NSA325 2-Bay Power Media Server

SoC:   Kirkwood 88F6282_A1
DRAM:  512 MiB
WARNING: Caches not enabled
NAND:  0 MiB
*** Warning - readenv() failed, using default environment

In:    serial
Out:   serial
Err:   serial
Net:   egiga0
MV88E1318 PHY initialized on egiga0
Hit any key to stop autoboot:  0 
starting USB...
USB0:   USB EHCI 1.00
scanning bus 0 for devices... 4 USB Device(s) found
       scanning usb for storage devices... 
Use USB retry period from the environment: 15 second(s)

Use USB retry period from the environment: 15 second(s)
Device NOT ready
   Request Sense returned 02 3A 00

Use USB retry period from the environment: 15 second(s)
Device NOT ready
   Request Sense returned 02 3A 00
1 Storage Device(s) found

Reset IDE: ide_preinit failed

Partition Map for USB device 0  --   Partition Type: DOS

Part	Start Sector	Num Sectors	UUID		Type
  1	8064      	60596352  	cef6e1d6-01	83

## 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 ...
** File not found /boot/uEnv.txt **

no IDE devices available
running scan_disk ...
Scan device usb
device usb 0:1
** File not found /boot/uImage **
device usb 1:1
** Bad device size - 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 ...
** File not found /boot/uImage **
loading uInitrd ...
** File not found /boot/uInitrd **
loading DTB /boot/dts/kirkwood-nsa325.dtb ...
** File not found /boot/dts/kirkwood-nsa325.dtb **
Unknown command 'bootm0x800000' - try 'help'
resetting ...
�
         __  __                      _ _
        |  \/  | __ _ _ ____   _____| | |
        | |\/| |/ _` | '__\ \ / / _ \ | |
        | |  | | (_| | |   \ V /  __/ | |
        |_|  |_|\__,_|_|    \_/ \___|_|_|
 _   _     ____              _
| | | |   | __ )  ___   ___ | |_ 
| | | |___|  _ \ / _ \ / _ \| __| 
| |_| |___| |_) | (_) | (_) | |_ 
 \___/    |____/ \___/ \___/ \__|  ** LOADER **
 ** MARVELL BOARD: Synology Disk Station LE 

U-Boot 1.1.4 (Apr 19 2012 - 18:47:44) Marvell version: 3.5.9

U-Boot code: 00600000 -> 0067FFF0  BSS: -> 0068B3D4

Soc: 88F6282 A1CPU running @ 2000Mhz L2 running @ 500Mhz
SysClock = 500Mhz , TClock = 200Mhz 

DRAM (DDR3) CAS Latency = 7 tRP = 7 tRAS = 20 tRCD=7
DRAM CS[0] base 0x00000000   size 512MB 
DRAM Total size 512MB  16bit width
Addresses 8M - 0M are saved for the U-Boot usage.
Mem malloc Initialization (8M - 7M): Done
Using default environment

[8192kB@f8000000] Flash:  8 MB

CPU : Marvell Feroceon (Rev 1)

Streaming disabled 
Write allocate disabled


USB 0: host mode
PEX 0: interface detected no Link.
PEX 1: PCI Express Root Complex Interface
PEX interface detected Link X1

Synology Model: DS213
Fan Status: Good

Net:   egiga0 [PRIME], egiga1
Hit any key to stop autoboot:  0 
## Booting image at f8090000 ...
   Image Name:   Linux-2.6.32.12
   Image Type:   ARM Linux Kernel Image (uncompressed)
   Data Size:    1553512 Bytes =  1.5 MB
   Load Address: 00008000
   Entry Point:  00008000
   Verifying Checksum ... OK
OK
## Loading Ramdisk Image at f8390000 ...
   Image Name:   synology_88f6282_213 25426
   Image Type:   ARM Linux RAMDisk Image (gzip compressed)
   Data Size:    3297004 Bytes =  3.1 MB
   Load Address: 00800000
   Entry Point:  00800000
   Verifying Checksum ... OK

Starting kernel ...

Uncompressing Linux... done, booting the kernel.
[    0.000000] Linux version 2.6.32.12 (root@build4) (gcc version 4.6.4 (Marvell GCC release 20150204-c4af733b 64K MAXPAGESIZE ALIGN CVE-2015-0235) ) #25426 Tue May 12 04:42:15 CST 2020
[    0.000000] CPU: Feroceon 88FR131 [56251311] revision 1 (ARMv5TE), cr=00053977
[    0.000000] CPU: VIVT data cache, VIVT instruction cache
[    0.000000] Machine: Synology 6282 board
[    0.000000] Using UBoot passing parameters structure
[    0.000000] Sys Clk = 200000000, Tclk = 166666667
[    0.000000] Synology Board ID: 27
[    0.000000] Memory policy: ECC disabled, Data cache writeback
[    0.000000] Built 1 zonelists in Zone order, mobility grouping off.  Total pages: 130048
[    0.000000] Kernel command line: console=ttyS0,115200 ip=off initrd=0x00800040,8M root=/dev/md0 rw syno_hw_version=DS213v10 ihd_num=2 netif_num=1 flash_size=8
[    0.000000] Synology Hardware Version: DS213v10-j
[    0.000000] Internal HD num: 2
[    0.000000] Internal netif num: 1
[    0.000000] Flash Memory Size: 8 MB
[    0.000000] PID hash table entries: 2048 (order: 1, 8192 bytes)
[    0.000000] Dentry cache hash table entries: 65536 (order: 6, 262144 bytes)
[    0.000000] Inode-cache hash table entries: 32768 (order: 5, 131072 bytes)
[    0.000000] Memory: 512MB = 512MB total
[    0.000000] Memory: 502784KB available (3656K code, 519K data, 124K init, 0K highmem)
[    0.000000] Hierarchical RCU implementation.
[    0.000000] NR_IRQS:128
[    0.000000] Console: colour dummy device 80x30
[    0.000000] Calibrating delay loop... 1985.74 BogoMIPS (lpj=9928704)
[    0.250000] Mount-cache hash table entries: 512
[    0.250000] CPU: Testing write buffer coherency: ok
[    0.250000] devtmpfs: initialized
[    0.250000] xor: measuring software checksum speed
[    0.300000]    arm4regs  :  1810.800 MB/sec
[    0.350000]    8regs     :  1086.400 MB/sec
[    0.400000]    32regs    :  1402.400 MB/sec
[    0.400000] xor: using function: arm4regs (1810.800 MB/sec)
[    0.400000] NET: Registered protocol family 16
[    0.400000] Feroceon L2: Enabling L2
[    0.400000] Feroceon L2: Cache support initialised, in WT override mode.
[    0.420000] 
[    0.420000] CPU Interface
[    0.420000] -------------
[    0.420000] SDRAM_CS0 ....base 00000000, size 512MB 
[    0.420000] SDRAM_CS1 ....disable
[    0.420000] SDRAM_CS2 ....disable
[    0.420000] SDRAM_CS3 ....disable
[    0.420000] PEX0_MEM ....base e0000000, size 128MB 
[    0.420000] PEX0_IO ....base f2000000, size   1MB 
[    0.420000] PEX1_MEM ....base e8000000, size 128MB 
[    0.420000] PEX1_IO ....base f2100000, size   1MB 
[    0.420000] INTER_REGS ....base f1000000, size   1MB 
[    0.420000] NFLASH_CS ....base fa000000, size   2MB 
[    0.420000] SPI_CS ....base f4000000, size  16MB 
[    0.420000] BOOT_ROM_CS ....no such
[    0.420000] DEV_BOOTCS ....no such
[    0.420000] CRYPT_ENG ....base f0000000, size   2MB 
[    0.420000]  Detected Tclk 200000000 and SysClk 500000000 
[    0.420000] Apply DS 212 GPIO
[    0.420000] Synology 6282 1, 2 bay GPIO Init
[    0.920000] PEX0 interface detected no Link.
[    1.420000] PEX1 interface detected Link X1
[    1.420000] PCI: bus0: Fast back to back transfers enabled
[    1.420000] pci 0000:01:01.0: PME# supported from D0 D3hot
[    1.420000] pci 0000:01:01.0: PME# disabled
[    1.420000] PCI: bus1: Fast back to back transfers disabled
[    1.430000] bio: create slab <bio-0> at 0
[    1.430000] vgaarb: loaded
[    1.430000] SCSI subsystem initialized
[    1.600000] raid6: int32x1    146 MB/s
[    1.770000] raid6: int32x2    211 MB/s
[    1.940000] raid6: int32x4    216 MB/s
[    2.110000] raid6: int32x8    238 MB/s
[    2.110000] raid6: using algorithm int32x8 (238 MB/s)
[    2.110000] Switching to clocksource kw_clocksource
[    2.110000] NET: Registered protocol family 2
[    2.110000] IP route cache hash table entries: 4096 (order: 2, 16384 bytes)
[    2.110000] TCP established hash table entries: 16384 (order: 5, 131072 bytes)
[    2.110000] TCP bind hash table entries: 16384 (order: 4, 65536 bytes)
[    2.110000] TCP: Hash tables configured (established 16384 bind 16384)
[    2.110000] TCP reno registered
[    2.110000] NET: Registered protocol family 1
[    2.110000] RPC: Registered udp transport module.
[    2.110000] RPC: Registered tcp transport module.
[    2.110000] RPC: Registered tcp NFSv4.1 backchannel transport module.
[    2.110000] Trying to unpack rootfs image as initramfs...
[    4.490000] rootfs image is not initramfs (no cpio magic); looks like an initrd
[    4.520000] Freeing initrd memory: 8192K
[    4.520000] XOR registered 4 channels
[    4.520000] XOR 2nd invalidate WA enabled
[    4.520000] VFS: Disk quotas dquot_6.5.2
[    4.520000] Dquot-cache hash table entries: 1024 (order 0, 4096 bytes)
[    4.520000] msgmni has been set to 998
[    4.520000] alg: No test for md5 (md5-generic)
[    4.520000] alg: No test for des (des-generic)
[    4.520000] alg: No test for des3_ede (des3_ede-generic)
[    4.520000] alg: No test for stdrng (krng)
[    4.520000] Block layer SCSI generic (bsg) driver version 0.4 loaded (major 254)
[    4.520000] io scheduler noop registered
[    4.520000] io scheduler anticipatory registered (default)
[    4.530000] Serial: 8250/16550 driver, 4 ports, IRQ sharing disabled
[    4.530000] serial8250.0: ttyS0 at MMIO 0xf1012000 (irq = 33) is a 16550A
[    4.540000] console [ttyS0] enabled
[    4.550000] serial8250.1: ttyS1 at MMIO 0xf1012100 (irq = 34) is a 16550A
[    4.560000] brd: module loaded
[    4.560000] sata_mv sata_mv.0: version 1.28
[    4.560000] sata_mv sata_mv.0: slots 32 ports 2
[    4.570000] scsi0 : sata_mv
[    4.570000] scsi1 : sata_mv
[    4.580000] ata1: SATA max UDMA/133 irq 21
[    4.580000] ata2: SATA max UDMA/133 irq 21
[   13.130000] ata1: link is slow to respond, please be patient (ready=0)
[   17.630000] ata1: SRST failed (errno=-16)
[   17.630000] ata1: SRST fail, set srst fail flag
[   20.180000] ata1: SATA link up 3.0 Gbps (SStatus 123 SControl F300)
[   20.180000] ata1: link reset sucessfully clear error flags
[   20.230000] ata1.00: ATA-8: Hitachi HUS724030ALE641, MJ8OA5F0, max UDMA/133
[   20.230000] ata1.00: 5860533168 sectors, multi 0: LBA48 NCQ (depth 31/32)
[   20.300000] ata1.00: configured for UDMA/133
[   20.320000] scsi 0:0:0:0: Direct-Access     Hitachi  HUS724030ALE641          MJ8O PQ: 0 ANSI: 5
[   20.320000] sd 0:0:0:0: [sda] 5860533168 512-byte logical blocks: (3.00 TB/2.72 TiB)
[   20.330000] sd 0:0:0:0: [sda] 4096-byte physical blocks
[   20.340000] sd 0:0:0:0: [sda] Write Protect is off
[   20.340000] sd 0:0:0:0: [sda] Write cache: enabled, read cache: enabled, doesn't support DPO or FUA
[   20.350000]  sda: sda1 sda2 sda5
[   20.400000] sd 0:0:0:0: [sda] Attached SCSI disk
[   23.400000] Delay 5 seconds to wait for disk 2 ready.
[   28.750000] ata2: SATA link down (SStatus 0 SControl F300)
[   28.750000] physmap platform flash device: 00400000 at f8000000
[   28.760000] SPI Serial flash detected @ 0xf8000000, 8192KB (128sec x 64KB)
[   28.770000] Searching for RedBoot partition table in SYNOMTD-0 at offset 0x7f0000
[   28.780000] 6 RedBoot partitions found on MTD device SYNOMTD-0
[   28.790000] SYNOMTD flash bank 0: Using RedBoot partition definition
[   28.790000] Creating 6 MTD partitions on "SYNOMTD-0":
[   28.800000] 0x000000000000-0x000000090000 : "RedBoot"
[   28.810000] 0x000000090000-0x000000390000 : "zImage"
[   28.810000] 0x000000390000-0x0000007d0000 : "rd.gz"
[   28.820000] 0x0000007d0000-0x0000007e0000 : "vendor"
[   28.820000] vender Mac1 checksum error ucSum:0x00 Buf:0xff Sum:0.
[   28.830000] vender Mac2 checksum error ucSum:0x00 Buf:0xff Sum:0.
[   28.830000] vender Mac3 checksum error ucSum:0x00 Buf:0xff Sum:0.
[   28.840000] serial number='C8L5N07423'
[   28.840000] 0x0000007e0000-0x0000007f0000 : "RedBoot Config"
[   28.850000] 0x0000007f0000-0x000000800000 : "FIS directory"
[   28.860000] SPI Serial flash detected @ 0xf4000000, 8192KB (128sec x 64KB)
[   28.860000] cmdlinepart partition parsing not available
[   28.870000] Loading Marvell Ethernet Driver:
[   28.880000]   o Cached descriptors in DRAM
[   28.880000]   o DRAM SW cache-coherency
[   28.880000]   o 2 Giga ports supported
[   28.890000]   o Single RX Queue support - ETH_DEF_RXQ=0
[   28.890000]   o Single TX Queue support - ETH_DEF_TXQ=0
[   28.900000]   o TCP segmentation offload (TSO) supported
[   28.900000]   o Receive checksum offload supported
[   28.910000]   o Transmit checksum offload supported
[   28.910000]   o SKB Recycle supported - (Enabled)
[   28.920000]   o Rx descripors: q0=128
[   28.920000]   o Tx descripors: q0=532
[   28.920000]   o Loading network interface(s):
[   28.930000]     o  register under mv88fx_eth platform
[   28.940000]     o eth0, ifindex = 2, GbE port = 0
[   28.940000]     o eth0, phy chipid = 1410e90, Support WOL = 32
[   28.950000] 
[   28.950000] md: linear personality registered for level -1
[   28.950000] md: raid0 personality registered for level 0
[   28.960000] md: raid1 personality registered for level 1
[   28.960000] md: raid10 personality registered for level 10
[   28.970000] md: raid6 personality registered for level 6
[   28.970000] md: raid5 personality registered for level 5
[   28.980000] md: raid4 personality registered for level 4
[   28.990000] device-mapper: ioctl: 4.15.0-ioctl (2009-04-01) initialised: dm-devel@redhat.com
[   28.990000] cpuidle: using governor ladder
[   29.000000] TCP cubic registered
[   29.000000] NET: Registered protocol family 17
[   29.010000] NET: Registered protocol family 15
[   29.010000] registered taskstats version 1
[   29.020000] md: Waiting for all devices to be available before autodetect
[   29.020000] md: If you don't use raid, use raid=noautodetect
[   29.030000] md: Autodetecting RAID arrays.
[   29.070000] md: invalid raid superblock magic on sda5
[   29.080000] md: sda5 does not have a valid v0.90 superblock, not importing!
[   29.080000] md: Scanned 3 and added 2 devices.
[   29.090000] md: autorun ...
[   29.090000] md: considering sda1 ...
[   29.100000] md:  adding sda1 ...
[   29.100000] md: sda2 has different UUID to sda1
[   29.100000] md: created md0
[   29.110000] md: bind<sda1>
[   29.110000] md: running: <sda1>
[   29.110000] raid1: raid set md0 active with 1 out of 2 mirrors
[   29.120000] md0: detected capacity change from 0 to 2549940224
[   29.120000] md: considering sda2 ...
[   29.130000] md:  adding sda2 ...
[   29.130000] md: created md1
[   29.130000] md: bind<sda2>
[   29.140000] md: running: <sda2>
[   29.140000] raid1: raid set md1 active with 1 out of 2 mirrors
[   29.150000] md1: detected capacity change from 0 to 2147418112
[   29.150000] md: ... autorun DONE.
[   29.160000] RAMDISK: lzma image found at block 0
[   31.760000] VFS: Mounted root (ext2 filesystem) on device 1:0.
START /linuxrc.syno
Insert basic USB modules...
:: Loading module usbcore[   32.000000] usbcore: registered new interface driver usbfs
[   32.000000] usbcore: registered new interface driver hub
[   32.040000] usbcore: registered new interface driver ethub
[   32.060000] usbcore: registered new device driver usb
 ... [  OK  ]
:: Loading module ehci-hcd[   32.120000] ehci_hcd: USB 2.0 'Enhanced' Host Controller (EHCI) Driver
[   32.120000] orion-ehci orion-ehci.0: Marvell Orion EHCI
[   32.130000] orion-ehci orion-ehci.0: new USB bus registered, assigned bus number 1
[   32.170000] orion-ehci orion-ehci.0: irq 19, io mem 0xf1050000
[   32.190000] orion-ehci orion-ehci.0: USB 2.0 started, EHCI 1.00
[   32.190000] usb usb1: configuration #1 chosen from 1 choice
[   32.220000] hub 1-0:1.0: USB hub found
[   32.220000] hub 1-0:1.0: 1 port detected
 ... [  OK  ]
:: Loading module ohci-hcd[   32.290000] ohci_hcd: USB 1.1 'Open' Host Controller (OHCI) Driver
 ... [  OK  ]
:: Loading module xhci-hcd[   32.370000] xhci_hcd 0000:01:01.0: xHCI Host Controller
[   32.370000] xhci_hcd 0000:01:01.0: new USB bus registered, assigned bus number 2
[   32.380000] xhci_hcd 0000:01:01.0: irq 10, io mem 0xe8000000
[   32.390000] usb usb2: No SuperSpeed endpoint companion for config 1  interface 0 altsetting 0 ep 129: using minimum values
[   32.430000] usb usb2: configuration #1 chosen from 1 choice
[   32.440000] hub 2-0:1.0: USB hub found
[   32.440000] hub 2-0:1.0: 4 ports detected
 ... [  OK  ]
[   32.540000] usb 1-1: new high speed USB device using orion-ehci and address 2
Insert net driver(Mindspeed only)...
[   32.570000] ds213_synobios: module license 'Synology Inc.' taints kernel.
[   32.580000] Disabling lock debugging due to kernel taint
[   32.640000] correction with 0x0f
[   32.690000] 2020-10-11 16:40:26 UTC
[   32.690000] synobios: load, major number 201
[   32.700000] Brand: Synology
[   32.700000] Model: DS-213
[   32.700000] This is default settings: set group disks wakeup number to 1, spinup time deno 1
[   32.710000] synobios cpu_arch proc entry initialized
[   32.720000] synobios crypto_hw proc entry initialized
[   32.720000] synobios syno_platform proc entry initialized
[   32.730000] synobios open /dev/ttyS1 success
Starting /usr/syno/bin/synocfgen...
/usr/syno/bin/synocfgen returns 0
[   32.750000] synobios: unload
Partition Version=8
 /sbin/e2fsck ex[   32.820000] Got empty serial number. Generate serial number from product.
ists, checking /dev/md0... 
[   32.830000] usb 1-1: configuration #1 chosen from 1 choice
[   32.830000] hub 1-1:1.0: USB hub found
[   32.860000] hub 1-1:1.0: 4 ports detected
[   32.860000]  md0: unknown partition table
[   33.150000] usb 1-1.3: new high speed USB device using orion-ehci and address 3
[   33.300000] usb 1-1.3: configuration #1 chosen from 1 choice
[   33.390000] usb 1-1.4: new high speed USB device using orion-ehci and address 4
[   33.530000] usb 1-1.4: configuration #1 chosen from 1 choice
/sbin/e2fsck -pvf returns 0
Mounting /dev/md0 /tmpRoot
[   34.420000] EXT4-fs (md0): barriers disabled
[   34.440000] EXT4-fs (md0): mounted filesystem with ordered data mode
------------upgrade
Begin upgrade procedure
No upgrade file exists
End upgrade procedure
============upgrade
ls: /tmpRoot/usr/share/init/root-file-system.override: No such file or directory
ls: /tmpRoot/usr/share/init/hostname.override: No such file or directory
ls: /tmpRoot/usr/share/init/syslog-ng.override: No such file or directory
ls: /tmpRoot/usr/share/init/dsmupdate.override: No such file or directory
ls: /tmpRoot/usr/share/init/smallupdate.override: No such file or directory
ls: /tmpRoot/usr/share/init/rc.override: No such file or directory
Wait 2 seconds for synology manufactory device
Sun Oct 11 16:40:30 UTC 2020
/dev/md0 /tmpRoot ext4 rw,relatime,user_xattr,barrier=0,journal_checksum,data=ordered 0 0
sys /sys sysfs rw,relatime 0 0
/dev/root.old / ext2 rw,relatime,errors=continue,user_xattr 0 0
none /dev devtmpfs rw,relatime,size=251528k,nr_inodes=62882,mode=755 0 0
proc /proc proc rw,relatime 0 0
linuxrc.syno executed successfully.
[   36.900000] EXT3-fs: md0: couldn't mount because of unsupported optional features (240).
[   36.900000] EXT2-fs: md0: couldn't mount because of unsupported optional features (240).
[   36.930000] EXT4-fs (md0): barriers disabled
[   36.950000] EXT4-fs (md0): mounted filesystem with ordered data mode
[   36.950000] VFS: Mounted root (ext4 filesystem) on device 9:0.
[   36.960000] Trying to move old root to /initrd ... okay
[   36.960000] Freeing init memory: 124K
[   45.080000] sd 0:0:0:0: Attached scsi generic sg0 type 0
[   45.840000]  md1: unknown partition table
[   46.000000] Adding 2097080k swap on /dev/md1.  Priority:-1 extents:1 across:2097080k 
==================== start udevd ====================
[   48.730000] NET: Registered protocol family 10
[   48.730000] lo: Disabled Privacy Extensions
[   48.780000] IPv6 over IPv4 tunneling driver
[   48.790000] sit0: Disabled Privacy Extensions
[   50.130000] init: syno-auth-check main process (1433) killed by TERM signal
[   51.060000] <30>systemd-udevd[1574]: starting version 204
===== trigger device plug event =====
[   51.270000] cpufreq: Init kirkwood cpufreq driver
[   53.150000] alg: No test for aes (aes-generic)
[   53.710000] alg: No test for stdrng (ansi_cprng)
[   54.040000] alg: No test for crc32c (crc32c-generic)
[   55.160000] cesadev_init(bf192000)
[   55.440000] mvCesaInit: sessions=10240, queue=64, pSram=f0000000
[   55.920000] alg: No test for sha1 (sha1-generic)
[   55.970000] alg: No test for sha224 (sha224-generic)
[   55.970000] alg: No test for sha256 (sha256-generic)
[   56.250000] encryptfs using the OCF package.
[   58.550000] alg: No test for arc4 (arc4-generic)
[   59.220000] fuse init (API version 7.13)
[   59.740000] exFAT: Version 1.2.9
[   60.680000] sky2 driver version 1.25
[   61.340000] correction with 0x0f
[   61.400000] 2020-10-11 16:40:54 UTC
[   61.400000] synobios: load, major number 201
[   61.400000] Brand: Synology
[   61.410000] Model: DS-213
[   61.410000] This is default settings: set group disks wakeup number to 1, spinup time deno 1
[   61.420000] synobios cpu_arch proc entry initialized
[   61.420000] synobios crypto_hw proc entry initialized
[   61.430000] synobios syno_platform proc entry initialized
[   61.430000] synobios open /dev/ttyS1 success
[   65.290000] eth0: mac address changed
[   67.930000] eth0: link down
[   67.930000] eth0: started
[   69.250000] ADDRCONF(NETDEV_UP): eth0: link is not ready
[   69.860000] eth0: link up, full duplex, speed 1 Gbps
[   69.870000] ADDRCONF(NETDEV_CHANGE): eth0: link becomes ready
[   81.940000] init: dhcp-client (eth0) main process (4203) killed by TERM signal
[   86.100000] md: md2 stopped.
[   86.150000] md: bind<sda5>
[   86.200000] raid1: raid set md2 active with 1 out of 1 mirrors
[   86.260000] md2: detected capacity change from 0 to 2995645906944
[   86.270000]  md2: unknown partition table
[   96.030000] EXT4-fs (dm-0): barriers disabled
[   96.810000] EXT4-fs (dm-0): mounted filesystem with writeback data mode
[  114.730000] Initializing USB Mass Storage driver...
[  115.020000] scsi2 : SCSI emulation for USB Mass Storage devices
[  115.070000] loop: module loaded
   115.200000] scsi3 : SCSI emulation for USB Mass Storage devices
   115.420000] usbcore: registered new interface driver usb-storage
[  115.430000] USB Mass Storage support registered.
[  116.050000] usbcore: registered new interface driver usblp
[  116.970000] Slow work thread pool: Starting up
[  117.570000] usbcore: registered new interface driver hiddev
[  117.570000] usbcore: registered new interface driver usbhid
[  117.580000] usbhid: v2.6:USB HID core driver
[  117.770000] Slow work thread pool: Ready
[  120.170000] scsi 2:0:0:0: Direct-Access     PNY      USB 3.0 FD               PMAP PQ: 0 ANSI: 6
[  120.180000] sd 2:0:0:0: Attached scsi generic sg1 type 0
[  120.210000] sd 2:0:0:0: [sdq] 60604416 512-byte logical blocks: (31.0 GB/28.8 GiB)
[  120.220000] sd 2:0:0:0: [sdq] Write Protect is off
[  120.220000] sd 2:0:0:0: [sdq] Assuming drive cache: write through
[  120.450000] scsi 3:0:0:0: Direct-Access     Generic  STORAGE DEVICE           9910 PQ: 0 ANSI: 0
[  120.460000] sd 3:0:0:0: Attached scsi generic sg2 type 0
[  120.490000] sd 2:0:0:0: [sdq] Assuming drive cache: write through
[  120.490000]  sdq:
[  120.500000] sd 3:0:0:0: [sdr] Attached SCSI removable disk
[  120.650000] scsi 3:0:0:1: Direct-Access     Generic  STORAGE DEVICE           9910 PQ: 0 ANSI: 0
[  120.650000] sd 3:0:0:1: Attached scsi generic sg3 type 0
[  120.660000] sd 3:0:0:1: [sds] Attached SCSI removable disk
[  120.710000]  sdq1
[  121.140000] iSCSI: init_io_buffer_head(833) LUN-backup: 512 buffers allocated, total 2097152 bytes successfully
[  121.150000] sd 2:0:0:0: [sdq] Assuming drive cache: write through
[  121.160000] sd 2:0:0:0: [sdq] Attached SCSI removable disk
[  126.910000] ata1.00: configured for UDMA/133
[  126.910000] ata1: EH complete
[  129.130000] warning: `nginx' uses 32-bit capabilities (legacy support in use)

Diskstation1 login: [  135.780000] kjournald starting.  Commit interval 5 seconds
[  135.820000] EXT3 FS on sdq1, internal journal
[  135.820000] EXT3-fs: mounted filesystem with ordered data mode.
[  142.050000] findhostd uses obsolete (PF_INET,SOCK_PACKET)
[  144.990000] init: syno_disk_latency_monitor faild on spawn stage, stopped
[  152.480000] eth0: link down
[  152.480000] eth0: link up, full duplex, speed 1 Gbps
[  158.100000] init: dhcp-client (eth0) main process (4499) killed by TERM signal
[  160.210000] init: nmbd main process (8115) killed by TERM signal
[  167.120000] init: dhcp-client (eth0) main process (8325) killed by TERM signal
[  211.050000] init: nmbd main process (10073) killed by TERM signal
[  245.170000] init: nmbd main process (11754) killed by TERM signal

Diskstation1 login: admin
Password: 
 -- admin: /var/services/homes/admin: change directory failed: No such file or directory
Logging in with home = "/".
admin@Diskstation1:/$ sudo -i
Password: 
                                                                                                                                                                                                                                                                                                                                root@Diskstation1:~# cat /proc/mtd
dev:    size   erasesize  name
mtd0: 00090000 00010000 "RedBoot"
mtd1: 00300000 00010000 "zImage"
mtd2: 00440000 00010000 "rd.gz"
mtd3: 00010000 00010000 "vendor"
mtd4: 00010000 00010000 "RedBoot Config"
mtd5: 00010000 00010000 "FIS directory"
mtd6: 00800000 00010000 "spi_flash"
root@Diskstation1:~# 
root@Diskstation1:~# dd if=/dev/mtd0 of=ds213.mtd0 bs=576k conv=sync
1+0 records in
1+0 records out
589824 bytes (590 kB) copied, 0.172444 s, 3.4 MB/s
root@Diskstation1:~# dd if=/dev/mtd1 of=ds213.mtd1 bs=3072k conv=sync
1+0 records in
1+0 records out
3145728 bytes (3.1 MB) copied, 0.928056 s, 3.4 MB/s
root@Diskstation1:~# dd if=/dev/mtd2 of=ds213.mtd2 bs=4352k conv=sync
1+0 records in
1+0 records out
4456448 bytes (4.5 MB) copied, 1.31712 s, 3.4 MB/s
root@Diskstation1:~# dd if=/dev/mtd3 of=ds213.mtd3 bs=64k conv=sync
1+0 records in
1+0 records out
65536 bytes (66 kB) copied, 0.0279568 s, 2.3 MB/s
root@Diskstation1:~# dd if=/dev/mtd4 of=ds213.mtd4 bs=64k conv=sync
1+0 records in
1+0 records out
65536 bytes (66 kB) copied, 0.0200228 s, 3.3 MB/s
root@Diskstation1:~# dd if=/dev/mtd5 of=ds213.mtd5 bs=64k conv=sync
1+0 records in
1+0 records out
65536 bytes (66 kB) copied, 0.0198252 s, 3.3 MB/s
root@Diskstation1:~# dd if=/dev/mtd6 of=ds213.mtd6 bs=8192k conv=sync
1+0 records in
1+0 records out
8388608 bytes (8.4 MB) copied, 2.47289 s, 3.4 MB/s
root@Diskstation1:~# 
root@Diskstation1:~# ls -l ds213.mtd?
-rw-r--r-- 1 root root  589824 Oct 11 09:47 ds213.mtd0
-rw-r--r-- 1 root root 3145728 Oct 11 09:47 ds213.mtd1
-rw-r--r-- 1 root root 4456448 Oct 11 09:48 ds213.mtd2
-rw-r--r-- 1 root root   65536 Oct 11 09:48 ds213.mtd3
-rw-r--r-- 1 root root   65536 Oct 11 09:48 ds213.mtd4
-rw-r--r-- 1 root root   65536 Oct 11 09:48 ds213.mtd5
-rw-r--r-- 1 root root 8388608 Oct 11 09:49 ds213.mtd6
root@Diskstation1:~# 
root@Diskstation1:~# ls -lh ds213.mtd?
-rw-r--r-- 1 root root 576K Oct 11 09:47 ds213.mtd0
-rw-r--r-- 1 root root 3.0M Oct 11 09:47 ds213.mtd1
-rw-r--r-- 1 root root 4.3M Oct 11 09:48 ds213.mtd2
-rw-r--r-- 1 root root  64K Oct 11 09:48 ds213.mtd3
-rw-r--r-- 1 root root  64K Oct 11 09:48 ds213.mtd4
-rw-r--r-- 1 root root  64K Oct 11 09:48 ds213.mtd5
-rw-r--r-- 1 root root 8.0M Oct 11 09:49 ds213.mtd6
root@Diskstation1:~# 
root@Diskstation1:~# 

Re: Bricked Synology DS213 (Kirkwood) so close
October 11, 2020 04:37PM
itangoii,

On the good box, you don't need to use kwboot. You can run minicom or picocom on your host Linux box as a normal serial console. And the box will automatically loads and runs u-boot in flash.

picocom --b 115200 --f n --p n --d 8 /dev/ttyUSB0

On the bricked box, you must load ds213.mtd0 with kwboot (it is the correct size of 576K).

Once you can start the bricked box with ds213.mtd0 image, it will run and count down, interrupt the count down and,

help
printenv
This is to see the behavior of the in-RAM u-boot while it is running. To see if we can flash the mtds backup files to SPI flash while it is running.

Let's take the issue of the size of the mtd files in a different post.

----
Edited: typos

-bodhi
===========================
Forum Wiki
bodhi's corner



Edited 1 time(s). Last edit at 10/11/2020 04:50PM by bodhi.
Re: Bricked Synology DS213 (Kirkwood) so close
October 11, 2020 04:47PM
The back up was successful. Each was verified the be the size we expected.

root@Diskstation1:~# ls -lh ds213.mtd?
-rw-r--r-- 1 root root 576K Oct 11 09:47 ds213.mtd0
-rw-r--r-- 1 root root 3.0M Oct 11 09:47 ds213.mtd1
-rw-r--r-- 1 root root 4.3M Oct 11 09:48 ds213.mtd2
-rw-r--r-- 1 root root  64K Oct 11 09:48 ds213.mtd3
-rw-r--r-- 1 root root  64K Oct 11 09:48 ds213.mtd4
-rw-r--r-- 1 root root  64K Oct 11 09:48 ds213.mtd5
-rw-r--r-- 1 root root 8.0M Oct 11 09:49 ds213.mtd6

The only number that was rounded up by the output is mtd2. So we use the other format to calculate the exact size:

-rw-r--r-- 1 root root 4456448 Oct 11 09:48 ds213.mtd2

4456448 /1024 = 4352 which is as expected.

-bodhi
===========================
Forum Wiki
bodhi's corner



Edited 1 time(s). Last edit at 10/11/2020 04:49PM by bodhi.
Re: Bricked Synology DS213 (Kirkwood) so close
October 11, 2020 04:55PM
bodhi Wrote:
-------------------------------------------------------
> The back up was successful. Each was verified the
> be the size we expected.
>
>
> root@Diskstation1:~# ls -lh ds213.mtd?
> -rw-r--r-- 1 root root 576K Oct 11 09:47
> ds213.mtd0
> -rw-r--r-- 1 root root 3.0M Oct 11 09:47
> ds213.mtd1
> -rw-r--r-- 1 root root 4.3M Oct 11 09:48
> ds213.mtd2
> -rw-r--r-- 1 root root  64K Oct 11 09:48
> ds213.mtd3
> -rw-r--r-- 1 root root  64K Oct 11 09:48
> ds213.mtd4
> -rw-r--r-- 1 root root  64K Oct 11 09:48
> ds213.mtd5
> -rw-r--r-- 1 root root 8.0M Oct 11 09:49
> ds213.mtd6
>
>
> The only number that was rounded up by the output
> is mtd2. So we use the other format to calculate
> the exact size:
>
>
> -rw-r--r-- 1 root root 4456448 Oct 11 09:48
> ds213.mtd2
>
>
> 4456448 /1024 = 4352 which is as expected.

Just making sure ;-)

So,

1. the good box can be booted with just an app listening on the serial port to do backups

2. Bricked box would be booted with kwboot and the backed up mtd0 that now resides on the USB with
./kwboot -t -B 115200 /dev/ttyUSB0 -b ds213.mtd0 -p

OK to proceed? And of course retrieve help and printenv if successful.
Re: Bricked Synology DS213 (Kirkwood) so close
October 11, 2020 06:16PM
itangoii,

> Just making sure ;-)

Yup! that's how hacking Linux should be. We take it slow and cross all the i's dot all the t's :)

> 1. the good box can be booted with just an app
> listening on the serial port to do backups

In fact, to do the back up you can also log into stock OS, if SSH is enable, and dump the mtds there. The serial console is to get the stock envs set so that it can be compared with the one in kwboot later.

Since you are the investigator, when you write the unbricking procedure at Synology forum for people to follow, you migh not need to describe how you get the mtds backup and the envs. It is up to you to judge if you want to include all info for the forum audience (i.e. level of techs need to understand).

What we do here we usually skip the beginner's steps such as creating Ext3 USB partition. And try not to explain too much (concise instruction avoids mistake).

> 2. Bricked box would be booted with kwboot and
> the backed up mtd0 that now resides on the USB
> with
> ./kwboot -t -B 115200 /dev/ttyUSB0 -b
> ds213.mtd0 -p

Yes.


> OK to proceed? And of course retrieve help and
> printenv if successful.

Sure. Please go ahead.

-bodhi
===========================
Forum Wiki
bodhi's corner



Edited 2 time(s). Last edit at 10/11/2020 06:22PM by bodhi.
Re: Bricked Synology DS213 (Kirkwood) so close
October 11, 2020 06:42PM
bodhi Wrote:
-------------------------------------------------------

>
> On the bricked box, you must load ds213.mtd0 with
> kwboot (it is the correct size of 576K).
>
> Once you can start the bricked box with ds213.mtd0
> image, it will run and count down, interrupt the
> count down and,
>

Well, I booted the good box and copied all the *mtd? over. I then tried kwboot with the mtd0 on the bricked one and as soon as
I plugged in the power it locked up the software. I also tried with picocom and same result. I do still have the debian boot usb if that will help see what's going on.
Re: Bricked Synology DS213 (Kirkwood) so close
October 11, 2020 07:03PM
> Well, I booted the good box and copied all the
> *mtd? over. I then tried kwboot with the mtd0 on
> the bricked one and as soon as
> I plugged in the power it locked up the software.

Please post the log of kwboot session.

-bodhi
===========================
Forum Wiki
bodhi's corner
Re: Bricked Synology DS213 (Kirkwood) so close
October 11, 2020 07:14PM
bodhi Wrote:
-------------------------------------------------------
> > Well, I booted the good box and copied all the
> > *mtd? over. I then tried kwboot with the mtd0
> on
> > the bricked one and as soon as
> > I plugged in the power it locked up the
> software.
>
> Please post the log of kwboot session.

I'm not sure how. I start kwboot with....

./kwboot -t -B 115200 /dev/ttyUSB0 -b ds213.mtd0 -p

I see the figure turning like a propeller and then turn the power on and it freezes.
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: