Dans le 2ème lien que tu donnes, on te dit que cette méthode ne marche pas avec Optimus et on te renvoie à Bumblebee ...
Effectivement, je vais donc prendre celui du wiki de fedora
Je vous tiendrai au courant
Regarde aussi si tu ne peux pas désactiver la carte intel à partir de ton bios.
Tu perdras en autonomie, mais tu n'auras pas de soucis avec Bumblebee, tu n'auras qu'a installer les drivers nvidia.
chepioq wrote:Regarde aussi si tu ne peux pas désactiver la carte intel à partir de ton bios.
Tu perdras en autonomie, mais tu n'auras pas de soucis avec Bumblebee, tu n'auras qu'a installer les drivers nvidia.
Bien evidement c'est la premiere chose que j'ai fait, et bien sur j'en ai pas la posibilité
jje teste la methode du premier lien
[olivier@localhost ~]$ optirun glxspheres                                                                                                                                            
[  688.351154] [ERROR]The Bumblebee daemon has not been started yet or the socket path /var/run/bumblebee.socket was incorrect.                                                              
[  688.351174] [ERROR]Could not connect to bumblebee daemon - is it running? 
[olivier@localhost ~]$ service bumblebeed start
Redirecting to /bin/systemctl start  bumblebeed.service                                                                                                                                      
[olivier@localhost ~]$ optirun glxspheres                                                                                                                                              
[  861.895701] [ERROR]The Bumblebee daemon has not been started yet or the socket path /var/run/bumblebee.socket was incorrect.                                                              
[  861.895726] [ERROR]Could not connect to bumblebee daemon - is it running?                                                                                                                 
[olivier@localhost ~]$   
Argh !

je lance un dnf update
[olivier@localhost ~]$ glxspheres
Polygons in scene: 62464 (61 spheres * 1024 polys/spheres)
libGL error: unable to load driver: swrast_dri.so
libGL error: failed to load driver: swrast
Visual ID of window: 0x1a4
X Error of failed request:  GLXBadContext
  Major opcode of failed request:  153 (GLX)
  Minor opcode of failed request:  6 (X_GLXIsDirect)
  Serial number of failed request:  38
  Current serial number in output stream:  37
[olivier@localhost ~]$ optirun glxspheres
Polygons in scene: 62464 (61 spheres * 1024 polys/spheres)
Visual ID of window: 0x21
Context is Direct
OpenGL Renderer: GeForce GTX 960M/PCIe/SSE2
274.884807 frames/sec - 306.771444 Mpixels/sec
293.353934 frames/sec - 327.382990 Mpixels/sec
293.579048 frames/sec - 327.634217 Mpixels/sec
294.019912 frames/sec - 328.126222 Mpixels/sec
291.986530 frames/sec - 325.856968 Mpixels/sec
[olivier@localhost ~]$ optirun -b none nvidia-settings -c :8
[olivier@localhost ~]$ bumblebeed -D
modprobe: FATAL: Module bbswitch not found in directory /lib/modules/4.4.2-301.fc23.x86_64
ca avance, toujours pas de second ecran activable ou detecté dans le nvidia settings.
[root@localhost olivier]# bumblebee-nvidia --check                                                                                      
                                                                                                                                         
                                                                                                                                           
nvidia.ko compiled into in the kernel tree ok.                                                                                              
modinfo output for NVIDIA:                                                                                                                   

filename:       /lib/modules/4.4.2-301.fc23.x86_64/kernel/drivers/video/nvidia.ko
alias:          char-major-195-*
version:        352.63
supported:      external
license:        NVIDIA
alias:          pci:v000010DEd00000E00sv*sd*bc04sc80i00*
alias:          pci:v000010DEd*sv*sd*bc03sc02i00*
alias:          pci:v000010DEd*sv*sd*bc03sc00i00*
depends:        drm
vermagic:       4.4.2-301.fc23.x86_64 SMP mod_unload 
parm:           NVreg_Mobile:int
parm:           NVreg_ResmanDebugLevel:int
parm:           NVreg_RmLogonRC:int
parm:           NVreg_ModifyDeviceFiles:int
parm:           NVreg_DeviceFileUID:int
parm:           NVreg_DeviceFileGID:int
parm:           NVreg_DeviceFileMode:int
parm:           NVreg_UpdateMemoryTypes:int
parm:           NVreg_InitializeSystemMemoryAllocations:int
parm:           NVreg_UsePageAttributeTable:int
parm:           NVreg_MapRegistersEarly:int
parm:           NVreg_RegisterForACPIEvents:int
parm:           NVreg_CheckPCIConfigSpace:int
parm:           NVreg_EnablePCIeGen3:int
parm:           NVreg_EnableMSI:int
parm:           NVreg_MemoryPoolSize:int
parm:           NVreg_RegistryDwords:charp
parm:           NVreg_RmMsg:charp
parm:           NVreg_AssignGpus:charp

Check bbswitch kernel module...

bbswitch is loaded into the current kernel ok.

All checks completed successfully! NVIDIA driver appears to have compiled ok.

Documentation on bumblebee for RHEL / CentOS / fedora can be found at:
https://www.linux.ncsu.edu/bumblebee/

[root@localhost olivier]# xrandr
xrandr: Failed to get size of gamma for output default
Screen 0: minimum 1920 x 1080, current 1920 x 1080, maximum 1920 x 1080
default connected primary 1920x1080+0+0 0mm x 0mm
   1920x1080      0.00* 
[root@localhost olivier]# 
je commence a etre perdu
j'ai suivi ca :

https://github.com/Bumblebee-Project/Bumblebee/wiki/Multi-monitor-setup

j'en suis a la creation du xorg.conf

au reboot avant le lancement de X, ecran noir avec le prompt qui clignote puis rien 🙁
X se lance avec la suppression de xorg.conf

voila mon Xorg.0.log.old
[    21.967] 
X.Org X Server 1.18.0
Release Date: 2015-11-09
[    21.967] X Protocol Version 11, Revision 0
[    21.967] Build Operating System:  4.2.5-300.fc23.x86_64 
[    21.967] Current Operating System: Linux localhost.localdomain 4.4.2-301.fc23.x86_64 #1 SMP Tue Feb 23 19:00:38 UTC 2016 x86_64
[    21.967] Kernel command line: BOOT_IMAGE=/boot/vmlinuz-4.4.2-301.fc23.x86_64 root=/dev/mapper/fedora-root ro rd.lvm.lv=fedora/root rd.lvm.lv=fedora/swap nomodeset nouveau.modeset=0 rd.driver.blacklist=nouveau rhgb quiet LANG=fr_FR.UTF-8
[    21.967] Build Date: 16 November 2015  10:08:25AM
[    21.967] Build ID: xorg-x11-server 1.18.0-2.fc23 
[    21.967] Current version of pixman: 0.34.0
[    21.967] 	Before reporting problems, check http://wiki.x.org
	to make sure that you have the latest version.
[    21.967] Markers: (--) probed, (**) from config file, (==) default setting,
	(++) from command line, (!!) notice, (II) informational,
	(WW) warning, (EE) error, (NI) not implemented, (??) unknown.
[    21.967] (==) Log file: "/var/log/Xorg.0.log", Time: Tue Mar  1 21:06:06 2016
[    21.968] (==) Using config file: "/etc/X11/xorg.conf"
[    21.968] (==) Using config directory: "/etc/X11/xorg.conf.d"
[    21.968] (==) Using system config directory "/usr/share/X11/xorg.conf.d"
[    21.968] (==) ServerLayout "Layout0"
[    21.968] (==) No screen section available. Using defaults.
[    21.968] (**) |-->Screen "Default Screen Section" (0)
[    21.968] (**) |   |-->Monitor "<default monitor>"
[    21.968] (==) No device specified for screen "Default Screen Section".
	Using the first device section listed.
[    21.968] (**) |   |-->Device "Device1"
[    21.968] (==) No monitor specified for screen "Default Screen Section".
	Using a default monitor configuration.
[    21.968] (==) Automatically adding devices
[    21.968] (==) Automatically enabling devices
[    21.968] (==) Automatically adding GPU devices
[    21.968] (==) Max clients allowed: 256, resource mask: 0x1fffff
[    21.968] (==) FontPath set to:
	catalogue:/etc/X11/fontpath.d,
	built-ins
[    21.968] (**) ModulePath set to "/usr/lib/nvidia/xorg/,/usr/lib/xorg/modules/"
[    21.968] (II) The server relies on udev to provide the list of input devices.
	If no devices become available, reconfigure udev or disable AutoAddDevices.
[    21.968] (II) Loader magic: 0x81cde0
[    21.968] (II) Module ABI versions:
[    21.968] 	X.Org ANSI C Emulation: 0.4
[    21.968] 	X.Org Video Driver: 20.0
[    21.968] 	X.Org XInput driver : 22.1
[    21.968] 	X.Org Server Extension : 9.0
[    21.968] (++) using VT number 1

[    21.968] (II) systemd-logind: logind integration requires -keeptty and -keeptty was not provided, disabling logind integration
[    21.969] (--) PCI:*(0:0:2:0) 8086:1612:1462:1139 rev 10, Mem @ 0xa1000000/16777216, 0xb0000000/268435456, I/O @ 0x00005000/64, BIOS @ 0x????????/131072
[    21.969] (--) PCI: (0:1:0:0) 10de:139b:1462:1139 rev 162, Mem @ 0xa2000000/16777216, 0xc0000000/268435456, 0xd0000000/33554432, I/O @ 0x00004000/128, BIOS @ 0x????????/524288
[    21.970] (II) LoadModule: "glx"
[    21.970] (WW) Warning, couldn't open module glx
[    21.970] (II) UnloadModule: "glx"
[    21.970] (II) Unloading glx
[    21.970] (EE) Failed to load module "glx" (module does not exist, 0)
[    21.970] (II) LoadModule: "nvidia"
[    21.970] (WW) Warning, couldn't open module nvidia
[    21.970] (II) UnloadModule: "nvidia"
[    21.970] (II) Unloading nvidia
[    21.970] (EE) Failed to load module "nvidia" (module does not exist, 0)
[    21.970] (EE) No drivers available.
[    21.970] (EE) 
Fatal server error:
[    21.970] (EE) no screens found(EE) 
[    21.970] (EE) 
Please consult the Fedora Project support 
	 at http://wiki.x.org
 for help. 
[    21.970] (EE) Please also check the log file at "/var/log/Xorg.0.log" for additional information.
[    21.970] (EE) 
La je suis perdu, coulé, sous le beton !

HELP !
[root@localhost olivier]# xrandr --output eDP1 --mode 1920×1080 --output HDMI --mode 1920×1080 --right-of eDP1
warning: output eDP1 not found; ignoring
warning: output HDMI not found; ignoring
00:02.0 VGA compatible controller: Intel Corporation Broadwell-U Integrated Graphics (rev 0a)
01:00.0 3D controller: NVIDIA Corporation GM107M [GeForce GTX 960M] (rev a2)
comment je fais pour connaitre les noms de 00:02.0 et de 01:00.0 ?
D'après le man xrandr dans cet exemple :
EXAMPLES
       Sets  an output called LVDS to its preferred mode, and on its right put
       an output called VGA to preferred mode of a screen which has been phys‐
       ically rotated clockwise:
              xrandr  --output  LVDS --auto --rotate normal --pos 0x0 --output
              VGA --auto --rotate left --right-of LVDS
Je remplacerais eDP1 par VGA et HDMI par 3D
Si seulement :
[root@localhost bumblebee]# xrandr --output VGA --mode 1920×1080 --output 3D --mode 1920×1080 --right-of eDP1
warning: output VGA not found; ignoring
warning: output 3D not found; ignoring
en faite c'est logique, xrandr detecte qu'une sortie:
[olivier@localhost ~]$ xrandr                                                                                                                
xrandr: Failed to get size of gamma for output default
Screen 0: minimum 1920 x 1080, current 1920 x 1080, maximum 1920 x 1080
default connected primary 1920x1080+0+0 0mm x 0mm
   1920x1080      0.00* 
[olivier@localhost ~]$
Que retourne la commande
xrandr --verbose
[root@localhost olivier]# xrandr --verbose
xrandr: Failed to get size of gamma for output default
Screen 0: minimum 1920 x 1080, current 1920 x 1080, maximum 1920 x 1080
default connected primary 1920x1080+0+0 (0x26f) normal (normal) 0mm x 0mm
        Identifier: 0x26e
        Timestamp:  19626
        Subpixel:   horizontal rgb
        Clones:    
        CRTC:       0
        CRTCs:      0
        Transform:  1.000000 0.000000 0.000000
                    0.000000 1.000000 0.000000
                    0.000000 0.000000 1.000000
                   filter: 
  1920x1080 (0x26f)  0.000MHz *current
        h: width  1920 start    0 end    0 total 1920 skew    0 clock   0.00KHz
        v: height 1080 start    0 end    0 total 1080           clock   0.00Hz
[root@localhost olivier]#
Là je ne sais plus.
Peut-être faut-il lancer xrandr avec bumblebee, mais je dis peut-être une bêtise.
Le mieux en général, c'est de faire :
> optirun bash
> ensemble
> de 
> commandes
> exit # Plus besoin de la carte dédiée 
Je rajouterai que souvent, pour pouvoir accéder au DisplayPort, on a effectivement besoin d'avoir la carte dédiée d'allumée, mais je ne pense pas avoir réussi à le faire via optimus
J'ai installé les Latest Long Lived Branch version: 361.28 de nvidia
Ca demarre en mode clone suivi de X en mode etendu en ecran noir
Au demarrage, en enlevant nomodeset et nouveau, toujours mode etendu, ecran noir avec souris
Tout en haut a gauche avec la souris apparait un ptit bout de bleu et si je reste dessus j'ai la bulle info de hplip !
Je clique dessus et j'ai la fenetre qui s'ouvre de hplip
La resolution du bureau etendu et des ecrans doivent être décalé...
Bonsoir
Bon la j'avoue désespérer
J'ai compris que les pilotes nvidia force l'activation de la carte nvidia, que bumblebee et switch permettent la bascule entre l'intel et la nvidia
L'économie de batterie je m'en fiche, je suis sur secteur
Donc j'essai l'install des pilotes nvidia
Le NVIDIAxxxxx.run me donne un bel ecran noir
Le akmod-nvidia idem

J'aimerai deja installer les derniers pilotes nvidia :
Nouvelle install f23, update, akmod-nvidia donne un ecran noir
En init 3 akmods --force change rien
Xorg :1 -configure puis copie dans /etc/x11, idem ecran noir

Une idée ?
Edouard_le_homard wrote:je suis assez certain que les cartes optimus ne tournent pas avec les drivers akmod-nvidia
Tu peux même en être sur, les drivers nvidia ne fonctionnent pas avec Optimus, il faut obligatoirement bumblebee.