Uploading Very Large Files (Increasing the Maximum Upload Size)
TLDR - Quick Summary
What: Understand the maximum single-file upload size when your cloud connection writes to Google Cloud Storage.
Short answer: there is nothing to raise. SFTP Gateway streams uploads to Cloud Storage with a resumable upload managed by the Google SDK, so a single file can be as large as Cloud Storage allows, about 5 TB.
If a large upload still fails: the cause is not a piece-size ceiling. Check backend memory and the client's timeouts (see below).
Other clouds: only S3 and Azure Blob connections have a configurable piece size; those settings are covered in the AWS and Azure articles.
Go further: SFTP Gateway for the Enterprise
Running secure file transfer at enterprise scale? Our free white paper covers high-availability SFTP Gateway architecture, security and compliance, and cloud integration across AWS, Azure, and Google Cloud.
👉 Download the SFTP Gateway white paper — free; a short registration unlocks the PDF.
Overview
Some object stores make SFTP Gateway upload files in fixed-size pieces and cap the number of pieces per object, which puts a ceiling on the largest single file. Google Cloud Storage does not work this way. SFTP Gateway streams each upload directly to Cloud Storage as a resumable upload managed by the Google SDK, with no configurable piece size and no piece-count limit. The only ceiling is Cloud Storage's own object size limit of about 5 TB.
So on a Compute Engine deployment writing to Cloud Storage, there is no application.properties setting to raise for large files.
This article extends the Application Properties reference. For broader throughput and memory tuning, see Performance Tuning SFTP Gateway.
Cloud Storage limit
| Storage | Setting | Default | Piece limit | Max single file |
|---|---|---|---|---|
| Google Cloud Storage | not configurable | managed by Google SDK | none | about 5 TB (Google limit) |
If a large upload to Cloud Storage fails
Because there is no piece-size ceiling, a failing large upload usually points somewhere else:
- Backend memory. In-progress uploads are buffered in the SFTP Gateway backend's heap. If the instance is undersized for the number of concurrent transfers, large uploads are the first to fail. See Configuring VM Memory Settings and the memory section of Performance Tuning SFTP Gateway.
- Client timeouts and retries. Many SFTP clients abort a long transfer on an idle timeout and then restart from the beginning, which looks like the upload "keeps restarting." Raise the client's timeout or use a client that supports resuming.
- Instance size. Throughput is CPU-bound; a small machine type will make very large transfers slow enough to hit client timeouts. See the instance sizing section of Performance Tuning SFTP Gateway.
Connections to other clouds
An SFTP Gateway instance can have cloud connections to more than one provider, and the piece-size ceiling does apply to some of them. If this instance also writes to Amazon S3, see Increasing Max Upload File Size (AWS). If it also writes to Azure Blob, see Increasing Max Upload File Size (Azure).