Ignore:
Timestamp:
Feb 14, 2009, 6:13:55 PM (16 years ago)
Author:
iannucci
Message:

Modified invirt-availability and invirt-vmcontrol to stat /etc/invirt/nocreate.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/packages/invirt-remote/host/usr/sbin/invirt-availability

    r2107 r2113  
    2020    All math is done in kilobytes for consistency
    2121    Output is in MB
     22
     23    Bail if /etc/invirt/nocreate exists
    2224    """
     25    try:
     26        os.stat('/etc/invirt/nocreate')
     27        print 0
     28        return 0
     29    except OSError:
     30        pass
     31
    2332    p = Popen(['/usr/sbin/xm', 'info'], stdout=PIPE)
    2433    output = p.communicate()[0]
Note: See TracChangeset for help on using the changeset viewer.