nvidia card driver not detected: no settings & cannot use HDMI

8,069

Solution 1

I've found a solution writing a script that adapts the resolution each time I login.

To make my life easier I had swapped monitors with the one I hook to my other laptop at my coworking space (that one detects the new monitor in both VGA and HDMI).

First I searched for my monitor's specifications using Google to figure out the optimal resolution, using these keywords: syncmaster t220 specs. This is the first bit of information I needed: Native Resolution 1680 x 1050 at 60 Hz.

Then I opened a terminal and used cvt to get the correct mode to add:

cvt 1680 1050

This is the result:

# 1680x1050 59.95 Hz (CVT 1.76MA) hsync: 65.29 kHz; pclk: 146.25 MHz
Modeline "1680x1050_60.00"  146.25  1680 1784 1960 2240  1050 1053 1059 1089 -hsync +vsync

The part that maters comes right after Modeline. To copy in the terminal you highlight the text that matters with your mouse and then press Ctrl+Shift+c, and to paste Ctrl+Shift+v. You can open a couple terminals if you feel more comfortable.

Then I used the simple text editor nano (you can also use gedit or any other simple text editor) and added the following:

#!/bin/bash
xrandr --newmode "1680x1050_60.00"  146.25  1680 1784 1960 2240  1050 1053 1059 1089 -hsync +vsync
xrandr --addmode VGA1 1680x1050_60.00
xrandr --output VGA1 --mode 1680x1050_60.00

As you can see I directly pasted the result of cvt after xrandr --newmode to create the new mode I want to use. Then I use the content within the brackets into the next two lines.

Notice that I used VGA1 for the output, but you can also use HDMI or whatever else you have connected. To find out the names of the devices just run xrandr without any parameters. In my case, the laptop's screen is called LVDS1.

Then I saved the file and exited (the commands are in the bottom of nano's screen, the ^ symbol means to use the Ctrl key in combination with whatever comes after it.) The name of the file does not matter, just make it something that will help you identify it later on (like, months after when you don't remember how you fixed your problem.)

After that I changed the permissions of the file so that it could be executed:

chmod +x activate-resolution-t220

You can also add execute permission using the file browser, right-clicking on it, selecting properties, the Permissions tab and then marking the tick box to the left of Allow executing file as program.

Running the file will change your monitor resolution:

./activate-resolution-t220 

Usually if you start typing the ./ and the beginning of the name of your file and hit the Tab key, the name of your file will be automatically written for you. If it is only part of it, then there's another file that shares that part as the beginning of their name and you have to add some more characters to help the computer see the one you mean and hit Tab again.

To execute it automatically every time I log in I just opened Startup Applications (in the Dash start typing startup and the icon will show right away), clicked on Add, clicked on Browse, looked for my file, clicked Open, and finally clicked Add.

Now every time I log in, my monitor displays the right resolution :)

If you like this answer and find it useful, please vote it up!

Solution 2

Your problem is that you have 2 video cards: the GeForce G105M and the intel Integrated one. It's called "Nvidia Hybrid Graphics" and it's a nightmare under Linux.

Your only solution is to disable one of the GPU and then install the correct driver for the other one. If you disable the nVidia GPU (my suggestion), you will have better battery life and it will work out-of-the-box but you will get worse 3D performance in games and WebGL. If you disable the Intel GPU, you'll need to install the nVidia proprietary drivers (they don't use XrandR and they need a proper Xorg.conf file).

To switch to a single GPU, you have 2 options: 1) Select the GPU in the HP BIOS, if there is such an option. Maybe upgrade to the latest BIOS first to be sure. 2) If there is no such option, follow these instructions on the Ubuntu wiki: https://help.ubuntu.com/community/HybridGraphics

Hope this helps :)

Share:
8,069

Related videos on Youtube

Ramon Suarez
Author by

Ramon Suarez

Coworking, entrepreneurship, learning to code; Betacowork Coworking Brussels founder; The Coworking Handbook author; startups.be founder; chocolate ambassador; Brussels lover. My Twitter account is @ramonsuarez

Updated on September 18, 2022

Comments

  • Ramon Suarez
    Ramon Suarez over 1 year

    I have an HP Pavilion DM3-1120eb laptop with an Nvidia Geforce G105M graphic card, running a fresh Ubuntu 12.04 Precise Pangolin install. When connecting to a new Samsung S23B550 23 inch LCD monitor the HDMI will not work and the VGA connection will not allow for 1920*1080 resolution. The result is a small resolution (1024*768) that does not look good (fuzzy) and I cannot watch YouTube videos (the video box keeps on moving to the right and back) and the same flickering effect happens with droping menus and Google's suggestion box.

    I've tried multiple solutions sugested in posts with no good result (including installing the drivers downloaded from the Nvidia page).

    As far as I can guess, the problem is that the NVIDIA card is present but not recognized and thus the drivers do not work. Originally the drivers were installed (nvidia-current and the rest, all updated), but could not configure them with nvidia-config (says driver not present) and they did not show up with jockey-gtk. There's also been an error message about GLX not being present either. SCREENSHOT

    For the HDMI the monitor says that there's no signal of MHL is not installed.

    The computer is running now with no Nvidia drivers and no xorg.conf file (it gives me the best resolution). VGA will not even recognize the monitor as a 16:9.

    This is the result of xrandr:

        Screen 0: minimum 320 x 200, current 1024 x 768, maximum 8192 x 8192
    LVDS2 connected 1024x768+0+0 (normal left inverted right x axis y axis) 293mm x 164mm
       1366x768       60.0 +
       1360x768       59.8     60.0  
       1024x768       60.0* 
       800x600        60.3     56.2  
       640x480        59.9  
    VGA2 connected 1024x768+0+0 (normal left inverted right x axis y axis) 0mm x 0mm
       1024x768       60.0* 
       800x600        60.3     56.2  
       848x480        60.0  
       640x480        59.9  
    DP1 disconnected (normal left inverted right x axis y axis)
    

    lspci -v (only section about vga):

    01:00.0 VGA compatible controller: NVIDIA Corporation G98M [GeForce G105M] (rev a2) (prog-if 00 [VGA controller])
        Subsystem: Hewlett-Packard Company Device 142e
        Flags: bus master, fast devsel, latency 0, IRQ 16
        Memory at f0000000 (32-bit, non-prefetchable) [size=16M]
        Memory at c0000000 (64-bit, prefetchable) [size=256M]
        Memory at d0000000 (64-bit, prefetchable) [size=32M]
        I/O ports at 4000 [size=128]
        Expansion ROM at f1080000 [disabled] [size=512K]
        Capabilities: <access denied>
        Kernel driver in use: nouveau
        Kernel modules: nvidia, nouveau, nvidiafb
    

    Last xorg.conf (now removed):

        # nvidia-xconfig: X configuration file generated by nvidia-xconfig
    # nvidia-xconfig:  version 295.40  ([email protected])  Thu Apr  5 22:40:54 PDT 2012
    
    
    Section "ServerLayout"
        Identifier     "Layout0"
        Screen      0  "Screen0" 0 0
        InputDevice    "Keyboard0" "CoreKeyboard"
        InputDevice    "Mouse0" "CorePointer"
    EndSection
    
    Section "Files"
    EndSection
    
    Section "InputDevice"
    
        # generated from default
        Identifier     "Mouse0"
        Driver         "mouse"
        Option         "Protocol" "auto"
        Option         "Device" "/dev/psaux"
        Option         "Emulate3Buttons" "no"
        Option         "ZAxisMapping" "4 5"
    EndSection
    
    Section "InputDevice"
    
        # generated from default
        Identifier     "Keyboard0"
        Driver         "kbd"
    EndSection
    
    Section "Monitor"
        Identifier     "Monitor0"
        VendorName     "Unknown"
        ModelName      "Unknown"
        HorizSync       28.0 - 33.0
        VertRefresh     43.0 - 72.0
        Option         "DPMS"
    EndSection
    
    Section "Device"
        Identifier     "Device0"
        Driver         "nvidia"
        VendorName     "NVIDIA Corporation"
    EndSection
    
    Section "Screen"
        Identifier     "Screen0"
        Device         "Device0"
        Monitor        "Monitor0"
        DefaultDepth    24
        SubSection     "Display"
            Depth       24
        EndSubSection
    EndSection
    

    nvidia-settings error:

    ![nvidia-settings error][2]
    
    lshw -C video:
    
      *-display               
           description: VGA compatible controller
           product: G98M [GeForce G105M]
           vendor: NVIDIA Corporation
           physical id: 0
           bus info: pci@0000:01:00.0
           version: a2
           width: 64 bits
           clock: 33MHz
           capabilities: pm msi pciexpress vga_controller bus_master cap_list rom
           configuration: driver=nouveau latency=0
           resources: irq:16 memory:f0000000-f0ffffff memory:c0000000-cfffffff memory:d0000000-d1ffffff ioport:4000(size=128) memory:f1080000-f10fffff
      *-display
           description: Display controller
           product: Mobile 4 Series Chipset Integrated Graphics Controller
           vendor: Intel Corporation
           physical id: 2
           bus info: pci@0000:00:02.0
           version: 07
           width: 64 bits
           clock: 33MHz
           capabilities: msi pm bus_master cap_list rom
           configuration: driver=i915 latency=0
           resources: irq:45 memory:f1400000-f17fffff memory:e0000000-efffffff ioport:50f0(size=8)
    
  • Ramon Suarez
    Ramon Suarez almost 12 years
    Thanks Christophe. I have no option to disable the intel card in the Bios. Trying out the link's solution.
  • Ramon Suarez
    Ramon Suarez almost 12 years
    I cannot proceed with the solution in that page. vgaswitchero is present:grep -i switcheroo /boot/config-3.2.* CONFIG_VGA_SWITCHEROO=y and sudo ls -l /sys/kernel/debug/vgaswitcheroo/switch -rw-r--r-- 1 root root 0 May 20 10:57 /sys/kernel/debug/vgaswitcheroo/switch but when I do `sudo echo ON > /sys/kernel/debug/vgaswitcheroo/switch" I get a permission denied message.
  • Ramon Suarez
    Ramon Suarez almost 12 years
    Found some info about the permission problem here: http://askubuntu.com/questions/20578/sudo-redirect-output Don't understand it right now.
  • Ramon Suarez
    Ramon Suarez almost 12 years
    Tried Bumblebee to see if my computer could be one of the "legacy" Optimus.Nothing changed in terms of display, but I could launch individual apps and it did change something after a bit of black screen, but had same resolution. So I uninstalled it and now the /sys/kernel/debug/vgaswitcheroo/switchfile is missing.
  • Ramon Suarez
    Ramon Suarez almost 12 years
    Thanks Alexis. In the meantime I've deleted the file by installing and uninstalling Bumblebee. How can I rebuild it?