- Platform information:
- Hardware: Raspberry Pi 3 Model B Rev 1.2 / 1GB RAM, 2GB swap / running off HDD
- OS: Raspbian GNU/Linux 11 (bullseye)
- Java Runtime Environment: openjdk version “11.0.16”
- openHAB version: 3.4.1 (originally an OpenHABian build)
This morning around 02:23, my OpenHAB server stopped responding on port 8080. I could ping the server but could not SSH into the server. Telnet could connect to the ports but got no response. I was seeing this about once a month but after switching to OpenJDK and OpenHAB 3.4.1, the problem seemed to be less frequent. However, the server last hung on April 10
I power-cycled the server, and checked kern.log.1, messages.1, and syslog.1 - I found nothing useful. In fact, the last entries were from May 20 or 21, yet the server was working the lights last night. The OpenHAB events log shows normal activity up to 01:42 this morning. I run a Cloud Connector check within OpenHAB every fifteen minutes - the one scheduled for 01:45 did not happen. However, Apache appears to have responded on port 8080 at 01:53 (monitors every 15 minutes, alerts after two failures).
I have been capturing hourly memory and other status information but nothing jumps out at me. It should have run at 02:00 this morning but the last data at 01:00 this morning shows:
Tue 23 May 2023 01:00:01 AM EDT
total used free shared buff/cache available
Mem: 845576 432412 50968 504 362196 349612
Swap: 2097148 267432 1829716
MemTotal: 845576 kB
MemFree: 50968 kB
MemAvailable: 349612 kB
Buffers: 78912 kB
Cached: 243580 kB
SwapCached: 28300 kB
Active: 334340 kB
Inactive: 358664 kB
Active(anon): 181196 kB
Inactive(anon): 187960 kB
Active(file): 153144 kB
Inactive(file): 170704 kB
Unevictable: 16 kB
Mlocked: 16 kB
SwapTotal: 2097148 kB
SwapFree: 1829716 kB
Dirty: 296 kB
Writeback: 0 kB
AnonPages: 353644 kB
Mapped: 31600 kB
Shmem: 504 kB
KReclaimable: 39704 kB
Slab: 71080 kB
SReclaimable: 39704 kB
SUnreclaim: 31376 kB
KernelStack: 5472 kB
PageTables: 3976 kB
NFS_Unstable: 0 kB
Bounce: 0 kB
WritebackTmp: 0 kB
CommitLimit: 2519936 kB
Committed_AS: 772368 kB
VmallocTotal: 262930368 kB
VmallocUsed: 12868 kB
VmallocChunk: 0 kB
Percpu: 768 kB
CmaTotal: 262144 kB
CmaFree: 1148 kB
After the reboot, the values are:
[09:28:04] root@openhabian:/home/openhabian# free
total used free shared buff/cache available
Mem: 845576 457936 53840 3708 333800 327456
Swap: 2097148 2064 2095084
[09:28:15] root@openhabian:/home/openhabian# cat /proc/meminfo
MemTotal: 845576 kB
MemFree: 51332 kB
MemAvailable: 325816 kB
Buffers: 7460 kB
Cached: 302436 kB
SwapCached: 116 kB
Active: 178744 kB
Inactive: 531636 kB
Active(anon): 4412 kB
Inactive(anon): 398788 kB
Active(file): 174332 kB
Inactive(file): 132848 kB
Unevictable: 16 kB
Mlocked: 16 kB
SwapTotal: 2097148 kB
SwapFree: 2095084 kB
Dirty: 28 kB
Writeback: 0 kB
AnonPages: 400488 kB
Mapped: 84984 kB
Shmem: 3708 kB
KReclaimable: 24716 kB
Slab: 53488 kB
SReclaimable: 24716 kB
SUnreclaim: 28772 kB
KernelStack: 5248 kB
PageTables: 3588 kB
NFS_Unstable: 0 kB
Bounce: 0 kB
WritebackTmp: 0 kB
CommitLimit: 2519936 kB
Committed_AS: 701984 kB
VmallocTotal: 262930368 kB
VmallocUsed: 12736 kB
VmallocChunk: 0 kB
Percpu: 768 kB
CmaTotal: 262144 kB
CmaFree: 25588 kB
CmaFree at 1148 kB stuck out, but it had been lower earlier.
Does anyone see something that might explain the hang? As a workaround, I can reboot the server every two weeks or so.