From mboxrd@z Thu Jan 1 00:00:00 1970 From: Leo Hofmann <hofmann@leo-andres.de> To: development@lists.ipfire.org Subject: Re: [PATCH 1/2] shutdown.cgi: Add "reboot with filesystem check" button Date: Wed, 14 Jul 2021 22:55:00 +0200 Message-ID: <b163ff94-4d8d-faa1-629f-d4c43f598b94@leo-andres.de> In-Reply-To: <20210714174106.GA37581@vesikko.tarvainen.info> MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="===============5783312635099836226==" List-Id: <development.lists.ipfire.org> --===============5783312635099836226== Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Am 14.07.2021 um 19:41 schrieb Tapani Tarvainen: > On Wed, Jul 14, 2021 at 05:12:27PM +0100, Michael Tremer (michael.tremer(a)= ipfire.org) wrote: > >> Does the -r switch in shutdown(8) actually work? > Yes. It has worked in all Linux systems I've used for years > (and several non-Linux Unix-based systems like HP-UX). I also tried this on my IPFire test system before submitting the patch and ca= n confirm that -r (and -F) work as expected :) > > In the past "shutdown -r now" and "reboot" differed, e.g., reboot > didn't sync or run shutdown scripts (and thus shutdown was sometimes > recommended as the "safe" or "clean" way to reboot), but nowadays > they're identical apart from some different options (notably, reboot > has the "-f" option for "dirty" reboot, but it's not default anymore). > People generally use whichever they're used to. > > Today shutdown, reboot, halt and poweroff are all symlinks to > systemctl in Debian and Ubuntu at least, but options and defaults > differ depending on which name it is called with. > > E.g., Debian Buster: > > $ ls -l /sbin/{shutdown,reboot,halt,poweroff} > lrwxrwxrwx 1 root root 14 Mar 18 21:59 /sbin/halt -> /bin/systemctl > lrwxrwxrwx 1 root root 14 Mar 18 21:59 /sbin/poweroff -> /bin/systemctl > lrwxrwxrwx 1 root root 14 Mar 18 21:59 /sbin/reboot -> /bin/systemctl > lrwxrwxrwx 1 root root 14 Mar 18 21:59 /sbin/shutdown -> /bin/systemctl > =09 Thanks for the detailed explanation! --===============5783312635099836226==--