Bug 44078

Summary: Changes to /etc/sysconfig/desktop not effective
Product: [Retired] Red Hat Linux Reporter: jason buberel <jason>
Component: switchdeskAssignee: Bernhard Rosenkraenzer <bero>
Status: CLOSED NOTABUG QA Contact: David Lawrence <dkl>
Severity: medium Docs Contact:
Priority: medium    
Version: 7.1   
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2001-11-04 02:26:46 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description jason buberel 2001-06-11 01:55:19 UTC
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.

How Reproducible:
Always

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.

Actual Results:
Once init has restarted X, you will still see the Gnome login window.

Expected Results:
The user should see the KDE login window instead.

Additional Information:
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'
found /etc/sysconfig/desktop                  
+ source /etc/sysconfig/desktop                        
+ '[' -n '' ']'  
+ echo 'desktop: '
desktop:                                                         
+ echo                                                       
+ '[' '' = GNOME ']'                                     
+ '[' '' = KDE -o '' = KDE1 -o '' = KDE2 ']'                    
+ '[' '' = AnotherLevel ']'                                         
+ '[' -z '' ']'                                      
+ which gdm                                                    
+ preferred=gdm                                            
+ echo 'pref2 is gdm'                                      
pref2 is gdm                                                     
+ '[' -n gdm ']'                                            
+ which gdm  
++ which gdm                                            
+ exec /usr/bin/gdm

Comment 1 Mike A. Harris 2001-06-16 08:18:52 UTC
Use switchdesk to change the desktop.  By the way, this has nothing to do
with the XFree86 package.

Comment 2 Khalid 2001-11-03 23:18:50 UTC
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

Comment 3 Mike A. Harris 2001-11-04 02:25:54 UTC
Well, it makes the most sense to file the bug against switchdesk then.
;o)
Switchdesk is not part of XFree86.  Reassigning to switchdesk component.

Comment 4 Mike A. Harris 2001-11-04 02:26:40 UTC
Bero, no idea if this is a valid bug or not, so I'm reassigning
it to you to decide.

Comment 5 Karsten Hopp 2002-08-06 13:06:44 UTC
Just putting the string KDE into /etc/sysconfig/desktop isn't enough. 
You have to use the following syntax: 
 
DESKTOP="KDE" 
 
Otherwise you'll always get the fallback (gdm)