ssh:ssh_reverse_tunnel

Unterschiede

Hier werden die Unterschiede zwischen zwei Versionen angezeigt.

Link zu dieser Vergleichsansicht

Beide Seiten der vorigen Revision Vorhergehende Überarbeitung
ssh:ssh_reverse_tunnel [2024/11/27 20:27] nikssh:ssh_reverse_tunnel [2024/11/27 20:27] (aktuell) nik
Zeile 12: Zeile 12:
  
 2. S 2. S
-<code | download>+<code>
 nano /root/.ssh/authorized_keys nano /root/.ssh/authorized_keys
 nano /etc/ssh/sshd_config nano /etc/ssh/sshd_config
 </code> </code>
-<code | download>+<code>
 GatewayPorts yes GatewayPorts yes
 ClientAliveInterval 60 ClientAliveInterval 60
Zeile 22: Zeile 22:
 </code> </code>
  
-<code | download>+<code>
 netstat -tulpn netstat -tulpn
 </code> </code>
Zeile 28: Zeile 28:
  
 3. C 3. C
-<code | download>+<code>
 ssh -p 22 -N -R 8080:localhost:8000 root@129.159.10.245 ssh -p 22 -N -R 8080:localhost:8000 root@129.159.10.245
 </code> </code>
Zeile 35: Zeile 35:
  
 4. C 4. C
-<code | download>+<code>
 autossh -M 0 -f -o ConnectTimeout=10 -o ServerAliveInterval=60 -o ServerAliveCountMax=2 -p 22 -N -R 8080:localhost:8000 root@129.159.10.245 autossh -M 0 -f -o ConnectTimeout=10 -o ServerAliveInterval=60 -o ServerAliveCountMax=2 -p 22 -N -R 8080:localhost:8000 root@129.159.10.245
 </code> </code>
 ->ggfs. mit ps aux | grep ssh die PID suchen und mit kill PID wieder killen ->ggfs. mit ps aux | grep ssh die PID suchen und mit kill PID wieder killen
  
-<code | download>+<code>
 crontab -e crontab -e
 </code> </code>
-<code | download>+<code>
 @reboot autossh -M 0 -f -o ConnectTimeout=10 -o ServerAliveInterval=60 -o ServerAliveCountMax=2 -p 22 -N -R 8080:localhost:8000 root@129.159.10.245 @reboot autossh -M 0 -f -o ConnectTimeout=10 -o ServerAliveInterval=60 -o ServerAliveCountMax=2 -p 22 -N -R 8080:localhost:8000 root@129.159.10.245
 </code> </code>
  • ssh/ssh_reverse_tunnel.1732739225.txt.gz
  • Zuletzt geändert: 2024/11/27 20:27
  • von nik