Skip to content

Commit 3ddc293

Browse files
authored
Update README.md
1 parent aa31707 commit 3ddc293

File tree

1 file changed

+10
-6
lines changed

1 file changed

+10
-6
lines changed

README.md

Lines changed: 10 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -9,24 +9,25 @@ _It will start, monitor and restart applications if they crash or stop sending h
99
The Process Watchdog is a Linux-based utility designed to start, monitor and manage processes specified in a configuration file. It ensures the continuous operation of these processes by periodically checking their status and restarting them if necessary.
1010

1111
## Overview
12-
This application acts as a vigilant guardian for your critical processes, ensuring they remain operational at all times. It accomplishes this task by regularly monitoring the specified processes and taking appropriate actions if any anomalies are detected. The primary function of this application is to ensure that the managed processes remain active, restarting them if they crash or stop sending heartbeat signals over UDP.
12+
This application acts as a vigilant guardian for your critical processes, ensuring they remain operational at all times. It accomplishes this task by regularly monitoring the specified processes and taking appropriate actions if any anomalies are detected. The primary function of this application is to ensure that the managed processes remain active, restarting them if they crash or stop sending heartbeat messages.
1313

14-
This application is particularly useful in environments where multiple processes need to be constantly running, such as server systems or embedded devices. It operates based on the principle that each monitored process should periodically send its process ID (PID) over UDP. If a process fails to send its PID within the specified time interval, the watchdog manager assumes the process has crashed and automatically restarts it.
14+
This application is particularly useful in environments where multiple processes need to be constantly running, such as server systems, clouds or embedded devices. It operates based on the principle that each monitored process should periodically send heartbeat messages. If a process fails to send a heartbeat within the specified time interval, the watchdog manager assumes the process has halted/hang and automatically restarts it.
1515

1616
## Features
1717
- Starts and monitors specified processes listed in a configuration file.
18-
- Restarts processes that have crashed or stopped sending their PID.
18+
- Restarts processes that have crashed or stopped sending their heartbeat.
1919
- Listens to a specified UDP port for heartbeat messages containing process IDs (PIDs).
2020
- Provides a centralized platform for managing multiple processes, enhancing operational efficiency.
2121
- Provides file command interface to manually start, stop, or restart individual processes or the entire watchdog system or even a Linux reboot.
2222
- Generates statistics log files to track the status and history of each managed process.
2323

2424
## Requirements
25-
- Processes managed by Process Watchdog must periodically send their PID over UDP to prevent being restarted.
25+
- Processes managed by Process Watchdog must periodically send their heartbeat messages to prevent being restarted.
2626
- Configuration file `config.ini` in the same directory with details about the processes to be managed and the UDP port for communication.
2727

2828
## Configuration File : `config.ini`
2929
An example configuration file looks like this:
30+
Note that ping means heartbeat.
3031

3132
```ini
3233
[processWatchdog]
@@ -65,8 +66,10 @@ nWdtApps = 4
6566
- `ping_interval` : Maximum time period in seconds between pings.
6667
- `cmd` : Command to start the application.
6768

68-
## Example Heartbeat Message Code
69-
The managed processes must send a message containing their PID with prefix `p` (Ex: `p12345`) over UDP. Below are example heartbeat message codes in various languages.
69+
## Heartbeat Message
70+
A heartbeat message is a UDP message containing the managed process's process IDs (PID) with the prefix p (e.g., p12345). This message is periodically sent to the specified UDP port.
71+
72+
Below are example heartbeat message codes in various languages:
7073

7174
### Java
7275
```java
@@ -334,6 +337,7 @@ Use the provided `run.sh` script to start the Process Watchdog application. This
334337
Or just `./run.sh &` which is recommended.
335338

336339
## TODO
340+
- Replace ping with heartbeat in the code and .ini
337341
- Redesign the apps.c
338342
- Add CPU & RAM usage to the statistics
339343
- Create easy-to-use heartbeat libraries

0 commit comments

Comments
 (0)