|
Re: revive Medion oxnas stg-212 April 04, 2023 04:46PM |
Admin Registered: 13 years ago Posts: 18,575 |
> Hit any key to stop autoboot: 0
setenv bootargs 'console=ttyS0,115200 earlyprintk=serial
OX820> ide reset OX820> ext2load ide 0:2 64000000 /owrt19/openwrt-19.07.5-oxnas-ox820-mitrastar_stg-212-initramfs-uImage OX820> bootm 64000000
|
Re: revive Medion oxnas stg-212 April 05, 2023 09:14AM |
Registered: 6 years ago Posts: 103 |
U-Boot SPL 2013.10-ga72eb8f-dirty (Feb 19 2014 - 15:21:12)
Boot device: SATA
Attempting to set PLLA to 800 MHz ...
plla_ctrl0 : 0000030a
plla_ctrl1 : 00400000
plla_ctrl2 : 007f0068
plla_ctrl3 : 00000193
PLLA Set
Bus 0: OK
Device 0:
reading bootargs.bin
reading u-boot.img
reading u-boot.img
U-Boot 2015.10-tld-2 (Oct 21 2017 - 22:00:02 -0700)
OXNAS OX820
DRAM: 128 MiB
NAND: 128 MiB
*** Warning - bad CRC, using default environment
In: serial
Out: serial
Err: serial
Net: dwmac.40400000
Hit any key to stop autoboot: 0
OX820> setenv bootargs 'console=ttyS0,115200 earlyprintk=serial'
OX820> ide reset
Reset IDE: Bus 0: OK
Device 0: Model: Crucial_CT275MX300SSD1 Firm: M0CR070 Ser#: 17251799E2D8
Type: Hard Disk
Supports 48-bit addressing
Capacity: 262321.6 MB = 256.1 GB (537234768 x 512)
OX820> ext2load ide 0:2 64000000 /owrt19/openwrt-19.07.5-oxnas-ox820-mitrastar_stg-212-initramfs-uImage
5698471 bytes read in 730 ms (7.4 MiB/s)
OX820> bootm 64000000
## Booting kernel from Legacy Image at 64000000 ...
Image Name: ARM OpenWrt Linux-4.14.209
Created: 2020-12-06 7:31:03 UTC
Image Type: ARM Linux Kernel Image (uncompressed)
Data Size: 5698407 Bytes = 5.4 MiB
Load Address: 60008000
Entry Point: 60008000
Verifying Checksum ... OK
Loading Kernel Image ... OK
Starting kernel ...
Edit: according to https://forum.doozan.com/read.php?4,86219 it seems "Starting kernel ..." means OpenWRT is started in RAM and accessible through LAN - that's what i'm trying next.|
Re: revive Medion oxnas stg-212 April 05, 2023 02:18PM |
Admin Registered: 13 years ago Posts: 18,575 |
|
Re: revive Medion oxnas stg-212 April 05, 2023 02:35PM |
Registered: 6 years ago Posts: 103 |
|
Re: revive Medion oxnas stg-212 April 05, 2023 02:48PM |
Admin Registered: 13 years ago Posts: 18,575 |
|
Re: revive Medion oxnas stg-212 April 05, 2023 02:56PM |
Registered: 6 years ago Posts: 103 |
|
Re: revive Medion oxnas stg-212 April 05, 2023 03:06PM |
Admin Registered: 13 years ago Posts: 18,575 |
|
Re: revive Medion oxnas stg-212 April 05, 2023 03:19PM |
Registered: 6 years ago Posts: 103 |
|
Re: revive Medion oxnas stg-212 April 05, 2023 03:35PM |
Registered: 6 years ago Posts: 103 |
Attempting to set PLLA to 725MHz ...
plla_ctrl0 : 0x0000011A
plla_ctrl1 : 0x003A0000
plla_ctrl2 : 0x007300D0
plla_ctrl3 : 0x000000B6
PLLA Set
Setup memory, testing
Reading disk 0, Image 0
Sector : 0x0000009A
Hdr len: 0x0001F854
Hdr CRC: 0x55B449B2
OK
Initialising disks
SATA PHY not ready for device 1
Detecting SATA busses:
Bus 0: Found first device OK
Device 0: Model: CT1000MX500SSD1 Firm: M3CR032 Ser#: 2037E4AF3A94
Type: Hard Disk
Capacity: 131071.9 MB = 127.9 GB (268435455 x 512)
Device 1: not available
Failed to read valid environment from disk, using built-in default
U-Boot 1.1.2 (Dec 30 2011 - 14:55:54)
U-Boot code: 60D00000 -> 60D1F854 BSS: -> 60D24074
RAM Configuration:
Bank #0: 60000000 128 MB
SRAM Configuration:
64KB at 0x50000000
NAND:128 MiB
*** Warning - bad CRC, using default environment
In: serial
Out: serial
Err: serial
Setting Linux mem= boot arg value
IDE read: device 0 block # 288, count 1 ... 1 blocks read: OK
Hit any key to stop autoboot: 0
IDE device 0: Model: CT1000MX500SSD1 Firm: M3CR032 Ser#: 2037E4AF3A94
Type: Hard Disk
Capacity: 131071.9 MB = 127.9 GB (268435455 x 512)
... is now current device
IDE read: device 0 block # 1290, count 10152 ... 10152 blocks read: OK
## Booting image at 60500000 ...
Bad Magic Number
IDE device 0: Model: CT1000MX500SSD1 Firm: M3CR032 Ser#: 2037E4AF3A94
Type: Hard Disk
Capacity: 131071.9 MB = 127.9 GB (268435455 x 512)
... is now current device
IDE read: device 0 block # 58344, count 10152 ... 10152 blocks read: OK
## Booting image at 60500000 ...
Bad Magic Number
Light LED
IDE device 1: not available
Light LED
IDE device 1: not available
Unknown command 'lightled' - try 'help'
$ printenv bootcmd=run select0 load boot || run select0 load2 boot || run lightled select1 load extinguishled boot || run lightled select1 load2 extinguishled boot || lightled bootdelay=2 baudrate=115200 ethaddr=00:30:e0:00:00:01 ipaddr=192.168.50.100 serverip=192.168.50.59 autoload=n netmask=255.255.0.0 bootfile="uImage" select0=ide dev 0 select1=ide dev 1 load=ide read 0x60500000 50a 27a8 load2=ide read 0x60500000 e3e8 27a8 lightled=ledfail 1 extinguishled=ledfail 0 boot=bootm 60500000 stdin=serial stdout=serial stderr=serial bootargs=root=/dev/sda1 console=ttyS0,115200 elevator=cfq mac_adr=0x00,0x30,0xe0,0x00,0x00,0x01 mem=128M poweroutage=yes Environment size: 644/8188 bytes
$ help ? - alias for 'help' base - print or set address offset bdinfo - print Board Info structure bootm - boot application image from memory bootp - boot image via network using BootP/TFTP protocol cmp - memory compare cp - memory copy crc32 - checksum calculation diskboot- boot from IDE device echo - echo args to console exit - exit script ext2load- load binary file from a Ext2 filesystem ext2ls- list files in a directory (default /) go - start application at address 'addr' help - print online help ide - IDE sub-system iminfo - print header information for application image ledfail - Extinguish (0) or light (1) failure LED loop - infinite loop on address range md - memory display mm - memory modify (auto-incrementing) mtest - simple RAM test mw - memory write (fill) nand - NAND sub-system nboot - boot from NAND device nm - memory modify (constant address) nwboot - NAND Write boot information ping - send ICMP ECHO_REQUEST to network host printenv- print environment variables rarpboot- boot image via network using RARP/TFTP protocol reset - Perform RESET of the CPU run - run commands in an environment variable saveenv - save environment variables to persistent storage setenv - set environment variables test - minimal test like /bin/sh tftpboot- boot image via network using TFTP protocol version - print monitor version
|
Re: revive Medion oxnas stg-212 April 05, 2023 04:13PM |
Admin Registered: 13 years ago Posts: 18,575 |
Quote
> IDE device 0: Model: CT1000MX500SSD1 Firm:
> M3CR032 Ser#: 2037E4AF3A94
> Type: Hard Disk
> Capacity: 131071.9 MB = 127.9 GB
|
Re: revive Medion oxnas stg-212 April 05, 2023 04:32PM |
Registered: 6 years ago Posts: 103 |
$ ide reset Reset IDE: $for sure the old original u-boot is very very limited in its possibilities!
|
Re: revive Medion oxnas stg-212 April 05, 2023 04:43PM |
Admin Registered: 13 years ago Posts: 18,575 |
> Attempting to set PLLA to 725MHz ...and stock u-boot was running
> U-Boot 1.1.2 (Dec 30 2011 - 14:55:54)
|
Re: revive Medion oxnas stg-212 April 05, 2023 05:20PM |
Registered: 6 years ago Posts: 103 |
|
Re: revive Medion oxnas stg-212 April 05, 2023 05:37PM |
Admin Registered: 13 years ago Posts: 18,575 |
Quote
In serial console, you'd flash stock u-boot to NAND and then do a reset. It should boot to that u-boot. Once you ar there, you are in a better shape. Because, from there you can install OpenWrt using their procedure. Or try to boot Debian on USB.
Let's make that an itermediate unbrick goal. Find the STG-212 stock mtd0 backup, and I'll help you flash it.
Quote
Wiki thread
Unbrick a Pogoplug Pro v3 OXNAS by flashing u-boot in serial console
https://forum.doozan.com/read.php?3,42599,44024#msg-44024
|
Re: revive Medion oxnas stg-212 April 05, 2023 05:55PM |
Registered: 6 years ago Posts: 103 |
Quote
Wiki thread
>
> Unbrick a Pogoplug Pro v3 OXNAS by flashing u-boot
> in serial console
>
> https://forum.doozan.com/read.php?3,42599,44024#msg-44024
>
|
Re: revive Medion oxnas stg-212 April 05, 2023 06:04PM |
Admin Registered: 13 years ago Posts: 18,575 |
ls -lh
nand
|
Re: revive Medion oxnas stg-212 April 05, 2023 06:07PM |
Admin Registered: 13 years ago Posts: 18,575 |
echo "Adding MTD1 data (stage1)"
dd if=mtd1.backup of=$device bs=512 seek=1024 bs=512 conv=notrunc status=noxfer &>/dev/null || {
echo "Failed to write disk"
exit 1
}
echo "Adding MTD2 data (NAND U-Boot)"
dd if=mtd2.backup of=$device bs=512 seek=1536 bs=512 conv=notrunc status=noxfer &>/dev/null || {
echo "Failed to write disk"
exit 1
}
echo "Adding MTD3 data (U-Boot Environment)"
dd if=mtd3.bin of=$device bs=512 seek=8704 bs=512 conv=notrunc status=noxfer &>/dev/null || {
echo "Failed to write disk"
exit 1
}
|
Re: revive Medion oxnas stg-212 April 05, 2023 06:11PM |
Admin Registered: 13 years ago Posts: 18,575 |
uboot.spl.2013.10.ox820.850mhz.mtd0.img uboot.2015.10-tld-2.ox820.mtd0.img uboot.2015.10-tld-2.ox820.environment.img
|
Re: revive Medion oxnas stg-212 April 05, 2023 06:35PM |
Registered: 6 years ago Posts: 103 |
root@Aspire-3820TG:~# ls -lh /media/alex/rootfs/boot/mtd/ insgesamt 118M -rw-r--r-- 1 root root 256K Apr 6 01:28 mtd1.backup -rw-r--r-- 1 root root 3,5M Apr 6 01:28 mtd2.backup -rw-r--r-- 1 root root 8,0K Apr 6 01:28 mtd3.data -rw-r--r-- 1 root root 10M Apr 6 01:28 mtd4.backup -rw-r--r-- 1 root root 10M Apr 6 01:28 mtd6.backup -rw-r--r-- 1 root root 94M Apr 6 01:28 mtd7.backup
OX820> nand
nand - NAND sub-system
Usage:
nand info - show available NAND devices
nand device [dev] - show or set current device
nand read - addr off|partition size
nand write - addr off|partition size
read/write 'size' bytes starting at offset 'off'
to/from memory address 'addr', skipping bad blocks.
nand read.raw - addr off|partition [count]
nand write.raw - addr off|partition [count]
Use read.raw/write.raw to avoid ECC and access the flash as-is.
nand erase[.spread] [clean] off size - erase 'size' bytes from offset 'off'
With '.spread', erase enough for given file size, otherwise,
'size' includes skipped bad blocks.
nand erase.part [clean] partition - erase entire mtd partition'
nand erase.chip [clean] - erase entire chip'
nand bad - show bad blocks
nand dump[.oob] off - dump page
nand scrub [-y] off size | scrub.part partition | scrub.chip
really clean NAND erasing bad blocks (UNSAFE)
nand markbad off [...] - mark bad block(s) at offset (UNSAFE)
nand biterr off - make a bit error at offset (UNSAFE)
|
Re: revive Medion oxnas stg-212 April 05, 2023 06:39PM |
Registered: 6 years ago Posts: 103 |
|
Re: revive Medion oxnas stg-212 April 05, 2023 06:51PM |
Registered: 6 years ago Posts: 103 |
U-Boot SPL 2013.10-ga72eb8f-dirty (Feb 19 2014 - 15:21:12)
Boot device: SATA
Attempting to set PLLA to 800 MHz ...
plla_ctrl0 : 0000030a
plla_ctrl1 : 00400000
plla_ctrl2 : 007f0068
plla_ctrl3 : 00000193
PLLA Set
Bus 0: OK
Device 0:
reading bootargs.bin
reading u-boot.img
reading u-boot.img
U-Boot 2015.10-tld-2 (Oct 21 2017 - 22:00:02 -0700)
OXNAS OX820
DRAM: 128 MiB
NAND: 128 MiB
In: serial
Out: serial
Err: serial
Net: dwmac.40400000
Hit any key to stop autoboot: 0
OX820> ide reset
Reset IDE: Bus 0: OK
Device 0: Model: Crucial_CT275MX300SSD1 Firm: M0CR070 Ser#: 17251799E2D8
Type: Hard Disk
Supports 48-bit addressing
Capacity: 262321.6 MB = 256.1 GB (537234768 x 512)
OX820> ext2ls ide 0:2 /uboot
<DIR> 4096 .
<DIR> 4096 ..
545676 openwrt-oxnas-ox820-u-boot.bin
524288 uboot.2015.10-tld-2.ox820.mtd0.img
131072 uboot.spl.2013.10.ox820.850mhz.mtd0.img
2636 uboot.2015.10-tld-2.ox820.environment
131072 uboot.2015.10-tld-2.ox820.environment.img
131072 uboot.spl.2013.10.ox820.mtd0.img
524288 uboot.2013.10-tld-3.ox820.mtd0.img
131072 pogopro_uboot_env.img
OX820> nand erase 0x0 0xC0000
NAND erase: device 0 offset 0x0, size 0xc0000
Erasing at 0xa0000 -- 100% complete.
OK
OX820> ext2load ide 0:2 0x800000 /uboot/uboot.spl.2013.10.ox820.mtd0.img
131072 bytes read in 23 ms (5.4 MiB/s)
OX820> nand write 0x800000 0x0 0x20000
NAND write: device 0 offset 0x0, size 0x20000
131072 bytes written: OK
OX820> ext2load ide 0:2 0x800000 /uboot/uboot.2015.10-tld-2.ox820.mtd0.img
524288 bytes read in 71 ms (7 MiB/s)
OX820> nand write 0x800000 0x40000 0x80000
NAND write: device 0 offset 0x40000, size 0x80000
524288 bytes written: OK
OX820> nand erase 0x100000 0x20000
NAND erase: device 0 offset 0x100000, size 0x20000
Erasing at 0x100000 -- 100% complete.
OK
OX820> ext2load ide 0:2 0x800000 /uboot/uboot.2015.10-tld-2.ox820.environment.img
131072 bytes read in 22 ms (5.7 MiB/s)
OX820> nand write 0x800000 0x100000 0x20000
NAND write: device 0 offset 0x100000, size 0x20000
131072 bytes written: OK
I took older uboot.spl.2013.10.ox820.mtd0.img as i read that overclocked spl may force trouble on stg-212.
|
Re: revive Medion oxnas stg-212 April 05, 2023 06:55PM |
Admin Registered: 13 years ago Posts: 18,575 |
|
Re: revive Medion oxnas stg-212 April 05, 2023 06:58PM |
Admin Registered: 13 years ago Posts: 18,575 |
-rw-r--r-- 1 root root 256K Apr 6 01:28 mtd1.backup -rw-r--r-- 1 root root 3,5M Apr 6 01:28 mtd2.backup -rw-r--r-- 1 root root 8,0K Apr 6 01:28 mtd3.data
|
Re: revive Medion oxnas stg-212 April 05, 2023 07:02PM |
Registered: 6 years ago Posts: 103 |
> -rw-r--r-- 1 root root 256K Apr 6 01:28 > mtd1.backup > -rw-r--r-- 1 root root 3,5M Apr 6 01:28 > mtd2.backup > -rw-r--r-- 1 root root 8,0K Apr 6 01:28 > mtd3.data >>
echo "Generating NAND U-Boot Environment" # Sector Starts (all values in HDD sectors) # MTD1 => 1024 # MTD2 => 1024 + MTD1Size # => 1536 # MTD3 => 1024 + MTD1Size + MTD2Size # => 8704 # MTD4 => 1024 + MTD1Size + MTD2Size + MTD3Size # => 9728 # MTD6 => 1024 + MTD1Size + MTD2Size + MTD3Size + MTD4Size # => 30208 # MTD7 => 1024 + MTD1Size + MTD2Size + MTD3Size + MTD4Size + MTD6Size # => 50688 # MTD1Size = 512 # MTD2Size = 7168 # MTD3Size = 1024 # MTD4Size = 20480 # MTD6Size = 20480 # MTD7Size = 192000i guess not, as they state that values are hdd sectors...
|
Re: revive Medion oxnas stg-212 April 05, 2023 07:02PM |
Admin Registered: 13 years ago Posts: 18,575 |
&nandc {
status = "okay";
pinctrl-names = "default";
pinctrl-0 = <&pinctrl_nand>;
nand@0 {
reg = <0>;
#address-cells = <1>;
#size-cells = <1>;
nand-ecc-mode = "soft";
nand-ecc-algo = "hamming";
partition@0 {
label = "stage1";
reg = <0x00000000 0x00040000>;
};
partition@40000 {
label = "u-boot";
reg = <0x00040000 0x00380000>;
};
partition@3c0000 {
label = "u-boot-env";
reg = <0x003c0000 0x00080000>;
};
|
Re: revive Medion oxnas stg-212 April 05, 2023 07:20PM |
Registered: 6 years ago Posts: 103 |
OX820> ext2load ide 0:2 0x800000 /boot/mtd/mtd1.backup 262144 bytes read in 46 ms (5.4 MiB/s) OX820> nand write 0x800000 0x00000000 0x00040000 OX820> ext2load ide 0:2 0x800000 /boot/mtd/mtd2.backup 262144 bytes read in 46 ms (5.4 MiB/s) OX820> nand write 0x800000 0x00040000 0x00380000 OX820> ext2load ide 0:2 0x800000 /boot/mtd/mtd3.data 262144 bytes read in 46 ms (5.4 MiB/s) OX820> nand write 0x800000 0x003c0000 0x00080000then?
OX820> nand write 0x800000 0x00040000 0x00380000 NAND write: device 0 offset 0x40000, size 0x380000keeps hanging...
|
Re: revive Medion oxnas stg-212 April 05, 2023 07:26PM |
Admin Registered: 13 years ago Posts: 18,575 |
nand erase 0x0 0x00040000 ext2load ide 0:2 0x800000 mtd1.backup nand write 0x800000 0x0 0x00040000
nand erase 0x00040000 0x00380000 ext2load ide 0:2 0x800000 mtd2.backup nand write 0x800000 0x00040000 0x00380000
nand erase 0x3c0000 0x00080000 ext2load ide 0:2 0x800000 mtd3.data nand write 0x800000 0x3c0000 0x00080000
|
Re: revive Medion oxnas stg-212 April 05, 2023 07:31PM |
Registered: 6 years ago Posts: 103 |
> nand erase 0x00040000 0x00380000 > ext2load ide 0:2 0x800000 mtd2.backup > nand write 0x800000 0x00040000 0x00380000 >still hangs here. shouldn't take ages writing 3,5M to NAND!? :-(
OX820> nand erase.chip NAND erase.chip: device 0 whole chip Skipping bad block at 0x07b20000 Erasing at 0x7fe0000 -- 100% complete. OK
|
Re: revive Medion oxnas stg-212 April 05, 2023 07:48PM |
Admin Registered: 13 years ago Posts: 18,575 |
> OX820> nand erase.chip > > NAND erase.chip: device 0 whole chip > Skipping bad block at 0x07b20000 > > Erasing at 0x7fe0000 -- 100% complete. > OK >
|
Re: revive Medion oxnas stg-212 April 05, 2023 07:52PM |
Admin Registered: 13 years ago Posts: 18,575 |