From owner-freebsd-current@freebsd.org Fri Jan 27 18:26:27 2017 Return-Path: Delivered-To: freebsd-current@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 55B74CC0C57 for ; Fri, 27 Jan 2017 18:26:27 +0000 (UTC) (envelope-from wlosh@bsdimp.com) Received: from mailman.ysv.freebsd.org (unknown [127.0.1.3]) by mx1.freebsd.org (Postfix) with ESMTP id 30D89987 for ; Fri, 27 Jan 2017 18:26:27 +0000 (UTC) (envelope-from wlosh@bsdimp.com) Received: by mailman.ysv.freebsd.org (Postfix) id 2D4F2CC0C56; Fri, 27 Jan 2017 18:26:27 +0000 (UTC) Delivered-To: current@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 2CF50CC0C55 for ; Fri, 27 Jan 2017 18:26:27 +0000 (UTC) (envelope-from wlosh@bsdimp.com) Received: from mail-io0-x235.google.com (mail-io0-x235.google.com [IPv6:2607:f8b0:4001:c06::235]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id E69D5985 for ; Fri, 27 Jan 2017 18:26:26 +0000 (UTC) (envelope-from wlosh@bsdimp.com) Received: by mail-io0-x235.google.com with SMTP id v96so66906820ioi.0 for ; Fri, 27 Jan 2017 10:26:26 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bsdimp-com.20150623.gappssmtp.com; s=20150623; h=mime-version:sender:in-reply-to:references:from:date:message-id :subject:to:cc:content-transfer-encoding; bh=aQpWxqitXl3pgJhQW2OFt3Cc4pKuHl3Xe8R+8vRYDP4=; b=IsF7NPI23OWAjVsNC0/pS3s+MB8SHyhIT32VPyVAsfjrQggrF9yy0Ls7SkgZOYZ9az 5/y0WvVfyhDw7NOOBhXNXbV9FPyxKDOP8bIcT0WEsG7OTjrqwwOTNU6YK/7yd+VPOCtO gQYkJ6VKZE5JTlR4/ctyAYfRrkuXCGeKWyIkwUQTddtsa6pIOX2k5jssYz9lfzxN9ZUX gvZPIAgfxSKBcSG0pifxwckfyRnjI+N34ygGb/fAFGFnAb9Uq5zuBfd3g6xeWbetUD5s 3w6Si379iHffkEjqNpbEgf7uAjkFTqPa2yr6pczLFwXgKj4bXIXh60r1hroSgMerJHu4 OpjA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:sender:in-reply-to:references:from :date:message-id:subject:to:cc:content-transfer-encoding; bh=aQpWxqitXl3pgJhQW2OFt3Cc4pKuHl3Xe8R+8vRYDP4=; b=Lfmry8To67qpbMA5fshMz8CROKekysAyTzBP6tE2zIHyNPP4JEa1khhamaVS9+gRh2 HJw5PyyuK+yG78i1xIhaKKDmXbXqcdnbfy+1D1zsKC9avRtvu6wHEmGjEiaji9Rs2vdL mzkyCWa/nea3mgjF3akDLNy/8NQmZqrGb6HQZZtDtprVBN7JICG9jfu3EcPgWlSexthK sWy5NfzyuTDMsUJzgfMsMlTJLNE/Un4eXglw9UGXZSdkvdnn9LA9Bi9WLsUOnOien/yI y8xHWHY9zQt9vDPr5wGc7uHNgSVk/4rro20AJ0ndx+R4KgIrWIDsYjl937G0L7NZJGr7 UjhA== X-Gm-Message-State: AIkVDXKhJaO3PKCeuuoRza/ESpvku+zJ0rrZu+7HIokQDNqdzSpKjw+VRqn7CEKdaD/WuS1dQ9gbUT0EXj6/Wg== X-Received: by 10.107.20.13 with SMTP id 13mr8349691iou.0.1485541586233; Fri, 27 Jan 2017 10:26:26 -0800 (PST) MIME-Version: 1.0 Sender: wlosh@bsdimp.com Received: by 10.79.145.217 with HTTP; Fri, 27 Jan 2017 10:26:25 -0800 (PST) X-Originating-IP: [50.253.99.174] In-Reply-To: <94f227b6-1f94-e54a-825a-dd9554c3bea3@freebsd.org> References: <444df1a4-1f27-49a8-6fa6-81f5853e6d80@freebsd.org> <20170127173338.wv6dul7zhxaaw4f4@mutt-hardenedbsd> <94f227b6-1f94-e54a-825a-dd9554c3bea3@freebsd.org> From: Warner Losh Date: Fri, 27 Jan 2017 11:26:25 -0700 X-Google-Sender-Auth: _cMCjkmu9UmH0z4diKHZDaN5GFQ Message-ID: Subject: Re: gptzfsboot grew a lot after skein support was added; need knob to control bloat To: Allan Jude Cc: Shawn Webb , Toomas Soome , "Ngie Cooper (yaneurabeya)" , FreeBSD Current Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 27 Jan 2017 18:26:27 -0000 On Fri, Jan 27, 2017 at 10:35 AM, Allan Jude wrote: > On 2017-01-27 12:33, Shawn Webb wrote: >> On Fri, Jan 27, 2017 at 12:30:17PM -0500, Allan Jude wrote: >>> On 2017-01-27 12:05, Warner Losh wrote: >>>> On Fri, Jan 27, 2017 at 12:34 AM, Toomas Soome wrote: >>>>> >>>>>> On 27. jaan 2017, at 1:40, Ngie Cooper (yaneurabeya) wrote: >>>>>> >>>>>> Hi, >>>>>> I tried upgrading one of my workstations and unfortunately the= freebsd-boot partition is too small (I follow manpage directions, exactly,= and those seem to be too small as of 10.3-RELEASE timeframe), and I don???= t have enough space or ability to resize the partition and make it bigger. = So, I???m in need of a build knob to control the bloat, and/or having an al= ternative boot loader without geli/skein/crypto support compiled in. Would = you be opposed to the work? >>>>>> Thanks, >>>>>> -Ngie >>>>> >>>>> >>>>> I do agree that since the geli knob is already there, it may do. Of c= ourse we also can think of additional knobs, but there is an issue - it won= t help just to exclude some files, the additional features also do sit in t= he code, so the replacement stubs will be needed, also testing them all ove= r will take some time. And the preprocessor spaghetti really is nasty thing= to deal with;) >>>>> >>>>> And then there is another issue (partly why I did the feature support= in first place) - as the kernel does not block user from enabling the feat= ures, the user can end up facing non-bootable setup which is also not good,= as user is using perfectly legal options, and still the whole thing is jus= t rendered unusable??? >>>> >>>> I'm curious why you can't find the space for a bigger partition? >>>> Almost all drives these days are partitioned with a little wasted >>>> space, and that wasted space should be more than enough to cover us >>>> here. Also, most drives have a swap partition that can be shrunk a >>>> trivial amount to get space for this... >>>> >>>> Warner >>>> >>> >>> I need to do some testing to make a recipe that works for it, but the >>> other option is to use the ZFS bootcode area. >>> >>> ZFS it self, reserves something like 3.5 mb of space in the ZFS >>> partition, for boot code. This is how we boot ZFS on MBR. >>> >>> It should be possible to use this on GPT as well, we just don't. >> >> In the future, maybe it'd be a good idea for the installer to leave >> more space (a few MB, perhaps?) between the freebsd-boot and >> freebsd-swap partitions? At least, for ZFS installs. >> >> Thanks, >> > > The PMBR code has a limitation for 536kb, and it all has to fit under > the 640k barrier, so the current 512kb size is plenty. The issue is some > people are upgrading from systems that were isntalled long ago, when > 64kb or less was the default. it's a limitation for the entire partition size, not just the code size. Which is a trap that's hard to understand at first... Warner