in reply to creating a perl script
Use Regular expression to match multiple lines with m modifier.
To run the script for every fifteen minutes, use sleep function.