Пример #1
0
    def is_applicable(cls):
        """Returns true if boot cmdline doesn't contain fadump=on"""

        if is_string_in_file("fadump=on", "/proc/cmdline"):
            return False

        return True
Пример #2
0
    def validate(self):
        """Validates the system configuration"""

        # Make sure that if -d (--dump) is provided then only
        # dump plugin should run
        if self.cmd_opts.dump and self.cmd_opts.plugins is None:
            if is_string_in_file("fadump=on", "/proc/cmdline"):
                self.cmd_opts.plugins = ["FADump"]
            else:
                self.cmd_opts.plugins = ["Kdump"]

        self.execute_plugins()
        return self.validation_results