Fresh installation on top of a old system in ZFS
Ross Penner
rossp at f-m.fm
Thu Feb 27 06:03:15 UTC 2014
On Sat, 22 Feb 2014, at 02:36 PM, Darren Pilgrim wrote:
> On 2/22/2014 12:11 PM, Ross Penner wrote:
> > I'm hoping to get some guidance on the best way to create a fresh
> > FreeBSD install using my existing drives partitioned with ZFS.
> >
> > The old set up is with two drives of different sizes. The smaller one is
> > mirrored with a partition of equal size on the larger drive to create
> > one pool which is the root and boot partition. A second pool is made of
> > the remaining space on the larger drive mounted at /tank/
> >
> > I booted the USB image of FreeBSD 10 and I couldn't see an obvious way
> > to use my old partitions as the base for the new system. Any advice that
> > could be offered would be really appreciated!
>
> What does your ZFS dataset structure look like? If your root is not the
> base dataset, you can install the new OS in parallel, change the bootfs
> and mountpoints and boot into the new OS leaving the old one untouched.
> For example, on a system that's been upgraded from 9.x to 10.x:
>
> # zfs list -o name,mountpoint
> NAME MOUNTPOINT
> tank none
> tank/home /home
> tank/logs /var/log
> tank/mail /var/mail
> tank/osroot9 none
> tank/osroot9/tmp none
> tank/osroot9/usr none
> tank/osroot9/usr/local none
> tank/osroot9/usr/obj none
> tank/osroot9/usr/src none
> tank/osroot9/var none
> tank/osroot9/var/empty none
> tank/osroot9/var/tmp none
> tank/osroot10 /
> tank/osroot10/tmp /tmp
> tank/osroot10/usr /usr
> tank/osroot10/usr/local /usr/local
> tank/osroot10/usr/obj /usr/obj
> tank/osroot10/usr/src /usr/src
> tank/osroot10/var /var
> tank/osroot10/var/empty /var/empty
> tank/osroot10/var/tmp /var/tmp
> tank/ports /usr/ports
> tank/db/postgresql /usr/local/pgsql
> tank/samba /samba
> tank/www /usr/local/www
>
I think I need to add some clarity about my setup. I had a mini-itx all
in one system that died on me. I bought a replacement system and
attached the same harddrives. The system boots and the ZFS filesystems
are available.
I have two zpools. zroot which is mounted root and tank which was
mounted at /tank.
I'm trying to follow this
(http://freebsdwiki.net/index.php/ZFS,_booting_from) guide, but my
importing my zpools instead of creating them.
The pools function fine when I boot off the harddrives, but I can't seem
to import them from the shell. 'zpool import -f -o altroot=/mnt zroot'
returns errors saying that none of the file systems are loaded. The same
happens for tank.
Can anybody offer any insight?
Thanks
More information about the freebsd-questions
mailing list