Alexander Bokovoy wrote:
On Wed, 12 Oct 2011, Rob Crittenden wrote:
Well, in the "generate new file" option I think the output is a bit
misleading.

+        print "New SSSD config will be generated. The old one is
backed up and can be restored during uninstall"

There could have been no existing sssd.conf, right?

+        logging.error("Failed to parse SSSD configuration and will
generate new one")

This could imply that an error occurred when in fact there just was
no sssd.conf to import.

Otherwise the approach looks good.
New version is attached. Works fine for me -- both in case
uninstall-after-upgrade (means no installation code was run and
nothing in state/file store) and normal install/uninstall. I also
tried installing/uninstalling with missing sssd.conf and all went
well:

1. Missing sssd.conf
---------------------
Enrolled in IPA realm IPA.LOCAL
Created /etc/ipa/default.conf
New SSSD config will be created.
Configured /etc/sssd/sssd.conf
Configured /etc/krb5.conf for IPA realm IPA.LOCAL
SSSD enabled
NTP enabled
Client configuration complete.
---------------------

2. Invalid sssd.conf
---------------------
Enrolled in IPA realm IPA.LOCAL
Created /etc/ipa/default.conf
Unable to parse existing SSSD config. As option --preserve-sssd was not 
specified, new config will override the old one.
The old /etc/sssd/sssd.conf is backed up and will be restored during uninstall.
root        : ERROR    Unable to parse existing SSSD config and --preserve-sssd 
was not specified:
Configured /etc/sssd/sssd.conf
Configured /etc/krb5.conf for IPA realm IPA.LOCAL
SSSD enabled
NTP enabled
Client configuration complete.
---------------------

3. Existing proper sssd.conf
---------------------
Enrolled in IPA realm IPA.LOCAL
Created /etc/ipa/default.conf
Configured /etc/sssd/sssd.conf
Configured /etc/krb5.conf for IPA realm IPA.LOCAL
SSSD enabled
NTP enabled
Client configuration complete.
---------------------

The only visible difference is change of comment symbol from ';' to
'#' for the existing correct sssd.conf, but that's how SSSDConfig
works.

ack, pushed to master and ipa-2-1

rob

_______________________________________________
Freeipa-devel mailing list
Freeipa-devel@redhat.com
https://www.redhat.com/mailman/listinfo/freeipa-devel

Reply via email to