Can't load graphical environment after (stupidly) removing linux519-nvidia, as it was preventing the OS update. Can't reinstall it because it 'does not exist' anymore

when updating this friday, I was told that this package was interrupting with the upgrade (did not record the message) and I, stupidly, removed it:

sudo pacman -R nvidia-519

Now I can’t boot into graphical environment (i3).

I tried

sudo pacman -S nvidia-519

but that just says:

error: target not found: nvidia-519

I tried downgrading the kernel to the LTS 515, but that still did not help

sudo mhwd -a pci nonfree 0300

which just says:

skipping already installed config 'video-nvidia' for device

So I’ve tried googling and searching the forums but I couldn’t find anything I could use (or, that I could understand, probably)

I can get to a terminal, and output these that might help:

output of inxi -Fza


System:
  Kernel: 5.15.89-1-MANJARO arch: x86_64 bits: 64 compiler: gcc v: 12.2.1
    parameters: BOOT_IMAGE=/boot/vmlinuz-5.15-x86_64 root=UUID=f61cf363-eb5f-4a1e-86cc-e0379407767b
    rw quiet apparmor=1 security=apparmor udev.log_priority=3
  Console: tty 2 DM: LightDM v: 1.32.0 Distro: Manjaro Linux base: Arch Linux
Machine:
  Type: Desktop System: LENOVO product: 30BYS2N000 v: ThinkStation P520c
    serial: <superuser required> Chassis: type: 3 serial: <superuser required>
  Mobo: LENOVO model: 1036 v: SDK0Q40104 WIN 3305667182328 serial: <superuser required>
    UEFI: LENOVO v: S03KT21A date: 10/26/2018
CPU:
  Info: model: Intel Xeon W-2135 bits: 64 type: MT MCP arch: Skylake level: v4 note: check
    process: Intel 14nm family: 6 model-id: 0x55 (85) stepping: 4 microcode: 0x2006E05
  Topology: cpus: 1x cores: 6 tpc: 2 threads: 12 smt: enabled cache: L1: 384 KiB
    desc: d-6x32 KiB; i-6x32 KiB L2: 6 MiB desc: 6x1024 KiB L3: 8.2 MiB desc: 1x8.2 MiB
  Speed (MHz): avg: 1200 high: 1201 min/max: 1200/4500 scaling: driver: intel_pstate
    governor: powersave cores: 1: 1200 2: 1200 3: 1200 4: 1200 5: 1201 6: 1200 7: 1200 8: 1200
    9: 1200 10: 1200 11: 1200 12: 1200 bogomips: 88824
  Flags: avx avx2 ht lm nx pae sse sse2 sse3 sse4_1 sse4_2 ssse3 vmx
  Vulnerabilities:
  Type: itlb_multihit status: KVM: VMX disabled
  Type: l1tf mitigation: PTE Inversion; VMX: conditional cache flushes, SMT vulnerable
  Type: mds mitigation: Clear CPU buffers; SMT vulnerable
  Type: meltdown mitigation: PTI
  Type: mmio_stale_data mitigation: Clear CPU buffers; SMT vulnerable
  Type: retbleed mitigation: IBRS
  Type: spec_store_bypass mitigation: Speculative Store Bypass disabled via prctl and seccomp
  Type: spectre_v1 mitigation: usercopy/swapgs barriers and __user pointer sanitization
  Type: spectre_v2 mitigation: IBRS, IBPB: conditional, RSB filling, PBRSB-eIBRS: Not affected
  Type: srbds status: Not affected
  Type: tsx_async_abort mitigation: Clear CPU buffers; SMT vulnerable
Graphics:
  Device-1: NVIDIA GP107GL [Quadro P1000] driver: N/A alternate: nouveau non-free: 525.xx+
    status: current (as of 2022-12) arch: Pascal code: GP10x process: TSMC 16nm built: 2016-21 pcie:
    gen: 1 speed: 2.5 GT/s lanes: 16 link-max: gen: 3 speed: 8 GT/s bus-ID: 65:00.0
    chip-ID: 10de:1cb1 class-ID: 0300
  Display: server: X.org v: 1.21.1.6 driver: N/A tty: 215x45
  API: OpenGL Message: GL data unavailable in console. Try -G --display
Audio:
  Device-1: Intel 200 Series PCH HD Audio vendor: Lenovo driver: snd_hda_intel v: kernel
    bus-ID: 00:1f.3 chip-ID: 8086:a2f0 class-ID: 0403
  Device-2: NVIDIA GP107GL High Definition Audio driver: snd_hda_intel v: kernel pcie: gen: 1
    speed: 2.5 GT/s lanes: 16 link-max: gen: 3 speed: 8 GT/s bus-ID: 65:00.1 chip-ID: 10de:0fb9
    class-ID: 0403
  Sound API: ALSA v: k5.15.89-1-MANJARO running: yes
  Sound Interface: sndio v: N/A running: no
  Sound Server-1: JACK v: 1.9.21 running: no
  Sound Server-2: PulseAudio v: 16.1 running: no
  Sound Server-3: PipeWire v: 0.3.64 running: no
Network:
  Device-1: Intel Ethernet I219-LM vendor: Lenovo driver: e1000e v: kernel port: N/A
    bus-ID: 00:1f.6 chip-ID: 8086:15b7 class-ID: 0200
  IF: enp0s31f6 state: up speed: 1000 Mbps duplex: full mac: <filter>
Drives:
  Local Storage: total: 476.94 GiB used: 198.57 GiB (41.6%)
  SMART Message: Required tool smartctl not installed. Check --recommends
  ID-1: /dev/sda maj-min: 8:0 vendor: SanDisk model: SD9SB8W512G1001 size: 476.94 GiB
    block-size: physical: 512 B logical: 512 B speed: 6.0 Gb/s type: SSD serial: <filter> rev: 4001
    scheme: GPT
Partition:
  ID-1: / raw-size: 268.55 GiB size: 263.28 GiB (98.04%) used: 198.57 GiB (75.4%) fs: ext4
    dev: /dev/sda5 maj-min: 8:5
  ID-2: /boot/efi raw-size: 427.3 MiB size: 426.5 MiB (99.80%) used: 300 KiB (0.1%) fs: vfat
    dev: /dev/sda7 maj-min: 8:7
Swap:
  Kernel: swappiness: 60 (default) cache-pressure: 100 (default)
  ID-1: swap-1 type: partition size: 37.11 GiB used: 0 KiB (0.0%) priority: -2 dev: /dev/sda6
    maj-min: 8:6
Sensors:
  System Temperatures: cpu: 31.0 C mobo: N/A
  Fan Speeds (RPM): N/A
Info:
  Processes: 197 Uptime: 12m wakeups: 0 Memory: 31.01 GiB used: 656.1 MiB (2.1%) Init: systemd
  v: 252 default: graphical tool: systemctl Compilers: gcc: 12.2.1 clang: 15.0.7 Packages:
  pm: pacman pkgs: 1870 libs: 375 tools: pamac,yay Shell: fish v: 3.6.0 default: Bash v: 5.1.16
  running-in: tty 2 inxi: 3.3.24


output of sudo mhwd-kernel -li

e[32mCurrently running:e[0m 5.15.89-1-MANJARO (linux515)
The following kernels are installed in your system:
   * linux515
   * linux519
   * linux61

Hi @emilbebri,

I suspect you’ll have to boot into a live environment, from there entering a chroot environment, install the 5.15 kernel, remove the graphics driver for Nvidia, and try again.


How to chroot

  1. Ensure you’ve got a relatively new ISO or at least one with a still supported LTS kernel.

  2. Write/copy/dd the ISO to a USB thumb drive.

  3. When done, boot with the above mentioned USB thumb drive into the live environment.

  4. Once booted, open a terminal and enter the following command to enter the chroot encironment:

manjaro-chroot -a
  1. If you have more than one Linux installation, select the correct one to use from the list provided.

When done, you should now be in the chroot environment.

But, be careful, as you’re now in an actual root environment on your computer, so any changes you make will persist after a restart.

From the chroot environment, please run the following and provide the output:

mhwd-kernel --listinstalled
mhwd --list

:bangbang: Tip: :bangbang:

When posting terminal output, copy the output and paste it here, wrapped in three (3) backticks, before AND after the pasted text. Like this:

```
pasted text
```

Or three (3) tilde signs, like this:

~~~
pasted text
~~~

This will just cause it to be rendered like this:

Sed
sollicitudin dolor
eget nisl elit id
condimentum
arcu erat varius
cursus sem quis eros.

Instead of like this:

Sed sollicitudin dolor eget nisl elit id condimentum arcu erat varius cursus sem quis eros.

Alternatively, paste the text you wish to format as terminal output, select all pasted text, and click the </> button on the taskbar. This will indent the whole pasted section with one TAB, causing it to render the same way as described above.

Thereby increasing legibility thus making it easier for those trying to provide assistance.

For more information, please see:


:bangbang::bangbang: Additionally

If your language isn’t English, please prepend any and all terminal commands with LC_ALL=C. For example:

LC_ALL=C bluetoothctl

This will just cause the terminal output to be in English, making it easier to understand and debug.

5.19 is long EOL now, all related packages have been removed from the repositories.


That command installs non-free graphical drivers for all installed kernels – unless the package is not available, obviously. It does not install kernels.
Also you already have 5.15 installed.


Simply boot on your 5.15 or 6.1 kernel, remove the 5.19, and update.

I know - I installed 515, not with that command but with mhwd-kernel. What I tried to say was that I also tried to reinstall the nvidia drivers by doing that.

I have removed 519 and booted into 515 (which I was also in before), but that does not fix it.

I don’t understand - I already have the 515 kernel installed. Why would it help installing it from a live envir?

you dont have any drivers installed…
post output from:
mhwd -l -li
pacman -Qs nvidia

ok interesting thanks for spotting that!

I would have thought

sudo mhwd -a pci nonfree 0300

took care of that.

output:

mhwd -l -li

e[1me[31m> e[mInstalled PCI configs:
--------------------------------------------------------------------------------
                  NAME               VERSION          FREEDRIVER           TYPE
--------------------------------------------------------------------------------
          video-nvidia            2021.12.18               false            PCI


e[1me[31mWarning: e[mNo installed USB configs!
e[1me[31m> e[m0000:65:00.0 (0300:10de:1cb1) Display controller nVidia Corporation:
--------------------------------------------------------------------------------
                  NAME               VERSION          FREEDRIVER           TYPE
--------------------------------------------------------------------------------
          video-nvidia            2021.11.04               false            PCI
    video-nvidia-470xx            2021.11.04               false            PCI
    video-nvidia-390xx            2021.11.26               false            PCI
           video-linux            2018.05.04                true            PCI
     video-modesetting            2020.01.13                true            PCI
            video-vesa            2017.03.12                true            PCI

pacman -Qs nvidia

local/egl-wayland 2:1.1.11-2
    EGLStream-based Wayland external platform
local/lib32-nvidia-utils 525.85.05-1
    NVIDIA drivers utilities (32-bit)
local/libvdpau 1.5-1
    Nvidia VDPAU library
local/libxnvctrl 525.85.05-1
    NVIDIA NV-CONTROL X extension
local/mhwd-nvidia 525.85.05-1
    MHWD module-ids for nvidia 525.85.05
local/mhwd-nvidia-390xx 390.157-1
    MHWD module-ids for nvidia 390.157
local/mhwd-nvidia-470xx 470.161.03-1
    MHWD module-ids for nvidia 470.161.03
local/nvidia-utils 525.85.05-1
    NVIDIA drivers utilities

you dont have installed linux515-nvidia, which should be installed when you ran the mhwd nonfree command…
post also output from:
mhwd-kernel -li

1 Like

That did it!! installed linux515-nvidia and we are back. Thank you so much, have a great day! Cheers from Copenhagen, Denmark.

This topic was automatically closed 2 days after the last reply. New replies are no longer allowed.