Leaving unbiased ratings and writing technical reviews is a difficult task, especially when the author has to assess quality and performance of computer and peripherals hardware.

A typical scenario: reviewing a USB thumb drive

USB thumb drives are a good option for those who need to store back up data or boot up a system. As they are usually sold preformatted using the FAT32 file system, USB thumb drives have to be reformatted using Ext4 or NTFS, should the user need for a more robust file system. While Microsoft Windows users should not experience a decline in performance when switching from FAT32 to NTFS, those ones who rely on Linux might, right after having switched to either the above mentioned journaling file systems. Is this behavior caused by the hardware or the software? USB thumb drives are special type of NAND memories, managed through the FTL (Flash Translation Layer), a piece of (usually proprietary) software embedded into the device firmware that allows the OS to read and write these devices as if they were rotating disk drives. Therefore, the FTL consists of algorithms that the OS has to interact with without having a full knowledge of. Moreover, some FTLs are known to be optimized for specific file systems (usually FAT32). At this stage the reader should bear in mind that writing FTLs or any other piece of software that has to interact with them is an extremely difficult task. Then... was the newly purchased USB thumb drive a good deal that only requires the system administrator to perform some operating system kernel parameters fine tuning?

Running an Ext4 and a NTFS USB thumb drive on Linux

This section of the post shows the result of a test that was conducted using a USB thumb drive (3.0) and Linux. The device was formatted using Ext4 and then NTFS and the transfer rate during a copy operation was measured with default and tuned kernel parameters. The file being copied is a approximately 120Mb Linux executable and the output below shows the amount of dirty memory (buffered data that has not been flushed yet) and writeback (amount of dirty pages in memory flushed onto permanent storage).

The test starts with the Ext4 and default kernel parameters:

Tue 19 Oct 2021 11:10:13 AM UTC
Dirty:            120436 kB
Writeback:             0 kB
...
Tue 19 Oct 2021 11:11:04 AM UTC
Dirty:                12 kB
Writeback:             0 kB

Next, the thumb drive is tested with Ext4 and a smaller OS cache (vm.dirty_background_ratio = 5, vm.dirty_ratio = 10):

Tue 19 Oct 2021 11:14:45 AM UTC
Dirty:             43964 kB
Writeback:             0 kB
...
Tue 19 Oct 2021 11:15:33 AM UTC
Dirty:                16 kB
Writeback:             0 kB

Next, the thumb drive is tested with Ext4 and a cache set to zero (vm.dirty_background_ratio = 0, vm.dirty_ratio = 0):

Tue 19 Oct 2021 11:19:15 AM UTC
Dirty:               156 kB
Writeback:             0 kB
...
Tue 19 Oct 2021 11:20:33 AM UTC
Dirty:                 0 kB
Writeback:             0 kB

Finally, the thumb drive is tested with Ext4 and a larger cache (vm.dirty_background_ratio = 50, vm.dirty_ratio = 80):

Tue 19 Oct 2021 11:48:26 AM UTC
Dirty:              4308 kB
Writeback:             0 kB
...
Tue 19 Oct 2021 11:49:20 AM UTC
Dirty:                12 kB
Writeback:             0 kB

Now the thumb drive is tested with tested with the NTFS file system and the default kernel parameters:

Tue 19 Oct 2021 11:23:23 AM UTC
Dirty:                36 kB
Writeback:             0 kB
...
Tue 19 Oct 2021 11:26:16 AM UTC
Dirty:                 0 kB
Writeback:             0 kB

Next, the thumb drive is tested with NTFS and a smaller OS cache (vm.dirty_background_ratio = 5, vm.dirty_ratio = 10):

Tue 19 Oct 2021 11:27:32 AM UTC
Dirty:             56808 kB
Writeback:             0 kB
...
Tue 19 Oct 2021 11:28:20 AM UTC
Dirty:                 0 kB
Writeback:             0 kB

Next, the thumb drive is tested with NTFS and the OS cache set to zero (vm.dirty_background_ratio = 0, vm.dirty_ratio = 0):

Tue 19 Oct 2021 11:29:52 AM UTC
Dirty:                 0 kB
Writeback:            48 kB
...
Tue 19 Oct 2021 11:36:50 AM UTC
Dirty:                 0 kB
Writeback:             0 kB

Finally, the thumb drive is tested with NTFS and a larger OS cache (vm.dirty_background_ratio = 50, vm.dirty_ratio = 80):

Tue 19 Oct 2021 11:51:12 AM UTC
Dirty:             18424 kB
Writeback:             0 kB
...
Tue 19 Oct 2021 11:52:03 AM UTC
Dirty:                 0 kB
Writeback:             0 kB

The same USB thumb drive formatted with the NTFS file system was faster on Windows 8.1 than all previous configurations.

Analysis of the results

Even though the thumb drive formatted with the NTFS file system plugged onto a Windows system performed slightly better than any other combination, it is evident that the same device behaved differently as the software configuration changed.

While the speed on which files are copied onto a USB thumb drive might not be a topic of concern, it might lead to corrupted file systems when the following scenario eventuates:

  1. The user starts a very large copy operation.
  2. The user correctly initiates the ejection procedure.
  3. The system is still busy copying the file(s) and no feedback is sent to the user in regard to the ejection procedure.
  4. The user just assumes the system message has not been displayed because of a glitch or it was just overlooked.
  5. The user prematurely unplugs the USB thumb drive.
  6. The file system becomes corrupted.
How to write a review then?

Although there is no one-size-fits-all approach, do not always assume the problem is with the hardware as all computer hardware manufacturers know very well the cost of a botched release. Software companies can easily fix issues by releasing software updates but this is not the case for any malfunctioning electronic component. While a single failed CPU or memory design has the potential to send entire organizations bankrupt, software companies usually survive catastrophic releases as they can always release patches. This is not to say that testing and quality control processes are stricter in the hardware world than in the software one, but it's just to show what's behind well written professional reviews.

Previous Post