From owner-freebsd-current Mon Mar 19 10:15:36 2001 Delivered-To: freebsd-current@freebsd.org Received: from critter.freebsd.dk (critter.freebsd.dk [212.242.86.163]) by hub.freebsd.org (Postfix) with ESMTP id BB58137B719 for ; Mon, 19 Mar 2001 10:15:33 -0800 (PST) (envelope-from phk@critter.freebsd.dk) Received: from critter (localhost [127.0.0.1]) by critter.freebsd.dk (8.11.3/8.11.3) with ESMTP id f2JIFQ159158; Mon, 19 Mar 2001 19:15:26 +0100 (CET) (envelope-from phk@critter.freebsd.dk) To: Ian Dowse Cc: current@FreeBSD.ORG Subject: Re: reboot(8) delay between SIGTERM and SIGKILL In-Reply-To: Your message of "Mon, 19 Mar 2001 18:12:10 GMT." <200103191812.aa82109@salmon.maths.tcd.ie> Date: Mon, 19 Mar 2001 19:15:26 +0100 Message-ID: <59156.985025726@critter> From: Poul-Henning Kamp Sender: owner-freebsd-current@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG In message <200103191812.aa82109@salmon.maths.tcd.ie>, Ian Dowse writes: > >I have noticed that reboot(8) sometimes appears not to wait long >enough before sending the final SIGKILL to all processes. On a >system that has a lot of processes swapped out, some processes such >as the X server may get a SIGKILL before they have had a chance to >perform their exit cleanup. > >The patch below causes reboot to wait up to 60 seconds for paging >activity to end before sending the SIGKILLs. It does this by >monitoring the sysctl `vm.stats.vm.v_swappgsian', and extending >the default 5-second delay if page-in operations are observed. > >On my laptop (64Mb, IDE disk) with a number of big apps running, >it can take around 20 seconds for all the paging to die down after >the SIGTERMs are sent. Sounds like a good heuristic -- Poul-Henning Kamp | UNIX since Zilog Zeus 3.20 phk@FreeBSD.ORG | TCP/IP since RFC 956 FreeBSD committer | BSD since 4.3-tahoe Never attribute to malice what can adequately be explained by incompetence. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message