Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I am trying to secure my Dropbox account by using EncFS. My strategy is as follows:

  • I store all my files in a folder called ~/Public/.
  • The encrypted counterpart of ~/Public/ is ~/Private/.
  • Use EncFS: encfs ~/Private/ ~/Public/

Now the problem is that I'd like to use Dropbox for backing up my dotfiles as well. So I tried symlinking ~/.rc/ (the folder containing my dotfiles) into ~/Public. But EncFS seems to treat the symlink as a file and it shows up in ~/Private as 0 byte file. Any way I can get EncFS to follow symlinks?

share|improve this question
up vote 3 down vote accepted

Encfs stores what you tell it to store. If you tell it to store a symbolic link, it'll store a symbolic link.

If you want a file to be encrypted, you need to store it on the encrypted filesystem. Creating a symbolic link to the file won't move it.

(If you created two symbolic links to the file, on two different encrypted filesystems, would you expect it to be stored in both? That would be utterly bizarre.)

So move your dotfile directory to the encrypted filesystem, and create a symbolic link to where you want to have a view of these files:

mv ~/.rc ~/Public/
ln -s Public/.rc ~/
share|improve this answer

Do it the other way around: move the dotfiles into ~/Public and make symlinks to them in your home directory.

I imagine there may be some programs that will detect this chicanery, but I doubt there would be many.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.