in reply to Reading a Log File - "pattern detection" Part 2
If you used code tags for your script and logfile examples, your post would've be almost perfect ;o))
If your only intention is to read from a logfile, and the program can't open it for reading, why is it hard, when the program dies if it can't open that logfile?
| (binary OR) is propably the wrong operator as you can reread in perldoc perlop. You are looking for the logical OR to combine your regex's.
If you need to have '/' in your patterns you should mask it ( '\|' ) or change the delimiters of your regex ( m{text/with/slash} ). See perldoc for details.
Perl Regex Tutorial
Perl Regex Quickstart
Perl Regex
|
|---|