This shows you the differences between two versions of the page.
Both sides previous revision Previous revision Next revision | Previous revision Next revision Both sides next revision | ||
сервис_ssh [2023/06/24 19:30] val [SSH вместо RSH] |
сервис_ssh [2024/02/22 07:51] val [SSH вместо RCP (SCP)] |
||
---|---|---|---|
Line 19: | Line 19: | ||
HKEY_CURRENT_USER\Software\SimonTatham\PuTTY\SshHostKeys | HKEY_CURRENT_USER\Software\SimonTatham\PuTTY\SshHostKeys | ||
+ | </code> | ||
+ | |||
+ | === MobaXterm === | ||
+ | |||
+ | * [[https://mobaxterm.mobatek.net/|MobaXterm]] | ||
+ | * [[https://bbs.archlinux.org/viewtopic.php?id=174595|Weird characters while pasting in terminal]] | ||
+ | <code> | ||
+ | printf "\e[?2004l" | ||
</code> | </code> | ||
Line 40: | Line 48: | ||
... | ... | ||
PermitRootLogin yes | PermitRootLogin yes | ||
+ | ... | ||
+ | #KexAlgorithms +diffie-hellman-group1-sha1,diffie-hellman-group-exchange-sha1 | ||
+ | #HostkeyAlgorithms +ssh-dss,ssh-rsa | ||
... | ... | ||
</code> | </code> | ||
Line 67: | Line 78: | ||
ServerAliveInterval 10 | ServerAliveInterval 10 | ||
- | #Host server2* | + | #Host gitlab* |
# Port 2222 | # Port 2222 | ||
- | # User backup | + | ## User root |
- | #Host switch* 192.168.X.3 192.168.X.4 192.168.X.5* | + | #Host switch* 192.168.X.5* |
# KexAlgorithms +diffie-hellman-group1-sha1 | # KexAlgorithms +diffie-hellman-group1-sha1 | ||
# Ciphers +aes128-cbc | # Ciphers +aes128-cbc | ||
Line 100: | Line 111: | ||
==== SSH вместо RCP (SCP) ==== | ==== SSH вместо RCP (SCP) ==== | ||
+ | ==== SCP ==== | ||
<code> | <code> | ||
$ scp -P 2222 val@radio.specialist.ru:/usr/local/www/apache22/data/unix/virus.zip . | $ scp -P 2222 val@radio.specialist.ru:/usr/local/www/apache22/data/unix/virus.zip . | ||
Line 106: | Line 118: | ||
server# sshpass -p cisco scp switchN:running-config /srv/tftp/switchN-running-config | server# sshpass -p cisco scp switchN:running-config /srv/tftp/switchN-running-config | ||
+ | |||
+ | server# scp -3 192.168.X.101:/etc/docker/daemon.json gate:/etc/docker/daemon.json | ||
</code> | </code> | ||
Line 172: | Line 186: | ||
# cat /proc/sys/net/ipv4/ip_local_port_range | # cat /proc/sys/net/ipv4/ip_local_port_range | ||
- | lan# ssh -N -R 61022:localhost:22 user1@server.corpX.un | + | lan# ssh -N -R 61022:localhost:22 -o ServerAliveInterval=60 user1@server.corpX.un |
lan# ssh -N -R 3101:192.168.100+X.101:3389 user1@server.corpX.un | lan# ssh -N -R 3101:192.168.100+X.101:3389 user1@server.corpX.un |