Bug 658256
Summary: | "500 Error - Internal Server Error" when scheduling remote commands. | |||
---|---|---|---|---|
Product: | [Community] Spacewalk | Reporter: | Ron Helzer <helzerr> | |
Component: | WebUI | Assignee: | Lukas Zapletal <lzap> | |
Status: | CLOSED CURRENTRELEASE | QA Contact: | Red Hat Satellite QA List <satqe-list> | |
Severity: | high | Docs Contact: | ||
Priority: | low | |||
Version: | 1.2 | CC: | johan, msuchy | |
Target Milestone: | --- | |||
Target Release: | --- | |||
Hardware: | Unspecified | |||
OS: | Unspecified | |||
Whiteboard: | ||||
Fixed In Version: | spacewalk-web-1.3.10-1 | Doc Type: | Bug Fix | |
Doc Text: | Story Points: | --- | ||
Clone Of: | ||||
: | 658085 658250 (view as bug list) | Environment: | ||
Last Closed: | 2011-02-08 08:42:26 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: | 653453 |
Description
Ron Helzer
2010-11-29 19:53:40 UTC
Quick fix: Change line 1036 in System_queries.xml from: "FROM rhn_probe_state PS" To "FROM rhn_probe_state PS, rhnServerOverview OV" Fixes the problem for me. Lukas, it is related to commits 163230506ca86de6efb7dd9e5220018c004d6357 7d337c4d88e4057d542601e2fb48099557e13e05 You may want to fix it. Johan, I edited /usr/lib/perl5/vendor_perl/5.8.8/RHN/DB/DataSource/xml/System_queries.xml as you recommended, however I now get the following error when I confirm the scheduled commands: The following exception occurred while executing this request: POST /network/systems/ssm/provisioning/remote_command_conf.pxt HTTP/1.1 (from browser) /network/systems/ssm/provisioning/remote_command_conf.pxt (from Apache) Date: Tue Nov 30 13:39:08 2010 Headers: Accept: text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8 Accept-Charset: ISO-8859-1,utf-8;q=0.7,*;q=0.7 Accept-Encoding: gzip,deflate Accept-Language: en-us,en;q=0.5 Connection: keep-alive Content-Length: 650 Content-Type: application/x-www-form-urlencoded Cookie: pxt-session-cookie=4443xa249cb265a2d09c16b12a12079db05f0 Host: spacewalk.hgvc.com Keep-Alive: 115 Referer: https://spacewalk.hgvc.com/network/systems/ssm/provisioning/remote_command_conf.pxt User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9.2.12) Gecko/20101026 (CK-IBM) Firefox/3.6.12 ( .NET CLR 3.5.30729; .NET4.0E) Form variables: alphabar_column => SERVER_NAME am_pm => PM day => 30 filter_value => first_lower => 1 first_upper => 50 formvars => hour formvars => hour formvars => hour formvars => hour formvars => hour formvars => hour formvars => hour formvars => hour formvars => hour formvars => hour formvars => hour group => root hour => 1 last_lower => 1 last_upper => 26 list_action_label_schedule_command => Schedule commands list_action_url_schedule_command => list_mode => ssm_remote_commandable lower => 1 minute => 38 month => 11 next_lower => 1 next_upper => 26 prev_filter_value => prev_lower => 1 prev_upper => 50 pxt:trap => rhn:system_list_cb script => #!/bin/sh /bin/true timeout => 600 upper => 26 username => root year => 2010 User Information: User rhelzer (id 1, org_id 1) Error notes: (none) Initial Request: Yes Error message: Died at /usr/lib/perl5/vendor_perl/5.8.8/RHN/DB.pm line 545. Hi! That's another bug, I can't find the bug report right now but here's a patch for it " --- /driften/down/DB.pm 2010-11-29 14:35:47.000000000 +0100 +++ DB.pm 2010-11-29 14:36:06.000000000 +0100 @@ -542,7 +542,8 @@ if (ref $v and blessed($v) and $v->isa("RHN::DB::Type::BLOB")) { if ($self->{Database}->{Driver}->{Name} eq 'Oracle') { - eval 'use DBD::Oracle ()' or die $@; + eval 'use DBD::Oracle ()'; + if ($@) { die $@; } $attr->{ora_type} = DBD::Oracle::ORA_BLOB(); if (defined $v->{ora_field}) { $attr->{ora_field} = $v->{ora_field}; " Change line 545 in /usr/lib/perl5/vendor_perl/5.8.8/RHN/DB.pm and then it'll actually work. I hope. =) Good luck! Johan, I can confirm, applying both the System_queries.xml change and the DB.pm patch and restarting Spacewalk finally allows one to schedule remote commands without 500 errors. Thank you for your assistance! Fixed and cherry picked into Spacewalk 1.2. commit 5acd110b749d0f948b8aca26935f7d8c434ff200 Author: Lukas Zapletal <lzap+git> Date: Wed Dec 1 14:59:52 2010 +0100 658256 - Error 500 - ISE - when scheduling remote commands (cherry picked from commit 5db2eedb1f8247360da182983dbf012dfd09e57b) Oh the commit is not fixing the issue properly. Reverted. Fixed in master commit 3589dbc33ea667fc7e5d17ec5ee8e91eaeb0c8d4 Author: Lukas Zapletal <lzap+git> Date: Thu Dec 2 10:11:26 2010 +0100 658256 - Error 500 - ISE - when scheduling remote commands (proper fix) Proper fix for reverted commit 01595ed07a3db9bc51a14d74a0b031378c12d3b0 @Ron @Jonas: Your solution is not doing what you expect. The workaround is to rewrite whole query to the ANSI compatible syntax notation: http://git.fedorahosted.org/git/?p=spacewalk.git;a=blob;f=web/modules/rhn/RHN/DB/DataSource/xml/System_queries.xml;h=e261064bef88283b3e01ce5ef673e6c53be2959e;hb=3589dbc33ea667fc7e5d17ec5ee8e91eaeb0c8d4#l1027 See the line 1027. Lukáš, I can confirm, replacing the "system_overview" query in System_queries.xml with the version you suggested works and appears to perform much better than the previously suggested fix. This also corrects #658250. - Ron - Moving ON_QA ... This bug has been fixed in Spacewalk 1.3. |