this post was submitted on 07 May 2024
68 points (91.5% liked)

Selfhosted

40006 readers
574 users here now

A place to share alternatives to popular online services that can be self-hosted without giving up privacy or locking you into a service you don't control.

Rules:

  1. Be civil: we're here to support and learn from one another. Insults won't be tolerated. Flame wars are frowned upon.

  2. No spam posting.

  3. Posts have to be centered around self-hosting. There are other communities for discussing hardware or home computing. If it's not obvious why your post topic revolves around selfhosting, please include details to make it clear.

  4. Don't duplicate the full text of your blog or github here. Just post the link for folks to click.

  5. Submission headline should match the article title (don’t cherry-pick information from the title to fit your agenda).

  6. No trolling.

Resources:

Any issues on the community? Report it using the report flag.

Questions? DM the mods!

founded 1 year ago
MODERATORS
 

Hey everyone, I'm building a new server to run Jellyfin (with a few other services like Pi-hole) and I'm stuck on GPU or CPU transcoding.

My main concern is smooth 4K HDR transcoding for 1 stream. I've been reading mixed advice online – some people say a strong CPU with good single-core performance can handle it, while others recommend a dedicated GPU.

Should I focus my budget (~$1000AUD/$658USD) on a good CPU, or spend some of it on a dedicated GPU?

top 50 comments
sorted by: hot top controversial new old
[–] [email protected] 1 points 6 months ago

Well it isn't really CPU vs GPU. It is integrated vs dedicated GPU. A CPU certainly can transcode, but not well. A lot of CPUs have integrated graphics which can handle transcoding quite well. I went with an Intel arc a380 because I know quite a lot of people could hit it under some circumstances. For most people though, I would recommend an Intel CPU with quicksync. What you really should spend your budget on IMO is as much storage as you can.

[–] [email protected] 2 points 6 months ago

My current setup:

  • one stream using CPU transcoding, Intel Xeon E2246G
  • six streams using GPU transcoding, Nvidia Tesla P4
[–] [email protected] 2 points 6 months ago (1 children)

I have no idea what the people who recommend CPU are smoking. The difference between a GPU with hardware support and doing it on the CPU is huge.

[–] [email protected] 6 points 6 months ago

It’s really not, like at all. QuickSync is fast af and overkill for almost any usecase.

[–] [email protected] 16 points 6 months ago

GPU all the way as it will be more efficient. Keep in mind Intel integrated graphics counts as a GPU

[–] [email protected] 2 points 6 months ago

If only 1 person will watch at any given time, cpu is plenty

[–] [email protected] 2 points 6 months ago (1 children)

My optiplex with i5-6500TE can transcode 4K videos easily if the codec is AVC. HEVC is different story though. Any CPU newer than 10th generation would be more than enough for your needs, I'd say.

[–] [email protected] 3 points 6 months ago (1 children)
[–] [email protected] 1 points 6 months ago

6th gen's integrated GPU cannot decode HEVC.

[–] [email protected] 25 points 6 months ago (1 children)

Intel Quicksync would do it, no need for a dedicated GPU.

[–] [email protected] 7 points 6 months ago

The easiest and cheapest solution is don’t allow transcoding.

The easiest way to do that is separate your 720/1080p videos from your 4k videos. Limit 4k access to the users that can play 4k

[–] [email protected] 2 points 6 months ago (1 children)

Setups for hardware decoding are based on the underlying OS. An example quite common is docker on Debian or Ubuntu. You will need to pass the appropriate /dev/ directories and at times files into your jellyfin docker container with the device environment variable. Commonly that would be /dev/dri

It gets more complicated with a vm because you are likely going to be passing the hardware directly into the vm which will prevent other devices outside the vm from using it.

You can get around this by placing docker directly on the os or placing docker in a Linux container with appropriate permissions and the same devices passed into the Linux container. In this manner system devices and other services will still have access the the video card.

All this to say it depends on your setup and where you have docker installed how you will pass the hardware into jellyfin. However jellyfin on docker will need you to pass the video card into the container with the device environment variable. Docker will need to see the device to be able to do that.

[–] [email protected] 2 points 6 months ago (1 children)

I've been using podman due to its low overhead.

[–] [email protected] 3 points 6 months ago

Nothing but love for that project. I've been using docker-ce and docker-compse. I had portainer-ce but just got tired of it. It's easier for me to just make a compose file and get things working exactly like I want.

load more comments
view more: next ›