Bug 246300
Summary: | Installation number and repos missing after upgrade to Satellite 5.0 | ||
---|---|---|---|
Product: | Red Hat Satellite 5 | Reporter: | Scott Dodson <sdodson> |
Component: | Upgrades | Assignee: | Jan Pazdziora <jpazdziora> |
Status: | CLOSED CURRENTRELEASE | QA Contact: | Steve Salevan <ssalevan> |
Severity: | high | Docs Contact: | |
Priority: | high | ||
Version: | 500 | CC: | cperry, jpazdziora, rhn-bugs |
Target Milestone: | --- | ||
Target Release: | --- | ||
Hardware: | All | ||
OS: | Linux | ||
Whiteboard: | |||
Fixed In Version: | sat501 | Doc Type: | Bug Fix |
Doc Text: | Story Points: | --- | |
Clone Of: | Environment: | ||
Last Closed: | 2007-08-29 15:34:30 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: |
Description
Scott Dodson
2007-06-29 21:37:29 UTC
moving to 501 maint and Upgrades component. https://satellite.gsslab.rdu.redhat.com/rhn/kickstart/KickstartOptionsEdit.do?ksid=707 http://satellite.gsslab.rdu.redhat.com/kickstart/ks/label/inventory Basically with Satellite 4.2.1 we did the: repo and key lines for RHEL 5 kickstarts statically in Java as they are rendered. With Satellite 5.0 these were added as options, which show up under advanced options for kickstart profile. Scott fixed his 'key' issues by editing under advanced options. What we need to do with the schema upgrade script is to pre-populate within the schema for RHEL 5 kickstart profiles the 'standard' entries that we place : http://rlx-1-12.rhndev.redhat.com/kickstart/ks/label/cliff-test-rhel5 repo --name=Cluster --baseurl=http://rlx-1-12.rhndev.redhat.com/kickstart/dist/ks-rhel-i386-server-5/Cluster repo --name=ClusterStorage --baseurl=http://rlx-1-12.rhndev.redhat.com/kickstart/dist/ks-rhel-i386-server-5/ClusterStorage repo --name=VT --baseurl=http://rlx-1-12.rhndev.redhat.com/kickstart/dist/ks-rhel-i386-server-5/VT repo --name=Workstation --baseurl=http://rlx-1-12.rhndev.redhat.com/kickstart/dist/ks-rhel-i386-server-5/Workstation key --skip Think this is rhnKickstartCommand and rhnKickstartCommandName tables are the ones of interest. This is a SQL to add "key --skip" to any RHEL 5 kickstart which doesn't have any key yet: insert into rhnkickstartcommand ( id, kickstart_id, ks_command_name_id, arguments, created, modified ) select rhn_kscommand_id_seq.nextval, rhnkickstartdefaults.kickstart_id,key_id.id, '--skip', sysdate, null from rhnkickstartdefaults, ( select rhnkickstartcommandname.id from rhnkickstartcommandname where rhnkickstartcommandname.name = 'key' ) key_id, rhnkickstartabletree, rhnksinstalltype where rhnkickstartdefaults.kstree_id = rhnkickstartabletree.id and rhnkickstartabletree.install_type = rhnksinstalltype.id and rhnksinstalltype.label = 'rhel_5' and not exists ( select 1 from rhnkickstartcommand where rhnkickstartdefaults.kickstart_id = rhnkickstartcommand.kickstart_id and rhnkickstartcommand.ks_command_name_id = key_id.id ) For the repo command, is it alright to put in repo --name=Cluster --baseurl=http://rlx-1-12.rhndev.redhat.com/kickstart/dist/ks-rhel-i386-server-5/Cluster even if the base URL will be in the ty form url --url http://rlx-1-12.rhndev.redhat.com/ty/v49bP9JB ? (In reply to comment #5) > For the repo command, is it alright to put in > > repo --name=Cluster > --baseurl=http://rlx-1-12.rhndev.redhat.com/kickstart/dist/ks-rhel-i386-server-5/Cluster > > even if the base URL will be in the ty form > > url --url http://rlx-1-12.rhndev.redhat.com/ty/v49bP9JB > > ? Yes, Jan, this seems exactly what Satellite 5.0.0 is doing when you create a new RHEL 5 kickstart. And here's the URL to add that those four missing repo commands: insert into rhnkickstartcommand ( id, kickstart_id, ks_command_name_id, arguments, created, modified ) select rhn_kscommand_id_seq.nextval, rhnkickstartdefaults.kickstart_id, repo_id.id, '--name=' || names.name || ' --baseurl=' || rtrim(replace(replace(rhnkickstartcommand.arguments, '--url ', ''), 'rhn/kickstart', 'kickstart/dist'), '/') || '/' || names.name, sysdate, null from rhnkickstartdefaults, ( select rhnkickstartcommandname.id from rhnkickstartcommandname where rhnkickstartcommandname.name = 'repo' ) repo_id, rhnkickstartabletree, rhnksinstalltype, ( select rhnkickstartcommandname.id from rhnkickstartcommandname where rhnkickstartcommandname.name = 'url' ) url_id, rhnkickstartcommand, ( select 'Cluster' name from dual union all select 'ClusterStorage' name from dual union all select 'Workstation' name from dual union all select 'VT' name from dual ) names where rhnkickstartdefaults.kstree_id = rhnkickstartabletree.id and rhnkickstartabletree.install_type = rhnksinstalltype.id and rhnksinstalltype.label = 'rhel_5' and not exists ( select 1 from rhnkickstartcommand x where rhnkickstartdefaults.kickstart_id = x.kickstart_id and x.ks_command_name_id = repo_id.id ) and rhnkickstartdefaults.kickstart_id = rhnkickstartcommand.kickstart_id and rhnkickstartcommand.ks_command_name_id = url_id.id and rhnkickstartcommand.arguments like '--url http%' Hi Jan - for me - option #2 is the most ideal solution. We look to have a set of SQL scripts (which you do) which will know for (by checking) for existing RHEL 5 kickstart profiles and for these profiles, during the upgrade add in the additional options into the DB which are needed under advanced options to provide the additional repo and key options still with the RHEL 5 kickstart profile post upgrade from 4.2 to 5.0 Sat. We should also have this script seperate and available to SEG and other to provide to customers who already have upgraded to 'fix' the missing data. Cliff. PS - nice to see I'm not the only person to talk to myself over bugzilla :) A fix to the satellite-4.2-to-5.0.sql script committed to SVN, trunk revision 118458, branch RELEASE-5.0 revision 118459. Moving ON_QA because: Satellite 5.0.1-1 and Proxy 5.0.1-1 are now available on webqa hosted channels. Satellite 5.0.1-1 ISOs are now available. Followed test plan and kickstart w/ 420 KS profile on upgraded 501 Satellite proceeded without interaction. Thus, I'm moving this bug to VERIFIED. RELEASE_PENDING |