Red Hat Bugzilla – Bug 44078
Changes to /etc/sysconfig/desktop not effective
Last modified: 2007-04-18 12:33:38 EDT
Description of Problem:
The /etc/sysconfig/desktop file that is configured during a RedHat install where Gnome is the chosen as the desktop will contain the string 'GNOME'. This results in 'gdm' being chosen as the login/display manager progem. However, changing the contents of this file to 'KDE' or 'KDE2' still result in 'gdm' being launched as the login/display manager.
Steps to Reproduce:
1. Edit the file /etc/sysconfig/desktop to contain only the text 'KDE'.
2. As root, kill -TERM the parent gdm process, causing init to restart X.
Once init has restarted X, you will still see the Gnome login window.
The user should see the KDE login window instead.
When you run /etc/X11/prefdm in shell debug mode, you will see that even when /etc/sysconfig/desktop contains 'GNOME', it actually launches GNOME becuase it is the fallback login manager, not becuase it was specified.
The only way to force /etc/X11/prefdm to honor your choice of login manager, you have to put 'DISPLAYMANAGER=KDE2' or 'DISPLAYMANAGER=GNOME' into /etc/X11/desktop.
Here is a transcript of a run of prefdm with extra echo's from me. When this was executed the /etc/X11/dekstop file contained 'KDE2':
+ '[' -f /etc/sysconfig/desktop ']'
+ echo 'found /etc/sysconfig/desktop'
+ source /etc/sysconfig/desktop
+ '[' -n '' ']'
+ echo 'desktop: '
+ '[' '' = GNOME ']'
+ '[' '' = KDE -o '' = KDE1 -o '' = KDE2 ']'
+ '[' '' = AnotherLevel ']'
+ '[' -z '' ']'
+ which gdm
+ echo 'pref2 is gdm'
pref2 is gdm
+ '[' -n gdm ']'
+ which gdm
++ which gdm
+ exec /usr/bin/gdm
Use switchdesk to change the desktop. By the way, this has nothing to do
with the XFree86 package.
No, this dosen't solve the problem, switchedesk doesn't put the right value
in /etc/sysconfig/desktop, redhat needs to adress this very annoying bug
Well, it makes the most sense to file the bug against switchdesk then.
Switchdesk is not part of XFree86. Reassigning to switchdesk component.
Bero, no idea if this is a valid bug or not, so I'm reassigning
it to you to decide.
Just putting the string KDE into /etc/sysconfig/desktop isn't enough.
You have to use the following syntax:
Otherwise you'll always get the fallback (gdm)