public class VM extends Host
Constructor and Description |
---|
VM(Host host,
java.lang.String name)
Create a `basic' VM (i.e.
|
VM(Host host,
java.lang.String name,
int ramSize,
int migNetSpeed,
int dpIntensity)
Create a VM
|
Modifier and Type | Method and Description |
---|---|
static VM[] |
all() |
void |
destroy() |
static VM |
getVMByName(java.lang.String name) |
void |
internalmig(Host destination)
Invoke native migration routine
|
int |
isCreated()
Returns whether the given VM is currently suspended
|
int |
isMigrating()
Returns whether the given VM is currently running
|
int |
isRunning()
Returns whether the given VM is currently running
|
int |
isSuspended()
Returns whether the given VM is currently suspended
|
void |
migrate(Host destination)
Change the host on which all processes are running
(pre-copy is implemented)
|
static void |
nativeInit()
Class initializer (for JNI), don't do it yourself
|
void |
resume()
Immediately resumes the execution of all processes within the given VM
No resume cost occurs.
|
void |
setBound(double bound)
Set a CPU bound for a given VM.
|
void |
shutdown()
Immediately kills all processes within the given VM.
|
void |
start()
start the VM
|
void |
suspend()
Immediately suspend the execution of all processes within the given VM
No suspension cost occurs.
|
currentHost, getAttachedStorage, getByName, getConsumedEnergy, getCoreNumber, getCount, getData, getMountedStorage, getName, getProperty, getSpeed, hasData, isOn, off, on, setAsyncMailbox, setData, setProperty, toString
public VM(Host host, java.lang.String name)
public VM(Host host, java.lang.String name, int ramSize, int migNetSpeed, int dpIntensity)
host
- Host nodename
- name of the machineramSize
- size of the RAM that should be allocated (in MBytes)migNetSpeed
- (network bandwith allocated for migrations in MB/s, if you don't know put zero ;))dpIntensity
- (dirty page percentage according to migNetSpeed, [0-100], if you don't know put zero ;))public static VM[] all()
public static VM getVMByName(java.lang.String name)
public void destroy()
public int isCreated()
public int isRunning()
public int isMigrating()
public int isSuspended()
public void setBound(double bound)
bound
- in flops/spublic void start()
public void shutdown()
public void internalmig(Host destination) throws java.lang.Exception
java.lang.Exception
public void migrate(Host destination) throws HostFailureException
HostFailureException
public void suspend()
public void resume()
public static void nativeInit()