Home Lab
  • Docker
    • Docker Engine
    • NVIDIA Container
  • Monitor
    • Grafana
    • Influxdb
    • Telegraf
  • Plex Server
    • Plex Media Server
    • Swizzin
    • GPU Acceleration Setup
  • RAID Array
    • How To List Disks on Linux
    • Adding a Spare Device to an Array
    • How To Create RAID Arrays with mdadm on Ubuntu 16.04
    • Deleting an Array
    • Increasing the Number of Active Devices in an Array
    • Removing a Device from an Array
  • Raspberry Pi
    • DNS Server
    • Raspberry Imager
    • Increasing SWAP on a Raspberry Pi
    • PiVPN
  • Markdown
  • Ubuntu Server 20.04 LTS
    • Ubuntu: Extend your default LVM space
    • Useful Commands
Powered by GitBook
On this page
  • Pre-setup Plex Hardware Acceleration
  • Setup Plex Hardware inside Container
  1. Plex Server

GPU Acceleration Setup

Guideline to setup Plex Hardware Acceleration function

PreviousSwizzinNextRAID Array

Last updated 1 year ago

Quadro M2000

Pre-setup Plex Hardware Acceleration

  • Pre-req for GPU offload

apt install beignet-opencl-icd
apt install ocl-icd-libopencl1
  • Install NVIDIA drivers (optional if doing GPU transcoding). Install ubuntu package to identify the drivers necessary for your particular GPU

apt install ubuntu-drivers-common 
  • List the graphics devices to get the nvidia drivers needed

ubuntu-drivers devices
  • Install latest drivers (replace xxx with driver package you want to use)

apt install nvidia-drivers-xxx 
  • After install the driver package will also install the ubuntu GUI environment, this will turn it back off. (skip this step if you want the GUI for some reason)

systemctl set-default multi-user
  • Reboot system, done !

shutdown -r now

Setup Plex Hardware inside Container

Installing the NVIDIA container toolkit

# Update apt.
sudo apt-get update

# Install the nvidia-docker2 package.
sudo apt-get install -y nvidia-docker2

# Restart Docker.
sudo systemctl restart docker

# Test the GPU with a base CUDA container.
sudo docker run --rm --gpus all nvidia/cuda:11.0.3-base-ubuntu20.04 nvidia-smi

After running all command above and installed all package, the final result should display as below

watch -n0.1 nvidia-smi

# Output
+-----------------------------------------------------------------------------+
| NVIDIA-SMI 510.73.05    Driver Version: 510.73.05    CUDA Version: 11.6     |
|-------------------------------+----------------------+----------------------+
| GPU  Name        Persistence-M| Bus-Id        Disp.A | Volatile Uncorr. ECC |
| Fan  Temp  Perf  Pwr:Usage/Cap|         Memory-Usage | GPU-Util  Compute M. |
|                               |                      |               MIG M. |
|===============================+======================+======================|
|   0  Quadro P2000        Off  | 00000000:0B:00.0 Off |                  N/A |
| 44%   31C    P8     5W /  75W |      2MiB /  5120MiB |      0%      Default |
|                               |                      |                  N/A |
+-------------------------------+----------------------+----------------------+
                                                                               
+-----------------------------------------------------------------------------+
| Processes:                                                                  |
|  GPU   GI   CI        PID   Type   Process name                  GPU Memory |
|        ID   ID                                                   Usage      |
|=============================================================================|
|  No running processes found                                                 |
+-----------------------------------------------------------------------------+

After confirming the result, we can deploy plex server following this instruction

Plex Media Server
Page cover image