With large adoption of the HEVC (x.265/H.265) codec, converting from H.264/VC-1 is becoming more and more appealing. Transcoding, on the fly, from H.264, H.265, and VC-1 can be done efficiently be accomplished in its entirety with QuickSync. It allows for a dozen+ streams, all transcoding, on a small computer worth a few hundred dollars and costing significantly less a computer and video card/GPU build. Some of the benefits of encoding in H.265:
- Significantly smaller file size footprint; anywhere from 20-50% reduction in overall size of the file;
- Half of the bitrate required for streaming/playback; when I travel and am on cellular and want to watch something from my home, over Plex, this is where the reduced footprint is obvious;
- and more uniform library with less codec variance; remove VC-1 and other less wonderful codecs.
Tdarr is a self hosted web-app used to automate media library management allowing you to make sure that your files are meet your specific needs in relation to codecs/streams/containers etc. It works in conjunction with Sonarr/Radarr with a core designed to be both customizable and scalable. You are able to set on a per library basis transcode settings, filters and schedule. Workers consist of three types including ‘general’, ‘transcode’, or ‘health check’.
Greater detail can be found: Tdarr – Audio/Video Library Analytics & Transcode/Remux Automation
Tdarr not only allows you to transcode files from and into multiple formats, but also allows:
- The use of HandBrake or FFmpeg
- Searching for files based on hundreds of properties
- Remove unwanted subtitle files
- Remove unwanted audio streams
- Transcode audio streams into a preferred format
Intel QuickSync Video is Intel’s brand for its dedicated video encoding and decoding hardware core. The name “QuickSync” refers to the use case of quickly transcoding (“converting”) a video from, for example, a DVD or Blu-ray Disc to a format appropriate to, for example, a smartphone. This becomes critically important in situations where source material may available in any number of video formats, all of which must be brought into a common format (commonly H.264/H.265) for inter-cutting.
Unlike video encoding on a CPU or a general-purpose GPU, Quick Sync is a dedicated hardware core on the processor die. This allows for much more power efficient video processing.
Further, hardware-accelerated en/decoding has come a long way. Since the release of 7th generation Intel processors, the onboard GPU & Quick Sync technology is now fierce competition with Nvidia (NVENC) GPU en/decoding. QuickSync-equipped Intel’s are bountiful, easy to get and can be found in low-power, cheap setups. This makes it super interesting to create a mostly-for-transcoding small-form computer.
The cost to use a QuickSync-enabled CPU rather than a video card is an excellent ROI. In our tests, we found our video cards added 30w+ to our machines at idle and could skyrocket during load. The reality is, using video cards for media transcoding in small volumes doesn’t make sense. We define small volume as less than 15 to 20 simultaneous transcoded streams & direct streams.
Whether you make it a Plex Server(guide-link), a Tdarr(guide-link) box, or something else(blue iris), we’ve got a list of suitable machines that you can then install Ubuntu on and get up and running. We mostly use Plex and Tdarr and so we will focus on boxes that benefit those use-cases.
Greater detail can be found here: QuickSync Box (QSB) on Budget: Hardware Transcoding
This guide assumes you will be setting up Tdarr on a never before used system.
- Install Ubuntu
- Install AutoFS
- Install Docker
- Install Portainer Docker
- Install Tdarr Docker
Before installing Ubuntu You will need to create bootable media:
- Create a bootable USB stick on macOS
- Create a bootable USB stick on Windows
- Create a bootable USB stick on Ubuntu
Once you media is prepared you can install Ubuntu: Install Ubuntu desktop
Now that we have Ubuntu installed and ready to role we need to open a terminal and set our sudo privileges on the host. Let set it for the entirety of this session using the following command:
To open a terminal window press
and once open
$ sudo -i
and now lets makes sure we have all of the latest and greatest information in our local database of software:
In the terminal window type:
Allow the operation to complete
and now lets upgrade our packages
Allow the operation to complete
AutoFS will allow us to mount network drives (via NFS) to look like local drives, and have them auto reconnect on disconnect. This will be needed when it is time to set up and access your libraries in Tdarr.
Please follow the guide located here for this install: AutoFS Setup an FStab Alternative
For our purposes we will be installing Tdarr as a docker instance. To do so we will need to first install docker within our Ubuntu environment.
- Install Docker
apt install docker.io
- Start and Automate Docker
- Start the Docker Service
systemctl start docker
- Enable docker to run at Startup
systemctl enable docker
- Verify the version of the docker install
Portainer is an open-source management interface for Docker. It makes docker management easier by allowing you to manage containers, images, networks, and volumes from a web-based dashboard. For our purposes we will install Portainer as a docker.
- Let us download the Portainer image from DockerHub using the docker pull command below:
docker pull portainer/portainer
Now we will run Portainer
docker run -d -p 9000:9000 -v /var/run/docker.sock:/var/run/docker.sock portainer/portainer
- Now we will verify that Portainer is now running as a container
- We can see that Portainer is now running under the name
- Next open your web browser and type the server IP address with port 9000. In the case of my install this will be
- Once the web page is loaded establish the user name and password for your admin account
- Now we will define the environment that Portainer will connect. For our purposes we will configure Portainer to connect to the local Docker environment. Chose the
Localenvironment and hit
8, You have now entered the Admin Dashboard for Portainer. Click on the tile labeled
You are now ready to install dockers. Whether you install a Docker in command line or within Portainer it will register in Portainer!
docker-composeis a single step operation and can be accomplished by execute this command:
apt install docker-compose
- Once it completes verify the install
Details on alternative methods can be found here: Tdarr Wiki
- Let us download the Tdarr image using the docker pull command below:
docker pull haveagitgat/tdarr_aio
- Now we will create the volume for the
docker volume create TdarrDB
- Switch Back to your home directory:
- Make a new directory for you docker-compose files:
- Enter your new directory
- Now we will create a Docker-Compose file for Tdarr. This assumes that you have followed the AutoFS Guide linked above, and requires that you know the paths you set for your shares while executing the guide.
bash nano docker-compose.yml
- Once inside this file you will paste the following:
version: "3" services: tdarr: image: haveagitgat/tdarr_aio container_name: tdarr ports: - 8265:8265 volumes: - /opt/docker/tdarr/config:/home/Tdarr/Documents/Tdarr - /opt/docker/tdarr/db:/var/lib/mongodb - /mnt/user:/home/Tdarr/media - /tmp/tdarr:/home/Tdarr/cache - /etc/localtime:/etc/localtime:ro devices: - "/dev/dri:/dev/dri" restart: unless-stopped
- Now you Save and Close by pressing
- Next we will start the docker
- Now we will stop the container by hit
CTRL+Cand head into Portainer for a few final tweaks. From this time forward all docker aspects for Tdarr will be managed in Portainer.
- To get to Portainer open a browser and navigate to you its GUI for me this is located at navigate to your
- Once you are logged in Navigate into the
localendpoint tile that we set up earlier in this guide and click on the
Containerstile and open the link to
tdarr. You are now in the container configuration.
- You will now hit the
Duplicate/Editbutton in the upper middle section of the page and scroll to the bottom where you will change the user to
- Now hit the
Deploy Containerbutton. When asked if you are sure hit yes.
- Tdarr is now installed. We will cover the configuration of Tdarr in another guide.
To discuss this post click here: https://forums.reeltalk.club/t/tdarr-install-quicksync-ubuntu/33