<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:

def _verify_run(out, cmd=None):
    '''
    Crash to the log if command execution was not successful.
    '''
    if out.get('retcode', 0) and out['stderr']:
        if cmd:
            log.debug('Command: \'%s\'', cmd)

        log.debug('Return code: %s', out.get('retcode'))
        log.debug('Error output:\n%s', out.get('stderr', 'N/A'))

        raise CommandExecutionError(out['stderr'])