🚩[GPU Driver 충돌] Nouveau Kernel Driver 제거

2023. 12. 27. 18:04·💻 Server/Linux

🚩 Nouveau Kernel Driver 제거

Ubuntu 22.04 LTS 버전에서 Nvidia Graphic Driver & Cuda Toolkit & OpenGL 설치 중 에러를 만났습니다.

이미 존재하는 nouveau 커널 드라이버와 설치하려는 그래픽 드라이버와 충돌이 나서 Installation이 자꾸 실패합니다.

로그를 보면 Nouveau Kernel Driver가 현재 사용 중 이라고 뜨고 있습니다.

$ cat /var/log/nvidia-installer.log
nvidia-installer log file '/var/log/nvidia-installer.log'
installer version: 535.75

PATH: /usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/snap/bin

nvidia-installer command line:
    ./nvidia-installer

Using: nvidia-installer ncurses v6 user interface
-> Detected 32 CPUs online; setting concurrency level to 32.
-> Installing NVIDIA driver version 535.75
ERROR: The Nouveau kernel driver is currently in use by your system.  This driver is incompatible with the NVIDIA driver, and must be disabled before proceeding.  Please consult the NVIDIA driver README and your Linux distribution's documentation for details on how to correctly disable the Nouveau kernel driver.
-> For some distributions, Nouveau can be disabled by adding a file in the modprobe configuration directory.  Would you like nvidia-installer to attempt to create this modprobe file for you? (Answer: No)
ERROR: Installation has failed.  Please see the file '/var/log/nvidia-installer.log' for details.  You may find suggestions on fixing installation problems in the README available on the Linux driver download page at www.nvidia.com.

nouveau 커널 드라이버는 GPU 코어의 온도를 확인하여 GPU Fan을 작동하고 온도 경고를 설정하는 커널 드라이버입니다.

lsmod로 확인해봐도 nouveau 모듈이 동작 중입니다.

$ lsmod | grep -i nouveau
nouveau              1949696  1
video                  49152  2 asus_wmi,nouveau
ttm                   106496  1 nouveau
drm_kms_helper        184320  1 nouveau
mxm_wmi                16384  1 nouveau
drm                   491520  4 drm_kms_helper,ttm,nouveau
i2c_algo_bit           16384  2 igb,nouveau
wmi                    32768  5 intel_wmi_thunderbolt,asus_wmi,wmi_bmof,mxm_wmi,nouveau

검색해본 결과 Nvidia GPU Driver를 설치 하려면 이 커널 드라이버를 제거하고 다시 실행되지 않도록 modprobe 블랙리스트에 추가해야 합니다.


우선 Nvidia 관련 패키지를 제거합니다.

$ sudo apt -y remove nvidia* && sudo apt -y autoremove

컴파일러와 Linux Header, GPU Driver를 설치하기 위한 종속성 패키지들을 설치 해 줍니다.

$ sudo apt -y install dkms build-essential linux-headers-generic pkg-config libglvnd-dev

nouveau 드라이버를 블랙리스트에 등록하여 활성화되지 않도록 합니다.

$ sudo echo -e "blacklist nouveau\nblacklist lbm-nouveau\noptions nouveau modeset=0\nalias nouveau off\nalias lbm-nouveau off" | sudo tee -a /etc/modprobe.d/blacklist.conf

initramfs를 업데이트하고 서버를 재기동합니다.

$ sudo update-initramfs -u
$ reboot

이제 다시 GPU Driver를 설치하고 nvidia-smi를 입력하면 잘 나오는 것을 확인할 수 있습니다.

저작자표시 (새창열림)

'💻 Server > Linux' 카테고리의 다른 글

Redmine <-> NAS CIFS-Mount  (2) 2024.11.20
Prometheus & Grafana - Metric Monitoring  (0) 2024.06.21
CronTab - Application Health Check  (0) 2024.05.23
Linux Graphic Driver & Remote GUI를 위한 TigerVNC 설정  (2) 2024.03.18
🚩 Headless OpenGL Rendering Error (TigerVNC & X11)  (4) 2024.01.24
'💻 Server/Linux' 카테고리의 다른 글
  • Prometheus & Grafana - Metric Monitoring
  • CronTab - Application Health Check
  • Linux Graphic Driver & Remote GUI를 위한 TigerVNC 설정
  • 🚩 Headless OpenGL Rendering Error (TigerVNC & X11)
신건우
신건우
조용한 개발자
  • 신건우
    우주먼지
    신건우
  • 전체
    오늘
    어제
    • 분류 전체보기 (422)
      • 📘 Frontend (71)
        • Markup (1)
        • Style Sheet (2)
        • Dart (8)
        • Javascript (12)
        • TypeScript (1)
        • Vue (36)
        • React (2)
        • Flutter (9)
      • 📘 Backend (143)
        • Java (34)
        • Concurrency (19)
        • Reflection (1)
        • Kotlin (29)
        • Python (1)
        • Spring (42)
        • Spring Cloud (5)
        • Message Broker (5)
        • Streaming (2)
        • 기능 개발 (5)
      • 💻 Server (6)
        • Linux (6)
      • ❌ Error Handling (11)
      • 📦 Database (62)
        • SQL (31)
        • NoSQL (2)
        • JPQL (9)
        • QueryDSL (12)
        • Basic (4)
        • Firebase (4)
      • ⚙️ Ops (57)
        • CS (6)
        • AWS (9)
        • Docker (8)
        • Kubernetes (13)
        • MSA (1)
        • CI & CD (20)
      • 📚 Data Architect (48)
        • Data Structure (10)
        • Algorithm (8)
        • Programmers (17)
        • BaekJoon (5)
        • CodeUp (4)
        • Design Pattern (4)
        • AI (0)
      • ⚒️ Management & Tool (8)
        • Git (7)
        • IntelliJ (1)
      • 📄 Document (10)
        • Project 설계 (6)
        • Server Migration (3)
      • 📄 책읽기 (2)
        • 시작하세요! 도커 & 쿠버네티스 (2)
      • 🎮 Game (4)
        • Stardew Vally (1)
        • Path of Exile (3)
  • 블로그 메뉴

    • 링크

      • Github
    • 공지사항

    • 인기 글

    • 태그

      React #Markdown
      Lock #Thread #Concurrency
      GStreamer #Pipeline
    • 최근 댓글

    • 최근 글

    • hELLO· Designed By정상우.v4.10.0
    신건우
    🚩[GPU Driver 충돌] Nouveau Kernel Driver 제거
    상단으로

    티스토리툴바