예제 #1
0
def remove_vifs(vmuuid):
    for vifuuid in xenhelpers.xe_param('vm-vif-list', 'uuid', vm=vmuuid):
        run('xe vif-unplug uuid=%s' % vifuuid)
        run('xe vif-destroy uuid=%s' % vifuuid)
예제 #2
0
def test_vifs_exist(vmuuid, vmname):
    vifs = xenhelpers.xe_param('vm-vif-list', 'uuid', vm=vmuuid)
    if not vifs:
        abort('No VIFs found on "%s" (%s). How did you SSH into it then?' % (vmname, vmuuid))