Welcome! Log In Create A New Profile

Advanced

Debian on Synology RS816 (Armada 385)

Posted by zifxify 
Re: Debian on Synology RS816 (Armada 385)
December 31, 2020 06:05PM
In order not to lose:

Marvell>> printenv
CASset=max
MALLOC_len=5
MPmode=SMP
ata_hdd_enable=syno_hdd_enable=15
autoload=no
baudrate=115200
boot_order=hd_scr usb_scr mmc_scr hd_img usb_img mmc_img pxe net_img net_scr
bootargs=
bootargs_dflt=$console $nandEcc $mtdparts_lgcy $bootargs_root nfsroot=$serverip:$rootpath ip=$ipaddr:$serverip$bootargs_end $mvNetConfig video=dovefb:lcd0:$lcd0_params clcd.lcd0_enable=$lcd0_enable clcd.lcd_panel=$lcd_panel
bootargs_end=:10.4.50.254:255.255.255.0:Armada38x:eth0:none
bootargs_root=root=/dev/nfs rw
bootcmd=mw 0xf10a2620 0x251;mw 0xf10a2e20 0x251;usb xhciinit; run bootspi
bootcmd_auto=stage_boot $boot_order
bootcmd_fdt=tftpboot 0x2000000 $image_name;tftpboot $fdtaddr $fdtfile;setenv bootargs $console $nandEcc $mtdparts $bootargs_root nfsroot=$serverip:$rootpath ip=$ipaddr:$serverip$bootargs_end $mvNetConfig video=dovefb:lcd0:$lcd0_params clcd.lcd0_enable=$lcd0_enable clcd.lcd_panel=$lcd_panel; bootz 0x2000000 - $fdtaddr;
bootcmd_fdt_boot=tftpboot 0x2000000 $image_name; setenv bootargs $console $nandEcc $mtdparts $bootargs_root nfsroot=$serverip:$rootpath ip=$ipaddr:$serverip$bootargs_end $mvNetConfig video=dovefb:lcd0:$lcd0_params clcd.lcd0_enable=$lcd0_enable clcd.lcd_panel=$lcd_panel; bootz 0x2000000 - $fdtaddr;
bootcmd_fdt_edit=tftpboot $fdtaddr $fdtfile; fdt addr $fdtaddr; setenv bootcmd $bootcmd_fdt_boot
bootcmd_lgcy=tftpboot 0x2000000 $image_name;setenv bootargs $console $nandEcc $mtdparts_lgcy $bootargs_root nfsroot=$serverip:$rootpath ip=$ipaddr:$serverip$bootargs_end  video=dovefb:lcd0:$lcd0_params clcd.lcd0_enable=$lcd0_enable clcd.lcd_panel=$lcd_panel;  bootm $loadaddr;
bootdelay=3
bootftp=run syno_bootargs;tftpboot $loadaddr_kernel $file_kernel;tftpboot $loadaddr_rootfs $file_rootfs;sf probe; sf read $loadaddr_dt $spi_pt_addr_dt $spi_pt_size_dt;fdt addr $loadaddr_dt;bootm $loadaddr_kernel $loadaddr_rootfs $loadaddr_dt;
bootspi=run syno_bootargs;sf probe 0 50000000;sf read $loadaddr_kernel $spi_pt_addr_kernel $spi_pt_size_kernel;sf read $loadaddr_rootfs $spi_pt_addr_rootfs $spi_pt_size_rootfs;sf read $loadaddr_dt $spi_pt_addr_dt $spi_pt_size_dt;bootm $loadaddr_kernel $loadaddr_rootfs $loadaddr_dt;
cacheShare=no
clean_env=sf probe; sf erase $spi_pt_addr_env $spi_pt_size_env;
console=console=ttyS0,115200
device_partition=0:1
disaMvPnp=no
eeeEnable=no
enaClockGating=no
enaCpuStream=no
enaFPU=yes
enaMonExt=no
enaWrAllo=no
eth1addr=00:50:43:78:0b:26
eth1mtu=1500
eth2addr=00:50:43:78:c6:26
eth2mtu=1500
eth3addr=00:50:43:0b:c6:78
eth3mtu=1500
ethact=egiga0
ethaddr=00:50:43:c6:0b:26
ethmtu=1500
ethprime=egiga0
fdt_addr=2040000
fdt_skip_update=yes
fdtaddr=0x1000000
fdtfile=armada-38x.dtb
file_flash=armada38x/flash.bin
file_kernel=armada38x/uImage
file_rootfs=armada38x/rd.bin
file_uboot=armada38x/uboot.bin
ide_path=/
image_name=uImage
initrd_high=8000000
initrd_name=uInitrd
kernel_addr_r=2080000
lcd0_enable=0
lcd0_params=640x480-16@60
lcd_panel=0
limit_dram_size=yes
loadaddr=0x02000000
loadaddr_dt=0x1000000
loadaddr_kernel=0x2000000
loadaddr_rootfs=0x3000000
loads_echo=0
mtdids=spi0=spi_flash
mtdparts=mtdparts=spi0.0:4m(boot),-(spi-rootfs)
mtdparts_lgcy=mtdparts=spi_flash:4m(boot),-(spi-rootfs)
mvNetConfig=mv_net_config=4,(00:50:43:11:11:11,0:1:2:3),mtu=1500
mv_pon_addr=00:50:43:26:c6:78
netbsd_en=no
netretry=no
pcieTune=no
pexMode=RC
pxe_files_load=:default.arm-armadaxp-db:default.arm-armadaxp:default.arm
pxefile_addr_r=3100000
ramdisk_addr_r=2880000
rootpath=/srv/nfs/
run_script=no
sata_delay_reset=0
sata_dma_mode=yes
script_addr_r=3000000
script_name=boot.scr
sd_detection_dat3=no
spi_pt_addr_dt=0x0E0000
spi_pt_addr_env=0x7e0000
spi_pt_addr_kernel=0x0F0000
spi_pt_addr_rootfs=0x3C0000
spi_pt_size_dt=0x010000
spi_pt_size_env=0x010000
spi_pt_size_kernel=0x2D0000
spi_pt_size_rootfs=0x410000
standalone=fsload 0x2000000 $image_name;setenv bootargs $console $nandEcc $mtdparts_lgcy root=/dev/mtdblock0 rw ip=$ipaddr:$serverip$bootargs_end; bootm 0x2000000;
stderr=serial
stdin=serial
stdout=serial
syno_boot_dev=/dev/sda1
syno_bootargs=setenv bootargs console=ttyS0,115200 ip=off initrd=$loadaddr_rootfs root=$syno_boot_dev rw $syno_extra_args syno_hw_version=$syno_hw_version hd_power_on_seq=$syno_hdd_powerup_seq ihd_num=$syno_hdd_powerup_seq netif_num=$syno_net_if_num $ata_hdd_detect $ata_hdd_enable flash_size=8
syno_hdd_powerup_seq=1
syno_hw_version=DS116
syno_net_if_num=1
upd_flash=setenv tftpfile $file_flash; tftpboot $loadaddr $tftpfile; if test $? -eq 0; then echo "This may take a while, please be patient..."; sf probe; sf erase 0 +$filesize; sf write $loadaddr 0 $filesize; echo "\
Flash Update Done"; fi;
upd_kernel=setenv tftpfile $file_kernel; mw.b $loadaddr 0xFF $spi_pt_size_kernel; tftpboot $loadaddr $tftpfile; if test $? -eq 0; then sf probe; sf erase $spi_pt_addr_kernel $spi_pt_size_kernel; sf write $loadaddr $spi_pt_addr_kernel $spi_pt_size_kernel; echo "\
Kernel Update Done"; fi;
upd_rootfs=setenv tftpfile $file_rootfs; mw.b $loadaddr 0xFF $spi_pt_size_rootfs; tftpboot $loadaddr $tftpfile; if test $? -eq 0; then sf probe; sf erase $spi_pt_addr_rootfs +$filesize; sf write $loadaddr $spi_pt_addr_rootfs $filesize; echo "\
Rootfs Update Done"; fi;
upd_uboot=setenv tftpfile $file_uboot; tftpboot $loadaddr $tftpfile; if test $? -eq 0; then sf probe; sf erase 0 +$filesize; sf write $loadaddr 0 $filesize; echo "\
Uboot Update Done"; fi;
usb0Mode=host
usbActive=0
usbType=2
vxworks_en=no
yuk_ethaddr=00:00:00:EE:51:81

Environment size: 5631/65532 bytes

root@debian:/# fw_printenv
Warning: Bad CRC, using default environment
bootcmd=run distro_bootcmd
bootdelay=2
baudrate=115200
stdin=serial,cros-ec-keyb,usbkbd
stdout=serial,vidconsole
stderr=serial,vidconsole
ethaddr=00:00:11:22:33:44
eth1addr=00:00:11:22:33:45
eth3addr=00:00:11:22:33:46
eth5addr=00:00:11:22:33:47
ipaddr=1.2.3.4
host_boot=if host dev ${devnum}; then setenv devtype host; run scan_dev_for_boot_part; fi
sata_boot=if sata dev ${devnum}; then setenv devtype sata; run scan_dev_for_boot_part; fi
scsi_init=if ${scsi_need_init}; then setenv scsi_need_init false; scsi scan; fi
scsi_boot=run scsi_init; if scsi dev ${devnum}; then setenv devtype scsi; run scan_dev_for_boot_part; fi
virtio_boot=if virtio dev ${devnum}; then setenv devtype virtio; run scan_dev_for_boot_part; fi
boot_prefixes=/ /boot/
boot_scripts=boot.scr.uimg boot.scr
boot_script_dhcp=boot.scr.uimg
boot_targets=host1 host0
boot_syslinux_conf=extlinux/extlinux.conf
boot_extlinux=sysboot ${devtype} ${devnum}:${distro_bootpart} any ${scriptaddr} ${prefix}${boot_syslinux_conf}
scan_dev_for_extlinux=if test -e ${devtype} ${devnum}:${distro_bootpart} ${prefix}${boot_syslinux_conf}; then echo Found ${prefix}${boot_syslinux_conf}; run boot_extlinux; echo SCRIPT FAILED: continuing...; fi
boot_a_script=load ${devtype} ${devnum}:${distro_bootpart} ${scriptaddr} ${prefix}${script}; source ${scriptaddr}
scan_dev_for_scripts=for script in ${boot_scripts}; do if test -e ${devtype} ${devnum}:${distro_bootpart} ${prefix}${script}; then echo Found U-Boot script ${prefix}${script}; run boot_a_script; echo SCRIPT FAILED: continuing...; fi; done
scan_dev_for_boot=echo Scanning ${devtype} ${devnum}:${distro_bootpart}...; for prefix in ${boot_prefixes}; do run scan_dev_for_extlinux; run scan_dev_for_scripts; done;
scan_dev_for_boot_part=part list ${devtype} ${devnum} -bootable devplist; env exists devplist || setenv devplist 1; for distro_bootpart in ${devplist}; do if fstype ${devtype} ${devnum}:${distro_bootpart} bootfstype; then run scan_dev_for_boot; fi; done
bootcmd_host1=setenv devnum 1; run host_boot
bootcmd_host0=setenv devnum 0; run host_boot
distro_bootcmd=setenv scsi_need_init; for target in ${boot_targets}; do run bootcmd_${target}; done
bootm_size=0x10000000
kernel_addr_r=0x1000000
fdt_addr_r=0xc00000
ramdisk_addr_r=0x2000000
scriptaddr=0x1000
pxefile_addr_r=0x2000
root@debian:/#



Edited 2 time(s). Last edit at 12/31/2020 06:48PM by bonk1990.
Re: Debian on Synology RS816 (Armada 385)
December 31, 2020 06:14PM
Steps 2.b

root@debian:~# fdisk /dev/sdb

Welcome to fdisk (util-linux 2.33.1).
Changes will remain in memory only, until you decide to write them.
Be careful before using the write command.

Device does not contain a recognized partition table.
Created a new DOS disklabel with disk identifier 0x6e5f77a4.

Command (m for help): g
Created a new GPT disklabel (GUID: 7004DF3A-A8B9-534A-9967-87A85CCB7697).

Command (m for help): n
Partition number (1-128, default 1):
First sector (2048-62533262, default 2048): 102400
Last sector, +/-sectors or +/-size{K,M,G,T,P} (102400-62533262, default 62533262):

Created a new partition 1 of type 'Linux filesystem' and of size 29.8 GiB.

Command (m for help): w
The partition table has been altered.
Calling ioctl() to re-read parti[  295.530662][ T3075]  sdb: sdb1
tion table.
Syncing disks.

root@debian:~#

Re: Debian on Synology RS816 (Armada 385)
December 31, 2020 06:21PM
Steps 3.c

root@debian:/# cd /media/sdb1/boot
root@debian:/media/sdb1/boot# dd if=uImage of=/dev/sdb bs=1MiB seek=10
4+1 records in
4+1 records out
5075485 bytes (5.1 MB, 4.8 MiB) copied, 0.0292306 s, 174 MB/s
root@debian:/media/sdb1/boot# dd if=uInitrd of=/dev/sdb bs=1MiB seek=20
9+1 records in
9+1 records out
9488618 bytes (9.5 MB, 9.0 MiB) copied, 0.0482732 s, 197 MB/s
root@debian:/media/sdb1/boot# sync
root@debian:/# umount /media/sdb1
root@debian:/# e2fsck /dev/sdb1
e2fsck 1.44.5 (15-Dec-2018)
rootfs: clean, 24099/1954064 files, 341006/7803857 blocks
root@debian:/#

But with this steps there is problem with:
[....] Starting OpenBSD Secure Shell server: sshd

Do you need a log with updating kernel as well?



Edited 1 time(s). Last edit at 12/31/2020 06:25PM by bonk1990.
Re: Debian on Synology RS816 (Armada 385)
January 01, 2021 04:01PM
bonk1990,

Thanks!

> Steps 3.c

> But with this steps there is problem with:
>
> [....] Starting OpenBSD Secure Shell server: sshd
>

That's OK. it should occur only if an SSD is used for rootfs.

> Do you need a log with updating kernel as well?

Yes, not crucial, but would be nice. That would be a post that we can refer to at the end of the installation.

-bodhi
===========================
Forum Wiki
bodhi's corner (buy bodhi a beer)
Re: Debian on Synology RS816 (Armada 385)
January 01, 2021 08:14PM
RS816/DS116 Installation Instruction Part II


II. Installion with HDD rootfs.

Credits:

- The draft instruction was written by richjn.
- Thanks eine for the original steps to install kernel images on HDD raw sectors.
- Thanks jdwl101 for another installation example on HDD raw sectors.
- Thanks bonk1990 for doing all the testing for this instruction.


Prerequisites:

a. All HDD drives must be removed from the RS816/DS116 when starting the installation.
b. Serial console must be connected during installation.
c. All installation steps must be performed while login as root (sudo will not work).


Steps:


1. Log in as root.

On another Linux box, or boot the RS816/DS116 into Debian USB rootfs (if you have installed it and running this box on USB).

2. Prepare the HDD

If installation is peformed on this box (running Debian USB rootfs), then insert the HDD into the 1st slot. If using another Linux box, then use USB adapter to connect it (if it does not have SATA slot).

Assuming this HDD is assigned as /dev/sdb. For sanity, use the mount command to list all mount points, and observe that the HDD was not mounted automatically. If it was mounted automatically then umount it.

Be extra careful here if using another Linux box to prepare the HDD. Ensure to see the disk you will wipe out is /dev/sdb. If the HDD drive was assigned a different drive letter, then adjust the drive letter accordingly in the next step and all following steps.

2.a. Zero out the first 50MiB of the HDD
dd if=/dev/zero of=/dev/sdb bs=1MiB count=50

2.b. Create a single partition that starts at 50MiB using fdisk. Below is the proper way to create a GPT partition at 50MiB on a large HDD:

fdisk /dev/sdb
Command (m for help): g
Command (m for help): n
Partition number (1-128, default 1):
First sector (2048-62533262, default 2048): 102400
Last sector, +/-sectors or +/-size{K,M,G,T,P} (102400-62533262, default 62533262):
Command (m for help): w

(Partition number and Last sector values are default).

This partition will become /dev/sdb1.

3. Create the rootfs on HDD

3.a. Format this partition with ext3 (or ext4), and label it rootfs.
mkfs.ext3 -L rootfs /dev/sdb1

Note: If Ext4 was used, then the partition must be "finalized" immediately (lazy_itable_init=0).


3.b. Install the rootfs Debian-5.2.9-mvebu-tld-1-rootfs-bodhi.tar.bz2 on this partition (see this thread for download link).

Note: if installing on DS116 then replace the DTB name armada-385-synology-rs816.dtb with armada-385-synology-ds116.dtb.
mount /dev/sdb1 /media/sdb1
cd /media/sdb1
tar -xjf Debian-5.2.9-mvebu-tld-1-rootfs-bodhi.tar.bz2
sync
cd /media/sdb1/boot
cp -a zImage-5.2.9-mvebu-tld-1 zImage.fdt 
cat dts/armada-385-synology-rs816.dtb  >> zImage.fdt
mkimage -A arm -O linux -T kernel -C none -a 0x00008000 -e 0x00008000 -n Linux-5.2.9-mvebu-tld-1 -d zImage.fdt uImage
sync

3.c. Write uImage and uInitrd to raw sectors.

cd /media/sdb1/boot
dd if=uImage of=/dev/sdb bs=1MiB seek=10
dd if=uInitrd of=/dev/sdb bs=1MiB seek=20
sync

If it is prepared on the RS816/DS116 then shutdown the box. If the HHD is prepared on another Linux box then unmount it.

4. Booting with the HDD rootfs

Note that if an SDD is used in this rootfs installation (instead of spinning rust HDD), it will take a long time to build up entropy in this kernel version and therefore Debian booting will be delayed for several minutes by OpenSSH. With HDD rootfs, it should be faster. To help making it boot as fast as it can, you can plug in a non-rootfs USB drive, or a USB gadget at this point.

Attach the prepared HDD rootfs to the box 1st SATA slot. And remove any attached USB rootfs drive. Power up, interrupt u-boot at countdown. And execute

setenv load_image_addr 0x02000000
setenv load_initrd_addr 0x3000000
setenv load_image 'echo loading uImage from raw HDD ...; scsi device 0; scsi read $load_image_addr 0x5000 0x2F00'
setenv load_initrd 'echo loading uInitrd from raw HDD ...; scsi device 0; scsi read $load_initrd_addr 0xA000 0x4F00'
setenv set_bootargs 'setenv bootargs "console=ttyS0,115200 root=LABEL=rootfs rootdelay=10 $mtdparts earlyprintk=serial"'
setenv bootcmd_exec 'echo Booting Debian ...; run set_bootargs; setenv fdt_skip_update yes; setenv initrd_high 0xffffffff; run load_image; run load_initrd; bootm $load_image_addr $load_initrd_addr'
setenv bootcmd 'scsi init; run bootcmd_exec; echo Booting Stock OS ...; run bootspi'

DS116 Note: if the installation is performed on Synology DS116, the bootcmd needs to be set to activate the SATA power:
setenv bootcmd 'mw.l f1018100 00008000; scsi init; run bootcmd_exec; echo Booting Stock OS ...; run bootspi'

and then

boot

Observe the serial console log, it should boot all the way to the Debian prompt (with up to a few minute delay due to entropy).

Log in using credential root/root.

After successfully logged in, check the serial log to see if there is any error messages output by the kernel.


5. In Debian, reboot the system.

Now we have booted into the HDD rootfs once, so reboot the system and make it permanent.

shutdown -r now


6. Make HDD installation permanent

Interrupt u-boot at countdown. And execute
setenv load_image_addr 0x02000000
setenv load_initrd_addr 0x3000000
setenv load_image 'echo loading uImage from raw HDD ...; scsi device 0; scsi read $load_image_addr 0x5000 0x2F00'
setenv load_initrd 'echo loading uInitrd from raw HDD ...; scsi device 0; scsi read $load_initrd_addr 0xA000 0x4F00'
setenv set_bootargs 'setenv bootargs "console=ttyS0,115200 root=LABEL=rootfs rootdelay=10 $mtdparts earlyprintk=serial"'
setenv bootcmd_exec 'echo Booting Debian ...; run set_bootargs; setenv fdt_skip_update yes; setenv initrd_high 0xffffffff; run load_image; run load_initrd; bootm $load_image_addr $load_initrd_addr'
setenv bootcmd 'scsi init; run bootcmd_exec; echo Booting Stock OS ...; run bootspi'

DS116 Note: if the installation is performed on Synology DS116, the bootcmd needs to be set to activate the SATA power:
setenv bootcmd 'mw.l f1018100 00008000; scsi init; run bootcmd_exec; echo Booting Stock OS ...; run bootspi'

and then

saveenv
reset

Observe the serial console log, it should reboot all the way to the Debian prompt again. Log in as root/root.

END of Installation.


7. Post installation

7.1. Personalize the system

Follow the post install instruction in the rootfs Note1 to regenerate SSH key. And also read Note3 to see how to ensure the MAC address will be persistent.

7.2. Using USB drives

If another USB drive is plugged in during boot, this USB drive must not contain a rootfs and its partition must be labeled to something other than rootfs. The label rootfs must be solely used for the HDD partition to ensure successful booting.

While the system is running, a USB rootfs can be plugged in and mounted as normally would be.

If you have a USB rootfs already installed and running before, you can set it up to boot with this USB rootfs as a fallback rescue system (More changes in u-boot envs needed to do this) .

7.3 Kernel upgrade

After the install is done, and the box is running normally, upgrade the kernel to the latest version. Later kernel version will have better entropy and will enable Debian booting without an extra USB attached to the box (as a way to gain entropy).

7.3.1 Kernel upgrade example

TBD

-bodhi
===========================
Forum Wiki
bodhi's corner (buy bodhi a beer)
Re: Debian on Synology RS816 (Armada 385)
January 01, 2021 08:37PM
bonk1990,

I've posted the final HDD Installation Instruction above (and remove the old post content). Please proof read it to see if I missed anything!

-bodhi
===========================
Forum Wiki
bodhi's corner (buy bodhi a beer)
salahuddin
Re: Debian on Synology RS816 (Armada 385)
July 17, 2021 09:13AM
It worked on my Synology DS218j.

Debian-5.2.9-mvebu-tld-1-rootfs-bodhi.tar.bz2 with dts/armada-385-synology-rs816.dtb

and boot parameter
setenv bootcmd 'mw.l f1018100 00008000; scsi init; run bootcmd_exec; echo Booting Stock OS ...; run bootspi'

note: linux-5.12.6 did not work for my device yet.
Re: Debian on Synology RS816 (Armada 385)
July 17, 2021 03:03PM
salahuddin,

> It worked on my Synology DS218j.
>
> Debian-5.2.9-mvebu-tld-1-rootfs-bodhi.tar.bz2 with
> dts/armada-385-synology-rs816.dtb
>
> and boot parameter
>
> setenv bootcmd 'mw.l f1018100 00008000; scsi init;
> run bootcmd_exec; echo Booting Stock OS ...; run
> bootspi'
>
>
> note: linux-5.12.6 did not work for my device yet.

Thanks for the report! will add the DS218j to the support list.

-bodhi
===========================
Forum Wiki
bodhi's corner (buy bodhi a beer)
salahuddin
Re: Debian on Synology RS816 (Armada 385)
July 17, 2021 06:43PM
Synology DS218j

One minor workaround for slow NAS HDD.
My NAS HDD is quite slow. So, I had to add sleep before scsi init.

setenv bootcmd 'mw.l f1018100 00008000; sleep 10; scsi init; run bootcmd_exec; echo Booting Stock OS ...; run bootspi'

I was trying to use bootdelay environment variable but could not make it work.
salahuddin
Re: Debian on Synology RS816 (Armada 385)
July 18, 2021 03:59AM
Synology DS218j

Pin configuration on board:
2-GND, 4-TX, 6-RX

So, I connected these pins from my usb TTL UART:
2-GND, 4-RXD, 6-TXD

https://wrgms.com/recovering-a-failed-synology-diskstation-ds2xx-serial/

connect
# screen /dev/ttyUSB1 115200
Re: Debian on Synology RS816 (Armada 385)
July 18, 2021 04:43PM
Cool!

Quote

My NAS HDD is quite slow. So, I had to add sleep before scsi init.

I was trying to use bootdelay environment variable but could not make it work.

That's normal. bootdelay does not have any effect to HDD spinning up. The sleep period after the poke "mw.l f1018100 00008000" is needed for slow disk/ disk controller.

It's a work around, since we can't control this stock u-boot (if we did, it would take only a few seconds for the HDD to power up).


You should try the GPIO to see if they are the same as the RS816
ls -l /sys/class/leds

Howto control GPIOs:
https://forum.doozan.com/read.php?2,12096,35663#msg-35663

-bodhi
===========================
Forum Wiki
bodhi's corner (buy bodhi a beer)
salahuddin
Re: Debian on Synology RS816 (Armada 385)
July 18, 2021 05:38PM
Thanks for the explanation.

ls -l /sys/class/leds
lrwxrwxrwx 1 root root 0 Jul 18 15:19 rs816:green:sata1 -> ../../devices/platform/gpio-leds/leds/rs816:green:sata1

I will check "How to control GPIOs".
Re: Debian on Synology RS816 (Armada 385)
July 19, 2021 05:02AM
salahuddin,

> I will check "How to control GPIOs".

That's how we try out each GPIO number to see which one is which.

The best way to find out the correct GPIOs is searching in the GPL source code. Synology is usually good in providing the GPL at their website.

Since you are running with the RS816 DTS, and there is only one LED GPIO that's available, you can try to control it like this to see if you can turn on/off the SATA1 LED.

echo default-on > /sys/class/leds/rs816:green:sata1/trigger
and
echo none > /sys/class/leds/rs816:green:sata1/trigger

If that works then set it to trigger the SATA1 activity:

echo ide-disk1 > /sys/class/leds/rs816:green:sata1/trigger

Ususally we set it in /etc/rc.local so that it takes effect at boot time.

-bodhi
===========================
Forum Wiki
bodhi's corner (buy bodhi a beer)
Re: Debian on Synology RS816 (Armada 385)
July 19, 2021 11:40AM
bodhi,

It has no effect on LED.
/sys/class/leds/rs816:green:sata1/trigger

Yes, I need to check their GPL source code.
Re: Debian on Synology RS816 (Armada 385)
July 20, 2021 12:58PM
I still could not find relevant files in their GPL code.

I am running with 5.2.9 but when I try to use linux-5.12.6-mvebu-tld-1-bodhi.tar.bz2 I am getting CRC error in initrdramfs and boot fall back to default ROM.

So, I tried to compile 5.13.0.
I copied kernel config then
$ make ARCH=arm CROSS_COMPILE=/usr/bin/arm-linux-gnueabihf- bindeb-pkg

Test 1:
I installed custom kernel and got same error message while booting.

Test 2:
I deboostrap basic system in Debian and added dts with kernel and added to raw HDD sectors as described.

Now, I can boot with kernel 5.13.0 but it could not find LABEL=rootfs after initial steps.

Could you please suggest some documentation that I can build a custom rootfs from source ?
Re: Debian on Synology RS816 (Armada 385)
July 20, 2021 04:36PM
salahuddin,


> Now, I can boot with kernel 5.13.0 but it could
> not find LABEL=rootfs after initial steps.

That should be easy to figure out. Make sure the USB rootfs was created correctly (EXt3 partition, with rootfs label, being root while creating it...) exactly as instructed in the release thread.

> I am running with 5.2.9 but when I try to use
> linux-5.12.6-mvebu-tld-1-bodhi.tar.bz2 I am
> getting CRC error in initrdramfs and boot fall
> back to default ROM.


That CRC error could be caused by a few reasons. You need to post the serial boot log, and also good to post the log of the session when you installed the kernel linux-5.12.6-mvebu-tld-1.

===

With all that said, you should stay with the rootfs Debian-5.2.9-mvebu-tld-1-rootfs-bodhi.tar.bz2 and the kernel 5.2.9-mvebu-tld-1 in it for a while until you got everything working for your box. And then worry about running the latest kernel.

-bodhi
===========================
Forum Wiki
bodhi's corner (buy bodhi a beer)
Re: Debian on Synology RS816 (Armada 385)
July 21, 2021 01:40PM
bodhi Wrote:
-------------------------------------------------------
> > Now, I can boot with kernel 5.13.0 but it could
> > not find LABEL=rootfs after initial steps.
>
> That should be easy to figure out. Make sure the
> USB rootfs was created correctly (EXt3 partition,
> with rootfs label, being root while
> creating it...) exactly as instructed in the
> release thread.
>

It is resolved after I installed similar packages.

> > I am running with 5.2.9 but when I try to use
> > linux-5.12.6-mvebu-tld-1-bodhi.tar.bz2 I am
> > getting CRC error in initrdramfs and boot fall
> > back to default ROM.
>
>
> That CRC error could be caused by a few reasons.
> You need to post the serial boot log, and also
> good to post the log of the session when you
> installed the kernel linux-5.12.6-mvebu-tld-1.
>

I found the root cause:
raw HDD address range of "uInitrd" exceed the limit

Both linux-5.12.6-mvebu-tld-1 and my custom build kernel 5.13.4 are working fine now.

setenv load_initrd 'echo loading uInitrd from raw HDD ...; scsi device 0; scsi read $load_initrd_addr 0xA000 0x4F00'

just change 0x4F00 to 0x5F00/0x6F00 depending on the size of your uInitrd. (please check the range limit)
setenv load_initrd 'echo loading uInitrd from raw HDD ...; scsi device 0; scsi read $load_initrd_addr 0xA000 0x6F00'

Thank you.
Re: Debian on Synology RS816 (Armada 385)
July 21, 2021 09:58PM
salahuddin,

> I found the root cause:
> raw HDD address range of "uInitrd" exceed the
> limit

That's the problem with installing the kernel in HDD raw sectors. It's a maintenance problem each time you upgrade the kernel.

Install the rootfs on USB or NAND/SPI flash is a more robust approach. For USB rootfs, some precaution is needed to avoid wearing out the drive:

http://forum.doozan.com/read.php?2,13702,13704#msg-13704

-bodhi
===========================
Forum Wiki
bodhi's corner (buy bodhi a beer)
Re: Debian on Synology RS816 (Armada 385)
July 23, 2021 04:45PM
Hi bodhi,

> Install the rootfs on USB or NAND/SPI flash is a more robust approach. For USB rootfs, some precaution is needed to avoid wearing out the drive:

I will try SPI flash.

I started wiki in Debian: https://wiki.debian.org/InstallingDebianOn/Synology

Please feel free to edit or comment.

Thank you.
Re: Debian on Synology RS816 (Armada 385)
July 23, 2021 05:45PM
salahuddin,

> I started wiki in Debian:
> https://wiki.debian.org/InstallingDebianOn/Synology

Cool!

> Please feel free to edit or comment.

I'll take a look and let you know.

-bodhi
===========================
Forum Wiki
bodhi's corner (buy bodhi a beer)
Re: Debian on Synology RS816 (Armada 385)
July 23, 2021 06:47PM
Comments:

==============

Quote

important to get device tree you can get pre-build dtb from kernel 5.2 from doozan forum or compile yourself.

That link should be:

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

So I would update it to:

Quote

important to get device tree you can get pre-build dtb from kernel 5.2 from the tarbal linux-5.12.6-mvebu-tld-1-bodhi.tar.bz2 at doozan forum or compile yourself.

==============

In this section

Quote

configure and build custom kernel

$ cp ../config-5.12.6-mvebu-tld-1 .config
$ make ARCH=arm CROSS_COMPILE=/usr/bin/arm-linux-gnueabihf- menuconfig
$ make ARCH=arm CROSS_COMPILE=/usr/bin/arm-linux-gnueabihf- bindeb-pkg

The config file config-5.12.6-mvebu-tld-1 has local version as
CONFIG_LOCALVERSION="-mvebu-tld-1"

My convention is x.xx.xx-mvebu-tld-1 so the resulting image name and the kernel file name will have that postfix if you use the config file as is. When someone build the kernel themself, the local version probably should have a local version like

CONFIG_LOCALVERSION="-mvebu-tld-1-salahuddin-1"

or whatever naming convention one choose to use. It should be like above (with -mvebu-tld1) so we know what version of the patch and config file came from and have been applied to the kernel source tree.

Of course, if a user wants keep it generic so that it uses mainline kernel name (no postfix), then there are a few minor drawbacks that should be aware of:

1. It goes against kernel naming convention: customed built kernel should have "distro' postfix to distinguish it from a mainline kernel (as advised in kernel Documentation).
2. During upgrade, Debian (or other distro) will assume it is a mainline kernel (there are distro setup to alleviate this, though). Some confusion will presented in the future kernel upgrade and distro upgrade.

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



Edited 1 time(s). Last edit at 07/23/2021 06:51PM by bodhi.
Re: Debian on Synology RS816 (Armada 385)
July 24, 2021 10:09AM
Hi bodhi,

Done. Thank you.
Re: Debian on Synology RS816 (Armada 385)
December 15, 2021 05:08PM
Hi bodhi,

Thank you for your work on this!

I have a DS213J on which I have followed the USB rootfs tutorial using Debian-5.13.8-mvebu-tld-1-rootfs-bodhi.tar.bz2 (28 Sept 2021)

I am lucky enough to have a NAS which has a DTS in the mainline tree.

Everything works until the last step (5.c).
If I skip the saveenv step and 'boot' just after, it works. But with the saveenv, I think that a part of the uImage on the SPI is overridden because I get a bad CRC:

BootROM 1.08
Booting from SPI flash
High speed PHY - Version: 2.1.2 (COM-PHY-V20) 
Update PEX Device ID 0x67100
High speed PHY - Ended Successfully
                                   DDR3 Training Sequence - Ver 4.5.0 
DDR3 Training Sequence - Ended Successfully 
Status = MV_OK
BootROM: Image checksum verification PASSED

 __   __                      _ _
|  \/  | __ _ _ ____   _____| | |
| |\/| |/ _` | '__\ \ / / _ \ | |
| |  | | (_| | |   \ V /  __/ | |
|_|  |_|\__,_|_|    \_/ \___|_|_|
         _   _     ____              _
        | | | |   | __ )  ___   ___ | |_ 
        | | | |___|  _ \ / _ \ / _ \| __| 
        | |_| |___| |_) | (_) | (_) | |_ 
         \___/    |____/ \___/ \___/ \__| 
 ** LOADER **


U-Boot 2011.12-SYNO-add48c3-2013-07-18 (Jul 18 2013 - 16:45:54) Marvell version: v2011.12 2013_Q1.2

Board: SYNO-DS213j-BP
SoC:   MV6710 A1
CPU:   Marvell PJ4B v7 UP (Rev 1) LE
       CPU    @ 1200 [MHz]
       L2     @ 600 [MHz]
       TClock @ 200 [MHz]
       DDR    @ 600 [MHz]
       DDR 16Bit Width, FastPath Memory Access
DRAM:  512 MiB

Map:   Code:            0x1ff0a000:0x1ffa1ed8
       BSS:             0x1ffefca0
       Stack:           0x1f9f9ef8
       Heap:            0x1f9fa000:0x1ff0a000

MMC:   MRVL_MMC: 0
SF: Detected M25P64 with page size 64 KiB, total 8 MiB
*** Warning - bad CRC, using default environment

PEX 0.0(0): Detected No Link.
PEX 0.1(1): Detected No Link.
FPU not initialized
USB 0: Host Mode
USB 1: Host Mode
Modules/Interfaces Detected:
       PEX0 (Lane 0)
       SATA0 (Lane 2)
       SATA1 (Lane 3)
       SGMII0 Phy module (Lane 1)

Synology Model: DS213j
Fan Status: Good

Net:   egiga0 [PRIME]
Press Ctrl+C to abort autoboot in 3 second
## Booting kernel from Legacy Image at f40c0000 ...
   Image Name:   Linux-3.2.40
   Created:      2021-07-01   6:31:28 UTC
   Image Type:   ARM Linux Kernel Image (uncompressed)
   Data Size:    2160360 Bytes = 2.1 MiB
   Load Address: 00008000
   Entry Point:  00008000
   Verifying Checksum ... Bad Data CRC
ERROR: can't get kernel image!
Marvell>> setenv ipaddr 192.168.1.19
Marvell>> setenv serverip 192.168.1.42
Marvell>> setenv usb_setup 'setenv usbActive 1; setenv usbType 3; usb start;'
Marvell>> setenv load_initrd_addr 0x3000000
Marvell>> setenv load_image_addr 0x02000000
Marvell>> setenv mtdparts 'mtdparts=spi0.0:896k(u-boot),64k(dtb),7104k(kernel),-(env)'
Marvell>> setenv boot_config_spi 'setenv image_addr_spi 0x0F0000; setenv image_size_spi 0x006f0000; sf probe 0 50000000' 
Marvell>> setenv load_image_spi 'echo loading uImage from flash ...; sf read $load_image_addr $image_addr_spi $image_size_spi'
Marvell>> setenv set_bootargs 'setenv bootargs "console=ttyS0,115200 root=/dev/sda1 rootdelay=10 $mtdparts earlyprintk=serial"' 
Marvell>> setenv bootcmd_exec 'echo Booting Debian ...; run set_bootargs; setenv fdt_skip_update yes; setenv initrd_high 0xffffffff; run boot_config_spi; run load_image_spi; bootm $load_image_addr -'
Marvell>> setenv bootcmd 'run bootcmd_exec; run bootspi'
Marvell>> saveenv
Saving Environment to SPI Flash...
SF: Detected M25P64 with page size 64 KiB, total 8 MiB
Erasing SPI flash....Writing to SPI flash.....done
Marvell>> reset
resetting ...
Marvell>> 
BootROM 1.08
Booting from SPI flash
High speed PHY - Version: 2.1.2 (COM-PHY-V20) 
Update PEX Device ID 0x67100
High speed PHY - Ended Successfully
                                   DDR3 Training Sequence - Ver 4.5.0 
DDR3 Training Sequence - Ended Successfully 
Status = MV_OK
BootROM: Image checksum verification PASSED

 __   __                      _ _
|  \/  | __ _ _ ____   _____| | |
| |\/| |/ _` | '__\ \ / / _ \ | |
| |  | | (_| | |   \ V /  __/ | |
|_|  |_|\__,_|_|    \_/ \___|_|_|
         _   _     ____              _
        | | | |   | __ )  ___   ___ | |_ 
        | | | |___|  _ \ / _ \ / _ \| __| 
        | |_| |___| |_) | (_) | (_) | |_ 
         \___/    |____/ \___/ \___/ \__| 
 ** LOADER **


U-Boot 2011.12-SYNO-add48c3-2013-07-18 (Jul 18 2013 - 16:45:54) Marvell version: v2011.12 2013_Q1.2

Board: SYNO-DS213j-BP
SoC:   MV6710 A1
CPU:   Marvell PJ4B v7 UP (Rev 1) LE
       CPU    @ 1200 [MHz]
       L2     @ 600 [MHz]
       TClock @ 200 [MHz]
       DDR    @ 600 [MHz]
       DDR 16Bit Width, FastPath Memory Access
DRAM:  512 MiB

Map:   Code:            0x1ff0a000:0x1ffa1ed8
       BSS:             0x1ffefca0
       Stack:           0x1f9f9ef8
       Heap:            0x1f9fa000:0x1ff0a000

MMC:   MRVL_MMC: 0
SF: Detected M25P64 with page size 64 KiB, total 8 MiB
PEX 0.0(0): Detected No Link.
PEX 0.1(1): Detected No Link.
FPU not initialized
USB 0: Host Mode
USB 1: Host Mode
Modules/Interfaces Detected:
       PEX0 (Lane 0)
       SATA0 (Lane 2)
       SATA1 (Lane 3)
       SGMII0 Phy module (Lane 1)

Synology Model: DS213j
Fan Status: Good

Net:   egiga0 [PRIME]
Press Ctrl+C to abort autoboot in 3 second
Booting Debian ...
SF: Detected M25P64 with page size 64 KiB, total 8 MiB
loading uImage from flash ...
## Booting kernel from Legacy Image at 02000000 ...
   Image Name:   Linux-5.13.8-mvebu-tld-1
   Created:      2021-12-15  21:46:41 UTC
   Image Type:   ARM Linux Kernel Image (uncompressed)
   Data Size:    5233120 Bytes = 5 MiB
   Load Address: 00008000
   Entry Point:  00008000
   Verifying Checksum ... Bad Data CRC
ERROR: can't get kernel image!
## Error: "bootspi" not defined
Marvell>>

printenv:
Marvell>> printenv
CASset=min
MALLOC_len=5
autoload=no
baudrate=115200
boot_config_spi=setenv image_addr_spi 0x0F0000; setenv image_size_spi 0x006f0000; sf probe 0 50000000
bootargs=console=ttyS0,115200 root=/dev/sda1 rootdelay=10 mtdparts=spi0.0:896k(u-boot),64k(dtb),7104k(kernel),-(env) earlyprintk=serial
bootargs_end=:10.4.50.254:255.255.255.0:KW40:eth0:none
bootargs_root=root=/dev/nfs rw
bootcmd=run bootcmd_exec; run bootspi
bootcmd_exec=echo Booting Debian ...; run set_bootargs; setenv fdt_skip_update yes; setenv initrd_high 0xffffffff; run boot_config_spi; run load_image_spi; bootm $load_image_addr -
bootdelay=3
cacheShare=no
console=console=ttyS0,115200
disL2Cache=yes
disaMvPnp=no
eeeEnable=no
enaAutoRecovery=yes
enaClockGating=no
enaFPU=no
enaWrAllo=no
eth1addr=00:50:43:02:00:00
eth1mtu=1500
ethact=egiga0
ethaddr=00:50:43:02:02:00
ethmtu=1500
ethprime=egiga0
fdt_skip_update=yes
image_addr_spi=0x0F0000
image_name=uImage
image_size_spi=0x006f0000
initrd_high=0xffffffff
initrd_name=uInitrd
ipaddr=192.168.1.19
load_image_addr=0x02000000
load_image_spi=echo loading uImage from flash ...; sf read $load_image_addr $image_addr_spi $image_size_spi
load_initrd_addr=0x3000000
loadaddr=0x02000000
loads_echo=0
mtdparts=mtdparts=spi0.0:896k(u-boot),64k(dtb),7104k(kernel),-(env)
mvNetConfig=mv_net_config=1,(00:50:43:11:11:11,0:1:2:3:4),mtu=1500
mv_pon_addr=00:50:43:00:00:02
netbsd_en=no
netmask=255.255.255.0
netretry=no
pcieTune=no
pexMode=rc
pxe_files_load=:default.arm-armada370-db:default.arm-armadaxp:default.arm
pxefile_addr_r=3100000
rcvrip=169.254.100.100
rootpath=/srv/oneiric
sata_delay_reset=0
sata_dma_mode=yes
serverip=192.168.1.42
setL2CacheWT=no
set_bootargs=setenv bootargs "console=ttyS0,115200 root=/dev/sda1 rootdelay=10 $mtdparts earlyprintk=serial"
standalone=fsload 0x2000000 $image_name;setenv bootargs $console $mtdparts root=/dev/mtdblock0 rw ip=$ipaddr:$serverip$bootargs_end; bootm 0x2000000;
stderr=serial
stdin=serial
stdout=serial
usb0Mode=host
usb1Mode=host
usb2Mode=device
usbActive=1
usb_setup=setenv usbActive 1; setenv usbType 3; usb start;
vxworks_en=no
yuk_ethaddr=00:00:00:EE:51:81

Environment size: 2250/65532 bytes

If I can get the USB rootfs to work, is it considered stable for the long term or is the HDD method preferred?
I have noticed that with the USB method, the uInitrd file is not flashed to the SPI.

Thank you.
Re: Debian on Synology RS816 (Armada 385)
December 15, 2021 10:54PM
rreignier,


> If I can get the USB rootfs to work, is it
> considered stable for the long term or is the HDD
> method preferred?

I would recommend running every thing from the USB rootfs. I have several boxes (at least 6) running with USB rootfs for many years using Sandisk brand, and have not seen any USB drive got worn out. In fact, only a few of my boxes are running HDD rootfs.

There are things to do that will make it stable, and avoid wearing out the USB drive:

https://forum.doozan.com/read.php?2,13702,13704#msg-13704

The USB installation method for this box was done in a way that saved time. I would like to see someone running the kernel uImage and uInitird from the USB rootfs.

But it was a few years ago so I can't recall if the stock u-boot has some problem booting uImage and uInitrd from the USB rootfs :) I would need to reread the whole thread to refresh my memory.

Please try to see if you can load uImage from the USB rootfs! if you need help, please post your questions. If you could do that, then you coul also load uInitrd from the USB rootfs too.

-bodhi
===========================
Forum Wiki
bodhi's corner (buy bodhi a beer)
Re: Debian on Synology RS816 (Armada 385)
December 16, 2021 01:24AM
Thank you bodhi.

My u-boot has the ext2ls and ext2load commands. But when starting USB, it does not find storage device.
Do I need to format my USB drive in EXT2 instead of EXT3?

Marvell>> setenv usb_setup 'setenv usbActive 1; setenv usbType 3; usb start;' 
Marvell>> run usb_setup
(Re)start USB...
USB:   Active port:     1
Register 10011 NbrPorts 1
USB EHCI 1.00
scanning bus for devices... 1 USB Device(s) found
       scanning bus for storage devices... 0 Storage Device(s) found
Marvell>> ext2ls usb 0 /

** Block device usb 0 not supported
Marvell>> ext2ls usb 1

** Block device usb 0 not supported
Re: Debian on Synology RS816 (Armada 385)
December 16, 2021 01:30AM
rreignier,

> My u-boot has the ext2ls and ext2load commands.
> But when starting USB, it does not find storage
> device.
> Do I need to format my USB drive in EXT2 instead
> of EXT3?

Not needed. Ext3 and Ext2 are the same driver (except that the journal is ignored if the drive partition is Ext2)

setenv usb_setup 'setenv usbActive 1; setenv usbType 3; usb start;'

The above is the key. Try a variation of the types to see if the USB drive is recognized:
setenv usbType 3
setenv usbType 2
Depending on the box, you might not have USB 3.0.

-bodhi
===========================
Forum Wiki
bodhi's corner (buy bodhi a beer)
Re: Debian on Synology RS816 (Armada 385)
December 16, 2021 01:40AM
Indeed, no USB3 here but no storage device found with both usbType. I have even tried all from 0 to 4.

My USB if format with only 1 EXT3 partition, as explained in the Debian release post.
Re: Debian on Synology RS816 (Armada 385)
December 16, 2021 10:24PM
rreignier,

I guess it's time to scan this whole thread to find the reason possibly why USB drive is not recognized!

-bodhi
===========================
Forum Wiki
bodhi's corner (buy bodhi a beer)
Re: Debian on Synology RS816 (Armada 385)
December 17, 2021 02:49AM
Indeed!

For now, I have focused on making it boot again with stock DSM.
After my failed attempt to flash uImage on the SPI flash, the boot was broken.

I had the backup of all 5 mtd partitions but the produced image files were too large (4 MB each).
For reference, I have used these commands:
dd if=/dev/mtd0 of=mtd0.stock.ds213j bs=4096k conv=sync
dd if=/dev/mtd1 of=mtd1.stock.ds213j bs=4096k conv=sync
dd if=/dev/mtd2 of=mtd2.stock.ds213j bs=4096k conv=sync
dd if=/dev/mtd3 of=mtd3.stock.ds213j bs=4096k conv=sync
dd if=/dev/mtd4 of=mtd4.stock.ds213j bs=4096k conv=sync
dd if=/dev/mtd5 of=mtd5.stock.ds213j bs=4096k conv=sync

On the first boot with Debian, without changing the mtdparts, I had:
root@debian:~# cat /proc/mtd 
dev:    size   erasesize  name
mtd0: 000c0000 00001000 "RedBoot"
mtd1: 002d0000 00001000 "zImage"
mtd2: 00440000 00001000 "rd.gz"
mtd3: 00010000 00001000 "vendor"
mtd4: 00010000 00001000 "RedBoot config"
mtd5: 00010000 00001000 "FIS directory"

So I have resized my image files with dd:
dd if=mtd0.stock.ds213j of=mtd0.stock.ds213j.trunc bs=1 count=768k
dd if=mtd1.stock.ds213j of=mtd1.stock.ds213j.trunc bs=1 count=2880k
dd if=mtd2.stock.ds213j of=mtd2.stock.ds213j.trunc bs=1 count=4352k
dd if=mtd3.stock.ds213j of=mtd3.stock.ds213j.trunc bs=1 count=64k
dd if=mtd4.stock.ds213j of=mtd4.stock.ds213j.trunc bs=1 count=64k
dd if=mtd5.stock.ds213j of=mtd5.stock.ds213j.trunc bs=1 count=64k

I have then used this mtdparts line in uboot to match the previous partitions:
setenv mtdparts 'mtdparts=spi0.0:768k(RedBoot),2880k(zImage),4358k(rd.gz),64k(vendor),64k(Redboot config),-(FIS directory)'

And once logged on Debian, flashed the images files:
flashcp -v mtd0.stock.ds213j.trunc /dev/mtd0
flashcp -v mtd1.stock.ds213j.trunc /dev/mtd1
flashcp -v mtd2.stock.ds213j.trunc /dev/mtd2
flashcp -v mtd3.stock.ds213j.trunc /dev/mtd3
flashcp -v mtd4.stock.ds213j.trunc /dev/mtd4
flashcp -v mtd5.stock.ds213j.trunc /dev/mtd5

And now the NAS can boot in DSM as before.

I am now ready to investigate further the SPI or USB boot.

But first, I need to read this whole thread :)
Re: Debian on Synology RS816 (Armada 385)
January 24, 2022 06:13PM
Hi bodhi

It took me a while but I have finally finished reading this whole thread.

From what I have read, I did not see anyone booting with a kernel image stored on USB. It was only from tftp (as I did already), from flash (which failed from me) or from raw HDD sectors (did not try yet).

Do you remember another thread in which it was done?
Author:

Subject:


Spam prevention:
Please, enter the code that you see below in the input field. This is for blocking bots that try to post this form automatically. If the code is hard to read, then just try to guess it right. If you enter the wrong code, a new image is created and you get another chance to enter it right.
Message: