Comment 15 for bug 1636890

Revision history for this message
Seth Forshee (sforshee) wrote :

I've reproduced this in a vm (more or less, my timestamps are different but still wrong, but I'm guessing that's just due to different timezone configurations).

Some relevant entries from /proc/mountinfo:

24 26 8:1 / /media/root-ro ro,relatime shared:2 - ext4 /dev/sda1 ro,data=ordered
25 26 0:20 / /media/root-rw rw,relatime shared:3 - tmpfs tmpfs-root rw
26 0 0:21 / / rw,relatime shared:1 - overlayfs overlayroot rw,lowerdir=/media/root-ro,upperdir=/media/root-rw//overlay,workdir=/media/root-rw//overlay-workdir
101 26 0:43 / /home/ubuntu rw,nosuid,nodev,relatime shared:80 - ecryptfs /home/ubuntu/.Private rw,ecryptfs_fnek_sig=8123544c12013d26,ecryptfs_sig=de2cdf716df70cde,ecryptfs_cipher=aes,ecryptfs_key_bytes=16,ecryptfs_unlink_sigs

So, the original root is mounted at /media/root-ro, and there's a tmpfs at /media/root-rw which holds the overlayfs work and upper directories. / is an overlayfs mount, and the encrypted files for my homedir are stored in /home/ubuntu/.Private (which is a symlink to /home/.ecryptfs/ubuntu/.Private).

What I see is that only the files in the root of the ecryptfs mount which come from the lowerdir have incorrect timestamps. A directory I created before enabling overlayroot has the correct timestamp, and two files in that directory also have correct timestamps. New files created in the directory (which thus exist only in the upperdir) have the correct timestamp, however if I modify a file created before overlayroot was enabled the timestamp remains incorrect, and even does so if I remove and create a file of the same name.

The timestamps in /home/.ecruptfs/ubuntu/.Private are all correct. I'm guessing that ecryptfs takes timestamps from the lower directory inodes, so my hunch is that this is a problem in ecryptfs.