Comment 1 for bug 1716857

Revision history for this message
Tim Richardson (tim-richardson) wrote : Re: gdm3, hybrid nvidia with modeset=1, no external monitors detected

ubuntu user Hon Weng Chong has emailed me as he continues to investigate the problem.
He believes he has proof that it is is GDM configuration issue and has provided the following fix

Hey Tim,

I figured out a hack solution to the GDM prime issue. If you replace /lib/systemd/system/gdm3.service with this file:

https://gist.github.com/hwchong/b3634b387e91b38d355a0500ffecfc7d

and /etc/X11/xorg.conf with this:

https://gist.github.com/hwchong/28d7c70aafd62a0d3114c5746da7da36

You should be able to use Prime Sync with your Intel graphics card and have an external monitor connected to the Nvidia GPU without using LightDM.

Cheers,
Hon

His proposed changes to xorg are probably not significant. He is proposing to add this to nvidia options, but this can be done via the GUI or command line.

    Option "metamodes" "nvidia-auto-select +0+0 {ForceCompositionPipeline=On, ForceFullCompositionPipeline=On}"

The revised /lib/systemd/system/gdm3.service he proposes is
is
--> Compared to Fedora 27's config, changes seem to be the addition of
ExecStartPre=/usr/bin/xinit /usr/share/gdm/generate-config
.
.
.
RestartSec=1s
ExecReload=/usr/share/gdm/generate-config

[Unit]
Description=GNOME Display Manager

# replaces the getty
<email address hidden>
<email address hidden>

# replaces plymouth-quit since it quits plymouth on its own
Conflicts=plymouth-quit.service
After=plymouth-quit.service

# Needs all the dependencies of the services it's replacing
# pulled from getty@.service and plymouth-quit.service
# (except for plymouth-quit-wait.service since it waits until
# plymouth is quit, which we do)
After=rc-local.service plymouth-start.service systemd-user-sessions.service

# GDM takes responsibility for stopping plymouth, so if it fails
# for any reason, make sure plymouth still stops
OnFailure=plymouth-quit.service

[Service]
ExecStartPre=/usr/bin/xinit /usr/share/gdm/generate-config
ExecStart=/usr/sbin/gdm3
KillMode=mixed
Restart=always
RestartSec=1s
IgnoreSIGPIPE=no
BusName=org.gnome.DisplayManager
StandardOutput=syslog
StandardError=inherit
EnvironmentFile=-/etc/default/locale
ExecReload=/usr/share/gdm/generate-config
ExecReload=/bin/kill -SIGHUP $MAINPID