Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 30 Aug 2009 22:53:28 +0800 (KRAST)
From:      Eugene Grosbein <eugen@grosbein.pp.ru>
To:        FreeBSD-gnats-submit@FreeBSD.org
Subject:   misc/138347: [patch] [nanobsd] nanobsd build is broken due to mdconfig(8) change
Message-ID:  <200908301453.n7UErS76071421@grosbein.pp.ru>
Resent-Message-ID: <200908301500.n7UF08KH085564@freefall.freebsd.org>

next in thread | raw e-mail | index | archive | help

>Number:         138347
>Category:       misc
>Synopsis:       [patch] [nanobsd] nanobsd build is broken due to mdconfig(8) change
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Sun Aug 30 15:00:08 UTC 2009
>Closed-Date:
>Last-Modified:
>Originator:     Eugene Grosbein
>Release:        FreeBSD 8.0-BETA3 i386
>Organization:
private person
>Environment:
System: FreeBSD grosbein.pp.ru 8.0-BETA3 FreeBSD 8.0-BETA3 #6: Fri Aug 28 22:34:15 KRAST 2009 eugen@grosbein.pp.ru:/usr/local/obj/usr/local/src/sys/DADV i386

>Description:
	After http://www.freebsd.org/cgi/query-pr.cgi?pr=116177,
	mdconfig returns non-zero exit status if called for non-existing
	device. This reveals a bug of src/tools/tools/nanobsd/nanobsd.sh
	sitting here from revision 1.1: inside create_i386_diskimage(),
	it does "mdconfig -d -u $MD" as last statement
	then runs the same command again as part of "trap ... EXIT" procedure
	and fails due to not masked non-zero exit status

>How-To-Repeat:
	Try to build nanobsd.

>Fix:

	Remove extra mdconfig call:

--- tools/tools/nanobsd/nanobsd.sh.orig	2009-08-30 22:39:54.000000000 +0800
+++ tools/tools/nanobsd/nanobsd.sh	2009-08-30 22:40:00.000000000 +0800
@@ -490,7 +490,6 @@
 
 	echo "Writing out _.disk.image..."
 	dd if=/dev/${MD}s1 of=${NANO_DISKIMGDIR}/_.disk.image bs=64k
-	mdconfig -d -u $MD
 	) > ${NANO_OBJ}/_.di 2>&1
 )
 


>Release-Note:
>Audit-Trail:
>Unformatted:



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200908301453.n7UErS76071421>