Server is constantly crashing

Discussions about RaZberry - Z-Wave board for Raspberry computer
User avatar
PoltoS
Posts: 7565
Joined: 26 Jan 2011 19:36

Re: Server is constantly crashing

Post by PoltoS »

Please do:
sudo -s
(from here all from root)
/etc/init.d/z-way-server stop
cd /opt/z-way-server
LD_LIBRARY_PATH=$LD_LIBRARY_PATH:./libs:./modules gdb ./z-way-server
> handle SIGPIPE nostop
> handle SIGILL nostop
> handle SIGHUP nostop
> (optional) set args <argument1> <argument2> ...
> r
....
(on crash) show the error message (signal that killed Z-Way) and gather some stats:
> bt
> info thr

If you can first run screee and then on crash allow us to connect to the box, would be even better. But let's first collect this info to see if different people have same problems or we need to address all of you personally.

Of course version should be v2.3.6!
kpanchen
Posts: 25
Joined: 08 Sep 2017 05:27

Re: Server is constantly crashing

Post by kpanchen »

PoltoS wrote:
26 Oct 2017 01:42
Please do:
...

Of course version should be v2.3.6!
Will do and report!

Thanks,
K.
paaland
Posts: 16
Joined: 08 Jun 2017 09:24
Location: Norway

Re: Server is constantly crashing

Post by paaland »

For me it would not start using the described method:

Code: Select all

$ sudo -s
root@razberry:/home/pi# /etc/init.d/z-way-server stop
Stopping z-way-server: done.
root@razberry:/home/pi# cd /opt/z-way-server
root@razberry:/opt/z-way-server# LD_LIBRARY_PATH=$LD_LIBRARY_PATH:./libs:./modules gdb ./z-way-server
GNU gdb (Raspbian 7.7.1+dfsg-5+rpi1) 7.7.1
Copyright (C) 2014 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
and "show warranty" for details.
This GDB was configured as "arm-linux-gnueabihf".
Type "show configuration" for configuration details.
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>.
Find the GDB manual and other documentation resources online at:
<http://www.gnu.org/software/gdb/documentation/>.
For help, type "help".
Type "apropos word" to search for commands related to "word"...
Reading symbols from ./z-way-server...(no debugging symbols found)...done.
(gdb) handle SIGPIPE nostop
Signal        Stop      Print   Pass to program Description
SIGPIPE       No        Yes     Yes             Broken pipe
(gdb) r
Starting program: /opt/z-way-server/z-way-server
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/arm-linux-gnueabihf/libthread_db.so.1".
Cannot access memory at address 0x0

Program received signal SIGILL, Illegal instruction.
0x7665bde8 in ?? () from /usr/lib/arm-linux-gnueabihf/libcrypto.so.1.0.0
(gdb)
User avatar
PoltoS
Posts: 7565
Joined: 26 Jan 2011 19:36

Re: Server is constantly crashing

Post by PoltoS »

type twice "c"

or add "handle SIGILL nostop"

first is better as only first two SIGILL are not a proble, others (if any) will lead to crash.

Those two SIGILL are used to test the CPU instructions available and are trapped by the program. No harm.
kpanchen
Posts: 25
Joined: 08 Sep 2017 05:27

Re: Server is constantly crashing

Post by kpanchen »

Here's the crash log, restarted, will see if the next one is the same.

Code: Select all

kpanchen@raspberrypi:~ $ sudo -s
root@raspberrypi:/home/kpanchen# /etc/init.d/z-way-server stop
Stopping z-way-server: rm: cannot remove ‘/var/run/z-way-server.pid’: No such file or directory
done.
root@raspberrypi:/home/kpanchen# cd /opt/z-way-server
root@raspberrypi:/opt/z-way-server# LD_LIBRARY_PATH=$LD_LIBRARY_PATH:./libs:./modules gdb ./z-way-server
GNU gdb (Raspbian 7.7.1+dfsg-5+rpi1) 7.7.1
Copyright (C) 2014 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
and "show warranty" for details.
This GDB was configured as "arm-linux-gnueabihf".
Type "show configuration" for configuration details.
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>.
Find the GDB manual and other documentation resources online at:
<http://www.gnu.org/software/gdb/documentation/>.
For help, type "help".
Type "apropos word" to search for commands related to "word"...
Reading symbols from ./z-way-server...(no debugging symbols found)...done.
(gdb) handle SIGPIPE nostop
Signal        Stop      Print   Pass to program Description
SIGPIPE       No        Yes     Yes             Broken pipe
(gdb) r
Starting program: /opt/z-way-server/z-way-server
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/arm-linux-gnueabihf/libthread_db.so.1".
Cannot access memory at address 0x0

Program received signal SIGILL, Illegal instruction.
0x7666dde8 in ?? () from /usr/lib/arm-linux-gnueabihf/libcrypto.so.1.0.0
(gdb) c
Continuing.
Z-Way version v2.3.6 from 2017-10-04 15:13:33 +0300 (build a25d58db56fe93180d0e891dcc11d62d87ec8c2c)
Looking for modules in ./modules
Module modzwave.so loaded
Module modskininstaller.so loaded
Module moddhs.so loaded
Module modnotification2ext.so loaded
Module modzbw.so loaded
Module modinstaller.so loaded
Module modenocean.so loaded
Module modhttp.so loaded
Module modhomekit.so loaded
Module modws.so loaded
Module modsockets.so loaded
Module modcrypto.so loaded
Module modiconinstaller.so loaded
Using default configuration file config.xml
Error: 'debug-port' number is out of range. Skipping it.
[New Thread 0x756b3450 (LWP 10082)]
[New Thread 0x74eb3450 (LWP 10083)]
(removed Thread info)
[New Thread 0x70aff450 (LWP 10869)]
[New Thread 0x714ff450 (LWP 10870)]
[Thread 0x714ff450 (LWP 10870) exited]
[Thread 0x70aff450 (LWP 10869) exited]
[New Thread 0x70aff450 (LWP 10975)]
[New Thread 0x714ff450 (LWP 10976)]
[Thread 0x714ff450 (LWP 10976) exited]
[Thread 0x70aff450 (LWP 10975) exited]
[New Thread 0x70aff450 (LWP 11091)]
[New Thread 0x714ff450 (LWP 11092)]
[Thread 0x714ff450 (LWP 11092) exited]
[Thread 0x70aff450 (LWP 11091) exited]

Program received signal SIGHUP, Hangup.
0x76403360 in nanosleep () at ../sysdeps/unix/syscall-template.S:81
81      ../sysdeps/unix/syscall-template.S: No such file or directory.
(gdb) bt
#0  0x76403360 in nanosleep () at ../sysdeps/unix/syscall-template.S:81
#1  0x76403098 in __sleep (seconds=0) at ../sysdeps/unix/sysv/linux/sleep.c:137
#2  0x0000aeb4 in main ()
(gdb) info thr
  Id   Target Id         Frame
  10   Thread 0x72aff450 (LWP 10092) "zway/core" 0x7642e964 in select ()
    at ../sysdeps/unix/syscall-template.S:81
  9    Thread 0x73aff450 (LWP 10091) "zway/timers" 0x76403360 in nanosleep ()
    at ../sysdeps/unix/syscall-template.S:81
  8    Thread 0x742ff450 (LWP 10090) "zway/webserver" 0x7642e964 in select ()
    at ../sysdeps/unix/syscall-template.S:81
  7    Thread 0x74e73450 (LWP 10087) "zway/core" 0x76403360 in nanosleep ()
    at ../sysdeps/unix/syscall-template.S:81
  6    Thread 0x74e83450 (LWP 10086) "v8:SweeperThrea" 0x76986a40 in do_futex_wait (isem=isem@entry=0x6477c) at ../nptl/sysdeps/unix/sysv/linux/sem_wait.c:48
  5    Thread 0x74e93450 (LWP 10085) "v8:SweeperThrea" 0x76986a40 in do_futex_wait (isem=isem@entry=0x64674) at ../nptl/sysdeps/unix/sysv/linux/sem_wait.c:48
  4    Thread 0x74ea3450 (LWP 10084) "v8:SweeperThrea" 0x76986a40 in do_futex_wait (isem=isem@entry=0x6456c) at ../nptl/sysdeps/unix/sysv/linux/sem_wait.c:48
  3    Thread 0x74eb3450 (LWP 10083) "v8:SweeperThrea" 0x76986a40 in do_futex_wait (isem=isem@entry=0x64464) at ../nptl/sysdeps/unix/sysv/linux/sem_wait.c:48
  2    Thread 0x756b3450 (LWP 10082) "OptimizingCompi" 0x76986a40 in do_futex_wait (isem=isem@entry=0x6431c) at ../nptl/sysdeps/unix/sysv/linux/sem_wait.c:48
* 1    Thread 0x7634b000 (LWP 10067) "z-way-server" 0x76403360 in nanosleep ()
    at ../sysdeps/unix/syscall-template.S:81

User avatar
PoltoS
Posts: 7565
Joined: 26 Jan 2011 19:36

Re: Server is constantly crashing

Post by PoltoS »

What happens if you just type "c" to continue?
User avatar
PoltoS
Posts: 7565
Joined: 26 Jan 2011 19:36

Re: Server is constantly crashing

Post by PoltoS »

Definitely, SIGHUP is used in Z-Way like in other daemons like syslog and apache to rotate logs - so just continue. This is not a crash.

I've updated the instruction above to reflect this.
kpanchen
Posts: 25
Joined: 08 Sep 2017 05:27

Re: Server is constantly crashing

Post by kpanchen »

PoltoS wrote:
28 Oct 2017 21:51
What happens if you just type "c" to continue?

Code: Select all

[New Thread 0x720ff450 (LWP 1455)]
[New Thread 0x70cff450 (LWP 1456)]
[Thread 0x70cff450 (LWP 1456) exited]
[Thread 0x720ff450 (LWP 1455) exited]

Program received signal SIGHUP, Hangup.
0x76403360 in nanosleep () at ../sysdeps/unix/syscall-template.S:81
81      ../sysdeps/unix/syscall-template.S: No such file or directory.
(gdb) c
Continuing.
[New Thread 0x720ff450 (LWP 5002)]
[New Thread 0x70cff450 (LWP 5003)]
[Thread 0x70cff450 (LWP 5003) exited]
[Thread 0x720ff450 (LWP 5002) exited]
[New Thread 0x720ff450 (LWP 5095)]
[New Thread 0x70cff450 (LWP 5096)]
[Thread 0x70cff450 (LWP 5096) exited]
[Thread 0x720ff450 (LWP 5095) exited]
[New Thread 0x720ff450 (LWP 5196)]
[New Thread 0x70cff450 (LWP 5197)]
[Thread 0x70cff450 (LWP 5197) exited]
[Thread 0x720ff450 (LWP 5196) exited]
[New Thread 0x720ff450 (LWP 5211)]
[New Thread 0x70cff450 (LWP 5212)]
[Thread 0x70cff450 (LWP 5212) exited]
[Thread 0x720ff450 (LWP 5211) exited]
[New Thread 0x720ff450 (LWP 5252)]
[New Thread 0x70cff450 (LWP 5253)]
[Thread 0x70cff450 (LWP 5253) exited]
[Thread 0x720ff450 (LWP 5252) exited]
[New Thread 0x720ff450 (LWP 5266)]
[New Thread 0x70cff450 (LWP 5267)]
[Thread 0x70cff450 (LWP 5267) exited]
[Thread 0x720ff450 (LWP 5266) exited]
After "continue" it took awhile but seems like eventually server start responding, keeping monitoring.
pierre2302
Posts: 132
Joined: 15 Oct 2013 19:04

Re: Server is constantly crashing

Post by pierre2302 »

If you use a raspberry made with SD card the servers are unstable.

The ideal is to use a hard disk.
" Raspi 2 (RaZberry) / Raspi B (Razberry) " With OpenRemote Free 2.2.0_TTS-Email-Serial and Z-Way
User avatar
PoltoS
Posts: 7565
Joined: 26 Jan 2011 19:36

Re: Server is constantly crashing

Post by PoltoS »

pierre2302 wrote:
29 Oct 2017 21:37
If you use a raspberry made with SD card the servers are unstable.

The ideal is to use a hard disk.
Please provide evidence. It is hard to account for such bug reports, since there are no valuable info in them. What means unstable?

I still use RPi v1 at home since 2013! Still works, never hangs, never crashes, never changed the SD card. And of course I always upgrade to the latest (even before official releases)
Post Reply