VeraCrypt icon indicating copy to clipboard operation
VeraCrypt copied to clipboard

Hidden volume generation failes with ext4, but works with fat

Open MalteFlender opened this issue 1 year ago • 1 comments

On my Fedora 41 KDE as root via VeraCrypt GUI on VeraCrypt 1.26.20 I try to format a 32 GB USB-stick as non-system partition, hidden volume with AES/SHA-512, files over 4GB enabled with a Linux Ext4 (I also tested Ext3 with the same results) and after the formatting of the outer volume is finished, I get a "The volume you are trying to mount is already mounted." error. Then i am unable to create the hidden volume.

When I try the same course of actions with FAT as filesystem (and therefore files over 4GB disabled) it works fine.

Expected behavior

I expect the creation of a new volume including a hidden volume on Ext4 to work.

Observed behavior

I observe the creation of a new volume including a hidden volume on Ext4 to fail with the "The volume you are trying to mount is already mounted." error.

Steps to reproduce

  1. Click "Create New Volume"
  2. Apply all the settings I gave in my description
  3. Wait for the formatting to finish

Screenshots

Image

Your Environment

VeraCrypt version: VeraCrypt 1.26.20

Operating system and version: Fedora 41 KDE

System type: 64-bit

MalteFlender avatar Feb 11 '25 15:02 MalteFlender

Since outer=FAT inner=ext4 works just fine, you must have tried to use ext4 as outer one. Yes that can be deduced from the Steps list, but could be a tiny tad clearer.

You should know that a hidden volume practically requires the file system to store its metadata at known locations towards the start or end of available space, otherwise the free sectors aren't contiguous or get overwritten too easily. Thus, NTFS would be almost unsuitable as it always stores metadata in the center of the partition - your hidden would always be less than half the allocated size. With ext4, you can expect similar restrictions - and VeryCrypt does warn you. But - agreed, the information given could be a bit clearer, and the actual message isn't a good symptom.

Oh, and I couldn't reproduce on Mint 22.1 Cinnamon edition (based on Ubuntu 24.04), using file containers hosted on Ext4. Outer FAT inner Ext4 gave 99% max usable space while Outer Ext4 inner Ext4 gave ~65% max usable, mountable and writable just fine.

SomeTroglodyte avatar Feb 20 '25 14:02 SomeTroglodyte