mirror of https://gitee.com/openkylin/docs.git
update en/Development-And-Common-Documents/Basic_SSH_Usage.md.
Signed-off-by: wucaiheng <11866284+wucaiheng@user.noreply.gitee.com>
This commit is contained in:
parent
fa2e1c042a
commit
7ad06c807f
|
@ -10,12 +10,12 @@
|
|||
`ssh Username@host -p port`
|
||||
Then you will be prompted to enter a password, the password is the password of the user name you want to log in, the user must exist, and is allowed to log in only, in general, we install the system when the establishment of the user is no problem, and the default password does not return to show.
|
||||
|
||||
He can also proxy x11 protocol, transfer the interface to the local, but actually run in the remote host, but the remote host needs to install xauth, and, both local and remote start x11 proxy to be able to, the actual test some applications may not be supported, in addition, if the local system is win, it may not work well, if it is linux then as long as the network speed is enough or The disadvantage is that you may not be able to use Chinese input method, you can only copy and paste, although you can configure the way to let the input method start, but I have not succeeded. In addition, there is a port mapping role, generally speaking, called ssh tunneling, you can map the remote port to the local, you can also map the local port to the remote, but also can be changed to a two-way, so that you can be used as an intranet penetration, or local services exposed to the remote, you can also turn the remote port into local access, and is encrypted with ssh do not worry about being eavesdropped, etc., generally In general, the development will be used more, the database port mapping to a local port, direct access, without opening the corresponding port of the public network to improve security, and then for example, vnc, the vnc port mapping to the local, although vncview prompt not encrypted, but the data transmitted in the middle is ssh encrypted, do not worry about being eavesdropped, and can close the corresponding port firewall ssh can disable password login and only use key login, or both, as long as there is a public key and private key, and then put the public key into a specific file, you can directly use the private key to login without encryption.
|
||||
He can also proxy the x11 protocol to transfer the interface locally and actually run it on the remote host, though it requires the remote host to install xauth and start the x11 proxy both locally and remotely to do so. Some applications may not be supported during actual testing. In addition, if the local system is win, it may not work well, if it is linux, the experience is still quite good with sufficient network speed. The downside is that it may not be possible to use Chinese input methods, only copy and paste, although you can configure the input method to start, but I have not succeeded. The other is the role of a port mapping, generally speaking, called ssh tunneling, you can map the remote port to the local, the local port mapping to the remote, or change to double, so used as an intranet penetration, the second is to expose the local service in the remote, but also the remote port into local access, with ssh encryption without worrying about being eavesdropped, etc., in general, the development will be used more In general, the development will be used more often, the database port mapping to a local port, direct access, without opening the corresponding port of the public network to improve security. For example, vnc, mapping the port of vnc to local, although the vncview prompt is not encrypted, but the data transmitted in the middle is encrypted by ssh, do not worry about being eavesdropped, but also can close the firewall of the corresponding port, others can not scan. ssh can disable the password login and only use the key login, or both, as long as there is a public key and private key, and then the public key into a specific You can use the private key for password-free login directly by having a public key and a private key in a specific file.
|
||||
|
||||
2. SSh a little trick, ssh if in a period of time does not respond then you can modify the heartbeat time, every certain time to send an empty packet, keep the response, in general I do not recommend setting the time more than 30, if the network environment is almost 30 may be broken, generally set to 15, extreme cases set to 5, here in seconds.
|
||||
2. SSh a little trick, if in a period of time does not respond then you can modify the heartbeat time, every certain time to send an empty packet, keep the response, in general I do not recommend setting the time more than 30, if the network environment is almost 30 may be broken, generally set to 15, extreme cases set to 5, here in seconds.
|
||||
There is also the fact that if you exit the ssh, then the running program will be killed, you can use the screen command to let the program run in the background, and then Ctrl + a + d to return, so you can exit the ssh without worrying about the program hanging, the recovery command is also available.
|
||||
|
||||
3. If it's the first time you log into a host a prompt will appear, something like the following.
|
||||
3. If it's the first time to log in a host will appear a prompt, roughly as follows:
|
||||
|
||||
This is the first time you log into a new host to give the prompt, as to why this prompt, because the ssh communication process leads to, is a kind of verification method, specific you can check the Baidu, it should be noted that here only enter yes to continue, simply a y or enter is not allowed, then enter the password to log in, after successful login will display some welcome message, and the last login address.
|
||||
Then enter the password to log in, after successful login will display some welcome message, and the last login address.
|
||||
|
|
Loading…
Reference in New Issue