I have to count how many occurrences of certain strings appear in a log4j file. I have a start date from which I want to start greping (maybe sed or awk?) in a Java class during a test.
Even if I don't know if it's better to capture the grep result from a Runtime.getRuntime().exec(...) command versus reading and parsing (via regex and string manipulation) the current log4j file, I don't know how to grep a file like this:
2016-07-29 15:13:08,725: INFO [main] .....
2016-07-29 15:13:08,817: INFO [main] ....
2016-07-29 15:13:08,901: INFO [main] ...
but only after 2016-07-29 15:13:08,818 for example
Thanks in advance!