A Python script to monitor the execution of a rsync task.
Project description
rsync-watch.py
A Python script to monitor the execution of a rsync task.
Features
The script rsync-watch.py parses the rsync --stats output and sends this statistics to a monitoring system like Nagios or Icinga using the NSCA protocol.
The script rsync-watch.py can be configured to perform various checks before starting the rsync process.
usage: rsync-watch.py [-h] [--host-name HOST_NAME]
[--dest-user-group USER_GROUP_NAME] [--exclude EXCLUDE]
[--ignore-exceptions IGNORE_EXCEPTIONS]
[--rsync-args RSYNC_ARGS]
[--action-check-failed {exception,skip}]
[--check-file FILE_PATH] [--check-ping DESTINATION]
[--check-ssh-login SSH_LOGIN] [-v]
src dest
A Python script to monitor the execution of a rsync task.
positional arguments:
src The source ([[USER@]HOST:]SRC)
dest The destination ([[USER@]HOST:]DEST)
options:
-h, --help show this help message and exit
--host-name HOST_NAME
The hostname to submit over NSCA to the monitoring.
--dest-user-group USER_GROUP_NAME
Both the user name and the group name of the
destination will be set to this name.
--exclude EXCLUDE See the documention of --exclude in the rsync manual.
--ignore-exceptions IGNORE_EXCEPTIONS
A comma-separated list of exit codes that are not null
and should be ignored. 24 is ignored by default.
--rsync-args RSYNC_ARGS
Rsync CLI arguments. Insert some rsync command line
arguments. Wrap all arguments in one string, for
example: --rsync-args '--exclude "this folder"'
-v, --version show program's version number and exit
checks:
Perform different checks before running the rsync task.
--action-check-failed {exception,skip}
Select action what to do when a check failed.
--check-file FILE_PATH
Check if a file exists on the local machine.
--check-ping DESTINATION
Check if a remote host is reachable by pinging.
DESTINATION can a IP address or a host name or a full
qualified host name.
--check-ssh-login SSH_LOGIN
Check if a remote host is reachable over the network
by SSHing into it. SSH_LOGIN: “root@192.168.1.1” or
“root@example.com” or “example.com”.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file rsync_watch-0.8.0.tar.gz.
File metadata
- Download URL: rsync_watch-0.8.0.tar.gz
- Upload date:
- Size: 5.8 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: uv/0.11.6 {"installer":{"name":"uv","version":"0.11.6","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
c0b2795d4f46876082e84340fb0db2a0e5db779ff0e5b0d9c7fd9df9574d38d6
|
|
| MD5 |
4f9ca715f1169ddc276389573a924b27
|
|
| BLAKE2b-256 |
18a2b4848e034c9fb4e749ea9c92962c3d9d31f2d364a71706b9af9be595eebf
|
File details
Details for the file rsync_watch-0.8.0-py3-none-any.whl.
File metadata
- Download URL: rsync_watch-0.8.0-py3-none-any.whl
- Upload date:
- Size: 7.7 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: uv/0.11.6 {"installer":{"name":"uv","version":"0.11.6","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
7f908f4d4fe07904c93654c7a25085f250e9a138473c25dfc67b2046c2649773
|
|
| MD5 |
014e2d3fc7a633a8cf698c2de2471ba5
|
|
| BLAKE2b-256 |
e2ee94d77c4339475d079eadd3caf47e85c78a7e5d1fe31d5363469f14434687
|