Welcome! Log In Create A New Profile

Advanced

Debian on Zyxel NAS326

Posted by Kirsch 
Re: Debian on Zyxel NAS326
September 28, 2017 04:22PM
musv,

Data point: I've tested a 1GB file xfer with NFS on 4.12.x, and it did not cause me any problem.

I've not yet tried 4.13.2, which I have planned to release.

-bodhi
===========================
Forum Wiki
bodhi's corner
musv
Re: Debian on Zyxel NAS326
October 18, 2017 02:00PM
I tried kernel 4.13.7 today. To get sure the problem is not related to my config, I took the config of 4.10.10 (the last fully working kernel) and used also the dts file from April.

The problem occurred again:
Okt 18 21:34:23 nas kernel: rpc-srv/tcp: nfsd: sent only 56968 when sending 65644 bytes - shutting down socket

Hence, I can eliminate every config changes. It must be the network driver in the kernel.

bodhi Wrote:
-------------------------------------------------------
> Data point: I've tested a 1GB file xfer with NFS on 4.12.x, and it did not cause me any problem.

It's not caused by a single file. For me the most likely way to reproduce it, is to send files not with full speed over a longer period of time - half an hour up to an hour. That's why I wrote explicitly: listen to music files, that are stored on the nfs device.

So far I downgraded to 4.10.10.
Re: Debian on Zyxel NAS326
October 19, 2017 08:43PM
musv Wrote:
-------------------------------------------------------
> I tried kernel 4.13.7 today. To get sure the
> problem is not related to my config, I took the
> config of 4.10.10 (the last fully working kernel)
> and used also the dts file from April.
>
> The problem occurred again:
>
Okt 18 21:34:23 nas kernel: rpc-srv/tcp:
> nfsd: sent only 56968 when sending 65644 bytes -
> shutting down socket
>
> Hence, I can eliminate every config changes. It
> must be the network driver in the kernel.
>
> bodhi Wrote:
> -------------------------------------------------------
> > Data point: I've tested a 1GB file xfer with NFS
> on 4.12.x, and it did not cause me any problem.
>
> It's not caused by a single file. For me the most
> likely way to reproduce it, is to send files not
> with full speed over a longer period of time -
> half an hour up to an hour. That's why I wrote
> explicitly: listen to music files, that are stored
> on the nfs device.
>
> So far I downgraded to 4.10.10.

Yes, it sounds like the ethernet driver TCP buffer xmit problem.

-bodhi
===========================
Forum Wiki
bodhi's corner
musv
Re: Debian on Zyxel NAS326
October 20, 2017 07:23AM
I'm currently in contact with the mvneta developer from free-electrons.com. With their help I'm testing around.

The first step was to take the mvneta driver directory (kernel/driver/net/ethernet/mvneta) from 4.10.10 and replace the driver from 4.13.7. I had to modify a few lines but I got the 4.10.10 driver running in 4.13.7 and it works perfectly without any issues.

In the whole driver update list, they have marked 3 patches as potentially suspicious. So I'll revert those patches and see, which one is the critical one.
Re: Debian on Zyxel NAS326
October 20, 2017 02:47PM
musv,

> In the whole driver update list, they have marked
> 3 patches as potentially suspicious. So I'll
> revert those patches and see, which one is the
> critical one.

There is one TCP buffer related patch I think the most suspicious.

-bodhi
===========================
Forum Wiki
bodhi's corner
kralan
Re: Debian on Zyxel NAS326
October 30, 2017 10:45AM
I am still at 4.9.5-tld-8 and am planning to upgrade to the latest available kernel soon.
Do I gather correctly from the recent posts that it's better to wait with the upgrade until the mvneta issue is sorted out?
Re: Debian on Zyxel NAS326
October 30, 2017 01:15PM
kralan Wrote:
-------------------------------------------------------
> I am still at 4.9.5-tld-8 and am planning to
> upgrade to the latest available kernel soon.
> Do I gather correctly from the recent posts that
> it's better to wait with the upgrade until the
> mvneta issue is sorted out?

It's really up to you. If your use case is similar to musv then I'd say don't upgrade. OTOH, I am not sure when this will be sorted out. If there is no activity upstream for a while, then I would have to repeat musv test and try patching the mvneta driver myself.

-bodhi
===========================
Forum Wiki
bodhi's corner
musv
Re: Debian on Zyxel NAS326
October 31, 2017 09:47AM
Here's the discussion about the issue:

https://www.spinics.net/lists/netdev/msg461420.html

kralan:
You can upgrade to at least to Kernel 4.10.x without issues. At least according to my tests to problematic patch is:

https://github.com/torvalds/linux/commit/2a90f7e1d5d04e4f1060268e0b55a2c702bbd67a#diff-851bfc43b3ca32355b4c07d29dbba7f0

If you just revert this patch before compiling the kernel, you won't suffer any nfs-server issues. If you don't use nfs or samba as a server on the Zyxel, you'll probably not notice any regressions.
Re: Debian on Zyxel NAS326
October 31, 2017 03:00PM
Thanks musv! I'll take a look and incorporate in the next release.

-bodhi
===========================
Forum Wiki
bodhi's corner
musv
Re: Debian on Zyxel NAS326
November 22, 2017 11:49AM
Just to give some feedback. The problem has been resolved.

If you build the next kernel image, just check if this patch has been applied:
https://www.spinics.net/lists/netdev/msg466892.html

diff --git a/drivers/net/ethernet/marvell/mvneta.c b/drivers/net/ethernet/marvell/mvneta.c
index 64a04975bcf8..bc93b69cfd1e 100644
--- a/drivers/net/ethernet/marvell/mvneta.c
+++ b/drivers/net/ethernet/marvell/mvneta.c
@@ -816,11 +816,14 @@ static void mvneta_txq_pend_desc_add(struct mvneta_port *pp,
 {
 	u32 val;
 
-	/* Only 255 descriptors can be added at once ; Assume caller
-	 * process TX desriptors in quanta less than 256
-	 */
-	val = pend_desc + txq->pending;
-	mvreg_write(pp, MVNETA_TXQ_UPDATE_REG(txq->id), val);
+	pend_desc += txq->pending;
+
+	/* Only 255 Tx descriptors can be added at once */
+	do {
+		val = min(pend_desc, 255);
+		mvreg_write(pp, MVNETA_TXQ_UPDATE_REG(txq->id), val);
+		pend_desc -= val;
+	} while (pend_desc > 0);
 	txq->pending = 0;
 }
Re: Debian on Zyxel NAS326
November 22, 2017 03:27PM
Thanks musv!

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

Your Email:


Subject:


Spam prevention:
Please, solve the mathematical question and enter the answer in the input field below. This is for blocking bots that try to post this form automatically.
Question: how much is 13 plus 4?
Message: