I know how to modify xorg.conf and get it to start at about 1024x768, but I can't get it to start at 1600x1200. It is quite an inconvenience to have to go and manually start them up each time. We are using these servers as automation agents. We are browser testing using sikuli so we can't go headless.
-
This answer may help you. – Takkat Aug 16 '11 at 09:02
-
@Takkat, this works if ubuntu started with the monitor plugged in. However, if I do those steps after starting without the monitor plugged in, then I just get 1024x768. – Unnamed Aug 17 '11 at 16:45
1 Answers
By default, X will use DDC to probe the monitor for its supported resolutions. If the monitor is not plugged in, then this will not be possible. If you know the characteristics of the monitor, you can program in additional modes through the xorg.conf
file.
If you haven't already, add a Monitor
section. This can be hooked in in one of two ways: either a Monitor "$IDENTIFIER"
directive in the Screen
section (the old way), or a Option "monitor-$OUTPUT" "$IDENTIFIER"
directive in the Device
section (the new multi-head aware way). If you use the second method, it uses the same output names as the xrandr
utility.
In the Monitor
section, add one or more ModeLine
directives for each of the modes you want to program. According to the man page, the format is as follows:
ModeLine "name" clock hdisp hsyncstart hsyncend htotal vdisp vsyncstart vsyncend vtotal options
If the monitor is plugged in, you should be able to get this information from the xrandr --verbose
command. For instance, if it shows the following:
1920x1080 (0x59) 148.5MHz +HSync +VSync *current +preferred
h: width 1920 start 2008 end 2052 total 2200 skew 0 clock 67.5KHz
v: height 1080 start 1084 end 1089 total 1125 clock 60.0Hz
Then the corresponding ModeLine
would be:
ModeLine "1920x1080" 148.5 1920 2008 2052 2200 1080 1084 1089 1125 +HSync +VSync
You should then be able to configure that mode even though the monitor is not initially connected.

- 41,136
-
-
Ok. I tried this configuration. http://pastie.org/2383128 And it didn't work. I got the modeline from gtf and everything. What is wrong? – Unnamed Aug 16 '11 at 23:16
-
You need to link reference the monitor section in the screen section with
Monitor "Monitor1"
. – James Henstridge Aug 17 '11 at 00:02 -
@James Henstridge, So what you are saying is that this pastie.org/2383128 should work then? – Unnamed Aug 17 '11 at 15:47