[Spacewalk-list] Error 500 Spacewalk 1.5

Jan Pazdziora jpazdziora at redhat.com
Thu Aug 4 13:56:05 UTC 2011


On Thu, Jul 28, 2011 at 10:45:51AM -0700, Robert Hernandez wrote:
> Hi,
> 
> I upgraded from Spacewalk 1.4 Postgres to 1.5 Postgres.  I am getting
> a web 500 errors when trying to do various actions in spacewalk.

Are these regressions against Spacewalk 1.4?

> These actions include SSM, re-activation keys, and viewing failed
> schedule actions.  The failed action results in a Fatal error in
> Python code occured [[6]] when I try to add file => import a file to
> one of my systems.  It schedules the action but fails when the client
> picks it up.  Ive included three tracebacks.  Any help would be
> greatly appreciated.
> 
> When I try to use a Group in SSM I get the following traceback:
> 
> The following exception occurred while executing this request:
>  GET /network/systems/ssm/system_list.pxt HTTP/1.1 (from browser)
>  /network/systems/ssm/system_list.pxt (from Apache)
> 
> Date:
>  Thu Jul 28 10:14:40 2011
> 
> 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
>  Cookie: __utma=224265929.55040022.1285266800.1308933712.1311100466.20;
> __utmz=224265929.1311100466.20.17.utmcsr=google|utmccn=(organic)|utmcmd=organic|utmctr=xxx%20xxx%20direct%20deposit;
> pxt-session-cookie=121xc329806d994312ad3c01c5cfcead2733
>  Host: spacewalk.xxx.xxx
>  Keep-Alive: 115
>  Referer: https://spacewalk.xxx.xxx/rhn/systems/SystemGroupList.do
>  User-Agent: Mozilla/5.0 (Windows; U; Windows NT 6.1; en-US;
> rv:1.9.2.18) Gecko/20110614 Firefox/3.6.18
> 
> Form variables:
> 
> User Information:
>  User admin (id 1, org_id 1)
> 
> Error notes:
>  (none)
> 
> Initial Request:
>  Yes
> 
> Error message:
>  Cannot bind unknown placeholder ':p1' at
> /usr/lib/perl5/vendor_perl/5.8.8/RHN/DB.pm line 560.
> 
> When I try to use re-activation I get:
> 
> The following exception occurred while executing this request:
>  POST /network/systems/details/activation.pxt HTTP/1.1 (from browser)
>  /network/systems/details/activation.pxt (from Apache)
> 
> Date:
>  Thu Jul 28 10:26:40 2011
> 
> 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: 144
>  Content-Type: application/x-www-form-urlencoded
>  Cookie: __utma=224265929.55040022.1285266800.1308933712.1311100466.20;
> __utmz=224265929.1311100466.20.17.utmcsr=google|utmccn=(organic)|utmcmd=organic|utmctr=xxx%20xxx%20direct%20deposit;
> pxt-session-cookie=121xc329806d994312ad3c01c5cfcead2733
>  Host: spacewalk.xxx.xxx
>  Keep-Alive: 115
>  Referer: https://spacewalk.xxx.xxx/network/systems/details/activation.pxt?sid=1000010007
>  User-Agent: Mozilla/5.0 (Windows; U; Windows NT 6.1; en-US;
> rv:1.9.2.18) Gecko/20110614 Firefox/3.6.18
> 
> Form variables:
>  formvar_hmac => 9ca45cd38d16a5e911bbf683f16db0f1f758474b
>  generate_new_key => Generate New Key
>  pxt:trap => rhn:system-activation-key-cb
>  sid => 1000010007
> 
> User Information:
>  User admin (id 1, org_id 1)
> 
> Error notes:
>  (none)
> 
> Initial Request:
>  Yes
> 
> Error message:
>  RHN::Exception: DBD::Pg::st execute failed: ERROR:  missing
> FROM-clause entry for table "rhn_reg_token_seq" at character 8
> 
>  RHN::DB /usr/lib/perl5/vendor_perl/5.8.8/RHN/DB.pm 228
> RHN::Exception::DB::throw
>  RHN::DB::Token /usr/lib/perl5/vendor_perl/5.8.8/RHN/DB/Token.pm 430
> RHN::DB::handle_error

In RHN/DB/Token.pm, you will find line like

	my $sth = $dbh->prepare("SELECT rhn_reg_token_seq.nextval FROM DUAL");

That needs to be make database-agnostic, using the guide at

	https://fedorahosted.org/spacewalk/wiki/PostgreSQLPortingGuide#Portablenextval

Please send in a patch so that we can include the fix in the next
version of Spacewalk.

-- 
Jan Pazdziora
Principal Software Engineer, Satellite Engineering, Red Hat




More information about the Spacewalk-list mailing list