Plex Media Server

Status
Not open for further replies.

thelambentonion

Dabbler
Joined
Jul 11, 2013
Messages
10
I apologize if this is outside of the scope of this forum, however since "Plugins" are now "Jails" in FreeNAS 9.1.0, I figured it would be the most appropriate.

Recently, Plex Media Server released an "experimental" build of Plex for FreeBSD 9.1. I tested Plex (installed from KalleDK's port) on a FreeBSD 9.1 install within VirtualBox and everything went smoothly.

I then tested Plex within a FreeNAS 9.1.0 jail (using VIMAGE) and hit a roadblock. The Web interface loads up correctly and begins the setup wizard, however Plex can't seem to load any of its plugins. The permissions of all files that Plex installs are the same in both the VM and in the Jail and I've tested it in both 'plugins' and 'ports' jails.

So far, I've been treating FreeNAS jails as I would a virtualized instance of FreeNAS/FreeBSD. I'm mostly hoping that someone with more experience with FreeNAS/FreeBSD could give me a little direction in tracking down this issue.
 

cyberjock

Inactive Account
Joined
Mar 25, 2012
Messages
19,526
Ooo. Someone with determination. I'll be watching this thread! I'd offer help but I'm not too familiar with installing Plex(I don't have a Plex Pass yet).
 

thelambentonion

Dabbler
Joined
Jul 11, 2013
Messages
10
For what it's worth, I believe the port itself can be installed without a Plex Pass. I purchased a one month Plex Pass to show my support, and will renew it if I can get it to play nice with my server; I can't imagine that the Plex Team would have any qualms about someone installing it for testing purposes.
 

thelambentonion

Dabbler
Joined
Jul 11, 2013
Messages
10
My NAS has been offline for the past few days due to a hardware error, so I've been testing Plex on FreeBSD in VirtualBox. With the help of some people on the Plex FreeBSD forum, we've somewhat weakly determined that the issue lies in using VIMAGE along with the Plex jail. One user at least has had general success installing from KalleDK's port into a FreeNAS 'ports' jail with VIMAGE unchecked.

I had been under the impression that VIMAGE just provided a virtualized network stack, but Plex appears to only work without it...
 

paleoN

Wizard
Joined
Apr 22, 2012
Messages
1,403
I had been under the impression that VIMAGE just provided a virtualized network stack, but Plex appears to only work without it...
FYI, jails in 9.1 have the option, may even be the default, to be created without VIMAGE.
 

thelambentonion

Dabbler
Joined
Jul 11, 2013
Messages
10
FYI, jails in 9.1 have the option, may even be the default, to be created without VIMAGE.


There's an option, but it defaults to an install with VIMAGE. I like the idea of a virtualized 10 GbE connection within the jail (primarily to facilitate jail-to-jail communication if I needed to), so I left it enabled. It's not a huge loss for Plex to operate without it, I'm just a little curious as to why it causes the Library agents to fail.
 

MrRw

Cadet
Joined
Aug 1, 2013
Messages
2
Hi there,

As a noob I tried my best but couldn't make PMS see my media folders... everything else is working fine.
Basically I need to solve two problems :
  1. Make it access/scan my local media;
  2. Make plex media server autostart when the server/jail starts;
I documented all my steps below:

1) Create a jail on Freenas web GUI
• standard kind​
• *NO* vimage​


2) Enter the jail (using SSH as root)
• jls​
• jexec [#] csh​


3) Follow instructions from KalleDK
• pkg_add plexmediaserver-0.9.8.4.116.tbz​


4) Create folders and mountpoints
• cd /mnt​
• mkdir {Music,Movies,Series,Pictures,Videos}​
• chmod 777 *​
• on Freenas web GUI > jails > plex jail > storage​
• create the mountpoints linking your media folders and the folders created above (inside the pled jail)​


5) Startup plex
• /usr/local/etc/rc.d/plexmediaserver start​
• follow instructions to edit the rc.conf file​
• ee /etc/rc.conf​
• plexmediaserver_enable="YES"​
• plexmediaserver_script_path="/usr/local/share/plexmediaserver"​
• plexmediaserver_support_path="/usr/local/plexdata" (optional)​
• save the file​
• again: /usr/local/etc/rc.d/plexmediaserver start​

6) Open http://your-local-ip:32400/manage
• configure and link your myplex account​
• go to my library > add section​
• navigate to /mnt/Movies etc…​


7) When I try to scan the folders, nothing shows up and the following message is immediately displayed:
• " Library scan complete: Extra information may still be downloading from the Internet"​

 

garfunkel

Dabbler
Joined
Jun 15, 2012
Messages
41
I got this working.

A couple days ago, I tried using the instructions above but ran into the same issue. I looked into it and looking at the plex log I found the command plex was shelling out to update the library. I noted that running it myself produced an error because plex comes with a version of python bundled with it and its libraries and running the script resulted in it trying to use my system python instead, which results in it not working.

I tried to play around with it but didn't have much time for it.

But today I tried again and noted that on the git repo here:
https://github.com/KalleDK/plexmediaserver_port

There is a recent (last couple days) commit related to exactly this issue. I cloned the repo into a new jail (Vimage off, haven't attempted with it on yet...), installed it as a port (had to add the 'plex' user and group to the port system's UID and GID files). and it's now scanning my library (and finding stuff correctly and working seemingly fine).

I'm toying with creating plugins for 9.1 but there isn't yet much documentation on doing this :(
 

tanik1

Contributor
Joined
Mar 31, 2013
Messages
163
is there a plex pbi or is this plugin installed differently?
 

cyberjock

Inactive Account
Joined
Mar 25, 2012
Messages
19,526
No pbi or comprehensive instructions...yet.
 

tanik1

Contributor
Joined
Mar 31, 2013
Messages
163

cyberjock

Inactive Account
Joined
Mar 25, 2012
Messages
19,526
I don't know. This thread is for Plex Media Server.
 

petr

Contributor
Joined
Jun 13, 2013
Messages
142
amazing progress, cannot wait for instructions/pbi!
 

trevorb

Dabbler
Joined
Aug 13, 2013
Messages
24
Or you could use his port http://www.freshports.org/multimedia/plexmediaserver/ as per the instructions on the Ports page
(e.g. To install the port: cd /usr/ports/multimedia/plexmediaserver/ && make install clean)

What I did:
Set up a standard jail as per above and added my mounts (I did not need to have VIMAGE disabled or change any permissions)
jls
jexec <jail#> csh
mkdir /mnt/media

Went back to the GUI and associated the mount with my media (making sure that I ticked the mount box)

Installed & compiled the port as per the FreeNAS instructions http://doc.freenas.org/index.php/Installing_non-PBI_Software#Compiling_FreeBSD_Ports_with_make
portsnap fetch extract
cd /usr/ports/multimedia/plexmediaserver/ && make install clean

Started the plexmediaserver via
/usr/local/etc/rc.d/plexmediaserver start

Made sure it starts everytime I start the jail by adding the following line to /etc/rc.conf
plexmediaserver_enable="YES"

This is defaulted to /usr/local/plexdata, but if you want to change it you should also add this line to /etc/rc.conf (I didn't have any issues without it)
plexmediaserver_support_path="/<new_path>/plexdata"

Navigated to the server page
http://<jail_IP>:32400/web
and configured to my liking

Hope it works as smoothly for you :)
 

amires

Explorer
Joined
Nov 19, 2012
Messages
66
Or you could use his port http://www.freshports.org/multimedia/plexmediaserver/ as per the instructions on the Ports page
(e.g. To install the port: cd /usr/ports/multimedia/plexmediaserver/ && make install clean)

What I did:
Set up a standard jail as per above and added my mounts (I did not need to have VIMAGE disabled or change any permissions)
jls
jexec <jail#> csh
mkdir /mnt/media

Went back to the GUI and associated the mount with my media (making sure that I ticked the mount box)

Installed & compiled the port as per the FreeNAS instructions http://doc.freenas.org/index.php/Installing_non-PBI_Software#Compiling_FreeBSD_Ports_with_make
portsnap fetch extract
cd /usr/ports/multimedia/plexmediaserver/ && make install clean

Started the plexmediaserver via
/usr/local/etc/rc.d/plexmediaserver start

Navigated to the server page
http://<jail_IP>:32400
and configured to my liking

Hope it works as smoothly for you :)


Great instructions. However you also to need to add the following lines to /etc/rc.conf

plexmediaserver_enable="YES"
plexmediaserver_support_path="/usr/local/plexdata"

I can confirm that it is working perfectly with VIMAGE enabled and GDM and DLNA is working too. The only problem I am having currently is that transcoder is not working as it should. For example on Plex iPhone App if I enable Universal Transcoder it doesnt work and I get a lot of errors in Plex log file that transcoder process died or something like that cannot remember the exact message. Also I cannot get the subtitles to show on Plex IOS app however on Plex Media Center on Windows PC the subtitles are working perfectly. Does anyone have the same problems?
 

trevorb

Dabbler
Joined
Aug 13, 2013
Messages
24
However you also to need to add the following lines to /etc/rc.conf
plexmediaserver_enable="YES"
plexmediaserver_support_path="/usr/local/plexdata"


Ah, it is handy to have plex start anytime you restart the jail :smile: Thanks, I have edited my post.
I'm not sure about the support path variable, as I did not set it and didn't appear to have any issues, but I may not have tested everything yet.
 

amires

Explorer
Joined
Nov 19, 2012
Messages
66
Ah, it is handy to have plex start anytime you restart the jail :) Thanks, I have edited my post.
I'm not sure about the support path variable, as I did not set it and didn't appear to have any issues, but I may not have tested everything yet.
support path specifies where do you want plex to store its database, metadata, logs files and etc.

I think it defaults to /usr/local/plexdata however you can change it to fit your needs.

By the way http://<jail_ip>:32400 alone did not work for me I had to append /web/ at the end for the web gui to appear.
 

trevorb

Dabbler
Joined
Aug 13, 2013
Messages
24
I think it defaults to /usr/local/plexdata however you can change it to fit your needs.
By the way http://<jail_ip>:32400 alone did not work for me I had to append /web/ at the end for the web gui to appear.

I think you are correct about the default, as adding it changed nothing with my setup (i.e. all settings were still in place after a restart).

Yes, I did have to access http://<jail_ip>:32400/web. Post updated! :smile:
 
Status
Not open for further replies.
Top