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
ipa-replica-install: properly use the file store #2332
Conversation
We ran into something similar in the past. It was fixed in 082c55f Is that the same issue? |
c4559a0
to
14dd9fd
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The patch doesn't add fstore argument to bindinstance.BindInstance(api=remote_api)
.
In ipa-replica-install, many components use their own instance of the FileStore to backup configuration files to the pre-install state. This causes issues when the calls are mixed, like for instance: ds.do_task1_that_backups_file (using ds.filestore) http.do_task2_that_backups_file (using http.filestore) ds.do_task3_that_backups_file (using ds.filestore) because the list of files managed by ds.filestore does not include the files managed by http.filestore, and the 3rd call would remove any file added on 2nd call. The symptom of this bug is that ipa-replica-install does not save /etc/httpd/conf.d/ssl.conf and subsequent uninstallation does not restore the file, leading to a line referring to ipa-rewrite.conf that prevents httpd startup. The installer should consistently use the same filestore. Fixes https://pagure.io/freeipa/issue/7684
Test that the scenario ipa-replica-install/ uninstall correctly restores the file /etc/httpd/conf.d/ssl.conf Related to https://pagure.io/freeipa/issue/7684
14dd9fd
to
966792a
Compare
082c55f was about the class StateFile (usually linked to sysrestore.state which contains sections and key=value), but this one is related to the class FileStore (sysrestore.index which contains a list of backup files with their permissions uid and gid). @tiran |
966792a
to
c7da2f0
Compare
ipa-replica-install: properly use the file store
In ipa-replica-install, many components use their own instance of the FileStore to backup configuration files to the pre-install state. This causes issues when the calls are mixed, like for instance:
ds.do_task1_that_backups_file (using ds.filestore)
http.do_task2_that_backups_file (using http.filestore)
ds.do_task3_that_backups_file (using ds.filestore)
because the list of files managed by ds.filestore does not include the files managed by http.filestore, and the 3rd call would remove any file added on 2nd call.
The symptom of this bug is that ipa-replica-install does not save /etc/httpd/conf.d/ssl.conf and subsequent uninstallation does not restore the file, leading to a line referring to ipa-rewrite.conf
that prevents httpd startup.
The installer should consistently use the same filestore.
Fixes https://pagure.io/freeipa/issue/7684
Test: scenario replica install/uninstall should restore ssl.conf
Test that the scenario ipa-replica-install/ uninstall correctly restores the file /etc/httpd/conf.d/ssl.conf
Related to https://pagure.io/freeipa/issue/7684