After struggling with Natty’s multiple monitor support last week, I thought I’d test my luck again and try rotating screens. My current favorite monitor is the Dell P2411H, a sturdy little 24" monitor that has more degrees of freedom than you’d imagine possible. One of these degrees is the monitor’s ability to rotate 90 degrees, letting me comfortably fit over 130 lines of code vertically on the screen. Less scrolling, more coding!
Since I’m writing a post about this, you might have guessed that something didn’t work. If you guessed that Natty completely broke xrandr rotation, well, you are unfortunately correct. Luckily, all was not lost. Here’s the fix (which will blast any other settings you have):
- Make sure you’re not using compiz/Unity! As I mentioned last week, make sure that your current session is Ubuntu Classic (no effects), and, even better, change your default session under Administration->Login Window.
- OK, now start by moving your old xorg.conf out of the way from console: $ sudo mv /etc/X11/xorg.conf /etc/X11/xorg.conf.1
- Next up, run the nvidia-settings wizard: $ sudo nvidia-settings
- Under X Server Display Configuration, set up each of your monitors as a separate X screen.
- Check the Xinerama box.
- Save the X configuration file with the button in the lower right.
- I’m going to assume you can figure this out. If not, there’s plenty of discussion on the Ubuntu forums about using nvidia-settings.
- Now open your xorg.conf in a text editor, e.g.: $ sudo gedit /etc/X11/xorg.conf
- Find the monitor that you’d like rotated, probably by looking for the ModelName field under Monitor section. Note the Monitor’s Identifier, e.g., Monitor0.
- Find the screen that corresponds to this Monitor. In general, nvidia-settings will match the numbers up, so Monitor0 will be controlled by Screen0.
- Add the following two options under the proper Screen section:
- Option "RandRRotation" "on"
- Option "Rotate" "CCW"
- Save the file!
- Log out and log back in.
You should now be set! Good luck.
Leave A Comment