This is the old XigmaNAS forum in read only mode,
it will taken offline by the end of march 2021!



I like to aks Users and Admins to rewrite/take over important post from here into the new fresh main forum!
Its not possible for us to export from here and import it to the main forum!

[HOWTO] Installing pyload into jail

Jails with XigmaNAS
Forum rules
Set-Up GuideFAQsForum Rules
Post Reply
Schopenhauer
NewUser
NewUser
Posts: 5
Joined: 26 Oct 2013 11:33
Status: Offline

[HOWTO] Installing pyload into jail

Post by Schopenhauer »

Hello there,

I've googled a lot in last few weeks regarding the above topic.

Sorry if this question seems stupid to you but I'm a BSD Beginner and I only got basic skills in Linux. I'm willing to learn from you :roll:

So here's my setup:

Im running latest N4F 9.1 x64 embedded on a Dual-Core Intel Atom D2550 rig. This seems sufficent for me because running a 24/7 NAS is VERY expensive in Germany nowadays..

I've installed latest Version of "The Brig" and took control of the jail via root.

When I try to install the python script of pyload inside the jail I've got an error Mesage like " Permission deniend.. "

Is it just me or is it about the permissions of the folder where the script tries to install??

I would be grateful if someone could explain me the installation of pyload via The Brig. Also a Link to an Newbie The Brig Howto is welcome 8-)

Fire
Starter
Starter
Posts: 26
Joined: 05 Oct 2013 23:20
Status: Offline

Re: [Help needed] Installing pyload into jail

Post by Fire »

i just did it 3 hours ago... was quiet easy ...

=== set up a jail via TheBrig
- mine called "download"
- jail type full
- remember to create da directory in you jail's folder for fstab (mine looks like this "/mnt/pool1/downloads /mnt/pool1/jails/download/mnt/downloads nullfs rw 0 0")
- i set "Route only TCP/IP within a jail" in TheBrig's config but i down know if it's important

=== install pyload
- SSH to your NAS
- get the jail ID (jls)
- log into your jail "jexec ID csh"
- create an dir for pyload "mkdir /usr/local/share/pyload"
- enter pyload dir "cd /usr/local/share/pyload/"
- get the pyload source "fetch http://download.pyload.org/pyload-src-v0.4.9.zip"
- unpack it "unzip pyload-src-v0.4.9.zip"
- move to your current dir "mv pyload/* ./ ; rmdir pyload"
- install dependencies

Code: Select all

pkg_add -r py27-curl 
pkg_add -r py27-Jinja2 
pkg_add -r py27-beaker 
pkg_add -r py27-pycrypto 
pkg_add -r tesseract
pkg_add -r tesseract-data
pkg_add -r py27-imaging
pkg_add -r spidermonkey17
pkg_add -r py27-feedparser
pkg_add -r py27-beautifulsoup
pkg_add -r py27-openssl
pkg_add -r python
pkg_add -r py27-sqlite3
- run pyload setup "/usr/local/bin/python /usr/local/share/pyload/pyLoadCore.py -s" (remember your download dir from above)
- testrun pyload "/usr/local/bin/python /usr/local/share/pyload/pyLoadCore.py --daemon"

if everything works fine, setup autorun:
- leave your jail "exit"
- open /etc/rc.conf.local (nano /etc/rc.conf.local)
- look up you jails section, add/extend the following lines:

Code: Select all

jail_download_exec_start="/usr/local/bin/python /usr/local/share/pyload/pyLoadCore.py --daemon"
jail_download_exec_prestop="/usr/local/bin/python /usr/local/share/pyload/pyLoadCore.py -q"
(you see your jail-name in the line, mine is "download", replace with your jail name)

thats it, you can now access the webinterface "JAILIP:8000"

(with help from here: http://forum.pyload.org/viewtopic.php?f=7&t=1798 and viewtopic.php?f=79&t=3894)

Schopenhauer
NewUser
NewUser
Posts: 5
Joined: 26 Oct 2013 11:33
Status: Offline

Re: [Help needed] Installing pyload into jail

Post by Schopenhauer »

thank you very much for your help.

I've managed to install pyload into the jail with your guide. :)

The only thing which needed to be done was installing "py27-qt4-core" via ports because the pyload installscript said qt4 lib was missing.

Cheers!

Fire
Starter
Starter
Posts: 26
Joined: 05 Oct 2013 23:20
Status: Offline

Re: [Help needed] Installing pyload into jail

Post by Fire »

That package is not needed because you don't have any graphical Interface on the machine itself

Schopenhauer
NewUser
NewUser
Posts: 5
Joined: 26 Oct 2013 11:33
Status: Offline

Re: [HOWTO] Installing pyload into jail

Post by Schopenhauer »

I was wondering about the package too. Nevertheless my N4F works like a charm.

Schopenhauer
NewUser
NewUser
Posts: 5
Joined: 26 Oct 2013 11:33
Status: Offline

Re: [HOWTO] Installing pyload into jail

Post by Schopenhauer »

Hello,

sorry for begging you again, but somehow my N4F embedded didn't save the changes in rc.conf.local (because of the ramdisk?)

Code: Select all

jail_download_exec_start="/usr/local/bin/python /usr/local/share/pyload/pyLoadCore.py --daemon"
jail_download_exec_prestop="/usr/local/bin/python /usr/local/share/pyload/pyLoadCore.py -q"
Therefore there's no pyload autostart on reboot :(

User avatar
raulfg3
Site Admin
Site Admin
Posts: 4865
Joined: 22 Jun 2012 22:13
Location: Madrid (ESPAÑA)
Contact:
Status: Offline

Re: [HOWTO] Installing pyload into jail

Post by raulfg3 »

add in thebrig webgui command section:

User command 0 = "/usr/local/bin/python /usr/local/share/pyload/pyLoadCore.py --daemon"

and in the User command stop section = "/usr/local/bin/python /usr/local/share/pyload/pyLoadCore.py -q"
12.1.0.4 - Ingva (revision 7743) on SUPERMICRO X8SIL-F 8GB of ECC RAM, 11x3TB disk in 1 vdev = Vpool = 32TB Raw size , so 29TB usable size (I Have other NAS as Backup)

Wiki
Last changes

HP T510

Fire
Starter
Starter
Posts: 26
Joined: 05 Oct 2013 23:20
Status: Offline

Re: [HOWTO] Installing pyload into jail

Post by Fire »

raulfg3 is right :) was my little mistake

User avatar
MikeMac
Forum Moderator
Forum Moderator
Posts: 429
Joined: 07 Oct 2012 23:12
Location: Moscow, Russia
Contact:
Status: Offline

Re: [HOWTO] Installing pyload into jail

Post by MikeMac »

Had anybody try installtion on 9.2 based nas4free?

I had failed. First there is a bug in pyload code (easy fix here http://forum.pyload.org/viewtopic.php?f=12&t=1423)
but second is dependencie problem like here http://forum.pyload.org/viewtopic.php?f=7&t=3112#p11845 I could not fix

inazr
NewUser
NewUser
Posts: 3
Joined: 07 Feb 2014 08:37
Status: Offline

Re: [HOWTO] Installing pyload into jail

Post by inazr »

//EDIT: works fine now. looks like it was my mistake.

bombai
Starter
Starter
Posts: 21
Joined: 07 Jan 2014 17:25
Status: Offline

Re: [HOWTO] Installing pyload into jail

Post by bombai »

Hi, I am trying to install pyload, and when I try to download pyload src it shows me an error.. I have downloaded by browser and upload by ftp to can follow the instruccions. But when I have to install dependencies it shows me a similar error for each dependency.. It seems I havent conectivity.. Have I to configure some extra options?

Image

I can do a ping from localhost to Jail IP.. But from jail by SSH cant do it because shows me..

ping: socket: Operation not permitted

How can i check if Is a jail network issue?

Thanks.

fumantsu
Starter
Starter
Posts: 69
Joined: 04 Mar 2014 12:15
Location: Athens->Brno
Status: Offline

Re: [HOWTO] Installing pyload into jail

Post by fumantsu »

Check your /etc/resolv.conf (?) for dns servers

the second is normal and you don't need it too much. Do a nslookup to check you connectivity inside the jail

All these issue I had them me also.
Fractal Node 304, Avoton C2550 Quad-Core Processor, 8GB RAM ECC, 4 x 4TB WD RED in mirrors , NAS4Free 9.2.0.1 build 972

bombai
Starter
Starter
Posts: 21
Joined: 07 Jan 2014 17:25
Status: Offline

Re: [HOWTO] Installing pyload into jail

Post by bombai »

fumantsu wrote:Check your /etc/resolv.conf (?) for dns servers

the second is normal and you don't need it too much. Do a nslookup to check you connectivity inside the jail

All these issue I had them me also.
I think that uses the same network configuration, I have copied /etc/resolv.conf to /mnt/Downloads/Jails/pyload/etc and it works.

Thanks a lot fumantsu!

EDIT: I had to unistall jinja2 dependency because is older than pyload includes, only remove it and works well, if not, you can not log in by web interface.

Regards.

bombai
Starter
Starter
Posts: 21
Joined: 07 Jan 2014 17:25
Status: Offline

Re: [HOWTO] Installing pyload into jail

Post by bombai »

Hi, I have a problem with a premium account..

I cant register my uploaded.me account, If I choose uploaded.to it tells me thats a invalid account..

Has anyone his uploaded.to account registered?

Thanks.

fumantsu
Starter
Starter
Posts: 69
Joined: 04 Mar 2014 12:15
Location: Athens->Brno
Status: Offline

Re: [HOWTO] Installing pyload into jail

Post by fumantsu »

I had issue with an easybytez premium account and I found out after long long search that py27-Jinja2 is the cause. Something in the code is incompatible with the package the py27-Jinja2 is installing. I don't know if you compile the package from the ports it will solve the problem but If you don't install it or if you remove it, pyload will still work without problem.
Fractal Node 304, Avoton C2550 Quad-Core Processor, 8GB RAM ECC, 4 x 4TB WD RED in mirrors , NAS4Free 9.2.0.1 build 972

Ironcurtain
Starter
Starter
Posts: 16
Joined: 01 Sep 2012 14:43
Status: Offline

Re: [HOWTO] Installing pyload into jail

Post by Ironcurtain »

Hello

i use the newest version of nas4free and created a jail named "pyLoad" with type "full" over the webgui.
Everything seems to work but when i type in: ip-Adress:8000 i get this message:

"Critical error while processing request: /login"

Can someone help me?

Alestrix
NewUser
NewUser
Posts: 7
Joined: 28 Feb 2014 14:37
Status: Offline

Re: [HOWTO] Installing pyload into jail

Post by Alestrix »

Ironcurtain wrote:"Critical error while processing request: /login"

Can someone help me?
Hi,

I experienced the same problem. This seems to be a current problem caused by a bug in the Jinja2 v2.7 library (see this bug) as well as a possibly incorrectly compiled curl library in the freebsd ports binaries installed by pkg_add (missing enabled cookies by default).

This is more or less the way I fixed it:
- start from scratch
- Install the packages as described above, except you leave out py27-Jinja2 and py27-curl
- Execute the installation as described in https://github.com/mrhanky17/pyload-freebsd, but before the pyload port is compiled, comile ftp/curl:

Code: Select all

# portsnap fetch extract
# pkg_add -r git
# cd /usr/ports/ftp/curl && make install clean
# cd /usr/ports/www
# git clone https://github.com/mrhanky17/pyload-freebsd.git pyload
# cd pyload/ && make install clean
I believe that were roughly the steps I undertook. Since I was circleing in onto the solution, my path did vary a bit (I first installed all packes, compiled pyload from git, didn't work, uninstalled Jinja and curl - not sure whether I also uninstalled py27-curl - compiled curl, maybe re-added py27-curl as a package again, who knows... at some point it did work)

On a sidenote: If you install according to the steps above described by Fire and only leave out the Jinja2 package, you will be able to log in and at first everything seems to work fine. However, when trying to download something, every download fails with a strange

Code: Select all

(48, '')
error.

Good luck,
aL

edit: typo

Jack8Coke
NewUser
NewUser
Posts: 1
Joined: 10 Jul 2014 18:57
Status: Offline

Re: [HOWTO] Installing pyload into jail

Post by Jack8Coke »

Hi,

could anyone please post a guide to install pyload with the newest version of nas4free? When i use the guide from Fire i get the same error like Ironcurtain.
I also tried Alestrix instructions.
With the command "/usr/local/bin/python /usr/local/share/pyload/pyLoadCore.py --daemon" i get the PID message
but with the command:
/usr/local/bin/python /usr/local/share/pyload/pyLoadCore.py --q
it says that no pyload is running.

I hope anyone can help me.

himbrr
Advanced User
Advanced User
Posts: 153
Joined: 21 Oct 2012 21:16
Location: Germany
Status: Offline

Re: [HOWTO] Installing pyload into jail

Post by himbrr »

Hi,

I have this problem, too. Build the jail with freebsd 9.2.
Do you have any news about this issue?

Jack8Coke: Try to run pyload not as deamon ( "/usr/local/bin/python /usr/local/share/pyload/pyLoadCore.py"). Then you'll see the errors.

best regards,
himbrr
Nas4Free 9.2.0.1.972, ASUS P8H77-I, 8GB RAM, Intel Celeron CPU G530 @ 2.40GHz, 5x 2TB WD Red, 1x 60GB OCZ Vertex 2

Post Reply

Return to “Jails”