2

after upgrading my machine to 18.04 from 16.04 I noticed that my Nvidia driver is no longer installed and after I reinstalled the driver I'm getting a black screen I've got such a problem before and fixed it with manually installing the Nvidia driver instead of using autoinstall or apt-get install Nvidia (number goes here). I've tried all the method of installation mentioned here and read almost all topic about this problem on askubuntu, its almost 2 weeks now and I'm unable to find a solution to this problem

information you might need

lspci | grep VGA
02:00.0 VGA compatible controller: NVIDIA Corporation GM204 [GeForce GTX 970] (rev a1)

ubuntu-drivers devices == /sys/devices/pci0000:00/0000:00:01.1/0000:02:00.0 == modalias : pci:v000010DEd000013C2sv00001458sd0000367Abc03sc00i00 vendor : NVIDIA Corporation model : GM204 [GeForce GTX 970] driver : nvidia-driver-415 - third-party free recommended driver : nvidia-driver-390 - third-party free driver : nvidia-driver-396 - third-party free driver : nvidia-driver-410 - third-party free driver : xserver-xorg-video-nouveau - distro free builtin

nvidia-detector none

sudo lshw -numeric -C display -display UNCLAIMED
description: VGA compatible controller product: GM204 [GeForce GTX 970] [10DE:13C2] vendor: NVIDIA Corporation [10DE] physical id: 0 bus info: pci@0000:02:00.0 version: a1 width: 64 bits clock: 33MHz capabilities: pm msi pciexpress vga_controller bus_master cap_list configuration: latency=0 resources: memory:f2000000-f2ffffff memory:e0000000-efffffff memory:f0000000-f1ffffff ioport:e000(size=128) memory:f3000000-f307ffff
-display UNCLAIMED description: Display controller product: Xeon E3-1200 v3/4th Gen Core Processor Integrated Graphics Controller [8086:412] vendor: Intel Corporation [8086] physical id: 2 bus info: pci@0000:00:02.0 version: 06 width: 64 bits clock: 33MHz capabilities: msi pm bus_master cap_list configuration: latency=0 resources: memory:f3400000-f37fffff memory:d0000000-dfffffff ioport:f000(size=64)

##glxinfo -B name of display: :1 display: :1 screen: 0 direct rendering: Yes Extended renderer info (GLX_MESA_query_renderer): Vendor: VMware, Inc. (0xffffffff) Device: llvmpipe (LLVM 7.0, 256 bits) (0xffffffff) Version: 18.2.8 Accelerated: no Video memory: 15904MB Unified memory: no Preferred profile: core (0x1) Max core profile version: 3.3 Max compat profile version: 3.1 Max GLES1 profile version: 1.1 Max GLES[23] profile version: 3.0 OpenGL vendor string: VMware, Inc. OpenGL renderer string: llvmpipe (LLVM 7.0, 256 bits) OpenGL core profile version string: 3.3 (Core Profile) Mesa 18.2.8 OpenGL core profile shading language version string: 3.30 OpenGL core profile context flags: (none) OpenGL core profile profile mask: core profile

OpenGL version string: 3.1 Mesa 18.2.8 OpenGL shading language version string: 1.40 OpenGL context flags: (none)

OpenGL ES profile version string: OpenGL ES 3.0 Mesa 18.2.8 OpenGL ES profile shading language version string: OpenGL ES GLSL ES 3.00

##uname -a Linux LeLouch 4.4.0-31-generic #50-Ubuntu SMP Wed Jul 13 00:07:12 UTC 2016 x86_64 x86_64 x86_64 GNU/Linux

edit i fixed the problem by updating the kernel

i've spent 3 weeks now with this and the problem was the grub boot loader needed to be updated after the linux-header update i used update-grub every time but i fail to notice that the main grub boot loader was on another distro so i needed to update that grub and that fixed my problem. all thanks to @BarBar1234

LeLouch
  • 21
  • when does the black screen appears? during boot, after boot? or else? – Jastria Rahmat Feb 24 '19 at 22:52
  • black screen appears after I select Ubuntu from the grub and a few seconds later the keyboard num pad light start working which means ubuntu has loaded but i can see nothing other than a black screen even ctrl + alt + f1 / f2 --> f12 goes no where – LeLouch Feb 25 '19 at 09:20
  • 16.04 -> 18.04 upgrades rarely run smooth. I can't get mine working as well. Consider a fresh install. – Pilot6 Feb 25 '19 at 20:32
  • 1
    Upgrades typically want you to disable 3rd party repos. If you did (the graphics ppa?), did you re-enable them, since 415 is not in the standard repos. – ubfan1 Feb 25 '19 at 20:48
  • @Pilot6 fresh install is not an option – LeLouch Feb 25 '19 at 22:42
  • @ubfan1 yes I did re-enable them and tried with and without the repo auto and manual install and getting always the same problem – LeLouch Feb 25 '19 at 22:44
  • Check all files in /etc/modprobe.d for blacklist nvidia lines (except OK to blacklist nvidiafb) -- remove them if any. What happens when you add the nvidia driver with modprobe nvidia (presuming you have the driver, and it's not getting used)? Post the output of lsmod | grep nvi (four nvidia... modules expected). Did you ever try booting an older kernel? – ubfan1 Feb 25 '19 at 23:07
  • 1
    I would try this: https://askubuntu.com/questions/162075/my-computer-boots-to-a-black-screen-what-options-do-i-have-to-fix-it – Dave Feb 25 '19 at 23:46

2 Answers2

0

disable Secure Boot in BIOS, as Secure Boot blocks the nvidia modules from being loaded in this case.

NetIceGear
  • 641
  • 3
  • 8
  • found secure boot already disabled – LeLouch Feb 25 '19 at 22:57
  • Ok, and have you tried the grub option nouveau.modeset=0 already as well? – NetIceGear Feb 26 '19 at 00:11
  • YES , i used that to uninstall all the nvidia drivers and log back to my desktop – LeLouch Feb 26 '19 at 00:27
  • Ok, could you provide the printout of glxinfo -B when you have modeset set to zero. I can't recall if glxinfo is already included, but if not you should be able to get it from the main repo. Also, please add uname -a output for additional reference – NetIceGear Feb 26 '19 at 01:19
  • thanks for the reply nouveau.modeset=0 didn't help at all but i sed nomodeset=0 to go back to desktop and i've updated what you asked for – LeLouch Feb 26 '19 at 20:21
  • Ok, I see that you have a whole selection of drivers you attempted to use, can you remove all nvidia drivers, and load only the xserver-xorg-video-nouveau one and then try the nouveau.modeset=0 grub parameter. also make sure your linux-headers are up to date! – NetIceGear Feb 26 '19 at 20:45
  • after I removed all Nvidia driver and made sure I was booting properly using nouveau I tried nouveau.modeset=0 on the grub parameter and went back to the same black screen . – LeLouch Feb 26 '19 at 21:21
  • Sorry, I edited the last comment I posted right after posting, but didnt realize there was only a 5 min window for editing and it didnt get updated. The nouveau.modeset=0 will of course cause a black screen when nouveau is the only nvidia driver in use. MY updated comment went something like this: purge all propriatary drivers and use nouvedau and test reboot, then re-check to make sure that the lshw -numeric -C now lists driver=nouveau in the line with configuration: latency and glxinfo -B updates the driver information as well. – NetIceGear Feb 27 '19 at 02:14
  • However, I just noticed the last part of the shell output you provided namely $uname -a . How do you have such an outdated kernel version if running Ubuntu 18.04? The 18.04 uses 4.15 kernel version. Please post output of $sudo apt search linux-headers-$(uname -r) because your headers seem very outdated and your gpu is a recent model. I would just proceed with header update and then let dkms build the nvidia driver accordingly: $sudo apt-get update && sudo apt install linux-headers-$(uname -r|sed 's/[^-]*-[^-]*-//') nvidia-driver – NetIceGear Feb 27 '19 at 02:26
0

I tried countless solutions found on the internet, the only thing that worked for me was to:

  • backup /etc/X11/xorg.conf to /etc/X11/xorg.conf.old
  • similarly backup /etc/X11/xorg.conf.d/ directory, if it exists
  • and then cp -r /usr/share/X11/xorg.conf.d /etc/X11/
axel22
  • 121