ethereum / go-ethereum

Go implementation of the Ethereum protocol
https://geth.ethereum.org
GNU Lesser General Public License v3.0
47.55k stars 20.13k forks source link

Via sync ssh drops #20631

Closed matejko94 closed 4 years ago

matejko94 commented 4 years ago

Geth version: last one OS & Version: Linux

The Ethereum light node is synced by geth, but when we tried to sync it we lost ssh connection. We assumed that while it is syncing it is impossible to connect via ssh to computer. If anyone has any idea why this should happen. We also have the most ports closed. The open ports are just ssh, http and one more. This problem happens just in one computer, at other is not possible. Is it possible to sync

ligi commented 4 years ago

You will need to provide more information. What happens exactly? Provide more details please. With an report like this is it not really possible to help you. Details that could help: command line flags on how you started the node, details about the computers (e.g. interesting what is different between the computer that has the problem and the one that does not.) But really every detail can help.

matejko94 commented 4 years ago

Thank you for prompt replay ligi. I wil provide information as much as possible: So in figure below you can see, how I try to run geth.

In one minute happen this network error. Then I couldn't connect like 1hour 30minutes. Is this procedure always re syncing Etherum node from zero. Screenshot from 2020-02-07 19-21-04

For machines where we don't have a problem I used VM virtual box and latest version of Ubuntu. It worked without any problem. The specifications are:

Ligi do you need any system logs or other logs which might be useful for as both? Any ideas?

matejko94 commented 4 years ago

Logs from auth.log.. Here it seems clearly that it log out all users ..

/var/log/auth.log Feb 7 18:17:57 megamrri sshd[25921]: Received disconnect from 122.51.48.118 port 35802:11: Bye Bye [preauth] Feb 7 18:17:57 megamrri sshd[25921]: Disconnected from invalid user csm 122.51.48.118 port 35802 [preauth] Feb 7 18:18:00 megamrri sshd[25926]: Invalid user haw from 106.13.166.110 port 53612 Feb 7 18:18:00 megamrri sshd[25926]: pam_unix(sshd:auth): check pass; user unknown Feb 7 18:18:00 megamrri sshd[25926]: pam_unix(sshd:auth): authentication failure; logname= uid=0 euid=0 tty=ssh ruser= rhost=106.13.166.110 Feb 7 18:18:01 megamrri sshd[25926]: Failed password for invalid user haw from 106.13.166.110 port 53612 ssh2 Feb 7 18:18:01 megamrri sshd[25926]: Received disconnect from 106.13.166.110 port 53612:11: Bye Bye [preauth] Feb 7 18:18:01 megamrri sshd[25926]: Disconnected from invalid user haw 106.13.166.110 port 53612 [preauth] Feb 7 18:25:01 megamrri CRON[25943]: pam_unix(cron:session): session opened for user root by (uid=0) Feb 7 18:25:01 megamrri CRON[25943]: pam_unix(cron:session): session closed for user root Feb 7 18:33:59 megamrri sshd[17776]: pam_unix(sshd:session): session closed for user mihac Feb 7 18:33:59 megamrri systemd-logind[1096]: Removed session 7422. Feb 7 18:35:01 megamrri CRON[25967]: pam_unix(cron:session): session opened for user root by (uid=0) Feb 7 18:35:01 megamrri CRON[25967]: pam_unix(cron:session): session closed for user root Feb 7 18:45:01 megamrri CRON[25992]: pam_unix(cron:session): session opened for user root by (uid=0) Feb 7 18:45:01 megamrri CRON[25992]: pam_unix(cron:session): session closed for user root Feb 7 18:55:01 megamrri CRON[26025]: pam_unix(cron:session): session opened for user root by (uid=0) Feb 7 18:55:01 megamrri CRON[26025]: pam_unix(cron:session): session closed for user root Feb 7 19:05:01 megamrri CRON[26051]: pam_unix(cron:session): session opened for user root by (uid=0) Feb 7 19:05:01 megamrri CRON[26051]: pam_unix(cron:session): session closed for user root Feb 7 19:15:01 megamrri CRON[26075]: pam_unix(cron:session): session opened for user root by (uid=0) Feb 7 19:15:01 megamrri CRON[26075]: pam_unix(cron:session): session closed for user root Feb 7 19:17:01 megamrri CRON[26082]: pam_unix(cron:session): session opened for user root by (uid=0) Feb 7 19:17:01 megamrri CRON[26082]: pam_unix(cron:session): session closed for user root Feb 7 19:18:08 megamrri sshd[26087]: Invalid user dgb from 159.65.12.204 port 45284 Feb 7 19:18:08 megamrri sshd[26089]: Invalid user qgf from 138.68.226.175 port 47470 Feb 7 19:18:08 megamrri sshd[26087]: pam_unix(sshd:auth): check pass; user unknown

ligi commented 4 years ago

what is the difference between the box that had the problem and the box that does not?

matejko94 commented 4 years ago

ok.. it seems that we found the problem.. It was the firewall of the server, which recognized syncing as attack. :) Thank you for your effort Ligi.

ligi commented 4 years ago

Thanks for the response - closing then ..-)