drivers - After upgrade, nVidia card is ON by default - Ask Ubuntu
after recent update on 16.04.1, involved nvidia drivers, nvidia card (optimus) turned on default @ every boot, causing overheating.
i can tell card on because cat /proc/acpi/bbswitch
returns 0000:01:00.0 on
. turn off use sudo tee /proc/acpi/bbswitch <<<off
.
in past, when experimenting nvidia drivers , xorg edgers ppa repo, experienced similar problem, solved purging repo , reinstalling drivers in ubuntu repo. since latter driver i'm using, wonder can fix problem.
after mixing solutions bumblebee not disabeling nvidia , http://www.webupd8.org/2016/08/how-to-install-and-configure-bumblebee.html seems have got place now.
here steps have performed (modulo bad memory!)
purge bumblebee* , primus*
install
nvidia-prime
make sure nvidia drivers installed system settings -> software & updates -> additional drivers. have tried nvidia-370, didn't work first time. can give try, in end i've got working proprietary driver nvidia-367.
sudo prime-select intel
(if fails first time, reboot might help).install bumblebee testing ppa
ppa:bumblebee/testing
, installbumblebee
blacklist drivers you've opted in
/etc/modprobe.d/bumblebee.conf
. in case had add# 367 blacklist nvidia-367 blacklist nvidia-367-updates blacklist nvidia-experimental-367 remove nvidia rmmod nvidia-drm nvidia-modeset nvidia-uvm nvidia
apparently last line crucial , 1 thing got solution work me (without line still got nvidia card work, turns on automatically @ boot , won't turn off
bbswitch
).configure
bumblebee
editing/etc/bumblebee/bumblebee.conf
.driver=
in[bumblebeed]
section. not necessary, if blank after=
, putnvidia
. make sure have these settings[driver-nvidia] kerneldriver=nvidia-367 pmmethod=auto librarypath=/usr/lib/nvidia-367:/usr/lib32/nvidia-367 xorgmodulepath=/usr/lib/nvidia-367/xorg,/usr/lib/xorg/modules xorgconffile=/etc/bumblebee/xorg.conf.nvidia
replace 367 chosen version.
sudo update-initramfs -u
reboot.
to test ok run command:
`read b <<< `cat /proc/acpi/bbswitch`; echo "nvidia card @ $a $b"`
you should get
nvidia card @ 0000:01:00.0 off
by running glxinfo
on optirun
, instance optirun glxinfo | grep opengl
, should this
opengl vendor string: nvidia corporation opengl renderer string: geforce gt 540m/pcie/sse2 opengl core profile version string: 4.5.0 nvidia 367.57 opengl core profile shading language version string: 4.50 nvidia opengl core profile context flags: (none) opengl core profile profile mask: core profile opengl core profile extensions: opengl version string: 4.5.0 nvidia 367.57 opengl shading language version string: 4.50 nvidia opengl context flags: (none) opengl profile mask: (none) opengl extensions:
which shows nvidia drivers used optirun
.
steps 6-8 can automated following bash script.
if [ "$euid" -ne 0 ] echo "this script requires superuser privileges run" fi sudo apt update echo "here list of (possibly) nvidia drivers available current software repositories" apt-cache search nvidia- | grep "nvidia-[0-9]\+ - n" echo -n "enter version wish install , hit [enter]: " read ver echo $ver echo "installing specified driver..." sudo apt install -y nvidia-${ver} echo -n "removing duplicate entries in /etc/modprobe.d/bumblebee.conf... " sed "/blacklist nvidia.\+$ver/d" /etc/modprobe.d/bumblebee.conf > bumblebee.conf sed -i "/\#.\+$ver/d" bumblebee.conf sed -i "/remove nvidia rmmod nvidia-drm nvidia-modeset nvidia-uvm nvidia/d" bumblebee.conf echo "done." echo -n "blacklisting drivers... " echo "# ${ver}" >> bumblebee.conf echo "blacklist nvidia-${ver}" >> bumblebee.conf echo "blacklist nvidia-${ver}-updates" >> bumblebee.conf echo "blacklist nvidia-experimental-${ver}" >> bumblebee.conf echo "remove nvidia rmmod nvidia-drm nvidia-modeset nvidia-uvm nvidia" >> bumblebee.conf sudo cp /etc/modprobe.d/bumblebee.conf /etc/modprobe.d/bumblebee.conf.bak sudo mv bumblebee.conf /etc/modprobe.d/bumblebee.conf echo "done." echo -n "configuring bumblebee... " sed "s/^driver=$/driver=nvidia/g" /etc/bumblebee/bumblebee.conf > bumblebee.conf sed -i "s/^kerneldriver=nvidia-.*/kerneldriver=nvidia-${ver}/g" bumblebee.conf sed -i "s|\(/usr/lib[32]*/nvidia-\)[^,:/\n]\+|\1${ver}|g" bumblebee.conf sudo cp /etc/bumblebee/bumblebee.conf /etc/bumblebee/bumblebee.conf.bak sudo mv bumblebee.conf /etc/bumblebee/bumblebee.conf echo "done." sudo update-initramfs -u echo "" echo "please restart system changes take effect."
Comments
Post a Comment