Bug 673694 - spacewalk-remove-channel fails to manage child custom channels.
Summary: spacewalk-remove-channel fails to manage child custom channels.
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Red Hat Satellite 5
Classification: Red Hat
Component: WebUI
Version: 540
Hardware: Unspecified
OS: Unspecified
low
low
Target Milestone: ---
Assignee: Tomas Lestach
QA Contact: Martin Minar
URL:
Whiteboard:
Depends On:
Blocks: sat550-blockers 871399
TreeView+ depends on / blocked
 
Reported: 2011-01-29 20:49 UTC by Dimitar Yordanov
Modified: 2018-11-15 10:00 UTC (History)
8 users (show)

Fixed In Version: spacewalk-backend-1.6.3-1
Doc Type: Bug Fix
Doc Text:
Clone Of:
: 871399 (view as bug list)
Environment:
Last Closed: 2012-09-21 09:18:18 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)

Description Dimitar Yordanov 2011-01-29 20:49:51 UTC
Description of problem:
spacewalk-remove-channel  fails to manage child custom channels.

Version-Release number of selected component (if applicable):
spacewalk-backend-tools-1.2.13-20.el5sat

How reproducible:
Always

Steps to Reproduce:
1.Create custom channel.
2.Create child channel of the custom channel. 
3.spacewalk-remove-channel --list 

Actual results:
Only the parent custum channel is listed.The child channel is missing.

Expected results:
Both, parent and child channels are listed.

Additional info:
spacewalk-remove-channel fails to remove such channels as well.
The problem is related only to custom channels.

Comment 1 Clifford Perry 2011-02-15 16:08:41 UTC
bug within the spacewalk-remove-channel tool. *but* the WebUI should/would work fine. So we have a valid alternative solution. Lower priority bug to be fixed. 

Cliff

Comment 2 Šimon Lukašík 2011-08-02 13:56:57 UTC
Taking.

Comment 3 Šimon Lukašík 2011-08-02 14:05:19 UTC
spacewalk.git 220bb740f47ed96b51dd65a6434e86be1f0a9661

Comment 4 Jiří Mikulka 2011-09-26 08:31:51 UTC
I tried to use this fix on Satellite package spacewalk-backend-tools-1.2.13-55.el6sat.noarch and it seems to be working well on Satellite.

Tested on Satellite 5.4.1 on RHEL 6.2 Server s390x.

Comment 8 Jan Hutař 2012-01-13 13:50:48 UTC
Hello,
using spacewalk-remove-channel from spacewalk-backend-tools-1.2.13-61.el5sat I'm getting this:


# spacewalk-remove-channel -c clone-my-channel
Deleting package metadata (246):
                  ________________________________________
Removing:         ######################################## - complete

ERROR: unhandled exception occurred: ((2292, 'ORA-02292: integrity constraint (RHNSAT.RHN_CHANNEL_PARENT_CH_FK) violated - child record found\n', 'delete from rhnChannel where id = :channel_id')).
Traceback (most recent call last):
  File "/usr/bin/spacewalk-remove-channel", line 559, in ?
    sys.exit(main() or 0)
  File "/usr/bin/spacewalk-remove-channel", line 151, in main
    skip_channels=options.skip_channels)
  File "/usr/bin/spacewalk-remove-channel", line 378, in delete_channels
    h.executemany(channel_id=channel_ids)
  File "/usr/share/rhn/server/rhnSQL/sql_base.py", line 177, in executemany
    return apply(self._execute_wrapper, (self._executemany, ) + p, kw)
  File "/usr/share/rhn/server/rhnSQL/driver_cx_Oracle.py", line 118, in _execute_wrapper
    raise apply(sql_base.SQLError, ret)
SQLError: (2292, 'ORA-02292: integrity constraint (RHNSAT.RHN_CHANNEL_PARENT_CH_FK) violated - child record found\n', 'delete from rhnChannel where id = :channel_id')


That is probably connected to this bug as on WebUI I can see that the channel have child:

  clone-my-channel
   +-- clone-my-child-channel

But the utility do not see the child channel:

  # spacewalk-remove-channel -l
  clone-my-channel

So adding the traceback here as I believe it is connected.

Comment 9 Šimon Lukašík 2012-01-13 14:10:46 UTC
This traceback was described in bug 582646, comment 15.

This traceback will go away after applying this bugfix. There will be
an error message instead:

Error: cannot remove channel clone-my-channel: subchannel(s) exist: 
			child-of-clone-my-child-channel

Comment 13 Clifford Perry 2012-09-21 09:18:18 UTC
This issue is resolved with the release of RHN Satellite 5.5. 

As of September 20th 2012, RHN Satellite 5.5 has been generally available. 

Release Notes and other 5.5 documentation can be found here:

 https://access.redhat.com/knowledge/docs/Red_Hat_Network_Satellite/

The associated Errata for the 5.5 release are:

5.5 Satellite GA Errata
 - http://rhn.redhat.com/errata/RHEA-2012-1296.html

5.5 Upgrade Errata
 - http://rhn.redhat.com/errata/RHEA-2012-1298.html

5.5 RHN Proxy GA Errata
 - http://rhn.redhat.com/errata/RHEA-2012-1297.html

5.5 RHN Tools GA Errata
 - http://rhn.redhat.com/errata/RHEA-2012-1299.html

Regards,
Clifford
- Engineering Manager, Satellite


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