Jump to content

Mac Mini 2014 - CPU while transcoding


bigembyfan

Recommended Posts

bigembyfan

Hi there,

 

I've had a search through the forums and seen things here and there about the transcoding settings and potential hardware transcoding options to ease the burden on the cpu of a mac running Emby Server but haven't managed to solve my issues unfortunately.

 

I run Emby server on a 2014 Mac Mini (2.6ghz i5, 8gb ram, 1TB HDD one), things are set up well but if I watch any file that needs transcoding the CPU in activity monitor can stay consistently at 275 - 325% all for ffmpeg (I mainly have MKV files but also happens for some pre-processed mp4s from Handbrake). I also have HD Homerun for live tv in Emby and the cpu values seen watching that are usually much lower, around 85% - 95%.

 

Unsurprisingly, occasionally my Mac can be radioactively hot and can only assume that it's not a great idea for me to be running Emby Server and using clients that need transcoding when the CPU can ramp up to ~300%, eg my iphone or android tablet on my commute. Using a Pi + Kodi for my tv, it copes better but I have to remember to power down the Pi as sometimes I've woken up the following day to find my Mac sounding like it's ready for take off, which I assumed was Kodi / Emby Server not killing a service of some sort.

 

I have messed around with the settings a little but it's a bit like monkeys writing Shakespeare, I don't really have much of a clue and unfortunately I've not succeeded in improving anything yet.

 

Checking the advanced settings in the transcoding page in the admin, I have one option in the Hardware Encoders but nothing available in the Hardware Decoders.

 

I'm a novice to the processor / transcoding side things and wondered if I'm stuck with this situation? I've tried to search around but not finding any concrete "ah you just need to do this" or "nope, not a great idea to run it on that". If it's the latter I'm considering an i7 NUC but would obviously be happy if I've missed something and there's solution or setting or something bios / setup wise I can do. I don't however want to burn out the mac as it's useful for managing my phone with iTunes and I also occasionally build iOS apps with it, it's not my main machine but it's my only mac os one.

 

If logs help, just let me know and I can try and get some added.

Edited by bigembyfan
Link to comment
Share on other sites

Hi, I would try leaving the settings at default. But what is your question here? Have you confirmed that your machine is capable of on the fly transcoding of your media? 

 

We do have Emby apps that can direct play more formats without transcoding, such as our android and iOS apps, and others. Have you tried those?

Link to comment
Share on other sites

bigembyfan

Hi Luke, thanks for the reply and apologies if you felt the question was vague. 

 

The Mac can transcode on the fly but the CPU is through the roof and it invariably overheats badly so I'm a little wary that it'll fry it. So basically, the question was to ask if there was any settings or tweaks I can make to the Mac Mini or to the Emby settings to transcode the files without such a high CPU (~300%)? I'm probably clutching at straws and the mac is too limited for the job that I should try and encode the videos with Handbrake to a lower quality mp4 and turn off transcoding?

 

I have the Android app on my tablet, the iOS app on my phone + iPad, Emby Kodi plugin on a Pi and browser access on my pc + laptop. All but the Pi play on the fly transcoding and cause the CPU to go into overdrive, could this be caused by the wifi connection if they should all be able to direct play? The files are mainly DVD ripped mkvs but also a couple of BluRay mkvs. 

Edited by bigembyfan
Link to comment
Share on other sites

mrfragger

 

 

I have the Android app on my tablet, the iOS app on my phone + iPad, Emby Kodi plugin on a Pi and browser access on my pc + laptop. All but the Pi play on the fly transcoding and cause the CPU to go into overdrive, could this be caused by the wifi connection if they should all be able to direct play?

 

The main reason I went with Emby rather than Plex was I believe only in Emby can you turn off transcoding.  I don't want it at all.  I have a 2012 Mac Mini.  I've encoded all my .avi files to h265 mkv files with handbrake or at least I'm in the process of doing so.  Also set Emby to download external .SRT subtitles rather than using the embedded ones.  This eliminates any transcoding on-the-fly completely. For playback I use an Nvidia Shield.  Have no problem playing 4K h265 x265 media but mostly it's 1080p or 720p.

 

For handbrake I set FAST 1080p 30fps peak 96kpbs OPUS audio.

 

Under the User settings:

Allow media playback

Allow audio playback that requires transcoding

Allow video playback that requires transcoding

Allow video playback that requires conversion without re-encoding

 

I only enable the first one (allow media playback).  

If I ever get unable to play then I know that set of videos needs to be encoded to x265 in an mkv or mp4 container.

 

For a browser on a laptop sometimes you can use Chrome but subtitles sometimes creates problems but they were working on HLS streaming subtitles so that may have solved that issue. Ok yea it seems Chrome can play mkv and mp4 with subtitles and no transcoding.  Firefox and Safari can't at least not mkv I believe. I think the only issue with Chrome is mkv with DTS audio.  Other audio streams aren't an issue.

Edited by mrfragger
Link to comment
Share on other sites

bigembyfan

Cheers for all that mrfragger - really helpful. I'll give that a go and see how I get on after that. That makes sense with those settings, will try those Handbrake settings to generate the new files.

Link to comment
Share on other sites

That may not actually help you because it may cause playback problems if you force a direct play when it isn't actually supported. Please let us know how you get on.

 

Regarding cpu usage, that's just the way the ffmpeg transcoder works, it will go as fast as it can. We do have a throttle feature that will slow it down when the transcoding position gets far enough ahead of your watching position. If this is never happening for you, then it's possible your cpu might not be fast enough for this to happen.

Link to comment
Share on other sites

mrfragger

yea after more and more tests with the Chrome browser it's hit or miss.  So yeah if you want browser playback you need transcoding.  I don't need it so I avoid transcoding altogether.  

Link to comment
Share on other sites

bigembyfan

That may not actually help you because it may cause playback problems if you force a direct play when it isn't actually supported. Please let us know how you get on.

 

Regarding cpu usage, that's just the way the ffmpeg transcoder works, it will go as fast as it can. We do have a throttle feature that will slow it down when the transcoding position gets far enough ahead of your watching position. If this is never happening for you, then it's possible your cpu might not be fast enough for this to happen.

 

Ah I didnt know that there should be a drop off, I will check this and see how soon it drops off in different scenarios and what it drops too. Thanks for that

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...