Continued importing some old wiki content
This commit is contained in:
parent
b1283325a5
commit
80c6fffa71
3 changed files with 58 additions and 0 deletions
19
content/blog/miscellaneous/reusing-ssh-connections.md
Normal file
19
content/blog/miscellaneous/reusing-ssh-connections.md
Normal file
|
@ -0,0 +1,19 @@
|
|||
---
|
||||
title: Reusing ssh connections
|
||||
date: 2020-02-05
|
||||
description: How to speed up opening multiple ssh to a single host
|
||||
tags:
|
||||
- toolbox
|
||||
---
|
||||
|
||||
## Introduction
|
||||
|
||||
It is possible to share multiple sessions over a single connection. One of the advantages is that for the duration of the connection, all new sessions open very fast.
|
||||
|
||||
## How to
|
||||
|
||||
You need a directory to store the sockets for the opened sessions, I use the `~/.ssh/tmp` directory for it. Whatever you choose, make sure it exists by running `mkdir` now. Then add these two lines at the start of your `~/.ssh/config` :
|
||||
{{< highlight sh >}}
|
||||
ControlMaster auto
|
||||
ControlPath ~/.ssh/tmp/%h_%p_%r
|
||||
{{< /highlight >}}
|
Loading…
Add table
Add a link
Reference in a new issue