From owner-freebsd-questions@FreeBSD.ORG Thu Jan 6 04:45:26 2005 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 A05DF16A4CE for ; Thu, 6 Jan 2005 04:45:26 +0000 (GMT) Received: from wproxy.gmail.com (wproxy.gmail.com [64.233.184.198]) by mx1.FreeBSD.org (Postfix) with ESMTP id 33FA043D2F for ; Thu, 6 Jan 2005 04:45:26 +0000 (GMT) (envelope-from somniosus@gmail.com) Received: by wproxy.gmail.com with SMTP id 55so25219wri for ; Wed, 05 Jan 2005 20:45:25 -0800 (PST) DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=beta; d=gmail.com; h=received:message-id:date:from:reply-to:to:subject:cc:in-reply-to:mime-version:content-type:content-transfer-encoding:references; b=JB6+GYwYEzF4XJDBp+7RG6eMwomtCkPKsjub8KNOHS/NHjTueHYazdvVjVpR16UmkQERfT1z6kkMdwM4jYMSsq3tD0zVXPbfWvTVPMiiM4yPN3MeXxVvii/5bpa06HCQi4Fdiw6eDT587yZziIXxlnGcfbARkKw+FBSQoguUgy4= Received: by 10.54.45.55 with SMTP id s55mr79552wrs; Wed, 05 Jan 2005 20:45:25 -0800 (PST) Received: by 10.54.14.10 with HTTP; Wed, 5 Jan 2005 20:45:25 -0800 (PST) Message-ID: Date: Wed, 5 Jan 2005 20:45:25 -0800 From: cape canaveral To: Tillman Hodgson In-Reply-To: <20050106043154.GI42299@seekingfire.com> Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit References: <41DCBE47.4070402@att.net> <20050106043154.GI42299@seekingfire.com> cc: FreeBSD - questions Subject: Re: grep help X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list Reply-To: cape canaveral List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 06 Jan 2005 04:45:26 -0000 On Wed, 5 Jan 2005 22:31:54 -0600, Tillman Hodgson wrote: > On Wed, Jan 05, 2005 at 08:27:51PM -0800, Jay O'Brien wrote: > > I want to look at all of the lines in a FreeBSD log file that do not > > have an entry from an IP, example 1.2.3.4. Some basic help with the > > use of grep would be appreciated. This is one of the arguments I've > > tried that didn't work: > > > > grep ^[^1.2.3.4]*$ logfile.log > > I like `grep -v` for "not" operations. Also note that "." is itself a > special character. > > grep -v 1\.2\.3\.4 logfile.log > > might be closer to what you want. > > -T > > -- > "'Way back, I set myself to be a happy man, and made it." > -- Louis Armstrong > _______________________________________________ > freebsd-questions@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-questions > To unsubscribe, send any mail to "freebsd-questions-unsubscribe@freebsd.org" > grep "1.2.3.4" logifle.log works for me (unless you were trying to pull all IPs in the form of a.b.c.d ?) -Aaron