Results 1 to 4 of 4
How do I add a blank space to the egrep below? I want to search for
port 25 and a blank? It must be an exact match 25 with a ...
Enjoy an ad free experience by logging in. Not a member yet? Register.
- 06-28-2004 #1Just Joined!
- Join Date
- Jun 2004
- Posts
- 8
Regular Expression
How do I add a blank space to the egrep below? I want to search for
port 25 and a blank? It must be an exact match 25 with a trailing blank.
That is my search criteria. Currently anything that begins with 25 is returned.
ex: 256 2567 25555 I only want matches on 25 and a space.
egrep "to outside:[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\/25" /var/log/messages
- 06-29-2004 #2
Ummm...escape a space: "\ "
"Time is an illusion. Lunchtime, doubly so."
~Douglas Adams, The Hitchhiker's Guide to the Galaxy
- 06-29-2004 #3
that should work.
-lakerdonald
- 06-29-2004 #4Just Joined!
- Join Date
- Jun 2004
- Posts
- 8
SYSLOG
For some reason that doesn't work . It returns no matches. If you have a second try it out with my line.
Thanks,


Reply With Quote
