Comparing Linode and Digital Ocean
On Sunday, Linode had a serious outage in their Newark data center, and the VPS that hosts this web site was down for nearly 24 hours. The Koha installations for two of the libraries in Vermont that I support were down for less time, but still many hours; thankfully these libraries weren’t open on Sunday. After this incident, I decided to look at Digital Ocean as a possible replacement for Linode. Since I use this VPS mostly for serving static content, I ran some Apache benchmark tests to compare the two services.
Digital Ocean Tests
I spun up a “Droplet” on Digital Ocean with the same specs and pricing as
my Linode VPS: 2 GB RAM, 1 CPU (no special premium CPU), 50 GB disk,
Ubuntu 22.04 LTS. Then I installed Apache and used the Apache benchmark
tool (ab
) to run the following tests.
Localhost
Here is a benchmark test while logged into the VPS as root:
ab -n 10000 http://localhost/index.html
This performs 10000 fetches of the default Apache web page. I ran the test several times, and here are the relevant results from the best of these tests:
Concurrency Level: 1
Time taken for tests: 2.520 seconds
Complete requests: 10000
Failed requests: 0
Total transferred: 109450000 bytes
HTML transferred: 106710000 bytes
Requests per second: 3967.64 [#/sec] (mean)
Time per request: 0.252 [ms] (mean)
Time per request: 0.252 [ms] (mean, across all concurrent requests)
Transfer rate: 42407.99 [Kbytes/sec] received
The results varied considerably; the worst of the results was 2017.81 requests per second.
Remote From Home
I then ran a similar test from my laptop, which is located in a rural area with relatively poor internet service (AT&T U-verse via bonded copper phone lines, about 25 MB/S download). Because this access was so much slower, I ran only 100 iterations:
ab -n 100 https://do.example.com/
Here are the relevant results:
Concurrency Level: 1
Time taken for tests: 13.921 seconds
Complete requests: 100
Failed requests: 0
Total transferred: 2812400 bytes
HTML transferred: 2785000 bytes
Requests per second: 7.18 [#/sec] (mean)
Time per request: 139.213 [ms] (mean)
Time per request: 139.213 [ms] (mean, across all concurrent requests)
Transfer rate: 197.29 [Kbytes/sec] received
Remote From Linode
Because the results from home were so poor, I ran a test from the Linode VPS to the Digital Ocean VPS. Both servers are in the same geographic region, and have superior internet connectivity, so the results should not be affected as much as they were by my very poor connectivity at home.
Here are the relevant results:
Concurrency Level: 1
Time taken for tests: 7.123 seconds
Complete requests: 1000
Failed requests: 0
Total transferred: 28124000 bytes
HTML transferred: 27850000 bytes
Requests per second: 140.39 [#/sec] (mean)
Time per request: 7.123 [ms] (mean)
Time per request: 7.123 [ms] (mean, across all concurrent requests)
Transfer rate: 3855.78 [Kbytes/sec] received
Linode Tests
I ran similar tests on Linode, and the results follow.
Localhost
First, a test while logged into the server:
Concurrency Level: 1
Time taken for tests: 1.830 seconds
Complete requests: 10000
Failed requests: 0
Total transferred: 111920000 bytes
HTML transferred: 109180000 bytes
Requests per second: 5464.51 [#/sec] (mean)
Time per request: 0.183 [ms] (mean)
Time per request: 0.183 [ms] (mean, across all concurrent requests)
Transfer rate: 59725.39 [Kbytes/sec] received
As you can see, the localhost tests on Linode were about 40% faster then on Digital Ocean.
Remote From Home
As I did with Digital Ocean, I ran a similar test from my laptop at home. Here are the relevant results:
Concurrency Level: 1
Time taken for tests: 39.205 seconds
Complete requests: 100
Failed requests: 0
Total transferred: 2812400 bytes
HTML transferred: 2785000 bytes
Requests per second: 2.55 [#/sec] (mean)
Time per request: 392.051 [ms] (mean)
Time per request: 392.051 [ms] (mean, across all concurrent requests)
Transfer rate: 70.05 [Kbytes/sec] received
The remote from home test was much slower for Linode than for Digital Ocean. But see Conclusions below for an interpretation of this result.
Remote from Digital Ocean
Because the results from home were so poor, I ran a test from the Digital Ocean VPS to the Linode VPS. Here are the relevant results:
Concurrency Level: 1
Time taken for tests: 7.094 seconds
Complete requests: 1000
Failed requests: 0
Total transferred: 28124000 bytes
HTML transferred: 27850000 bytes
Requests per second: 140.97 [#/sec] (mean)
Time per request: 7.094 [ms] (mean)
Time per request: 7.094 [ms] (mean, across all concurrent requests)
Transfer rate: 3871.65 [Kbytes/sec] received
Here we can see that when connectivity is good, Linode and Digital Ocean have similar performance serving a web page.
Hetzner
Some commenters on LWN’s note about the Linode outage mentioned Hetzner favorably as an alternative cloud provider. I brought up their lowest cost VPS, which had two CPUS and 4 GB of RAM: double the resources of Linode but less half the price. On cost, Hetzner is the clear winner. But the performance running the Apache benchmark from Linode to Hetzner was very poor: about a tenth of the throughput of either Linode or Digital Ocean. So that doesn’t look like a good alternative for my purposes.
Conclusions
I realize this is not an exhaustive test, but it is clear that for whatever reason (e.g. CPU speed or disk speed), Linode has a significant speed advantage (around 40%) over Digital Ocean.
But testing web server speed from a remote host (my laptop at home) gave a very different story. Here, Digital Ocean’s VPS delivered a web page more than twice as quickly as Linode.
Both of the VPSs are located in the same geographical area (SF Bay Area). But for some reason, traceroute from my home to the Linode VPS takes much longer than to the Digital Ocean VPS: 75 ms and 23 hops for Linode, vs. 25 ms and 13 hops for Digital Ocean. This is probably the major factor in the difference in performance between the two services when fetching web pages from home.
In an attempt to eliminate the problem with poor connectivity at home, I reran the tests by using each VPS to fetch a web page from the other VPS. This time, Linode was about the same as Digital Ocean, though the results varied from day to day; in one test I ran, Linode was 35% faster than Digital Ocean.
Linode has a “warm migration” feature that is missing on Digital Ocean. After the outage, I migrated my VPS to a data center closer to home, and there was almost no downtime. On Digital Ocean, I would have had to shut down the VPS before doing a migration. However, since I expect migrations would be very rare, this may not be a significant issue.
More importantly, Linode allows sending emails from a VPS, which allows me to run an SMTP-using old-fashioned email client on my VPS. Digital Ocean blocks all SMTP ports, and this block cannot be removed. That means I cannot run my email client on DO; I’d have to use their fancy complicated EmailEngine REST API, or possibly use a service like SMTP2GO. Supposedly new accounts on Linode have SMTP blocks, but mine is old enough to have escaped this block, at least for now.
I’ll stick with Linode unless there is some compelling need to switch in the future.