creative-2008
Posts: 65
Joined: Sat Nov 25, 2017 2:16 pm

Pi 4 - Network

Wed Dec 11, 2019 9:17 pm

I currently have a Raspberry Pi 2B+ which I have set up a Samba share on. I'm aware that both the ethernet and the USB share the same bus, which contributes to slow write speeds when transferring files across a network onto a USB attached device.

I was wondering if this has changed with any of the more recent versions of the Raspberry Pi?

User avatar
thagrol
Posts: 2107
Joined: Fri Jan 13, 2012 4:41 pm
Location: Darkest Somerset, UK
Contact: Website

Re: Pi 4 - Network

Wed Dec 11, 2019 9:39 pm

Yes. See https://www.raspberrypi.org/blog/raspbe ... w-from-35/

Ethernet is no longer connected via USB. However to get gigabit you need every link inthe chain to support it. That's cables, router/switch, and the device you're talking to.

Reading/writing to storage will still be limited by the slowest device in the chain.

If you USB storage device supports USB3 and you connect it to one of the USB 3 ports you should definitely see some improvement (subjevt to the know issues regarding device compatitbility. Search the forum)
Attempts to contact me outside of thes forums will be ignored unless signed in triplicate, sent in, sent back, queried, lost, found, subjected to public enquiry, lost again, and finally buried in soft peat for three months and recycled as firelighters

andrum99
Posts: 983
Joined: Fri Jul 20, 2012 2:41 pm

Re: Pi 4 - Network

Wed Dec 11, 2019 10:41 pm

jcyr wrote:
Wed Dec 11, 2019 10:35 pm
Also be aware that a switch in the path will halve the maximum transfer rate.
That's not the case. I get nearly the full gigabit per second with my Pi 4. The fact that a switch is 'store and forward' has nothing to do with throughput, but would add latency compared to a cut-through switch. You don't need a cut-through switch unless you need the very lowest latency. Please don't spread FUD.

andrum99
Posts: 983
Joined: Fri Jul 20, 2012 2:41 pm

Re: Pi 4 - Network

Wed Dec 11, 2019 10:46 pm

creative-2008 wrote:
Wed Dec 11, 2019 9:17 pm
I currently have a Raspberry Pi 2B+ which I have set up a Samba share on. I'm aware that both the ethernet and the USB share the same bus, which contributes to slow write speeds when transferring files across a network onto a USB attached device.

I was wondering if this has changed with any of the more recent versions of the Raspberry Pi?
The Raspberry PI 4B is very different to previous models of Pi, in terms of the limitations of the hardware. There is very much more IO bandwidth available: the gigabit ethernet is directly connected, and does not go via USB, so operates at full speed. The USB controller is external to the SoC and is connected via a PCIe link, so you get full USB 3.0 speeds. The addition of more memory, on the 2 and 4GB versions, is also extremely welcome.

Clearly if you are using the Pi 4B to talk to a Pi 2B then the speed is going to be contrained by the 2B, but when talking to PCs etc you should see much better performance with the 4B if you are moving a lot of data.

andrum99
Posts: 983
Joined: Fri Jul 20, 2012 2:41 pm

Re: Pi 4 - Network

Thu Dec 12, 2019 12:40 pm

jcyr wrote:
Thu Dec 12, 2019 3:02 am
andrum99 wrote:
Wed Dec 11, 2019 10:41 pm
jcyr wrote:
Wed Dec 11, 2019 10:35 pm
Also be aware that a switch in the path will halve the maximum transfer rate.
That's not the case. I get nearly the full gigabit per second with my Pi 4. The fact that a switch is 'store and forward' has nothing to do with throughput, but would add latency compared to a cut-through switch. You don't need a cut-through switch unless you need the very lowest latency. Please don't spread FUD.
That may be true for streaming protocols such as TCP, but not the case for query/response protocols (TFTP is an example, PTP is another). Check the thoughput of a TFTP transfer across a store and forward switch, such as used by BOOTP for network boot.

It gets worse. We measured an additional 3.6 microsecond of latency at gigE rate on a HP 1410-24G unmanaged switch, twice that at 100 MB excluding packet tx and rx time.
If your particular application requires the lowest possible latency then by all means use a cut-through switch. For general usage, a normal 'store and forward' switch is perfectly acceptable.

creative-2008
Posts: 65
Joined: Sat Nov 25, 2017 2:16 pm

Re: Pi 4 - Network

Sun Dec 29, 2019 10:36 am

Thanks for all of the very informative responses. It has certainly made my mind up that I am going to buy the RPi 4.


I'd be interested to know what potential read and write speeds might be? Say from a laptop connected via gigabit Ethernet to the same router as the Pi also connected by Ethernet.

andrum99
Posts: 983
Joined: Fri Jul 20, 2012 2:41 pm

Re: Pi 4 - Network

Sun Dec 29, 2019 3:01 pm

creative-2008 wrote:
Sun Dec 29, 2019 10:36 am
Thanks for all of the very informative responses. It has certainly made my mind up that I am going to buy the RPi 4.


I'd be interested to know what potential read and write speeds might be? Say from a laptop connected via gigabit Ethernet to the same router as the Pi also connected by Ethernet.
For transferring large files over the network to a Pi 4B-based samba server I get very close to the full gigabit wire speed. The major contraint is the speed of the hard disk I have attached to my Pi 4B - it maxes out at around 100MB/sec, which is pretty much the same speed as the gigabit network port. So basically you should get the full gigabit network bandwidth.

Return to “General discussion”