Bug 494920 - Cloning errata to a custom channel causes ISE
Cloning errata to a custom channel causes ISE
Status: CLOSED CURRENTRELEASE
Product: Red Hat Satellite 5
Classification: Red Hat
Component: Server (Show other bugs)
530
All Linux
low Severity medium
: ---
: ---
Assigned To: Justin Sherrill
Sayli Karmarkar
:
Depends On:
Blocks: 456985
  Show dependency treegraph
 
Reported: 2009-04-08 13:51 EDT by Sayli Karmarkar
Modified: 2015-03-22 21:09 EDT (History)
2 users (show)

See Also:
Fixed In Version: sat530
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2009-09-10 16:35:23 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)
before confirming update errata (133.47 KB, image/png)
2009-04-08 13:54 EDT, Sayli Karmarkar
no flags Details
after clicking on update errata (106.57 KB, image/png)
2009-04-08 13:55 EDT, Sayli Karmarkar
no flags Details

  None (edit)
Description Sayli Karmarkar 2009-04-08 13:51:16 EDT
Description of problem:
If we create a clone of a channel with select errata and then go back to manage that channel and try to clone some more errata, its giving an ISE. 

Steps to Reproduce:
1. Create a clone of a channel which has associated errata.
2. Choose "select errata" when cloning channel and leave out 4-5 errata and clone rest of them. 
3. Now go back to manage software channels -> cloned channel -> errata
4. select clone from the tab 
5. It will show 4-5 errata that can be cloned. 
6. Confirm clone errata. 
  
Actual results:
ISE

Expected results:
no ISE and errata should get cloned
Comment 1 Sayli Karmarkar 2009-04-08 13:54:28 EDT
Created attachment 338769 [details]
before confirming update errata
Comment 2 Sayli Karmarkar 2009-04-08 13:55:07 EDT
Created attachment 338770 [details]
after clicking on update errata
Comment 3 Justin Sherrill 2009-04-15 13:22:29 EDT
The following exception occurred while executing this request:
 POST /network/software/channels/manage/errata/clone_confirm.pxt HTTP/1.1 (from browser)
 /network/software/channels/manage/errata/clone_confirm.pxt (from Apache)

Date:
  Wed Apr 15 13:12:14 2009

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: 415
  Content-Type: application/x-www-form-urlencoded
  Cookie: rh_omni_tc=70160000000H4AoAAK; s_vi=[CS]v1|4907A59100005110-A3A0813000024B9[CE]; pysid=8d5c57c20bf108138f785de0728e1b69; s_cc=true; s_sq=redhatglobal%2Credhatcom%3D%2526pid%253Dhttps%25253A//www.redhat.com/wapps/sso/rhn/login.html%25253Fredirect%25253Dhttp%2525253A%2525252F%2525252Frhn.redhat.com%2525252Frhn%2525252FYourRhn.do%2526oid%253DLog%252520In%2526oidt%253D3%2526ot%253DSUBMIT; rh_sso=0|7GbUuTHxzYDOmBnKBIhEcbskrxHklce0bmH; rh_user=rhn-support-jsherril|Justin|member; rh_shared_auth=853cc4631a145cc3ee10e99806d34522f946f410e4f1e00846f179a2fc4b87df5c2f90d4ff5a7b91b3f28b324537638e2d6e18c56622c4291da0a489fb05de2673744e5e94a9cb27dac74b5b13c254d446ef76192932c7d92816b36015a51652; pxt-session-cookie=29986xa8f926ef886cc166cf88a21df1d3c8e0
  Host: columbia.devel.redhat.com
  Keep-Alive: 300
  Referer: https://columbia.devel.redhat.com/network/software/channels/manage/errata/clone_confirm.pxt?cid=931
  User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9.0.7) Gecko/2009030503 Fedora/3.0.7-1.fc10 Firefox/3.0.7

Form variables:
  alphabar_column => 
  cid => 931
  first_lower => 1
  first_upper => 250
  formvars => alphabar_column
  formvars => alphabar_column
  last_lower => 1
  last_upper => 4
  list_action_label_confirm_errata_application => Update Errata
  list_action_url_confirm_errata_application => /network/software/channels/manage/index.pxt
  list_mode => potential_for_cloned_channel
  lower => 1
  next_lower => 1
  next_upper => 4
  prev_lower => 1
  prev_upper => 250
  pxt:trap => rhn:errata_list_cb
  upper => 4

User Information:
  User admin (id 1, org_id 1)

Error notes:
  (none)

Initial Request:
  Yes

Error message:
  RHN::Exception: DBD::Oracle::st execute failed: ORA-00001: unique constraint (RHNSAT.RHN_CE_CE_UQ) violated (DBD ERROR: OCIStmtExecute) [for Statement "INSERT INTO rhnChannelErrata
       (errata_id, channel_id)
VALUES (:eid, :cid)
" with ParamValues: :eid=6944, :cid='931']
  RHN::DB /var/www/lib/RHN/DB.pm 233 RHN::Exception::DB::throw
  RHN::DB::st /var/www/lib/RHN/DB.pm 561 RHN::DB::handle_error
  RHN::DB::ChannelEditor /var/www/lib/RHN/DB/ChannelEditor.pm 886 RHN::DB::st::execute_h
  Sniglets::ListView::ErrataList /var/www/lib/Sniglets/ListView/ErrataList.pm 539 RHN::DB::ChannelEditor::add_cloned_errata_to_channel
  Sniglets::ListView::List /var/www/lib/Sniglets/ListView/List.pm 374 Sniglets::ListView::ErrataList::potential_for_cloned_channel_cb
  Sniglets::Lists /var/www/lib/Sniglets/Lists.pm 142 Sniglets::ListView::List::callback
  PXT::ApacheHandler /var/www/lib/PXT/ApacheHandler.pm 621 Sniglets::Lists::listview_cb
  PXT::ApacheHandler /var/www/lib/PXT/ApacheHandler.pm 124 PXT::ApacheHandler::pxt_parse_data
  PXT::ApacheHandler /var/www/lib/PXT/ApacheHandler.pm 124 (eval)
  main -e 0 PXT::ApacheHandler::handler
  main -e 0 (eval)

Offending Query: INSERT INTO rhnChannelErrata
       (errata_id, channel_id)
VALUES (:eid, :cid)
Comment 4 Justin Sherrill 2009-04-15 15:17:09 EDT
Turns out the set wasn't being cleared, so it was trying to clone errata that was already cloned:

f6762d9
Comment 5 Justin Sherrill 2009-04-15 15:17:36 EDT
master: ea37485
Comment 6 Sayli Karmarkar 2009-04-28 17:21:11 EDT
verified.
Comment 7 Brandon Perkins 2009-08-25 17:11:08 EDT
Release Pending.  No ISE and errata are being cloned.
Comment 8 Brandon Perkins 2009-09-10 16:35:23 EDT
An advisory has been issued which should help the problem
described in this bug report. This report is therefore being
closed with a resolution of ERRATA. For more information
on therefore solution and/or where to find the updated files,
please follow the link below. You may reopen this bug report
if the solution does not work for you.

http://rhn.redhat.com/errata/RHEA-2009-1434.html

Note You need to log in before you can comment on or make changes to this bug.