xorg fails to start due to "bad fd number"

Bug #340676 reported by Martin Olsson
2
Affects Status Importance Assigned to Milestone
xorg (Ubuntu)
Fix Released
Undecided
Unassigned

Bug Description

X.org shows a message saying that the X.org session lasted less than 10 seconds. In detail this error is shown:
/etc/X11/Xsession.d/60x11-localhost: 4: Syntax error: Bad fd number

On my system this file looks like:
      # This file is sourced by Xsession(5), not executed.
      [ -x /usr/bin/xhost ] && [ -x /usr/bin/id ] &&
          xhost +si:localuser:`id -un` >& /dev/null

I think this is a plain typo and that they mean &> (i.e. redirect both stdout and stderr) instead of >& which makes bash choke.

The strange thing is that this comes from upstream:
http://cvs.fedoraproject.org/viewvc/rpms/xorg-x11-xinit/devel/localuser.sh?revision=1.2&view=markup

Revision history for this message
Bryce Harrington (bryce) wrote :

Changed it to >. Update to 5u15 and verify fix plz.

Changed in xorg:
status: New → Fix Released
Revision history for this message
Martin Olsson (mnemo) wrote :

After "sudo apt-get update" I do see 5u15, however, even after running "sudo apt-get install --reinstall x11-common", "sudo aptitude reinstall x11-common" and "sudo dpkg-reconfigure -phigh x11-common" that didn't fix it for me (config file doesn't get updated?). I'm guess that I'm just doing it the wrong way? If I do "apt-get source x11-common" then I see the bugfix inside ~/src/x11-common_apt/xorg-7.4~5ubuntu15/debian/local/Xsession.d/60x11-localhost" but I don't see that fix making it into the real copy of the config file in etc?

If I change it manually to say:

    xhost +si:localuser:`id -un` > /dev/null

Then it works fine.

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.