“service” name is not the same as “process” name … service name in Monit is unique description of the monitored service - not related to the monitored object. If you have multiple processes with the same process name, you can monitor them, just choose unique service name for each process:
check process myprocess_XYZ with pidfile /var/run/myprocess1.pid
check process myprocess_ABC with pidfile /var/run/myprocess2.pid
Hi,
I'm getting "Error: service name conflict, <process name> already defined" error if I define two configuration entries for the corresponding process with different pid files in the same configuration file. Only way I can get this thing implemented is to run two instances of monit with two different configuration files.
Thanks
Samitha
Yes,
if you use pidfile, the process name is not significant - monit checks the process by the PID from the file, they can have the same name.
Regards, Martin
Hi,
How can I monitor two processes with the same name but different PID files ?
Thanks
Samitha
|