Skip to content
Update ssh authored by umaumax's avatar umaumax
......@@ -201,6 +201,7 @@ ssh -N -g -L 8080:localhost:10080 localhost
* `nc`: 300MiB/s
* `nc`,`socat`: 280MiB/s
* `nc`,`ssh`: 260MiB/s
* `nc`,`ssh -C`: 40MiB/s
`mkfifo`: 500-540MiB/s
``` bash
......@@ -225,6 +226,10 @@ pv < /dev/random | nc localhost 28080
## nc, ssh
ssh -N -L 28080:127.0.0.1:8080 localhost
pv < /dev/random | nc localhost 28080
## nc, ssh -C
ssh -C -N -L 28080:127.0.0.1:8080 localhost
pv < /dev/random | nc localhost 28080
```
## `~/.ssh/config`なしの多段ProxyCommand利用時の注意
......@@ -347,6 +352,7 @@ e.g. `ssh-keygen -t ecdsa -b 521`
* `ssh -C``ssh -OCompression`のどちらかを指定すればよい(`gzip`とおなじ`6`(速い/低圧縮率 `1` - `9` 遅い/高圧縮率)であり、プロトコルバージョン`1`のみ変更可能であるので、事実上変更不可である)
* e.g. 100MB/s程度のリモートフォワーディングの場合はおおよそ`sshd`のCPU利用率が50%ほどであった
* AWSからの通信の場合は適用した方が、スループット・レイテンシーともに増えた
* パフォーマンス測定の結果、通常のsshのフォワーディングが260MiB/sのところ、40MiB/sとなった(この場合、sshによる実際の圧縮率は不明)
## tips
### [while内でsshを使うと1回で止まる \- Miuran Business Systems]( http://site.m-bsys.com/error/whileread-ssh )
......
......