Ubuntu Dual Monitors

Screenshot-NVIDIA X Server SettingsSetting up dual monitors in Ubuntu (Karmic) has been easy for quite awhile especially if you are using an Nvidia chipset.  Using the nvidia-settings application allowed me to configure everything I needed.  The problem was when I tried to save the configuration so it would persist when I rebooted.  The utility said that it could not parse the existing xorg.conf configuration file.

There are two solutions to this problem.  I found both in the comments section of a bug report describing the problem.  The first option is to add the following to the “screen” section of the /etc/X11/xorg.conf file.

Device         "Default Device"

This still gave me a few problems related to saving a backup configuration file before writing over the existing one, so I then used the next suggestion and ran the configuration tool with administrative privileges with the command:

gksudo nvidia-settings

Then it had full access to modify the configuration file.  Now when Ubuntu starts up, the screen positions and sizes are maintained.