This project has moved. For the latest updates, please go here.

Is there a size limit to an encrypted file container?

Topics: Technical Issues, Users Discussion
Feb 3, 2016 at 9:14 PM
I am trying to create a 16TB file container on a network drive to store backups for a business. I am unable to find any documented limitation but when I try to create the file, it fails. I get to the volume format step and I can see the 16TB file created on the network drive but it will eventually fail with a message that the network location is no longer available. The progress bar never starts to fill and the "Done" "Speed" and "Left" boxes remain blank. I retried the process with a 1TB file and it worked fine. Am I doing something wrong with this big file or am I running into a limitation?
Feb 4, 2016 at 12:00 AM
The size limits for file container is much higher than 16 TB: it is set to 1PB which is equal to 1000 TB.
In practive, the size limit comes from the operating system or the file system, not VeraCrypt.
In your case, this is exactly what is happening since the it is the network drive who refuses to create the 16 TB file (VeraCrypt only calls the operating system function to perform file creation).

FYI, here is an excerpt of the file src/Common/Volumes.h which contains the value of various limits:
// Filesystem size limits
#define TC_MIN_FAT_FS_SIZE              (9 * TC_MAX_VOLUME_SECTOR_SIZE)
#define TC_MAX_FAT_SECTOR_COUNT         0x100000000ULL
#define TC_MIN_NTFS_FS_SIZE             (884 * TC_MAX_VOLUME_SECTOR_SIZE)
#define TC_MAX_NTFS_FS_SIZE             (128LL * BYTES_PER_TB)  // NTFS volume can theoretically be up to 16 exabytes, but Windows XP and 2003 limit the size to that addressable with 32-bit clusters, i.e. max size is 128 TB (if 64-KB clusters are used).
#define TC_MAX_FAT_CLUSTER_SIZE         (256 * BYTES_PER_KB)    // Windows XP/Vista may crash when writing to a filesystem using clusters larger than 256 KB
#define TC_MAX_EXFAT_FS_SIZE            (128LL * BYTES_PER_PB)

// Volume size limits
#define TC_MAX_VOLUME_SIZE_GENERAL      0x7fffFFFFffffFFFFLL    // Signed 64-bit integer file offset values
Feb 4, 2016 at 12:21 PM
The network drive I'm working with is a NAS with an EXT3 volume. Any info on EXT3?
Feb 4, 2016 at 12:39 PM
The maximum file size for Ext3 is 2TB (it can be much less in certain configurations). See
Feb 4, 2016 at 12:49 PM
Interesting. I was able to start formatting a 15000GB file just now so I'll let it run and see if it errors out