From owner-freebsd-bugs@FreeBSD.ORG Wed Oct 2 14:00:01 2013 Return-Path: Delivered-To: freebsd-bugs@smarthost.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTP id 7911719B for ; Wed, 2 Oct 2013 14:00:01 +0000 (UTC) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [IPv6:2001:1900:2254:206c::16:87]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id 4409D2CEC for ; Wed, 2 Oct 2013 14:00:01 +0000 (UTC) Received: from freefall.freebsd.org (localhost [127.0.0.1]) by freefall.freebsd.org (8.14.7/8.14.7) with ESMTP id r92E01eL083804 for ; Wed, 2 Oct 2013 14:00:01 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.14.7/8.14.7/Submit) id r92E01lE083803; Wed, 2 Oct 2013 14:00:01 GMT (envelope-from gnats) Resent-Date: Wed, 2 Oct 2013 14:00:01 GMT Resent-Message-Id: <201310021400.r92E01lE083803@freefall.freebsd.org> Resent-From: FreeBSD-gnats-submit@FreeBSD.org (GNATS Filer) Resent-To: freebsd-bugs@FreeBSD.org Resent-Reply-To: FreeBSD-gnats-submit@FreeBSD.org, Anes Mukhametov Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTP id 5FC76F59; Wed, 2 Oct 2013 13:51:57 +0000 (UTC) (envelope-from amuhametov@amuhametov.park.rambler.ru) Received: from amuhametov.park.rambler.ru (amuhametov.park.rambler.ru [81.19.64.112]) by mx1.freebsd.org (Postfix) with ESMTP id 13F6A2C94; Wed, 2 Oct 2013 13:51:56 +0000 (UTC) Received: by amuhametov.park.rambler.ru (Postfix, from userid 502) id 5BB5F3C6974; Wed, 2 Oct 2013 17:42:58 +0400 (MSK) Message-Id: <20131002134259.5BB5F3C6974@amuhametov.park.rambler.ru> Date: Wed, 2 Oct 2013 17:42:58 +0400 (MSK) From: Anes Mukhametov To: FreeBSD-gnats-submit@freebsd.org X-Send-Pr-Version: 3.114 Subject: bin/182574: freebsd-update can not update custom release with custom kernels Cc: Colin Percival X-BeenThere: freebsd-bugs@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list Reply-To: Anes Mukhametov List-Id: Bug reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 02 Oct 2013 14:00:01 -0000 >Number: 182574 >Category: bin >Synopsis: freebsd-update can not update custom release with custom kernels >Confidential: no >Severity: serious >Priority: medium >Responsible: freebsd-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: sw-bug >Submitter-Id: current-users >Arrival-Date: Wed Oct 02 14:00:00 UTC 2013 >Closed-Date: >Last-Modified: >Originator: Anes Mukhametov >Release: FreeBSD 9.2-STABLE >Organization: >Environment: >Description: I use custom FreeBSD releases which include more than one custom kernel. In my case I can't update with freebsd-update, it fails with fetch_metadata_bogus. The reason is custom kernel path /boot/kernel.CUSTOMKERNEL is invalid for freebsd-update. Attached patch fixes this behaviour. >How-To-Repeat: Build your own release with more than one kernel (GENERIC+XENHVM for example). Set up freebsd-update server and try to update. >Fix: --- freebsd-update.sh.diff begins here --- Index: usr.sbin/freebsd-update/freebsd-update.sh =================================================================== --- usr.sbin/freebsd-update/freebsd-update.sh (revision 254897) +++ usr.sbin/freebsd-update/freebsd-update.sh (working copy) @@ -1206,7 +1206,7 @@ # Check that the first four fields make sense. if gunzip -c < files/$1.gz | - grep -qvE "^[a-z]+\|[0-9a-z]+\|${P}+\|[fdL-]\|"; then + grep -qvE "^[a-z]+\|[0-9a-zA-Z\.]+\|${P}+\|[fdL-]\|"; then fetch_metadata_bogus "" return 1 fi --- freebsd-update.sh.diff ends here --- >Release-Note: >Audit-Trail: >Unformatted: