HomeRaspberry PiSlow NAS write speeds: OrangePi 3, Ubuntu Server 16.04, Samba and SSD

Slow NAS write speeds: OrangePi 3, Ubuntu Server 16.04, Samba and SSD

Encouraged by the initial file sharing benchmarks, I decided to go “all in” and I got myself a brand new 240GB PNY CS900 SSD. A promise of a 1Gbps network and the USB 3.0 interface was too good, not to take advantage of the greater speeds associated with SSD drives. Then things went horribly wrong.

Poor SSD performance

The 240GB PNY CS900 SSD drive is rated for 550MB/s read and 515MB/s write, which is more than enough to saturate my network. On paper, this would never be a bottleneck.

With the same setup (Orange Pi 3, Ubuntu 16.04, SMB) the traditional HDD were able to score a decent 60-70MB/s read/write speeds. I was hoping to saturate the Gigabit Ethernet even more with a faster drive.

Read

The speed never went below 60MB/s (dips caused by local traffic)

I had no issues with a beautiful and very consistent read over 80MB/s for files over 4GB in size. Obviously, the speed would change depending on the number of files per transfer and their respective size, but a single file performance was a very good indicative benchmark.

Houston we have a problem (write)

I wish I could say the same about write speeds. I’m running the test in the same environment. The same OrangePi, the same Gigabit Network, the same computer used as client. The only (apparent) change was the hard drive. The SSD’s speed for writes is absolutely dreadful.

The transfer would stop every 10-15 sec for about 10 sec, maxing out at 30MB/s

The transfers vary between 12-30MB/s, stutters or grinds to a stop for a couple of minutes. I would blame Orange Pi 3 at first if the writes done on HDDs weren’t blowing this SSD out of the water! What gives?

I would like to thank easeus.com for being a super patient sponsor. Check out their backup tools and grab an extra 50% OFF!

Possible solutions?

It’s not always easy to find one solution to fix slow write speed problems. These can range from network issues, hardware problems etc. Upon investigation, my speed issues were caused by permission conflicts.

To confirm that, I have simply overridden the share’s permission with:

 sudo chmod /path_to_share 777 -R 

and just like that, the write speeds returned to expected speeds. While the command isn’t a solution to the problem (you have to set up permissions correctly for your folders and users), this quick (and also permission destructive) test will confirm the nature of the problem. I’m not entirely sure why the conflict of permissions resulted in slow write speeds rather than simply a denied access message, but Linux is a strange beast, and I’m happy for someone to explain the issue to me in detail.

As my installation was new, I could simply start from scratch which solved the issue for me. to solve the issue with existing files and folders, add correct permissions for your user and for the samba service. If the files were stored on another device, you may also need to rewrite the permissions for these. You can learn a bit more about the topic here.

Now that the board and the share perform as expected, I can decide if I want to use my Raspberry Pi 4 or Orange Pi 3 for my next NAS build. Which bard would you use and why? Drop me a message in this Reddit thread.

PayPal

Nothing says "Thank you" better than keeping my coffee jar topped up!

Patreon

Support me on Patreon and get an early access to tutorial files and videos.

image/svg+xml

Bitcoin (BTC)

Use this QR to keep me caffeinated with BTC: 1FwFqqh71mUTENcRe9q4s9AWFgoc8BA9ZU

M5Paper

Programable, ESP32 based awesome dev platform with 4.7 e-ink display by M5Stack

More HATs

client-image
client-image

Argon One M.2

Enclose Raspberry Pi 4 inside this great case with custom I/O, cooling and GPIO and M.2 SSD support

More cases on

client-image
client-image

Best Raspberry Pi Projects

How to use Raspberry PI as WOL (wake on lan) server

0
While you could wake up your PC from a mobile directly, having a dedicated server capable of doing so is the best solution. The reason is simple. You can hook up as many devices as you wish with a single endpoint. This is why Raspberry Pi is perfect for this.

Slow Internet Warning

0
From time to time my Internet grinds to a stop. Since Raspberry Pi 4 comes with a 1Gbps Ethernet, I decided to take advantage of it and create a reporting system in NodeRED that will monitor and report when the ISP is not keeping the contractual agreements. Works with Alexa, Google Home, Android and Windows 10.

How fast Raspberry Pi NAS is?

0
Let's see how fast Raspberry Pi NAS really is?

Argon18: Argon ONE SSD modification

0
Argon One case just got better - now you can boot it from USB without ruining the design thanks to Argon 18: Argon One SSD modification

HOW TO...

It took me 2 months to boot CM4 from NVMe

0
Complete beginners guide to Compute Module 4 boot from NVMe.

Raspberry Pi Zero 2 W vs other Zero boards

0
It's time to test the Raspberry Pi Zero 2 W against other Raspberry Pi boards from Zero series: power, WiFi, temperature and core performance

C/C++ and MicroPython SDK for Raspberry Pi Pico on Windows

0
A guide to SDK toolchain for Raspberry Pi Pico and C/C++ , Micropython on Windows.

A comprehensive guide to Grafana & InfluxDB

0
How to use Grafana and InfluxDB on Raspberry Pi for IoT sensors in home automation

How to boot Raspberry Pi 4 from USB

0
How to set up and boot Raspberry Pi 4 from USB drive - headless guide.