In system administration, there is a weird sense of gratification that comes with solving a problem, doubly so when the problem stems from a self-inflicted foot shooting.
I had such an instance this week, when I fixed a very subtle problem that had been driving me nuts for the better part of a year. Not a major issue, which is why it languished for that long before I pursued it, but one of those irritating, low-level annoyances.
My laptop is a fairly long-in-the-tooth Lenovo Thinkpad W520. The -20 series was the last one with the good keyboard. Not a fan of chicklet keyboards...My mac drives me nuts when I have to use the laptop without the cherry blue switch clicky keyboard on my KVM switch. But I digress. This probably happened when I was running 14.0 or 14.1. The laptop comes with Optimus graphics, a combined Intel and nVidia graphics card. However, at least on hardware of this ilk, it didn't seem to work well. However, in 2024, I kind of got a burr under my saddle to either get optimus working, or barring that, switching to the the nVidia card.
So I went into BIOS, enabled optimus, and messed around with it. couldn't get it to work. I don't know if newer versions work better, but I couldn't get optimus to work, so I set BIOS to discrete graphics, and then booted back into FreeBSD. I installed the nvidia drivers, and changed my xorg to use it. However, running nvidia-driver, instead of giving me the 1920x1080, I could only get 1280x720. Instead of sinking a bunch of time into it, I decided to go back to Intel graphics. Once more into BIOS, force Intel only on the graphics, then set the i915kms driver in FreeBSD.
After a while, I noticed that graphics were...weird. I could run a video, but if I went full screen, it would go fullscreen, but the video would remain the original resolution. Then, as I noted in an earlier blog post, I have been setting up games, both on my laptop and desktop. I noticed games like UFO: Alien Invasion would dump core, various other wine games would fail, unable to load GLX. I know you old FreeBSD-heads are snickering into your sleeves at this point, but I started digging, and ran across a post on Stack Exchange, and everything fell into place. The solution description,
"It turns out that nvidia-driver overwrites files previously installed by xorg and/or drm-next-kmod. As a result the X server is unable to determine, what is really in charge of supporting GL."
This brought everything into focus, and it all clicked. I removed the nvidia drivers, reinstalled the intel and drm drivers, and rebooted. At that point, things started to work again. Fullscreen is actually fullscreen, games and other graphics-related stuff works.
Problem solved, endorphins rushed.