Relatively new to Ubuntu. I have a recently set-up machine running Ubuntu 22.04. It's used only for hosting games with friends so it has very little on it besides the initial installation.
Not on the initial build and first few boots, but not long after, it started shutting down with a hard power cut, waiting a few seconds, and rebooting automatically. This would happen only a few seconds after getting to the login screen, and would continue to happen on each subsequent boot.
After experimenting, it actually only shuts down a few seconds after using the USB mouse or keyboard. It can sit at login for 5 or 10 minutes, but after starting to type my password, shuts off within 10 characters. Rarely it would last long enough log in and shut off a few seconds after that.
Mouse and keyboard run fine in the BIOS.
However, if I boot to recovery mode, do no recovery options, and resume normal boot, it runs perfectly fine all day. To me that feels like a race condition but I don't know enough about ubuntu to say for sure.
Things I've tried:
- Different mouse and keyboard
- Different USB port (tower ports and direct MB ports)
- sudo apt update/upgrade
- Flashing to most current BIOS
- recovery mode option for dpkg. Running this did run some changes inthe console output the first time, but didn't fix the problem
Motherboard is MSI MAG B560M MORTAR WIFI. Though I don't think it's a hardware problem since they run fine in bios and after booting through recovery.