←back to thread

Making TRAMP faster

(coredumped.dev)
226 points celeritascelery | 2 comments | | HN request time: 0.415s | source
Show context
kristjansson ◴[] No.44358266[source]
Also, using persistent ssh connections makes a huge difference, esp. if you’ve got a heavy shell init on the local or remote side

  Host *
      ControlPath ~/.ssh/cm-%r@%h:%p
      ControlMaster auto
      ControlPersist 600
replies(3): >>44358619 #>>44360493 #>>44363852 #
1. bqmjjx0kac ◴[] No.44360493[source]
I thought TRAMP overrides that setting in your SSH config.

> TRAMP uses the ControlMaster=auto OpenSSH option by default, if possible. However, it overwrites ControlPath settings when initiating ssh sessions. TRAMP does this to fend off a stall if a master session opened outside the Emacs session is no longer open. That is why TRAMP prompts for the password again even if there is an ssh already open.

https://www.gnu.org/software/emacs/manual/html_node/tramp/Ss...

replies(1): >>44361692 #
2. dietr1ch ◴[] No.44361692[source]
It does and it becomes a bit annoying if you were already persisting sessions, but you can just tell emacs to use the same sockets that ssh sets up.