CSS434 Process Migration: Textbook 7.4.2 and Non-Textbook Contents
CSS434 Process Migration: Textbook 7.4.2 and Non-Textbook Contents
CSS434 Process Migration: Textbook 7.4.2 and Non-Textbook Contents
servers.
Reducing network traffic
Migrating processes closer to the resources they are using
most heavily.
Improving system reliability
Migrating processes from a site in failure to more reliable
sites
Replicating and migrating critical processes to a remote.
CPU registers
Captured upon a freeze
Address space
Difficult to restore pointers
I/O state:
Fast I/O Operations
source node.
Some popular files available at the destination node
Suspended
Migration Migration Migration
Suspended decision decision Freezing decision
time
Freezing
resumed time resumed
Merits: easy implementation Merits: freezing time reduce Merits: quick migration
Demerits: long delay time Demerits: total time extended Demerits: large memory latency
Dest 2 Dest 2
Current location
Dest 2 Dest 2
Conventional Approach
client server
Network
Encapsulation
All code and data are carried with an agent.
Agents:
1. State: Execution state to be resumed upon a migration
2. Implementation: Architectural independent code
3. Interface: Facility to communicate with places and other
agents
4. Identifier: Agent identifier
5. Authority/Principal: The owner of agent
Places:
1. Engine: Place to execute agents
2. Resource: CPU, memory, database, etc.
3. Location: IP + logical location id
4. Principal: The owner of place
CSS434 Process Migration 17
Mobile Agents
Process Migration v.s. Mobile Agents
uw1-320-lab: ~css434/hw3/uwagent }
void init( ) {
String[] args = new String[2];
args[0] = Integer.toString( 10 );
args[1] = Integer.toString( 3 );
hop( ) hop( ) hop( “uw1-320-01”, “power”, String[] funcArgs );
}
void power( String[] args ) {
base = Integer.parseInt( args[0] );
MyAgent MyAgent MyAgent exp = Integer.parseInt( args[1] );
init( ) power( ) Factorial( ) for ( int j = 0; j < exp; j++ );
pow += base;
System.out.println( “host =” + getInetAddress( ) + “power =” + pow );
hop( “uw1-320-02”, “factorial”, String[] args );
Uw1-320-00 Uw1-320-01 Uw1-320-02 }
void factorial( String[] arg ) {
base = Integer.parseInt( args[0] );
fact = 1;
for ( int j = base; j > 0; j== )
fact *= j;
System.out.println( “host =“ + getInetAddress( ) + “fact =“ + fact );
}