Wednesday 27 January 2010

Ubuntu 9.10 display resolution problem

1,5 years ago I switched from a Windows laptop to a MacBook Pro and haven't really looked back since, ... except at home I still have a water cooled desktop PC that's about 7 years old and still runs Windows XP and I absolutely loathe that operating system. In my honest opinion Windows 2000 Professional was the best OS Microsoft ever made. My desktop PC ran on it for 4 years without the dreaded BSOD and within a week of installing XP it started presenting me all too frequently with them.

Since I wasn't really using the PC that much I tolerated this for some time, but two weeks ago 2 of the 3 hard drives in it failed and while repairing it I decided to install Ubuntu 9.10 which completed my goal of getting rid of Windows. The installation of Ubuntu went pretty painless and quick, with just one hitch: I couldn't configure a higher screen resolution than 800x600. That really sucks ass, especially on a 19inch CRT.

Installing the hardware drivers didn't really solve the problem, in fact it only made it worse, because afterwards I could only select 640x480 as the highest resolution. After reverting to the previous settings I started farting around with the xorg.conf file, but it turned out that that wasn't really my forté as I fucked up the configuration in such a way that in the end I just got a black screen.

You'd think that after all these years a desktop linux distro such as Ubuntu would get configuring your screen resolution as good/user friendly/easy as it is in Windows! So I pretended I wanted to be a millionaire and phoned a friend. He came over and also messed around a bit with the xorg.conf, but also couldn't get a better resolution. What we did discover however was that Ubuntu recognized my ancient Geforce2 M X400 without a problem, but not my CRT. It's some cheap piece of crap from some long-defunct Taiwanese manufacturer and that doesn't help autodiscovering settings one bit.

So I almost gave up, but decided to Google one last time and found a forum post with a possible solution: download a different linux live cd, check if that one provides better resolutions and if it does find the xorg.conf and copy the contents of that one into Ubuntu. I tried several, Knoppix, Linux Mint and CentOS, and with the last one I hit pay dirt! In CentOS I was able to change my monitor and resolution to a significantly better one by using some menu's in System > Preferences and System > Administration.

So I emailed myself the file /etc/X11/xorg.conf from within the livecd, rebooted back into Ubuntu, got the file from my email, put it in the correct location and a log off/log on later I had the resolution I wanted.


And so others won't have to go through the same troubles, I present to you the xorg.conf I got:


# Xorg configuration created by system-config-display

Section "ServerLayout"
Identifier "single head configuration"
Screen 0 "Screen0" 0 0
InputDevice "Keyboard0" "CoreKeyboard"
EndSection

Section "InputDevice"
Identifier "Keyboard0"
Driver "kbd"
Option "XkbModel" "pc105"
Option "XkbLayout" "us"
EndSection

Section "Monitor"

### Comment all HorizSync and VertSync values to use DDC:
Identifier "Monitor0"
ModelName "Monitor 1024x768"
### Comment all HorizSync and VertSync values to use DDC:
HorizSync 31.5 - 61.0
VertRefresh 50.0 - 75.0
Option "dpms"
EndSection

Section "Device"
Identifier "Videocard0"
Driver "nv"
EndSection

Section "Screen"
Identifier "Screen0"
Device "Videocard0"
Monitor "Monitor0"
DefaultDepth 24
SubSection "Display"
Viewport 0 0
Depth 24
Modes "1280x800" "1152x864" "1152x768" "1024x768" "800x600" "640x480"
EndSubSection
EndSection

No comments:

Post a Comment