From owner-freebsd-questions@FreeBSD.ORG Fri Feb 20 12:49:37 2004 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id EF63416A4CE for ; Fri, 20 Feb 2004 12:49:36 -0800 (PST) Received: from www6.web2010.com (www6.web2010.com [216.157.5.254]) by mx1.FreeBSD.org (Postfix) with ESMTP id 9CC3143D1D for ; Fri, 20 Feb 2004 12:49:36 -0800 (PST) (envelope-from MLandman@face2interface.com) Received: from delliver.face2interface.com (dialup-wash-129-203.thebiz.net [64.30.129.203] (may be forged)) by www6.web2010.com (8.12.10/8.9.0) with ESMTP id i1KKnD89005875; Fri, 20 Feb 2004 15:49:17 -0500 (EST) Message-Id: <6.0.0.22.0.20040220154400.092f0ba0@pop.face2interface.com> X-Sender: face@pop.face2interface.com X-Mailer: QUALCOMM Windows Eudora Version 6.0.0.22 Date: Fri, 20 Feb 2004 15:49:29 -0500 To: "Marwan Sultan" , "FreeBSD questions List" From: Marty Landman In-Reply-To: <20040220201619.M35470@kifco.net> References: <20040220201619.M35470@kifco.net> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii"; format=flowed Subject: Re: cron or ipfw problem! X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 20 Feb 2004 20:49:37 -0000 At 03:33 PM 2/20/2004, Marwan Sultan wrote: > I want to add a rule to ipfw which activate from 3AM to 3PM : says: > ipfw 05000 add deny all from 192.168.1.21 to any > > How to run the scripts? thro crontab I fixed my crontab to > 0 3 * * * /path/deny.sh > 0 15 * * * /path/enable.sh Marwan, are these scripts running as root? Perhaps you could modify the scripts to do ipfw -a list when they end, and put their outputs in a file e.g. 0 3 * * * /path/deny.sh >> /root/ipfwJob 0 15 * * * /path/enable.sh >> /root/ipfwJob Also add echo deny (or enable) starting to the top of each script then post back with the contents of /root/ipfwJob after they've both run. Marty Landman Face 2 Interface Inc 845-679-9387 This Month's New Quiz --- Past Superbowl Winners Make a Website: http://face2interface.com/Home/Demo.shtml