nvidia-driver install

Jinha Song·2020년 12월 20일
1

Guides

목록 보기
2/2
  • 본 문서는 nvidia-driver의 설치 방법을 설명하는 문서이다.

Check information of graphic card

sudo lshw -C display

# Result
# - GTX 1080 Ti
  *-display                 
       description: VGA compatible controller
       product: GP102 [GeForce GTX 1080 Ti]
       vendor: NVIDIA Corporation
       physical id: 0
       bus info: pci@0000:01:00.0
       version: a1
       width: 64 bits
       clock: 33MHz
       capabilities: pm msi pciexpress vga_controller bus_master cap_list rom
       configuration: driver=nvidia latency=0
       resources: irq:145 memory:ee000000-eeffffff memory:c0000000-cfffffff memory:d0000000-d1ffffff ioport:e000(size=128) memory:c0000-dffff
# - GTX Titan X
  *-display                 
       description: VGA compatible controller
       product: GM200 [GeForce GTX TITAN X]
       vendor: NVIDIA Corporation
       physical id: 0
       bus info: pci@0000:01:00.0
       version: a1
       width: 64 bits
       clock: 33MHz
       capabilities: pm msi pciexpress vga_controller bus_master cap_list rom
       configuration: driver=nvidia latency=0
       resources: irq:16 memory:de000000-deffffff memory:c0000000-cfffffff memory:d0000000-d1ffffff ioport:e000(size=128) memory:c0000-dffff
# - GTX Titan Xp
  *-display                 
       description: VGA compatible controller
       product: GP102 [TITAN Xp]
       vendor: NVIDIA Corporation
       physical id: 0
       bus info: pci@0000:01:00.0
       version: a1
       width: 64 bits
       clock: 33MHz
       capabilities: pm msi pciexpress vga_controller bus_master cap_list rom
       configuration: driver=nvidia latency=0
       resources: irq:158 memory:ee000000-eeffffff memory:d0000000-dfffffff memory:e0000000-e1ffffff ioport:e000(size=128) memory:c0000-dffff
# - RTX Titan
  *-display                 
       description: VGA compatible controller
       product: TU102 [TITAN RTX]
       vendor: NVIDIA Corporation
       physical id: 0
       bus info: pci@0000:17:00.0
       version: a1
       width: 64 bits
       clock: 33MHz
       capabilities: pm msi pciexpress vga_controller bus_master cap_list rom
       configuration: driver=nvidia latency=0
       resources: irq:135 memory:b4000000-b4ffffff memory:a0000000-afffffff memory:b0000000-b1ffffff ioport:7000(size=128) memory:b5000000-b507ffff
# - RTX 3090
  *-display                 
       description: VGA compatible controller
       product: NVIDIA Corporation
       vendor: NVIDIA Corporation
       physical id: 0
       bus info: pci@0000:01:00.0
       version: a1
       width: 64 bits
       clock: 33MHz
       capabilities: pm msi pciexpress vga_controller bus_master cap_list rom
       configuration: driver=nvidia latency=0
       resources: irq:16 memory:74000000-74ffffff memory:60000000-6fffffff memory:70000000-71ffffff ioport:4000(size=128) memory:75000000-7507ffff

Install nvidia-driver via apt

Add apt repository

sudo add-apt-repository ppa:graphics-drivers/ppa
sudo apt update

List of nvidia-driver versions that match CUDA version

CUDA ToolkitNVIDIA-driver
11.7.xnvidia-driver-515
11.6.xnvidia-driver-510
11.5.xnvidia-driver-495
11.4.xnvidia-driver-470
11.3.1nvidia-driver-465
11.2nvidia-driver-460
11.1nvidia-driver-455
11.0nvidia-driver-450
10.2nvidia-driver-440
10.1nvidia-driver-418
10.0nvidia-driver-410
9.2nvidia-driver-410
9.1nvidia-driver-396
9.0nvidia-driver-384
8.0.61nvidia-driver-375
8.0.44nvidia-driver-367
7.5nvidia-driver-352
7.0nvidia-driver-346

Check nvidia-driver version in apt list

apt-cache search nvidia | grep nvidia-driver-${VERSION_NUMBER}
# Result
nvidia-driver-xxx - NVIDIA driver metapackage

Install nvidia-driver

sudo apt install -y nvidia-driver-xxx
sudo reboot

Monitor nvidia driver

watch nvidia-smi

주의사항

  • 간혹 설치 중 display manager와 충돌이 발생하여 부팅이 안되거나 nvidia-smi 가 정상적으로 실행되지 않을 경우가 있기 때문에 반드시 아래 명령어로 gdm(gnome display manager) 서버시를 멈추고 설치를 실행한다.
sudo service gdm stop
profile
Jinha Song

0개의 댓글