I'm running an Ubuntu 13.04 server with an encrypted home directory (encryptfs). I keep a tmux session open which holds my development environment (vim, etc). When I disconnect, I'll detach the tmux session and then disconnect the ssh connection. Later, when I reconnect, and reattach the tmux session, I'll get errors such as:
fatal: Could not change back to '(unreachable)/*****': No such file or directory
This will often mean that vim (which was still open while detached) saves to the wrong spot, and won't actually write the file to the disk, only to the "unreachable" directory, which seems temporary.
If I run 'pwd' from bash (not doing anything else since reattaching) I get the proper directory /home/***/***. If I run 'git status', I get the message above (no such file), and if I ':pwd' from within vim, I get "(unreachable)/***".
The temporary fix for this is to run 'cd .' before running any other commands, which allows git/vim/etc to actually see the directory. This is quite inconvenient, since I often have many panels/screens open in tmux and I'd have to run 'cd .' on each of them every time I reconnect. And on top of that, I'd have to make sure vim or anything else, is closed before I disconnect, or I'll likely lose data if I'm not careful.
I saw another thread somewhere that attributed this to encryptfs dismounting $HOME upon logout, but there were no replies. This seems like a possible cause, but I have no idea where to begin. Any help?