Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 21 Jun 2022 13:07:41 -0600
From:      Warner Losh <imp@bsdimp.com>
To:        "Rodney W. Grimes" <freebsd-rwg@gndrsh.dnsmgr.net>
Cc:        "freebsd-arch@freebsd.org" <freebsd-arch@freebsd.org>
Subject:   Re: Updating reboot's default
Message-ID:  <CANCZdfrPWSSRsQvMmh4kt7eXtz2NyF=S0R4U67KyV47HPJ%2ByHA@mail.gmail.com>
In-Reply-To: <202206211620.25LGKvbN053809@gndrsh.dnsmgr.net>
References:  <CANCZdfqm22kUCgVseR%2BF9nx5B84r5-gMUhQBBRwzFtxTmhYg2w@mail.gmail.com> <202206211620.25LGKvbN053809@gndrsh.dnsmgr.net>

next in thread | previous in thread | raw e-mail | index | archive | help
--0000000000001f0f2405e1f9f081
Content-Type: text/plain; charset="UTF-8"

On Tue, Jun 21, 2022, 10:20 AM Rodney W. Grimes <
freebsd-rwg@gndrsh.dnsmgr.net> wrote:

> [ Charset UTF-8 unsupported, converting... ]
> > On Tue, Jun 21, 2022 at 8:01 AM Warner Losh <imp@bsdimp.com> wrote:
> >
> > > 15 or 20 years ago, we talked about changing the default for reboot
> from
> > > 'right now' to being safe shutdown. There were arguments made against
> it
> > > due to tiny appliances and such.
> > >
> > > Time has past, and this oddity has persisted. It's time to revisit that
> > > decision.
> > >
> > > I'd propose that we keep 'fastboot' and 'fasthalt' having the immediate
> > > behavior. However, the 'reboot' command will switch from '-q' behavior
> to
> > > '-r' behavior.
> > >
> > > I'll update the man page, etc to reflect these new defaults. Most of
> the
> > > systems I've been on in the last 10-15 years have had some flavor of
> 'alias
> > > reboot reboot -r' in their login scripts and/or made shell scripts
> that did
> > > this. This will match what everybody else is doing, and will likely
> result
> > > in less astonishment rather than more, even though it changes a
> > > long-standing default behavior.
> > >
> > > Comments?
> > >
> >
> > I slightly misspoke here. I'm proposing we change the default to like
> > 'shutodwn -r' not to re-root the system... Sorry for any confusion.
>
> Retract my prior objection based on reboot -r being a re-root.
>
> BUTT:
> shutdown -r requires an argument of "time"
> And what would the time be?
>
> aka if you alias reboot "shutdown -r", when I type
> reboot I'll end up getting a usage error.
> This is gona cause some confusion, perhaps you
> mean to alias reboot "shutdown -r now"?
>

Yes. It would signal init to start the shutdown right now.

Warner


-- 
> Rod Grimes
> rgrimes@freebsd.org
>

--0000000000001f0f2405e1f9f081
Content-Type: text/html; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable

<div dir=3D"auto"><div><br><br><div class=3D"gmail_quote"><div dir=3D"ltr" =
class=3D"gmail_attr">On Tue, Jun 21, 2022, 10:20 AM Rodney W. Grimes &lt;<a=
 href=3D"mailto:freebsd-rwg@gndrsh.dnsmgr.net">freebsd-rwg@gndrsh.dnsmgr.ne=
t</a>&gt; wrote:<br></div><blockquote class=3D"gmail_quote" style=3D"margin=
:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">[ Charset UTF-8 un=
supported, converting... ]<br>
&gt; On Tue, Jun 21, 2022 at 8:01 AM Warner Losh &lt;<a href=3D"mailto:imp@=
bsdimp.com" target=3D"_blank" rel=3D"noreferrer">imp@bsdimp.com</a>&gt; wro=
te:<br>
&gt; <br>
&gt; &gt; 15 or 20 years ago, we talked about changing the default for rebo=
ot from<br>
&gt; &gt; &#39;right now&#39; to being safe shutdown. There were arguments =
made against it<br>
&gt; &gt; due to tiny appliances and such.<br>
&gt; &gt;<br>
&gt; &gt; Time has past, and this oddity has persisted. It&#39;s time to re=
visit that<br>
&gt; &gt; decision.<br>
&gt; &gt;<br>
&gt; &gt; I&#39;d propose that we keep &#39;fastboot&#39; and &#39;fasthalt=
&#39; having the immediate<br>
&gt; &gt; behavior. However, the &#39;reboot&#39; command will switch from =
&#39;-q&#39; behavior to<br>
&gt; &gt; &#39;-r&#39; behavior.<br>
&gt; &gt;<br>
&gt; &gt; I&#39;ll update the man page, etc to reflect these new defaults. =
Most of the<br>
&gt; &gt; systems I&#39;ve been on in the last 10-15 years have had some fl=
avor of &#39;alias<br>
&gt; &gt; reboot reboot -r&#39; in their login scripts and/or made shell sc=
ripts that did<br>
&gt; &gt; this. This will match what everybody else is doing, and will like=
ly result<br>
&gt; &gt; in less astonishment rather than more, even though it changes a<b=
r>
&gt; &gt; long-standing default behavior.<br>
&gt; &gt;<br>
&gt; &gt; Comments?<br>
&gt; &gt;<br>
&gt; <br>
&gt; I slightly misspoke here. I&#39;m proposing we change the default to l=
ike<br>
&gt; &#39;shutodwn -r&#39; not to re-root the system... Sorry for any confu=
sion.<br>
<br>
Retract my prior objection based on reboot -r being a re-root.<br>
<br>
BUTT:<br>
shutdown -r requires an argument of &quot;time&quot;<br>
And what would the time be?<br>
<br>
aka if you alias reboot &quot;shutdown -r&quot;, when I type<br>
reboot I&#39;ll end up getting a usage error.<br>
This is gona cause some confusion, perhaps you<br>
mean to alias reboot &quot;shutdown -r now&quot;?<br></blockquote></div></d=
iv><div dir=3D"auto"><br></div><div dir=3D"auto">Yes. It would signal init =
to start the shutdown right now.</div><div dir=3D"auto"><br></div><div dir=
=3D"auto">Warner=C2=A0</div><div dir=3D"auto"><br></div><div dir=3D"auto"><=
br></div><div dir=3D"auto"><div class=3D"gmail_quote"><blockquote class=3D"=
gmail_quote" style=3D"margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-=
left:1ex">
-- <br>
Rod Grimes=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =
=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=
=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0<a href=3D"mailto:rgrimes@freebsd.org=
" target=3D"_blank" rel=3D"noreferrer">rgrimes@freebsd.org</a><br>
</blockquote></div></div></div>

--0000000000001f0f2405e1f9f081--



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?CANCZdfrPWSSRsQvMmh4kt7eXtz2NyF=S0R4U67KyV47HPJ%2ByHA>