> For the complete documentation index, see [llms.txt](https://docs.cloudeka.ai/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.cloudeka.ai/deka-gpu-documentations/panduan-untuk-enterprise/troubleshooting/nvidia-driver-not-detected-after-upgrade-kernel.md).

# Driver NVIDIA Tidak Terdeteksi Setelah Upgrade Kernel

{% hint style="warning" %}
Panduan ini digunakan jika driver NVIDIA tidak terdeteksi setelah upgrade kernel.
{% endhint %}

Sebelum pembaruan kernel, driver NVIDIA berhasil diinstal menggunakan berkas `NVIDIA-Linux-x86_64-550.54.14-grid.run`. Saat menjalankan perintah `nvidia-smi`, driver masih terdeteksi pada sistem komputer Anda.

<figure><img src="https://753761090-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FtAYQyBIz2BclZ3ZHHlS4%2Fuploads%2Fgit-blob-df9a7dd89d90cc0fb868a8d25b8b00b2f1301f45%2Fimage.png?alt=media" alt=""><figcaption><p>nvida-smi</p></figcaption></figure>

Namun, setelah pembaruan kernel, instalasi ulang menggunakan `NVIDIA-Linux-x86_64-550.54.14-grid.run` gagal.

<figure><img src="https://753761090-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FtAYQyBIz2BclZ3ZHHlS4%2Fuploads%2Fgit-blob-a7157099ee7860ca88ae0ebd21f49b8fbd4914bb%2Fimage.png?alt=media" alt=""><figcaption><p>Error</p></figcaption></figure>

<figure><img src="https://753761090-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FtAYQyBIz2BclZ3ZHHlS4%2Fuploads%2Fgit-blob-2bb796f8f41e51000932126d4cdcca78a7e64ba3%2Fimage.png?alt=media" alt=""><figcaption><p>Error</p></figcaption></figure>

Pada kasus ini, driver NVIDIA tidak terdeteksi. Ikuti beberapa langkah berikut untuk mengatasinya.

## Menghapus Instalasi Driver NVIDIA

Pertama, hapus paket NVIDIA yang sebelumnya terinstal. Perintah berikut menghapus seluruh paket terkait NVIDIA dari sistem.

```bash
sudo apt-get remove nvidia*
```

Perintah berikut menghapus seluruh paket library terkait NVIDIA dari sistem.

```bash
sudo apt-get remove libnvidia*
```

Perintah berikut membersihkan paket yang tidak lagi diperlukan setelah paket NVIDIA dihapus.

```bash
sudo apt-get autoremove
```

Perintah berikut menampilkan daftar paket terkait NVIDIA yang masih terinstal. Gunakan untuk memastikan semua paket telah dihapus atau mengidentifikasi paket yang tersisa.

```bash
dpkg -l | grep nvidia
```

Perintah berikut menghapus paket `libnvidia-compute-550:amd64` dari sistem. Gunakan untuk menghapus versi library NVIDIA tertentu saat terjadi konflik atau masalah kompatibilitas.

```bash
sudo apt-get remove libnvidia-compute-550:amd64
```

## Menginstal Ulang Driver NVIDIA

Selanjutnya, instal ulang driver NVIDIA pada komputer Anda.

```bash
sudo ./NVIDIA-Linux-x86_64-550.54.14-grid.run
```

## Memulai Ulang Layanan

Kemudian, mulai ulang layanan yang digunakan.

```bash
sudo systemctl restart nvidia-gridd.service
sudo systemctl status nvidia-gridd.service
nvidia-smi
```

## Pencegahan

Untuk mencegah masalah ini terjadi kembali, tahan pembaruan kernel.

#### 1. **Memeriksa Versi Kernel Saat Ini**

Jalankan perintah berikut di terminal untuk memeriksa versi kernel aktif.

```bash
uname -r
```

**Contoh keluaran**

<figure><img src="https://lh7-rt.googleusercontent.com/docsz/AD_4nXdttirV9m4r5RlHxjmUNaU32CIRPGT_xeZ9ZBucvugPr7PayV-ZvJ0erdNBD92JwCqK0aqyqEYOoFwAQ80F1R_TUG_JrEBJPTbPdsfbZUXJ_zkBDWpHB-FeuTJyOVY5D0bWW_lVTlsvlGGtghkatkQ?key=k7F6zkDwbRDarUABscjeWnS8" alt=""><figcaption></figcaption></figure>

#### 2. **Melihat Kernel yang Terinstal**

Untuk melihat semua kernel yang terinstal pada sistem, gunakan perintah berikut.

```bash
dpkg --list | grep linux-image
```

**Contoh keluaran**

<figure><img src="https://lh7-rt.googleusercontent.com/docsz/AD_4nXd2SRR6k4LSB4uotObzpm7GUuuDGzhe99bIHcFSG0sZWdem5YJ4wNSmZdo9CgcMKxZ9V0uVVWIiMWZKsU_Klzld-tXL-uZG_JEC3v9_RxYkCsjzxH1bVXGXJZc3G7AebbQALtXPuPFJsrvgk-eYln4?key=k7F6zkDwbRDarUABscjeWnS8" alt=""><figcaption></figcaption></figure>

#### 3. **Menahan Pembaruan Kernel**

Tahan upgrade kernel menggunakan perintah berikut. Sesuaikan versinya dengan kernel yang terinstal.

```bash
sudo apt-mark hold linux-image-5.15.0-56-generic
```

<figure><img src="https://lh7-rt.googleusercontent.com/docsz/AD_4nXdw5KIIdAMziZDnp73TBWNBR7HGf6XSQmuyE30ZcBa7CJMteiDQwAvbUNRElfvK4cmX4DHIwcHpk6DZ-bqEpYG6hBf2412p9pisat-2CFahbp-2A9u4_UjEnSlZW9f2rpUn-fDtEfmBNuObEjOpqB4?key=k7F6zkDwbRDarUABscjeWnS8" alt=""><figcaption><p>Menahan pembaruan kernel</p></figcaption></figure>

```bash
sudo apt-mark hold linux-image-virtual
```

<figure><img src="https://lh7-rt.googleusercontent.com/docsz/AD_4nXcuuUjMrVpScz2Y4b6RHPyVKGJpq2Y0ZEU_UR7ll_ZtXR0SO2nTfgkphe52UWxN5hEZY3HsLTMjchGnaeuFGmuyJpby8_mP4th5ByzrpcZdGeo1iEFuN4-XmYpdFgKJlG-9R-ifXKVRhxMh15bVl7U?key=k7F6zkDwbRDarUABscjeWnS8" alt=""><figcaption><p>Menahan pembaruan kernel</p></figcaption></figure>
