Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Topics - FastLaneJB

Pages: [1]
1
Installation and Upgrades / [HOWTO] Plex Media Server
« on: December 11, 2013, 03:34:52 pm »
Hi,

OK, I've worked out a way of running Plex Media Server as the user plex and having access to Samba shares configured in Zentyal so I thought I would share. This is the best way I've come up with doing this but let us know if you can think of a better way, it's been working fine for me for quite a few weeks now.

I'm not a fan of having my services running as root, my initial attempt at this had it running as a user I made inside Zentyal's LDAP with pam enabled however the service would fail on occasions when other services were restarted on Zentyal (At a guess, Samba and LDAP). So when it was up and running it worked fine but it wasn't reliable.

Anyway here we go. I'm assuming you've got some basic Linux knowledge but you shouldn't need much. I'm assuming you've got a share setup in Zentyal already with some media in it but if not make a blank one ready to have media in it.

Connect onto your Zentyal server's command line. I'm using Putty but connect on how you please.

First I switch to root so I don't need to type sudo infront of every command. Enter your password and you should now be root.

Code: [Select]
sudo -i
Lets get right to it and get Plex downloaded and installed. The commands below will download and install the 64bit version, go to the Plex site and get the URL of the 32bit one if your Zentyal isn't 64bit. This is the current version at the time of writing but again you might want to check.

I like to store the installer in /usr/src so I know which version is loaded. Maybe not the right place to put it but it's what I do.

Code: [Select]
mkdir /usr/src/plex
cd /usr/src/plex
wget http://downloads.plexapp.com/plex-media-server/0.9.8.14.263-139ddbc/plexmediaserver_0.9.8.14.263-139ddbc_amd64.deb
dpkg -i plexmediaserver_0.9.8.14.263-139ddbc_amd64.deb

Right that should have Plex installed and running under it's own plex system account.

Now we need to modify the way Zentyal's Samba works with permissions. This didn't work on early versions of Zentyal's 3.2 Samba module because of a bug but it's working on newer versions. So if your on a fresh 3.2 install you should update first.

I'm a nano person but use which ever editor you like.

Code: [Select]
nano /etc/zentyal/samba.conf
Change the following line so it's not commented out and is enabled with a yes.

Code: [Select]
unmanaged_acls = yes
Lets restart the service so this takes affect.

Code: [Select]
/etc/init.d/zentyal samba restart
Now we need to fix the permissions on the folder. I'm using hooks for this so they are checked and fixed if Zentyal overwrites them at any point.

I'm using acl files as I have more than just plex needing permission to the folders and it makes it easier to manage.

Code: [Select]
nano /etc/zentyal/hooks/base.acl
Add in the following line.

Code: [Select]
user:plex:rx
This is used to set permissions to the /home/samba and /home/samba/shares folders. Now I have another acl which is used for the media folder. I give Plex write permission because you can allow Plex to delete media from a device if you want, you can give it read only access if you want. If you want read only take the w out.

Code: [Select]
nano /etc/zentyal/hooks/media.acl
Add in the following lines.

Code: [Select]
user:plex:rwx
default:user:plex:rwx

If you've already got a samba.postservice then add this code to it, if not make a new file for it.

Code: [Select]
nano /etc/zentyal/hooks/samba.postservice
Add the following code but modify the path to match where your share is. I'm assuming it's in /home/samba/shares default location but again if not just change this.

Code: [Select]
#!/bin/bash

# Modify permissions for base folders
setfacl -M /etc/zentyal/hooks/base.acl /home/samba
setfacl -M /etc/zentyal/hooks/base.acl /home/samba/shares

# Check for missing permissions on shares
if ! getfacl -p /home/samba/shares/media | grep -q "plex"
then
   setfacl -R -M /etc/zentyal/hooks/media.acl /home/samba/shares/media
fi

This should allow the plex system account to have access to your media files. Lets restart Samba so the permissions are updated.

Code: [Select]
/etc/init.d/zentyal samba restart
Now we just need to sort out the firewall. So log into the Zentyal Administration Interface. Go to Network and Services and click on Add New. I've got 2 services, one which is allowed from outside my network for MyPlex and another which is internal.

So lets make the internal / external ports first.

TCP 32400 (Plex Web Interface)
TCP 32433 (Plex HTTPS which at the time of writing isn't used but should be in the future).


Now make another Service which is what we need for uPnP inside your local network. Add in the following ports.

TCP 1662
TCP 32469
UDP 1900
UDP 5353
UDP 32410
UDP 32413


Now go to Firewall, Packet Filter and Configure Rules for "Filtering rules from internal networks to Zentyal". Add in both the internal and internal / external services you've setup as allow.

Now go to Firewall, Packet Filter and Configure Rules for "Filtering rules from external networks to Zentyal". Add in just the internal / external service which has the 2 ports in it.

Save changes so this change is enabled on the firewall.

Finally go to http://*zentyal-ip*:32400/web so you can configure Plex. When it comes to MyPlex you need you have Advanced Settings and then tell it to manually specify port which should be 32400. Otherwise it'll try and pick a Random port and not get through Zentyal.

You should be able to add in your media in your Samba share and that's it. Go fire up a Plex Client and give it a whirl.

Hope this helps out. I've got some other services running which I might document as well given some time.

2
Installation and Upgrades / Jabber User Settings Missing
« on: November 30, 2013, 11:41:29 pm »
Hi,

I've got the jabber module installed. I can see the jabber options to have it enabled by default in the user template but when adding or editing a user the jabber settings aren't there. So no user can access jabber.

I've run the command to make sure the LDAP schema is added in and looking inside LDAP the schema is there but no user it getting the required settings stored for them. I think this is because Zentyal isn't showing the options when adding / editing a user.

Has anyone else got jabber working on 3.2 or is it broken? If it does work for some any ideas how I can fix it?

Cheers,
James

3
Installation and Upgrades / Virtual Machine Manager gone?
« on: September 17, 2013, 08:33:25 pm »
Cannot see this module on Zentyal 3.2 RC2 as an installable option. Doesn't seem to be there in the package list.

Is this an accident or it's been removed?

4
Installation and Upgrades / [SOLVED] Samba copy just stops
« on: May 07, 2013, 02:25:26 pm »
Hi,

OK after giving up getting Zentyal to work correctly in ESXi and using other products I really do like Zentyal so have come back to give it another go. I've install it direct to an ML110 G7 so there's no visualization used this time.

On a fresh install I've got the File Sharing module enabled. Setup a share and start to copy some files to it from a Windows 7 machine and the copy dialog just vanishes as if it has finished only it's only done some of the files. So I recopy the files over and Windows 7 resumes, does a few more and then stops again.

How do I get Zentyal to do SMB shares that are stable? This is a similar problem to what I had with ESXi so it seems that wasn't to blame after all.

I really do want to use Zentyal but if it cannot share files well then it's of no use. However if this was the case there would surely but lots of other people posting on this but there doesn't seem to be. I just don't see what I could be doing wrong. The same server works just fine if it was Windows Server loaded on it. The Windows 7 client works fine to 2 other servers on the network with copies of TB's worth of data never stopping until they are complete.

The samba.log is so verbose I don't know where to look. Just this small test has got it up to 489KB worth.

Any suggestions on what I could try to fix this?

Cheers,
James

5
Installation and Upgrades / Latest updates, now cannot login to Zentyal
« on: December 21, 2012, 07:30:51 am »
Hi,

I've put the latest updates on and rebooted the host last night. This morning I noticed the web server isn't working. So I go to log into the Zentyal 3 server and I cannot log into it with any user account. So I'm locked out of the server.

The passwords of the accounts I'm trying are definitely right but none of them are working. Something in one of the updates has broken the local server authentication so I cannot get into Zentyal.

I'll have to try recovery mode when I can get a chance and see what's up with the authentication. I'd warn people to hang fire on the latest updates currently.

6
Installation and Upgrades / Virtual machines and bridge interface
« on: September 18, 2011, 05:29:04 pm »
Hi,

I cannot seem to make a bridged interface with QEmu and if I uninstall that and put on Virtualbox I then can but no VM will ever start with it. I just get an error on trying to start it.

How do I make this work?

Cheers

Pages: [1]