dglt1 / optimus-switch

*installer finished* installs nvidia prime and makes switching to intel only and back again easy as one command. intel mode fully disables the nvidia gpu to extend battery life.
71 stars 9 forks source link

Not properly configuring BusID in /etc/X11/xorg.conf.d/99-nvidia.conf #17

Open rfestag opened 4 years ago

rfestag commented 4 years ago

I was recently having issues with the default bumblebee install on my newly installed Manjaro box. I decided to try using optimus-switch to get around it. After the install, grub booted me to a blank screen.

In my case, it looks like the BusID in my xorg config is not the assumed default (1:0:0). Somehow I missed that at the beginning of your readme.

Perhaps set-nvidia.sh could be updated to properly set the BusID based on this?

rfestag commented 4 years ago

So, I did some testing. First, here is a command that should work for getting the BusID:

nvidiaBus=`lspci | grep 3D | awk -F'[:. ]' '{print $1, $2, $3}' | sed -r 's|0([0-9]) |\1:|g'`

This takes the 02:00.0 from lspci | grep 3D and turns it into the form expected by the config (2:0:0). I tried using set-intel.sh, manually adding the BusID above, and rebooting, but ended up with the blank screen again. So, clearly that isn't sufficient to get my system up and running (or I have something else wrong).

dglt1 commented 4 years ago

the default setup uses the intel driver for intel mode, make sure xf86-video-intel is installed. i also included a configuration to use the modesetting driver instead if your not able to get the intel driver working properly.

to use the modesetting config, edit /usr/local/bin/set-intel.sh and change

cp /etc/switch/intel/intel-xorg.conf /etc/X11/xorg.conf.d/99-intel.conf

to this

cp /etc/switch/intel/modeset-xorg.conf /etc/X11/xorg.conf.d/99-intel.conf

save/exit and sudo set-intel.sh

edit: also, check these directories for any video related .conf files you may of missed and should of moved/deleted

/etc/modprobe.d/
/etc/X11/xorg.conf.d/
/etc/modules-load.d/
rfestag commented 4 years ago

Thanks for the tip. I just tried the modesetting config, no luck. I also verified there aren't any other files in those directories that could be conflicting. I am running a newer processor (Core i7-10710U), so perhaps it is just an incompatibility right now. It is odd that it worked with Bumblebee (but I had other graphics issues, which was why I started looking for alternatives). My battery life isn't fantastic, but it isn't horrible either. I can get a good 4-5 hours of active use with the Nvidia driver.