Page 1 of 1

jail help

Posted: 01 Jun 2014 08:25
by nfenech
hi all,

So i have a jail set up for sickbeard and alike.
I am able to get the jail working, able to download packages and sickbeard and get that running.
However i have tried and tried but can not get fstab to mount my files system.
I have no way of seeing all my data.

/mnt/tank/data <- hold data like movies/tv
/mnt/tank/downloads <- download
/mnt/tank/jail <- jails

So i have a jail set up
/mnt/tank/jail/apps/ <- apps is the jail.

If i just set it up, the jail starts. I can install to it, restart the server/jail and it will still work.
If stop the jail and add the fstab setting:
/mnt/tank/data /mnt/tank/jail/apps/mnt/data nullfs rw 0 0 (so i can read and write to all of my files)
Save and try and start the jail i get nothing. It will not start.
No errors.
If i point to a dir that does not exist, ie: /mnt/tank/data /mnt/tank/jail/apps/mnt/newfolder nullfs rw 0 0
I get an error that the path does not exist?
After i delete the fstab, the jail is still broken and will not start.

What am i doing wrong?

Re: jail help

Posted: 01 Jun 2014 09:03
by nfenech
I'm running the latest TheBrig (.8)
and Nas4Free 9.2.0.1 - Shigawire (revision 972)

I think i found the problem.
When i change the fstab settings it breaks the config file.
Looking at the export before and after:
Extract:

Code: Select all

<?xml version="1.0" encoding="UTF-8"?>
<NAS4Free revision="972" version="9.2.0.1">
	<content>
		<uuid>c1b21d89-eaf0-40a5-83a7-54f6c057f14d</uuid>
		<enable />
		<jailno>1</jailno>
		<jailname>apps</jailname>
		<jail_type>slim</jail_type>
		<if>le0</if>
		<ipaddr>192.168.1.241</ipaddr>
		<subnet>32</subnet>
		<jailpath>/mnt/tank/jail/apps/</jailpath>
		<devfsrules />
		<jail_mount />
		<exec_prestart />
		<exec_start>/bin/sh /etc/rc</exec_start>
		<afterstart0 />
		<afterstart1 />
Once i change the fstab i get:

Code: Select all

<?xml version="1.0" encoding="UTF-8"?>
<NAS4Free revision="972" version="9.2.0.1">
	<content>
		<uuid>c1b21d89-eaf0-40a5-83a7-54f6c057f14d</uuid>
		<enable />
		<jailno>1</jailno>
		<jailname>apps</jailname>
		<type />
		<if>le0</if>
		<ipaddr>192.168.1.241</ipaddr>
		<subnet>32</subnet>
		<jailpath>/mnt/tank/jail/apps/</jailpath>
		<jail_mount />
		<auxparam>
			<content>/mnt/tank/data /mnt/tank/jail/apps/mnt/data nullfs rw 0 0</content>
		</auxparam>
		<exec_prestart />
		<exec_start>/bin/sh /etc/rc</exec_start>
		<afterstart0 />
		<afterstart1 />
Notice how the Type is not complete (Should be slim)

Also, i can not seem to restore the old config? Am i doing something wrong?

Re: jail help

Posted: 01 Jun 2014 10:23
by nfenech
If i put all the setting in when creating the jail it seems to work.
It's once i modify any that the config breaks.

Once i install Sickbread, how do i make sure it starts up with the jail?
Where is the PostInit settings?

Or how do i create a startup script to start sickbeard, sabnzbd and couchpotato?
I have the commands, just need to know how to combine into one startup command as there all installed in the one jail.

Re: jail help

Posted: 04 Jun 2014 04:46
by nfenech
Anyone?

Just need to create a startup script to start sickbeard, sabnzbd and couchpotato.

Re: jail help

Posted: 05 Jun 2014 07:34
by raulfg3

Re: jail help

Posted: 06 Jun 2014 00:37
by nfenech
ok, so how do i create a start up script to start all my apps (Within the same jail)
do i just create nano a su.sh and place the commands in there?

Re: jail help

Posted: 06 Jun 2014 07:41
by raulfg3
yes

Re: jail help

Posted: 08 Jun 2014 10:29
by nfenech
I still have the problem with the config file.
I've created my jail but it wont start now.
looking at the config file, it's wrong.
As in it's missing '<jail_type>slim</jail_type>'
And i can not import a modified version. It wont work?
Where on the NAS is the config stored so i can use the built in editor to fix up this line?
I have searched and can not find it anywhere??
Does anyone know the location?

Re: jail help

Posted: 08 Jun 2014 13:11
by nfenech
found and fixed.
Jail is all working.
Still strange that it breaks the config file.