Hi,
I managed to add a custom process to the list of managed processes by the Watchdog module. To achieve this, I did the following:
- Hardcoded a line with the information of the process in the /opt/psa/etc/modules/watchdog/watchdog_db.sql file:
INSERT INTO module_watchdog_service (name, label, sort_val, start_cmd, stop_cmd) VALUES ('my-process', 'OpenERP PyC', 130, '/etc/init.d/my-process start', '/etc/init.d/my-process stop');
- Created a file in /opt/psa/etc/modules/service.tpl.d with the following contents:
check process my-process
with pidfile "/var/run/my-process.pid"
start = "/etc/init.d/my-process start"
stop = "/etc/init.d/my-process stop"
- After deactivating and activating the module Watchdog, the new service appeared in the list of processes and it has been working perfectly for months.
The thing is that after one of the latest automatic updates, It has stopped working and the list of processes in Watchdog doesn't show my process anymore.
Does anyone know how to solve this or how to add the process to Watchdog using any other method?
Thanks in advance.
Javier
I managed to add a custom process to the list of managed processes by the Watchdog module. To achieve this, I did the following:
- Hardcoded a line with the information of the process in the /opt/psa/etc/modules/watchdog/watchdog_db.sql file:
INSERT INTO module_watchdog_service (name, label, sort_val, start_cmd, stop_cmd) VALUES ('my-process', 'OpenERP PyC', 130, '/etc/init.d/my-process start', '/etc/init.d/my-process stop');
- Created a file in /opt/psa/etc/modules/service.tpl.d with the following contents:
check process my-process
with pidfile "/var/run/my-process.pid"
start = "/etc/init.d/my-process start"
stop = "/etc/init.d/my-process stop"
- After deactivating and activating the module Watchdog, the new service appeared in the list of processes and it has been working perfectly for months.
The thing is that after one of the latest automatic updates, It has stopped working and the list of processes in Watchdog doesn't show my process anymore.
Does anyone know how to solve this or how to add the process to Watchdog using any other method?
Thanks in advance.
Javier