From owner-freebsd-questions@FreeBSD.ORG Wed Feb 15 20:09:00 2012 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 1468A106567F for ; Wed, 15 Feb 2012 20:09:00 +0000 (UTC) (envelope-from jrisom@gmail.com) Received: from mail-yw0-f54.google.com (mail-yw0-f54.google.com [209.85.213.54]) by mx1.freebsd.org (Postfix) with ESMTP id C46938FC13 for ; Wed, 15 Feb 2012 20:08:59 +0000 (UTC) Received: by yhfs35 with SMTP id s35so1062892yhf.13 for ; Wed, 15 Feb 2012 12:08:59 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=message-id:date:from:user-agent:mime-version:to:subject:references :in-reply-to:content-type:content-transfer-encoding; bh=5EaV7KwA1KTB9wWYR5CVamy9FwO/+uVq4xW2XpD2h4M=; b=Wb8BKm/Gx5sM1EJXWReNHWXy8ja5uBMBcUteeDQKupYDm1fQMO0e9Y2gq03KBB+8IB qucdNQQa63qifJdqvn3kBy9xVkKKdf/h5HgB+8YLJn3bGjEzuPil5A+C7Pt+UcdcASKq 5KajybpLEn8zO861JQUKk7pCHi9sTI4lxeDuo= Received: by 10.50.196.167 with SMTP id in7mr14204659igc.9.1329336539032; Wed, 15 Feb 2012 12:08:59 -0800 (PST) Received: from [192.168.1.3] (c-98-212-197-29.hsd1.il.comcast.net. [98.212.197.29]) by mx.google.com with ESMTPS id b6sm6109351igj.7.2012.02.15.12.08.57 (version=SSLv3 cipher=OTHER); Wed, 15 Feb 2012 12:08:57 -0800 (PST) Message-ID: <4F3C10CD.3040209@gmail.com> Date: Wed, 15 Feb 2012 14:08:45 -0600 From: Joshua Isom User-Agent: Mozilla/5.0 (Windows NT 6.0; rv:10.0.1) Gecko/20120208 Thunderbird/10.0.1 MIME-Version: 1.0 To: freebsd-questions@freebsd.org References: <20120214044816.GA18161@daniel3.local> <20120215003110.GA32543@daniel3.local> <20120215174811.GA14636@daniel3.local> In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Subject: Re: zroot won't mount after 9.0-RC2 -> 9.0-RELEASE upgrade X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Feb 2012 20:09:00 -0000 On 2/15/2012 12:03 PM, George Kontostanos wrote: > On Wed, Feb 15, 2012 at 7:48 PM, Daniel Shahaf wrote: >> So far we've tried: >> >> - 'gpart bootcode -b' >> - load geom_part_gpt.ko >> - using zpool.cache from the 9.0-RELEASE CD >> >> And none of that seems to have had any effect. >> >> Additional info: from the CD environment, 'zpool import' reports an old >> 'tank' pool on devices mfid[2-5]. (The 'zroot' pool uses mfid[0-5]p3.) >> >> Any further ideas, please? >> >> Thanks for all the suggestions so far. > > You are running ZFS version 4 while the default is 5 on 9.0-RELEASE > > ---> Assuming your pool is called zroot > --->This is the way to update your zpool.cache:<--- > > Boot with 9.0-RELEASE and proceed with: > > #zpool import -o altroot=/mnt -o cachefile=/var/tmp/zpool.cache zroot > > #zfs set mountpoint=/mnt zroot > #zfs set mountpoint=/mnt/usr zroot/usr > #zfs set mountpoint=/mnt/var zroot/var > #zfs set mountpoint=/mnt/tmp zroot/tmp > > ## Ignore any warnings## > > Now export the pool: > > #zpool export -f zroot > > Import the pool back and update the zpool.cache: > > #zpool import -o cachefile=/var/tmp/zpool.cache zroot > #cp /var/tmp/zpool.cache /mnt/boot/zfs/zpool.cache > > Make sure that bootfs is set correctly: > > #zpool set bootfs=zroot zroot > > Now, unmount any ZFS datasets > > #zfs umount -af > > And fix mountpoints: > > #zfs set mountpoint=legacy zroot > #zfs set mountpoint=/tmp zroot/tmp > #zfs set mountpoint=/usr zroot/usr > #zfs set mountpoint=/var zroot/var > > That should be enough to update your zpool.cache > > If this still doesn't work then you can upgrade your ZFS version to 5. > > Make sure you have backups first!!! > > Before unmounting your datasets issue a: > > zfs upgrade -a > I remember doing something similar. It took me a few hours to figure everything out and repeated reboots to attempt to get it working. I believe what worked for me wasn't mounting it in /mnt, but actually mounting on / and making sure the cache file was in the zfs pool. I think I had to make a copy because zfs wanted to export the pool before shutdown which defeated the point. It was almost a year ago that I dealt with it. I'm 90% sure it's a cache file issue, and it's just getting it working properly. Note: I've never had a problem when upgrading from /usr/src, it was only when I was moving datasets to different drives, adding hard drives, and redoing my hard drive arrangement.