Date: Sat, 24 Sep 2022 18:08:54 +0100 From: Nuno Teixeira <eduardo@freebsd.org> To: FreeBSD CURRENT <freebsd-current@freebsd.org> Subject: Re: Good practices with bectl Message-ID: <CAFDf7U%2BUkKZ0wS6FgaQoftbeu_HaBc6ThQm%2BC1EG7vfTC9gdaw@mail.gmail.com> In-Reply-To: <Yy8Kb/b7u4EXV6KB@mail.gmail.com> References: <CAFDf7UL42z-m9P-gp6eY-orwcPz_UdJpiAM3ab-z4XLbY0LOdg@mail.gmail.com> <CAOtMX2gdoh2XxF0ofohyBA3DY-tgB5wAWb6%2BQmMb5tZRjieEvw@mail.gmail.com> <CAFDf7UJR73_rJeFQ059LCRw=K6AL8Y__9XgZ7RdR5zcjLitY_g@mail.gmail.com> <CAFDf7UKNaqCXr_KcYUPjGzN8hhZ22v6D9E00N7f=BvT2RukBZQ@mail.gmail.com> <20220921112706.Horde.eNaqpvIqq64Qe7crIQQ9JwX@webmail.leidinger.net> <YyrmsFONtjy1jVhh@albert.catwhisker.org> <20220921124452.Horde.BSQPZ4imQhhKUUE0k3W5iFb@webmail.leidinger.net> <CAFDf7UL-YTNHWFLRXx0JbgotxG6TH0P=MOowh9DPt5OVaiy8TQ@mail.gmail.com> <Yy8Kb/b7u4EXV6KB@mail.gmail.com>
index | next in thread | previous in thread | raw e-mail
[-- Attachment #1 --]
And src/tools/build/beinstall.sh too!
beinstall.sh is just great:
`bectl list`:
---
BE Active Mountpoint Space Created
14.0-CURRENT-20220924.142841 NR / 110G 2022-09-24 17:48
default - - 2.41G 2021-07-06 11:03
---
Cheers
Daniel Tameling <tamelingdaniel@gmail.com> escreveu no dia sábado,
24/09/2022 à(s) 14:47:
> On Wed, Sep 21, 2022 at 12:08:38PM +0100, Nuno Teixeira wrote:
> > Summary: Using bectl for upgrades
> >
> > RELEASE=Whatever
> > > bectl create ${RELEASE}
> > > bectl mount ${RELEASE}
> > BASEDIR=/tmp/be_mount.XXXX # Use mount point returned by bectl mount
> >
> > [freebsd-update method]
> > > freebsd-update -b ${BASEDIR} -d ${BASEDIR}/var/db/freebsd-update \
> > upgrade -r ${RELEASE}
> > > freebsd-update -b ${BASEDIR} -d ${BASEDIR}/var/db/freebsd-update
> install
> > # Ignore admonitions to reboot, since we're using a boot environment
> > > freebsd-update -b ${BASEDIR} -d ${BASEDIR}/var/db/freebsd-update
> install
> > > bectl activate ${RELEASE}
> > #> bectl activate -t ${RELEASE} # Failsafe (if the machine is too far
> away
> > to simply walk over and
> > switch to the old BE):
> > > reboot
> >
> > [upgrade from source method]
> > > make DESTDIR=${BASEDIR} installkernel
> > > etcupdate -p -D $BASEDIR
> > > make DESTDIR=${BASEDIR} installworld
> > > etcupdate -D $BASEDIR
> > > make DESTDIR=${BASEDIR} -DBATCH_DELETE_OLD_FILES delete-old
> > delete-old-libs
> > > bectl activate ${RELEASE}
> > #> bectl activate -t ${RELEASE} # Failsafe (if the machine is too far
> away
> > to simply walk over and
> > switch to the old BE):
> > > reboot
> >
>
> Would it be possible to add this to the handbook? I know that I will be
> looking for it when I upgrade next time.
>
> Best regards,
> Daniel
>
>
--
Nuno Teixeira
FreeBSD Committer (ports)
[-- Attachment #2 --]
<div dir="ltr"><div>And src/tools/build/beinstall.sh too!</div><div><br></div><div>beinstall.sh is just great:</div><div>`bectl list`:</div><div>---<br></div><div> BE Active Mountpoint Space Created<br> 14.0-CURRENT-20220924.142841 NR / 110G 2022-09-24 17:48<br> default - - 2.41G 2021-07-06 11:03</div><div>---</div><div><br></div><div>Cheers<br></div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">Daniel Tameling <<a href="mailto:tamelingdaniel@gmail.com">tamelingdaniel@gmail.com</a>> escreveu no dia sábado, 24/09/2022 à(s) 14:47:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">On Wed, Sep 21, 2022 at 12:08:38PM +0100, Nuno Teixeira wrote:<br>
> Summary: Using bectl for upgrades<br>
> <br>
> RELEASE=Whatever<br>
> > bectl create ${RELEASE}<br>
> > bectl mount ${RELEASE}<br>
> BASEDIR=/tmp/be_mount.XXXX # Use mount point returned by bectl mount<br>
> <br>
> [freebsd-update method]<br>
> > freebsd-update -b ${BASEDIR} -d ${BASEDIR}/var/db/freebsd-update \<br>
> upgrade -r ${RELEASE}<br>
> > freebsd-update -b ${BASEDIR} -d ${BASEDIR}/var/db/freebsd-update install<br>
> # Ignore admonitions to reboot, since we're using a boot environment<br>
> > freebsd-update -b ${BASEDIR} -d ${BASEDIR}/var/db/freebsd-update install<br>
> > bectl activate ${RELEASE}<br>
> #> bectl activate -t ${RELEASE} # Failsafe (if the machine is too far away<br>
> to simply walk over and<br>
> switch to the old BE):<br>
> > reboot<br>
> <br>
> [upgrade from source method]<br>
> > make DESTDIR=${BASEDIR} installkernel<br>
> > etcupdate -p -D $BASEDIR<br>
> > make DESTDIR=${BASEDIR} installworld<br>
> > etcupdate -D $BASEDIR<br>
> > make DESTDIR=${BASEDIR} -DBATCH_DELETE_OLD_FILES delete-old<br>
> delete-old-libs<br>
> > bectl activate ${RELEASE}<br>
> #> bectl activate -t ${RELEASE} # Failsafe (if the machine is too far away<br>
> to simply walk over and<br>
> switch to the old BE):<br>
> > reboot<br>
> <br>
<br>
Would it be possible to add this to the handbook? I know that I will be looking for it when I upgrade next time.<br>
<br>
Best regards,<br>
Daniel<br>
<br>
</blockquote></div><br clear="all"><br>-- <br><div dir="ltr" class="gmail_signature"><div dir="ltr"><span style="color:rgb(102,102,102)">Nuno Teixeira<br>FreeBSD Committer (ports)</span></div></div>
help
Want to link to this message? Use this
URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?CAFDf7U%2BUkKZ0wS6FgaQoftbeu_HaBc6ThQm%2BC1EG7vfTC9gdaw>
