My operating system restarts by itself randomly, sometimes it reboots few minutes after boot, it happens 2-3 times and after that it's ok for a month, and I can't find anything suspicious in /var/log/dmesg A guy who was checking my hardware (doing stress tests for 12 hours, but on windows, I didn't give him my SSD with the system) didn't find any hardware issue.

Maybe you can find something and point me, or give me some idea where to look

Here is my /var/log/dmesg file: https://gist.github.com/pmartini/e849b65ffd6ce8ad5c14deed1b2b602a

and journalctl output: https://gist.github.com/pmartini/1e843d0f1de982f53daeaf617fa7767b

lsblk output:

loop0    7:0    0  96,6M  1 loop /snap/core/9804
loop1    7:1    0  29,9M  1 loop /snap/snapd/8790
loop2    7:2    0  55,3M  1 loop /snap/core18/1885
loop3    7:3    0  14,9M  1 loop /snap/ubuntu-mate-welcome/524
loop4    7:4    0    16K  1 loop /snap/software-boutique/54
loop5    7:5    0  97,1M  1 loop /snap/core/9993
loop6    7:6    0  14,9M  1 loop /snap/ubuntu-mate-welcome/539
loop7    7:7    0    55M  1 loop /snap/core18/1880
loop8    7:8    0 197,5M  1 loop /snap/viber-unofficial/37
loop9    7:9    0  30,3M  1 loop /snap/snapd/9279
sda      8:0    0 111,8G  0 disk 
├─sda1   8:1    0 107,1G  0 part /
├─sda2   8:2    0     1K  0 part 
└─sda5   8:5    0   4,7G  0 part [SWAP]
sr0     11:0    1  1024M  0 rom  

fdisl -l output: https://gist.github.com/pmartini/acceb0fac6c20631b4eb8c1044b724e9

grep sda5 /etc/fstab outut: # swap was on /dev/sda5 during installation

grep sda5 /proc/mounts doesn't show any output

  • dmesg only shows logs since last boot, so will probably not contain data relevant to your problem. The systemd journal is a better place to look.
    – Spooler
    Sep 28, 2020 at 16:46
  • Could you please edit your question and add the output oflsblk, fdisk -l, grep sda5 /etc/fstab and grep sda5 /proc/mounts? Sep 28, 2020 at 17:22
  • 1
    I am facing a similar issue with the Asus motherboard + Intel i7 9700 + Ubuntu. Since it looked like a hardware issue, I did a memtest86 test to check for faulty RAMs and even replaced it with a better PSU. Apparently, it wasn't a hardware issue. The random shutdowns happened on Fedora as well but not on Windows.
    – jeev
    Mar 1, 2021 at 19:33
  • 1
    it starts happening to me now...
    – Kostanos
    Nov 6, 2021 at 19:34
  • 1
    @Kostanos check your RAM with memtest, in my case reboots was caused by a memory bar Nov 8, 2021 at 19:25

3 Answers 3


It looks like I found the source of the problem, I ran memtest86 before logging into Unbuntu, and it was stopping at 40% each time I ran it. I played with RAM sticks ( I have three) for a while and found that one of them is broken (when I keep only this stick inserted the system didn't load at all and pc speaker was beeping). I bought 2 RAM sticks from a list recommended by a motherboard manufacturer and everything seems ok now.


For the next person with this problem...

I recently built a new Ubuntu 20.04.2 system, using AMD Ryzen 3700x with an NVidia GP108 graphics card, and it has had a similar behavior -- mostly works fine, but occasionally spontaneously reboots with nothing much in the system logs. It doesn't seem related to what I'm doing at the time - sometimes reboots when I'm just typing email, other times when the computer is sitting idle waiting for the timer to trigger suspend. Not a heat issue either, running below 30C with several fans installed.

I suspected a hardware issue. The system is a Ryzen 3700x, with 16GB of DDR3200 memory. As part of building, I had set the BIOS to use DDR3200. Today, I changed that BIOS setting back to Auto, letting the MB decide what memory setting to use. System has been stable for many hours now, when before I would have expected at least a few spontaneous reboots.

So, suggestion -- try changing your memory settings; the system might be a few percent slower, but that's better than rebooting at random.

  • Still stable???
    – rogerdpack
    Dec 26, 2022 at 23:59

It seems there is a problem with sdb5 partition.

Here are the relevant log entries:

вер 28 18:43:03 pc systemd[1]: dev-sdb5.device: Job dev-sdb5.device/start timed out.
вер 28 18:43:03 pc systemd[1]: Timed out waiting for device /dev/sdb5.
вер 28 18:43:03 pc systemd[1]: Dependency failed for File System Check on /dev/sdb5.
вер 28 18:43:03 pc systemd[1]: Dependency failed for /mnt/files.
вер 28 18:43:03 pc systemd[1]: Dependency failed for Local File Systems.
вер 28 18:43:03 pc systemd[1]: local-fs.target: Job local-fs.target/start failed with result 'dependency'.
вер 28 18:43:03 pc systemd[1]: mnt-files.mount: Job mnt-files.mount/start failed with result 'dependency'.
вер 28 18:43:03 pc systemd[1]: [email protected]: Job [email protected]/start failed with result 'dependency'.
вер 28 18:43:03 pc systemd[1]: dev-sdb5.device: Job dev-sdb5.device/start failed with result 'timeout'.

I think you have a 2nd disk /dev/sdb, which is not present all the time and that it is "required" to boot. It could be an USB stick.

  • yes, /dev/sdb is not connected to SATA cable (it's HDD drive with some data). Do you think it can produce reboots? I log into the system, open Chrome, etc, everything looks normal until it reboots randomly Sep 28, 2020 at 17:40

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .