ABOUT ME

-

Today
-
Yesterday
-
Total
-
  • [Linux]ERROR: The nvidia kernel module was not created.
    linux/오류해결 2024. 7. 16. 08:53

     

    CentOS 7에서 NVIDIA 드라이버를 업데이트하는 과정을 단계별로 설명해드리겠습니다:

    1. 현재 드라이버 제거: 먼저 기존 드라이버를 제거해야 합니다.
      sudo yum remove nvidia*
    2. NVIDIA 저장소 추가:
    3. 저장소 캐시 업데이트:
      sudo yum clean all sudo yum makecache
    4. 필요한 패키지 설치:
      sudo yum install kernel-devel kernel-headers gcc make dkms acpid libglvnd-glx libglvnd-opengl libglvnd-devel pkgconfig
    5. 최신 NVIDIA 드라이버 설치:
      sudo yum install nvidia-driver nvidia-settings
    6. 시스템 재부팅:
      sudo reboot
    7. 설치 확인: 재부팅 후, 다음 명령어로 새 드라이버 버전을 확인하세요:
      nvidia-smi

     

    위 순서대로 드라이버 업데이트를 진행중 오류가 발생하였음

    (base) [root@localhost ~]# sudo yum remove nvidia*
     
    Loaded plugins: fastestmirror, langpacks, nvidia
    Repository base is listed more than once in the configuration
    Repository updates is listed more than once in the configuration
    Repository extras is listed more than once in the configuration
    Repository centosplus is listed more than once in the configuration
    No Match for argument: nvidia*
    No Packages marked for removal

    문제 파악

    • NVIDIA 드라이버가 설치되어 있지 않거나, 'nvidia*' 패턴과 일치하는 패키지가 없습니다.
      "No Match for argument: nvidia*" 메시지가 이를 나타냅니다.
    •  YUM 설정에 중복된 리포지토리 항목(base, updates, extras, centosplus) 이 있습니다. 
    • NVIDIA 플러그인이 YUM에 로드되어 있습니다. 이는 "Loaded plugins: fastestmirror, langpacks, nvidia" 줄에서 확인할 수 있습니다.

    해결 방안

     

    • YUM 설정 파일을 확인하고 중복된 리포지토리 항목을 제거합니다
      sudo vi /etc/yum.repos.d/CentOS-Base.repo
      이 파일에서 중복된 항목을 찾아 제거
    • NVIDIA 드라이버가 이미 제거되었거나 설치되어 있지 않은 것 같습니다. 따라서 다음 단계로 넘어가 새 드라이버를 설치할 수 있습니다.
    • YUM 캐시를 정리하고 메타데이터를 다시 생성합니다
      sudo yum clean all sudo yum makecache
    • 이 과정을 거친 후 이어서 NVIDIA 그래픽 드라이버를 설치 진행을 하면 해결!

     

     

Designed by Tistory.