← Back to team overview

openstack team mailing list archive

Horizon logging?

 

I want to put some debug logging statements in a custom "overrides.py" module for Horizon.  But I can't figure out where the messages will be logged.  They don't go in the apache logs and they don't appear in any of the nova logs.  Horizon doesn't appear to have its own logging, so Im a little stumped.

Im using the standard LOGGING definition in /etc/openstack_dashboard/local_settings.py:

LOGGING = {
        'version': 1,
        # When set to True this will disable all logging except
        # for loggers specified in this configuration dictionary. Note that
        # if nothing is specified here and disable_existing_loggers is True,
        # django.db.backends will still log unless it is disabled explicitly.
        'disable_existing_loggers': False,
        'handlers': {
            'null': {
                'level': 'DEBUG',
                'class': 'django.utils.log.NullHandler',
                },
            'console': {
                # Set the level to "DEBUG" for verbose output logging.
                'level': 'DEBUG',
                'class': 'logging.StreamHandler',
                },
            },
        'loggers': {
            # Logging from django.db.backends is VERY verbose, send to null
            # by default.
            'django.db.backends': {
                'handlers': ['null'],
                'propagate': False,
                },
            'horizon': {
                'handlers': ['console'],
                'propagate': False,
            },
            'openstack_dashboard': {
                'handlers': ['console'],
                'propagate': False,
            },
            'novaclient': {
                'handlers': ['console'],
                'propagate': False,
            },
            'keystoneclient': {
                'handlers': ['console'],
                'propagate': False,
            },
            'glanceclient': {
                'handlers': ['console'],
                'propagate': False,
            },
            'nose.plugins.manager': {
                'handlers': ['console'],
                'propagate': False,
            }
        }
}


My custom override module just uses 
LOG = logging.getLogger(__name__)

and then when I want to log something, I'm using:
                LOG.debug("Some message…")

Ideally, I think I'd like to have horizon stuff go into its own log file, but if that's too involved, I'd be happy to have them in the standard syslog file or even one of the nova logs. Any suggestions here would be greatly appreciated.

thanks,
  Wyllys