$HOME/.Xdefaults no longer being read

Bug #320886 reported by GiuseppeVerde
14
This bug affects 2 people
Affects Status Importance Assigned to Milestone
xinit (Ubuntu)
Invalid
Low
Unassigned

Bug Description

Sometime in the last day, the $HOME/.Xdefaults file stopped being read on login. I'm not certain if this is a bug in GNOME or the X session scripts, but it is there. Sadly, this makes emacs have giamahugical fonts until I xrdb ~/.Xdefaults. It also results in other things (e.g. the memscanner screensaver not getting pointed to the right file).

Tags: jaunty
Revision history for this message
Niall Creech (sevenmachines-deactivatedaccount) wrote :

i think its maybe $HOME/.Xdefaults-hostname now, give that a try and see http://www.xfree86.org/current/X.7.html

Revision history for this message
Niall Creech (sevenmachines-deactivatedaccount) wrote :

i'm sure you know already but hostname in the above filename is the name of your actual host and not just the text 'hostname', bad writing on my part there :)

Revision history for this message
GiuseppeVerde (launchpad-digitasaru) wrote :

Interesting. I wasn't aware of that change. I humbly submit that this sucks. It arbitrarily breaks a working system and will be a rude surprise for those who weren't expecting it.

Unfortunately, I have a dissertation to write intead of patch the X server code responsible for this misbheavior, but I think the following algorithms would be significantly better for transition and perhaps in general. I understand why the -hostname dependent behavior was wanted, but it lacks a bit of flourish yet.

Algorithm 1:
1) If $HOME/.Xdefaults-hostname exists, read it in.
2) Else, if $HOmE/.Xdefaults exists, read it in.

This won't break backwards compatibility and has an added feature: if you migrate your Xdefaults to a new host or whatever, a "default" Xdefaults file will be available..

Alrigthm 2:
1) If $HOME/.Xdefaults exists, read it in.
2) If $HOME/.Xdefaults-hostname exists, read it in and override any conflicts with $HOME/.Xdefaults.

This has all of the advantages of algo 1 but now even allows you to set up a generic Xdefaults file with per-box customizations in the -hostname file.

Personally, I'm a fan of Algo 2 and would recommend someone implement it before Jaunty goes stable, or both of us users of this feature will be upset. ;)

Revision history for this message
Niall Creech (sevenmachines-deactivatedaccount) wrote :

your probably right with the back compatibility. i'm not sure whether this is an xorg problem or application specific (see https://bugs.launchpad.net/ubuntu/+source/rxvt/+bug/46462). if .Xdefaults is completely ignored it should probably be filed against xorg. if its only happening with respect to specific applications this should probably be moved to those specific packages.

Revision history for this message
Niall Creech (sevenmachines-deactivatedaccount) wrote :

it seems that .Xdefaults should still be read followed by .Xdefaults-HOSTNAME, though .Xdefaults may be ignored if your running remotely? in which case .Xdefaults-HOSTNAME should be merged into the resources

Revision history for this message
Timo Aaltonen (tjaalton) wrote :

What ubuntu version is this? And what display manager are you running? No X package sources ~/.Xdefaults, so this is likely misfiled.

Changed in xorg:
status: New → Incomplete
Revision history for this message
Fabien Tassin (fta) wrote :

I confirm the bug as it's happening for me too. Strangely, i see this on some computers, but not all, all running Jaunty.
Re-assiging to xorg.

Bryce Harrington (bryce)
Changed in xorg:
status: Confirmed → Triaged
Revision history for this message
Gerald Jansen (jansengb) wrote :

I upgraded two machines from 8.10 to 9.04, one yesterday that did not have this problem and one today that did. Cost me 2 hours to find this bug and the solution. Should be listed among the upgrade issues.

Revision history for this message
Martin Shepherd (mcs-astro) wrote :

Note that an alternative to renaming the file is to add the following to your .bashrc file:

export XENVIRONMENT=~/.Xdefaults

Revision history for this message
Antti Kaihola (akaihola) wrote :

I'm seeing this on a fresh Ubuntu Jaunty 9.04 i386 install as well as on an Ubuntu Netbook Remix 9.04 i386 fresh install.

Revision history for this message
Artships (ubuntubugs-johndouglass-deactivatedaccount) wrote :

An alternative to setting XENVIRONMENT is executing:

xrdb -merge .Xdefaults

Bryce Harrington (bryce)
tags: added: jaunty
Revision history for this message
Fabien Tassin (fta) wrote :

this bug re-appeared for me a few days ago in karmic. I see it now in a 64bit desktop, and in UNR.
Strangely, my 32bit desktop is fine. They all have the same ~/.Xdefaults.

Revision history for this message
Fabien Tassin (fta) wrote :

mv ~/.Xdefaults ~/.Xresources

works for me.

It happens it's not a bug.

man Xsession:

       $HOME/.Xresources
              contains X resources specific to the invoking user's environment. The
              settings are loaded with xrdb -merge. Note that $HOME/.Xdefaults is a
              relic from X Version 10 (and X11R1) days, before app-defaults files
              were implemented. It has been deprecated for over ten years at the
              time of this writing. .Xresources should be used instead.

Changed in xinit (Ubuntu):
status: Triaged → Invalid
summary: - [Jaunty] $HOME/.Xdefaults no longer being read
+ $HOME/.Xdefaults no longer being read
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.