Using preroll to wake hard disk storage prior to playback

Hi,

I’d like to make use of preroll and potentially web hooks to buy time to wake my storage drive before playback starts on an item. Currently my hard drive takes around 20 seconds to wake when media playback is started which can be pretty frustrating. I could make the hard drive spin 24/7 which would resolve the problem, but it seems a little wasteful given that the server isn’t used for more than a couple of hours per day.

My thinking was could I use an event trigger on pre-roll start (running from a SSD) to run a shell script or something similar that would wake the hard drive? By the time the pre-roll had finished, the hard drive would be ready and media playback would start much more quickly.

Has anybody tried anything like this to get round this issue?

Thanks in advance!

There’s quite a popular feature suggestion asking to start caching/buffering the main movie while the preroll is playing. This should also cover your request…

1 Like

Have you investigated - is a webhook called when the preroll is started, or only when it gets to the “actual” media?

Edit2: It seems like it does make a callout when the preroll starts playing.

I wonder if Plex would allow you to use a named pipe as a preroll video. It would be a very oldschool way to do it.

Edit: Nope. Plex tries to figure out how big the file is, which doesn’t work with a named pipe. Sorry on that front.

Edit3: Having a disconnected named pipe/fifo in a Plex library directory makes the scanner crabby.

Ignore everything I said about pipes. Try making a webhook listener. :slight_smile:

Plex starting to buffer the main movie right away should address this. Otherwise we’re only talking about some workaround.

PS: I recently moved my prerolls to a SSD… so I’m 100% in your boat on this. Currently every movie gives me a „your server is not fast enough“ error message while I can hear my NAS spinning up the respective HDD.
I’ll probably rearrange some of my votes to free one up for this suggestion.

Are you privy to insider intel about that feature being implemented? :slight_smile:

It looks like a “hard” feature to me. On platforms where Plex doesn’t control the player it’s probably impossible. On ones where it does control the player, it’s probably still hard.

In a “transcode everything” world it’s slightly more doable, but STILL hard.

I hope you know something, because as cool as it would be, it’s wayyyyy down the list of stuff I expect to see any time soon.

Nope. Just a regular user with a fancy ninja tag :wink:

Darnit. :stars:

(that’s a ninja star. fyi.)

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.