To disable the integrated GPU (usually Intel) and use only the dedicated GPU (e.g., NVIDIA or AMD) on Linux (Ubuntu or similar), here are the most reliable methods:
1.Disable the iGPU in BIOS/UEFI (recommended if available)
Reboot your PC.
Enter BIOS/UEFI (usually Del, F2, F10, etc. depending on the manufacturer).
Go to Advanced > Integrated Graphics or IGD settings.
Disable the integrated GPU (set to Disable, Auto, or PEG/PCI-E depending on the BIOS).
Save and reboot.
Advantage: clean hardware-level solution.
2.Blacklist the integrated GPU kernel module (if BIOS doesn't allow it)
Example for Intel iGPU:
Edit the blacklist configuration:
sudo nano /etc/modprobe.d/blacklist.conf
Add the following line:
blacklist i915
Then update initramfs:
sudo update-initramfs -u
Reboot
i915 is the kernel module for Intel GPU.
Verify After Reboot
Check which GPU is active for rendering:
glxinfo | grep "OpenGL renderer"
Check if the processor graphic unit module is still loaded:
lsmod | grep i915 # for exemple for intel
After, share again with us:
inxi -Gx