# Plex Remote Transcoder - A distributed transcoding backend for Plex

**URL:** <https://forums.plex.tv/t/plex-remote-transcoder-a-distributed-transcoding-backend-for-plex/112681>\
**Category:** Dev/API Corner\
**Tags:** other-dev\
**Created:** [August 21, 2015, 4:06pm UTC](https://forums.plex.tv/t/plex-remote-transcoder-a-distributed-transcoding-backend-for-plex/112681 "2015-08-21T16:06:56Z")\
**Posts on this page:** 20\
**Page:** 1

<div class="post-metadata">

**Author:** ![peva](https://sea1.discourse-cdn.com/plex/user_avatar/forums.plex.tv/peva/32/83145_2.png) [@peva](https://forums.plex.tv/u/peva)\
**Post date:** [August 21, 2015, 4:06pm UTC](https://forums.plex.tv/t/plex-remote-transcoder-a-distributed-transcoding-backend-for-plex/112681/1 "2015-08-21T16:06:56Z")

</div>

I just came across this repo and couldn’t find a post on here about it. I AM NOT THE DEVELOPER, but I am really excited about this and have been waiting for something like this.

> **[wnielson/Plex-Remote-Transcoder](https://github.com/wnielson/Plex-Remote-Transcoder)**
>
> A distributed transcoding backend for Plex. Contribute to wnielson/Plex-Remote-Transcoder development by creating an account on GitHub.

Would love to hear peoples take/opinion on this project.

---

<div class="post-metadata">

**Author:** ![wnielson](https://sea1.discourse-cdn.com/plex/user_avatar/forums.plex.tv/wnielson/32/2673_2.png) [@wnielson](https://forums.plex.tv/u/wnielson)\
**Post date:** [August 21, 2015, 6:46pm UTC](https://forums.plex.tv/t/plex-remote-transcoder-a-distributed-transcoding-backend-for-plex/112681/2 "2015-08-21T18:46:55Z")

</div>

I am the developer of this project. I’ve just put together a guide [here](https://github.com/wnielson/Plex-Remote-Transcoder/wiki/Ubuntu-Install) detailing how to get started with two Ubuntu machines.

This is a work in progress, so feedback and bug reports are greatly appreciated.

---

<div class="post-metadata">

**Author:** ![wnielson](https://sea1.discourse-cdn.com/plex/user_avatar/forums.plex.tv/wnielson/32/2673_2.png) [@wnielson](https://forums.plex.tv/u/wnielson)\
**Post date:** [August 21, 2015, 8:49pm UTC](https://forums.plex.tv/t/plex-remote-transcoder-a-distributed-transcoding-backend-for-plex/112681/3 "2015-08-21T20:49:31Z")

</div>

I am currently working on basic load balancing. Here is a screen shot showing the transcoder running on two separate machines (bottom two windows) and the PMS running on the third (top window). You can see that the transcode machines are working hard, but the PMS master is not. All three of these machines are running as virtual machines (via VirtualBox).

Some additional features and improvement ideas are being collected [here](https://github.com/wnielson/Plex-Remote-Transcoder/wiki/Improvements-&-Additional-Features).

 ![load-based load balancing](http://wnielson.github.io/images/Plex%20Remote%20Transcoder%20-%20Load%20Balance.png)

---

<div class="post-metadata">

**Author:** ![Suspense](https://avatars.discourse-cdn.com/v4/letter/s/b782af/32.png) [@Suspense](https://forums.plex.tv/u/Suspense)\
**Post date:** [August 22, 2015, 3:06pm UTC](https://forums.plex.tv/t/plex-remote-transcoder-a-distributed-transcoding-backend-for-plex/112681/4 "2015-08-22T15:06:27Z")

</div>

Would this be compatible and run fine on windows machines? Been looking for this for well over 2 years now

Regards

---

<div class="post-metadata">

**Author:** ![wnielson](https://sea1.discourse-cdn.com/plex/user_avatar/forums.plex.tv/wnielson/32/2673_2.png) [@wnielson](https://forums.plex.tv/u/wnielson)\
**Post date:** [August 22, 2015, 5:29pm UTC](https://forums.plex.tv/t/plex-remote-transcoder-a-distributed-transcoding-backend-for-plex/112681/5 "2015-08-22T17:29:34Z")

</div>

In the current state, no, it will not work on Windows. That’s said it shouldn’t take too much effort to get it working. Cygwin would likely be a prerequisite.

---

<div class="post-metadata">

**Author:** ![CB2131](https://avatars.discourse-cdn.com/v4/letter/c/9fc348/32.png) [@CB2131](https://forums.plex.tv/u/CB2131)\
**Post date:** [August 23, 2015, 3:44am UTC](https://forums.plex.tv/t/plex-remote-transcoder-a-distributed-transcoding-backend-for-plex/112681/6 "2015-08-23T03:44:38Z")

</div>

Brilliant work!!

---

<div class="post-metadata">

**Author:** ![Suspense](https://avatars.discourse-cdn.com/v4/letter/s/b782af/32.png) [@Suspense](https://forums.plex.tv/u/Suspense)\
**Post date:** [August 23, 2015, 10:07am UTC](https://forums.plex.tv/t/plex-remote-transcoder-a-distributed-transcoding-backend-for-plex/112681/7 "2015-08-23T10:07:56Z")

</div>

> @wnielson said:  
> In the current state, no, it will not work on Windows. That’s said it shouldn’t take too much effort to get it working. Cygwin would likely be a prerequisite.

Would absolutely love if you could port this to windows

---

<div class="post-metadata">

**Author:** ![CB2131](https://avatars.discourse-cdn.com/v4/letter/c/9fc348/32.png) [@CB2131](https://forums.plex.tv/u/CB2131)\
**Post date:** [August 23, 2015, 4:56pm UTC](https://forums.plex.tv/t/plex-remote-transcoder-a-distributed-transcoding-backend-for-plex/112681/8 "2015-08-23T16:56:27Z")

</div>

I’m excited to see where this goes!

---

<div class="post-metadata">

**Author:** ![CB2131](https://avatars.discourse-cdn.com/v4/letter/c/9fc348/32.png) [@CB2131](https://forums.plex.tv/u/CB2131)\
**Post date:** [August 23, 2015, 5:15pm UTC](https://forums.plex.tv/t/plex-remote-transcoder-a-distributed-transcoding-backend-for-plex/112681/9 "2015-08-23T17:15:00Z")

</div>

Can I assume that the initial setup via (sudo prt install) needs to be re-run when the PMS is updated?

---

<div class="post-metadata">

**Author:** ![wnielson](https://sea1.discourse-cdn.com/plex/user_avatar/forums.plex.tv/wnielson/32/2673_2.png) [@wnielson](https://forums.plex.tv/u/wnielson)\
**Post date:** [August 23, 2015, 6:32pm UTC](https://forums.plex.tv/t/plex-remote-transcoder-a-distributed-transcoding-backend-for-plex/112681/10 "2015-08-23T18:32:35Z")

</div>

> @CB2131 said:  
> Can I assume that the initial setup via (sudo prt install) needs to be re-run when the PMS is updated?

Correct. Upgrading PMS will overwrite the changes made by `prt`. For now you’ll probably need to remove the `plex_transcoder` (located in `/usr/lib/plexmediaserver/Resources`) before runnning `sudo prt install` again, at least until I’ve updated the code to be a bit smarter.

---

<div class="post-metadata">

**Author:** ![CB2131](https://avatars.discourse-cdn.com/v4/letter/c/9fc348/32.png) [@CB2131](https://forums.plex.tv/u/CB2131)\
**Post date:** [August 23, 2015, 6:52pm UTC](https://forums.plex.tv/t/plex-remote-transcoder-a-distributed-transcoding-backend-for-plex/112681/11 "2015-08-23T18:52:41Z")

</div>

Is Real-Time Load-Based Balancing configured by default?

---

<div class="post-metadata">

**Author:** ![wnielson](https://sea1.discourse-cdn.com/plex/user_avatar/forums.plex.tv/wnielson/32/2673_2.png) [@wnielson](https://forums.plex.tv/u/wnielson)\
**Post date:** [August 23, 2015, 7:01pm UTC](https://forums.plex.tv/t/plex-remote-transcoder-a-distributed-transcoding-backend-for-plex/112681/12 "2015-08-23T19:01:37Z")

</div>

> @CB2131 said:  
> Is Real-Time Load-Based Balancing configured by default?

Yeah, it is the only load-balancing currently. If you have more than one host, it’ll automatically pick the one with the lowest load.

---

<div class="post-metadata">

**Author:** ![CB2131](https://avatars.discourse-cdn.com/v4/letter/c/9fc348/32.png) [@CB2131](https://forums.plex.tv/u/CB2131)\
**Post date:** [August 23, 2015, 9:05pm UTC](https://forums.plex.tv/t/plex-remote-transcoder-a-distributed-transcoding-backend-for-plex/112681/13 "2015-08-23T21:05:28Z")

</div>

Ahh! Followed your guide precisely. It’s non-functional over here. The transcoder does not seem to be firing up at all.

---

<div class="post-metadata">

**Author:** ![wnielson](https://sea1.discourse-cdn.com/plex/user_avatar/forums.plex.tv/wnielson/32/2673_2.png) [@wnielson](https://forums.plex.tv/u/wnielson)\
**Post date:** [August 23, 2015, 9:31pm UTC](https://forums.plex.tv/t/plex-remote-transcoder-a-distributed-transcoding-backend-for-plex/112681/14 "2015-08-23T21:31:39Z")

</div>

> @CB2131 said:  
> Ahh! Followed your guide precisely. It’s non-functional over here. The transcoder does not seem to be firing up at all.

Debugging is tricky. If I had to guess I’d say it is a permissions error related to the PMS temporary directory. Try logging into the slave, su to the plex user, cd to the network shared PMS temp dir and make sure it is writable.

---

<div class="post-metadata">

**Author:** ![CB2131](https://avatars.discourse-cdn.com/v4/letter/c/9fc348/32.png) [@CB2131](https://forums.plex.tv/u/CB2131)\
**Post date:** [August 23, 2015, 10:00pm UTC](https://forums.plex.tv/t/plex-remote-transcoder-a-distributed-transcoding-backend-for-plex/112681/15 "2015-08-23T22:00:19Z")

</div>

Ok so that did the trick. Seems to be passing transcoding from the master to the slave. So given the Real-Time Load-Based Balancing…this will automatically shift jobs between the Master and Slave nodes based on CPU load?

If One slave exists, does it pass jobs back to the master when CPU load hit a particular %?

---

<div class="post-metadata">

**Author:** ![wnielson](https://sea1.discourse-cdn.com/plex/user_avatar/forums.plex.tv/wnielson/32/2673_2.png) [@wnielson](https://forums.plex.tv/u/wnielson)\
**Post date:** [August 23, 2015, 10:02pm UTC](https://forums.plex.tv/t/plex-remote-transcoder-a-distributed-transcoding-backend-for-plex/112681/16 "2015-08-23T22:02:58Z")

</div>

> @CB2131 said:  
> Ok so that did the trick. Seems to be passing transcoding from the master to the slave. So given the Real-Time Load-Based Balancing…this will automatically shift jobs between the Master \<------\> Slaves based on CPU load?
> 
> If One slave exists, does it pass jobs back to the master when CPU load hit a particular %?

By default, the `master` is not considered as a transcode `slave`. If you want the `master` to be considered a `slave` as well, then run `prt add_host` and use the loopback address `127.0.0.1`.

---

<div class="post-metadata">

**Author:** ![CB2131](https://avatars.discourse-cdn.com/v4/letter/c/9fc348/32.png) [@CB2131](https://forums.plex.tv/u/CB2131)\
**Post date:** [August 24, 2015, 1:27am UTC](https://forums.plex.tv/t/plex-remote-transcoder-a-distributed-transcoding-backend-for-plex/112681/17 "2015-08-24T01:27:50Z")

</div>

`plex@master:/root$ prt add_host Host: 127.0.0.1 Port: 22 User: plex We're going to add the following transcode host: Host: 127.0.0.1 Port: 22 User: plex Proceed: [y/n]y close failed in file object destructor: IOError: [Errno 28] No space left on device Host successfully added`

What are you thoughts on this? What is the location of the host file? i.e. the file where I can remove configured hosts?

---

<div class="post-metadata">

**Author:** ![wnielson](https://sea1.discourse-cdn.com/plex/user_avatar/forums.plex.tv/wnielson/32/2673_2.png) [@wnielson](https://forums.plex.tv/u/wnielson)\
**Post date:** [August 24, 2015, 1:44am UTC](https://forums.plex.tv/t/plex-remote-transcoder-a-distributed-transcoding-backend-for-plex/112681/18 "2015-08-24T01:44:16Z")

</div>

> @CB2131 said:  
> `plex@master:/root$ prt add_host Host: 127.0.0.1 Port: 22 User: plex We're going to add the following transcode host: Host: 127.0.0.1 Port: 22 User: plex Proceed: [y/n]y close failed in file object destructor: IOError: [Errno 28] No space left on device Host successfully added`
> 
> What are you thoughts on this? What is the location of the host file? i.e. the file where I can remove configured hosts?

The configuration file is ~/.prt.conf, which should be /var/lib/plexmediaserver/.prt.conf on the master. There isn’t an option to hangs that location yet, but maybe I should add a way to specify a different location.

---

<div class="post-metadata">

**Author:** ![CB2131](https://avatars.discourse-cdn.com/v4/letter/c/9fc348/32.png) [@CB2131](https://forums.plex.tv/u/CB2131)\
**Post date:** [August 24, 2015, 1:52am UTC](https://forums.plex.tv/t/plex-remote-transcoder-a-distributed-transcoding-backend-for-plex/112681/19 "2015-08-24T01:52:13Z")

</div>

That config file seems to be empty.

---

<div class="post-metadata">

**Author:** ![wnielson](https://sea1.discourse-cdn.com/plex/user_avatar/forums.plex.tv/wnielson/32/2673_2.png) [@wnielson](https://forums.plex.tv/u/wnielson)\
**Post date:** [August 24, 2015, 1:58am UTC](https://forums.plex.tv/t/plex-remote-transcoder-a-distributed-transcoding-backend-for-plex/112681/20 "2015-08-24T01:58:25Z")

</div>

> @CB2131 said:  
> That config file seems to be empty.

Are you running the prt command as the plex user?

[Next page](https://forums.plex.tv/t/plex-remote-transcoder-a-distributed-transcoding-backend-for-plex/112681.md?page=2)
