tldr journalctl man journalctl
Linux
Welcome to c/linux!
Welcome to our thriving Linux community! Whether you're a seasoned Linux enthusiast or just starting your journey, we're excited to have you here. Explore, learn, and collaborate with like-minded individuals who share a passion for open-source software and the endless possibilities it offers. Together, let's dive into the world of Linux and embrace the power of freedom, customization, and innovation. Enjoy your stay and feel free to join the vibrant discussions that await you!
Rules:
-
Stay on topic: Posts and discussions should be related to Linux, open source software, and related technologies.
-
Be respectful: Treat fellow community members with respect and courtesy.
-
Quality over quantity: Share informative and thought-provoking content.
-
No spam or self-promotion: Avoid excessive self-promotion or spamming.
-
No NSFW adult content
-
Follow general lemmy guidelines.
If you launch a process from CLI, you can redirect its standard output (stdout) and standard error (stderr) to files. Errors messages might be there.
foo >> /tmp/gamelog.out 2>> /tmp/gamelog.err
Maybe the application is already saving logs or crashdumps to disk. If the game has just crashed, you can search for files modified during the last minute: find $HOME /var/log -mmin -1
That might turn up some clues on where to look.
If you have to dig deeper, look into strace (premium subscribers only).
Oh, I see now that by "crashes", you mean your whole system freezes?
Normally you might not have kernel logs left after that. In preparation if you think it might happen and want to gather the kernel log, you can put up a shell in the background and let this run: sudo dmesg -Tw | sudo tee -a /var/log/mykernel.log
It's pretty hard to totally "crash" a running Linux kernel, so understanding some details about what symptoms happened, during, and after (screen freezes, sound stops, mouse stops...etc) would be helpful to discern if this was a kernel thing, or just apps crashing. Almost always ends up being a hardware issue or resource constraint though.
As for game logs and crashing, here are some guides and info:
https://steamcommunity.com/sharedfiles/filedetails/?id=3287870137 (This shows some debug steps in detail) https://github.com/ValveSoftware/Proton/issues/6650 https://bbs.archlinux.org/viewtopic.php?id=285102
That’s a fair point.
Both system crashes were in fact a totally unresponsive system after a random action minutes after coming back from a long period of inactivity.
Crash 1: computer had been left on, downloading some software and games, for the past 2 hours. When I came back, I moved the mouse, the screen turned on again, I put down my password, saw the files that had finished downloading, and then I pressed alt tab, and the whole screen froze. After waiting 1 minute, I tried closing programs or seeing if anything was responsive, and it was not the case. No keyboard command was working, mouse wasn’t moving. I did a hard reset.
Crash 2: I’m playing something full screen, then pause to go have lunch. Come back 1 hour later, pc never went into sleep, and the screen is still on, on the pause menu. I alt tab to check my email, and when I tab back into the game the screen freezes on my email (with the tab selector in the middle).
i doubt they help, but sometimes core dump files are created when programs terminate abnormally
I think Mint uses systemd, so after rebooting, you should be able to review the system log from the previous boot with this command:
journalctl --boot=-1
The kernel might still be running even when the display is frozen. If that's the case, you can try rebooting more gently than a forced power-off would do. While holding down the Alt key, type these keys in order, with a couple seconds between each tap: SysRq R E I S U B
https://en.wikipedia.org/wiki/Magic_SysRq_key
Note: SysRq is disabled by default on some distros, and unsupported by some keyboard controllers. You can check (when the system is not frozen) by holding Alt and typing SysRq H while watching the output of sudo dmesg --follow. If it's working, you should see a help message.
For what it's worth, what you're describing sounds like it might be a GPU driver misbehaving, perhaps in response to power saving events. If you have an Nvidia card, you might try a different driver version. Otherwise, you might try an older or newer kernel version.
This is extremely helpful, thanks! Gpu is amd, as is the motherboard. I’ll be on the lookout for the next time the system freezes.