Hide Forgot
Description of problem: katello-restore refuses to restore a backup created with katello-backup --skip-pulp-content Version-Release number of selected component (if applicable): Satellite 6.2.3 katello-common-3.0.0-14.el7sat.noarch How reproducible: always Steps to Reproduce: 1. katello-backup --skip-pulp-content /var/satbackup/2016-10-28 2. satellite-installer --reset 3. katello-restore /var/satbackup/2016-10-28/ Actual results: 20:03:34 [root@satellite ~]# katello-restore /var/satbackup/2016-10-28/ **** Given directory does not include pulp content **** **** Please choose a backup that contains pulp content **** Usage: katello-restore /path/to/dir [options] eg: $ katello-restore /tmp/katello-backup -y, --assumeyes Answer yes for all questions 20:03:54 [root@satellite ~]# Expected results: ability to restore a backup created as per https://access.redhat.com/documentation/en/red-hat-satellite/6.2/paged/server-administration-guide/chapter-6-backup-and-disaster-recovery either via a --no-pulp-present or similar flag to katello-restore or "katello-backup --skip-pulp-content" creating an empty pulp data file Additional info:
workaround; touch pulp_data.tar in the backup directory, prior to running katello-restore
*** Bug 1387785 has been marked as a duplicate of this bug. ***
Created redmine issue http://projects.theforeman.org/issues/17174 from this bug
workaround that doesn't cause errors on restore is to make an empty tarball, rather than touch. tar -vcf pulp_data.tar /dev/null
Upstream bug component is Packaging
Moving this bug to POST for triage into Satellite 6 since the upstream issue http://projects.theforeman.org/issues/17174 has been resolved.
*** Bug 1434812 has been marked as a duplicate of this bug. ***
Verified in Satellite 6.3 Snap 33. Check attached output.txt file for full restore output. -bash-4.2# satellite-backup --skip-pulp-content /tmp Starting backup: 2018-01-31 19:24:27 +0100 Creating backup folder /tmp/satellite-backup-20180131192427 Generating metadata ... Done. Backing up config files... Done. WARNING: This script will stop your services. Do you want to proceed(y/n)? y Stopping services... Redirecting to /bin/systemctl stop foreman-tasks.service Redirecting to /bin/systemctl stop httpd.service Redirecting to /bin/systemctl stop pulp_celerybeat.service Redirecting to /bin/systemctl stop pulp_streamer.service Redirecting to /bin/systemctl stop pulp_resource_manager.service Redirecting to /bin/systemctl stop pulp_workers.service Redirecting to /bin/systemctl stop tomcat.service Redirecting to /bin/systemctl stop postgresql.service Redirecting to /bin/systemctl stop mongod.service Backing up postgres db... Done. Backing up mongo db... Done. Starting services... Redirecting to /bin/systemctl start mongod.service Redirecting to /bin/systemctl start postgresql.service Redirecting to /bin/systemctl start tomcat.service Redirecting to /bin/systemctl start pulp_workers.service Redirecting to /bin/systemctl start pulp_resource_manager.service Redirecting to /bin/systemctl start pulp_streamer.service Redirecting to /bin/systemctl start pulp_celerybeat.service Redirecting to /bin/systemctl start httpd.service Redirecting to /bin/systemctl start foreman-tasks.service Done with backup: 2018-01-31 19:27:49 +0100 **** BACKUP Complete, contents can be found in: /tmp/satellite-backup-20180131192427 **** Performed some changes (including removing hosts) -bash-4.2# satellite-restore /tmp/satellite-backup-20180131192427 WARNING: This script will drop and restore your database. Your existing installation will be replaced with the backup database. Once this operation is complete there is no going back. Are you sure(Y/N)? y Starting restore from /tmp/satellite-backup-20180131192427: 2018-01-31 19:42:01 +0100 Setting file security Done. Resetting Katello yes | foreman-installer -v --reset --scenario satellite --disable-system-checks [ INFO 2018-01-31 19:44:00 verbose] Executing hooks in group pre_migrations ... [ INFO 2018-01-31 19:53:40 verbose] Installer finished in 583.163295715 seconds Done. Stopping Katello services ... Done. Migrating pulp databases ... Attempting to connect to localhost:27017 Attempting to connect to localhost:27017 Write concern for Mongo connection: {} Loading content types. Loading type descriptors [] Parsing type descriptors Validating type descriptor syntactic integrity Validating type descriptor semantic integrity ... Updating the database with types [] Found the following type definitions that were not present in the update collection [puppet_module, docker_tag, ostree, package_langpacks, erratum, docker_blob, docker_manifest, yum_repo_metadata_file, package_group, package_category, iso, package_environment, drpm, srpm, rpm, distribution, docker_image] Updating the database with types [puppet_module, docker_tag, ostree, package_langpacks, erratum, docker_blob, docker_manifest, yum_repo_metadata_file, package_group, package_category, iso, package_environment, drpm, distribution, rpm, srpm, docker_image] Content types loaded. Ensuring the admin role and user are in place. Admin role and user are in place. Beginning database migrations. ... Database migrations complete. Done. Done. Ensuring all Katello processes are started ... Done. Done with restore: 2018-01-31 19:55:43 +0100
Since the problem described in this bug report should be resolved in a recent advisory, it has been closed with a resolution of ERRATA. > > For information on the advisory, and where to find the updated files, follow the link below. > > If the solution does not work for you, open a new bug report. > > https://access.redhat.com/errata/RHSA-2018:0336