I need a script to monitor a long running process with a particular username that runs more than 5 hrs. In my case the name of the process is java used in my OTM application. If this java process is running more that 5 hrs then it should automatically kill the process and send an mail to me. Below are the system config details. Please help.
OS: redhat-release
Release: 4AS
CPU Arch: i686-redhat-linux
OS: redhat-release
Release: 4AS
CPU Arch: i686-redhat-linux