Best way to combine ControlPersist and ProxyCommand?

Do you have a question? Post it now! No Registration Necessary.  Now with pictures!

Hi all,

What's the best way to set up a persistent master connection, along with a  
proxy jump host? Ideally the persistent master would speed up connections t
o machines behind the proxy, not just the connection to the proxy.

Is this okay?

Host jumpbox
    User           jumpboxuser
    IdentityFile   jumpbox_key
    ControlMaster  auto
    ControlPath    ~/.ssh/controlmaster-%r@%h:%p
    ControlPersist 5m

Host internal1 internal2 internal3 internal4
    User           internaluser
    IdentityFile   internal_key
    ProxyCommand   ssh -W %h:%p -F ssh.config jumpbox
    ControlMaster  auto
    ControlPath    ~/.ssh/controlmaster-%r@%h:%p
    ControlPersist 5m

I was worried that the internal[1234] controlmaster connections would be mu
ltiplexed through the jumpbox one, but I stopped the jumpbox master with "-
O stop", verified that the socket file was gone, and the internal[1234] con
trolmaster connections seemed to keep working.


Site Timeline