'Function to perform post boot checks such as if the system configuration
has changed across reboots (specifically, CPUs and partitions).
:param subdir: The subdir to use in the job.record call.
:param running_id: An optional running_id to include in the reboot
failure log message
:raise JobError: Raised if the current configuration does not match the
pre-reboot configuration.'

def _check_post_reboot(self, subdir, running_id=None):

    abort_on_mismatch = settings.get_value('CLIENT', 'abort_on_mismatch', type=bool, default=False)
    partition_list = partition_lib.get_partition_list(self, exclude_swap=False)
    mount_info = partition_lib.get_mount_info(partition_list)
    old_mount_info = self._state.get('client', 'mount_info')
    if (mount_info != old_mount_info):
        new_entries = (mount_info - old_mount_info)
        old_entries = (old_mount_info - mount_info)
        description = ('mounted    partitions    are    different    after    reboot    (old    entries:    %s,    new    entries:    %s)' % (old_entries, new_entries))
        if abort_on_mismatch:
            self._record_reboot_failure(subdir, 'reboot.verify_config', description, running_id=running_id)
            raise error.JobError(('Reboot    failed:    %s' % description))
        else:
            logging.warning(description)
    cpu_count = utils.count_cpus()
    old_count = self._state.get('client', 'cpu_count')
    if (cpu_count != old_count):
        description = ('Number    of    CPUs    changed    after    reboot    (old    count:    %d,    new    count:    %d)' % (old_count, cpu_count))
        if abort_on_mismatch:
            self._record_reboot_failure(subdir, 'reboot.verify_config', description, running_id=running_id)
            raise error.JobError(('Reboot    failed:    %s' % description))
        else:
            logging.warning(description)
