0

I was experiencing problems with Ubuntu at the time of booting, apparently it was/is the Nvidia Drivers as my laptop has a 970M. One solution I found and worked well was every time before booting press e in Ubuntu and then editing the Linux part to nouveau.modeset=0. However, as this was tedious, I tried to set this to be automatic when booting, a solution was editing /etc/default/grub and then sudo update-grub, and the rebooting. After rebooting I can no longer enter to Ubuntu, and the command nouveau.modeset=0 does not work anymore as it gets stucked in a blank screen.

I would really appreciate help as there is my masters thesis.

  • P.S the recovery mode is not working neither it gets stucked in Loading initial ramdisk – Angelo Espinoza May 16 '23 at 08:15
  • It seems to me that your automatic setting is doing something different from what you did manually (maybe because of a typing error or a misunderstood command). Can you boot into the grub menu? In that case try to edit it manually. Otherwise you need to repair your system when booted from another system, for example from a USB pendrive with Ubuntu live: Edit the file grub.cfg that belongs to the installed system. After booting into it, fix /etc/default/grub to avoid the problem the next time sudo update-grub is run (manually or automatically). – sudodus May 16 '23 at 09:14
  • @sudodus you mean pressing again e in Ubuntu? I can do that, actually there is the command nouveau.modeset=0 not misspelled in fact. But if I try to delete or place at the end does not work as it did. As for the Ubuntu live, you mean installing Ubuntu then run wih the Try Ubuntu, and then mount the disk in order to edit again /etc/default/grub? – Angelo Espinoza May 16 '23 at 09:28
  • If your system does not work as before, when the grub commands look exactly the same, something else has changed (maybe an upgrade of the kernel, that brings another kernel driver, maybe something else). - And yes, run Try Ubuntu from USB. But you should not need to do that, when you have access to the grub menu. - But if that does not help, and there is another problem, maybe you should run Try Ubuntu from USB in order to backup (save) all files that you do not want to lose and then consider a fresh installation. – sudodus May 16 '23 at 09:31
  • I suggest that you try to fix the current system, but do not spend too much time and effort on it, because reinstallation may be easier and faster. – sudodus May 16 '23 at 09:37
  • Maybe you have one or more old kernels available and possible to select in the grub menu. In that case please try if Ubuntu works better with one of those kernels. – sudodus May 16 '23 at 09:56
  • @sudodus how can I do that? – Angelo Espinoza May 16 '23 at 10:07
  • Look for boot alternatives via grub (a submenu may contain older versions of kernels); 2. Look in the boot directory of the installed system (files numbers indicates which kernel they belong to); 3. But you should really consider a re-installation, because that way you will get rid of whatever is destroying your current installed system (unless some hardware is failing).
  • – sudodus May 16 '23 at 10:56
  • Apparently I have 2 but none of them work. I have reinstalled Ubuntu multiple times due to the first problem I mentioned, until I figured out the nouveau.modeset=0. Very strange since the only line I modified was the GRUB_CMDLINE_LINE_DEFAULT="quiet splash" to GRUB_CMDLINE_LINE_DEFAULT="quiet splash nouveau.modeset=0" in /etc/default/grub, and then sudo update-grub. Just as in https://askubuntu.com/questions/1053150/nouveau-modeset0?newreg=444e841d08ac4464924b081efb179adf. – Angelo Espinoza May 16 '23 at 13:38
  • Please specify the computer: brand name and model; 5. Check in the BIOS if you can turn on/off the nvidia card (and use built-in graphics in the CPU); 6. Please download and clone some other Ubuntu iso files: 20.04 LTS and 22.04 LTS (and if the computer is very new 23.04 LTS). Try these live (booted from USB) with and without an extra boot option (you may try nomodeset as well as nouveau.modeset=0 directly from the grub menu.
  • – sudodus May 16 '23 at 15:56
  • The brand name is Razer the model is a Blade RZ09-0130. No option is available in the BIOS to turn on/off the Nvidia card. – Angelo Espinoza May 16 '23 at 18:22
  • 1
    Finally got it working after following what @sudodus suggested. I boot through a Ubuntu live USB pendrive, mount the driver, accessed as a root, and deleted the line nouveau.modeset=0 from /etc/default/grub, then simply update-grub in /boot/grub. After that everything went back just as before. Of course, I currently have to access Ubuntu through nouveau.modeset=0 typed manually. Yet I have not tried any other solution to make it automatic. – Angelo Espinoza May 17 '23 at 05:04
  • Thanks for sharing your solution, or maybe we should call it 'workaround'. Do you want to continue debugging in order to find a more convenient solution? For example, maybe the delay, when you add nouveau.modeset=0 help by letting something get settled, maybe there is something else that is hard to find. Have you tried to install any proprietary driver for your nvidia graphics yet? – sudodus May 17 '23 at 07:44
  • News after 10 months... I left the computer closed on my backpack and forgot to charge it, so it ran out of battery, which left the computer to turn off, I have to clarify that it happened to me before. But this time, when I wanted to use again the same thing nouveau.modeset=0 it didn't boot up. I was trying to use other options and nothing worked, so I decided to reinstall Ubuntu again with the hope it let me enter with or without the trick, and nothing has happened. After the message of restart the computer after installing Ubuntu it does not let me boot again :(. – Angelo Espinoza Mar 30 '24 at 00:51
  • Which version of Ubuntu did you try this time: 20.04.x LTS according to the tag or the newer 22.04.x LTS or some other version? I suggest that you try different versions, because they have different graphics drivers and also different ways to manage the 'lock-down mechanisms' that Microsoft and the computer manufacturers develop. (If the computer has been upgraded with new firmware, you may need to disable TPM and/or Secure Boot and similar features to make the computer bootable.) – sudodus Mar 30 '24 at 10:18
  • Thanks for you answer. Still at 20.04 LTS. I am currently working with ROS1 (a framework for robotics) and it requires me to have that distro of Ubuntu so that's why I'm sticking to it... Where can I find those TPM and Secure Boot? I guess in the BIOS, but where exactly? Wouldn't it affect my Windows partition?

    Thanks once again.

    – Angelo Espinoza Mar 30 '24 at 20:08
  • Yes, TPM and Secure Boot should be found in a UEFI-BIOS menu (this varies a lot between computers, you must search for it yourself; I have no Razor Blade computer, and don't know what your computer's UEFI-BIOS menu system looks like). Turning off the {security/lock-down features} should be OK with Windows. Anyway, if you can turn them off, you should be able to turn them back on again. But it might be difficult or impossible to turn them off (depending on the UEFI-BIOS system). – sudodus Mar 30 '24 at 22:02
  • When Secure Boot is turned off, it might be possible to install and use a proprietary nvidia driver for your graphics card. But if you are satisfied with the performance with nouveau.modeset=0 you should not bother with that. -- By the way, are you using X or Wayland? Check by the command echo $XDG_SESSION_TYPE? I think it works better with X. – sudodus Mar 30 '24 at 22:09
  • 1
    Just finished attempting the solution, and ALL IS WORKING plus no "trick" of nouveau.modeset=0 is needed anymore. I found that I had turned off the Secure Boot, however when I checked the TPM as the reference I saw that it was enabled, after disabling it, and automatically restarting I could enter Ubuntu without any problem along with Windows! Hopefully this solution remains forever. But so far, I think it does it. Thank you @sudodus once more, to be there after almost one year from the original post! – Angelo Espinoza Apr 01 '24 at 03:12
  • I'm glad that you found a solution :-) – sudodus Apr 01 '24 at 08:47