Find every instance of hostname
Anne Wilson
cannewilson at tiscali.co.uk
Sat Aug 26 21:36:26 UTC 2006
On Saturday 26 August 2006 20:56, Dean S. Messing wrote:
> :
> : Time, I don't mind. I suspect, though, that the 12,000 or so emails
> : would also be included.
>
> Easily handled if the e-mail is all under one directory. If so, then
> (assuming the mail is in "/usr/foo/mail-under-here"
>
> find / -path "/usr/foo/mail-under-here" -prune -o -type f -fstype ext3
> -exec fgrep -l "hostname" {} \;
>
> This is just a boolean expression. -o means "OR".
>
> "AND" is implicitly between all other arguments if no "-o" conjunction
> is given. So it says
>
> if the current pathname is "/usr/foo/mail-under-here" then prune it
> from the search tree (i.e. don't search any deeper), "OR" do the
> stuff to the right of the "-o" which is what you were already
> doing.
>
Useful hints, Dean. Filed for study later, thanks.
Anne
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
URL: <http://listman.redhat.com/archives/fedora-list/attachments/20060826/cab68096/attachment-0001.sig>
More information about the fedora-list
mailing list