Screen resolution got all funky? Try dpkg-reconfigure xserver-xorg

Posted in Technology
Tue, Jan 22 - 8:12 am EDT | 7 years ago by
Comments: 5
Share This Post:
  • Facebook
  • StumbleUpon
  • Tumblr
  • Reddit
  • Twitter

Have you experienced booting up your laptop and your screen resolution sucks? It has happened to me several times over. Not just my laptop but the desktop machines in the office as well. There are times when it’s easy to fix via the admin menu on the panel but it’s not the case all the time. Sometimes, when it’s so bad already, I don’t even get anything graphical. I get stuck on the command line. Because it has happened to me more than once, I remembered how to use dpkg-reconfigure xserver-xorg. I could edit xorg.conf but I was afraid I’d botch it up so I opted to remember the command dpkg-reconfigure xserver-xorg instead.

The pre-requisites:

  • You want to edit the screen resolution for some reason or another.
  • You have sudo rights or you are root. Doing things as root or super user would mean that you could actually end up doing the wrong thing and it would be quite tough to undo it. When you execute it via sudo, you’re acting like the super user.
  • You are using Ubuntu, Debian, and such distros. (Sorry, Red Hat, etc. users. I am really not very familiar with your package managers.)

Now what?
When you’re thinking about changing the resolution, you could run Gnome-terminal or press CTRL-F1 to get a terminal. Then log in as root then run the command dpkg-reconfigure xserver-xorg. Or if you don’t want to log in as root, then you could sudo dpkg-reconfigure xserver-xorg.

What happens next is that you will see a bunch of options. You need to indicate stuff like the graphics driver, the keyboard layout, screen resolution, etc. More often than not, you just have to mark them and you would have guides on marking them, depending on which ‘page’ of it you are on already. After that you will have to log off then log on again. Usually, you’d get the desired resolution after that but there are times when you have to do it again. I am not quite sure why though.

In any case, dpkg-reconfigure doesn’t only work for fixing xserver-xorg. It also does that for the other apps. Debian made that in order to help the users not remember too many quirks for config files. After all, you’d probably forget anyway. Or maybe you won’t but it might take some time to remember all the details. If you want to know more about dpkg-reconfigure, an article pointing out the differences between Debian and Red Hat might be a good read. (Actual page link is here. I gave the link of the cached article in Google because the site was down.)

I hope that helps!:)

Related Posts

Share This Post:
  • Facebook
  • StumbleUpon
  • Tumblr
  • Reddit
  • Twitter
  • Kristen

    Grrrr….
    Is that a site!?!?
    I mean sudo dpkg-reconfigure -phigh xserver-xorg
    ?????????????????????????????????????????????
    I need to know so I can fix my iPod…?? Thanks=]

  • Clair

    Hi, Kristen! sudo dpkg-reconfigure-phigh xserver-xorg is not a website.

    It’s a command so that there would be a way to fix the screen resolution of your computer.

  • Jivabill

    Tried this. I gave me a screen in the Terminal that looked like MS Dos screens. And all it would let me do is configure the keyboard. Nothing more. Checked all the options and things at the top menu bar. Nada.
    so it did not help. Thanks anyway.

  • Jonathan

    I have tried that and another. But all I get is a xorg.conf that just has categories with nothing in them.

    sudo dpkg-reconfigure-phigh xserver-xorg

    sudo dpkg-reconfigure-phigh -phigh xserver-xorg

    I found the command somewhere that actually filled in the info the way it was supposed to but it had placed the file in the wrong place or I ran the command in the wrong folder. Either way…

    At this time, I am searching the net for the right command. I moved from 8 to 9 and my xserver died on me. I have to find the correct command to configure my monitor for xserver.

    Any help would be appreciated.

    Jonathan

  • Chris

    Hey Jonathan, you have to pay attention to the spacing. There is a space between “dpkg-reconfigure” and “-phigh” and another between “xserver-xorg” Try that.

    My issue is that I enter this command and I go through the options but it only asks me ONE graphic question (yes or no) then proceeds to the keyboard questions and never gives me the option to adjust screen resolution! I am using Jaunty. Anyone help?