From owner-freebsd-pf@FreeBSD.ORG Mon Jul 29 18:16:42 2013 Return-Path: Delivered-To: freebsd-pf@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTP id 33ED0420; Mon, 29 Jul 2013 18:16:42 +0000 (UTC) (envelope-from gpalmer@freebsd.org) Received: from mail.in-addr.com (unknown [IPv6:2001:470:8:162::1]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id E17C12695; Mon, 29 Jul 2013 18:16:41 +0000 (UTC) Received: from gjp by mail.in-addr.com with local (Exim 4.80.1 (FreeBSD)) (envelope-from ) id 1V3rzp-0007Fr-Fc; Mon, 29 Jul 2013 14:16:37 -0400 Date: Mon, 29 Jul 2013 14:16:37 -0400 From: Gary Palmer To: Yeris Antonio Madrigal Castro Subject: Re: pf log script issue Message-ID: <20130729181637.GC70888@in-addr.com> References: <51F30C00.2000007@netcrc.cr> <51F3F06F.4000101@netcrc.net> <166BA3A5-3876-4383-B78B-7BCB32BCDE80@dataix.net> <51F69A00.5080202@netcrc.net> <20130729164329.GB70888@in-addr.com> <51F6A1FA.8040109@netcrc.net> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <51F6A1FA.8040109@netcrc.net> X-SA-Exim-Connect-IP: X-SA-Exim-Mail-From: gpalmer@freebsd.org X-SA-Exim-Scanned: No (on mail.in-addr.com); SAEximRunCond expanded to false Cc: "freebsd-pf@freebsd.org" X-BeenThere: freebsd-pf@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Technical discussion and general questions about packet filter \(pf\)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 29 Jul 2013 18:16:42 -0000 On Mon, Jul 29, 2013 at 11:10:18AM -0600, Yeris Antonio Madrigal Castro wrote: > Dude! that actually solved the problem... may I know why. > > Kind regards /usr/sbin tends not to be on the default path. If you do something like echo $PATH > /tmp/root-cron-path in your script you'll see the path that is being used. Gary > > El 29/07/2013 10:43, Gary Palmer escribi?: > > On Mon, Jul 29, 2013 at 10:36:16AM -0600, Yeris Antonio Madrigal Castro wrote: > >> No, I am actually using the crontab as root, just the line with tcpdump > >> is not working, but if I runt the script manually all works. > >> > >> Regards > > If you specify the full path to the tcpdump binary, i.e. /usr/sbin/tcpdump, > > does that fix the problem? > > > > Gary > > > >> El 27/07/2013 10:17, Jason Hellenthal escribi??: > >>> Are you using /etc/crontab ? > >>> > >>> -- > >>> Jason Hellenthal > >>> Inbox: jhellenthal@DataIX.net > >>> Voice: +1 (616) 953-0176 > >>> JJH48-ARIN > >>> > >>> > >>> On Jul 27, 2013, at 12:08, Yeris Antonio Madrigal Castro > >>> > wrote: > >>> > >>>> Hi > >>>> > >>>> I am using freebsd 9.1 R, and i am trying to make the pf firewall to log > >>>> to the syslog. > >>>> > >>>> I am using the script at the openbsd fag: > >>>> > >>>> http://www.openbsd.org/faq/pf/logging.html > >>>> > >>>> The script works 100% if I run it manually, but when crontab runs it as > >>>> root, the tcpdump wont work. > >>>> > >>>> I would appreciate any help. > >>>> > >>>> Regards > >>>> > >>>> ** > >>>> ** > >>>> > >>>> > >>>> > >>>> _______________________________________________ > >>>> freebsd-pf@freebsd.org mailing list > >>>> http://lists.freebsd.org/mailman/listinfo/freebsd-pf > >>>> To unsubscribe, send any mail to "freebsd-pf-unsubscribe@freebsd.org > >>>> " > >> _______________________________________________ > >> freebsd-pf@freebsd.org mailing list > >> http://lists.freebsd.org/mailman/listinfo/freebsd-pf > >> To unsubscribe, send any mail to "freebsd-pf-unsubscribe@freebsd.org" > >