2

I just installed Ubuntu. I am new to Linux, so I will need this explained in pretty basic terms please. I have two monitors. I use a AMD R7 2xx graphics card. I haven't installed the AMD drivers but don't know if I need to or not. In terminal I used the command xrandr --addmode DVI-0 1600x900 to add that resolution to my second monitor. It works fine until I restart the computer. I read something about needing to change a xorg file in /etc/X11, but that directory doesn't exist on my computer. Not sure what to do.

Andrew
  • 165
  • 1
  • 3
  • 7
  • You either have to set and save your settings with a graphical tool or run xrandr at login. http://blog.bodhizazen.net/linux/use-xrandr-to-set-a-screen-resolution/ – Panther Jun 07 '15 at 17:14
  • @bodhi.zazen fancy ! you even got a blog :) – Sergiy Kolodyazhnyy Jun 07 '15 at 17:17
  • possible duplicate of [How can I make xrandr customization permanent?](http://askubuntu.com/questions/63681/how-can-i-make-xrandr-customization-permanent) – Pilot6 Jun 07 '15 at 17:32

2 Answers2

2

You can add

display-setup-script=<your_xrandr_command>

to /etc/lightdm/lightdm.conf in [seat defaults] section.

This will ensure it starts before you login into the system.

It also can be done in xorg.conf file, or better in a new file in

/usr/share/X11/xorg.conf.d/<50-some_name.conf>

Pilot6
  • 88,764
  • 91
  • 205
  • 313
0

Personally, I'd add your command xrandr --addmode DVI-0 1600x900 to list of Startup Applications, or create a .desktop file in ~/.config/autostart , so that the command runs on every login.

Sergiy Kolodyazhnyy
  • 103,293
  • 19
  • 273
  • 492
  • Note that the command might (and probably will) break if it runs before the desktop is fully loaded. Especially if a second monitor is attached. – Jacob Vlijm Jun 07 '15 at 17:17
  • I would, but would that mean I would still get the error window each time I log on. It says: "Could not apply the stored configuration for monitors. Then it says below that could not assign CRTCs to outputs: and a really long list. – Andrew Jun 07 '15 at 17:17
  • @JacobVlijm never had this issue, I've a `.desktop ` file which configures my dual screen with 15.04. – Sergiy Kolodyazhnyy Jun 07 '15 at 17:19
  • I assure you, in many cases it does, as a result of `xrandr` to break in that case. – Jacob Vlijm Jun 07 '15 at 17:20
  • It worked, however, I am still getting this annoying error message when I reboot. It is a long list of CRTC errors. It doesn't seem to affect anything, but it is rather annoying – Andrew Jun 07 '15 at 17:24
  • Try lightdm.conf too. – Pilot6 Jun 07 '15 at 17:27
  • @Andrew can't help you with that error, but when you login , try running in terminal xprop and clicking on that error popup or whatever. At least it will tell you what program runs it – Sergiy Kolodyazhnyy Jun 07 '15 at 17:30