Re: [Freeipa-devel] [PATCH] 323 Report ipa-upgradeconfig errors during RPM upgrade
Martin Kosek wrote: On 10/19/2012 03:23 PM, Rob Crittenden wrote: Petr Viktorin wrote: On 10/19/2012 08:15 AM, Martin Kosek wrote: On 10/18/2012 05:51 PM, Rob Crittenden wrote: Martin Kosek wrote: On 10/18/2012 05:22 PM, Rob Crittenden wrote: Martin Kosek wrote: Report errors just like with ipa-ldap-updater. These messages should warn user that some parts of the upgrades may have not been successful and he should follow up on them. Otherwise, user may not notice them at all. ipa-upgradeconfig logging has been made consistent with ipa-ldap-updater logging - only error level or higher severity log messages are printed to stderr, with the same console format. A new debug log that an upgrade script has started was added to make log investigation easier. https://fedorahosted.org/freeipa/ticket/3157 --- Reproducer is in Bugzilla attached to the ticket. With this patch, RPM update will report errors to user: # rpm -Uvh --force ~/freeipa-master/dist/rpms/freeipa-* Preparing... ### [100%] 1:freeipa-python ### [ 14%] 2:freeipa-client ### [ 29%] 3:freeipa-admintools ### [ 43%] 4:freeipa-server ### [ 57%] ERROR: Cannot update connections in /etc/named.conf: [Errno 13] Permission denied: '/etc/named.conf' 5:freeipa-server-selinux ### [ 71%] 6:freeipa-server-trust-ad### [ 86%] 7:freeipa-debuginfo ### [100%] Martin Can you add an option to run in info mode (the equivalent of verbose=True)? Otherwise running from the cli returns nothing unless there is an error, I like some amount of output myself. rob ipa-upgradeconfig has a --debug option. I doubt that the output can be more verbose :-) Martin Yeah, but there is no middle ground. You either get everything or nothing. rob Well, I can add it if you want it really hard. But from my perspective, having both "--debug" and "--verbose" is strange and it will also make it inconsistent with our other CLI tools where we have just --debug option (ipa-ldap-updater, ipa-replica-prepare, ipa-*-install). I like ipa-replica-conncheck's approach: --debug (output everything) and --quiet (only output errors). I guess I'm sad because we spent a fair bit of time adding pretty output to the script in non-debug mode which we are not suppressing. ACK on quiet mode. rob Ok, you won, this actually makes sense - added a --quiet mode. I also played a bit with console level formatting and print the level only in --debug mode. Martin ACK, pushed to master and ipa-3-0 ___ Freeipa-devel mailing list Freeipa-devel@redhat.com https://www.redhat.com/mailman/listinfo/freeipa-devel
Re: [Freeipa-devel] [PATCH] 323 Report ipa-upgradeconfig errors during RPM upgrade
On 10/19/2012 04:06 PM, Martin Kosek wrote: On 10/19/2012 03:23 PM, Rob Crittenden wrote: Petr Viktorin wrote: On 10/19/2012 08:15 AM, Martin Kosek wrote: On 10/18/2012 05:51 PM, Rob Crittenden wrote: Martin Kosek wrote: On 10/18/2012 05:22 PM, Rob Crittenden wrote: Martin Kosek wrote: Report errors just like with ipa-ldap-updater. These messages should warn user that some parts of the upgrades may have not been successful and he should follow up on them. Otherwise, user may not notice them at all. ipa-upgradeconfig logging has been made consistent with ipa-ldap-updater logging - only error level or higher severity log messages are printed to stderr, with the same console format. A new debug log that an upgrade script has started was added to make log investigation easier. https://fedorahosted.org/freeipa/ticket/3157 --- Reproducer is in Bugzilla attached to the ticket. With this patch, RPM update will report errors to user: # rpm -Uvh --force ~/freeipa-master/dist/rpms/freeipa-* Preparing... ### [100%] 1:freeipa-python ### [ 14%] 2:freeipa-client ### [ 29%] 3:freeipa-admintools ### [ 43%] 4:freeipa-server ### [ 57%] ERROR: Cannot update connections in /etc/named.conf: [Errno 13] Permission denied: '/etc/named.conf' 5:freeipa-server-selinux ### [ 71%] 6:freeipa-server-trust-ad### [ 86%] 7:freeipa-debuginfo ### [100%] Martin Can you add an option to run in info mode (the equivalent of verbose=True)? Otherwise running from the cli returns nothing unless there is an error, I like some amount of output myself. rob ipa-upgradeconfig has a --debug option. I doubt that the output can be more verbose :-) Martin Yeah, but there is no middle ground. You either get everything or nothing. rob Well, I can add it if you want it really hard. But from my perspective, having both "--debug" and "--verbose" is strange and it will also make it inconsistent with our other CLI tools where we have just --debug option (ipa-ldap-updater, ipa-replica-prepare, ipa-*-install). I like ipa-replica-conncheck's approach: --debug (output everything) and --quiet (only output errors). I guess I'm sad because we spent a fair bit of time adding pretty output to the script in non-debug mode which we are not suppressing. ACK on quiet mode. rob Ok, you won, this actually makes sense - added a --quiet mode. I also played a bit with console level formatting and print the level only in --debug mode. Nice idea. I think it would be useful if standard_logging_setup did this by default (though this patch is probably not the place for standard_logging_setup changes). -- PetrĀ³ ___ Freeipa-devel mailing list Freeipa-devel@redhat.com https://www.redhat.com/mailman/listinfo/freeipa-devel
Re: [Freeipa-devel] [PATCH] 323 Report ipa-upgradeconfig errors during RPM upgrade
On 10/19/2012 03:23 PM, Rob Crittenden wrote: > Petr Viktorin wrote: >> On 10/19/2012 08:15 AM, Martin Kosek wrote: >>> On 10/18/2012 05:51 PM, Rob Crittenden wrote: Martin Kosek wrote: > On 10/18/2012 05:22 PM, Rob Crittenden wrote: >> Martin Kosek wrote: >>> Report errors just like with ipa-ldap-updater. These messages >>> should warn >>> user that some parts of the upgrades may have not been successful and >>> he should follow up on them. Otherwise, user may not notice them >>> at all. >>> >>> ipa-upgradeconfig logging has been made consistent with >>> ipa-ldap-updater >>> logging - only error level or higher severity log messages are >>> printed >>> to stderr, with the same console format. A new debug log that an >>> upgrade >>> script has started was added to make log investigation easier. >>> >>> https://fedorahosted.org/freeipa/ticket/3157 >>> >>> --- >>> >>> Reproducer is in Bugzilla attached to the ticket. With this patch, >>> RPM update >>> will report errors to user: >>> >>> # rpm -Uvh --force ~/freeipa-master/dist/rpms/freeipa-* >>> Preparing... >>> ### [100%] >>> 1:freeipa-python >>> ### [ >>> 14%] >>> 2:freeipa-client >>> ### [ >>> 29%] >>> 3:freeipa-admintools >>> ### [ >>> 43%] >>> 4:freeipa-server >>> ### [ >>> 57%] >>> ERROR: Cannot update connections in /etc/named.conf: [Errno 13] >>> Permission >>> denied: '/etc/named.conf' >>> 5:freeipa-server-selinux >>> ### [ >>> 71%] >>> >>> 6:freeipa-server-trust-ad### >>> [ >>> 86%] >>> 7:freeipa-debuginfo >>> ### >>> [100%] >>> >>> Martin >> >> Can you add an option to run in info mode (the equivalent of >> verbose=True)? >> Otherwise running from the cli returns nothing unless there is an >> error, I like >> some amount of output myself. >> >> rob >> > > ipa-upgradeconfig has a --debug option. I doubt that the output can > be more > verbose :-) > > Martin > Yeah, but there is no middle ground. You either get everything or nothing. rob >>> >>> Well, I can add it if you want it really hard. But from my >>> perspective, having >>> both "--debug" and "--verbose" is strange and it will also make it >>> inconsistent >>> with our other CLI tools where we have just --debug option >>> (ipa-ldap-updater, >>> ipa-replica-prepare, ipa-*-install). >>> >> >> I like ipa-replica-conncheck's approach: --debug (output everything) and >> --quiet (only output errors). >> > > I guess I'm sad because we spent a fair bit of time adding pretty output to > the > script in non-debug mode which we are not suppressing. > > ACK on quiet mode. > > rob Ok, you won, this actually makes sense - added a --quiet mode. I also played a bit with console level formatting and print the level only in --debug mode. Martin From 95366eb5f5685415be348c64f15308ed19ee7c71 Mon Sep 17 00:00:00 2001 From: Martin Kosek Date: Wed, 17 Oct 2012 13:05:24 +0200 Subject: [PATCH] Report ipa-upgradeconfig errors during RPM upgrade Report errors just like with ipa-ldap-updater. These messages should warn user that some parts of the upgrades may have not been successful and he should follow up on them. Otherwise, user may not notice them at all. ipa-upgradeconfig now has a new --quiet option to make it output only error level log messages or higher. ipa-upgradeconfig run without options still pring INFO log messages as it can provide a clean overview about its actions (unlike ipa-ldap-updater). https://fedorahosted.org/freeipa/ticket/3157 --- freeipa.spec.in | 5 - install/tools/ipa-upgradeconfig | 15 --- install/tools/man/ipa-upgradeconfig.8 | 4 3 files changed, 20 insertions(+), 4 deletions(-) diff --git a/freeipa.spec.in b/freeipa.spec.in index 060f09b12e6891defc8cb00d4f52a0d019198a70..916630029f6dfac8ef32dabb00f338052cbbf08e 100644 --- a/freeipa.spec.in +++ b/freeipa.spec.in @@ -493,7 +493,7 @@ if [ $1 = 1 ]; then fi %endif if [ $1 -gt 1 ] ; then -/usr/sbin/ipa-upgradeconfig >/dev/null 2>&1 || : +/usr/sbin/ipa-upgradeconfig --quiet >/dev/null || : fi %posttrans server @@ -815,6 +815,9 @@ fi %ghost %attr(0644,root,apache) %config(noreplace) %{_sysconfdir}/ipa/ca.crt %changelog +* Wed Oct 17 2012 Martin Kosek - 2.99.0-51 +- Print ipa-upgradeconfig errors during RPM update + * Wed Oct 10 2012 Alexander Bokovoy - 2.99.0-50 - Make sure server-trust-ad subpackage alte
Re: [Freeipa-devel] [PATCH] 323 Report ipa-upgradeconfig errors during RPM upgrade
Petr Viktorin wrote: On 10/19/2012 08:15 AM, Martin Kosek wrote: On 10/18/2012 05:51 PM, Rob Crittenden wrote: Martin Kosek wrote: On 10/18/2012 05:22 PM, Rob Crittenden wrote: Martin Kosek wrote: Report errors just like with ipa-ldap-updater. These messages should warn user that some parts of the upgrades may have not been successful and he should follow up on them. Otherwise, user may not notice them at all. ipa-upgradeconfig logging has been made consistent with ipa-ldap-updater logging - only error level or higher severity log messages are printed to stderr, with the same console format. A new debug log that an upgrade script has started was added to make log investigation easier. https://fedorahosted.org/freeipa/ticket/3157 --- Reproducer is in Bugzilla attached to the ticket. With this patch, RPM update will report errors to user: # rpm -Uvh --force ~/freeipa-master/dist/rpms/freeipa-* Preparing... ### [100%] 1:freeipa-python ### [ 14%] 2:freeipa-client ### [ 29%] 3:freeipa-admintools ### [ 43%] 4:freeipa-server ### [ 57%] ERROR: Cannot update connections in /etc/named.conf: [Errno 13] Permission denied: '/etc/named.conf' 5:freeipa-server-selinux ### [ 71%] 6:freeipa-server-trust-ad### [ 86%] 7:freeipa-debuginfo ### [100%] Martin Can you add an option to run in info mode (the equivalent of verbose=True)? Otherwise running from the cli returns nothing unless there is an error, I like some amount of output myself. rob ipa-upgradeconfig has a --debug option. I doubt that the output can be more verbose :-) Martin Yeah, but there is no middle ground. You either get everything or nothing. rob Well, I can add it if you want it really hard. But from my perspective, having both "--debug" and "--verbose" is strange and it will also make it inconsistent with our other CLI tools where we have just --debug option (ipa-ldap-updater, ipa-replica-prepare, ipa-*-install). I like ipa-replica-conncheck's approach: --debug (output everything) and --quiet (only output errors). I guess I'm sad because we spent a fair bit of time adding pretty output to the script in non-debug mode which we are not suppressing. ACK on quiet mode. rob ___ Freeipa-devel mailing list Freeipa-devel@redhat.com https://www.redhat.com/mailman/listinfo/freeipa-devel
Re: [Freeipa-devel] [PATCH] 323 Report ipa-upgradeconfig errors during RPM upgrade
On 10/19/2012 08:15 AM, Martin Kosek wrote: On 10/18/2012 05:51 PM, Rob Crittenden wrote: Martin Kosek wrote: On 10/18/2012 05:22 PM, Rob Crittenden wrote: Martin Kosek wrote: Report errors just like with ipa-ldap-updater. These messages should warn user that some parts of the upgrades may have not been successful and he should follow up on them. Otherwise, user may not notice them at all. ipa-upgradeconfig logging has been made consistent with ipa-ldap-updater logging - only error level or higher severity log messages are printed to stderr, with the same console format. A new debug log that an upgrade script has started was added to make log investigation easier. https://fedorahosted.org/freeipa/ticket/3157 --- Reproducer is in Bugzilla attached to the ticket. With this patch, RPM update will report errors to user: # rpm -Uvh --force ~/freeipa-master/dist/rpms/freeipa-* Preparing...### [100%] 1:freeipa-python ### [ 14%] 2:freeipa-client ### [ 29%] 3:freeipa-admintools ### [ 43%] 4:freeipa-server ### [ 57%] ERROR: Cannot update connections in /etc/named.conf: [Errno 13] Permission denied: '/etc/named.conf' 5:freeipa-server-selinux ### [ 71%] 6:freeipa-server-trust-ad### [ 86%] 7:freeipa-debuginfo ### [100%] Martin Can you add an option to run in info mode (the equivalent of verbose=True)? Otherwise running from the cli returns nothing unless there is an error, I like some amount of output myself. rob ipa-upgradeconfig has a --debug option. I doubt that the output can be more verbose :-) Martin Yeah, but there is no middle ground. You either get everything or nothing. rob Well, I can add it if you want it really hard. But from my perspective, having both "--debug" and "--verbose" is strange and it will also make it inconsistent with our other CLI tools where we have just --debug option (ipa-ldap-updater, ipa-replica-prepare, ipa-*-install). I like ipa-replica-conncheck's approach: --debug (output everything) and --quiet (only output errors). -- PetrĀ³ ___ Freeipa-devel mailing list Freeipa-devel@redhat.com https://www.redhat.com/mailman/listinfo/freeipa-devel
Re: [Freeipa-devel] [PATCH] 323 Report ipa-upgradeconfig errors during RPM upgrade
On 10/18/2012 05:51 PM, Rob Crittenden wrote: > Martin Kosek wrote: >> On 10/18/2012 05:22 PM, Rob Crittenden wrote: >>> Martin Kosek wrote: Report errors just like with ipa-ldap-updater. These messages should warn user that some parts of the upgrades may have not been successful and he should follow up on them. Otherwise, user may not notice them at all. ipa-upgradeconfig logging has been made consistent with ipa-ldap-updater logging - only error level or higher severity log messages are printed to stderr, with the same console format. A new debug log that an upgrade script has started was added to make log investigation easier. https://fedorahosted.org/freeipa/ticket/3157 --- Reproducer is in Bugzilla attached to the ticket. With this patch, RPM update will report errors to user: # rpm -Uvh --force ~/freeipa-master/dist/rpms/freeipa-* Preparing...### [100%] 1:freeipa-python ### [ 14%] 2:freeipa-client ### [ 29%] 3:freeipa-admintools ### [ 43%] 4:freeipa-server ### [ 57%] ERROR: Cannot update connections in /etc/named.conf: [Errno 13] Permission denied: '/etc/named.conf' 5:freeipa-server-selinux ### [ 71%] 6:freeipa-server-trust-ad### [ 86%] 7:freeipa-debuginfo ### [100%] Martin >>> >>> Can you add an option to run in info mode (the equivalent of verbose=True)? >>> Otherwise running from the cli returns nothing unless there is an error, I >>> like >>> some amount of output myself. >>> >>> rob >>> >> >> ipa-upgradeconfig has a --debug option. I doubt that the output can be more >> verbose :-) >> >> Martin >> > > Yeah, but there is no middle ground. You either get everything or nothing. > > rob Well, I can add it if you want it really hard. But from my perspective, having both "--debug" and "--verbose" is strange and it will also make it inconsistent with our other CLI tools where we have just --debug option (ipa-ldap-updater, ipa-replica-prepare, ipa-*-install). Martin ___ Freeipa-devel mailing list Freeipa-devel@redhat.com https://www.redhat.com/mailman/listinfo/freeipa-devel
Re: [Freeipa-devel] [PATCH] 323 Report ipa-upgradeconfig errors during RPM upgrade
Martin Kosek wrote: On 10/18/2012 05:22 PM, Rob Crittenden wrote: Martin Kosek wrote: Report errors just like with ipa-ldap-updater. These messages should warn user that some parts of the upgrades may have not been successful and he should follow up on them. Otherwise, user may not notice them at all. ipa-upgradeconfig logging has been made consistent with ipa-ldap-updater logging - only error level or higher severity log messages are printed to stderr, with the same console format. A new debug log that an upgrade script has started was added to make log investigation easier. https://fedorahosted.org/freeipa/ticket/3157 --- Reproducer is in Bugzilla attached to the ticket. With this patch, RPM update will report errors to user: # rpm -Uvh --force ~/freeipa-master/dist/rpms/freeipa-* Preparing...### [100%] 1:freeipa-python ### [ 14%] 2:freeipa-client ### [ 29%] 3:freeipa-admintools ### [ 43%] 4:freeipa-server ### [ 57%] ERROR: Cannot update connections in /etc/named.conf: [Errno 13] Permission denied: '/etc/named.conf' 5:freeipa-server-selinux ### [ 71%] 6:freeipa-server-trust-ad### [ 86%] 7:freeipa-debuginfo ### [100%] Martin Can you add an option to run in info mode (the equivalent of verbose=True)? Otherwise running from the cli returns nothing unless there is an error, I like some amount of output myself. rob ipa-upgradeconfig has a --debug option. I doubt that the output can be more verbose :-) Martin Yeah, but there is no middle ground. You either get everything or nothing. rob ___ Freeipa-devel mailing list Freeipa-devel@redhat.com https://www.redhat.com/mailman/listinfo/freeipa-devel
Re: [Freeipa-devel] [PATCH] 323 Report ipa-upgradeconfig errors during RPM upgrade
On 10/18/2012 05:22 PM, Rob Crittenden wrote: > Martin Kosek wrote: >> Report errors just like with ipa-ldap-updater. These messages should warn >> user that some parts of the upgrades may have not been successful and >> he should follow up on them. Otherwise, user may not notice them at all. >> >> ipa-upgradeconfig logging has been made consistent with ipa-ldap-updater >> logging - only error level or higher severity log messages are printed >> to stderr, with the same console format. A new debug log that an upgrade >> script has started was added to make log investigation easier. >> >> https://fedorahosted.org/freeipa/ticket/3157 >> >> --- >> >> Reproducer is in Bugzilla attached to the ticket. With this patch, RPM update >> will report errors to user: >> >> # rpm -Uvh --force ~/freeipa-master/dist/rpms/freeipa-* >> Preparing...### >> [100%] >> 1:freeipa-python ### [ >> 14%] >> 2:freeipa-client ### [ >> 29%] >> 3:freeipa-admintools ### [ >> 43%] >> 4:freeipa-server ### [ >> 57%] >> ERROR: Cannot update connections in /etc/named.conf: [Errno 13] Permission >> denied: '/etc/named.conf' >> 5:freeipa-server-selinux ### [ >> 71%] >> 6:freeipa-server-trust-ad### [ >> 86%] >> 7:freeipa-debuginfo ### >> [100%] >> >> Martin > > Can you add an option to run in info mode (the equivalent of verbose=True)? > Otherwise running from the cli returns nothing unless there is an error, I > like > some amount of output myself. > > rob > ipa-upgradeconfig has a --debug option. I doubt that the output can be more verbose :-) Martin ___ Freeipa-devel mailing list Freeipa-devel@redhat.com https://www.redhat.com/mailman/listinfo/freeipa-devel
Re: [Freeipa-devel] [PATCH] 323 Report ipa-upgradeconfig errors during RPM upgrade
Martin Kosek wrote: Report errors just like with ipa-ldap-updater. These messages should warn user that some parts of the upgrades may have not been successful and he should follow up on them. Otherwise, user may not notice them at all. ipa-upgradeconfig logging has been made consistent with ipa-ldap-updater logging - only error level or higher severity log messages are printed to stderr, with the same console format. A new debug log that an upgrade script has started was added to make log investigation easier. https://fedorahosted.org/freeipa/ticket/3157 --- Reproducer is in Bugzilla attached to the ticket. With this patch, RPM update will report errors to user: # rpm -Uvh --force ~/freeipa-master/dist/rpms/freeipa-* Preparing...### [100%] 1:freeipa-python ### [ 14%] 2:freeipa-client ### [ 29%] 3:freeipa-admintools ### [ 43%] 4:freeipa-server ### [ 57%] ERROR: Cannot update connections in /etc/named.conf: [Errno 13] Permission denied: '/etc/named.conf' 5:freeipa-server-selinux ### [ 71%] 6:freeipa-server-trust-ad### [ 86%] 7:freeipa-debuginfo ### [100%] Martin Can you add an option to run in info mode (the equivalent of verbose=True)? Otherwise running from the cli returns nothing unless there is an error, I like some amount of output myself. rob ___ Freeipa-devel mailing list Freeipa-devel@redhat.com https://www.redhat.com/mailman/listinfo/freeipa-devel