Ubuntu: Do I need unencrypted files underneath encrypted overmount?



Question:

I have unencrypted files in my /home/user dir (likely fallout from moving my home dir to a different partition).

/dev/sda1             440G  137G  282G  33% /home  /home/user/.Private  440G  137G  282G  33% /home/user  

If I ls /home/user while logged on as a different user, I see older contents of that dir since the encrypted file isn't mounted.

Do I need those files? And if not, what is a safe way to delete them?


Solution:1

Looking at the unmounted encrypted home directory of a non-logged-in user, I see some unencrypted files (well they're really directories and links):

$ /bin/ls -la /home/walt  total 12  dr-x------  3 w3   walt 4096 Apr  9 22:12 .  drwxr-xr-x 13 root root 4096 Sep  1  2015 ..  lrwxrwxrwx  1 walt walt   56 Oct 22  2011 Access-Your-Private-Data.desktop -> /usr/share/ecryptfs-utils/ecryptfs-mount-private.desktop  drwx------  7 walt walt 4096 Jan 16  2013 .cache  lrwxrwxrwx  1 walt walt   30 Oct 22  2011 .ecryptfs -> /home/.ecryptfs/walt/.ecryptfs  lrwxrwxrwx  1 walt walt   29 Oct 22  2011 .Private -> /home/.ecryptfs/walt/.Private  lrwxrwxrwx  1 walt walt   52 Oct 22  2011 README.txt -> /usr/share/ecryptfs-utils/ecryptfs-mount-private.txt  

You don't need any other files. You could delete the files with something like find /home/user -maxdepth 1 \( \! -type l -a -type d \) -exec echo rm {} \;, remove the echo when you are thrilled with the results of the find


Note:If u also have question or solution just comment us below or mail us on toontricks1994@gmail.com
Previous
Next Post »