Is it simple to move my plugin jail to another pool?

atomic007za

Cadet
Joined
Apr 17, 2018
Messages
2
I used rsync to move my jails.
Not sure if I will have an issue later.
I only use Nextcloud

My config:
Old Jail mount point: /mnt/Data/
New Jail mount point /mnt/Data1/

stop all jails:
Jail/View Jails stop
and
Plugins/installed stop

rsync -arvh --delete --progress /mnt/Data/ /mnt/Data1/
go to Jails/Configuration
change jail root from /mnt/Data to /mnt/Data1

start all jails:
Jail/View Jails start
and
Plugins/installed start.

All seems to be working fine.
 

ric

Contributor
Joined
Dec 22, 2013
Messages
180
I followed your instructions then I changed my jail>configuration from /mnt/tank/jails to /mnt/tank/newjails_location, and when I check the newjails_location dataset to see if there's any file transferred but there was zero file on the new Jail Root: jails_pool_new so what I did was reinstalled all the plugins.

sent 8.48M bytes received 65.69K bytes 813.89K bytes/sec
total size is 13.43G speedup is 1,571.73
root@freenas:~ #

As you can see, jails are still on the original location. Pls see attached screenshot.

i have a few jails that I wanted to migrate including jails_2, and jails_3 and then after the migration is complete I want to delete them completely from original location.


 

Attachments

  • storage_volumes.png
    storage_volumes.png
    125.2 KB · Views: 399
Last edited:

Martynk

Cadet
Joined
Dec 21, 2018
Messages
2
Hi guys!
The steps worked as a charm for me also, though I felt a bit like black magic when I typed the commands...:)
Just wanted to say thank you, I've been at this problem for two days!
 

danjng

Explorer
Joined
Mar 20, 2017
Messages
51
Logged in just to post that your instructions still hold up! Ran them but subbed out jails with iocage. Worked like a charm! Thanks!!

Edit: Don't forget to change the paths in your mount point paths. My jails wouldn't start up because I destroyed my original jail pool. I actually had to manually go in an edit the fstab file for the impacted jails to correct to the new pool name. After that everything came up as normal.
 
Last edited:
Joined
Jul 31, 2019
Messages
1
Logged in just to post that your instructions still hold up! Ran them but subbed out jails with iocage. Worked like a charm! Thanks!!

Edit: Don't forget to change the paths in your mount point paths. My jails wouldn't start up because I destroyed my original jail pool. I actually had to manually go in an edit the fstab file for the impacted jails to correct to the new pool name. After that everything came up as normal.

I'm doing the same thing, but getting a bit stuck at editing the fstab file for the jails I moved. If I could pick peoples' brains? I haven't deleted the original dataset yet. I found if I got to /mnt/iocage/jails that there are folders for each jail and an fstab in those, but the files are either empty or don't contain and references to the older dataset.

At the moment I'm not certain FN has picked up where the jails are running from correctly because even though I have used the jail config to point to the new location ad rebooted, I cannot delete (for example) the log dataset in the original pool as it is still in use.

I've also done a zfs get mount and there are two entries for /mnt/iocage

General/iocage mountpoint /mnt/iocage local
OurData/iocage mountpoint /mnt/iocage received

The first one is the original pool and the second enty is the shiny new location. I'm guessing with iocage, I need to somehow configure things so the old one is no longer mounted? (I'm not certain of what local and received means)
 
Last edited:
Top