-
Notifications
You must be signed in to change notification settings - Fork 105
Use ISS export sync for disconnected Updating #4293
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Closed
bangelic
wants to merge
10
commits into
theforeman:master
from
bangelic:bangelic-SAT-24752-Update-doc-gives-inconsistent-choices
Closed
Changes from 9 commits
Commits
Show all changes
10 commits
Select commit
Hold shift + click to select a range
fad4ed5
Update instructions in Updating doc
bangelic 0fd730d
Apply suggestions from review
Lennonka 8bb2295
Apply suggestions from tech review
Lennonka ff785a5
Apply suggestions from peer review
Lennonka 931a449
Replace RHEL with EL for consistency
Lennonka a72e522
Remove unnecessary plus
Lennonka 0b78018
Revert out-of-scope change (article)
Lennonka b7dd14b
Update guides/common/modules/proc_updating-disconnected-server-on-EL9…
Lennonka c98f1dd
Clean up Additional resources
Lennonka cc2dc0a
Apply suggestions from review
Lennonka File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
151 changes: 40 additions & 111 deletions
151
guides/common/modules/proc_updating-disconnected-server-on-EL9.adoc
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,150 +1,79 @@ | ||
| :_mod-docs-content-type: PROCEDURE | ||
|
|
||
| [id="Updating-Disconnected-{project-context}-on-EL9_{context}"] | ||
| = Updating a disconnected {ProjectServer} on {RHEL} 9 | ||
| = Updating a disconnected {ProjectServer} on {EL} 9 | ||
|
|
||
| You can update your disconnected {Project} on {RHEL} 9 by synchronizing the required repositories on the connected {Project} and syncing the content to the disconnected {Project} using `reposync`. | ||
| You can update your disconnected {Project} on {EL} 9 by synchronizing the required repositories on the connected {Project} and syncing the content to the disconnected {Project} by using `syncable` exports. | ||
|
|
||
| .Procedure on the connected {ProjectServer} | ||
| . Ensure that you have synchronized the following repositories in your connected {ProjectServer}: | ||
| . Synchronize the following repositories on your connected {ProjectServer}: | ||
| + | ||
| * {RepoRHEL9BaseOS} | ||
| * {RepoRHEL9AppStream} | ||
| * {RepoRHEL9ServerSatelliteServerProjectVersion} | ||
| * {RepoRHEL9ServerSatelliteMaintenanceProjectVersion} | ||
| . Download the debug certificate of the organization and store it locally at `/etc/pki/katello/certs/org-debug-cert.pem` or a location of your choosing. | ||
| For more information, see {AdministeringDocURL}Creating_an_Organization_Debug_Certificate_admin[Creating an Organization Debug Certificate] in _{AdministeringDocTitle}_. | ||
| . Create a Yum configuration file under `/etc/yum.repos.d`, such as `_{project-context}-disconnected_.repo`, with the following contents: | ||
| + | ||
| [options="nowrap" subs="+quotes,verbatim,attributes"] | ||
| ---- | ||
| [{RepoRHEL9BaseOS}] | ||
| name=Red Hat Enterprise Linux 9 for x86_64 - BaseOS (RPMs) | ||
| baseurl=_https://{foreman-example-com}_/pulp/content/_My_Organization_/Library/content/dist/rhel9/9/x86_64/baseos/os | ||
| enabled = 1 | ||
| sslclientcert = /etc/pki/katello/certs/org-debug-cert.pem | ||
| sslclientkey = /etc/pki/katello/certs/org-debug-cert.pem | ||
| sslcacert = /etc/pki/katello/certs/katello-server-ca.crt | ||
| sslverify = 1 | ||
|
|
||
| [{RepoRHEL9AppStream}] | ||
| name=Red Hat Enterprise Linux 9 for x86_64 - AppStream (RPMs) | ||
| baseurl=_https://{foreman-example-com}_/pulp/content/_My_Organization_/Library/content/dist/rhel9/9/x86_64/appstream/os | ||
| enabled = 1 | ||
| sslclientcert = /etc/pki/katello/certs/org-debug-cert.pem | ||
| sslclientkey = /etc/pki/katello/certs/org-debug-cert.pem | ||
| sslcacert = /etc/pki/katello/certs/katello-server-ca.crt | ||
| sslverify = 1 | ||
|
|
||
| [{RepoRHEL9ServerSatelliteServerProjectVersion}] | ||
| name={ProjectName} {ProjectVersion} for RHEL 9 RPMs x86_64 | ||
| baseurl=_https://{foreman-example-com}_/pulp/content/_My_Organization_/Library/content/dist/layered/rhel9/x86_64/satellite/{ProjectVersion}/os | ||
| enabled = 1 | ||
| sslclientcert = /etc/pki/katello/certs/org-debug-cert.pem | ||
| sslclientkey = /etc/pki/katello/certs/org-debug-cert.pem | ||
| sslcacert = /etc/pki/katello/certs/katello-server-ca.crt | ||
| sslverify = 1 | ||
|
|
||
| [{RepoRHEL9ServerSatelliteMaintenanceProjectVersion}] | ||
| name={ProjectName} Maintenance {ProjectVersion} for RHEL 9 RPMs x86_64 | ||
| baseurl=_https://{foreman-example-com}_/pulp/content/_My_Organization_/Library/content/dist/layered/rhel9/x86_64/sat-maintenance/{ProjectVersion}/os | ||
| enabled = 1 | ||
| sslclientcert = /etc/pki/katello/certs/org-debug-cert.pem | ||
| sslclientkey = /etc/pki/katello/certs/org-debug-cert.pem | ||
| sslcacert = /etc/pki/katello/certs/katello-server-ca.crt | ||
| sslverify = 1 | ||
| ---- | ||
| . In the configuration file, complete the following steps: | ||
| * For the `sslclientcert` and `sslclientkey` options, replace `/etc/pki/katello/certs/org-debug-cert.pem` with the location of the downloaded organization debug certificate. | ||
| * For the `baseurl` option, replace `{foreman-example-com}` with the correct FQDN of your connected {ProjectServer}. | ||
| * For the `baseurl` option, replace `My_Organization` with your organization label. | ||
| . Obtain the organization label: | ||
| + | ||
| ---- | ||
| $ hammer organization list | ||
| ---- | ||
| . Enter the `reposync` command: | ||
| . Export the repositories in the syncable format: | ||
| + | ||
| [options="nowrap" subs="+quotes,verbatim,attributes"] | ||
| ---- | ||
| # dnf reposync \ | ||
| --delete \ | ||
| --disableplugin=foreman-protector \ | ||
| --download-metadata \ | ||
| --repoid {RepoRHEL9AppStream} \ | ||
| --repoid {RepoRHEL9BaseOS} \ | ||
| --repoid {RepoRHEL9ServerSatelliteMaintenanceProjectVersion} \ | ||
| --repoid {RepoRHEL9ServerSatelliteServerProjectVersion} \ | ||
| -n \ | ||
| -p ~/{Project}-repos | ||
| $ hammer content-export complete repository \ | ||
| --id=_Repo_ID_ --format=syncable | ||
Lennonka marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
| ---- | ||
| + | ||
| This downloads the contents of the repositories from the connected {ProjectServer} and stores them in the directory `~/{Project}-repos`. | ||
| . Verify that the RPMs have been downloaded and the repository data directory is generated in each of the sub-directories of `~/{Project}-repos`. | ||
| . Archive the contents of the directory: | ||
| + | ||
| [options="nowrap" subs="+quotes,verbatim,attributes"] | ||
| ---- | ||
| # tar czf {Project}-repos.tgz -C ~ {Project}-repos | ||
| ---- | ||
| . Use the generated `{Project}-repos.tgz` file to update in the disconnected {ProjectServer}. | ||
| . Copy the exported directories to the disconnected {ProjectServer}. | ||
|
|
||
| .Procedure on the disconnected {ProjectServer} | ||
| . Copy the generated `{Project}-repos.tgz` file to your disconnected {ProjectServer}. | ||
| . Extract the archive to anywhere accessible by the `root` user. | ||
| In the following example `/root` is the extraction location. | ||
| + | ||
| [options="nowrap" subs="+quotes,verbatim,attributes"] | ||
| ---- | ||
| # tar zxf {Project}-repos.tgz -C /root | ||
| ---- | ||
| . Create a Yum configuration file under `/etc/yum.repos.d` with the following repository information: | ||
| . Locate the copied exported directories. | ||
| . Create the `/etc/yum.repos.d/upgrade.repo` file and update the `baseurl` values to point to the local file system: | ||
| + | ||
| [options="nowrap" subs="+quotes,verbatim,attributes"] | ||
| ---- | ||
| [{RepoRHEL9BaseOS}] | ||
| name=Red Hat Enterprise Linux 9 for x86_64 - BaseOS (RPMs) | ||
| baseurl=file:///root/{Project}-repos/{RepoRHEL9BaseOS} | ||
| enabled = 1 | ||
|
|
||
| metadata_expire=-1 | ||
| gpgcheck=0 | ||
| cost=500 | ||
| baseurl=file:///_BaseOS_Export_Location_/content/dist/rhel9/9/x86_64/baseos/os | ||
| [{RepoRHEL9AppStream}] | ||
| name=Red Hat Enterprise Linux 9 for x86_64 - AppStream (RPMs) | ||
| baseurl=file:///root/{Project}-repos/{RepoRHEL9AppStream} | ||
| enabled = 1 | ||
|
|
||
| [{RepoRHEL9ServerSatelliteServerProjectVersion}] | ||
| name={ProjectNameX} for RHEL 9 Server RPMs x86_64 | ||
| baseurl=file:///root/{Project}-repos/{RepoRHEL9ServerSatelliteServerProjectVersion} | ||
| enabled = 1 | ||
|
|
||
| [{RepoRHEL9ServerSatelliteMaintenanceProjectVersion}] | ||
| name={ProjectName} Maintenance 6 for RHEL 9 Server RPMs x86_64 | ||
| baseurl=file:///root/{Project}-repos/{RepoRHEL9ServerSatelliteMaintenanceProjectVersion} | ||
| enabled = 1 | ||
| mediaid=None | ||
| metadata_expire=-1 | ||
| gpgcheck=0 | ||
| cost=500 | ||
| baseurl=file:///_AppStream_Export_Location_/content/dist/rhel9/9/x86_64/appstream/os | ||
| [{Project}] | ||
| name={Project} | ||
| mediaid=None | ||
| metadata_expire=-1 | ||
| gpgcheck=0 | ||
| cost=500 | ||
| baseurl=file:///_{Project}_Export_Location_/content/dist/layered/rhel9/x86_64/{project-context}/{ProjectVersion}/os/ | ||
| ---- | ||
| . Upgrade {foreman-maintain} to the next version: | ||
| + | ||
| [options="nowrap" subs="attributes"] | ||
| ---- | ||
| # {foreman-maintain} self-upgrade --maintenance-repo-label={Project} | ||
| ---- | ||
| . In the configuration file, replace the `/root/{Project}-repos` with the extracted location. | ||
| . Use the health check option to determine if the system is ready for update. | ||
| On first use of this command, `{foreman-maintain}` prompts you to enter the hammer admin user credentials and saves them in the `/etc/foreman-maintain/foreman-maintain-hammer.yml` file. | ||
| . Evaluate that the system is ready for update. | ||
| The first time you run this command, `{foreman-maintain}` prompts you to enter the hammer admin user credentials and saves them to `/etc/foreman-maintain/foreman-maintain-hammer.yml`. | ||
| + | ||
| [options="nowrap" subs="+quotes,verbatim,attributes"] | ||
| ---- | ||
| # {foreman-maintain} update check \ | ||
| --whitelist="check-upstream-repository,repositories-validate" | ||
| # {foreman-maintain} update check --whitelist="repositories-validate,repositories-setup" | ||
| ---- | ||
| . Review the results and address any highlighted error conditions before performing the update. | ||
| . Due to the lengthy update time, use a utility such as `tmux` to suspend and reattach a communication session. | ||
| You can then check the update progress without staying connected to the command shell continuously. | ||
| . Review the results and resolve any errors before proceeding with the update. | ||
| . Due to the lengthy update time, use a utility such as `tmux` to suspend and resume the session as needed. | ||
| By using such utility, you can monitor progress without maintaining a continuous connection to the command shell. | ||
| + | ||
| If you lose connection to the command shell where the update command is running, you can see the logged messages in the `{installer-log-file}` file to check if the process completed successfully. | ||
| If the update process is interrupted, check the `{installer-log-file}` file to confirm whether the process completed successfully. | ||
| . Perform the update: | ||
| + | ||
| [options="nowrap" subs="+quotes,verbatim,attributes"] | ||
| ---- | ||
| # {foreman-maintain} update run \ | ||
| --whitelist="check-upstream-repository,repositories-setup,repositories-validate" | ||
| # {foreman-maintain} update run --whitelist="repositories-validate,repositories-setup" | ||
| ---- | ||
|
|
||
| include::snip_steps-needs-reboot.adoc[] | ||
|
|
||
| .Additional resources | ||
| * To restore the backup of the {ProjectServer} or {SmartProxyServer}, see {AdministeringDocURL}Restoring_from_a_Full_Backup_admin[Restoring {ProjectServer} or {SmartProxyServer} from a Backup]. | ||
| * {AdministeringDocURL}Restoring_from_a_Full_Backup_admin[Restoring {ProjectServer} or {SmartProxyServer} from a backup] | ||
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.