# Migrating the iocage Dataset to Another Pool

First, you migrate your pools like this :

```
iocage stop ALL
zfs unmount -f tank/iocage
zfs snapshot -r tank/iocage@migration
zfs send -R tank/iocage@migration | zfs receive -v dozer/iocage
iocage clean -a
zfs destroy -f tank/iocage
iocage activate dozer
zfs destroy -r dozer/iocage@migration
```

Here, you should use your own pool names.  
The old pool is named `tank`, the new one `dozer`

Then, you could need to edit your jail mount points.  
To do this, you have to :  
1\. Set `nano` as your editor (optional if you know how to search and replace with `vi`)

```
EDITOR=/usr/local/bin/nano; export EDITOR
```

Then edit the `fstab` of your jails

```
iocage fstab -e yourjail
```

Then do search and replace all with `nano`, searching with your old mountpoint `/mnt/tank/iocage` with `/mnt/dozer/iocage`

Tested on 11.2U1