{"id":31290143,"url":"https://github.com/stdevel/check_uyuni_currency","last_synced_at":"2025-09-24T14:59:07.316Z","repository":{"id":79816739,"uuid":"70918557","full_name":"stdevel/check_uyuni_currency","owner":"stdevel","description":"A Nagios / Icinga plugin for checking patch currency of hosts managed by Uyuni or SUSE Multi-Linux Manager","archived":false,"fork":false,"pushed_at":"2025-08-25T12:58:08.000Z","size":38,"stargazers_count":2,"open_issues_count":1,"forks_count":1,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-08-25T14:29:07.744Z","etag":null,"topics":["icinga","icinga-plugin","nagios","suse-manager","suse-multi-linux-manager","system-information","system-update","uyuni"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/stdevel.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2016-10-14T14:38:16.000Z","updated_at":"2025-08-25T12:58:12.000Z","dependencies_parsed_at":null,"dependency_job_id":"7c84db60-0e42-4c29-a171-51452ffebd72","html_url":"https://github.com/stdevel/check_uyuni_currency","commit_stats":null,"previous_names":["stdevel/check_uyuni_currency"],"tags_count":2,"template":false,"template_full_name":null,"purl":"pkg:github/stdevel/check_uyuni_currency","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/stdevel%2Fcheck_uyuni_currency","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/stdevel%2Fcheck_uyuni_currency/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/stdevel%2Fcheck_uyuni_currency/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/stdevel%2Fcheck_uyuni_currency/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/stdevel","download_url":"https://codeload.github.com/stdevel/check_uyuni_currency/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/stdevel%2Fcheck_uyuni_currency/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":276769579,"owners_count":25701569,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-09-24T02:00:09.776Z","response_time":97,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["icinga","icinga-plugin","nagios","suse-manager","suse-multi-linux-manager","system-information","system-update","uyuni"],"created_at":"2025-09-24T14:59:04.152Z","updated_at":"2025-09-24T14:59:07.311Z","avatar_url":"https://github.com/stdevel.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# check_uyuni_currency\n\n`check_uyuni_currency` is a Nagios / Icinga plugin for checking patch currency of hosts managed by Uyuni or SUSE Multi-Linux Manager.\n\nThe script checks the patch currency of one or multiple systems. The following information are gathered:\n\n- Outstanding package update counter per category:\n  - critical\n  - important\n  - moderate\n  - low\n  - enhancement\n  - bug fix\n- system currency score\n\nTo gather these information a valid username / password combination to your management system is required. The login credentials **are prompted** when running the script. To automate this you have two options:\n\n## Setting shell variables\n\nThe following shell variables are used:\n\n- `UYUNI_LOGIN` - a username\n- `UYUNI_PASSWORD` - the appropriate password\n\nYou might also want to set the `HISTFILE` variable (*depending on your shell*) to hide the command including the password in the history:\n\n```command\n$ HISTFILE=\"\" UYUNI_LOGIN=mylogin UYUNI_PASSWORD=mypass ./check_uyuni_currency.py -S giertz.stankowic.loc\n```\n\n## Using an authfile\n\nA better possibility is to create a authfile with permisions **0600**. Just enter the username in the first line and the password in the second line and hand the path to the script:\n\n```command\n$ ./check_uyuni_currency.py -a myauthfile -S giertz.stankowic.loc\n```\n\n## Requirements\n\nThe plugin requires the `xmlrpclic` module which is shipped with `rhnlib`.\nA minimum API version of 24 is required - the script checks the API version and aborts if you are using a historic version of Uyuni.\n\n## Usage\n\nBy default, the script checks a particular system or multiple systems for outstanding bug fixes and critical updates (*combining critical, important and also moderate patch metrics*). It is possible to control this behaviour by specifying additional parameters (*see below*).\nThe script also support performance data for data visualization.\n\nThe following parameters can be specified:\n\n| Parameter | Description |\n|:----------|:------------|\n| `-d` / `--debug` | enable debugging outputs (*default: no*) |\n| `-h` / `--help` | shows help and quits |\n| `-P` / `--show-perfdata` | enables performance data (*default: no*) |\n| `-a` / `--authfile` | defines an auth file to use instead of shell variables |\n| `-s` / `--server` | defines the server to use (*default: localhost*) |\n| `-k` / `--insecure` | disables SSL verification (*default: no*) |\n| `-S` / `--system` | defines one or multiple system(s) to check |\n| `-A` / `--all-systems` | checks all registered systems - USE WITH CAUTION (*default: no*) |\n| `-t` / `--total-warning` | defines total package update warning threshold (*default: empty*) |\n| `-T` / `--total-critical` | defines total package update critical threshold (*default: empty*) |\n| `-i` / `--important-warning` | defines security package (*critical, important and moderate security fixes*) update warning threshold (*default: 10*) |\n| `-I` / `--important-critical` | defines security package (*critical, important and moderate security fixes*) update warning threshold (*default: 20*) |\n| `-b` / `--bugs-warning` | defines bug package update warning threshold (*default: 25*) |\n| `-B` / `--bugs-critical` | defines bug package update warning threshold (*default: 50*) |\n| `-y` / `--generic-statistics` | checks for inactive and outdated system statistic metrics (*default :no*) |\n| `-u` / `--outdated-warning` | defines outdated systems warning percentage threshold (*default: 50*) |\n| `-U` / `--outdated-critical` | defines outdated systems critical percentage threshold (*default: 80*) |\n| `-n` / `--inactive-warning` | defines inactive systems warning percentage threshold (*default: 10*) |\n| `-N` / `--inactive-critical` | defines inactive systems critical percentage threshold (*default: 50*) |\n| `--version` | prints programm version and quits |\n\n## Examples\n\nThe following example checks a single system on the local Uyuni server:\n\n```command\n$ ./check_uyuni_currency.py -S giertz.stankowic.loc\nUsername: admin\nPassword:\nOK: critical updates okay (0), bug fixes okay (0) for giertz.stankowic.loc\n```\n\nChecking multiple systems on a remote Uyuni server, authentication using authfile:\n\n```command\n$ ./check_uyuni_currency.py -s st-uyuni02.stankowic.loc -a uyuni.auth -S giertz.stankowic.loc -S shittyrobots.test.loc\nOK: giertz.stankowic.loc critical updates okay (0)critical updates okay (0), shittyrobots.test.loc bug fixes okay (0)shittyrobots.test.loc bug fixes okay (0)\n```\n\nChecking a single host on a local Uyuni installation, also checking total updates, enabling performance data:\n\n```command\n$ ./check_uyuni_currency.py -S giertz.stankowic.loc -t 20 -T 40 -P\nUsername: admin\nPassword:\nOK: total updates okay (0), critical updates okay (0), bug fixes okay (0) for giertz.stankowic.loc | 'crit_pkgs'=0;10;20;; 'imp_pkgs'=0;10;20;; 'mod_pkgs'=0;10;20;; 'low_pkgs'=0;;;; 'enh_pkgs'=0;;;; 'bug_pkgs'=0;25;50;; 'score'=0;;;;\n```\n\nWhen specifying multiple systems along with performance data, the metric names will get prefix according to the particular host:\n\n```command\n$ ./check_uyuni_currency.py -S giertz.stankowic.loc -S shittyrobots.test.loc -a uyuni.auth -P\nOK: shittyrobots.test.loc critical updates okay (0)giertz.stankowic.loc critical updates okay (0), shittyrobots.test.loc bug fixes okay (0)giertz.stankowic.loc bug fixes okay (0) | 'shittyrobots.test.loc_crit_pkgs'=0;10;20;; 'shittyrobots.test.loc_imp_pkgs'=0;10;20;; 'shittyrobots.test.loc_mod_pkgs'=0;10;20;; 'shittyrobots.test.loc_low_pkgs'=0;;;; 'shittyrobots.test.loc_enh_pkgs'=0;;;; 'shittyrobots.test.loc_bug_pkgs'=0;25;50;; 'shittyrobots.test.loc_score'=0;;;;'giertz.stankowic.loc_crit_pkgs'=0;10;20;; 'giertz.stankowic.loc_imp_pkgs'=0;10;20;; 'giertz.stankowic.loc_mod_pkgs'=0;10;20;; 'giertz.stankowic.loc_low_pkgs'=0;;;; 'giertz.stankowic.loc_enh_pkgs'=0;;;; 'giertz.stankowic.loc_bug_pkgs'=0;25;50;; 'giertz.stankowic.loc_score'=0;;;;\n```\n\nChecking generic statistics of an Uyuni system:\n\n```command\n$ ./check_uyuni_currency.py -a uyuni.auth -y -P\nOK: outdated systems okay (0), inactive systems okay (0) | 'sys_total'=9;;;; 'sys_outdated'=9;5;8;; 'sys_inact'=0;1;5;;\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fstdevel%2Fcheck_uyuni_currency","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fstdevel%2Fcheck_uyuni_currency","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fstdevel%2Fcheck_uyuni_currency/lists"}