Discussion:
Strech on TS-109 (Orion) Stucks
Mopox
2018-02-16 10:59:06 UTC
Permalink
Hi Community,

i try to install Debian Strech on a QNAP TS-109. But somehow the
installer kernel is not booting. I used a serial interface to load the
debian installer via uboot with tftpboot as following:

---
setenv serverip 192.168.203.14
setenv ipaddr 192.168.203.84
setenv bootargs console=ttyS0,115200n8 root=/dev/ram rw
initrd=0x800000,0x3fffff
tftpboot 0x0800000 mtd2.bin
tftpboot 0x400000 mtd1.bin
bootm 0x400000
---

Also when I install Strech to the flash (I followed
https://www.cyrius.com/debian/orion/qnap/ts-109/install/) I am stucking
after reboot at the same stage. The installer is just not loading:

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

QNAP SYSTEMS, INC.

** MARVELL BOARD: RD-88F5182-NAS-2 LE

U-Boot 1.1.1 (Nov 14 2008 - 17:05:22) Marvell version: 1.11.2

Enable SDRAM Bank 0.
OnBoard DRAM CS[0] base 0x00000000 size 128MB
DRAM Total size 128MB
[***@ff000000] [***@f8000000] ## Unknown FLASH at f8000000: Size =
0x00000000 = 0 MB
Flash: 8 MB
Addresses 20M - 0M are saved for the U-Boot usage.
Mem malloc Initialization (20M - 16M): Done

Soc: 88F5182 A2
CPU: ARM926 (Rev 0) running @ 500Mhz
Orion 1 streaming disabled
SysClock = 166Mhz , TClock = 166Mhz


USB 0: host mode
USB 1: host mode
PCI 0: PCI Express Root Complex Interface
pci_init_board:Error calling mvPciIfInit for pciIf 0
PCI 1: Conventional PCI, speed = 33000000
Net: egiga0
Hit any key to stop autoboot: 0
## Booting image at ff000000 ...
Image Name: Debian kernel
Created: 2017-12-05 16:25:07 UTC
Image Type: ARM Linux Kernel Image (uncompressed)
Data Size: 2050264 Bytes = 2 MB
Load Address: 00c08000
Entry Point: 00c08000
Verifying Checksum ... OK
OK

Starting kernel ...

Uncompressing Linux... done, booting the kernel.
---

Now nothing is happening anymore it is stucking (I waited over night).

I assume that it has something to do with the kernel size. The Entry
Point might be wrong or so one.

I installed Jessy and it booted without problem.

So any Ideas?

Greetings,
Mopox
Martin Michlmayr
2018-02-17 17:58:12 UTC
Permalink
i try to install Debian Strech on a QNAP TS-109. But somehow the installer
kernel is not booting. I used a serial interface to load the debian
setenv bootargs console=ttyS0,115200n8 root=/dev/ram rw
initrd=0x800000,0x3fffff
This was one line, correct? (because in your email it shows up as two
lines)
tftpboot 0x0800000 mtd2.bin
tftpboot 0x400000 mtd1.bin
bootm 0x400000
What are mtd2.bin and mtd1.bin? You say you're loading the installer,
which would be "kernel" and "initrd" (from
<http://ftp.debian.org/debian/dists/stretch/main/installer-armel/current/images/orion5x/network-console/qnap/ts-109>).
Also when I install Strech to the flash (I followed
https://www.cyrius.com/debian/orion/qnap/ts-109/install/) I am stucking
Above you write that you cannot load Debian installer and now you
describe problems after you install Debian. How did you install
Debian? Did you use the QNAP firmware to flash the installer?
--
Martin Michlmayr
http://www.cyrius.com/
Arthur Lutz
2018-02-22 20:51:38 UTC
Permalink
Hi Mopox and Martin,

I'm getting the same behaviour but from an upgrade from jessie to stretch.

I've added some info to
https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=890262#51 but this
might be a different problem.

Funnily enough while setting up a tftp server to try to boot from the
network I found some old kernel & initrd files in the existing tftp
server on my machine, these are from early 2017 and I guess they are
jessie installers. Try those out doesn't get me into the installer
(which I want to use to revert to the old 3.16 kernel) I get the
following log https://paste.debian.net/1011554/

So I tried with the initrd and kernel from the stretch installer from
http://ftp.debian.org/debian/dists/stretch/main/installer-armel/current/images/orion5x/network-console/qnap/ts-109/
I tried with the padding for the kernel as suggested in
http://www.cyrius.com/debian/orion/qnap/ts-109/recovery/ (dd if=kernel
of=kernel.pad ibs=2097152 conv=sync) but that is obviously not useful.

In the end, I got it to boot to installer with
http://ftp.debian.org/debian/dists/jessie/main/installer-armel/current/images/orion5x/network-console/qnap/ts-109/


I now have to find out how to do the equivalent of grub-upgrade on the
previous kernel. But while I'm in this state, I can help out debug this
problem.

Arthur
Martin Michlmayr
2018-02-22 21:24:30 UTC
Permalink
Post by Arthur Lutz
I've added some info to
https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=890262#51 but this
might be a different problem.
They are different. The bug report is about the size issue.
Post by Arthur Lutz
So I tried with the initrd and kernel from the stretch installer from
http://ftp.debian.org/debian/dists/stretch/main/installer-armel/current/images/orion5x/network-console/qnap/ts-109/
I tried with the padding for the kernel as suggested in
http://www.cyrius.com/debian/orion/qnap/ts-109/recovery/ (dd if=kernel
of=kernel.pad ibs=2097152 conv=sync) but that is obviously not useful.
Padding the kernel won't make a difference. Padding the kernel is
only required when creating a recovery image because you're combining
several files into one.
Post by Arthur Lutz
In the end, I got it to boot to installer with
http://ftp.debian.org/debian/dists/jessie/main/installer-armel/current/images/orion5x/network-console/qnap/ts-109/
I now have to find out how to do the equivalent of grub-upgrade on the
previous kernel. But while I'm in this state, I can help out debug this
problem.
This blog entry might help:
http://www.cyrius.com/journal/debian/installer-flash-kernel
Instead of update-initramfs run flash-kernel and the version of the
kernel.

Now as to why the stretch kernel doesn't work for some people... I'm
pretty sure the ARM kernel has EARLY_PRINTK enabled so you could try
adding earlyprintk to the cmd line options.

Take kernel and ramdisk from
http://ftp.debian.org/debian/dists/stretch/main/installer-armel/current/images/orion5x/network-console/qnap/ts-109/

setenv bootargs console=ttyS0,115200n8 earlyprintk root=/dev/ram rw initrd=0x800000,0x3fffff
tftpboot 0x0800000 initrd
tftpboot 0x400000 kernel
bootm 0x400000
--
Martin Michlmayr
http://www.cyrius.com/
Arthur
2018-02-22 22:24:20 UTC
Permalink
Hi Martin,
Post by Martin Michlmayr
Post by Arthur Lutz
I've added some info to
https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=890262#51 but this
might be a different problem.
They are different. The bug report is about the size issue.
Sorry about putting this in the wrong place.
Post by Martin Michlmayr
Post by Arthur Lutz
So I tried with the initrd and kernel from the stretch installer from
http://ftp.debian.org/debian/dists/stretch/main/installer-armel/current/images/orion5x/network-console/qnap/ts-109/
I tried with the padding for the kernel as suggested in
http://www.cyrius.com/debian/orion/qnap/ts-109/recovery/ (dd if=kernel
of=kernel.pad ibs=2097152 conv=sync) but that is obviously not useful.
Padding the kernel won't make a difference. Padding the kernel is
only required when creating a recovery image because you're combining
several files into one.
Yep, thanks for the formal explanation.
Post by Martin Michlmayr
Post by Arthur Lutz
In the end, I got it to boot to installer with
http://ftp.debian.org/debian/dists/jessie/main/installer-armel/current/images/orion5x/network-console/qnap/ts-109/
I now have to find out how to do the equivalent of grub-upgrade on the
previous kernel. But while I'm in this state, I can help out debug this
problem.
http://www.cyrius.com/journal/debian/installer-flash-kernel
Instead of update-initramfs run flash-kernel and the version of the
kernel.
Yes, I managed to do the equivalent. By the way I tried the 4.13 kernel
from backports and it had the same behaviour as the 4.9. So I went back
into the installer and removed both 4.x kernels and flash-kernel
correctly re-flashed the 3.x one. Which works fine !
Post by Martin Michlmayr
Now as to why the stretch kernel doesn't work for some people... I'm
pretty sure the ARM kernel has EARLY_PRINTK enabled so you could try
adding earlyprintk to the cmd line options.
Take kernel and ramdisk from
http://ftp.debian.org/debian/dists/stretch/main/installer-armel/current/images/orion5x/network-console/qnap/ts-109/
setenv bootargs console=ttyS0,115200n8 earlyprintk root=/dev/ram rw initrd=0x800000,0x3fffff
tftpboot 0x0800000 initrd
tftpboot 0x400000 kernel
bootm 0x400000
Oh, sorry, I was kind of hyped that it rebooted correctly in 3.x, that I
forgot my offer and disconnected the serial cable and closed the
enclosure. If this is usefull to others, I can test that out in the next
few days.

Arthur

ps. by the way Martin, thank you so much for your efforts to get debian
working on this and the sheevaplug, I have been following your
documentation for years and it's just awesome!
Martin Michlmayr
2018-03-04 18:23:26 UTC
Permalink
Andrew Lunn pointed out this is fixed in David Miller's net tree:
https://git.kernel.org/pub/scm/linux/kernel/git/davem/net.git/commit/?id=13a55372b64e00e564a08d785ca87bd9d454ba30

It should find its way into -stable and from there into Debian's
kernel.
--
Martin Michlmayr
http://www.cyrius.com/
Martin Michlmayr
2018-03-04 18:26:48 UTC
Permalink
Post by Martin Michlmayr
https://git.kernel.org/pub/scm/linux/kernel/git/davem/net.git/commit/?id=13a55372b64e00e564a08d785ca87bd9d454ba30
Just found this bug report which triggered the revert:
https://www.mail-archive.com/***@vger.kernel.org/msg218223.html
--
Martin Michlmayr
http://www.cyrius.com/
Loading...