0

I have an Intel G33/G31 Express Chip in my Foxconn desktop computer. The Ubuntu does not detect my analogic monitor Samsung SB19B300B.

This monitor has 1366 x 768 max resolution.

In the System setting Display, Ubuntu only shows me the options 1024 x 768 (4:3) and 800 x 600 (4:3) for resolution and shows me "Unknown display" but DOES NOT show me 16:9 relations for 1366 x 768 resolution (60 Hz).

I ran the recommendations of How to set a custom resolution?

cvt 1366 768 60 
xrandr --newmode "1368x768_60.00" 85.25 1368 1440 1576 1784 768 771 781 798 -hsync + vsync 
xrandr --addmode VGA1 1368x768_60.00 
xrandr -s 1368x768 

I make one string with the last 3 command (xrandr) and I set it as executable and I add it in the "applications at startup" But I do not think it's good because the start takes more time and works like OS windows performance! Then How can I fix these changes in the installation configuration?

1 Answers1

0

Some of your commands are a little old or unnecessary. Here's a slightly updated version (note that I'm using the name 'custom' to illustrate that the mode name can be anything you want). Save it to a bash script:

#!/usr/bin/env bash
cvt 1366 768
xrandr --newmode "custom" 85.25 1368 1440 1576 1784 768 771 781 798 -hsync +vsync
xrandr --addmode VGA1 custom
xrandr --output VGA1 --mode custom

As for it being slow, it could be due to something trying to load early, xrandr scripts can cause problems if that happens.

Make sure your bash script is at least executable. No harm in making it readable by everyone too, so chmod 755 on the script file.

Bear in mind you may need to access the terminal in recovery mode to undo your changes/comment out problematic lines if anything goes wrong.

Using Startup Applications:

Add your script to Startup Applications the same way you added your concatenated commands. If the above script doesn't solve your problem try adding sleep 10 just below #!/bin/bash.

The higher the sleep value the more guarantee you have that xrandr won't start early, but it may delay your monitors appearing properly - play around with the time so you get it how you want it.

Using LightDM (Edit - this may not work in 16.x due to Unity jumping in and resetting changes made in your script):

There should also be a way to get execute the script using system hooks in LightDM config files; this is probably the 'proper' way of doing things these days.

Go to /usr/share/lightdm/lightdm.conf.d and create a file called monitors.conf.

In there add a seat heading then one or all of the following commands:

[Seat:*]
display-setup-script=/path/to/your/script
greeter-setup-script=/path/to/your/script
session-setup-script=/path/to/your/script

Play around to try and get your desired behaviour. For me, most of the script runs as it's supposed, but the xrandr --output commands don't work. Not sure if it's my setup or they're being fired at the wrong time, from some other posts I've seen it works just fine for other people.

I'll carry on investigating and update if I find a clearer answer.

Having said all that though, Linux Display Managers just aren't that great - startup time can be slow, and performance will probably be worse than Windows.

Bathmat
  • 171
  • the file that must be created is monitor.conf or 50-monitors.conf (all files in this subdirectory begin with "50-" prefix – joscastel Dec 19 '16 at 20:20