Jump to content

Emby transcoder fills up 32gb RAMDisk then stops playing


sittingmongoose

Recommended Posts

sittingmongoose

I am using a 32gb RAMDisk for my temporary folder for embys transcoder. But when I watch 4k movies, it fills up the drive and doesn’t delete older files. So then the transcoder stops. Plex on the other hand deletes older files to make room automatically.

 

Anyone know a solution to this?

Link to comment
Share on other sites

sittingmongoose

Yea, watching I 4k remux. Usually fills up towards the end. So watched 1:20 minetes of a 1:40 movie. By the time it got to 1:20, it filled up and failed. Those files are larger tban 50gb.

Link to comment
Share on other sites

sittingmongoose

You should use an SSD for a transcode drive. 32GB isn't very big.

I was hoping to be able to use it as its obviously much faster than an SSD.  The way Plex works, it takes out older files if it runs out of space.  Does Emby not do that?  Also, Plex only seems to use 2gb or so per stream for transcoding.

Link to comment
Share on other sites

Guest asrequested

I was hoping to be able to use it as its obviously much faster than an SSD. The way Plex works, it takes out older files if it runs out of space. Does Emby not do that? Also, Plex only seems to use 2gb or so per stream for transcoding.

But if you have one file that is bigger than the available space, how are you going to remove it? 32GB total space and a movie that's bigger than that. How are you going to remove the file while you watch it?

 

Does Plex mux in blocks, as opposed to the whole movie?

Edited by Doofus
Link to comment
Share on other sites

sittingmongoose

But if you have one file that is bigger than the available space, how are you going to remove it? 32GB total space and a movie that's bigger than that. How are you going to remove the file while you watch it?

 

Plex does it.  The movie is transcoded in chucks so the oldest chunks are discarded.  I don't have this issue with Plex transcoding 4k movies.  So obviously its possible.

Link to comment
Share on other sites

Guest asrequested

Plex does it. The movie is transcoded in chucks so the oldest chunks are discarded. I don't have this issue with Plex transcoding 4k movies. So obviously its possible.

Interesting.

Link to comment
Share on other sites

You really think the difference between a RAM and SSD disc will be noticeable in this application?  The media is being delivered at speeds well within the limits of mechanical hard drives and then over a network connection...

Link to comment
Share on other sites

Are you aware that the downfall of discarding the chunks is that if you seek back to a position that you've already watched, it will have to be transcoded all over again? Just want to make sure that you realize that. @ as well.

 

Anyway, I do agree that we can detect that there is low disk space and do some chunk recycling. Running out of disk space will cause errors so we should try to prevent that.

Link to comment
Share on other sites

Guest asrequested

That's a good point about seeking. I hadn't considered that. I chose to use an m.2 SSD for my transcode drive. So I have plenty of space. I did that, deliberately. I prefer it this way.

Link to comment
Share on other sites

sittingmongoose

Are you aware that the downfall of discarding the chunks is that if you seek back to a position that you've already watched, it will have to be transcoded all over again? Just want to make sure that you realize that. @ as well.

 

Anyway, I do agree that we can detect that there is low disk space and do some chunk recycling. Running out of disk space will cause errors so we should try to prevent that.

Yea I understand the downside. I can always choose to put the transcode folder on my ssd. I would prefer it on my RAMDisk as it’s more than 6x faster and doesn’t put tons of read writes on my ssd wearing it out. It is noticeably snappier on ram than my ssds, I think my raid controller doesn’t like ssds.

Link to comment
Share on other sites

sittingmongoose

Unfortunately I can’t. I’m out of funds as I just built this server. Plus I’m moving this weekend. But I don’t have m.2 slots nor do I have any free pci e slots.

Link to comment
Share on other sites

Guest asrequested

Unfortunately I can’t. I’m out of funds as I just built this server. Plus I’m moving this weekend. But I don’t have m.2 slots nor do I have any free pci e slots.

 

That sucks! Well, something to think about for the future :)

Link to comment
Share on other sites

  • 1 month later...

Are you aware that the downfall of discarding the chunks is that if you seek back to a position that you've already watched, it will have to be transcoded all over again? Just want to make sure that you realize that. @ as well.

 

Anyway, I do agree that we can detect that there is low disk space and do some chunk recycling. Running out of disk space will cause errors so we should try to prevent that.

This is one of the few things I think Plex does better then Emby.

 

I'll try and explain why.  First as the OP has found, Plex does monitor the transcode directory and can/will cleanup as it goes by discarding oldest segments to make room for new.  You could transcode a 1 TB file this way using only a 32 GB flash drive.

 

Secondly, if you jump/seek to say the middle of the file it will start transcoding/remuxing from that point WITHOUT having to work it's way through the file.  This is super important to many sports fans.  Emby is not very usable to me on Saturday and Sundays for the way I watch college and NFL football games.  I'll explain.  A typical football game is 3.5 hours or so plus padding.  Typically on Sunday there are two 1 pm EST games broadcast OTA (more on cable).  So some sports nuts will watch the first quarter of game 1 then quarter 1 of game 2.  Then go back to watch quarter 2 of game 1.  This starts to take a while as you can't just start player right where you left off as Emby seems to want to transcode the file from the start vs jumping directly to where you left off.  By the time you reach half time or 3rd quarter it's an unbearable wait for video to start playing.  On Plex this is easy/fast as it will transcode from the spot you need to resume from.  Also making this situation worse yet is that on Android, Xbox, Theater and other apps the TS file can be direct played without having to transcode.  A 1080i game played back on Roku 3 for example would still need transcoding but it's much faster resuming do to how this works in Plex.

 

If the past segments are discarded and a user RW then these segments are redone again as needed. So in a nutshell transcoding in Plex is done on an NEED to USE basis.

 

Another feature making it's way is "global" transcoding/remuxing.  By this I mean if multiple people on say Roku 3 are watching said 1080i football game above they can share the same segments produced.  So for example if you have 4 Roku 3 all watching this 1080i game at 720p 4Mb they can share the same segments. Hence one transcode vs 4 assuming they are all near each other on the timeline.

 

So the Plex approach allows quick starting of playback of transcodes/remuxes even when you jump into a file 3/4 way through.  It can make use of just about any temp drive for transcoding (bigger usually better) and does on the fly cleanup so it never runs out of temp space.  The downside really doesn't exist.  If you RW to a place the segments don't exist they are redone quickly and the user really doesn't notice any slowdown as all jumps take just about the same time which is usually 1 to 2 seconds for the retranscode.  Of course if you started at the beginning of the file and had been transcoding/remuxing the whole way through on a bigger drive you would have the past segments available.

 

This approach allows large RAM drives to work perfectly fine for transcoding as well as saving wear and tear on the SSD/HDDs.

Edited by cayars
  • Like 1
Link to comment
Share on other sites

When you seek in Emby, we also start the transcode from the seek point and not from the beginning. We will look at dynamically deleting segments to conserve disk space in a future update. Thanks.

  • Like 1
Link to comment
Share on other sites

It doesn't seem like it @@Luke.

 

If I try to resume a NFL game from half time it can take up to 10 minutes for the remux to get to the point of being able to play it.  The client just waits and waits then starts playing finally.

 

Also in said remux of game if it finally starts playing from half time and I FF to get to 4th quarter there is also a long wait.

Edited by cayars
Link to comment
Share on other sites

I think this is getting off topic, but yes we do transcode from the seek point. In progress live tv might require some adjustment but out of scope of this particular discussion. 

 

To address the original issue, we plan to look at dynamically deleting segments to conserve disk space in a future update. Thanks.

Link to comment
Share on other sites

NikeSwe

I would like this functionality.
Want to save life for my cache SSD in my system. Transcoding is temporary files that could be stored in ram instead of wasting writes on the SSDs. But, it will not work good if transcoding is done to one file that grows bigger and bigger and bigger. Would like to see something like Plex does it (haven't tested it, just read about it). Split it in different smaller files, expire and remove older files while transcoding. An option to do transcoding in ram would be the best thing since the discovery of the light bulb. Almost. :D

Edited by NikeSwe
Link to comment
Share on other sites

  • 3 years later...

Just curious was this ever resolved or is the guidance to still use the SSD for the transcoding directory?  I ask as I'm testing Emby now (4k transcoding with HDR in windows on plex is a MESS!!!) and currently I'm using a 24 gb ramdisk as I did in plex, but wondering if thats still a good idea.  Originally with plex I did that to try to work around 4k transcoding buffering issues but decided to keep it for the potential SSD wear issue.  BTW 4k transcoding is working great with my little Tigerlake NUC, so far I have tested 2 concurrent streams :)  I've also found that the exoplayer implementation seems to be much smarter and more capable than plex!!!

Edited by tom9933
Link to comment
Share on other sites

The issue of transcoding temporary files occasionally being left behind is resolved in the upcoming emby server 4.7 release. Thanks.

 

  • Like 1
Link to comment
Share on other sites

  • 2 months later...
chris0101

What about a possible option for deleting transcode chunks older than s specific time ?  

 

Otherwise if a few people are watching you'll get a situation where you're using 50gb and most of it is old , the transcoder is fast enough that if you want to skip back it can just start again 

 

Link to comment
Share on other sites

8 hours ago, chris0101 said:

What about a possible option for deleting transcode chunks older than s specific time ?  

 

Otherwise if a few people are watching you'll get a situation where you're using 50gb and most of it is old , the transcoder is fast enough that if you want to skip back it can just start again 

 

Hi, yes we are planning on adding automatic detection of low disk space to delete segments even during the transcoding process.

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...