I'm able to use TRAMP fine for reading/writing files on a remote server. I only have to login to the server the first time I open a file, and from then on I can open files without being prompted to login again.
However, when I run commands through TRAMP, I have to login every time. For example, if I run M-x grep ENTER grep -nH -r foo ENTER
, I need to login every time I run that grep
command. I've tried increasing the TRAMP log level and even debugging through the TRAMP code, but I haven't been able to figure out why it can't reuse the same SSH connection to run commands.
This is on OS X. Running M-x version
shows GNU Emacs 24.5.1 (x86_64-apple-darwin14.5.0, NS apple-appkit-1348.17) of 2015-08-24
. Note that I cannot simply make the login process easier by using keys or caching my password, because the server I'm connecting to uses 2fac auth.