1

I let my RPi on yesterday with several scripts open and running. But when I came back today, all the scripts were closed, like if the RPI rebooted. I read that Raspbian, contrary to Windows, is not doing auto-update. So, I don't know what happened.

It doesn't look like Power failure, because I was using the same power delivery (5 V - 3 A) for a while without any problems. But I cannot exclude there was no blackout in the building, I don't know that.

Are there any log file that could tell me what happened during the night?

Thanks in advance.

[EDIT] Here the last entries of the last -x command (without pi user): (I set up everything around 18h yesterday (25th), and discovered the problem around 15h today (26th). I rebooted the Pi manually at 15h56)

runlevel (to lvl 5)   5.4.72-v7l+      Tue Jan 26 15:56   still running
reboot   system boot  5.4.72-v7l+      Thu Jan  1 09:00   still running
shutdown system down  5.4.72-v7l+      Tue Jan 26 15:56 - 09:00 (-18653+06:56)
runlevel (to lvl 5)   5.4.72-v7l+      Mon Jan 25 17:23 - 15:56  (22:33)
reboot   system boot  5.4.72-v7l+      Thu Jan  1 09:00 - 15:56 (18653+06:56)
Dark Patate
  • 103
  • 2
  • 9
  • look at the output of last -x ... if there was a power failure, you'll see (ignoring the user entries) a sequence of runlevel, reboot, runlevel - the last runlevel being from the previous boot ... whereas a controlled reboot results in runlevel, reboot, shutdown ... now you should be able to determine if you indeed had a power failure – Jaromanda X Jan 26 '21 at 06:25
  • Thanks for the command. I cannot see any power failure between yesterday and today. So I don't know what happened :/ – Dark Patate Jan 26 '21 at 09:13
  • so, only proper reboots - you can also see if the pi has rebooted using the uptime command - this will tell you how long it's been running since the last boot - regardless if it was reboot or power off/on – Jaromanda X Jan 26 '21 at 09:13
  • You should take a few minutes to read this related Q&A on reboot – Seamus Jan 26 '21 at 09:19
  • I'm not totally sure as the orders of the entries from last -x are a bit strange. I edited my post with a copy of the last 2 days. I'll look you link @Seamus – Dark Patate Jan 26 '21 at 09:28
  • Yes - I agree, they are strange :) They can be deciphered though - you'll find some of that in this answer & the comments that follow it. – Seamus Jan 26 '21 at 09:43
  • So, it happened again. But today it happened also during the day. And I realised that the Pi didn't reboot because SSH connection remained. So, it means the Pi shutdown itself all my scripts. Can the Pi kills all the processes in case of asking to much CPU power? – Dark Patate Jan 28 '21 at 07:23

0 Answers0