Hi,
I were experience some issues with emoncms so i decided to upgrade my raspberry pi (kernel and applications). Emoncms misworking continues so i applied a Factory Reset:
$ /home/pi/emonpi/factoryreset
After reconfigure all envirnoment, all seems work again, but each some time i have notified that on emoncms feeds suddenly not update. The cause: disconnection of mqtt.
Tue Dec 26 21:43:57 2017: New connection from ::1 on port 1883.
Tue Dec 26 21:43:57 2017: New client connected from ::1 as mosq/uo?r<k0vh@HPXrLrs@ (c1, k5, u'emonpi').
Thu Dec 28 16:23:03 2017: Client mosq/uo?r<k0vh@HPXrLrs@ has exceeded timeout, disconnecting.
Thu Dec 28 16:23:03 2017: Socket error on client mosq/uo?r<k0vh@HPXrLrs@, disconnecting.
I belive kernel and applications is up to date
root@emonpi(rw):~# uname -a
Linux emonpi 4.9.59-v7+ #1047 SMP Sun Oct 29 12:19:23 GMT 2017 armv7l GNU/Linux
mosquitto -v
mosquitto version 1.4.14 (build date Mon, 10 Jul 2017 23:48:43 +0100)
Mossquito configurations is default:
root@emonpi(rw):~# cat /etc/mosquitto/mosquitto.conf
**# Place your local configuration in /etc/mosquitto/conf.d/**
**#**
**# A full description of the configuration file is at**
**# /usr/share/doc/mosquitto/examples/mosquitto.conf.example**
pid_file /var/run/mosquitto.pid
persistence false
persistence_location /var/lib/mosquitto/
log_dest file /var/log/mosquitto/mosquitto.log
include_dir /etc/mosquitto/conf.d
allow_anonymous false
password_file /etc/mosquitto/passwd
Here some examples of disconnections. Normally disconnect each less than two days
root@emonpi(rw):~# tail -50 /var/log/mosquitto/mosquitto.log | perl -pe 's/(\d+)/localtime($1)/e'
Sun Dec 24 17:36:41 2017: New client connected from 127.0.0.1 as mqtt_39f6498c.c609b6 (c1, k15, u'emonpi').
Sun Dec 24 17:36:58 2017: New connection from 127.0.0.1 on port 1883.
Sun Dec 24 17:36:58 2017: New client connected from 127.0.0.1 as openhab.1514133418120 (c1, k60, u'emonpi').
Sun Dec 24 17:37:30 2017: New connection from ::1 on port 1883.
Sun Dec 24 17:37:30 2017: New client connected from ::1 as mosq/1Ir7DGG`H@pG;G_adv (c1, k5, u'emonpi').
Sun Dec 24 17:38:21 2017: Socket error on client 231482b5-432f-4c3d-bd04-000e934ae440, disconnecting.
Sun Dec 24 17:38:22 2017: Socket error on client mosq/1Ir7DGG`H@pG;G_adv, disconnecting.
Sun Dec 24 17:38:23 2017: mosquitto version 1.4.14 terminating
Sun Dec 24 18:10:17 2017: mosquitto version 1.4.14 (build date Mon, 10 Jul 2017 23:48:43 +0100) starting
Sun Dec 24 18:10:17 2017: Config loaded from /etc/mosquitto/mosquitto.conf.
Sun Dec 24 18:10:17 2017: Opening ipv4 listen socket on port 1883.
Sun Dec 24 18:10:17 2017: Opening ipv6 listen socket on port 1883.
Sun Dec 24 18:10:24 2017: New connection from 127.0.0.1 on port 1883.
Sun Dec 24 18:10:24 2017: New client connected from 127.0.0.1 as ebd42aad-09f7-4a29-9adb-337648578ae1 (c1, k60, u'emonpi').
Sun Dec 24 18:10:24 2017: New connection from 127.0.0.1 on port 1883.
Sun Dec 24 18:10:24 2017: New client connected from 127.0.0.1 as lwrf (c1, k20, u'emonpi').
Sun Dec 24 18:10:30 2017: New connection from 127.0.0.1 on port 1883.
Sun Dec 24 18:10:30 2017: New client connected from 127.0.0.1 as mqtt_39f6498c.c609b6 (c1, k15, u'emonpi').
Sun Dec 24 18:10:46 2017: New connection from 127.0.0.1 on port 1883.
Sun Dec 24 18:10:46 2017: New client connected from 127.0.0.1 as openhab.1514135446325 (c1, k60, u'emonpi').
Sun Dec 24 18:11:18 2017: New connection from ::1 on port 1883.
Sun Dec 24 18:11:18 2017: New client connected from ::1 as mosq/obuuVIfUlZxBUgPY?K (c1, k5, u'emonpi').
Mon Dec 25 14:57:17 2017: Client mosq/obuuVIfUlZxBUgPY?K has exceeded timeout, disconnecting.
Mon Dec 25 14:57:17 2017: Socket error on client mosq/obuuVIfUlZxBUgPY?K, disconnecting.
Mon Dec 25 16:29:54 2017: New connection from 127.0.0.1 on port 1883.
Mon Dec 25 16:29:54 2017: New client connected from 127.0.0.1 as 12a100de-f703-4ce3-8b74-78a991b0ccc0 (c1, k60, u'emonpi').
Mon Dec 25 17:23:10 2017: mosquitto version 1.4.14 terminating
Mon Dec 25 17:23:18 2017: mosquitto version 1.4.14 (build date Mon, 10 Jul 2017 23:48:43 +0100) starting
Mon Dec 25 17:23:18 2017: Config loaded from /etc/mosquitto/mosquitto.conf.
Mon Dec 25 17:23:18 2017: Opening ipv4 listen socket on port 1883.
Mon Dec 25 17:23:18 2017: Opening ipv6 listen socket on port 1883.
Mon Dec 25 17:23:19 2017: New connection from 127.0.0.1 on port 1883.
Mon Dec 25 17:23:19 2017: New client connected from 127.0.0.1 as e9967724-8589-4c5e-bd50-54b94e791213 (c1, k60, u'emonpi').
Mon Dec 25 17:23:20 2017: New connection from 127.0.0.1 on port 1883.
Mon Dec 25 17:23:20 2017: New client connected from 127.0.0.1 as openhab.1514135446325 (c1, k60, u'emonpi').
Mon Dec 25 17:23:25 2017: New connection from 127.0.0.1 on port 1883.
Mon Dec 25 17:23:25 2017: New client connected from 127.0.0.1 as lwrf (c1, k20, u'emonpi').
Mon Dec 25 17:23:25 2017: New connection from 127.0.0.1 on port 1883.
Mon Dec 25 17:23:25 2017: New client connected from 127.0.0.1 as 3144b63e-cf68-4dd0-8aec-32e0d5f31830 (c1, k60, u'emonpi').
Mon Dec 25 17:23:25 2017: New connection from 127.0.0.1 on port 1883.
Mon Dec 25 17:23:25 2017: New client connected from 127.0.0.1 as mqtt_39f6498c.c609b6 (c1, k15, u'emonpi').
Mon Dec 25 17:23:29 2017: New connection from ::1 on port 1883.
Mon Dec 25 17:23:29 2017: New client connected from ::1 as mosq/YHrvXPaN=Lg9oallP] (c1, k5, u'emonpi').
Tue Dec 26 20:34:51 2017: Client mosq/YHrvXPaN=Lg9oallP] has exceeded timeout, disconnecting.
Tue Dec 26 20:34:51 2017: Socket error on client mosq/YHrvXPaN=Lg9oallP], disconnecting.
Tue Dec 26 21:43:57 2017: New connection from ::1 on port 1883.
Tue Dec 26 21:43:57 2017: New client connected from ::1 as mosq/uo?r<k0vh@HPXrLrs@ (c1, k5, u'emonpi').
Thu Dec 28 16:23:03 2017: Client mosq/uo?r<k0vh@HPXrLrs@ has exceeded timeout, disconnecting.
Thu Dec 28 16:23:03 2017: Socket error on client mosq/uo?r<k0vh@HPXrLrs@, disconnecting.
Thu Dec 28 16:39:07 2017: New connection from ::1 on port 1883.
Attached extended log and packages version.
mosquitto_issue.zip (43.1 KB)
I have not clear why is disconnecting, because is working over Wiffi? because is required add some additional configuration to prevent timeouts? Any help will be welcomed.