Date: Sat, 10 Dec 2011 17:46:12 +0100 From: Robert Millan <rmh@freebsd.org> To: Volodymyr Kostyrko <c.kworr@gmail.com> Cc: freebsd-fs@freebsd.org, Adrian Chadd <adrian@freebsd.org> Subject: Re: [PATCH] Wipe other file systems when creating new UFS Message-ID: <CAOfDtXMKK2p1q4a_KvmswAHZpRAooP0HcPnBEt8TK2QE1S92AA@mail.gmail.com> In-Reply-To: <4EE221F9.9010505@gmail.com> References: <20111208134307.GA5266@thorin> <4EE221F9.9010505@gmail.com>
next in thread | previous in thread | raw e-mail | index | archive | help
2011/12/9 Volodymyr Kostyrko <c.kworr@gmail.com>: > <flame> > Shouldn't it make us a coffee then? Making precautions against > shooting-the-foot is a wrong choice for me. This way we need to extend it to > support any other file system that can repair thyself upon mount in case > user mistakenly mounted the wrong one. > </flame> This suggests you don't agree with the premise that file systems need to be identifiable. We could argue about this, but note that existing behaviour is entirely consistent with this premise: - newfs stores an UFSv2 signature on disk - fsck checks for this signature and refuses to operate - newfs checks for UFSv1 signature and makes sure it is cleared out before creating a new UFSv2 - the kernel checks for UFS signature before attempting to mount a file system > What about drives that support SSD? Isn't it convenient to use TRIM in such > cases? As I'm quite unfamiliar with SSD, I'd rather have someone else answer that. My impression, however, is that this improvement would most likely belong in berase() and be completely orthogonal to my patch. > You messing up ZFS terminology a bit. Uberblock size is 1k and what you > refer is ZFS vdev label. Size of vdev label is 256k. There are four vdev > labels for each vdev - two at the beginning of the vdev and two at the end. Ah yes, I probably confused the concepts, I was working from memory and it's been a while since I read the spec. > All vdev labels are _aligned_ to 256k. So technically this is not just last > 512k. I see that you mean. I guess just aligning down "mediasize" to 256 kiB before using it would suffice?
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?CAOfDtXMKK2p1q4a_KvmswAHZpRAooP0HcPnBEt8TK2QE1S92AA>