lisa.trace.DmesgCollector#

class lisa.trace.DmesgCollector(target, *, empty_buffer=False, facility='kern', level='debug', output_path=None, parse_error=None)[source]#

Bases: CollectorBase

Wrapper around devlib.collector.dmesg.DmesgCollector.

It installs the dmesg tool automatically on the target upon creation, so we know what version is being is used.

Attributes

LOG_LEVELS

NAME

Name of the collector class.

TOOLS

Sequence of tools to install on the target when using the collector.

Properties

logger inherited

Convenience short-hand for self.get_logger().

Methods

__enter__() inherited

__exit__() inherited

__getattr__ inherited

Delegate attribute lookup to a private attribute.

get_data() inherited

Similar to devlib.collector.CollectorBase.get_data() but takes the path directly as a parameter in order to disallow representing an invalid state where no path has been set.

get_logger() inherited

Provides a logging.Logger named after cls.

log_locals() inherited

Debugging aid: log the local variables of the calling function.

Attributes#

DmesgCollector.LOG_LEVELS = ['emerg', 'alert', 'crit', 'err', 'warn', 'notice', 'info', 'debug']#
DmesgCollector.NAME = 'dmesg'#

Name of the collector class.

DmesgCollector.TOOLS = ['dmesg']#

Sequence of tools to install on the target when using the collector.

Properties#

property DmesgCollector.logger#

Inherited property, see lisa.utils.Loggable.logger

Convenience short-hand for self.get_logger().

Methods#

DmesgCollector.__enter__()#

Inherited method, see lisa.trace.CollectorBase.__enter__()

DmesgCollector.__exit__(*args, **kwargs)#

Inherited method, see lisa.trace.CollectorBase.__exit__()

DmesgCollector.__getattr__(attr)#

Inherited method, see lisa.trace.CollectorBase.__getattr__

Delegate attribute lookup to a private attribute.

DmesgCollector.get_data(path=None)#

Inherited method, see lisa.trace.CollectorBase.get_data()

Similar to devlib.collector.CollectorBase.get_data() but takes the path directly as a parameter in order to disallow representing an invalid state where no path has been set.

classmethod DmesgCollector.get_logger(suffix=None)#

Inherited method, see lisa.utils.Loggable.get_logger()

Provides a logging.Logger named after cls.

classmethod DmesgCollector.log_locals(var_names=None, level='debug')#

Inherited method, see lisa.utils.Loggable.log_locals()

Debugging aid: log the local variables of the calling function.