From bbfa16cf0f78111501859302061e9c022a308474 Mon Sep 17 00:00:00 2001 From: Ilya Etingof Date: Fri, 15 Jun 2018 14:36:15 +0200 Subject: [PATCH] Improve logging This is a followup patch to [1] addressing minor fixes and improvements in the area of logging. 1. https://review.openstack.org/#/c/488874 Change-Id: I6c703b35c32644d8769a863fbe7940a002a185f0 --- virtualbmc/cmd/vbmc.py | 9 +++++---- virtualbmc/cmd/vbmcd.py | 2 +- virtualbmc/manager.py | 2 +- 3 files changed, 7 insertions(+), 6 deletions(-) diff --git a/virtualbmc/cmd/vbmc.py b/virtualbmc/cmd/vbmc.py index 304177c..c1782b9 100644 --- a/virtualbmc/cmd/vbmc.py +++ b/virtualbmc/cmd/vbmc.py @@ -98,10 +98,11 @@ class ZmqClient(object): no_daemon = True - LOG.debug("Attempting to start vBMC daemon behind the " - "scenes...") - LOG.debug("Please, configure your system to manage vbmcd " - "by systemd!") + LOG.debug("Attempting to start `vbmcd` behind the " + "scenes. Consider configuring your system to " + "manage `vbmcd` via systemd. Automatic " + "`vbmcd` start up will be removed in the " + "future releases!") # attempt to start and daemonize the server if os.fork() == 0: diff --git a/virtualbmc/cmd/vbmcd.py b/virtualbmc/cmd/vbmcd.py index 1540f5e..66046fd 100644 --- a/virtualbmc/cmd/vbmcd.py +++ b/virtualbmc/cmd/vbmcd.py @@ -70,7 +70,7 @@ def main(argv=sys.argv[1:]): func() except Exception as e: - LOG.error('%(error)s. ', {'error': e}) + LOG.error('%(error)s', {'error': e}) return 1 finally: diff --git a/virtualbmc/manager.py b/virtualbmc/manager.py index b65e02d..158e3a8 100644 --- a/virtualbmc/manager.py +++ b/virtualbmc/manager.py @@ -196,7 +196,7 @@ class VirtualBMCManager(object): if instance and not instance.is_alive(): del self._running_domains[domain_name] - LOG.info( + LOG.debug( 'Reaped vBMC instance for domain %(domain)s ' '(rc %(rc)s)' % {'domain': domain_name, 'rc': instance.exitcode}