Bug 530519
| Summary: | "Apache: Uptime" probe tries incorrect URL | ||
|---|---|---|---|
| Product: | Red Hat Satellite 5 | Reporter: | Jan Hutař <jhutar> |
| Component: | Monitoring | Assignee: | Miroslav Suchý <msuchy> |
| Status: | CLOSED CURRENTRELEASE | QA Contact: | Petr Sklenar <psklenar> |
| Severity: | medium | Docs Contact: | |
| Priority: | medium | ||
| Version: | 520 | CC: | cperry, jpazdziora, psklenar, xdmoon |
| Target Milestone: | --- | ||
| Target Release: | --- | ||
| Hardware: | All | ||
| OS: | Linux | ||
| Whiteboard: | Fixed in the 5.4.0 Release - GA'd 2010-10-27 | ||
| Fixed In Version: | perl-NOCpulse-Probe-1.184.3-1 | Doc Type: | Bug Fix |
| Doc Text: | Story Points: | --- | |
| Clone Of: | Environment: | ||
| Last Closed: | 2010-10-28 15:02:43 UTC | Type: | --- |
| Regression: | --- | Mount Type: | --- |
| Documentation: | --- | CRM: | |
| Verified Versions: | Category: | --- | |
| oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |
| Cloudforms Team: | --- | Target Upstream Version: | |
| Embargoed: | |||
| Bug Depends On: | |||
| Bug Blocks: | 487678 | ||
|
Description
Jan Hutař
2009-10-23 09:30:50 UTC
If this problem exists on Satellite 5.3.0 as well, this bugzilla should be aligned to sat531-triage. If it does not exist in 5.3.0, this bugzilla should probably be closed as WONTFIX. The issue is caused by spaces in the rhnservernetwork table: SQL> select replace(ipaddr, ' ', '+') from rhnservernetwork where server_id = 1000010023 ; REPLACE(IPADDR,' ---------------- 10.16.98.211++++ SQL> I wonder why other probes are not affected. We should either strip the spaces in monitoring code, or (preferred) strip them in rhnservernetwork and ensure we never have spaces there, via trigger and check or something. I have tested on 530 (sputnik-stage.brq.redhat.com) and I see there: Status: UNKNOWN, HTTP error found at http://192.168.122.141%20:80/server-status: 500 Can't connect to 192.168.122.141 :80 (connect: timeout) (tested on a dead system, so that "connect: timeout" is not important IMO) https://sputnik-stage.brq.redhat.com/rhn/systems/details/probes/ProbeDetails.do?probe_id=167&sid=1000011378 Adding "sat531-triage", removing "sat52maint". It is only in probes which use ./NP/Probe/DataSource/HTTP.pm
becouse of this usage of URI::URL
use URI::URL;
my $uri = new URI::URL('/foooo');
$uri->scheme('http');
$a='127.0.0.1 ';
$uri->host($a);
$uri->port('80');
print $uri;
which will print:
http://127.0.0.1%20%20%20:80/foooo
I fixed HTTP.pm so it strips spaces before passing to URI::URL - commit 8026a276261a9f1f91ae131850fef134ce6b9625 And I also change schema to make column ipaddr varchar(16) as char(16) does not have much sense. commit e539f359155bebeae80e8f41edac2f9e0d4bd0e6 I added probes with Apache: Processes/Requests/Uptime; All was using server-status and probes works as expected. log: Probe(s) assigned to system have an OK status Apache: Processes Max transferred per child 0.090 MB; Max transferred per slot 0.090 MB System Probe(s) assigned to system have an OK status Apache: Requests Traffic 0.217 Kbytes/sec; Request rate 0.050/sec; Current requests 1 System Probe(s) assigned to system have an OK status Apache: Uptime Apache Server uptime: 11 minutes 41 seconds System -- Verified with Satellite-5.4.0-RHEL5-re20100910.2 The 5.4.0 RHN Satellite and RHN Proxy release has occurred. This issue has been resolved with this release. RHEA-2010:0801 - RHN Satellite Server 5.4.0 Upgrade https://rhn.redhat.com/rhn/errata/details/Details.do?eid=10332 RHEA-2010:0803 - RHN Tools enhancement update https://rhn.redhat.com/rhn/errata/details/Details.do?eid=10333 RHEA-2010:0802 - RHN Proxy Server 5.4.0 bug fix update https://rhn.redhat.com/rhn/errata/details/Details.do?eid=10334 RHEA-2010:0800 - RHN Satellite Server 5.4.0 https://rhn.redhat.com/rhn/errata/details/Details.do?eid=10335 Docs are available: http://docs.redhat.com/docs/en-US/Red_Hat_Network_Satellite/index.html Regards, Clifford |