Are any of you aware of any way to get these health checks working on a RHEL 7 system? https://github.com/freeipa/freeipa-healthcheck
IIRC, these checks weren't really introduced until a newer version of FreeIPA, so they are only included on RHEL 8 and above, but I'm wondering if there's a way to get these installed manually. Is this possible on RHEL 7?
I tried doing the following a lab environment:
- Downloaded the code and extracted it - pip3 install pytest-runner - python3 setup.py install
Now, I do have an executable at /usr/local/bin/ipa-healthcheck
However, when I go to run that, I'm getting the following error:
[root@cha-cop-lab-mgt-ath-001 freeipa-healthcheck-master]# /usr/local/bin/ipa-healthcheck Traceback (most recent call last): File "/usr/local/bin/ipa-healthcheck", line 11, in <module> load_entry_point('ipahealthcheck==0.6', 'console_scripts', 'ipa-healthcheck')() File "/usr/lib/python3.6/site-packages/pkg_resources/__init__.py", line 476, in load_entry_point return get_distribution(dist).load_entry_point(group, name) File "/usr/lib/python3.6/site-packages/pkg_resources/__init__.py", line 2700, in load_entry_point return ep.load() File "/usr/lib/python3.6/site-packages/pkg_resources/__init__.py", line 2318, in load return self.resolve() File "/usr/lib/python3.6/site-packages/pkg_resources/__init__.py", line 2324, in resolve module = __import__(self.module_name, fromlist=['__name__'], level=0) ModuleNotFoundError: No module named 'ipahealthcheck'
White, David via FreeIPA-users wrote:
Are any of you aware of any way to get these health checks working on a RHEL 7 system? https://github.com/freeipa/freeipa-healthcheck
IIRC, these checks weren't really introduced until a newer version of FreeIPA, so they are only included on RHEL 8 and above, but I'm wondering if there's a way to get these installed manually. Is this possible on RHEL 7?
I tried doing the following a lab environment:
- Downloaded the code and extracted it
- pip3 install pytest-runner
- python3 setup.py install
Now, I do have an executable at /usr/local/bin/ipa-healthcheck
However, when I go to run that, I'm getting the following error:
[root@cha-cop-lab-mgt-ath-001 freeipa-healthcheck-master]# /usr/local/bin/ipa-healthcheck Traceback (most recent call last): File "/usr/local/bin/ipa-healthcheck", line 11, in <module> load_entry_point('ipahealthcheck==0.6', 'console_scripts', 'ipa-healthcheck')() File "/usr/lib/python3.6/site-packages/pkg_resources/__init__.py", line 476, in load_entry_point return get_distribution(dist).load_entry_point(group, name) File "/usr/lib/python3.6/site-packages/pkg_resources/__init__.py", line 2700, in load_entry_point return ep.load() File "/usr/lib/python3.6/site-packages/pkg_resources/__init__.py", line 2318, in load return self.resolve() File "/usr/lib/python3.6/site-packages/pkg_resources/__init__.py", line 2324, in resolve module = __import__(self.module_name, fromlist=['__name__'], level=0) ModuleNotFoundError: No module named 'ipahealthcheck'
I assume /usr/local/lib/python3.x isn't in your PYTHONPATH. This is a dead-end though as many of the checks aren't applicable to 4.6.x.
I did a backport a few releases ago and built it against EPEL but it's still rough.
https://copr.fedorainfracloud.org/coprs/rcritten/ipa-healthcheck/
rob
I assume /usr/local/lib/python3.x isn't in your PYTHONPATH. This is a dead-end though as many of the checks aren't applicable to 4.6.x.
Ah, that makes sense.
I did a backport a few releases ago and built it against EPEL but it's still rough. https://copr.fedorainfracloud.org/coprs/rcritten/ipa-healthcheck/
That look sweet. Thanks for your work here. I tested it in the lab, and intentionally broke something, and confirmed that it works fine.
I've started writing a number of health checks of my own, apart from your code here, that look for exit status codes. Running your code in debug mode (--debug), I don't see whether or not EACH of these checks are returning a separate status code or not. (i.e. 0 = healthy, or !0 = not healthy)
Does this script do anything like that?
White, David via FreeIPA-users wrote:
I assume /usr/local/lib/python3.x isn't in your PYTHONPATH. This is a dead-end though as many of the checks aren't applicable to 4.6.x.
Ah, that makes sense.
I did a backport a few releases ago and built it against EPEL but it's still rough. https://copr.fedorainfracloud.org/coprs/rcritten/ipa-healthcheck/
That look sweet. Thanks for your work here. I tested it in the lab, and intentionally broke something, and confirmed that it works fine.
I've started writing a number of health checks of my own, apart from your code here, that look for exit status codes. Running your code in debug mode (--debug), I don't see whether or not EACH of these checks are returning a separate status code or not. (i.e. 0 = healthy, or !0 = not healthy)
Does this script do anything like that?
A check can return multiple responses including a mix of success and failure. Every one should return something (if it blows up the healthcheck itself will report that).
I think what you're looking for is something like:
https://github.com/freeipa/freeipa-healthcheck/blob/master/src/ipahealthchec...
rob
freeipa-users@lists.fedorahosted.org