Server Fault is a question and answer site for system and network administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

With recent versions of Ubuntu, there's no /etc/X11/xorg.conf file being shipped anymore. That's good as long as you don't have a Nvidia graphics cards and you want to use multiple screens, in which case you have to allow normal users to write to /etc/X11/xorg.conf.

Now, given that Ubuntu doesn't ship a default /etc/X11/xorg.conf file, I can't chmod 666 it (no file to change permissions on).

If I try to ship a default xorg.conf file with puppet (and set the permissions accordingly so that normal user can overwrite that file), puppet will keep overwriting this file in case it changes from the shipped default.

So what are my options here?

  1. Is there a way to ship a default file with puppet but tell puppet to not overwrite customized versions of that file?
  2. Is there a way to tell the xorg-x11 package to create a default xorg.conf file?
  3. Polkit?

any other options that I'm not aware of?

share|improve this question
Why are you trying to overwrite this file at all? – Michael Hampton Feb 26 '13 at 8:10
@MichaelHampton by default there's no file, which works fine with one monitor setups. But once you have multiple monitors, you need to write the config into the xorg.conf file. Users can't write into that file if it doesn't exist. – memyself Feb 26 '13 at 12:20
up vote 2 down vote accepted

I found a solution that works with puppet: in the file section, you need to include replace => "no". By default puppet will ship the right xorg.conf file, but once a user modifies it, the modification won't be overwritten.

    file { "$name":
            replace => "no",
            mode => 666,
            owner => root,
            group => root,
            ensure => present,
share|improve this answer

NVidia provide a tool for users to configure their screen (resolution, dual-screen, etc.). You just need to deploy this application and give the user proper rights to execute it.

So you should configure /etc/sudoers so that your users can do:

sudo nvidia-xconfig
share|improve this answer
I'm aware of that option, but the average users configures the computer with the nvidia-settings program. The nvidia-xconfig program just provides a skeleton, but once the user wants to configure multiple screens, you use nvidia-settings. – memyself Feb 26 '13 at 12:18
Would not that be sufficient for option? – Huygens Feb 26 '13 at 14:11

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.