Page 18 of 26
Re: Python Plugin: Shelly MQTT
Posted: Sunday 06 February 2022 18:45
by gizmocuz
@microchip1974
I have send you an email.
Anyone having issues with the MQTT Auto Discovery hardware feel free to join our Slack channels:
https://join.slack.com/t/domoticz/share ... G2dBSOTRwg
Re: Python Plugin: Shelly MQTT
Posted: Sunday 06 February 2022 18:48
by Derik
Love you Rob....
Hope you get shelly working...
If you need a hardware device to test.
I buy 1 for you..
Let me know please
Re: Python Plugin: Shelly MQTT
Posted: Sunday 06 February 2022 22:07
by waltervl
There is no zigbee2mqtt integration, there is a MQTT Autodiscover integration that Z2M also happen to support. That and also the fact that Zwavejs2mqtt supports this gave some momentum.
But everyone is free to start a C++ integration. Rob is not the only person that starts an integration.
Also you would need the hardware to test.
But you are free to ask

Re: Python Plugin: Shelly MQTT
Posted: Sunday 06 February 2022 22:18
by Derik
waltervl wrote: ↑Sunday 06 February 2022 22:07
There is no zigbee2mqtt integration, there is a MQTT Autodiscover integration that Z2M also happen to support. That and also the fact that Zwavejs2mqtt supports this gave some momentum.
But everyone is free to start a C++ integration. Rob is not the only person that starts an integration.
Also you would need the hardware to test.
But you are free to ask
I now wat you mean....
If you could.. i buy you a shelly


Re: Python Plugin: Shelly MQTT
Posted: Friday 04 March 2022 11:48
by darrepac
Hello
I have shellies and plugin working since a while flawlessly.
Yet, I realized something odd with my Shelly EM:
While the voltage device is updated everything few seconds (at each mqtt update), the watt consumption is only updated every 10 or more seconds (while through MQTT Explorer I see that both are updated in the same time).
What is the reason behind and can we change that?
EDIT:
Looking at the plugin.py, domoticz voltage device value (and on/off values) is updated at every mqtt message while power/energy values are updated at minimum every 10seconds:
if( updated > 10 ):
Why? I don't know
Re: Python Plugin: Shelly MQTT
Posted: Sunday 06 March 2022 17:18
by Robinjoo94
Hi all,
I have the Shelly MQTT running rather flawlesly for over a year, or maybe 2 already, now.
I just updated to Domoticz 2022.1 stable build, and that is when the problems started.
Is see the following error in the Domoticz.log after which Domoticz service goes to "active (exited)":
Code: Select all
Error: Domoticz(pid:22631, tid:22647('Shelly MQTT')) received fatal signal 11 (Segmentation fault)
Anyone faced the same and has a solution?
Re: Python Plugin: Shelly MQTT
Posted: Sunday 06 March 2022 17:40
by waltervl
There is an issue on running Python plugins on Bullseye but you seem to run Buster so that would not be an issue.
Does it stop directly or after a while?
What is in the Domoticz log before the crash?
Re: Python Plugin: Shelly MQTT
Posted: Monday 07 March 2022 10:07
by darrepac
darrepac wrote: ↑Friday 04 March 2022 11:48
Hello
I have shellies and plugin working since a while flawlessly.
Yet, I realized something odd with my Shelly EM:
While the voltage device is updated everything few seconds (at each mqtt update), the watt consumption is only updated every 10 or more seconds (while through MQTT Explorer I see that both are updated in the same time).
What is the reason behind and can we change that?
EDIT:
Looking at the plugin.py, domoticz voltage device value (and on/off values) is updated at every mqtt message while power/energy values are updated at minimum every 10seconds:
if( updated > 10 ):
Why? I don't know
I found why, here is the answer if someone else need it:
https://github.com/enesbcs/Shelly_MQTT/pull/87
Re: Python Plugin: Shelly MQTT
Posted: Monday 07 March 2022 16:22
by Robinjoo94
waltervl wrote: ↑Sunday 06 March 2022 17:40
There is an issue on running Python plugins on Bullseye but you seem to run Buster so that would not be an issue.
Does it stop directly or after a while?
What is in the Domoticz log before the crash?
It stops after a while, where the "while" is rather unpredictable (1 minute to >24 hours).
The log shows "Disconnected from MQTT Server" for the occurences I was not directly looking at last time. Other than that there is nothing interesting in the log, just my (non-Shelly) devices updating:
- Spoiler: show
-
2022-03-04 14:47:58.677 Error: Shelly MQTT: Disconnected from MQTT Server: <ip_address>:<port>
2022-03-04 14:47:58.748 Error: Domoticz(pid:22903, tid:22917('Shelly MQTT')) received fatal signal 11 (Segmentation fault)
I do have the domoticz_crash.log, but I am not able to extract useful information from it:
- Spoiler: show
-
[New LWP 22632]
[New LWP 22636]
[New LWP 22637]
[New LWP 22638]
[New LWP 22643]
[New LWP 22645]
[New LWP 22647]
[New LWP 22648]
[New LWP 22649]
[New LWP 22650]
[New LWP 22651]
[New LWP 22652]
[New LWP 22653]
[New LWP 22654]
[New LWP 22655]
[New LWP 22656]
[New LWP 22657]
[New LWP 22658]
[New LWP 22684]
[New LWP 22686]
[New LWP 22685]
[New LWP 22687]
[New LWP 22688]
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/arm-linux-gnueabihf/libthread_db.so.1".
0x76a33a3c in __GI___pthread_timedjoin_ex (threadid=1858073088, thread_return=0x0, abstime=<optimized out>, block=<optimized out>) at pthread_join_common.c:89
89 pthread_join_common.c: No such file or directory.
Id Target Id Frame
* 1 Thread 0x76f0d040 (LWP 22631) "domoticz" 0x76a33a3c in __GI___pthread_timedjoin_ex (threadid=1858073088, thread_return=0x0, abstime=<optimized out>, block=<optimized out>) at pthread_join_common.c:89
2 Thread 0x759b4200 (LWP 22632) "Watchdog" __GI___nanosleep (remaining=0x759b3bb0, requested_time=0x759b3bb0) at ../sysdeps/unix/sysv/linux/nanosleep.c:28
3 Thread 0x751b3200 (LWP 22636) "SQLHelper" syscall () at ../sysdeps/unix/sysv/linux/arm/syscall.S:37
4 Thread 0x749b2200 (LWP 22637) "PluginMgr" syscall () at ../sysdeps/unix/sysv/linux/arm/syscall.S:37
5 Thread 0x73b80200 (LWP 22638) "InfluxPush" syscall () at ../sysdeps/unix/sysv/linux/arm/syscall.S:37
6 Thread 0x70fff200 (LWP 22643) "Scheduler" syscall () at ../sysdeps/unix/sysv/linux/arm/syscall.S:37
7 Thread 0x6fffd200 (LWP 22645) "MainWorker" syscall () at ../sysdeps/unix/sysv/linux/arm/syscall.S:37
8 Thread 0x6ebff200 (LWP 22647) "Shelly MQTT" __waitpid (options=0, stat_loc=0x6ebfdf98, pid=12484) at ../sysdeps/unix/sysv/linux/waitpid.c:30
9 Thread 0x6e3fe200 (LWP 22648) "ZWaveBase" syscall () at ../sysdeps/unix/sysv/linux/arm/syscall.S:37
10 Thread 0x6dbfd200 (LWP 22649) "MainWorker" 0x768e59c0 in epoll_wait (epfd=<optimized out>, events=0x6dbfc340, maxevents=128, timeout=-1) at ../sysdeps/unix/sysv/linux/epoll_wait.c:30
11 Thread 0x6d3fc200 (LWP 22650) "P1 USB" syscall () at ../sysdeps/unix/sysv/linux/arm/syscall.S:37
12 Thread 0x6cbfb200 (LWP 22651) "Buienradar" syscall () at ../sysdeps/unix/sysv/linux/arm/syscall.S:37
13 Thread 0x6c3fa200 (LWP 22652) "Thermostat" syscall () at ../sysdeps/unix/sysv/linux/arm/syscall.S:37
14 Thread 0x6bbf9200 (LWP 22653) "Solar Inverter" syscall () at ../sysdeps/unix/sysv/linux/arm/syscall.S:37
15 Thread 0x6b3f8200 (LWP 22654) "NotificationSys" futex_abstimed_wait_cancelable (private=<optimized out>, abstime=0x6b3f7bb0, expected=0, futex_word=0xa8de7c <m_mainworker+2652>) at ../sysdeps/unix/sysv/linux/futex-internal.h:205
16 Thread 0x6a7ff200 (LWP 22655) "Plugin_ASIO" 0x768e59c0 in epoll_wait (epfd=<optimized out>, events=0x6a7fe340, maxevents=128, timeout=-1) at ../sysdeps/unix/sysv/linux/epoll_wait.c:30
17 Thread 0x69ffe200 (LWP 22656) "Solar Inverter" futex_wait_cancelable (private=0, expected=0, futex_word=0x6a840088) at ../sysdeps/unix/sysv/linux/futex-internal.h:88
18 Thread 0x695ff200 (LWP 22657) "EventSystem" syscall () at ../sysdeps/unix/sysv/linux/arm/syscall.S:37
19 Thread 0x68dfe200 (LWP 22658) "EventSystemQueu" futex_abstimed_wait_cancelable (private=<optimized out>, abstime=0x68dfdac0, expected=0, futex_word=0xa8d578 <m_mainworker+344>) at ../sysdeps/unix/sysv/linux/futex-internal.h:205
20 Thread 0x685fd200 (LWP 22684) "OZW-driver" futex_wait_cancelable (private=0, expected=0, futex_word=0x67b886d8) at ../sysdeps/unix/sysv/linux/futex-internal.h:88
21 Thread 0x679ff200 (LWP 22686) "OZW-dns" futex_wait_cancelable (private=0, expected=0, futex_word=0x71025de0) at ../sysdeps/unix/sysv/linux/futex-internal.h:88
22 Thread 0x671fe200 (LWP 22685) "OZW-driver" __GI___select (timeout=0x671fd9a8, exceptfds=0x671fda28, writefds=0x0, readfds=0x671fd9a8, nfds=42) at ../sysdeps/unix/sysv/linux/select.c:41
23 Thread 0x669fd200 (LWP 22687) "OZW-poll" futex_abstimed_wait_cancelable (private=<optimized out>, abstime=0x669fcaf0, expected=0, futex_word=0x72298458) at ../sysdeps/unix/sysv/linux/futex-internal.h:205
24 Thread 0x661fc200 (LWP 22688) "OZW-timer" futex_wait_cancelable (private=0, expected=0, futex_word=0x180ed30) at ../sysdeps/unix/sysv/linux/futex-internal.h:88
Thread 24 (Thread 0x661fc200 (LWP 22688)):
#0 futex_wait_cancelable (private=0, expected=0, futex_word=0x180ed30) at ../sysdeps/unix/sysv/linux/futex-internal.h:88
#1 __pthread_cond_wait_common (abstime=0x0, mutex=0x0, cond=0x180ed08) at pthread_cond_wait.c:502
#2 __pthread_cond_wait (cond=0x180ed08, mutex=0x0) at pthread_cond_wait.c:655
#3 0x00836ee8 in OpenZWave::Internal::Platform::EventImpl::Wait(int) ()
#4 0x00830fe0 in OpenZWave::Internal::Platform::Wait::Multiple(OpenZWave::Internal::Platform::Wait**, unsigned int, int) ()
#5 0x007d4a60 in OpenZWave::Internal::TimerThread::TimerThreadProc(OpenZWave::Internal::Platform::Event*) ()
#6 0x00834fe8 in OpenZWave::Internal::Platform::ThreadImpl::Run() ()
#7 0x00835004 in OpenZWave::Internal::Platform::ThreadImpl::ThreadProc(void*) ()
#8 0x76a32494 in start_thread (arg=0x661fc200) at pthread_create.c:486
#9 0x768e5568 in ?? () at ../sysdeps/unix/sysv/linux/arm/clone.S:73 from /lib/arm-linux-gnueabihf/libc.so.6
Backtrace stopped: previous frame identical to this frame (corrupt stack?)
Thread 23 (Thread 0x669fd200 (LWP 22687)):
#0 futex_abstimed_wait_cancelable (private=<optimized out>, abstime=0x669fcaf0, expected=0, futex_word=0x72298458) at ../sysdeps/unix/sysv/linux/futex-internal.h:205
#1 __pthread_cond_wait_common (abstime=0x669fcaf0, mutex=0x0, cond=0x72298430) at pthread_cond_wait.c:539
#2 __pthread_cond_timedwait (cond=0x72298430, mutex=0x0, abstime=0x669fcaf0) at pthread_cond_wait.c:667
#3 0x00837068 in OpenZWave::Internal::Platform::EventImpl::Wait(int) ()
#4 0x00830fe0 in OpenZWave::Internal::Platform::Wait::Multiple(OpenZWave::Internal::Platform::Wait**, unsigned int, int) ()
#5 0x007b7824 in OpenZWave::Driver::PollThreadProc(OpenZWave::Internal::Platform::Event*) ()
#6 0x00834fe8 in OpenZWave::Internal::Platform::ThreadImpl::Run() ()
#7 0x00835004 in OpenZWave::Internal::Platform::ThreadImpl::ThreadProc(void*) ()
#8 0x76a32494 in start_thread (arg=0x669fd200) at pthread_create.c:486
#9 0x768e5568 in ?? () at ../sysdeps/unix/sysv/linux/arm/clone.S:73 from /lib/arm-linux-gnueabihf/libc.so.6
Backtrace stopped: previous frame identical to this frame (corrupt stack?)
Thread 22 (Thread 0x671fe200 (LWP 22685)):
#0 __GI___select (timeout=0x671fd9a8, exceptfds=0x671fda28, writefds=0x0, readfds=0x671fd9a8, nfds=42) at ../sysdeps/unix/sysv/linux/select.c:41
#1 __GI___select (nfds=42, readfds=0x671fd9a8, writefds=0x0, exceptfds=0x671fda28, timeout=0x0) at ../sysdeps/unix/sysv/linux/select.c:37
#2 0x00836ab8 in OpenZWave::Internal::Platform::SerialControllerImpl::Read(OpenZWave::Internal::Platform::Event*) ()
#3 0x00836b10 in OpenZWave::Internal::Platform::SerialControllerImpl::ReadThreadProc(OpenZWave::Internal::Platform::Event*) ()
#4 0x00834fe8 in OpenZWave::Internal::Platform::ThreadImpl::Run() ()
#5 0x00835004 in OpenZWave::Internal::Platform::ThreadImpl::ThreadProc(void*) ()
#6 0x76a32494 in start_thread (arg=0x671fe200) at pthread_create.c:486
#7 0x768e5568 in ?? () at ../sysdeps/unix/sysv/linux/arm/clone.S:73 from /lib/arm-linux-gnueabihf/libc.so.6
Backtrace stopped: previous frame identical to this frame (corrupt stack?)
Thread 21 (Thread 0x679ff200 (LWP 22686)):
#0 futex_wait_cancelable (private=0, expected=0, futex_word=0x71025de0) at ../sysdeps/unix/sysv/linux/futex-internal.h:88
#1 __pthread_cond_wait_common (abstime=0x0, mutex=0x0, cond=0x71025db8) at pthread_cond_wait.c:502
#2 __pthread_cond_wait (cond=0x71025db8, mutex=0x0) at pthread_cond_wait.c:655
#3 0x00836ee8 in OpenZWave::Internal::Platform::EventImpl::Wait(int) ()
#4 0x00830fe0 in OpenZWave::Internal::Platform::Wait::Multiple(OpenZWave::Internal::Platform::Wait**, unsigned int, int) ()
#5 0x007e4068 in OpenZWave::Internal::DNSThread::DNSThreadProc(OpenZWave::Internal::Platform::Event*) ()
#6 0x00834fe8 in OpenZWave::Internal::Platform::ThreadImpl::Run() ()
#7 0x00835004 in OpenZWave::Internal::Platform::ThreadImpl::ThreadProc(void*) ()
#8 0x76a32494 in start_thread (arg=0x679ff200) at pthread_create.c:486
#9 0x768e5568 in ?? () at ../sysdeps/unix/sysv/linux/arm/clone.S:73 from /lib/arm-linux-gnueabihf/libc.so.6
Backtrace stopped: previous frame identical to this frame (corrupt stack?)
Thread 20 (Thread 0x685fd200 (LWP 22684)):
#0 futex_wait_cancelable (private=0, expected=0, futex_word=0x67b886d8) at ../sysdeps/unix/sysv/linux/futex-internal.h:88
#1 __pthread_cond_wait_common (abstime=0x0, mutex=0x0, cond=0x67b886b0) at pthread_cond_wait.c:502
#2 __pthread_cond_wait (cond=0x67b886b0, mutex=0x0) at pthread_cond_wait.c:655
#3 0x00836ee8 in OpenZWave::Internal::Platform::EventImpl::Wait(int) ()
#4 0x00830fe0 in OpenZWave::Internal::Platform::Wait::Multiple(OpenZWave::Internal::Platform::Wait**, unsigned int, int) ()
#5 0x007c89a4 in OpenZWave::Driver::DriverThreadProc(OpenZWave::Internal::Platform::Event*) ()
#6 0x00834fe8 in OpenZWave::Internal::Platform::ThreadImpl::Run() ()
#7 0x00835004 in OpenZWave::Internal::Platform::ThreadImpl::ThreadProc(void*) ()
#8 0x76a32494 in start_thread (arg=0x685fd200) at pthread_create.c:486
#9 0x768e5568 in ?? () at ../sysdeps/unix/sysv/linux/arm/clone.S:73 from /lib/arm-linux-gnueabihf/libc.so.6
Backtrace stopped: previous frame identical to this frame (corrupt stack?)
Thread 19 (Thread 0x68dfe200 (LWP 22658)):
#0 futex_abstimed_wait_cancelable (private=<optimized out>, abstime=0x68dfdac0, expected=0, futex_word=0xa8d578 <m_mainworker+344>) at ../sysdeps/unix/sysv/linux/futex-internal.h:205
#1 __pthread_cond_wait_common (abstime=0x68dfdac0, mutex=0x0, cond=0xa8d550 <m_mainworker+304>) at pthread_cond_wait.c:539
#2 __pthread_cond_timedwait (cond=0xa8d550 <m_mainworker+304>, mutex=0x0, abstime=0x68dfdac0) at pthread_cond_wait.c:667
#3 0x00213404 in CEventSystem::EventQueueThread() ()
#4 0x00906734 in execute_native_thread_routine ()
#5 0x76a32494 in start_thread (arg=0x68dfe200) at pthread_create.c:486
#6 0x768e5568 in ?? () at ../sysdeps/unix/sysv/linux/arm/clone.S:73 from /lib/arm-linux-gnueabihf/libc.so.6
Backtrace stopped: previous frame identical to this frame (corrupt stack?)
Thread 18 (Thread 0x695ff200 (LWP 22657)):
#0 syscall () at ../sysdeps/unix/sysv/linux/arm/syscall.S:37
#1 0x008e41a4 in std::__atomic_futex_unsigned_base::_M_futex_wait_until(unsigned int*, unsigned int, bool, std::chrono::duration<long long, std::ratio<1ll, 1ll> >, std::chrono::duration<long long, std::ratio<1ll, 1000000000ll> >) ()
#2 0x0020a438 in CEventSystem::Do_Work() ()
#3 0x00906734 in execute_native_thread_routine ()
#4 0x76a32494 in start_thread (arg=0x695ff200) at pthread_create.c:486
#5 0x768e5568 in ?? () at ../sysdeps/unix/sysv/linux/arm/clone.S:73 from /lib/arm-linux-gnueabihf/libc.so.6
Backtrace stopped: previous frame identical to this frame (corrupt stack?)
Thread 17 (Thread 0x69ffe200 (LWP 22656)):
#0 futex_wait_cancelable (private=0, expected=0, futex_word=0x6a840088) at ../sysdeps/unix/sysv/linux/futex-internal.h:88
#1 __pthread_cond_wait_common (abstime=0x0, mutex=0x0, cond=0x6a840060) at pthread_cond_wait.c:502
#2 __pthread_cond_wait (cond=0x6a840060, mutex=0x0) at pthread_cond_wait.c:655
#3 0x003d727c in boost::asio::detail::scheduler::run(boost::system::error_code&) ()
#4 0x003ec324 in boost::asio::detail::posix_thread::func<boost::asio::detail::resolver_service_base::work_scheduler_runner>::run() ()
#5 0x003d3140 in boost_asio_detail_posix_thread_function ()
#6 0x76a32494 in start_thread (arg=0x69ffe200) at pthread_create.c:486
#7 0x768e5568 in ?? () at ../sysdeps/unix/sysv/linux/arm/clone.S:73 from /lib/arm-linux-gnueabihf/libc.so.6
Backtrace stopped: previous frame identical to this frame (corrupt stack?)
Thread 16 (Thread 0x6a7ff200 (LWP 22655)):
#0 0x768e59c0 in epoll_wait (epfd=<optimized out>, events=0x6a7fe340, maxevents=128, timeout=-1) at ../sysdeps/unix/sysv/linux/epoll_wait.c:30
#1 0x003d519c in boost::asio::detail::epoll_reactor::run(long, boost::asio::detail::op_queue<boost::asio::detail::scheduler_operation>&) ()
#2 0x003d7194 in boost::asio::detail::scheduler::run(boost::system::error_code&) ()
#3 0x00683e74 in Plugins::BoostWorkers() ()
#4 0x0077d374 in thread_proxy ()
#5 0x76a32494 in start_thread (arg=0x6a7ff200) at pthread_create.c:486
#6 0x768e5568 in ?? () at ../sysdeps/unix/sysv/linux/arm/clone.S:73 from /lib/arm-linux-gnueabihf/libc.so.6
Backtrace stopped: previous frame identical to this frame (corrupt stack?)
Thread 15 (Thread 0x6b3f8200 (LWP 22654)):
#0 futex_abstimed_wait_cancelable (private=<optimized out>, abstime=0x6b3f7bb0, expected=0, futex_word=0xa8de7c <m_mainworker+2652>) at ../sysdeps/unix/sysv/linux/futex-internal.h:205
#1 __pthread_cond_wait_common (abstime=0x6b3f7bb0, mutex=0x0, cond=0xa8de50 <m_mainworker+2608>) at pthread_cond_wait.c:539
#2 __pthread_cond_timedwait (cond=0xa8de50 <m_mainworker+2608>, mutex=0x0, abstime=0x6b3f7bb0) at pthread_cond_wait.c:667
#3 0x00277298 in CNotificationSystem::QueueThread() ()
#4 0x00906734 in execute_native_thread_routine ()
#5 0x76a32494 in start_thread (arg=0x6b3f8200) at pthread_create.c:486
Backtrace stopped: Cannot access memory at address 0x8c
Thread 14 (Thread 0x6bbf9200 (LWP 22653)):
#0 syscall () at ../sysdeps/unix/sysv/linux/arm/syscall.S:37
#1 0x008e41a4 in std::__atomic_futex_unsigned_base::_M_futex_wait_until(unsigned int*, unsigned int, bool, std::chrono::duration<long long, std::ratio<1ll, 1ll> >, std::chrono::duration<long long, std::ratio<1ll, 1000000000ll> >) ()
#2 0x006804fc in Plugins::CPlugin::Do_Work() ()
#3 0x00906734 in execute_native_thread_routine ()
#4 0x76a32494 in start_thread (arg=0x6bbf9200) at pthread_create.c:486
#5 0x768e5568 in ?? () at ../sysdeps/unix/sysv/linux/arm/clone.S:73 from /lib/arm-linux-gnueabihf/libc.so.6
Backtrace stopped: previous frame identical to this frame (corrupt stack?)
Thread 13 (Thread 0x6c3fa200 (LWP 22652)):
#0 syscall () at ../sysdeps/unix/sysv/linux/arm/syscall.S:37
#1 0x008e41a4 in std::__atomic_futex_unsigned_base::_M_futex_wait_until(unsigned int*, unsigned int, bool, std::chrono::duration<long long, std::ratio<1ll, 1ll> >, std::chrono::duration<long long, std::ratio<1ll, 1000000000ll> >) ()
#2 0x0060fd3c in CTado::Do_Work() ()
#3 0x00906734 in execute_native_thread_routine ()
#4 0x76a32494 in start_thread (arg=0x6c3fa200) at pthread_create.c:486
#5 0x768e5568 in ?? () at ../sysdeps/unix/sysv/linux/arm/clone.S:73 from /lib/arm-linux-gnueabihf/libc.so.6
Backtrace stopped: previous frame identical to this frame (corrupt stack?)
Thread 12 (Thread 0x6cbfb200 (LWP 22651)):
#0 syscall () at ../sysdeps/unix/sysv/linux/arm/syscall.S:37
#1 0x008e41a4 in std::__atomic_futex_unsigned_base::_M_futex_wait_until(unsigned int*, unsigned int, bool, std::chrono::duration<long long, std::ratio<1ll, 1ll> >, std::chrono::duration<long long, std::ratio<1ll, 1000000000ll> >) ()
#2 0x003fc578 in CBuienRadar::Do_Work() ()
#3 0x00906734 in execute_native_thread_routine ()
#4 0x76a32494 in start_thread (arg=0x6cbfb200) at pthread_create.c:486
Backtrace stopped: Cannot access memory at address 0x2d668b5e
Thread 11 (Thread 0x6d3fc200 (LWP 22650)):
#0 syscall () at ../sysdeps/unix/sysv/linux/arm/syscall.S:37
#1 0x008e41a4 in std::__atomic_futex_unsigned_base::_M_futex_wait_until(unsigned int*, unsigned int, bool, std::chrono::duration<long long, std::ratio<1ll, 1ll> >, std::chrono::duration<long long, std::ratio<1ll, 1000000000ll> >) ()
#2 0x005a2f34 in P1MeterSerial::Do_Work() ()
#3 0x00906734 in execute_native_thread_routine ()
#4 0x76a32494 in start_thread (arg=0x6d3fc200) at pthread_create.c:486
#5 0x768e5568 in ?? () at ../sysdeps/unix/sysv/linux/arm/clone.S:73 from /lib/arm-linux-gnueabihf/libc.so.6
Backtrace stopped: previous frame identical to this frame (corrupt stack?)
Thread 10 (Thread 0x6dbfd200 (LWP 22649)):
#0 0x768e59c0 in epoll_wait (epfd=<optimized out>, events=0x6dbfc340, maxevents=128, timeout=-1) at ../sysdeps/unix/sysv/linux/epoll_wait.c:30
#1 0x003d519c in boost::asio::detail::epoll_reactor::run(long, boost::asio::detail::op_queue<boost::asio::detail::scheduler_operation>&) ()
#2 0x003d7194 in boost::asio::detail::scheduler::run(boost::system::error_code&) ()
#3 0x003d9520 in boost::detail::thread_data<AsyncSerial::open(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, unsigned int, boost::asio::serial_port_base::parity, boost::asio::serial_port_base::character_size, boost::asio::serial_port_base::flow_control, boost::asio::serial_port_base::stop_bits)::{lambda()#2}>::run() ()
#4 0x0077d374 in thread_proxy ()
#5 0x76a32494 in start_thread (arg=0x6dbfd200) at pthread_create.c:486
Backtrace stopped: Cannot access memory at address 0x8a
Thread 9 (Thread 0x6e3fe200 (LWP 22648)):
#0 syscall () at ../sysdeps/unix/sysv/linux/arm/syscall.S:37
#1 0x008e41a4 in std::__atomic_futex_unsigned_base::_M_futex_wait_until(unsigned int*, unsigned int, bool, std::chrono::duration<long long, std::ratio<1ll, 1ll> >, std::chrono::duration<long long, std::ratio<1ll, 1000000000ll> >) ()
#2 0x0066f6d4 in ZWaveBase::Do_Work() ()
#3 0x00906734 in execute_native_thread_routine ()
#4 0x76a32494 in start_thread (arg=0x6e3fe200) at pthread_create.c:486
#5 0x768e5568 in ?? () at ../sysdeps/unix/sysv/linux/arm/clone.S:73 from /lib/arm-linux-gnueabihf/libc.so.6
Backtrace stopped: previous frame identical to this frame (corrupt stack?)
Thread 8 (Thread 0x6ebff200 (LWP 22647)):
#0 __waitpid (options=0, stat_loc=0x6ebfdf98, pid=12484) at ../sysdeps/unix/sysv/linux/waitpid.c:30
#1 __waitpid (pid=12484, stat_loc=0x6ebfdf98, options=0) at ../sysdeps/unix/sysv/linux/waitpid.c:25
#2 0x0029121c in dumpstack_gdb(bool) ()
#3 0x002917e8 in signal_handler(int, siginfo_t*, void*) ()
#4 <signal handler called>
#5 raise (sig=11) at ../sysdeps/unix/sysv/linux/raise.c:50
#6 <signal handler called>
#7 0x75c5f724 in ?? () from /lib/arm-linux-gnueabihf/libpython3.7m.so
#8 0x75c5f714 in ?? () from /lib/arm-linux-gnueabihf/libpython3.7m.so
Backtrace stopped: previous frame identical to this frame (corrupt stack?)
Thread 7 (Thread 0x6fffd200 (LWP 22645)):
#0 syscall () at ../sysdeps/unix/sysv/linux/arm/syscall.S:37
#1 0x008e41a4 in std::__atomic_futex_unsigned_base::_M_futex_wait_until(unsigned int*, unsigned int, bool, std::chrono::duration<long long, std::ratio<1ll, 1ll> >, std::chrono::duration<long long, std::ratio<1ll, 1000000000ll> >) ()
#2 0x0025f5fc in MainWorker::Do_Work() ()
#3 0x00906734 in execute_native_thread_routine ()
#4 0x76a32494 in start_thread (arg=0x6fffd200) at pthread_create.c:486
Backtrace stopped: Cannot access memory at address 0xff8
Thread 6 (Thread 0x70fff200 (LWP 22643)):
#0 syscall () at ../sysdeps/unix/sysv/linux/arm/syscall.S:37
#1 0x008e41a4 in std::__atomic_futex_unsigned_base::_M_futex_wait_until(unsigned int*, unsigned int, bool, std::chrono::duration<long long, std::ratio<1ll, 1ll> >, std::chrono::duration<long long, std::ratio<1ll, 1000000000ll> >) ()
#2 0x00288690 in CScheduler::Do_Work() ()
#3 0x00906734 in execute_native_thread_routine ()
#4 0x76a32494 in start_thread (arg=0x70fff200) at pthread_create.c:486
#5 0x768e5568 in ?? () at ../sysdeps/unix/sysv/linux/arm/clone.S:73 from /lib/arm-linux-gnueabihf/libc.so.6
Backtrace stopped: previous frame identical to this frame (corrupt stack?)
Thread 5 (Thread 0x73b80200 (LWP 22638)):
#0 syscall () at ../sysdeps/unix/sysv/linux/arm/syscall.S:37
#1 0x008e41a4 in std::__atomic_futex_unsigned_base::_M_futex_wait_until(unsigned int*, unsigned int, bool, std::chrono::duration<long long, std::ratio<1ll, 1ll> >, std::chrono::duration<long long, std::ratio<1ll, 1000000000ll> >) ()
#2 0x00393ed0 in CInfluxPush::Do_Work() ()
#3 0x00906734 in execute_native_thread_routine ()
#4 0x76a32494 in start_thread (arg=0x73b80200) at pthread_create.c:486
#5 0x768e5568 in ?? () at ../sysdeps/unix/sysv/linux/arm/clone.S:73 from /lib/arm-linux-gnueabihf/libc.so.6
Backtrace stopped: previous frame identical to this frame (corrupt stack?)
Thread 4 (Thread 0x749b2200 (LWP 22637)):
#0 syscall () at ../sysdeps/unix/sysv/linux/arm/syscall.S:37
#1 0x008e41a4 in std::__atomic_futex_unsigned_base::_M_futex_wait_until(unsigned int*, unsigned int, bool, std::chrono::duration<long long, std::ratio<1ll, 1ll> >, std::chrono::duration<long long, std::ratio<1ll, 1000000000ll> >) ()
#2 0x00684684 in Plugins::CPluginSystem::Do_Work() ()
#3 0x00906734 in execute_native_thread_routine ()
#4 0x76a32494 in start_thread (arg=0x749b2200) at pthread_create.c:486
#5 0x768e5568 in ?? () at ../sysdeps/unix/sysv/linux/arm/clone.S:73 from /lib/arm-linux-gnueabihf/libc.so.6
Backtrace stopped: previous frame identical to this frame (corrupt stack?)
Thread 3 (Thread 0x751b3200 (LWP 22636)):
#0 syscall () at ../sysdeps/unix/sysv/linux/arm/syscall.S:37
#1 0x008e41a4 in std::__atomic_futex_unsigned_base::_M_futex_wait_until(unsigned int*, unsigned int, bool, std::chrono::duration<long long, std::ratio<1ll, 1ll> >, std::chrono::duration<long long, std::ratio<1ll, 1000000000ll> >) ()
#2 0x002a8698 in CSQLHelper::Do_Work() ()
#3 0x00906734 in execute_native_thread_routine ()
#4 0x76a32494 in start_thread (arg=0x751b3200) at pthread_create.c:486
#5 0x768e5568 in ?? () at ../sysdeps/unix/sysv/linux/arm/clone.S:73 from /lib/arm-linux-gnueabihf/libc.so.6
Backtrace stopped: previous frame identical to this frame (corrupt stack?)
Thread 2 (Thread 0x759b4200 (LWP 22632)):
#0 __GI___nanosleep (remaining=0x759b3bb0, requested_time=0x759b3bb0) at ../sysdeps/unix/sysv/linux/nanosleep.c:28
#1 __GI___nanosleep (requested_time=0x759b3bb0, remaining=0x759b3bb0) at ../sysdeps/unix/sysv/linux/nanosleep.c:25
#2 0x00224e2c in sleep_milliseconds(long) ()
#3 0x00291950 in Do_Watchdog_Work() ()
#4 0x00906734 in execute_native_thread_routine ()
#5 0x76a32494 in start_thread (arg=0x759b4200) at pthread_create.c:486
#6 0x768e5568 in ?? () at ../sysdeps/unix/sysv/linux/arm/clone.S:73 from /lib/arm-linux-gnueabihf/libc.so.6
Backtrace stopped: previous frame identical to this frame (corrupt stack?)
Thread 1 (Thread 0x76f0d040 (LWP 22631)):
#0 0x76a33a3c in __GI___pthread_timedjoin_ex (threadid=1858073088, thread_return=0x0, abstime=<optimized out>, block=<optimized out>) at pthread_join_common.c:89
#1 0x00906978 in std::thread::join() ()
#2 0x0067dafc in Plugins::CPlugin::StopHardware() ()
#3 0x0042df54 in CDomoticzHardwareBase::Stop() ()
#4 0x00250998 in MainWorker::StopDomoticzHardware() ()
#5 0x00250ba8 in MainWorker::Stop() ()
#6 0x001af78c in main ()
Main thread:
#0 0x76a33a3c in __GI___pthread_timedjoin_ex (threadid=1858073088, thread_return=0x0, abstime=<optimized out>, block=<optimized out>) at pthread_join_common.c:89
#1 0x00906978 in std::thread::join() ()
#2 0x0067dafc in Plugins::CPlugin::StopHardware() ()
#3 0x0042df54 in CDomoticzHardwareBase::Stop() ()
#4 0x00250998 in MainWorker::StopDomoticzHardware() ()
#5 0x00250ba8 in MainWorker::Stop() ()
#6 0x001af78c in main ()
[Inferior 1 (process 22631) detached]
Re: Python Plugin: Shelly MQTT
Posted: Monday 07 March 2022 16:31
by darrepac
I had also lot of plugin problem with latest stable. I updated to latest Beta because something has been changed about python, and everything is working much better now
Re: Python Plugin: Shelly MQTT
Posted: Monday 07 March 2022 16:33
by waltervl
Is MQTT broker (eg mosquitto) running on the same server or a different one?
As it seems that the disconnecting issue could trigger the crash (it should not).
Perhaps another issue in your environment that is triggering this? Wifi issues, Network issues, Memory issues?
@darrepac Plugin issues were on Bullseye environment not on Buster.
Re: Python Plugin: Shelly MQTT
Posted: Monday 07 March 2022 16:36
by darrepac
waltervl wrote: ↑Monday 07 March 2022 16:33
@darrepac Plugin issues were on Bullseye environment not on Buster.
I just share my experience...
Re: Python Plugin: Shelly MQTT
Posted: Monday 07 March 2022 17:47
by Robinjoo94
waltervl wrote: ↑Monday 07 March 2022 16:33
Is MQTT broker (eg mosquitto) running on the same server or a different one?
As it seems that the disconnecting issue could trigger the crash (it should not).
Perhaps another issue in your environment that is triggering this? Wifi issues, Network issues, Memory issues?
Yes, running on the same Raspberry Pi.
Will keep an eye on the logs upcoming days.
Re: Python Plugin: Shelly MQTT
Posted: Wednesday 09 March 2022 20:00
by ProjektC
Hello
I have been using Domoticz for many years
basically with Yeelight lamps in LAN mode and Shelly products.
Have various Shelly sockets, motion sensor, window detector and since short Shelly 1.
Now I thought for my daughter a Shelly button to switch on zb your lamps or colored switch.
I thought the part just turns on and off.
The Shelly Button is integrated in domoticz.
But on and off I guess I can't switch.
Instead once, twice, three times and long press.
But it's not clear to me how I can just turn anything on and off.
Or how I can assign the commands somewhere to a lamp or scene.
So I'm not sure if that works at all.
bye
Re: Python Plugin: Shelly MQTT
Posted: Monday 14 March 2022 15:17
by Robinjoo94
ProjektC wrote: ↑Wednesday 09 March 2022 20:00
But it's not clear to me how I can just turn anything on and off.
Or how I can assign the commands somewhere to a lamp or scene.
So I'm not sure if that works at all.
Have a look at:
https://www.domoticz.com/wiki/Events
Robinjoo94 wrote: ↑Monday 07 March 2022 17:47
waltervl wrote: ↑Monday 07 March 2022 16:33
Is MQTT broker (eg mosquitto) running on the same server or a different one?
As it seems that the disconnecting issue could trigger the crash (it should not).
Perhaps another issue in your environment that is triggering this? Wifi issues, Network issues, Memory issues?
Yes, running on the same Raspberry Pi.
Will keep an eye on the logs upcoming days.
So I still do not have a clear cause for my issues.
I now have a "watchdog" script running that restarts domoticz whenever went to "active (exited)".
Added a simple script/domoticz device to track the memory consumption, there seems to be some memory leak, but the error happens already when the memory consumption is at 70%, so too early in my oppinion to be caused by memory issues.
I will have to add some more monitoring to get to the root cause.
Re: Python Plugin: Shelly MQTT
Posted: Monday 14 March 2022 15:38
by waltervl
For memory tracking you can use the build in motherboard sensor gateway
https://www.domoticz.com/wiki/Motherboard_sensors
Re: Python Plugin: Shelly MQTT
Posted: Wednesday 16 March 2022 15:51
by extremeaudio
Everything was working, suddenly when i checked again I get this error
mqtt: disconnected, Invalid Username/Password (rc=5)
I havent made any changes. How can I re enable mqtt again?
log as below
Code: Select all
2022-03-16 20:19:33.143 Error: Shelly MQTT: (Shelly MQTT) Disconnected from MQTT Server: 192.168.1.63:1883
2022-03-16 20:19:33.143 Error: Shelly MQTT: (Shelly MQTT) No transport, write directive to '192.168.1.63' ignored.
2022-03-16 20:19:43.111 Shelly MQTT: (Shelly MQTT) Connected to MQTT Server: 192.168.1.63:1883
2022-03-16 20:19:43.162 Error: Shelly MQTT: (Shelly MQTT) Disconnected from MQTT Server: 192.168.1.63:1883
2022-03-16 20:19:43.162 Error: Shelly MQTT: (Shelly MQTT) No transport, write directive to '192.168.1.63' ignored.
2022-03-16 20:19:45.088 RPi: Temp (Internal Temperature)
2022-03-16 20:19:45.423 InfluxLink: value Temperature,idx=2,name=Internal-Temperature value=57.9
2022-03-16 20:19:49.444 Status: MQTT: MQTT: Connecting to localhost:1883
2022-03-16 20:19:49.646 Error: MQTT: MQTT: Connection failed!, restarting (rc=2)
2022-03-16 20:19:49.646 Error: MQTT: MQTT: disconnected, Invalid Username/Password (rc=5)
2022-03-16 20:19:53.131 Shelly MQTT: (Shelly MQTT) Connected to MQTT Server: 192.168.1.63:1883
2022-03-16 20:19:53.183 Error: Shelly MQTT: (Shelly MQTT) Disconnected from MQTT Server: 192.168.1.63:1883
2022-03-16 20:19:53.183 Error: Shelly MQTT: (Shelly MQTT) No transport, write directive to '192.168.1.63' ignored.
Re: Python Plugin: Shelly MQTT
Posted: Wednesday 16 March 2022 20:16
by waltervl
Did you update to latest beta (would conflict your statement that nothing changed..)? As this seems to be an issue now:
https://github.com/domoticz/domoticz/issues/5195
Re: Python Plugin: Shelly MQTT
Posted: Thursday 17 March 2022 10:35
by extremeaudio
I had not updated to beta. After reading your post I updated in fact to the latest beta and the problem persists.
Re: Python Plugin: Shelly MQTT
Posted: Thursday 17 March 2022 15:51
by waltervl
Is your MQTT broker running? Can you connect it with MQTT explorer?
https://www.domoticz.com/wiki/MQTT#Debugging_MQTT