Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

I have a Dell 5110 laptop that has hybrid graphics. I have tried using vgaswitcheroo to some limited success, but I have still not been able to select my discrete ATI 6470 card. I use the following commands with the following outputs:

root@mikelaptop:~# cat /sys/kernel/debug/vgaswitcheroo/switch
0:DIS: :Off:0000:01:00.0  
1:IGD:+:Pwr:0000:00:02.0

root@mikelaptop:~# echo ON > /sys/kernel/debug/vgaswitcheroo/switch

root@mikelaptop:~# cat /sys/kernel/debug/vgaswitcheroo/switch
0:DIS: :Pwr:0000:01:00.0  
1:IGD:+:Pwr:0000:00:02.0

root@mikelaptop:~# echo DIS > /sys/kernel/debug/vgaswitcheroo/switch

root@mikelaptop:~# cat /sys/kernel/debug/vgaswitcheroo/switch
0:DIS: :Pwr:0000:01:00.0  
1:IGD:+:Pwr:0000:00:02.0

root@mikelaptop:~# echo IGD > /sys/kernel/debug/vgaswitcheroo/switch

root@mikelaptop:~# cat /sys/kernel/debug/vgaswitcheroo/switch
0:DIS: :Pwr:0000:01:00.0  
1:IGD:+:Pwr:0000:00:02.0

root@mikelaptop:~# echo OFF > /sys/kernel/debug/vgaswitcheroo/switch

root@mikelaptop:~# cat /sys/kernel/debug/vgaswitcheroo/switch
0:DIS: :Off:0000:01:00.0  
1:IGD:+:Pwr:0000:00:02.0

As you can see here, vgaswitcheroo turns power on and off to my discrete card, but for some reason will not select my discrete card. When I tried using echo DDIS > /sys/kernel/debug/vgaswitcheroo/switch, then logged out, my system froze. Can anyone help me?

Thanks!

share|improve this question
add comment

3 Answers

this worked for me (hybrid with i915 - radeon redwood (5000), ubuntu 11.10 64, unity)

most laptop "hybrid equiped" boot with both gpu ON (could explain why batteries last so few with a fresh install of ubuntu and default GRUB settings), but with IGD (i915) connected (seems to be by default with no BIOS tweak)

Well, lets say your're allready logged in Unity (or Gnome):

Just want to power off DIS to save your batt (you'll probably gain about 30 to 40%+ time) ? issue that in a terminal

echo "OFF"|sudo tee /sys/kernel/debug/vgaswitcheroo/switch

But I can guess your're waiting for more than that... switch from IGD to DIS!

Ok, read : first logoff unity... yes, you need!

open another terminal with

CRTL-ALT-F1

login and stop lightdm (on which runs the Unity shell)

sudo service lightdm stop

connect discret gpu (right after pressing ENTER, your screen may flicker... that sounds good! or it may ... just freeze! depend your setup.

echo "DDIS"|sudo tee /sys/kernel/debug/vgaswitcheroo/switch

verify the status

sudo cat /sys/kernel/debug/vgaswitcheroo/switch

should get

0:IGD: :Off:0000:00:02.0
1:DIS:+:Pwr:0000:01:00.0

then what you need is start the lightdm-Unity GUI

sudo service lightdm start

At that point you should get a regular Ubuntu 11 login screen, if not, try pressing

CRTL-ALT-F7 and login running on the DIS GPU

if it don't work, your computer may have frozen. Try back

CRTL-ALT-F1

to get the terminal and restart.

If you succeed to connect and use your DIS GPU, you will switch back to default both gpu ON with IGD connected setting next time you'll restart...

That's a really poor hybrid GPU switch support... but it works. Should be possible to force your prefered GPU setting during boot, just after vgaswitcheroo is available and before lightdm starts.

Better could be with GRUB and menu choice... if anyone knows how to?

Greater could be a script to run inside Unity... I'm afraid it'll be hard to do, because lightdm must be restarted!

share|improve this answer
    
Sorry I had to say no, but my system froze when I switched to the discrete card... thanks for your reply, though. –  user44251 Jan 30 '12 at 16:38
    
damn! does it froze even if you issue this command before? sudo service lightdm stop –  sevenwd Feb 1 '12 at 1:19
    
Also didn't work here (HP Pavilion g4, Ubuntu 13.04). If I issue it before sudo service lightdm stop, it tells that client 0 refused. –  BornToCode Jan 24 at 9:20
add comment

Did you try in safe mode? I have a HP and the only way to turn on discrete, switch to discrete and turn the integrated off, is on safe mode. But then, I've got a blank screen on boot. No way to use the discrete.

HP Pavilion dv6 3160us Integrated: ATI 4250 Discrete: ATI 5650

share|improve this answer
add comment

I can use any of these methods to control the both GPUs on Arch Linux but here Ubuntu 14.04 absolutely ignores any change made to the switch file.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.