From owner-freebsd-questions@FreeBSD.ORG Tue Sep 12 11:02:01 2006 Return-Path: X-Original-To: freebsd-questions@freebsd.org 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 E951716A412 for ; Tue, 12 Sep 2006 11:02:01 +0000 (UTC) (envelope-from xfb52@dial.pipex.com) Received: from smtp-out2.blueyonder.co.uk (smtp-out2.blueyonder.co.uk [195.188.213.5]) by mx1.FreeBSD.org (Postfix) with ESMTP id 82A4543D45 for ; Tue, 12 Sep 2006 11:02:00 +0000 (GMT) (envelope-from xfb52@dial.pipex.com) Received: from [172.23.170.141] (helo=anti-virus02-08) by smtp-out2.blueyonder.co.uk with smtp (Exim 4.52) id 1GN61f-00076D-HE; Tue, 12 Sep 2006 12:01:59 +0100 Received: from [82.41.35.166] (helo=[192.168.0.2]) by asmtp-out2.blueyonder.co.uk with esmtp (Exim 4.52) id 1GN61e-00073L-Kn; Tue, 12 Sep 2006 12:01:58 +0100 Message-ID: <450693A6.7090108@dial.pipex.com> Date: Tue, 12 Sep 2006 12:01:58 +0100 From: Alex Zbyslaw User-Agent: Mozilla/5.0 (X11; U; FreeBSD i386; en-GB; rv:1.7.13) Gecko/20060515 X-Accept-Language: en MIME-Version: 1.0 To: bsd References: <377AA521-83A6-45A6-9892-A1B167607EFD@todoo.biz> In-Reply-To: <377AA521-83A6-45A6-9892-A1B167607EFD@todoo.biz> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: Liste FreeBSD Subject: Re: Ambiguous output redirect X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 12 Sep 2006 11:02:02 -0000 bsd wrote: > I don't understand why when I execute this script I have an > "Ambiguous output redirect." ? > > > p0f -l 'tcp dst port 25' 2>&1 | /usr/local/sbin/p0f-analyzer.pl 2345 & One answer would be that this is bourne shell syntax and you shell is csh. Try 0f -l 'tcp dst port 25' |& /usr/local/sbin/p0f-analyzer.pl 2345 & or change your shell to a bourne shell compatible one like bash. --Alex PS In csh the ">&" means redirect to a file including stderr, in this case the file "1"; then you are telling it to also pipe to something, which is impossible since you just redirected to a file.