Troubleshoot slow performance

This page provides troubleshooting information to help address slow performance issues you might encounter while using Filestore.

Slow read or write performance

  1. Ensure that you are using the recommended machine type for the client VM.
  2. If your client VM is running Linux, confirm that you're using the default mount options.

  3. Ensure that the client VM is located in the same region as the Filestore instance. Mounting across regions not only reduces performance, it also incurs a networking cost.

  4. Ensure that your Filestore instance isn't at or near full capacity. When capacity is nearly full, any remaining space is highly fragmented, causing read and write operations to slow down. The amount of free space needed to avoid this scenario is case-dependent. We recommend setting up low disk space alerts.

  5. Test the performance of your Filestore instance using the fio tool.

    If the test results show abnormally slow performance, contact your account representative. If the test results show similar or greater performance than expected, continue to the next section.

Use cases that cause slow performance

Here are some use cases and scenarios that cause poor performance:

Workloads involving high volumes of small files

Filestore file shares use the sync export option for data safety and NFS protocol compliance. For most data-modifying operations, the Filestore instance waits for the data to be committed to storage before replying to requests from the client VM. When many files are involved in an operation, the client makes a long series of synchronous operations and the cumulative latency adds up.

An example of this scenario is when you extract an archive on the file share, like tar files. TAR makes many synchronous operations in a series when extracting an archive containing many files. As a result, performance is reduced.

If you're trying to copy many small files to a file share, try parallelizing file creation with a tool like gsutil:

mkdir -p /mnt/nfs/many_files_rsync/
time gsutil -m -q rsync -rp many_files /mnt/nfs/many_files_rsync/

Copying data between Cloud Storage and Filestore

Copying data from Cloud Storage to a Filestore instance using gsutil is known to be slow. For detailed information on how to improve performance, see Improve performance across Google Cloud resources.

What's next