Announcement

Collapse
No announcement yet.

Extact resolution at startup

Collapse
This topic is closed.
X
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Extact resolution at startup

    Hello everyone, I'm an Italian user who uses Kubuntu 9.10 (sorry if my English is bad).

    This is my motherboard.
    From bash:
    lspci |grep VGA
    01:00.0 VGA compatible controller: VIA Technologies, Inc. P4M890 [S3 UniChrome Pro] (rev 02)
    Unfortunately, there are no drivers for my integrated video card.
    I've already searched on VIA driver site, but there are no drivers for me.

    So, from bash, "sudo lshw -c display | grep driver" shows me nothing.

    However, I have some usable resolution.
    From bash:
    xrandr
    Screen 0: minimum 640 x 480, current 1024 x 768, maximum 1280 x 1024
    default connected 1024x768+0+0 0mm x 0mm
    1280x1024 0.0
    1024x768 0.0*
    800x600 0.0
    640x480 0.0
    On windows I always use 1024 x768 @ 85 Hz on a CRT 4:3 Monitor.
    On Kubuntu, without drivers, I can use 1024 x 768 @ auto-refresh (60 Hz).

    But I have a little issue. At kubuntu startup my resolution is 1280x1024 (5:4) (see screenshot attached).
    When I go to System Management and click on Display, the resolution changes to 1024x768 (4:3) automatically.

    How can I set 1024x768 at startup?
    Thanks...
    Attached Files
    I'm an Italian user, sorry if my English is bad...

    #2
    Re: Extact resolution at startup

    Salve, Your english is excellent.

    As to why this is happening - you haven't posted enough information. There are at least two drivers for your video card - xserver-xorg-video-openchrome and xserver-xorg-video-via but this doesn't really seem to be the issue.

    Start with looking for the file /etc/X11/xorg.conf - I think you will not find it. The newest versions of X don't require it anymore. IF it is there, the fix is to set the resolution under the SCREEN section.

    If you look in your log file /var/log/Xorg.0.log I suspect you will find the line Using 1280x1024 or something similar.

    So, I can think of two ways to fix this for you:
    1. Generate an xorg.conf file and set your screen resolution. sudo X -configure will generate the file.

    or

    2. Enter the xrandr command in your /etc/rc.local file.

    I believe the xrandr command is xrandr --output default --mode 1024x768. Try it out in a terminal until you get it right, then put it in your /etc/rc.local file

    Please Read Me

    Comment


      #3
      Re: Extact resolution at startup

      Originally posted by oshunluvr
      Salve, Your english is excellent.
      Thanks...

      Originally posted by oshunluvr
      As to why this is happening - you haven't posted enough information. There are at least two drivers for your video card - xserver-xorg-video-openchrome and xserver-xorg-video-via but this doesn't really seem to be the issue.
      I think there are no usable drivers for my video card. I've already tried to install something, but It doesn't work.
      Besides, the "sudo lshw -c display | grep driver" command doesn't show me something, so I'm not using drivers for video card now.
      If you say that there are 2 drivers, can you tell me how I can set one of them?

      Originally posted by oshunluvr
      Start with looking for the file /etc/X11/xorg.conf - I think you will not find it. The newest versions of X don't require it anymore. IF it is there, the fix is to set the resolution under the SCREEN section.
      I find it.
      Here is its content:
      Section "Device"
      Identifier "Configured Video Device"
      Driver "vesa"
      EndSection

      Section "Monitor"
      Identifier "Configured Monitor"
      EndSection

      Section "Screen"
      Identifier "Default Screen"
      Monitor "Configured Monitor"
      Device "Configured Video Device"
      EndSection
      Originally posted by oshunluvr
      If you look in your log file /var/log/Xorg.0.log I suspect you will find the line Using 1280x1024 or something similar.

      So, I can think of two ways to fix this for you:
      1. Generate an xorg.conf file and set your screen resolution. sudo X -configure will generate the file.
      No. First, I got this:
      Fatal server error:
      Server is already active for display 0
      If this server is no longer running, remove /tmp/.X0-lock
      and start again.


      Please consult the The X.Org Foundation support
      at http://wiki.x.org
      for help.

      ddxSigGiveUp: Closing log
      Then, I removed .X0-lock and got:
      _XSERVTransSocketUNIXCreateListener: ...SocketCreateListener() failed
      _XSERVTransMakeAllCOTSServerListeners: server already running

      Fatal server error:
      Cannot establish any listening sockets - Make sure an X server isn't already running

      Please consult the The X.Org Foundation support
      at http://wiki.x.org
      for help.
      Please also check the log file at "/var/log/Xorg.0.log" for additional information.

      ddxSigGiveUp: Closing log
      I don't know what to do.

      Originally posted by oshunluvr
      2. Enter the xrandr command in your /etc/rc.local file.

      I believe the xrandr command is xrandr --output default --mode 1024x768. Try it out in a terminal until you get it right, then put it in your /etc/rc.local file
      I added "xrandr --output default --mode 1024x768" before "exit 0", but nothing is changed. At startup my resolution is 1280x1024 again.
      I'm an Italian user, sorry if my English is bad...

      Comment


        #4
        Re: Extact resolution at startup

        Ok, Step one - If you are unsure how to install a package, have you updated your system yet

        Do a full system update by running "System Settings". then under Computer Administration, "Add and Remove Software", then "Software Updates", click on Refresh. If you have a list of programs in this window, then you have updates to install. To the right of each file is a symbol to click on.

        After you've done all the updates, then click on "Software Management" and in the search bar type the names of the two "xserver-xorg-video-..." packages I listed before. Once they're installed, we can continue.

        Since you found an xorg.conf file, you don't need to generate a new one. But for future reference, this error
        Fatal server error:
        Server is already active for display 0
        is because you can't be running X when you do it. You have to switch to the text terminal mode and kill X before it will work Sorry, I should have been more clear.

        To continue using the VESA driver:
        Edit /etc/X11/xorg.conf and edit the "Section Screen"
        Code:
        Section "Screen"
          Identifier  "Default Screen"
          Monitor   "Configured Monitor"
          Device   "Configured Video Device"
          SubSection "Display"
          	Viewport	0 0
          	Depth		16
          	Modes    "1024x768"
          EndSubSection
        EndSection
        NOTE: This may not help because Vesa mode may be set elsewhere, but it's worth a try. You must be Root or "superuser" to edit this file. To do this: open a terminal (Konsole - it's under System
        in Kmenu) then type "sudo kate /etc/X11/xorg.conf". Please also note that if you make an error in this file, your graphics mode may not start at all. Type carefully!

        Restart your X after you do this edit.

        To stop or restart your graphics mode without a full reboot; here are the steps:

        1. Type CRTL-ALT-F1 >this should switch you to a text terminal log in screen.
        2. Log in and then type "sudo -i" >this will switch you to superuser mode.
        3. Type "service kdm restart"

        I don't know why rc.local command didn't work. Did the command work by itself? You tried it in a terminal window?

        Please Read Me

        Comment


          #5
          Re: Extact resolution at startup

          The situation is not good.
          I'm using Windows now and don't know how return in graphic mode on Kubuntu.
          Couldn't you tell me how to switch in graphic mode?

          Originally posted by oshunluvr
          Ok, Step one - If you are unsure how to install a package, have you updated your system yet
          I've already updated my system.

          Originally posted by oshunluvr
          Do a full system update by running "System Settings". then under Computer Administration, "Add and Remove Software", then "Software Updates", click on Refresh. If you have a list of programs in this window, then you have updates to install. To the right of each file is a symbol to click on.
          Already done.

          Originally posted by oshunluvr
          After you've done all the updates, then click on "Software Management" and in the search bar type the names of the two "xserver-xorg-video-..." packages I listed before. Once they're installed, we can continue.
          I've installed only "...-via" because the other one was already installed.

          Originally posted by oshunluvr
          To continue using the VESA driver:
          Edit /etc/X11/xorg.conf and edit the "Section Screen"
          Code:
          Section "Screen"
            Identifier  "Default Screen"
            Monitor   "Configured Monitor"
            Device   "Configured Video Device"
            SubSection "Display"
            	Viewport	0 0
            	Depth		16
            	Modes    "1024x768"
            EndSubSection
          EndSection
          NOTE: This may not help because Vesa mode may be set elsewhere, but it's worth a try. You must be Root or "superuser" to edit this file. To do this: open a terminal (Konsole - it's under System
          in Kmenu) then type "sudo kate /etc/X11/xorg.conf". Please also note that if you make an error in this file, your graphics mode may not start at all. Type carefully!

          Restart your X after you do this edit.

          To stop or restart your graphics mode without a full reboot; here are the steps:

          1. Type ALT-F1 >this should switch you to a text terminal log in screen.
          2. Log in and then type "sudo -i" >this will switch you to superuser mode.
          3. Type "service kdm restart"
          ALT+F1 does nothing. CTRL+ALT+F1 switches in text mode.
          I've done what you suggested me, but in terminal text mode I've tried to swicth in graphic mode and I can't.
          I've tried with keys from CTRL+ALT+F1 to CTRL+ALT+F12 and nothing change.
          What have I to do?

          Originally posted by oshunluvr
          I don't know why rc.local command didn't work. Did the command work by itself? You tried it in a terminal window?
          Yes and yes.
          I'm an Italian user, sorry if my English is bad...

          Comment


            #6
            Re: Extact resolution at startup

            Sorry yes it's CRTL-ATL-F1 (actually F1 to F6) for terminal mode. CRTL-ALT-F7 returns you to graphic mode.

            "sudo service kdm restart" should kill and restart graphics mode and return you to the log in screen

            If these fail - try starting X manually by typing "X" or "startx".

            If X is already running, you will get an error message about the lock file. If X won't start at all, you should get some error messages on the screen. If this happens, write them down and report them here.

            If you're not getting graphics mode when you reboot, then there should be an error like "screen not found" "no usable modes" or "parse error"

            Please Read Me

            Comment


              #7
              Re: Extact resolution at startup

              Originally posted by Digitalone
              I've done what you suggested me, but in terminal text mode I've tried to swicth in graphic mode and I can't.
              I've tried with keys from CTRL+ALT+F1 to CTRL+ALT+F12 and nothing change.
              What have I to do?
              Did you try Alt+F7 ?

              Comment


                #8
                Re: Extact resolution at startup

                Originally posted by skunk
                Did you try Alt+F7?
                Yes. Black screen, taxt cursor flashing, changes nothing...
                I'm an Italian user, sorry if my English is bad...

                Comment


                  #9
                  Re: Extact resolution at startup

                  Originally posted by oshunluvr
                  "sudo service kdm restart" should kill and restart graphics mode and return you to the log in screen
                  After give this command I get:
                  Code:
                  restart: reject send message, 1 matched rules; type="method_call", sender="1.18" 
                  (uid=1000 pid=1520 comm="restart") (interface="com.ubuntu.upstart0_6.job" member="restart" error name="(unset)" 
                  requested_reply=0 destination="com.ubuntu.upstart" 
                  (uid=0 pid=1 comm="/sbin/init"))
                  Originally posted by oshunluvr
                  If these fail - try starting X manually by typing "X" or "startx".

                  If X is already running, you will get an error message about the lock file. If X won't start at all, you should get some error messages on the screen. If this happens, write them down and report them here.

                  If you're not getting graphics mode when you reboot, then there should be an error like "screen not found" "no usable modes" or "parse error"
                  There are errors:
                  Code:
                  parse error on line 18 of section screen in file /ect/x11/xorg.conf
                  unexpected EOF, missing endsection keyword?
                  
                  (EE) problem parsing the config file
                  (EE) error parsing the config file
                  
                  fatal server error
                  no screens found
                  What can I do now?
                  I'm an Italian user, sorry if my English is bad...

                  Comment


                    #10
                    Re: Extact resolution at startup

                    Remember I said:
                    Please also note that if you make an error in this file, your graphics mode may not start at all. Type carefully!
                    the answer lies here:
                    parse error on line 18 of section screen in file /ect/x11/xorg.conf
                    unexpected EOF, missing endsection keyword?

                    (EE) problem parsing the config file
                    (EE) error parsing the config file
                    It appears you left out either
                    Code:
                      EndSubSection
                    or
                    Code:
                    EndSection
                    When you edited xorg.conf.

                    You can fix this several ways.
                    1. rename xorg.conf to somethings else, do sudo X -configure to create a new one, and start over.
                    2. boot to the livecd and mount your hard drive, edit xorg.conf (as root) to fix the error.
                    3. edit xorg.conf from the command line.

                    To do number 3:
                    IF you left out the final line only (seems likely):
                    Type cat /etc/X11/xorg.conf. This will type the file out on your screen. If the last line is "EndSubSection" then type sudo echo EndSection >> /etc/X11/xorg.conf and try to start X again.

                    If the last line is "EndSection" and the one above is NOT "EndSubSection" you'll need to edit it and add "EndSubSection". You can use a program called "nano". Type sudo nano /etc/X11/xorg.conf and try to figure out the editor.

                    Please Read Me

                    Comment


                      #11
                      Re: Extact resolution at startup

                      It might be as simple as a missing new line at end of file

                      Comment


                        #12
                        Re: Extact resolution at startup

                        Ok. I'm with Kubuntu now. Thanks for the help but nothing is changed.

                        I've not forgotten something to write into xorg.conf.
                        I figured out the problem only opening the file under Windows with Notepad.
                        There was no spaces or \n beetween endsubsection and endsection, although with kate I see them separated.

                        However, I edited xorg.conf with notepad. With liveCD I've overwritten his older version and restarted.
                        Kubuntu works, but at startup I'm with 1280x1024 again.

                        I've tried again to do:
                        Code:
                        CRTL+ALT+F1
                        sudo -i
                        service kdm restart
                        It switched in GUI mode this time, but the start is always at 1280x1024.
                        Besides, "sudo lshw -c display | grep driver" continues to don't give me something.
                        This means that my ****ing video card does not want to work with any drivers...

                        I post also "sudo lshw | grep driver", if you are interested:
                        Code:
                             configuration: driver=agpgart-via latency=8
                               configuration: driver=pcieport-driver
                               configuration: driver=sata_via latency=32
                               configuration: driver=pata_via latency=32
                               configuration: driver=uhci_hcd latency=32
                               configuration: driver=uhci_hcd latency=32
                               configuration: driver=uhci_hcd latency=32
                               configuration: driver=uhci_hcd latency=32
                               configuration: driver=ehci_hcd latency=32
                               configuration: driver=VIA 82xx Audio latency=0
                               configuration: autonegotiation=off broadcast=yes driver=via-rhine driverversion=1.4.3
                                          duplex=full ip=192.168.0.2 latency=32 link=yes maxlatency=8 mingnt=3
                                          multicast=yes port=MII speed=100MB/s
                        I don't understand. I'm surrender...
                        I'm an Italian user, sorry if my English is bad...

                        Comment


                          #13
                          Re: Extact resolution at startup

                          Don't surrender yet. You driver isn't being loaded because xorg put "Vesa" in the driver section of xorg.conf. If you want the best performance and display options, you should try and install the openchrome driver. My websearching reveals the via driver is older and no longer supported.

                          Have you seen this page? http://linux.via.com.tw/support/downloadFiles.action. It looks like Via is trying to support linux and they might just help you if you email them directly. Also this page http://www.openchrome.org/ and this one http://wiki.archlinux.org/index.php/...he_Xorg-driver have more information and tips.

                          In the mean time, I've not used a Via card yet - but try this: In Kubuntu, open a terminal (konsole) and type modprobe openchrome and see if you get any errors. If you don't we're going to change xorg.conf again but this time we'll save a working copy how it is now.

                          I have attached two files for you to the post. Save them to your home directory for now. Then do these commands:
                          Code:
                          CRTL-ALT-F1
                          cd /etc/X11
                          sudo -i
                          mv xorg.conf xorg.conf.vesa
                          mv ~/xorg.conf.openchrome.txt xorg.conf
                          service kdm restart
                          If all goes well - you should be restarted to the login in prompt and using your new openchrome driver. If it fails (you might want to print out this post), these commands should return you to the Vesa driver
                          Code:
                          mv xorg.conf xorg.conf.openchrome
                          mv xorg.conf.vesa xorg.conf
                          service kdm restart
                          If you want to try to "fix" the Vesa driver using xrandr, copy the second file to the /etc/X11/Xsession.d directory with these commands:
                          Code:
                          CRTL-ALT-F1
                          cd /etc/X11
                          sudo -i
                          mv ~/45custom_xrandr-settings.txt Xsession.d/45custom_xrandr-settings
                          service kdm restart
                          Attached Files

                          Please Read Me

                          Comment


                            #14
                            Re: Extact resolution at startup

                            Originally posted by oshunluvr
                            In the mean time, I've not used a Via card yet - but try this: In Kubuntu, open a terminal (konsole) and type modprobe openchrome and see if you get any errors.
                            FATAL: Module openchrome not found.

                            I don't understand. With Adept I see that xserver-xorg-video-openchrome is installed!
                            Do you have any idea?
                            I'm an Italian user, sorry if my English is bad...

                            Comment


                              #15
                              Re: Extact resolution at startup

                              OpenChrome
                              Windows no longer obstructs my view.
                              Using Kubuntu Linux since March 23, 2007.
                              "It is a capital mistake to theorize before one has data." - Sherlock Holmes

                              Comment

                              Working...
                              X