From owner-freebsd-stable@FreeBSD.ORG Wed Apr 16 00:08:24 2008 Return-Path: Delivered-To: freebsd-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id CBFDE1065673 for ; Wed, 16 Apr 2008 00:08:24 +0000 (UTC) (envelope-from miguel@anjos.strangled.net) Received: from mailrly02.isp.novis.pt (mailrly02.isp.novis.pt [195.23.133.212]) by mx1.freebsd.org (Postfix) with ESMTP id 377068FC14 for ; Wed, 16 Apr 2008 00:08:23 +0000 (UTC) (envelope-from miguel@anjos.strangled.net) Received: (qmail 17308 invoked from network); 15 Apr 2008 23:41:42 -0000 Received: from unknown (HELO mailfrt12.isp.novis.pt) ([195.23.133.228]) (envelope-sender ) by mailrly02.isp.novis.pt with compressed SMTP; 15 Apr 2008 23:41:42 -0000 Received: (qmail 24766 invoked from network); 15 Apr 2008 23:41:42 -0000 Received: from unknown (HELO satan.anjos.strangled.net) ([89.181.41.37]) (envelope-sender ) by mailfrt12.isp.novis.pt with SMTP; 15 Apr 2008 23:41:42 -0000 Received: from satan.anjos.strangled.net (localhost [127.0.0.1]) by satan.anjos.strangled.net (8.14.2/8.14.2) with ESMTP id m3FNfZ2Z021952 for ; Wed, 16 Apr 2008 00:41:36 +0100 (WEST) (envelope-from miguel@satan.anjos.strangled.net) Received: (from miguel@localhost) by satan.anjos.strangled.net (8.14.2/8.14.2/Submit) id m3FNfZNH021951 for freebsd-stable@freebsd.org; Wed, 16 Apr 2008 00:41:35 +0100 (WEST) (envelope-from miguel) Date: Wed, 16 Apr 2008 00:41:35 +0100 (WEST) From: Miguel Lopes Santos Ramos Message-Id: <200804152341.m3FNfZNH021951@satan.anjos.strangled.net> To: freebsd-stable@freebsd.org Subject: /etc/daily.local and sim. never run X-BeenThere: freebsd-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Production branch of FreeBSD source code List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 16 Apr 2008 00:08:24 -0000 Hi, I just noticed that scripts in /etc/daily.local, /etc/weekly.local, etc, never run. The reason seems to be that the /etc/periodic/daily/999.local and similar scripts use "for script in $daily_local". Because the variable $daily_local is initialized in /etc/defaults/periodic.conf to /etc/daily.local, which actually does not contain a wildcard, the for loop step executes only once with the variable script bound to "/etc/daily.local". There's no iteration over scripts contained in /etc/daily.local. I have no idea when this might have gotten broken. The 999.local scripts date back to 2001. It's curious that no one has noticed. Perhaps most people just use the crontab or put their scripts directly into /etc/periodic/daily, etc. Anyway, scheduling things in crontabs and the like is not very good when the system is not always on. Since UNIX is no longer such a "time sharing system" and many people run desktops and part-time servers, wouldn't it be desirable to have a periodic job scheduling mechanism that would reliably run jobs when a given amount of time (uptime or not) had passed? Greetings, Miguel Ramos Lisboa