From nobody Tue Apr 11 17:35:40 2023 X-Original-To: freebsd-hackers@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4PwtKV1QfHz44FZJ for ; Tue, 11 Apr 2023 17:35:42 +0000 (UTC) (envelope-from grahamperrin@freebsd.org) Received: from smtp.freebsd.org (smtp.freebsd.org [IPv6:2610:1c1:1:606c::24b:4]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "smtp.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4PwtKT6YZgz3Nk4; Tue, 11 Apr 2023 17:35:41 +0000 (UTC) (envelope-from grahamperrin@freebsd.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1681234541; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=kGE6ErXs6VLGVhwj8YtrOWa/LoXUsaQMbVeqUeL3pLY=; b=oiAG441Msww6ppXK+1/Iel6JYkGQlJVKCCsWkvuHxesGFF05nXkjmnHNrq+VjCh8CHc6na wheTvoq/7t97bHnX6kOHpJRUds2Jkhr7yMh3uyCPZRnfY61ge9BEW9sWL7ISCUF4qnQnwG 69ltdJrXxjW2dzxblD9+27YhirREaRAuKaoSie67O6bI95TzIH6ddS2gdFRk7ml4n6XzvP a+FwPW3jSAaMaZBXYGdb0x1vvL/C5HzfLkHQ8q4ZzuSB8X7UdMjEmRfPYnB9Da+ME0/77t lzfEqjD9wLLFXU2I1epwD6nkf+9JNarqa/gXsofbxu5HeaTNMZXZ757EyK/PBw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1681234541; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=kGE6ErXs6VLGVhwj8YtrOWa/LoXUsaQMbVeqUeL3pLY=; b=pOL3/dzE/LDe2gm71G213VKBz90ueVs1q26jNAnXxtgO5RUIzw36eXvjusP+PaDfCr5C53 gG7ZFjZdcdhNnchwwx+vJy6+3JKWXRynyfZDHkzSSpMxWoYyZ2mqBJgxPK5cIcqvHErTgz g/qUVsTXZ3NDT0s7LFBadgQTUYYxu2PcrshXbel5nXoI1yOcFfoIRo9NpR3S9PLBqjRcFK lcFVgJaOUfyncAHUTPHVCQz8bpx8whu/yPPXCPwsNTvEmfunDH4wFHjVl4Ah0XCmMFhMFy K31ZLu68hmANhlbXh9qakDIfhc1+noGQwQc0k2jMq0uJeWBnhWKM6yaCL9tdYw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1681234541; a=rsa-sha256; cv=none; b=kNPvht3ayCcXQNxdP0YMzZyNslkb6Gej3rIrlQbVoPYPhLQrm39gglhIF5Jr+KFWj5Khnf l61zrnwShWwWr5LsNDUcbllpX5YFJhudacFpfyFSpR4naADsgjY78F3iSmVUfncZscjmn+ WmWR/CkufJjjXEl1wkNQnViIHufx4YpWdPPeEgZNtqH+h+QQBGKBCIYSXjn66YEZhAQJdL TmqA7q+dUuqYG5Zxh1YJx6/ZUXyjS3POOe0wDJv0s2Wb5kIcn9u2cPNH7WYNmc1Tpa60Gd IryNUFEJl/tyuzBxgf1QlzZGkIyixh0CzmNMRWpsHU1+ak92Mxt8ZfzYpNmuJA== Received: from [IPV6:2001:470:1f1c:a0::2] (tunnel642390-pt.tunnel.tserv1.lon2.ipv6.he.net [IPv6:2001:470:1f1c:a0::2]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits)) (Client did not present a certificate) (Authenticated sender: grahamperrin) by smtp.freebsd.org (Postfix) with ESMTPSA id 4PwtKT3Kzyz15Zb; Tue, 11 Apr 2023 17:35:41 +0000 (UTC) (envelope-from grahamperrin@freebsd.org) Message-ID: <519b5387-4561-94a1-f2e1-6fe6c4a4f35e@freebsd.org> Date: Tue, 11 Apr 2023 18:35:40 +0100 List-Id: Technical discussions relating to FreeBSD List-Archive: https://lists.freebsd.org/archives/freebsd-hackers List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-freebsd-hackers@freebsd.org MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:102.0) Gecko/20100101 Thunderbird/102.10.0 Subject: Re: gpart destroy, in depth Content-Language: en-US To: Warner Losh Cc: FreeBSD Hackers References: <64e88636-1e03-7ff5-7d3f-e8a36117cdbe@freebsd.org> From: Graham Perrin Organization: FreeBSD In-Reply-To: Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="------------esgQ6W4xJg61g3ZGvhVjs5XT" X-ThisMailContainsUnwantedMimeParts: N This is an OpenPGP/MIME signed message (RFC 4880 and 3156) --------------esgQ6W4xJg61g3ZGvhVjs5XT Content-Type: multipart/mixed; boundary="------------Ev00wvEXl3XbZCKAeeyKdE0x"; protected-headers="v1" From: Graham Perrin To: Warner Losh Cc: FreeBSD Hackers Message-ID: <519b5387-4561-94a1-f2e1-6fe6c4a4f35e@freebsd.org> Subject: Re: gpart destroy, in depth References: <64e88636-1e03-7ff5-7d3f-e8a36117cdbe@freebsd.org> In-Reply-To: --------------Ev00wvEXl3XbZCKAeeyKdE0x Content-Type: multipart/alternative; boundary="------------mXhEaQsKUoxGdwtVYyQh0wmE" --------------mXhEaQsKUoxGdwtVYyQh0wmE Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: base64 T24gMTEvMDQvMjAyMyAxNDoyNCwgV2FybmVyIExvc2ggd3JvdGU6DQoNCj4gSXQgd3JpdGVz IHplcm9zIHRvIHRoZSBwYXJ0aXRpb24gdGFibGUuDQo+DQo+IFdhcm5lcg0KDQoNClRoYW5r cy4NCg0KSXMgaXQgcHJlY2lzZSBhYm91dCB3aGVyZSBpdCBjZWFzZXMgd3JpdGluZyB6ZXJv cyBpbiB0aGUgYXJlYXMgDQpwcmV2aW91c2x5IG9jY3VwaWVkIGJ5IHRoZSB0YWJsZSBhbmQg YmFja3VwIHRhYmxlPw0KDQpPciBkb2VzIGl0IChmb3Igd2FudCBvZiBhIGJldHRlciBleHBy ZXNzaW9uKSBzcGlsbCBvdmVyLCBhIGxpdHRsZT8NCg0KPg0KPiBPbiBUdWUsIEFwciAxMSwg MjAyMywgNzoxMyBBTSBHcmFoYW0gUGVycmluIDxncmFoYW1wZXJyaW5AZnJlZWJzZC5vcmc+ IA0KPiB3cm90ZToNCj4NCj4gICAgIFBsZWFzZTogd2hhdCwgZXhhY3RseSwgb2NjdXJzIHdo ZW4gYSBwYXJ0aXRpb24gdGFibGUgaXMgZGVzdHJveWVkIGJ5DQo+ICAgICBncGFydCg4KT8N Cj4NCj4gICAgIEJhY2tncm91bmQ6IOKApg0KPg0K --------------mXhEaQsKUoxGdwtVYyQh0wmE Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable

On 11/04/2023 14:24, Warner Losh wrote:

It writes zeros to the partition table.

Warner


Thanks.

Is it precise about where it ceases writing zeros in the areas previously occupied by the table and backup table?

Or does it (for want of a better expression) spill over, a little?


On Tue, Apr 11, 2023, 7:13 = AM Graham Perrin <grah= amperrin@freebsd.org> wrote:
Please: what, exactly, occurs when a partition table is destroyed by gpart(8)?

Background: =E2=80=A6
--------------mXhEaQsKUoxGdwtVYyQh0wmE-- --------------Ev00wvEXl3XbZCKAeeyKdE0x-- --------------esgQ6W4xJg61g3ZGvhVjs5XT Content-Type: application/pgp-signature; name="OpenPGP_signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="OpenPGP_signature" -----BEGIN PGP SIGNATURE----- wsF5BAABCAAjFiEEWT/lssMHB+28ly8Kt2dIb0oY1AsFAmQ1mmwFAwAAAAAACgkQt2dIb0oY1AuS 3BAAjmwJW00rhzXC2vypwP42dXn3FaPWEy2mqDFxy4PLMm5gmDNm1PFizDpSOYAdmieCm+OWJ2hS msaDJLeawwXi6sNx6ih39yCxANWrrzReHuhQ/KkCT2xCLY9moD5dvgF9Cbr2jqIRpHOyEyoRNceH n+NBwds4Mx0L1bWiCYOOGaKr06/Qt/GenmkYCFd8onOZ/1HGiyUl4iWtvH4UpByGrW26yN5gPevo wA4EgSLe11o2JhEzkHlYa1lW/iOVAaGXLdiULYn10sIr6l8ejLo8XWnxaYW1UChT48cjTS+fSfu6 Zfqbkmy37tnCa6AyWuYlECIyROV2QMTwZ3uxVLYhtNQ7erBJ3y/m8DPcMPlX19wmyGkRV0188u/i OqfUvjDNeHTYz9HGmsvzLjaO3mMr6siQHqSiPD1HXPSQFP4NL1XDUV38Ey10TUIUG/Tf2KsWtMvf 1W2gEVMBfdzDv2ckJX+HbFLfSNmj0t9qQpbR6hBBFvyFeBXTEdHWOkCsoJDpO/gLHDBNcADWt4tm wEdZqGl5cTx4sj6LTYFpiGlGD6QRZNoRSA4luJkjLiQvBNj5Oa/TEqUPR0FDbwIt8BhQxPGKFuwd pLd+CEY0XXqJvStfkN1m45FEDUUd9SIGZ58JuN0UOe9S4B0FJpp81hsVf0fI0IGqCtTaMYMxsXU+ oZM= =YrrA -----END PGP SIGNATURE----- --------------esgQ6W4xJg61g3ZGvhVjs5XT--