Score:0

Ubuntu server stops working everyday overnight

cn flag

Everyday, my ubuntu server stops responding (I think overnight) and I have to restart it. I cant even SSH on. These are the server logs for the morning (before restart):

Jul 01 23:54:37 hcah sshd[4085]: Disconnecting authenticating user root 103.131.52.4 port 44684: Too many authentication failures [preauth]
Jul 01 23:54:40 hcah sshd[4087]: Received disconnect from 103.131.52.4 port 47265:11: disconnected by user [preauth]
Jul 01 23:54:40 hcah sshd[4087]: Disconnected from authenticating user root 103.131.52.4 port 47265 [preauth]
Jul 01 23:54:42 hcah sshd[4089]: Invalid user admin from 103.131.52.4 port 48297
Jul 01 23:54:43 hcah sshd[4089]: error: maximum authentication attempts exceeded for invalid user admin from 103.131.52.4 port 48297 ssh2 [preauth]
Jul 01 23:54:43 hcah sshd[4089]: Disconnecting invalid user admin 103.131.52.4 port 48297: Too many authentication failures [preauth]
Jul 01 23:54:45 hcah sshd[4091]: Invalid user admin from 103.131.52.4 port 49361
Jul 01 23:54:47 hcah sshd[4091]: error: maximum authentication attempts exceeded for invalid user admin from 103.131.52.4 port 49361 ssh2 [preauth]
Jul 01 23:54:47 hcah sshd[4091]: Disconnecting invalid user admin 103.131.52.4 port 49361: Too many authentication failures [preauth]
Jul 01 23:54:49 hcah sshd[4093]: Invalid user admin from 103.131.52.4 port 50484
Jul 01 23:54:49 hcah sshd[4093]: Received disconnect from 103.131.52.4 port 50484:11: disconnected by user [preauth]
Jul 01 23:54:49 hcah sshd[4093]: Disconnected from invalid user admin 103.131.52.4 port 50484 [preauth]
Jul 01 23:54:51 hcah sshd[4095]: Invalid user oracle from 103.131.52.4 port 51352
Jul 01 23:54:52 hcah sshd[4095]: error: maximum authentication attempts exceeded for invalid user oracle from 103.131.52.4 port 51352 ssh2 [preauth]
Jul 01 23:54:52 hcah sshd[4095]: Disconnecting invalid user oracle 103.131.52.4 port 51352: Too many authentication failures [preauth]
Jul 01 23:54:54 hcah sshd[4097]: Invalid user oracle from 103.131.52.4 port 52492
Jul 01 23:54:56 hcah sshd[4097]: error: maximum authentication attempts exceeded for invalid user oracle from 103.131.52.4 port 52492 ssh2 [preauth]
Jul 01 23:54:56 hcah sshd[4097]: Disconnecting invalid user oracle 103.131.52.4 port 52492: Too many authentication failures [preauth]
Jul 01 23:54:58 hcah sshd[4099]: Invalid user oracle from 103.131.52.4 port 53542
Jul 01 23:54:58 hcah sshd[4099]: Received disconnect from 103.131.52.4 port 53542:11: disconnected by user [preauth]
Jul 01 23:54:58 hcah sshd[4099]: Disconnected from invalid user oracle 103.131.52.4 port 53542 [preauth]
Jul 01 23:55:00 hcah sshd[4101]: Invalid user usuario from 103.131.52.4 port 54279
Jul 01 23:55:01 hcah sshd[4101]: error: maximum authentication attempts exceeded for invalid user usuario from 103.131.52.4 port 54279 ssh2 [preauth]
Jul 01 23:55:01 hcah sshd[4101]: Disconnecting invalid user usuario 103.131.52.4 port 54279: Too many authentication failures [preauth]
Jul 01 23:55:03 hcah sshd[4103]: Invalid user usuario from 103.131.52.4 port 55590
Jul 01 23:55:05 hcah sshd[4103]: error: maximum authentication attempts exceeded for invalid user usuario from 103.131.52.4 port 55590 ssh2 [preauth]
Jul 01 23:55:05 hcah sshd[4103]: Disconnecting invalid user usuario 103.131.52.4 port 55590: Too many authentication failures [preauth]
Jul 01 23:55:07 hcah sshd[4105]: Invalid user usuario from 103.131.52.4 port 56773
Jul 01 23:55:07 hcah sshd[4105]: Received disconnect from 103.131.52.4 port 56773:11: disconnected by user [preauth]
Jul 01 23:55:07 hcah sshd[4105]: Disconnected from invalid user usuario 103.131.52.4 port 56773 [preauth]
Jul 01 23:55:07 hcah sshd[4107]: Unable to negotiate with 209.141.43.233 port 36274: no matching key exchange method found. Their offer: diffie-hellman-group14-sha1,diffie-hellman-group-exchange-sha1,diffie-hellman-group1-sha1 [preauth]
Jul 01 23:55:09 hcah sshd[4109]: Invalid user test from 103.131.52.4 port 57479
Jul 01 23:55:10 hcah sshd[4109]: error: maximum authentication attempts exceeded for invalid user test from 103.131.52.4 port 57479 ssh2 [preauth]
Jul 01 23:55:10 hcah sshd[4109]: Disconnecting invalid user test 103.131.52.4 port 57479: Too many authentication failures [preauth]
Jul 01 23:55:12 hcah sshd[4111]: Invalid user test from 103.131.52.4 port 58644
Jul 01 23:55:14 hcah sshd[4111]: error: maximum authentication attempts exceeded for invalid user test from 103.131.52.4 port 58644 ssh2 [preauth]
Jul 01 23:55:14 hcah sshd[4111]: Disconnecting invalid user test 103.131.52.4 port 58644: Too many authentication failures [preauth]
Jul 01 23:55:15 hcah kernel: [UFW BLOCK] IN=ens192 OUT= MAC=00:50:56:0b:82:6d:00:50:56:af:33:4a:08:00 SRC=74.120.14.27 DST=77.68.84.223 LEN=44 TOS=0x00 PREC=0x00 TTL=41 ID=17691 PROTO=TCP SPT=23868 DPT=993 WINDOW=1024 RES=0x00 SYN URGP=0 
Jul 01 23:55:16 hcah sshd[4113]: Invalid user test from 103.131.52.4 port 59839
Jul 01 23:55:16 hcah sshd[4113]: Received disconnect from 103.131.52.4 port 59839:11: disconnected by user [preauth]
Jul 01 23:55:16 hcah sshd[4113]: Disconnected from invalid user test 103.131.52.4 port 59839 [preauth]
Jul 01 23:55:18 hcah sshd[4115]: Invalid user user from 103.131.52.4 port 60589
Jul 01 23:55:19 hcah sshd[4115]: error: maximum authentication attempts exceeded for invalid user user from 103.131.52.4 port 60589 ssh2 [preauth]
Jul 01 23:55:19 hcah sshd[4115]: Disconnecting invalid user user 103.131.52.4 port 60589: Too many authentication failures [preauth]
Jul 01 23:55:21 hcah sshd[4117]: Invalid user user from 103.131.52.4 port 61856
Jul 01 23:55:23 hcah sshd[4117]: error: maximum authentication attempts exceeded for invalid user user from 103.131.52.4 port 61856 ssh2 [preauth]
Jul 01 23:55:23 hcah sshd[4117]: Disconnecting invalid user user 103.131.52.4 port 61856: Too many authentication failures [preauth]
Jul 01 23:55:25 hcah sshd[4119]: Invalid user user from 103.131.52.4 port 63031
Jul 01 23:55:25 hcah sshd[4119]: Received disconnect from 103.131.52.4 port 63031:11: disconnected by user [preauth]
Jul 01 23:55:25 hcah sshd[4119]: Disconnected from invalid user user 103.131.52.4 port 63031 [preauth]
Jul 01 23:55:27 hcah sshd[4121]: Invalid user ftpuser from 103.131.52.4 port 63746
Jul 01 23:55:29 hcah sshd[4121]: error: maximum authentication attempts exceeded for invalid user ftpuser from 103.131.52.4 port 63746 ssh2 [preauth]
Jul 01 23:55:29 hcah sshd[4121]: Disconnecting invalid user ftpuser 103.131.52.4 port 63746: Too many authentication failures [preauth]
Jul 01 23:55:30 hcah sshd[4124]: Invalid user ftpuser from 103.131.52.4 port 65073
Jul 01 23:55:32 hcah sshd[4124]: error: maximum authentication attempts exceeded for invalid user ftpuser from 103.131.52.4 port 65073 ssh2 [preauth]
Jul 01 23:55:32 hcah sshd[4124]: Disconnecting invalid user ftpuser 103.131.52.4 port 65073: Too many authentication failures [preauth]
Jul 01 23:55:34 hcah sshd[4126]: Invalid user ftpuser from 103.131.52.4 port 10632
Jul 01 23:55:34 hcah sshd[4126]: Received disconnect from 103.131.52.4 port 10632:11: disconnected by user [preauth]
Jul 01 23:55:34 hcah sshd[4126]: Disconnected from invalid user ftpuser 103.131.52.4 port 10632 [preauth]
Jul 01 23:55:36 hcah sshd[4128]: Invalid user test1 from 103.131.52.4 port 11392
Jul 01 23:55:37 hcah sshd[4128]: error: maximum authentication attempts exceeded for invalid user test1 from 103.131.52.4 port 11392 ssh2 [preauth]
Jul 01 23:55:37 hcah sshd[4128]: Disconnecting invalid user test1 103.131.52.4 port 11392: Too many authentication failures [preauth]
Jul 01 23:55:39 hcah sshd[4130]: Invalid user test1 from 103.131.52.4 port 12590
Jul 01 23:55:41 hcah sshd[4130]: error: maximum authentication attempts exceeded for invalid user test1 from 103.131.52.4 port 12590 ssh2 [preauth]
Jul 01 23:55:41 hcah sshd[4130]: Disconnecting invalid user test1 103.131.52.4 port 12590: Too many authentication failures [preauth]
Jul 01 23:55:43 hcah sshd[4132]: Invalid user test1 from 103.131.52.4 port 13858
Jul 01 23:55:43 hcah sshd[4132]: Received disconnect from 103.131.52.4 port 13858:11: disconnected by user [preauth]
Jul 01 23:55:43 hcah sshd[4132]: Disconnected from invalid user test1 103.131.52.4 port 13858 [preauth]
Jul 01 23:55:45 hcah sshd[4134]: Invalid user test2 from 103.131.52.4 port 14603
Jul 01 23:55:46 hcah sshd[4134]: error: maximum authentication attempts exceeded for invalid user test2 from 103.131.52.4 port 14603 ssh2 [preauth]
Jul 01 23:55:46 hcah sshd[4134]: Disconnecting invalid user test2 103.131.52.4 port 14603: Too many authentication failures [preauth]
Jul 01 23:55:48 hcah sshd[4136]: Invalid user test2 from 103.131.52.4 port 15779
Jul 01 23:55:50 hcah sshd[4136]: error: maximum authentication attempts exceeded for invalid user test2 from 103.131.52.4 port 15779 ssh2 [preauth]
Jul 01 23:55:50 hcah sshd[4136]: Disconnecting invalid user test2 103.131.52.4 port 15779: Too many authentication failures [preauth]
Jul 01 23:55:52 hcah sshd[4138]: Invalid user test2 from 103.131.52.4 port 17049
Jul 01 23:55:53 hcah sshd[4138]: Received disconnect from 103.131.52.4 port 17049:11: disconnected by user [preauth]
Jul 01 23:55:53 hcah sshd[4138]: Disconnected from invalid user test2 103.131.52.4 port 17049 [preauth]
Jul 01 23:55:54 hcah sshd[4140]: Invalid user contador from 103.131.52.4 port 17772
Jul 01 23:55:55 hcah sshd[4140]: Received disconnect from 103.131.52.4 port 17772:11: disconnected by user [preauth]
Jul 01 23:55:55 hcah sshd[4140]: Disconnected from invalid user contador 103.131.52.4 port 17772 [preauth]
Jul 01 23:55:56 hcah sshd[4142]: Invalid user duni from 103.131.52.4 port 18533
Jul 01 23:55:57 hcah sshd[4142]: Received disconnect from 103.131.52.4 port 18533:11: disconnected by user [preauth]
Jul 01 23:55:57 hcah sshd[4142]: Disconnected from invalid user duni 103.131.52.4 port 18533 [preauth]
Jul 01 23:55:58 hcah sshd[4144]: Invalid user pi from 103.131.52.4 port 19299
Jul 01 23:55:59 hcah sshd[4144]: Received disconnect from 103.131.52.4 port 19299:11: disconnected by user [preauth]
Jul 01 23:55:59 hcah sshd[4144]: Disconnected from invalid user pi 103.131.52.4 port 19299 [preauth]
Jul 01 23:56:01 hcah sshd[4146]: Invalid user baikal from 103.131.52.4 port 20072
Jul 01 23:56:01 hcah sshd[4146]: Received disconnect from 103.131.52.4 port 20072:11: disconnected by user [preauth]
Jul 01 23:56:01 hcah sshd[4146]: Disconnected from invalid user baikal 103.131.52.4 port 20072 [preauth]
Jul 01 23:57:00 hcah sshd[4148]: Unable to negotiate with 209.141.43.233 port 37464: no matching key exchange method found. Their offer: diffie-hellman-group14-sha1,diffie-hellman-group-exchange-sha1,diffie-hellman-group1-sha1 [preauth]
Jul 01 23:58:33 hcah sshd[4150]: Unable to negotiate with 209.141.43.233 port 38654: no matching key exchange method found. Their offer: diffie-hellman-group14-sha1,diffie-hellman-group-exchange-sha1,diffie-hellman-group1-sha1 [preauth]
Jul 01 23:59:52 hcah sshd[4152]: Received disconnect from 111.67.203.141 port 47604:11: Bye Bye [preauth]
Jul 01 23:59:52 hcah sshd[4152]: Disconnected from authenticating user root 111.67.203.141 port 47604 [preauth]
Jul 02 00:00:00 hcah sshd[4154]: Unable to negotiate with 209.141.43.233 port 39844: no matching key exchange method found. Their offer: diffie-hellman-group14-sha1,diffie-hellman-group-exchange-sha1,diffie-hellman-group1-sha1 [preauth]
Jul 02 00:00:00 hcah systemd[1]: Starting Rotate log files...
Jul 02 00:00:00 hcah systemd[1]: Starting Daily man-db regeneration...
Jul 02 00:00:00 hcah systemd[1]: Reloading The Apache HTTP Server.
Jul 02 00:00:00 hcah systemd[1]: Reloaded The Apache HTTP Server.
Jul 02 00:00:00 hcah rsyslogd[938]: [origin software="rsyslogd" swVersion="8.2001.0" x-pid="938" x-info="https://www.rsyslog.com"] rsyslogd was HUPed
Jul 02 00:00:00 hcah systemd[1]: logrotate.service: Succeeded.
Jul 02 00:00:00 hcah systemd[1]: Finished Rotate log files.
Jul 02 00:00:01 hcah systemd[1]: man-db.service: Succeeded.
Jul 02 00:00:01 hcah systemd[1]: Finished Daily man-db regeneration.
Jul 02 00:01:39 hcah sshd[4279]: Unable to negotiate with 209.141.43.233 port 41034: no matching key exchange method found. Their offer: diffie-hellman-group14-sha1,diffie-hellman-group-exchange-sha1,diffie-hellman-group1-sha1 [preauth]
Jul 02 00:02:03 hcah sshd[4281]: Received disconnect from 65.24.66.132 port 44872:11: Bye Bye [preauth]
Jul 02 00:02:03 hcah sshd[4281]: Disconnected from authenticating user root 65.24.66.132 port 44872 [preauth]
Jul 02 00:03:18 hcah sshd[4283]: Unable to negotiate with 209.141.43.233 port 42222: no matching key exchange method found. Their offer: diffie-hellman-group14-sha1,diffie-hellman-group-exchange-sha1,diffie-hellman-group1-sha1 [preauth]
Jul 02 00:05:01 hcah sshd[4285]: Unable to negotiate with 209.141.43.233 port 43420: no matching key exchange method found. Their offer: diffie-hellman-group14-sha1,diffie-hellman-group-exchange-sha1,diffie-hellman-group1-sha1 [preauth]
Jul 02 00:06:45 hcah sshd[4288]: Unable to negotiate with 209.141.43.233 port 44604: no matching key exchange method found. Their offer: diffie-hellman-group14-sha1,diffie-hellman-group-exchange-sha1,diffie-hellman-group1-sha1 [preauth]
Jul 02 00:08:23 hcah sshd[4290]: Unable to negotiate with 209.141.43.233 port 45796: no matching key exchange method found. Their offer: diffie-hellman-group14-sha1,diffie-hellman-group-exchange-sha1,diffie-hellman-group1-sha1 [preauth]
Jul 02 00:08:24 hcah sshd[4292]: Received disconnect from 95.182.139.119 port 38456:11: Bye Bye [preauth]
Jul 02 00:08:24 hcah sshd[4292]: Disconnected from authenticating user root 95.182.139.119 port 38456 [preauth]
Jul 02 00:10:07 hcah sshd[4294]: Unable to negotiate with 209.141.43.233 port 46984: no matching key exchange method found. Their offer: diffie-hellman-group14-sha1,diffie-hellman-group-exchange-sha1,diffie-hellman-group1-sha1 [preauth]
Jul 02 00:10:08 hcah kernel: [UFW BLOCK] IN=ens192 OUT= MAC=00:50:56:0b:82:6d:00:50:56:af:33:4a:08:00 SRC=88.9.119.217 DST=77.68.84.223 LEN=40 TOS=0x00 PREC=0x00 TTL=244 ID=54321 PROTO=TCP SPT=51207 DPT=8000 WINDOW=65535 RES=0x00 SYN URGP=0 
Jul 02 00:10:59 hcah sshd[4296]: Received disconnect from 49.234.43.127 port 38408:11: Bye Bye [preauth]
Jul 02 00:10:59 hcah sshd[4296]: Disconnected from authenticating user root 49.234.43.127 port 38408 [preauth]
Jul 02 00:11:53 hcah sshd[4299]: Unable to negotiate with 209.141.43.233 port 48172: no matching key exchange method found. Their offer: diffie-hellman-group14-sha1,diffie-hellman-group-exchange-sha1,diffie-hellman-group1-sha1 [preauth]
Jul 02 00:13:13 hcah sshd[4301]: Invalid user  from 65.49.20.66 port 41088
Jul 02 00:13:17 hcah sshd[4301]: Connection closed by invalid user  65.49.20.66 port 41088 [preauth]
Jul 02 00:13:38 hcah sshd[4305]: Unable to negotiate with 209.141.43.233 port 49364: no matching key exchange method found. Their offer: diffie-hellman-group14-sha1,diffie-hellman-group-exchange-sha1,diffie-hellman-group1-sha1 [preauth]
Jul 02 00:13:40 hcah sshd[4303]: Connection closed by 192.241.215.97 port 55686 [preauth]
Jul 02 00:14:59 hcah sshd[4307]: Received disconnect from 210.245.92.136 port 54888:11: Bye Bye [preauth]
Jul 02 00:14:59 hcah sshd[4307]: Disconnected from authenticating user root 210.245.92.136 port 54888 [preauth]
Jul 02 00:15:19 hcah sshd[4309]: Unable to negotiate with 209.141.43.233 port 50552: no matching key exchange method found. Their offer: diffie-hellman-group14-sha1,diffie-hellman-group-exchange-sha1,diffie-hellman-group1-sha1 [preauth]
Jul 02 00:15:22 hcah kernel: [UFW BLOCK] IN=ens192 OUT= MAC=00:50:56:0b:82:6d:00:50:56:af:33:4a:08:00 SRC=74.120.14.16 DST=77.68.84.223 LEN=44 TOS=0x00 PREC=0x00 TTL=41 ID=5856 PROTO=TCP SPT=29266 DPT=587 WINDOW=1024 RES=0x00 SYN URGP=0 
Jul 02 00:15:41 hcah sshd[4311]: Received disconnect from 49.51.180.246 port 42242:11: Bye Bye [preauth]
Jul 02 00:15:41 hcah sshd[4311]: Disconnected from authenticating user root 49.51.180.246 port 42242 [preauth]
Jul 02 00:17:01 hcah CRON[4315]: pam_unix(cron:session): session opened for user root by (uid=0)
Jul 02 00:17:01 hcah CRON[4316]: (root) CMD (   cd / && run-parts --report /etc/cron.hourly)
Jul 02 00:17:01 hcah CRON[4315]: pam_unix(cron:session): session closed for user root
Jul 02 00:19:44 hcah sshd[4318]: Received disconnect from 121.5.243.95 port 57770:11: Bye Bye [preauth]
Jul 02 00:19:44 hcah sshd[4318]: Disconnected from authenticating user root 121.5.243.95 port 57770 [preauth]
Jul 02 00:26:01 hcah sshd[4322]: Received disconnect from 142.93.8.164 port 40802:11: Bye Bye [preauth]
Jul 02 00:26:01 hcah sshd[4322]: Disconnected from authenticating user root 142.93.8.164 port 40802 [preauth]
Jul 02 00:27:03 hcah sshd[4324]: Received disconnect from 185.111.88.212 port 53384:11: Bye Bye [preauth]
Jul 02 00:27:03 hcah sshd[4324]: Disconnected from authenticating user root 185.111.88.212 port 53384 [preauth]
Jul 02 00:29:12 hcah sshd[4326]: Received disconnect from 159.75.67.197 port 54718:11: Bye Bye [preauth]
Jul 02 00:29:12 hcah sshd[4326]: Disconnected from authenticating user root 159.75.67.197 port 54718 [preauth]
Jul 02 00:31:35 hcah systemd-timesyncd[806]: No network connectivity, watching for changes.
Jul 02 01:17:01 hcah CRON[4334]: pam_unix(cron:session): session opened for user root by (uid=0)
Jul 02 01:17:01 hcah CRON[4335]: (root) CMD (   cd / && run-parts --report /etc/cron.hourly)
Jul 02 01:17:01 hcah CRON[4334]: pam_unix(cron:session): session closed for user root
Jul 02 02:17:01 hcah CRON[4344]: pam_unix(cron:session): session opened for user root by (uid=0)
Jul 02 02:17:01 hcah CRON[4345]: (root) CMD (   cd / && run-parts --report /etc/cron.hourly)
Jul 02 02:17:01 hcah CRON[4344]: pam_unix(cron:session): session closed for user root
Jul 02 02:33:49 hcah systemd[1]: Starting Refresh fwupd metadata and update motd...
Jul 02 02:33:50 hcah dbus-daemon[923]: [system] Activating via systemd: service name='org.freedesktop.fwupd' unit='fwupd.service' requested by ':1.36' (uid=62803 pid=4350 comm="/usr/bin/fwupdmgr refresh --no-metadata-check " label="unconfined")
Jul 02 02:33:50 hcah systemd[1]: Starting Firmware update daemon...
Jul 02 02:33:50 hcah dbus-daemon[923]: [system] Successfully activated service 'org.freedesktop.fwupd'
Jul 02 02:33:50 hcah systemd[1]: Started Firmware update daemon.
Jul 02 02:33:50 hcah systemd[1]: fwupd-refresh.service: Succeeded.
Jul 02 02:33:50 hcah systemd[1]: Finished Refresh fwupd metadata and update motd.
Jul 02 03:10:01 hcah CRON[4383]: pam_unix(cron:session): session opened for user root by (uid=0)
Jul 02 03:10:01 hcah CRON[4384]: (root) CMD (test -e /run/systemd/system || SERVICE_MODE=1 /sbin/e2scrub_all -A -r)
Jul 02 03:10:01 hcah CRON[4383]: pam_unix(cron:session): session closed for user root
Jul 02 03:17:01 hcah CRON[4386]: pam_unix(cron:session): session opened for user root by (uid=0)
Jul 02 03:17:01 hcah CRON[4387]: (root) CMD (   cd / && run-parts --report /etc/cron.hourly)
Jul 02 03:17:01 hcah CRON[4386]: pam_unix(cron:session): session closed for user root
Jul 02 03:17:08 hcah snapd[942]: autorefresh.go:501: Cannot prepare auto-refresh change due to a permanent network error: persistent network error: Post https://api.snapcraft.io/v2/snaps/refresh: dial tcp: lookup api.snapcraft.io: Temporary failure in name resolution
Jul 02 03:17:08 hcah snapd[942]: stateengine.go:150: state ensure error: persistent network error: Post https://api.snapcraft.io/v2/snaps/refresh: dial tcp: lookup api.snapcraft.io: Temporary failure in name resolution
Jul 02 03:42:08 hcah snapd[942]: autorefresh.go:501: Cannot prepare auto-refresh change due to a permanent network error: persistent network error: Post https://api.snapcraft.io/v2/snaps/refresh: dial tcp: lookup api.snapcraft.io: Temporary failure in name resolution
Jul 02 03:42:08 hcah snapd[942]: stateengine.go:150: state ensure error: persistent network error: Post https://api.snapcraft.io/v2/snaps/refresh: dial tcp: lookup api.snapcraft.io: Temporary failure in name resolution
Jul 02 04:02:08 hcah snapd[942]: autorefresh.go:501: Cannot prepare auto-refresh change due to a permanent network error: persistent network error: Post https://api.snapcraft.io/v2/snaps/refresh: dial tcp: lookup api.snapcraft.io: Temporary failure in name resolution
Jul 02 04:02:08 hcah snapd[942]: stateengine.go:150: state ensure error: persistent network error: Post https://api.snapcraft.io/v2/snaps/refresh: dial tcp: lookup api.snapcraft.io: Temporary failure in name resolution
Jul 02 04:17:01 hcah CRON[4397]: pam_unix(cron:session): session opened for user root by (uid=0)
Jul 02 04:17:01 hcah CRON[4398]: (root) CMD (   cd / && run-parts --report /etc/cron.hourly)
Jul 02 04:17:01 hcah CRON[4397]: pam_unix(cron:session): session closed for user root
Jul 02 04:27:08 hcah snapd[942]: autorefresh.go:501: Cannot prepare auto-refresh change due to a permanent network error: persistent network error: Post https://api.snapcraft.io/v2/snaps/refresh: dial tcp: lookup api.snapcraft.io: Temporary failure in name resolution
Jul 02 04:27:08 hcah snapd[942]: stateengine.go:150: state ensure error: persistent network error: Post https://api.snapcraft.io/v2/snaps/refresh: dial tcp: lookup api.snapcraft.io: Temporary failure in name resolution
Jul 02 04:33:50 hcah systemd[1]: fwupd.service: Succeeded.
Jul 02 04:47:08 hcah snapd[942]: autorefresh.go:501: Cannot prepare auto-refresh change due to a permanent network error: persistent network error: Post https://api.snapcraft.io/v2/snaps/refresh: dial tcp: lookup api.snapcraft.io: Temporary failure in name resolution
Jul 02 04:47:08 hcah snapd[942]: stateengine.go:150: state ensure error: persistent network error: Post https://api.snapcraft.io/v2/snaps/refresh: dial tcp: lookup api.snapcraft.io: Temporary failure in name resolution
Jul 02 05:12:08 hcah snapd[942]: autorefresh.go:501: Cannot prepare auto-refresh change due to a permanent network error: persistent network error: Post https://api.snapcraft.io/v2/snaps/refresh: dial tcp: lookup api.snapcraft.io: Temporary failure in name resolution
Jul 02 05:12:08 hcah snapd[942]: stateengine.go:150: state ensure error: persistent network error: Post https://api.snapcraft.io/v2/snaps/refresh: dial tcp: lookup api.snapcraft.io: Temporary failure in name resolution
Jul 02 05:17:01 hcah CRON[4432]: pam_unix(cron:session): session opened for user root by (uid=0)
Jul 02 05:17:01 hcah CRON[4433]: (root) CMD (   cd / && run-parts --report /etc/cron.hourly)
Jul 02 05:17:01 hcah CRON[4432]: pam_unix(cron:session): session closed for user root
Jul 02 05:32:08 hcah snapd[942]: autorefresh.go:501: Cannot prepare auto-refresh change due to a permanent network error: persistent network error: Post https://api.snapcraft.io/v2/snaps/refresh: dial tcp: lookup api.snapcraft.io: Temporary failure in name resolution
Jul 02 05:32:08 hcah snapd[942]: stateengine.go:150: state ensure error: persistent network error: Post https://api.snapcraft.io/v2/snaps/refresh: dial tcp: lookup api.snapcraft.io: Temporary failure in name resolution
Jul 02 05:57:08 hcah snapd[942]: autorefresh.go:501: Cannot prepare auto-refresh change due to a permanent network error: persistent network error: Post https://api.snapcraft.io/v2/snaps/refresh: dial tcp: lookup api.snapcraft.io: Temporary failure in name resolution
Jul 02 05:57:08 hcah snapd[942]: stateengine.go:150: state ensure error: persistent network error: Post https://api.snapcraft.io/v2/snaps/refresh: dial tcp: lookup api.snapcraft.io: Temporary failure in name resolution
Jul 02 06:17:01 hcah CRON[4444]: pam_unix(cron:session): session opened for user root by (uid=0)
Jul 02 06:17:01 hcah CRON[4445]: (root) CMD (   cd / && run-parts --report /etc/cron.hourly)
Jul 02 06:17:01 hcah CRON[4444]: pam_unix(cron:session): session closed for user root
Jul 02 06:22:08 hcah snapd[942]: autorefresh.go:501: Cannot prepare auto-refresh change due to a permanent network error: persistent network error: Post https://api.snapcraft.io/v2/snaps/refresh: dial tcp: lookup api.snapcraft.io: Temporary failure in name resolution
Jul 02 06:22:08 hcah snapd[942]: stateengine.go:150: state ensure error: persistent network error: Post https://api.snapcraft.io/v2/snaps/refresh: dial tcp: lookup api.snapcraft.io: Temporary failure in name resolution
Jul 02 06:25:01 hcah CRON[4449]: pam_unix(cron:session): session opened for user root by (uid=0)
Jul 02 06:25:01 hcah CRON[4450]: (root) CMD (test -x /usr/sbin/anacron || ( cd / && run-parts --report /etc/cron.daily ))
Jul 02 06:25:01 hcah CRON[4449]: pam_unix(cron:session): session closed for user root
Jul 02 06:41:22 hcah systemd[1]: Starting Daily apt upgrade and clean activities...
Jul 02 06:41:52 hcah systemd-networkd-wait-online[4520]: Event loop failed: Connection timed out
Jul 02 06:41:52 hcah apt-helper[4510]: E: Sub-process /lib/systemd/systemd-networkd-wait-online returned an error code (1)
Jul 02 06:41:54 hcah systemd[1]: apt-daily-upgrade.service: Succeeded.
Jul 02 06:41:54 hcah systemd[1]: Finished Daily apt upgrade and clean activities.
Jul 02 06:42:08 hcah snapd[942]: autorefresh.go:501: Cannot prepare auto-refresh change due to a permanent network error: persistent network error: Post https://api.snapcraft.io/v2/snaps/refresh: dial tcp: lookup api.snapcraft.io: Temporary failure in name resolution
Jul 02 06:42:08 hcah snapd[942]: stateengine.go:150: state ensure error: persistent network error: Post https://api.snapcraft.io/v2/snaps/refresh: dial tcp: lookup api.snapcraft.io: Temporary failure in name resolution
Jul 02 07:03:49 hcah systemd[1]: Starting Daily apt download activities...
Jul 02 07:04:20 hcah systemd-networkd-wait-online[4632]: Event loop failed: Connection timed out
Jul 02 07:04:20 hcah apt-helper[4620]: E: Sub-process /lib/systemd/systemd-networkd-wait-online returned an error code (1)
Jul 02 07:04:22 hcah systemd[1]: apt-daily.service: Succeeded.
Jul 02 07:04:22 hcah systemd[1]: Finished Daily apt download activities.
Jul 02 07:07:08 hcah snapd[942]: autorefresh.go:501: Cannot prepare auto-refresh change due to a permanent network error: persistent network error: Post https://api.snapcraft.io/v2/snaps/refresh: dial tcp: lookup api.snapcraft.io: Temporary failure in name resolution
Jul 02 07:07:08 hcah snapd[942]: stateengine.go:150: state ensure error: persistent network error: Post https://api.snapcraft.io/v2/snaps/refresh: dial tcp: lookup api.snapcraft.io: Temporary failure in name resolution
Jul 02 07:17:01 hcah CRON[4722]: pam_unix(cron:session): session opened for user root by (uid=0)
Jul 02 07:17:01 hcah CRON[4723]: (root) CMD (   cd / && run-parts --report /etc/cron.hourly)
Jul 02 07:17:01 hcah CRON[4722]: pam_unix(cron:session): session closed for user root
Jul 02 07:28:22 hcah systemd[1]: Starting Refresh fwupd metadata and update motd...
Jul 02 07:28:22 hcah dbus-daemon[923]: [system] Activating via systemd: service name='org.freedesktop.fwupd' unit='fwupd.service' requested by ':1.40' (uid=62803 pid=4726 comm="/usr/bin/fwupdmgr refresh --no-metadata-check " label="unconfined")
Jul 02 07:28:22 hcah systemd[1]: Starting Firmware update daemon...
Jul 02 07:28:22 hcah dbus-daemon[923]: [system] Successfully activated service 'org.freedesktop.fwupd'
Jul 02 07:28:22 hcah systemd[1]: Started Firmware update daemon.
Jul 02 07:28:22 hcah systemd[1]: fwupd-refresh.service: Succeeded.
Jul 02 07:28:22 hcah systemd[1]: Finished Refresh fwupd metadata and update motd.
Jul 02 07:32:08 hcah snapd[942]: autorefresh.go:501: Cannot prepare auto-refresh change due to a permanent network error: persistent network error: Post https://api.snapcraft.io/v2/snaps/refresh: dial tcp: lookup api.snapcraft.io: Temporary failure in name resolution
Jul 02 07:32:08 hcah snapd[942]: stateengine.go:150: state ensure error: persistent network error: Post https://api.snapcraft.io/v2/snaps/refresh: dial tcp: lookup api.snapcraft.io: Temporary failure in name resolution
Jul 02 07:52:08 hcah snapd[942]: autorefresh.go:501: Cannot prepare auto-refresh change due to a permanent network error: persistent network error: Post https://api.snapcraft.io/v2/snaps/refresh: dial tcp: lookup api.snapcraft.io: Temporary failure in name resolution
Jul 02 07:52:08 hcah snapd[942]: stateengine.go:150: state ensure error: persistent network error: Post https://api.snapcraft.io/v2/snaps/refresh: dial tcp: lookup api.snapcraft.io: Temporary failure in name resolution

I am terrible with logs but it looks like by 00:31 it cant access the network. It looks like people are trying to access my server? Any help would be much appreciated.

Doug Smythies avatar
gn flag
@user535733 : I do not see a successful login, I only see failed attempts which is pretty normal for any externally enabled ssh. Can you give a specific time reference? OP: your network seems to go down at about 00:30, as you already mentioned. Don't know why.
Saif avatar
cn flag
Hi @Doug Smythies, Im not sure when the network goes down. Just before this log, I successfully accessed the server and there were no issues. So it must happen after 2300 but I cant see why in the logs.
Doug Smythies avatar
gn flag
The network is working at 00:29:12 and not working at 00:31:35. Search any other logs in this time area.
user535733 avatar
cn flag
@DougSmythies you are correct. Oops, thanks for spotting that.
Saif avatar
cn flag
I have checked syslogs and the journalctl for that service but I cannot see any particular reason why the network goes down.
Doug Smythies avatar
gn flag
Try some things before you re-boot tomorrow morning. Try: `sudo systemctl status systemd-networkd`. And try just re-starting the network, instead of re-boot: `sudo systemctl re-start systemd-networkd` (I think, I didn't test it.)
Saif avatar
cn flag
@Doug Smythies I wish I could but I cant even SSH on, I just have to use my hosting providers web panel to restart it!
Doug Smythies avatar
gn flag
Oh. I thought it was perhaps a local computer. Hopefully someone will chime in with help. Otherwise. maybe get a cron job to run every hour doing `sudo systemctl status systemd-networkd` to a log file. There is likely a way to get more information logged, I just don't know what it is.
Doug Smythies avatar
gn flag
Have you solved your problem? Interestingly, I am used to being able to hot plug ethernet cables at my switch, but when I did so yesterday my computer crashed with a similar `systemd-timesyncd[806]: No network connectivity, watching for changes.` message.
Saif avatar
cn flag
Nope still ongoing :( Will update here if I find the solution.
Igor Beaufils avatar
my flag
@Saif still nothing ? I get exactly the same problem
Saif avatar
cn flag
@IgorBeaufils No unfortunately not. I had to wipe the server and start again.
Igor Beaufils avatar
my flag
@Saif ok that does not work for me sadly it keeps coming again and again. still thanks for your response
mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.