50
Load Balancing using Mobile Agent Approach Prepared by: Wong Tsz Yeung,Ah Mole Supervisor : Prof. Michael Lyu 18 December 2000

Load Balancing using Mobile Agent Approach

  • Upload
    shlomo

  • View
    43

  • Download
    2

Embed Size (px)

DESCRIPTION

Load Balancing using Mobile Agent Approach. Prepared by: Wong Tsz Yeung,Ah Mole Supervisor : Prof. Michael Lyu 18 December 2000. Introduction (1). Autonomous Agents 2 kinds of research going on : Multi-Agent System; and Mobile Agent How do they different?? - PowerPoint PPT Presentation

Citation preview

Page 1: Load Balancing using Mobile Agent Approach

Load Balancing using Mobile Agent Approach

Prepared by: Wong Tsz Yeung,Ah Mole

Supervisor : Prof. Michael Lyu

18 December 2000

Page 2: Load Balancing using Mobile Agent Approach

Introduction (1)Autonomous Agents

2 kinds of research going on : Multi-Agent System; and Mobile Agent

How do they different?? What are the advantages and

disadvantages of using them??

Page 3: Load Balancing using Mobile Agent Approach

Introduction (2)Parallel Computing

Load Balancing In the past - Super Computer with multi-processor Nowadays - Cluster of Single of multi-processor

machines

Can we build a system that combine the advantages of agent and load balancing??

Page 4: Load Balancing using Mobile Agent Approach

Multi-Agent System (MAS) (1)The goal of MAS :

Creating a system that interconnects separately developed agents, thus enabling the ensemble to function beyond the capabilities of any singular agent in the system.

Implication: Specialization on agents.

Page 5: Load Balancing using Mobile Agent Approach

Multi-Agent System (MAS) (2)Every Agent is specialized to perform

particular task.

To perform a task, an agent that is on behalf of the user need to communicate with one or more agents in order to complete a task.

Page 6: Load Balancing using Mobile Agent Approach

Multi-Agent System (MAS) (3)All the agents in a MAS can be provided

by one by more venders given that:

Agents are using the same language in communication.

Agents are having the same kind of knowledge.

Page 7: Load Balancing using Mobile Agent Approach

Multi-Agent System (MAS) (4)For Example:

A business from US wants to arrange a trip from New York to Hong Kong.

He has to plan: Which airline will he take?? Which hotel will he stay??

Page 8: Load Balancing using Mobile Agent Approach

Multi-Agent System (MAS) (5) Fortunately, the business man has a

personal agent. i.e. his secretary

Then, the secretary phones the airline companies and hotels for information.

Page 9: Load Balancing using Mobile Agent Approach

Multi-Agent System (MAS) (6) She can make a final decision based on

the criteria given by her boss. E.g.

Choose the cheapest airline. Choose the most comfortable hotel.

The above case shows how human agents work.

Page 10: Load Balancing using Mobile Agent Approach

Multi-Agent System (MAS) (7)We can treat the above case as:

Agent

user

Airline Agent 1

Airline Agent 2

Hotel Agent 1

Hotel Agent 2

Page 11: Load Balancing using Mobile Agent Approach

Multi-Agent System (MAS) (8)Advantages

Technically speaking

It is autonomous in the sense that the agent can find a service provider, query for suitable information and determine the final result.

Every service provider has its own implementation. However, it is transparent to the user agent.

Page 12: Load Balancing using Mobile Agent Approach

Multi-Agent System (MAS) (9) Economically speaking

Every agent is specialized, so it can sell the service. User can buy the service which meets he/she criteria.

Page 13: Load Balancing using Mobile Agent Approach

Challenges in MAS (1) Information Discovery Problem

Human Agent : Go to Yahoo! to search for the related information.

How can software agent locate other agents??

Page 14: Load Balancing using Mobile Agent Approach

Challenges in MAS (2)

Service-seekingagent

Discoveryserver

Lookupserver

serviceprovider

Searching for service provider.

Return a list of name ofservice provider.

Lookup the address ofa service provider.

Successfully locate a serviceprovider.

Page 15: Load Balancing using Mobile Agent Approach

Challenges in MAS (3)The Discover server provides yellow

page service.The Lookup server provides white page

service.Jini also has such discovery-and-lookup

mechanism.

Page 16: Load Balancing using Mobile Agent Approach

Challenges in MAS (4)Communication Problem

It is the communication language problem. E.g. On the Internet, we have HTML which is

widely used. An agent-to-agent language is more preferable. KQML - Knowledge Query Markup Language. ACL - Agent Communication Language from

FIPA.

Page 17: Load Balancing using Mobile Agent Approach

Challenges in MAS (5)Ontology Problem

It is problem dealing with the context of the communication language.

E.g. Bus has a meaning in the transportation field while it is different in computer field.

The agents involved in a MAS must agree on and share a common definition of concepts.

Page 18: Load Balancing using Mobile Agent Approach

Challenges in MAS (6) This problem hinders the development of

agent interoperability. Systems tend to use their own knowledge

database. we cannot plug another agent into the

current existing MAS, unless we are using the same knowledge base.

Page 19: Load Balancing using Mobile Agent Approach

Mobile Agent (MA) (1)The goal of Mobile Agent

You delegate tasks to an agent. The agent will do the tasks for you.

Instead of passing message among agents, mobile agent can migrate across the network (hence mobile) representing users in various tasks (hence agents).

Page 20: Load Balancing using Mobile Agent Approach

Mobile Agent (MA) (2)Potential application domains of MA

Data-intensive application. Disconnected computing.

However, the sad fact is there is no application that would not exist

without mobile agents. Every mobile agent application will have its

client-server counterpart such as RPC or sockets.

Page 21: Load Balancing using Mobile Agent Approach

Mobile Agent (MA) (3)The difference between MA and MAS

They have similar properties. Mobile agent can migrate itself to other

hosts.

Page 22: Load Balancing using Mobile Agent Approach

Load Balancing (1) Imagine that you are inside a factory :

Our Goal : to minimize the total length of time needed to process a fixed set of tasks.

Machine B

Machine C

Machine A? ??

Page 23: Load Balancing using Mobile Agent Approach

Load Balancing (2)Our approach is a greedy approach.

Whenever a new job comes in the system, we search for the machine that has the minimum load.

We assign the new job to the minimum-load machine.

Page 24: Load Balancing using Mobile Agent Approach

Description of the System (1)Suppose we are given:

n identical processing units, namely Pi where 1 <= i <= n

A set of tasks: T = {T1, T2, …, Tm}

A partial-order < on T and a function where is mapping that maps T to real number >= 0

Page 25: Load Balancing using Mobile Agent Approach

Description of the System (2)Once a processor Pi begins a task Tj, It

works without interruption on Tj until completion

The time that is taken : (Tj).

If Ti < Tj, Tj cannot be started until Ti is completed.

Page 26: Load Balancing using Mobile Agent Approach

Description of the System (3)Pi executes the task Tj in the following way:

We are given a linear ordering

L is called a task list.

In any time t, a Pi completes a task, it immediately scans the list L.

L : (Tk1, …, Tkm)

Page 27: Load Balancing using Mobile Agent Approach

Description of the System (4)Pi scans from the beginning of L until it comes

to the first task Tj which has not yet begun to be executed.

If Ti < Tj and Ti has been finished, Pi begins to executes Tj.

Otherwise, Pi proceeds to the next task in L which has not begun executing.

Page 28: Load Balancing using Mobile Agent Approach

Description of the System (5) If Pi proceeds through the entire list L

without finding a task to execute, then Pi becomes idle.

Idle means Pi is executing an empty task.

Pi remains idle until some other Pj completes a task.

Page 29: Load Balancing using Mobile Agent Approach

Description of the System (6)At that time, Pi immediately scans the

list L as before for possible tasks to execute.

If Pi and Pj, i < j, simultaneously attempt to begin the same task Tk, the processor with the smaller index will execute Tk, i.e. Pi.

Page 30: Load Balancing using Mobile Agent Approach

Description of the System (7)The processors all start scanning L at

time t = 0 and proceed in the above-mentioned fashion until some time w.

Our aim is to minimize w.

Page 31: Load Balancing using Mobile Agent Approach

Description of the System (8)E.g. 1.

n = 3 L : (T3, T1, T2, T4, T6, T5, T7, T8) Partial relation :

T1/4 T2/3

T4/5

T6/2 T7/2

T3/1 T5/3

T8/3

Page 32: Load Balancing using Mobile Agent Approach

Description of the System (9)E.g 1 (continued)

P1

P2

P3

T1/4 T2/3T4/5T6/2 T7/2

T3/1 T5/3T8/3

4

5

2

L : (T3, T1, T2, T4, T6, T5, T7, T8)L : (T3, T1, T2, T4, T6, T5, T7, T8)L : (T3, T1, T2, T4, T6, T5, T7, T8)L : (T3, T1, T2, T4, T6, T5, T7, T8)L : (T3, T1, T2, T4, T6, T5, T7, T8)L : (T3, T1, T2, T4, T6, T5, T7, T8)L : (T3, T1, T2, T4, T6, T5, T7, T8)L : (T3, T1, T2, T4, T6, T5, T7, T8)L : (T3, T1, T2, T4, T6, T5, T7, T8)

2

T1

T4

T6 T7

3T2

T31

T83

T53

E12

E22

Page 33: Load Balancing using Mobile Agent Approach

Description of the System (13)E.g. 3

Page 34: Load Balancing using Mobile Agent Approach

Description of the System (14)From the above observations, we can

conclude that w is a function of :

Task list L Partial order < Time function Number of processors n

Page 35: Load Balancing using Mobile Agent Approach

Description of the System (14) It seems that we can improve w by:

Change the task list L Decrease the function Relax the partial-order < Change the number of processors from n

to n'

Page 36: Load Balancing using Mobile Agent Approach

Description of the System (15)However, there are counter-examples

show that is not always the case!!

The bound is:

Page 37: Load Balancing using Mobile Agent Approach

Description of the System (16)Back to our greedy approach

We know that no matter how bad our design is, there is still a bound that governs the maximum time needed.

It can be proved that the bound for such a system is:

Page 38: Load Balancing using Mobile Agent Approach

Load Balancing using Mobile Agent Approach (1)Currently, load balancing decision is

centralized.There is a switch which gathers load

information of all servers. Then, it decides which machine should be

chosen to assign an incoming task.The switch may collect loading status from all

machines periodically, say every 1 second.

Page 39: Load Balancing using Mobile Agent Approach

Load Balancing using Mobile Agent Approach (2)Our approach for load-balancing

decision is a decentralized one.The computations of load balancing

decision making are not performed on the switch, but on the back-end servers.

Page 40: Load Balancing using Mobile Agent Approach

Load Balancing using Mobile Agent Approach (3)When a customer arrives, it will

encapsulate the customer's request into an mobile agent

The agent will go to find a server that has the minimum load autonomously.

Page 41: Load Balancing using Mobile Agent Approach

Load Balancing using Mobile Agent Approach (4)Multiple-Hop Mobile Agent Approach

switch

server server server

Page 42: Load Balancing using Mobile Agent Approach

Load Balancing using Mobile Agent Approach (5)

Advantage We distribute the load of the switch to the

server, this can increase the efficiency of the switch in creating agents.

We can have a platform-independent load balancing scheme since the dispatched agent can run on the different machines given that a unique agent execution environment is provided.

Page 43: Load Balancing using Mobile Agent Approach

Load Balancing using Mobile Agent Approach (5)

Disadvantage our scheme will be a failure if the number of

servers is too large. As we have to travel all server once, the load

information will be out-of-date or incorrect at the time when decision is made.

If the number of servers is small and the agents are migrating fast enough, this will be a very efficient scheme.

Page 44: Load Balancing using Mobile Agent Approach

Load Balancing using Mobile Agent Approach (6)Multi-Multi-Hop Mobile Agent Approach

Since the efficiency of the multi-hop approach is restricted by the number of servers, we are now sending multiple agents in this new scheme.

After all the agents finished calculating the sub-minimal, they will gather together to calculate global minimum load.

Page 45: Load Balancing using Mobile Agent Approach

Load Balancing using Mobile Agent Approach (7)Advantage

By using mobile agent, we can calculate the load status with respect to the nature of the service.

For example, if the task is a memory intensive process, we have no reason to treat the CPU load as the load information.

Therefore, we can plug a suitable instruction to the mobile agent in order to calculate the load status.

Page 46: Load Balancing using Mobile Agent Approach

Load Balancing using Mobile Agent Approach (8)Disadvantage

The mobile agent approach introduces undesirable load to servers as the agents calculate the load information before the execution by incoming tasks.

Mobile agent is typically written by script language or Java. They are much slower than currently adopted approaches.

Page 47: Load Balancing using Mobile Agent Approach

Conclusion (1)Two kinds of agents are examined:

Multi-agent system and Mobile agent.Their advantages as well as

disadvantages are discussed.Load Balancing is an old research topic,

however, many domains are adopting this issues such as clusters of computers.

Page 48: Load Balancing using Mobile Agent Approach

Conclusion (2)The possibilities of combining mobile

agent and load balancing are illustrated.This shows that with the autonomous

characteristics of agents, we can improve the current load balancing decision schemes.

Page 49: Load Balancing using Mobile Agent Approach

Future WorksContinue to investigate more about

agent.Continue to think of the possibilities of

combining mobile agent and load balancing techniques.

Page 50: Load Balancing using Mobile Agent Approach

~~ END ~~