files in eCryptFS Private directory get corrupted
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
eCryptfs |
Fix Released
|
High
|
Unassigned | ||
ecryptfs-utils (Ubuntu) |
Invalid
|
Undecided
|
Unassigned |
Bug Description
I'm using a .Private directory to encrypt parts of my home directory. I'm using ext4 in my home and in my ~/Private. Some files turned became corrupted for no apparent reason in that trying to read them produced an "Input/output error" on the console and this in the syslog:
Mar 17 12:08:55 Saffron kernel: [ 2427.492737] Valid eCryptfs headers not found in file header region or xattr region, inode 306879
Mar 17 12:08:55 Saffron kernel: [ 2427.492757] Either the lower file is not in a valid eCryptfs format, or the key could not be retrieved. Plaintext passthrough mode is not enabled; returning -EIO
This includes some chromium files (I'll probably survive that) and some files from my PhD thesis (not funny if it happens before I can git push that stuff out of reach for ecryptfs to mess with).
I found this post from 2009 (!) that matter-of-factly asserts that ecryptfs volumes corrupt files when the disk runs out of space: https:/
I did indeed once run out of disk space but there are younger corruptions.
I also failed to figure out how to fsck an ecryptfs volume. I only found people asking that question with zero answers.
At the current state of affairs I'm seriously considering to switch to full disk encryption and to tell everyone to stay as far away from ecryptfs as possible. If necessary, run.
But maybe I'm missing something regarding the missing fsck and that file corruption bug is easily fixed.
ProblemType: Bug
DistroRelease: Ubuntu 12.04
Package: ecryptfs-utils 96-0ubuntu2
ProcVersionSign
Uname: Linux 3.2.0-18-generic x86_64
ApportVersion: 1.94.1-0ubuntu2
Architecture: amd64
Date: Sat Mar 17 12:10:08 2012
EcryptfsInUse: Yes
InstallationMedia: Lubuntu 12.04 "Precise Pangolin" - Alpha amd64 (20120201.1)
ProcEnviron:
LANGUAGE=en_GB:en
TERM=xterm
PATH=(custom, user)
LANG=en_GB.UTF-8
SHELL=
SourcePackage: ecryptfs-utils
UpgradeStatus: No upgrade log present (probably fresh install)
Oh I should mention that I checked the volumes that let me do that and also ran a smartctl --long check on the disk. Everything seems fine other than on that black box ecryptfs volume.