Description of problem: "ose-upgrade begin" command throw traceback when doing upgrade testing against RHN subscription Version-Release number of selected component (if applicable): OSE-1.2 RHN stage How reproducible: Always Steps to Reproduce: 1.Register system to RHN Live, setup openshift environment. 2.Edit /etc/sysconfig/rhn/up2date to use stage url according to https://docspace.corp.redhat.com/docs/DOC-64963 3.Register system to RHN Stage to get latest ose-1.2 binaries. 4.Subscribe rhel-x86_64-server-6-osop-1-infrastructure channel 5.Install openshift-enterprise-release 6.Run "ose-upgrade begin" Actual results: [root@broker ~]# ose-upgrade begin INFO: Setting host step 'begin' status to UPGRADING INFO: Starting upgrade number 1 to version 1.2. INFO: loading list of installed packages INFO: RHN subscription detected. In order to reconfigure your RHN channels, we will need credentials. What is your RHN username? qa What is your RHN password (will not show)? INFO: Running upgrade scripts in /usr/lib/ruby/site_ruby/1.8/ose-upgrade/host/upgrades/1/rhn INFO: skipping /usr/lib/ruby/site_ruby/1.8/ose-upgrade/host/upgrades/1/rhn/01-new-channels -- already ran successfully INFO: running /usr/lib/ruby/site_ruby/1.8/ose-upgrade/host/upgrades/1/rhn/02-configure-yum-priorities ERROR: run_script /usr/lib/ruby/site_ruby/1.8/ose-upgrade/host/upgrades/1/rhn/02-configure-yum-priorities had errors: --BEGIN OUTPUT-- + yum install -y yum-plugin-priorities Loaded plugins: priorities, product-id, rhnplugin, security, subscription- : manager This system is not registered to Red Hat Subscription Management. You can use subscription-manager to register. This system is receiving updates from RHN Classic or RHN Satellite. Setting up Install Process Nothing to do + for channel in rhel-x86_64-server-6-ose-1.2-rhc rhel-x86_64-server-6-ose-1.2-infrastructure rhel-x86_64-server-6-ose-1.2-node rhel-x86_64-server-6-ose-1.2-jbosseap + yum-config-manager --setopt=rhel-x86_64-server-6-ose-1.2-rhc.priority=1 rhel-x86_64-server-6-ose-1.2-rhc --save Loaded plugins: priorities, product-id, rhnplugin This system is receiving updates from RHN Classic or RHN Satellite. + for channel in rhel-x86_64-server-6-ose-1.2-rhc rhel-x86_64-server-6-ose-1.2-infrastructure rhel-x86_64-server-6-ose-1.2-node rhel-x86_64-server-6-ose-1.2-jbosseap + yum-config-manager --setopt=rhel-x86_64-server-6-ose-1.2-infrastructure.priority=1 rhel-x86_64-server-6-ose-1.2-infrastructure --save Loaded plugins: priorities, product-id, rhnplugin This system is receiving updates from RHN Classic or RHN Satellite. ============== repo: rhel-x86_64-server-6-ose-1.2-infrastructure =============== [rhel-x86_64-server-6-ose-1.2-infrastructure] bandwidth = 0 base_persistdir = /var/lib/yum/repos/x86_64/6Server baseurl = https://xmlrpc.rhn.errata.stage.redhat.com/XMLRPC/GET-REQ/rhel-x86_64-server-6-ose-1.2-infrastructure cache = 0 cachedir = /var/cache/yum/x86_64/6Server/rhel-x86_64-server-6-ose-1.2-infrastructure cost = 1000 enabled = True enablegroups = True exclude = failovermethod = priority gpgcadir = /var/lib/yum/repos/x86_64/6Server/rhel-x86_64-server-6-ose-1.2-infrastructure/gpgcadir gpgcakey = gpgcheck = True gpgdir = /var/lib/yum/repos/x86_64/6Server/rhel-x86_64-server-6-ose-1.2-infrastructure/gpgdir gpgkey = file:///etc/pki/rpm-gpg/RPM-GPG-KEY-redhat-release hdrdir = /var/cache/yum/x86_64/6Server/rhel-x86_64-server-6-ose-1.2-infrastructure/headers http_caching = True includepkgs = keepalive = 0 label = rhel-x86_64-server-6-ose-1.2-infrastructure mdpolicy = group:primary mediaid = metadata_expire = 21600 metalink = mirrorlist = mirrorlist_expire = 86400 name = Red Hat OpenShift Enterprise 1.2 Infrastructure - x86_64 password = persistdir = /var/lib/yum/repos/x86_64/6Server/rhel-x86_64-server-6-ose-1.2-infrastructure pkgdir = /var/cache/yum/x86_64/6Server/rhel-x86_64-server-6-ose-1.2-infrastructure/packages priority = 99 proxy = proxy_dict = proxy_password = proxy_username = repo_gpgcheck = False retries = 1 rhn_needed_headers = X-RHN-Server-Id, X-RHN-Auth-User-Id, X-RHN-Auth, X-RHN-Auth-Server-Time, X-RHN-Auth-Expire-Offset skip_if_unavailable = False ssl_check_cert_permissions = True sslcacert = /usr/share/rhn/RHNS-CA-CERT sslclientcert = sslclientkey = sslverify = True throttle = 0 timeout = 60.0 up2date_cfg = <up2date_client.config.Config instance at 0x23a3128> username = + for channel in rhel-x86_64-server-6-ose-1.2-rhc rhel-x86_64-server-6-ose-1.2-infrastructure rhel-x86_64-server-6-ose-1.2-node rhel-x86_64-server-6-ose-1.2-jbosseap + yum-config-manager --setopt=rhel-x86_64-server-6-ose-1.2-node.priority=1 rhel-x86_64-server-6-ose-1.2-node --save Loaded plugins: priorities, product-id, rhnplugin This system is receiving updates from RHN Classic or RHN Satellite. + for channel in rhel-x86_64-server-6-ose-1.2-rhc rhel-x86_64-server-6-ose-1.2-infrastructure rhel-x86_64-server-6-ose-1.2-node rhel-x86_64-server-6-ose-1.2-jbosseap + yum-config-manager --setopt=rhel-x86_64-server-6-ose-1.2-jbosseap.priority=1 rhel-x86_64-server-6-ose-1.2-jbosseap --save Loaded plugins: priorities, product-id, rhnplugin This system is receiving updates from RHN Classic or RHN Satellite. + for channel in rhel-x86_64-server-6 + yum-config-manager --setopt=rhel-x86_64-server-6.priority=2 rhel-x86_64-server-6 --save Loaded plugins: priorities, product-id, rhnplugin This system is receiving updates from RHN Classic or RHN Satellite. ========================== repo: rhel-x86_64-server-6 ========================== [rhel-x86_64-server-6] bandwidth = 0 base_persistdir = /var/lib/yum/repos/x86_64/6Server baseurl = https://xmlrpc.rhn.errata.stage.redhat.com/XMLRPC/GET-REQ/rhel-x86_64-server-6 cache = 0 cachedir = /var/cache/yum/x86_64/6Server/rhel-x86_64-server-6 cost = 1000 enabled = True enablegroups = True exclude = failovermethod = priority gpgcadir = /var/lib/yum/repos/x86_64/6Server/rhel-x86_64-server-6/gpgcadir gpgcakey = gpgcheck = True gpgdir = /var/lib/yum/repos/x86_64/6Server/rhel-x86_64-server-6/gpgdir gpgkey = file:///etc/pki/rpm-gpg/RPM-GPG-KEY-redhat-release hdrdir = /var/cache/yum/x86_64/6Server/rhel-x86_64-server-6/headers http_caching = True includepkgs = keepalive = 0 label = rhel-x86_64-server-6 mdpolicy = group:primary mediaid = metadata_expire = 21600 metalink = mirrorlist = mirrorlist_expire = 86400 name = Red Hat Enterprise Linux Server (v. 6 for 64-bit x86_64) password = persistdir = /var/lib/yum/repos/x86_64/6Server/rhel-x86_64-server-6 pkgdir = /var/cache/yum/x86_64/6Server/rhel-x86_64-server-6/packages priority = 99 proxy = proxy_dict = proxy_password = proxy_username = repo_gpgcheck = False retries = 1 rhn_needed_headers = X-RHN-Server-Id, X-RHN-Auth-User-Id, X-RHN-Auth, X-RHN-Auth-Server-Time, X-RHN-Auth-Expire-Offset skip_if_unavailable = False ssl_check_cert_permissions = True sslcacert = /usr/share/rhn/RHNS-CA-CERT sslclientcert = sslclientkey = sslverify = True throttle = 0 timeout = 60.0 up2date_cfg = <up2date_client.config.Config instance at 0x11e70e0> username = Traceback (most recent call last): File "/usr/bin/yum-config-manager", line 179, in <module> repo.cfg.options, repo.iteritems, repo.optionobj, AttributeError: 'RhnRepo' object has no attribute 'cfg' + exit 1 --END /usr/lib/ruby/site_ruby/1.8/ose-upgrade/host/upgrades/1/rhn/02-configure-yum-priorities OUTPUT-- INFO: Setting host step 'begin' status to FAILED Expected results: No any error is seen. Additional info:
https://github.com/openshift/enterprise/pull/24 yum-config-manager does not work for rhn channels, instead per-channel configuration changes need to be made in /etc/yum/pluginconf.d/rhnplugin.conf This changes the upgrade script to use awk to update the rhnplugin.conf file to update priorities/excludes instead of yum-config-manager.
Verified this bug with openshift-enterprise-release-1.1.5-1.el6op.noarch, and PASS. No error is seen now.
I'm closing this since it's not a BZ that needs to be attached to the advisories.