this post was submitted on 13 Dec 2024
26 points (96.4% liked)
linux4noobs
1420 readers
2 users here now
linux4noobs
Noob Friendly, Expert Enabling
Whether you're a seasoned pro or the noobiest of noobs, you've found the right place for Linux support and information. With a dedication to supporting free and open source software, this community aims to ensure Linux fits your needs and works for you. From troubleshooting to tutorials, practical tips, news and more, all aspects of Linux are warmly welcomed. Join a community of like-minded enthusiasts and professionals driving Linux's ongoing evolution.
Seeking Support?
- Mention your Linux distro and relevant system details.
- Describe what you've tried so far.
- Share your solution even if you found it yourself.
- Do not delete your post. This allows other people to see possible solutions if they have a similar problem.
- Properly format any scripts, code, logs, or error messages.
- Be mindful to omit any sensitive information such as usernames, passwords, IP addresses, etc.
Community Rules
- Keep discussions respectful and amiable. This community is a space where individuals may freely inquire, exchange thoughts, express viewpoints, and extend help without encountering belittlement. We were all a noob at one point. Differing opinions and ideas is a normal part of discourse, but it must remain civil. Offenders will be warned and/or removed.
- Posts must be Linux oriented
- Spam or affiliate links will not be tolerated.
founded 1 year ago
MODERATORS
you are viewing a single comment's thread
view the rest of the comments
view the rest of the comments
Sometimes the freeze might be in the display manager. Eg xorg or your wayland compositor has crashed.
In that case, you can use keyboard controls to change tty and fall back to a text interface. I think it's ctrl + alt + Fn$number, where $number will correspond to the tty you want. Most graphical sessions launch on tty2, so you would use crtl + alt + F1 to switch to tty1.
From there you can log in and use terminal commands to launch a new gui session, or to try and debug what went wrong. Generally, I've only had freezing issues on Linux when my GPU is dying. There was also a period where my work computer didn't have enough swap space. It would freeze whenever I tried to compile code during a video call.
Since I am still quite new to Linux, is swap space referring to swap RAM?
swap space is a dedicated place on your hard drive that the OS throws stuff to when there isn't enough ram for everything. this is called swapping. since the hard drive is involved, swapping can slow things down a lot. if you get close to filling both ram and swap space, the machine starts shedding load by killing programs.
My display manager keeps hanging during wallpaper engine development, never does respond to Ctrl+Alt+F2. Only REISUB seems to be able to save me. Never had anything borked or out of place after reboot. Any ideas? That still sound like the display driver crashing? Haven't done much diagnosing since I'd have to cludge through troubleshooting over SSH on Android at random :\
have you tried other ttys? there could be something running on 2.
Tried F1-6, no love. Only thing that does respond is the mouse movement... keyboard only responds to input reisub. I think if I am at keyboard and the screen does not lock, any windows open will respond to mouse hover but not clicks... I need a linux doctor lol. Maybe a second display for outputting kernel logs, that would be fun for dev work. Though I feel like ssh is the defacto way to accomplish that... Anything we can accomplish with one host and two displays, no network?
Prompted GPT
It sounds like you're encountering a kernel-level or X/Wayland-level freeze while developing. The fact that the keyboard is unresponsive except for
REISUB
suggests a deep hang in the graphical session or related system processes.Here’s a practical way to debug and diagnose this issue with two displays and one host, without needing a network:
Setup for Debugging on Two Displays
Enable Persistent Kernel Logs on Second Display:
Ctrl+Alt+F2
(or F3-F6, depending on availability).Mirror Logs or Virtual Console Across Displays:
tmux
orscreen
) to duplicate the kernel log view.tmux
in TTY1 and attach to it from TTY2: Then on the second TTY:Improve Debugging Workflow
Set Up Magic SysRq for More Control:
REISUB
, the Magic SysRq key is already enabled. You can use other commands to debug live:Alt + SysRq + F
can attempt to kill resource-hogging processes.Alt + SysRq + R
can re-enable raw keyboard input if the GUI is frozen.Enable Kernel Debugging Outputs:
debug
to your kernel boot parameters in GRUB:/etc/default/grub
:Use a Non-GUI Target:
Forcefully Isolate the Process:
:1
while keeping your primary desktop untouched.Tips to Prevent GUI Freezes During Development
ulimit
to restrict resource usage of your program:Could be a GPU driver bug. I get them occasionally with amdgpu. In this case only hard reset works (no it's not a hardware problem, Windows never freezes like that).
BTW you can get logs of the pervious boot using
journalctl -b -1
command. Useful for debugging freezes like this.Some desktop environments will allow Ctrl Alt Backspace to restart the environment. It's the Linux equivalent of killing Windows Explorer, and sometime just as sketchy.
One time I accidentally went into tty and had no idea what it was. Had to wait a day or so for someone to reply to my stack post telling me what tty was and how to exit it.