Date: Thu, 25 Jan 2024 11:27:16 -0800 From: Cy Schubert <Cy.Schubert@cschubert.com> To: Miroslav Lachman <000.fbsd@quip.cz>, Warner Losh <imp@bsdimp.com>, "Rodney W. Grimes" <freebsd-rwg@gndrsh.dnsmgr.net>, George Michaelson <ggm@algebras.org>, Ed Maste <emaste@freebsd.org>, FreeBSD Current <freebsd-current@freebsd.org> Subject: Re: Removing fdisk and bsdlabel (legacy partition tools) Message-ID: <20240125192716.DD3B6267@slippy.cwsent.com> In-Reply-To: <20240125101308.92E931A6@slippy.cwsent.com> References: <202401242347.40ONlWKZ099356@gndrsh.dnsmgr.net> <20240125050736.A11871AC@slippy.cwsent.com> <CANCZdfq%2BF1iFpUkDEYdcxPJfp96Ymz8KjBGaK_JNN1i09s7P=A@mail.gmail.com> <20240125055019.CCF1973@slippy.cwsent.com> <84c6f3b1-58b3-44f8-aeaf-35f78e05975d@quip.cz> <20240125101308.92E931A6@slippy.cwsent.com>
next in thread | previous in thread | raw e-mail | index | archive | help
In message <20240125101308.92E931A6@slippy.cwsent.com>, Cy Schubert writes: > In message <84c6f3b1-58b3-44f8-aeaf-35f78e05975d@quip.cz>, Miroslav Lachman > wri > tes: > > On 25/01/2024 06:50, Cy Schubert wrote: > > > In message <CANCZdfq+F1iFpUkDEYdcxPJfp96Ymz8KjBGaK_JNN1i09s7P=A@mail.gmai > l. > > c > > > > > > >> > > >> What can they do that gpart can't do? > > > > > > This was quite a while ago, booted off my recovery USB attempting to repa > ir > > > some self caused damage. The ability to edit (vi) a file with starting > > > addresses and lengths, visually using bsdlabel, was suited to my panicked > > > state as I worked to recover the machine. > > > > > > A visual view of columns of a bsdlabel, editing a label using vi, checkin > g > > > and double checking numbers before committing them is handy.The visual > > > format and the ability to adjust the numbers in an editor before committi > ng > > > them is handy. You can't do this with gpart, as it's transactional. And > > > bsdinstall doesn't give one the opportunity to check the numbers in detai > l > > > on a console before committing them. > > > > If you really like your editor of choice to edit partition table, you > > can use gpart backup and gpart restore like this: > > > > gpart backup ada0 > ada0.part > > vi ada0.part > > gpart restore -F -l < ada0.part > > That would work. > > > > > > Maybe a good GSoC project may be to replace bsdlabel's driect writes to > > > disk with geom calls. Though, t doesn't need to be bsdlabel, but some kin > d > > > of utility that displays the existing label in an editor session where > > > changes can be made, using the editor, and committed. This could even be > an > > > enhancement to bsdinstall: call it expert mode or whatever. > > > > Manipulating partition table in editor session can be achieved by few > > lines of shell script as a wrapper around gpart backup & gpart restore. > > Or just build a gpart edit mode with the functions used to implement backup > and restore. Excellent idea. Thank you. A small project to work on. > > > > > Kind regards > > Miroslav Lachman A freebsd-bsdlabel port has been created making way for its removal. -- Cheers, Cy Schubert <Cy.Schubert@cschubert.com> FreeBSD UNIX: <cy@FreeBSD.org> Web: https://FreeBSD.org NTP: <cy@nwtime.org> Web: https://nwtime.org e^(i*pi)+1=0
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20240125192716.DD3B6267>
