SSH to overseas server too slow?

UPDATE (2018-05-03):

I ended up using a BandWagon VPS as high volume traffic proxy with an AEAD encryption method and another faster one as a backup instead of those ssh forwarding stuff, it was unstable and quickly fallen only one month later and never be fast again.


The original post:

Use China mainland cloud server as a hop.

1
ssh -v -N -L 2222:remote.oversea:2222  cloud.mainland

Then:

1
ssh -p 2222 root@localhost

Or even mount as a local folder:

1
sshfs -p 2222 root@localhost:/var/www/html ~/docker/nhweb -oauto_cache,reconnect,defer_permissions,noappledouble,negative_vncache,volname=nhweb

A few sweet ssh features to improve your development experience.

Expose local port to internet with a delegate:

1
2
3
4
5
6
7
# Remote server
sudo vi /etc/ssh/sshd_config
# Append below content:
# GatewayPorts yes

# Local
ssh -v -N -R *:9090:localhost:8080 cloud.mainland

Then heading to http://cloud.mainland:9090 for the results.

Ref: