Pihole keeps shutting down - memory issue?

So my pi-hole keeps shutting down maybe 2-3 times a day. It completely shuts off both pihole and pihole-FTL. When I then ssh into the NAS and start pihole again with

pihole restartdns

Everything is fine and runs smoothly again.

I think it has to do with my memory usage, but I am not sure and cannot get any valuable information out of the logs myself. Could anyone check whether this is correct?

My debug token is iw566hdobk
Uploaded my pihole-FTL log as well using

cat /var/log/pihole-FTL.log | nc tricorder.pi-hole.net 9999

Which gives the token 0tcgu2u5bd.
I've also added a screenshot using htop

Your top display shows that you are not out of memory.

You are running an unsupported OS. Stretch and Buster are both supported, Jessie is not.

*** [ DIAGNOSING ]: Operating system
[✓] Debian GNU/Linux 8 (jessie)

Makes some sense, but this has only been a problem for a couple of days and I've been running smoothly on Jessie way longer.

Let's see if I can upgrade to stretch anyway. Hope things stay stable.

Ok so I successfully updated, and everything seems to be working again. However, I'm seeing some errors when debugging, but I am not sure whether they will cause problems or not.

Debug token is ks6imbdcq8.

So I'm currently on Stretch

*** [ DIAGNOSING ]: Operating system
[✓] Debian GNU/Linux 9 (stretch)

But last night, pihole seemed to have shut down randomly again. Can you see if there's anything wrong? The last 11 days have been without any issues.

debug token

edit: the dns service has shut down two more times throughout the day, even though pihole kept running.