From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on inbox.vuxu.org X-Spam-Level: X-Spam-Status: No, score=-1.1 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,HTML_MESSAGE,MAILING_LIST_MULTI,RCVD_IN_DNSWL_NONE autolearn=ham autolearn_force=no version=3.4.4 Received: (qmail 8809 invoked from network); 28 Jul 2020 00:38:28 -0000 Received: from minnie.tuhs.org (45.79.103.53) by inbox.vuxu.org with ESMTPUTF8; 28 Jul 2020 00:38:28 -0000 Received: by minnie.tuhs.org (Postfix, from userid 112) id D05E69CAA7; Tue, 28 Jul 2020 10:38:23 +1000 (AEST) Received: from minnie.tuhs.org (localhost [127.0.0.1]) by minnie.tuhs.org (Postfix) with ESMTP id 7440B9C8E4; Tue, 28 Jul 2020 10:37:06 +1000 (AEST) Authentication-Results: minnie.tuhs.org; dkim=pass (1024-bit key; unprotected) header.d=ccc.com header.i=@ccc.com header.b="LBhLlj2Y"; dkim-atps=neutral Received: by minnie.tuhs.org (Postfix, from userid 112) id 4A9A09C8E4; Tue, 28 Jul 2020 10:37:02 +1000 (AEST) Received: from mail-qv1-f47.google.com (mail-qv1-f47.google.com [209.85.219.47]) by minnie.tuhs.org (Postfix) with ESMTPS id 628929C8E2 for ; Tue, 28 Jul 2020 10:37:01 +1000 (AEST) Received: by mail-qv1-f47.google.com with SMTP id u8so8379646qvj.12 for ; Mon, 27 Jul 2020 17:37:01 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ccc.com; s=google; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=52pNwfQsVPrtoZTUiHJXopxnnCDTBhAoyuB+Wr7pcls=; b=LBhLlj2YuKesbTJ2i8KeDdcM/KE6kaEeP1odB8ayAMba8ZcOehHPKuyQkLVUI2SBQ+ xJVnRe56HVEXm2erF92yBE1CQja/DODvB+/kBObtux7tKAd7GLsiu3oC7GnbJbxnZNQU l9dL8qjGIWXS1lXDNVgRilTxYif8OYHuZDHtM= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=52pNwfQsVPrtoZTUiHJXopxnnCDTBhAoyuB+Wr7pcls=; b=d2M8QsZ1zeNs6t+qrA0t2cEbcBIu/WyRT4IB8fc+ed0Gu9o+QfdDXjc4D+FkKcOt0G QP0jeSsNjsptMVWOhb1DyDM6I2oJsQGtOhGATZGDc2Dvs9nlK5lHP+pGtaAQIy6QQEHe rbuDNL3I3D2KdSG4PlXe0XujDoYyV52CnjED1ONDCfv3vKAlWuTdJh84mbgng5gNi5ml lfOKrSCFMrNBTDdbRwmlu970RXK1Ftcuff13oKxUQ2muWnGiDjUpTc5a2sKBY4vsi3rm CANUTylKNxJUhUrBGZjDUw9b2GklcqviRrhC75opImOn6cKtGYPEbFkf2Rs/Y3IzZkMf ua/A== X-Gm-Message-State: AOAM533gM0PcVpX8jBkgJYPrHCrXoi323+Zdv59aC7U2ggfSU1rwAOM8 BMNBZQN8iF6SFNOy15jacQ86zVoGMRzrThNxSFDooiP83Z8= X-Google-Smtp-Source: ABdhPJxtFbGYKf83von/Cwioa7XExzwZDuzqq/gHZI68L69kfnALu+BH4h+pJzcAaGJazSQL/WDMVWccc6kTSNKSlT0= X-Received: by 2002:ad4:4812:: with SMTP id g18mr24742971qvy.56.1595896620154; Mon, 27 Jul 2020 17:37:00 -0700 (PDT) MIME-Version: 1.0 References: In-Reply-To: From: Clem Cole Date: Mon, 27 Jul 2020 20:36:33 -0400 Message-ID: To: Warner Losh Content-Type: multipart/alternative; boundary="00000000000024972c05ab75a3c6" Subject: Re: [TUHS] reboot(2) system call X-BeenThere: tuhs@minnie.tuhs.org X-Mailman-Version: 2.1.26 Precedence: list List-Id: The Unix Heritage Society mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: TUHS main list Errors-To: tuhs-bounces@minnie.tuhs.org Sender: "TUHS" --00000000000024972c05ab75a3c6 Content-Type: text/plain; charset="UTF-8" Warner - awesome. I would add a few things that were sort of in the story, although not directly. The primary difference between 4.0 and 4.1 was originally a political push with Stanford trying to get VMS as the official OS for Arpa and Joy countering with BSD claiming it was within epsilon of VMS and in some cases faster. The performance was the biggest of the Stanford complaints which Bill fixed with a much a carefully placed assembler. But IIRC, one of the other issues was "UNIX is unreliable" and file system corrupt was tossed out as an example of the same [The lack of real/complete Fortran compiler was never corrected, but I remember that was one of the other reasons given. But it was one of the reasons why a couple of UCB compiler folks worked on improving F77 and building dbx, although it was never in the same league as VMS's compiler or any of the many DEC debuggers]. Anyway, after 4.0 came out, Goble released the 'Purdue file system fixes'. When V6-4.1BSD Unix crashed, the OS was noted for leaving a possible corrupted file system (this was why tjk wrote fsck of course for V6 years before). George really spent time analyzing the order that different writes were done *i.e.* making sure the data, inodes, superblock were updated in the right order. This cut down file system corruption after a system crash. He also had a way to force the buffer cache to be cleared properly and part of that was that George had implemented reboot independently of Joy and I think before Bill. Certainly by 4.1B when McKussick's new FS was being folded into the kernel, Joy had pulled the original file system write order changes from Purdue. He may have done that as part of 4.1 "FASTVAX" work and before he explored reboot. The point is that sync, reboot, and file system block write ordering was all mixed together. On Mon, Jul 27, 2020 at 3:01 PM Warner Losh wrote: > I've done some research for a friend about when the reboot() system call > was added, and how it related to the sync, sync, sync dance. > > https://bsdimp.blogspot.com/2020/07/when-unix-learned-to-reboot2.html > > may be of interest. Please do let me know if I've gotten something wrong... > > Warner > --00000000000024972c05ab75a3c6 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
Warner - awesome.=C2=A0 I would add a few things that w= ere sort of in the story, although not directly.

The p= rimary difference between 4.0 and 4.1 was originally a political push with = Stanford trying to get VMS as the official OS for Arpa and Joy countering w= ith BSD claiming it was within epsilon of VMS and in some cases faster.=C2= =A0 The performance was the biggest of the Stanford complaints which Bill f= ixed with a much a carefully placed assembler.=C2=A0 But IIRC, one of the o= ther issues was "UNIX is unreliable" and file system corrupt was = tossed out as an example of the same [The lack of real/complete Fortran com= piler was never corrected, but I remember that was one of the other reasons= given.=C2=A0 But it was one of the reasons why a couple of UCB compiler=C2= =A0folks worked on improving F77 and building dbx, although it was never in= the same league as VMS's=C2=A0compiler or any of the many DEC debugger= s].

Anyway, after 4.0 cam= e out, Goble released the 'Purdue file system fixes'.=C2=A0 =C2=A0W= hen V6-4.1BSD Unix crashed, the OS was noted for leaving a possible corrupt= ed file system (this was why tjk wrote fsck of=C2=A0course for V6 years bef= ore).=C2=A0 George really spent time analyzing the order that different wri= tes were done i.e. making sure the data, inodes, superblock were upd= ated in the right order.=C2=A0 This cut down file system corruption after a= system crash.=C2=A0 He also had a way to force the=C2=A0buffer cache to be= cleared properly and part of that was that George had implemented reboot i= ndependently of Joy and I think before Bill.=C2=A0=C2=A0

Certainly by 4.1B wh= en McKussick's new FS was being folded into the kernel, Joy had pulled = the original file system write order changes from Purdue.=C2=A0 He may have= done that as part of 4.1 "FASTVAX" work and before he explored r= eboot.

The point is that sync, reboot, and file system block write ordering w= as all mixed together.=C2=A0


On Mon, Jul 27, 2020= at 3:01 PM Warner Losh <imp@bsdimp.co= m> wrote:
I've done some research for a friend about when the r= eboot() system call was added, and how it related to the sync, sync, sync d= ance.


may be of interest. Please do let me know if I've gotten something= =C2=A0wrong...

Warner
--00000000000024972c05ab75a3c6--