From owner-freebsd-geom@FreeBSD.ORG Mon Jul 30 16:17:34 2012 Return-Path: Delivered-To: freebsd-geom@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 8B58D106564A for ; Mon, 30 Jul 2012 16:17:34 +0000 (UTC) (envelope-from freebsd@psconsult.nl) Received: from mx1.psconsult.nl (unknown [IPv6:2001:7b8:30f:e0::5059:ee8a]) by mx1.freebsd.org (Postfix) with ESMTP id 0B6448FC1A for ; Mon, 30 Jul 2012 16:17:33 +0000 (UTC) Received: from mx1.psconsult.nl (mx1.iaf.psconsult.nl [80.89.238.138]) by mx1.psconsult.nl (8.14.5/8.14.4) with ESMTP id q6UGHRMd091629 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO) for ; Mon, 30 Jul 2012 18:17:32 +0200 (CEST) (envelope-from freebsd@psconsult.nl) Received: (from paul@localhost) by mx1.psconsult.nl (8.14.5/8.14.4/Submit) id q6UGHRF1091628 for freebsd-geom@freebsd.org; Mon, 30 Jul 2012 18:17:27 +0200 (CEST) (envelope-from freebsd@psconsult.nl) X-Authentication-Warning: mx1.psconsult.nl: paul set sender to freebsd@psconsult.nl using -f Date: Mon, 30 Jul 2012 18:17:27 +0200 From: Paul Schenkeveld To: freebsd-geom@freebsd.org Message-ID: <20120730161727.GA90551@psconsult.nl> References: <803675128.20120730002927@serebryakov.spb.ru> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <803675128.20120730002927@serebryakov.spb.ru> User-Agent: Mutt/1.5.21 (2010-09-15) Subject: Re: "nextboot" for MBR slice? X-BeenThere: freebsd-geom@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: GEOM-specific discussions and implementations List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 30 Jul 2012 16:17:34 -0000 On Mon, Jul 30, 2012 at 12:29:27AM +0400, Lev Serebryakov wrote: > Hello, Freebsd-geom. > > Is it possible to implement something like "nextboot" for MBR > slice? I don't know of such implementation. > I have typical NanoBSD installation: CF card divided into tow slices > (ad1 and ad2), standard boot0 (as "smart" boot0 with partition > selection doesn't play well with serial console), each slice contains > full NanoBSD installation, current one and previous one. When I need > upgrade "firmware" I dd new image on "previous" slice and set > active bit in MBR (with gpart set -a active) to it, reboot. Did you try to use boot0sio? I run dozens of NanoBSD systems, most are Soekris hardware with serial console, system on flash (CF, mSATA or soldered on the mainboard) so that matches the hardware you describe. There was a change in the working of boot0 and boot0sio a couple of years ago. Before the change (FB <= 7) one would use boot0cfg to change the active partition. Now (FB >= 8) one should use 'gpart set -a active -i '. The default slice reported during boot can be misleading after changing the active slice with gpart but you can still use the serial terminal to switch boot partitions. HTH, Paul Schenkeveld