def METHOD_NAME(vm):
    if params.get("stop_rngd"):
        session = vm.wait_for_login()
        error_context.context("Disable rngd service before unplug",
                              test.log.info)
        status, output = session.cmd_status_output(params.get("stop_rngd"))
        if status != 0:
            raise exceptions.TestError(output)
        session.close()