# Cost-Effective Location Management for Mobile Agents on the Internet

Authors: Chien-Sheng Chen; Jiing-Dong Hwang; Chyuan-Der Lu; Ting-Yuan Yeh
Journal: Journal of Sensors
 (2015)

---

## Abstract

Many mobile agent system-related services and applications require interacting with a mobile agent by passing messages. However, an agent’s mobility raises several challenges in delivering messages to a mobile agent accurately. Consisting of tracking and message delivery phases, most mobile agent location management schemes create or receive many update messages and interaction messages to ensure the effectiveness of the schemes. In addition to downgrading the overall performance of a mobile agent location management scheme, excessive transmission of messages increases the network load. The migration locality of a mobile agent and the interaction rate between mobile agents significantly affect the performance of a mobile agent location management scheme with respect to location management cost. This work presents a novel Dual Home based Scheme (DHS) that can lower the location management costs in terms of migration locality and interaction rate. While the DHS scheme uniquely adopts dual home location management architecture, a selective update strategy based on that architecture is also designed for cost-effective location management of mobile agents. Moreover, DHS is compared with available schemes based on formulations and simulation experiments from the perspective of location management costs. Simulation results demonstrate that the proposed DHS scheme performs satisfactorily in terms of migration locality and interaction rate.


---

## Body

## 1. Introduction

As a software program, a mobile agent [1] migrates dynamically between hosts on a network to complete assigned missions. Autonomy and mobility make a mobile agent flexible and one of the most promising paradigms for future distributed computing. Among the many applicable areas [2] of mobile agent technology are information retrieval [3], network management [4], telecommunication systems [5], and wireless sensor networks [6].Location management of a mobile agent is essential for a mobile agent system, in which many significant services are accomplished via mobile agent interactions that need precise location information. Notable examples include task communication [7], fault tolerance [8, 9], and control of a mobile agent [10, 11]. However, agent mobility raises several new challenges in designing an effective and efficient location management scheme. Accurately transmitting interaction messages to a mobile agent involves a location management scheme that generally functions in two phases, that is, location tracking and message delivery. Tracking phase entails monitoring location information of a mobile agent. Two methods are generally adopted, that is, update message and forwarding pointer. In the former, update message is sent for refreshing the location information of a mobile agent that is maintained by a responsible Location Management Server (LMS). In the latter, started from LMS, a forwarding pointer is left by a mobile agent on the current location as a reference to the next destination of a mobile agent. Next, during the message delivery phase, interaction messages are delivered accurately to a mobile agent along a channel that is formed from the stored location information.The popularity of mobile agent technology has led to numerous mobile agents to execute tasks on a network simultaneously, thus incurring considerable location management costs. Location management costs of a mobile agent consist of the transmission costs of update messages and interaction messages. In addition to degrading the overall performance of a mobile agent location management scheme, excessive transmission of messages increases the network load.Information retrieval is one of the important applications in mobile agent technology. Among the many Internet applications in which a mobile agent has been applied to retrieve information are web searching [12, 13], electronic commerce [14, 15], network management [4], and peer-to-peer systems [16]. Recently there has been a growing interest in the use of mobile agents to facilitate efficient data fusion and dissemination in wireless sensor network environment [6, 17]. Using mobile agents in wireless sensor networks has many advantages over the client/server paradigm in terms of energy consumptions, networks bandwidth, and storage space. One of the typical applications of wireless sensor networks is a monitoring application [18].Available mobile agent location management schemes can be classified into hierarchy-based, region-based, and home-based location management architectures. Hierarchy-based and region-based architectures can localize location management tasks and are highly promising for developing an economically feasible cost mobile agent location management scheme. However, both architectures have several limitations. For instance, globally deployed cooperative LMSs for providing location services are difficult to achieve, while installing, managing, and maintaining these designated and stationary LMSs incur extra costs. Moreover, previous studies that adopt both location management architectures are concerned with reliability and scalability, yet they do not attempt to reduce location management costs [19–21].Although a home-based location management scheme is simple and easily implemented, reducing location management costs is problematic because a contradiction arises between the transmission cost of update messages and interaction messages. Specifically, increasing the frequency of updates of a mobile agent decreases the transmission cost of interaction messages, while the overall transmission cost could be increased due to the increasing number of update messages. Current mobile agent location management schemes based on this architecture adopt complex update strategies for minimizing location management costs.To maintain low location management costs in terms of migration locality and interaction rate, this work presents a novel Dual Home based Scheme (DHS) by incorporating the advantages of the above three location management architectures. The proposed DHS scheme uniquely adopts a dual home location management architecture, as well as a selective update strategy based on the architecture to ensure cost-effective mobile agent location management. Additionally, the proposed DHS scheme is compared with available schemes based on formulations and simulation experiments from the perspective of location management costs. Simulation results demonstrate that the proposed DHS scheme performs satisfactorily in terms of migration locality and interaction rate.The rest of this paper is organized as follows. Section2 discusses the background and motivation in mobile agent location management. Fundamentals of location management are introduced in Section 3. Section 4 describes the design and operation of the proposed DHS scheme. The derived formulae of location management costs in each compared scheme are presented in Section 5. Section 6 displays the simulation results and the evaluation of extra costs. Finally, in Section 7, the conclusions of this study are summarized.


## 2. Background and Performance Issues

### 2.1. Channel and Region

The channel of a mobile agent MA is a path that can locate MA. It is constituted by location information that is left by MA on hosts that provide location services. The location information is a pair in the form ofAgentID,NextAddress and constitutes a link to the current location of MA.A region is a group of agent platforms that are in the same administration scope [19, 20]. In this paper, the region specifically refers to agent platforms that are close in network distance, for example, in the same router scope.


### 2.2. Related Works

Hierarchy-based location management architecture generally divides hosts in a mobile agent system into groups based on geographic locations. In each group, one or more LMSs are deployed to administrate the status of each mobile agent in the same group. In such an architecture, achannel develops from the root LMS to a leaf LMS. A hierarchy-based architecture is advantageous owing to its ability to manage a mobile agent’s position with locality, significantly reducing location management costs. Schemes such as the domain gateway server scheme [22], hierarchy shadows scheme [10], and hierarchical Agent Tracer scheme [11] adopt this architecture. Additionally, the mobile agent location management scheme in global networks, as developed by Patel et al. [23], and the distributed location databases, as developed by Pitoura and Fudos [24], are hierarchy-based location management architectures.A LMS in a hierarchy-based architecture generally refers to a designated, independent, and stationary host that induces inestimable costs, including the installation, management, and maintenance of LMSs, as well as selection of the best position for LMS. Budhkar et al. [25] proposed a locator mechanism based on hierarchy architecture for dealing with mobile agent security issues. Aggarwal and Pathak [26] employ routers as location management servers on the Internet. Wang et al. [27] developed a hierarchical dynamic monitoring scheme for mobile agent location management, which uses a mobile monitoring agent created dynamically to replace a stationary location management server if necessary. Similarly, Kastidou et al. [28] use a stationary or mobile agent called IAgent to manage the location of a mobile agent. A mobile agent is assigned an IAgent based on a system-wide hash function upon creation. Although additional costs produced by independent LMSs can be subsequently averted, supervising the mobility of a mobile monitoring agent or an IAgent is problematic.A region-based location management architecture originates from the feature of transmission latencies in local area network (LAN), which is significantly lower than that in wide area network (WAN). In such architecture, a network contains an independent and stationary host, which administers active mobile agents in the region. Migration of a mobile agent is either intraregion or interregion. The former is attributed to the fact that the source and the destination hosts of a mobile agent’s migration are located in the same region, while the latter is attributed to the fact that the source and the destination hosts are located in different regions. Schemes such as Search-by-Path-Chase (SPC) [19], Reliable Asynchronous Message Delivery (RAMD) [20], Broadcasting with Search-by-Path-Chase (BSPC) [21], and research in [29] adopt region-based location management architectures. In SPC, the LMS in a region is called Agent Name Server (ANS) and it maintains a Region Agent Register (RAR) for storing location information with respect to all mobile agents that have been created in the region or have transited through it. On each host, a Site Agent Register (SAR) keeps track of location information about mobile agents that have either passed through or resided on the host. Location tracking in SPC is based on migration of the mobile agent. In intraregion migration, a mobile agent updates the location information to the previous host and the current ANS as it arrives at the destination host. In interregion migration, a mobile agent updates the location information to the previous host and ANS, the home ANS, and the current ANS when it arrives at the destination host. Via the above tracking mechanism, hosts on a mobile agent’schannel are the home ANS, the current ANS, and the current host. An interaction message is not forwarded along achannel in SPC. A sender agent queries the hosts on achannel in sequence to locate the receiver agent and, then, it delivers the interaction message directly to the current host of a receiver agent.In RAMD, the LMS is called region server (RS) in a region. Location tracking in RAMD is also based on the migration behavior of a mobile agent. In intraregion migration, a mobile agent only updates location information to the current RS as it arrives at the destination host. In interregion migration, a mobile agent updates to the home host, home RS, and current RS when it arrives at the destination host. Hosts on a mobile agent’schannel are the home host, current RS, and current host. An interaction message is forwarded to a receiver agent by the hosts on achannel sequentially.BSPC scheme is a variation of SPC scheme. A LMS in a region is called a region agent tracker (RAT) in BSPC. When a RAT perceives that a queried receiver agent is located in its region, it determines the actual location of the receiver agent by broadcasting. Only the host where the receiver agent resides will reply to the RAT as receiving the broadcast. Importantly, BSPC improves scalability and reliability, as well as reducing migration and interaction overhead.In the home-based location management approach, the home host that creates mobile agents serves as a LMS for the mobile agents. The location management architecture is simple and easily implemented. Models such as home-proxy scheme (HP) and forwarding-proxy scheme (FP) belonging to this type significantly differ in location update strategies. In HP, a mobile agent arriving at a new host reports to its LMS the new location by using an update message. However, constantly updating location information incurs a large overhead during the tracking phase. In FP, a mobile agent that is ready to depart leaves a forwarding pointer at the current host to indicate its next stop; hence, FP produces no messages during the tracking phase. Nevertheless, with an increasing frequency of the migration of a mobile agent, achannel gets longer and longer. Figures 1(a) and 1(b) display the implement of the HP and FP schemes. Mobile agent platforms such as Grasshopper [30], Aglet [31], and Springs [32, 33] utilize the HP scheme, and others such as Mole [34] and Voyager [35] adopt FP scheme.Figure 1
(a) HP scheme, (b) FP scheme.
(a)
(b)Current researches tend to use update message and forwarding pointer alternately during the tracking phase to reduce location management costs, by which a mobile agent updates the location information to LMS periodically. Another movement based scheme, the dU scheme, is described elsewhere [36]. In the dU scheme, a mobile agent updates its location information after d migrations between hosts. Songsiri [37] devised a time-based scheme, in which a mobile agent updates its location information to its LMS after time τ has elapsed. Hans and Kaur [38] propose an approach for tracking mobile agents by using forward and backward pointers. Furthermore, Yeh and Wang [39] developed a ratio-based scheme, in which a mobile agent updates its location information to its LMS as the ratio between the costs of transmitting update message and interactive message reaches a threshold. For the above schemes, location tracking between two updates depends on forwarding pointers.Flocchini and Xie [40] devised a unique mobile agent location management scheme based on a P2P-like location management architecture. In this scheme, the hosts and the mobile agents in the mobile agent system are viewed separately as peers and objects in the well-known peer-to-peer system chord. That study attempted to enhance the scalability of system and to increase the efficiency of retrieving mobile agents.Several studies have evaluated mobile agent location management schemes. Deugo [41] evaluated five mobile agent messaging models: Home-Proxy, Follower-Proxy, Email, Blackboard, and Broadcast. That study focused on assisting a developer of a mobile agent location management scheme to select the most appropriate one from numerous messaging models. Alouf et al. [42] developed simple Markovian analytical models to assess how forwarding pointers and centralized server approaches perform in locating mobile objects. Ben-Ami and Shehory [43] developed a large scale MAS simulation test-bed and performed a series of experiments to evaluate and compare the distributed and centralized mobile agent location management schemes. They all evaluated conventionally adopted mobile agent location management schemes in terms of various factors and made several constructive suggestions.


### 2.3. Performance Issues

In information retrieval applications, a mobile agent visits as many hosts as possible to acquire large amounts of required information. However, with the rapid growth of the Internet, an increasing amount of valuable information can be retrieved by the mobile agent in a region, subsequently causing the migration locality to change dynamically with the migration of the mobile agent. Moreover, intraregion and interregion migration of a mobile agent in current region-based location management schemes significantly differ in tracking cost owing to the design of update strategies. Therefore, this work compares the location management costs of each location management scheme by considering the migration locality of a mobile agent. Migration locality (ML) of a mobile agent denotes the probability that a migration of the mobile agent is within the same region, and it is defined as follows:(1)ML=Nrn×100%,where Nr denotes the number that the mobile agent migrates within the same region and n denotes the number of hosts in the mobile agent’s itinerary.Additionally, an information retrieval application normally dispatches multiple mobile agents to search for information in parallel for efficiency, in which mobile agents coordinate and negotiate with each other to refine the searched results by exchanging messages. This interaction implies that the interaction rate between mobile agents varies with the migration of mobile agents. As the interaction rate is low, most of the location management cost is the tracking cost because of the low number of interaction messages. Under this circumstance, location management schemes that produce a higher cost during the tracking phase introduce additional performance overhead and network load. The extent to which message delivery cost influences location management cost becomes increasingly significant with an increasing interaction rate. Interaction messages are sent to a mobile agent along achannel. Thus, the location management scheme that adequately controls the length of achannel can produce lower location management costs as the interaction rate is high. Obviously, the interaction rate between mobile agents significantly affects the location management costs of a mobile agent location management scheme. Interaction rate (IR) denotes the message exchange frequency between mobile agents and is defined as follows:(2)IR=NIn×100%,where NI denotes the total number of interaction messages received by a mobile agent during an itinerary.


## 2.1. Channel and Region

The channel of a mobile agent MA is a path that can locate MA. It is constituted by location information that is left by MA on hosts that provide location services. The location information is a pair in the form ofAgentID,NextAddress and constitutes a link to the current location of MA.A region is a group of agent platforms that are in the same administration scope [19, 20]. In this paper, the region specifically refers to agent platforms that are close in network distance, for example, in the same router scope.


## 2.2. Related Works

Hierarchy-based location management architecture generally divides hosts in a mobile agent system into groups based on geographic locations. In each group, one or more LMSs are deployed to administrate the status of each mobile agent in the same group. In such an architecture, achannel develops from the root LMS to a leaf LMS. A hierarchy-based architecture is advantageous owing to its ability to manage a mobile agent’s position with locality, significantly reducing location management costs. Schemes such as the domain gateway server scheme [22], hierarchy shadows scheme [10], and hierarchical Agent Tracer scheme [11] adopt this architecture. Additionally, the mobile agent location management scheme in global networks, as developed by Patel et al. [23], and the distributed location databases, as developed by Pitoura and Fudos [24], are hierarchy-based location management architectures.A LMS in a hierarchy-based architecture generally refers to a designated, independent, and stationary host that induces inestimable costs, including the installation, management, and maintenance of LMSs, as well as selection of the best position for LMS. Budhkar et al. [25] proposed a locator mechanism based on hierarchy architecture for dealing with mobile agent security issues. Aggarwal and Pathak [26] employ routers as location management servers on the Internet. Wang et al. [27] developed a hierarchical dynamic monitoring scheme for mobile agent location management, which uses a mobile monitoring agent created dynamically to replace a stationary location management server if necessary. Similarly, Kastidou et al. [28] use a stationary or mobile agent called IAgent to manage the location of a mobile agent. A mobile agent is assigned an IAgent based on a system-wide hash function upon creation. Although additional costs produced by independent LMSs can be subsequently averted, supervising the mobility of a mobile monitoring agent or an IAgent is problematic.A region-based location management architecture originates from the feature of transmission latencies in local area network (LAN), which is significantly lower than that in wide area network (WAN). In such architecture, a network contains an independent and stationary host, which administers active mobile agents in the region. Migration of a mobile agent is either intraregion or interregion. The former is attributed to the fact that the source and the destination hosts of a mobile agent’s migration are located in the same region, while the latter is attributed to the fact that the source and the destination hosts are located in different regions. Schemes such as Search-by-Path-Chase (SPC) [19], Reliable Asynchronous Message Delivery (RAMD) [20], Broadcasting with Search-by-Path-Chase (BSPC) [21], and research in [29] adopt region-based location management architectures. In SPC, the LMS in a region is called Agent Name Server (ANS) and it maintains a Region Agent Register (RAR) for storing location information with respect to all mobile agents that have been created in the region or have transited through it. On each host, a Site Agent Register (SAR) keeps track of location information about mobile agents that have either passed through or resided on the host. Location tracking in SPC is based on migration of the mobile agent. In intraregion migration, a mobile agent updates the location information to the previous host and the current ANS as it arrives at the destination host. In interregion migration, a mobile agent updates the location information to the previous host and ANS, the home ANS, and the current ANS when it arrives at the destination host. Via the above tracking mechanism, hosts on a mobile agent’schannel are the home ANS, the current ANS, and the current host. An interaction message is not forwarded along achannel in SPC. A sender agent queries the hosts on achannel in sequence to locate the receiver agent and, then, it delivers the interaction message directly to the current host of a receiver agent.In RAMD, the LMS is called region server (RS) in a region. Location tracking in RAMD is also based on the migration behavior of a mobile agent. In intraregion migration, a mobile agent only updates location information to the current RS as it arrives at the destination host. In interregion migration, a mobile agent updates to the home host, home RS, and current RS when it arrives at the destination host. Hosts on a mobile agent’schannel are the home host, current RS, and current host. An interaction message is forwarded to a receiver agent by the hosts on achannel sequentially.BSPC scheme is a variation of SPC scheme. A LMS in a region is called a region agent tracker (RAT) in BSPC. When a RAT perceives that a queried receiver agent is located in its region, it determines the actual location of the receiver agent by broadcasting. Only the host where the receiver agent resides will reply to the RAT as receiving the broadcast. Importantly, BSPC improves scalability and reliability, as well as reducing migration and interaction overhead.In the home-based location management approach, the home host that creates mobile agents serves as a LMS for the mobile agents. The location management architecture is simple and easily implemented. Models such as home-proxy scheme (HP) and forwarding-proxy scheme (FP) belonging to this type significantly differ in location update strategies. In HP, a mobile agent arriving at a new host reports to its LMS the new location by using an update message. However, constantly updating location information incurs a large overhead during the tracking phase. In FP, a mobile agent that is ready to depart leaves a forwarding pointer at the current host to indicate its next stop; hence, FP produces no messages during the tracking phase. Nevertheless, with an increasing frequency of the migration of a mobile agent, achannel gets longer and longer. Figures 1(a) and 1(b) display the implement of the HP and FP schemes. Mobile agent platforms such as Grasshopper [30], Aglet [31], and Springs [32, 33] utilize the HP scheme, and others such as Mole [34] and Voyager [35] adopt FP scheme.Figure 1
(a) HP scheme, (b) FP scheme.
(a)
(b)Current researches tend to use update message and forwarding pointer alternately during the tracking phase to reduce location management costs, by which a mobile agent updates the location information to LMS periodically. Another movement based scheme, the dU scheme, is described elsewhere [36]. In the dU scheme, a mobile agent updates its location information after d migrations between hosts. Songsiri [37] devised a time-based scheme, in which a mobile agent updates its location information to its LMS after time τ has elapsed. Hans and Kaur [38] propose an approach for tracking mobile agents by using forward and backward pointers. Furthermore, Yeh and Wang [39] developed a ratio-based scheme, in which a mobile agent updates its location information to its LMS as the ratio between the costs of transmitting update message and interactive message reaches a threshold. For the above schemes, location tracking between two updates depends on forwarding pointers.Flocchini and Xie [40] devised a unique mobile agent location management scheme based on a P2P-like location management architecture. In this scheme, the hosts and the mobile agents in the mobile agent system are viewed separately as peers and objects in the well-known peer-to-peer system chord. That study attempted to enhance the scalability of system and to increase the efficiency of retrieving mobile agents.Several studies have evaluated mobile agent location management schemes. Deugo [41] evaluated five mobile agent messaging models: Home-Proxy, Follower-Proxy, Email, Blackboard, and Broadcast. That study focused on assisting a developer of a mobile agent location management scheme to select the most appropriate one from numerous messaging models. Alouf et al. [42] developed simple Markovian analytical models to assess how forwarding pointers and centralized server approaches perform in locating mobile objects. Ben-Ami and Shehory [43] developed a large scale MAS simulation test-bed and performed a series of experiments to evaluate and compare the distributed and centralized mobile agent location management schemes. They all evaluated conventionally adopted mobile agent location management schemes in terms of various factors and made several constructive suggestions.


## 2.3. Performance Issues

In information retrieval applications, a mobile agent visits as many hosts as possible to acquire large amounts of required information. However, with the rapid growth of the Internet, an increasing amount of valuable information can be retrieved by the mobile agent in a region, subsequently causing the migration locality to change dynamically with the migration of the mobile agent. Moreover, intraregion and interregion migration of a mobile agent in current region-based location management schemes significantly differ in tracking cost owing to the design of update strategies. Therefore, this work compares the location management costs of each location management scheme by considering the migration locality of a mobile agent. Migration locality (ML) of a mobile agent denotes the probability that a migration of the mobile agent is within the same region, and it is defined as follows:(1)ML=Nrn×100%,where Nr denotes the number that the mobile agent migrates within the same region and n denotes the number of hosts in the mobile agent’s itinerary.Additionally, an information retrieval application normally dispatches multiple mobile agents to search for information in parallel for efficiency, in which mobile agents coordinate and negotiate with each other to refine the searched results by exchanging messages. This interaction implies that the interaction rate between mobile agents varies with the migration of mobile agents. As the interaction rate is low, most of the location management cost is the tracking cost because of the low number of interaction messages. Under this circumstance, location management schemes that produce a higher cost during the tracking phase introduce additional performance overhead and network load. The extent to which message delivery cost influences location management cost becomes increasingly significant with an increasing interaction rate. Interaction messages are sent to a mobile agent along achannel. Thus, the location management scheme that adequately controls the length of achannel can produce lower location management costs as the interaction rate is high. Obviously, the interaction rate between mobile agents significantly affects the location management costs of a mobile agent location management scheme. Interaction rate (IR) denotes the message exchange frequency between mobile agents and is defined as follows:(2)IR=NIn×100%,where NI denotes the total number of interaction messages received by a mobile agent during an itinerary.


## 3. Naming Scheme and Look-Up Service

Since an interaction message is forwarded along achannel, a sender agent in a mobile agent system, when attempting to interact with a receiver agent, must locate the home host or the starting LMS on the receiver agent’schannel before sending an interaction enquiry message to the LMS. This is the main task of the naming service in a mobile agent system. Several mechanisms have been developed to provide such naming services without incurring an excessive performance overhead [37, 44, 45].A naming service includes naming and lookup. Naming refers to assigning a unique name to a newly created agent, while look-up refers to querying the location of a receiver agent’s LMS by submitting a look-up request. Two naming services are available in a mobile agent system. The first service is one in which the location information of the home host or the starting LMS on a channel is embedded into a mobile agent’s name. A sender agent attempting to interact with a receiver agent resolves the receiver agent’s name first. The second service constructs a global look-up service similar to the domain name system (DNS) protocol on the Internet. Location information of the home host and the starting LMS on a channel is obtained by querying one or more look-up servers. Although easily implemented, the first naming service cannot ensure that the location can transparently deliver messages to a mobile agent, thus making it impractical for a mobile agent location management scheme. Moreover, although message delivery in the second naming service is transparent to the mobile agent, transmitting query messages to look-up servers increases location management costs, ultimately increasing the complexity of maintaining the look-up servers.


## 4. System Architecture and Operations

This section introduces the location management architecture of DHS scheme, as well as its tracking phase and message delivery phase. Moreover, a simple method which is called On-Demand Probe and Priority Cache is devised for providing the selective update strategy in DHS the necessary transmission cost information between a pair of hosts on a network when making an update decision.


### 4.1. Tracking Phase

The proposed DHS scheme adopts a dual home location management architecture, in which a mobile agent has two homes, that is, primary and temporary. The primary home is a host that creates the mobile agent, while the temporary home is the host where the mobile agent updates location information to the primary home. Restated, the latter is the host next to the primary home on the mobile agent’schannel. The mobile agent arriving at a new host updates its location information to one of both homes each time by using the selective update strategy.Figure2 illustrates the operational details of the proposed DHS scheme. In this figure, a mobile agent MA has just arrived at a new host Hi+k. Assume that the transmission costs betweenPrimary Home, Hi, and Hi+k are a, b, and c, respectively. Before executing the assigned tasks on Hi+k, MA must update the location information toPrimary Home or Hi by using the following selective update strategy.(1)
Ifc>a and c>b, MA updates the location information to Hi, as shown in Figure 2(a).(2)
Elsec≤a or c≤b; MA updates the location information toPrimary Home, and then Hi+k becomes the new temporary home, as shown in Figure 2(b).Figure 2
An example to illustrate tracking operation of DHS. (a) Ifc>b and c>a. (b) If c≤a or c≤b.
(a)
(b)The philosophy behind the proposed DHS scheme is to reduce the total location management costs by preventing update and interaction messages from being transported on network links with higher transmission costs. To achieve this every host has to maintain a location table for storing the location information of mobile agents in the proposed DHS scheme. Location information stored in the location table of each host forms a channel that can forward an interaction message to a mobile agent. Eitherprimary home-to-temporary home (current location) orprimary home-to-temporary home-to-current location is the channel of a mobile agent in DHS. Figure 3 displays achannel that forms from the update operations in Figure 2.Figure 3
The formed channel after updates to (a) temporary home, (b) primary home.
(a)
(b)A location table consists of two entries, that is, AgentID and NextAddress, in each record. AgentID is the unique identifier of a mobile agent, while NextAddress is the next destination of a mobile agent. As a host receives an update message, the value in the NextAddress field is updated to the address in the update message.When making update decision, MA requests the transmission costs fromHi+k to the primary home and the temporary home from Hi+k. The transmission cost between the primary home and the temporary home is carried by MA. In the proposed DHS scheme, when a mobile agent updates to the primary home, the current location of the mobile agent becomes the temporary home. Simultaneously, the mobile agent stores the transmission costs between the primary home and the temporary home into a distance field.


### 4.2. Message Delivery Phase

Interaction messages are handled in the message delivery phase, which are sent among mobile agents alongchannels. To reach a mobile agent accurately, an interaction message has a field containing the identification of the receiver agent to enable the hosts on achannel to forward it in the correct direction. On receiving an interaction message, a host on achannel extracts the identification of the receiver agent from the field, queries the location table for the next destination of thechannel, and, then, sends the interaction message there. Conversely, if the receiver agent has no records in the location table, the host returns a failure message to the LMS. Accordingly, the hosts on thechannel repeat the forwarding process until the interaction message reaches the current location of the receiver agent.Fields of an interaction message vary in different applications that require mobile agents to communicate, coordinate, or negotiate with each other for completing different tasks. Under such circumstances, interaction messages must include the name of the sender agent for the receiver agent to reply to the message. Obviously, a reply message sent by a receiver agent is another interaction message and, therefore, is delivered in the same way. A sender agent that remains stationary and requests to initiate a session that interacts directly can also add the address of the host, where it currently stays, in the interaction message for a direct delivery to the host.Reliable message delivery is vital for mobile agent location management. Communication failure and message chasing are of major concerns in this issue. The message chasing problem does not last long in the proposed DHS scheme because there are at most three hosts on a mobile agent’s channel, that is, the primary home, the temporary home, and the current host. As an interaction message reaches the mobile agent’s current location and the mobile agent has left, communication failure occurs. The mailbox approach [7, 46, 47] is often adopted to resolve a communication failure. For delivering the interaction message reliably, the proposed DHS scheme assigns each mobile agent a mailbox at creation time. As a mobile agent’s home host receives an interaction message for it, the following procedure is conducted:(1)
the received message is assigned a serial number based on the incoming sequence;(2)
a copy of the message is stored in the mobile agent’s mailbox;(3)
the message is forwarded to the next host on the mobile agent’s channel.A mobile agent always includes in the update message the serial number of the message that it last received and, then, sends it to the home host. The home host that receives the update message not only refreshes the location information of the mobile agent in the location table, but also checks the mobile agent’s mailbox to see if the mobile agent has missed any messages. The home host then pushes the lost messages to the mobile agent directly.


### 4.3. Further Reduction of Tracking Cost

The tracking cost in DHS can be reduced by using forwarding pointers at the right time. While a mobile agent MA updates the location information to the primary home at hostHi, Hi becomes MA’s new temporary home. After completing its task on Hi, MA leaves a forwarding pointer in the location table of Hi; it then migrates to the next destination host Hi+1. Upon arriving at Hi+1, MA initiates the computation of update decision. If the computation result indicates MA to update to Hi, MA can commence with its task on Hi+1 without the need to send an update message to refresh the location information. This is because of the forwarding pointer that it left on Hi points towards Hi+1. Briefly, if the mobile agent’s current location is the temporary home, it leaves a forwarding pointer to indicate its next stop when ready to depart. If the mobile agent’s current location is the host that is next to the temporary home in itinerary and the computational result of update decision is positive, then the update procedure can be omitted. Simulation results in this work indicate that doing so can reduce 16–24% of the number of updates. The reduced number of updates is denoted as ΔC in the following.


### 4.4. Transmission Costs

Hop counts and Round Trip Time (RTT) are two commonly used network latency metrics for counting message transmission costs. The former represents the network resources a message consumes, while the latter reflects the efficiency of transmitting a message. Evaluating the cost for transmitting messages among hosts on a network is network distance measurement [48, 49] and is an essential work in data dissemination applications, such as on-line software version update and peer-to-peer file sharing. Discovering the closest server efficiently that stored the replicated files can significantly reduce network latency, bandwidth, and load, for example.Measuring network distance in real-time helps DHS make more precise decisions, but it is too expensive for a mobile agent system that provides communication services for mobile agents because most network distance measurement methods use exhaustive explorations between a host and its peer hosts. Result of a simulation experiment in this paper shows that probing network distances constitute the major cost for making update decision. DHS requires each host in a system knowing the costs of transmission message between itself and other hosts for visiting mobile agents to decide whether to update. To reduce such probing cost, distance information, once measured, will be cached in amembership table maintained by every host in the system. After a period of time, a host’smembership table contains the distance information between itself and other hosts, and a mobile agent, upon making update decision, can just query themembership table with much more efficiency.A host’smembership table consists of at least two entries:Host_Address andTransmission_Cost in each record. The former keeps the address of another host, and the latter stores the cost of transmitting a message to that host. Other entries, such asFrequency, can be included for managing amembership table. Hosts providing services may join the system from time to time, resulting in an oversizedtable, which must shrink for querying efficiency. Reducing the size of amembership table by deleting records arbitrarily, however, increases the chance of physical distance measurements. AFrequency entry thus records how many times a record has been queried and indicates the priorities for deletion. Deleting an entry with low priority, that is, low query frequency, reduces the chances of distance remeasurement. DHS uses such an On-Demand Probe and Priority Cache.


### 4.5. Measurement of Transmission Costs

Currently, Ping and Traceroute are two network tools that can be used to measure network distance between two hosts. However, both of them cannot satisfy the requirements of DHS because they are not originally for this purpose. The DHS needs a quick response and low overhead tool to measure both the RTT and hop counts between two hosts. This paper implemented an extended Ping tool that uses network practice for this goal. Currently, most network hosts use platforms such as Linux, Unix, FreeBSD, or Windows. The default time-to-live (TTL) value in Linux-like system, for example, Linux, Unix, or FreeBSD, is set to 64 or 255, while in Windows system, for example, Windows 2000, XP, Vista, Server 2008, or 7, it is set to 128. The disparity between these TTL values is at least 64. Although the scale of the Internet is huge, the distance between a pair of hosts should not exceed 64 hops. Therefore, the hop counts between a pair of hosts are obtained by using the three default TTL values to subtract the remainder of TTL value after pinging the destination host. And finally choose the calculation result that is between 0 and 64. For example, the remainder of TTL value is 246 after pinging an IP address. Using 255, 128, and 64 to subtract 246 separately equals 9, −118, and −182. The distance between both hosts is 9 hops. The extended Ping tool has been verified by Traceroute, and the results are all correct in the randomly selected IP address.


## 4.1. Tracking Phase

The proposed DHS scheme adopts a dual home location management architecture, in which a mobile agent has two homes, that is, primary and temporary. The primary home is a host that creates the mobile agent, while the temporary home is the host where the mobile agent updates location information to the primary home. Restated, the latter is the host next to the primary home on the mobile agent’schannel. The mobile agent arriving at a new host updates its location information to one of both homes each time by using the selective update strategy.Figure2 illustrates the operational details of the proposed DHS scheme. In this figure, a mobile agent MA has just arrived at a new host Hi+k. Assume that the transmission costs betweenPrimary Home, Hi, and Hi+k are a, b, and c, respectively. Before executing the assigned tasks on Hi+k, MA must update the location information toPrimary Home or Hi by using the following selective update strategy.(1)
Ifc>a and c>b, MA updates the location information to Hi, as shown in Figure 2(a).(2)
Elsec≤a or c≤b; MA updates the location information toPrimary Home, and then Hi+k becomes the new temporary home, as shown in Figure 2(b).Figure 2
An example to illustrate tracking operation of DHS. (a) Ifc>b and c>a. (b) If c≤a or c≤b.
(a)
(b)The philosophy behind the proposed DHS scheme is to reduce the total location management costs by preventing update and interaction messages from being transported on network links with higher transmission costs. To achieve this every host has to maintain a location table for storing the location information of mobile agents in the proposed DHS scheme. Location information stored in the location table of each host forms a channel that can forward an interaction message to a mobile agent. Eitherprimary home-to-temporary home (current location) orprimary home-to-temporary home-to-current location is the channel of a mobile agent in DHS. Figure 3 displays achannel that forms from the update operations in Figure 2.Figure 3
The formed channel after updates to (a) temporary home, (b) primary home.
(a)
(b)A location table consists of two entries, that is, AgentID and NextAddress, in each record. AgentID is the unique identifier of a mobile agent, while NextAddress is the next destination of a mobile agent. As a host receives an update message, the value in the NextAddress field is updated to the address in the update message.When making update decision, MA requests the transmission costs fromHi+k to the primary home and the temporary home from Hi+k. The transmission cost between the primary home and the temporary home is carried by MA. In the proposed DHS scheme, when a mobile agent updates to the primary home, the current location of the mobile agent becomes the temporary home. Simultaneously, the mobile agent stores the transmission costs between the primary home and the temporary home into a distance field.


## 4.2. Message Delivery Phase

Interaction messages are handled in the message delivery phase, which are sent among mobile agents alongchannels. To reach a mobile agent accurately, an interaction message has a field containing the identification of the receiver agent to enable the hosts on achannel to forward it in the correct direction. On receiving an interaction message, a host on achannel extracts the identification of the receiver agent from the field, queries the location table for the next destination of thechannel, and, then, sends the interaction message there. Conversely, if the receiver agent has no records in the location table, the host returns a failure message to the LMS. Accordingly, the hosts on thechannel repeat the forwarding process until the interaction message reaches the current location of the receiver agent.Fields of an interaction message vary in different applications that require mobile agents to communicate, coordinate, or negotiate with each other for completing different tasks. Under such circumstances, interaction messages must include the name of the sender agent for the receiver agent to reply to the message. Obviously, a reply message sent by a receiver agent is another interaction message and, therefore, is delivered in the same way. A sender agent that remains stationary and requests to initiate a session that interacts directly can also add the address of the host, where it currently stays, in the interaction message for a direct delivery to the host.Reliable message delivery is vital for mobile agent location management. Communication failure and message chasing are of major concerns in this issue. The message chasing problem does not last long in the proposed DHS scheme because there are at most three hosts on a mobile agent’s channel, that is, the primary home, the temporary home, and the current host. As an interaction message reaches the mobile agent’s current location and the mobile agent has left, communication failure occurs. The mailbox approach [7, 46, 47] is often adopted to resolve a communication failure. For delivering the interaction message reliably, the proposed DHS scheme assigns each mobile agent a mailbox at creation time. As a mobile agent’s home host receives an interaction message for it, the following procedure is conducted:(1)
the received message is assigned a serial number based on the incoming sequence;(2)
a copy of the message is stored in the mobile agent’s mailbox;(3)
the message is forwarded to the next host on the mobile agent’s channel.A mobile agent always includes in the update message the serial number of the message that it last received and, then, sends it to the home host. The home host that receives the update message not only refreshes the location information of the mobile agent in the location table, but also checks the mobile agent’s mailbox to see if the mobile agent has missed any messages. The home host then pushes the lost messages to the mobile agent directly.


## 4.3. Further Reduction of Tracking Cost

The tracking cost in DHS can be reduced by using forwarding pointers at the right time. While a mobile agent MA updates the location information to the primary home at hostHi, Hi becomes MA’s new temporary home. After completing its task on Hi, MA leaves a forwarding pointer in the location table of Hi; it then migrates to the next destination host Hi+1. Upon arriving at Hi+1, MA initiates the computation of update decision. If the computation result indicates MA to update to Hi, MA can commence with its task on Hi+1 without the need to send an update message to refresh the location information. This is because of the forwarding pointer that it left on Hi points towards Hi+1. Briefly, if the mobile agent’s current location is the temporary home, it leaves a forwarding pointer to indicate its next stop when ready to depart. If the mobile agent’s current location is the host that is next to the temporary home in itinerary and the computational result of update decision is positive, then the update procedure can be omitted. Simulation results in this work indicate that doing so can reduce 16–24% of the number of updates. The reduced number of updates is denoted as ΔC in the following.


## 4.4. Transmission Costs

Hop counts and Round Trip Time (RTT) are two commonly used network latency metrics for counting message transmission costs. The former represents the network resources a message consumes, while the latter reflects the efficiency of transmitting a message. Evaluating the cost for transmitting messages among hosts on a network is network distance measurement [48, 49] and is an essential work in data dissemination applications, such as on-line software version update and peer-to-peer file sharing. Discovering the closest server efficiently that stored the replicated files can significantly reduce network latency, bandwidth, and load, for example.Measuring network distance in real-time helps DHS make more precise decisions, but it is too expensive for a mobile agent system that provides communication services for mobile agents because most network distance measurement methods use exhaustive explorations between a host and its peer hosts. Result of a simulation experiment in this paper shows that probing network distances constitute the major cost for making update decision. DHS requires each host in a system knowing the costs of transmission message between itself and other hosts for visiting mobile agents to decide whether to update. To reduce such probing cost, distance information, once measured, will be cached in amembership table maintained by every host in the system. After a period of time, a host’smembership table contains the distance information between itself and other hosts, and a mobile agent, upon making update decision, can just query themembership table with much more efficiency.A host’smembership table consists of at least two entries:Host_Address andTransmission_Cost in each record. The former keeps the address of another host, and the latter stores the cost of transmitting a message to that host. Other entries, such asFrequency, can be included for managing amembership table. Hosts providing services may join the system from time to time, resulting in an oversizedtable, which must shrink for querying efficiency. Reducing the size of amembership table by deleting records arbitrarily, however, increases the chance of physical distance measurements. AFrequency entry thus records how many times a record has been queried and indicates the priorities for deletion. Deleting an entry with low priority, that is, low query frequency, reduces the chances of distance remeasurement. DHS uses such an On-Demand Probe and Priority Cache.


## 4.5. Measurement of Transmission Costs

Currently, Ping and Traceroute are two network tools that can be used to measure network distance between two hosts. However, both of them cannot satisfy the requirements of DHS because they are not originally for this purpose. The DHS needs a quick response and low overhead tool to measure both the RTT and hop counts between two hosts. This paper implemented an extended Ping tool that uses network practice for this goal. Currently, most network hosts use platforms such as Linux, Unix, FreeBSD, or Windows. The default time-to-live (TTL) value in Linux-like system, for example, Linux, Unix, or FreeBSD, is set to 64 or 255, while in Windows system, for example, Windows 2000, XP, Vista, Server 2008, or 7, it is set to 128. The disparity between these TTL values is at least 64. Although the scale of the Internet is huge, the distance between a pair of hosts should not exceed 64 hops. Therefore, the hop counts between a pair of hosts are obtained by using the three default TTL values to subtract the remainder of TTL value after pinging the destination host. And finally choose the calculation result that is between 0 and 64. For example, the remainder of TTL value is 246 after pinging an IP address. Using 255, 128, and 64 to subtract 246 separately equals 9, −118, and −182. The distance between both hosts is 9 hops. The extended Ping tool has been verified by Traceroute, and the results are all correct in the randomly selected IP address.


## 5. Comparison of Location Management Costs

This section compares the proposed DHS scheme with HP, FP, dU, SPC, RAMD, and Ratio schemes by formulating the location management costs in each of them. In doing so, the constituents of location management cost in each scheme are analyzed and the performance of DHS is evaluated. Abbreviations section lists the parameters used in the comparison.Several assumptions are made for the following comparison. The first is that the probability that a mobile agent migrates to the home region is considerably low, and the second is the probability that the sender agent’s current host and the receiver agent’s home are within the same region is also extremely low.Location management costs are constituted by the tracking cost and the message delivery cost. The tracking cost is the total cost of the update messages produced in the tracking phase, while the message delivery cost is the total cost of interaction messages created in the message delivery phase. The formulation is based on the region, where the migration of a mobile agent is divided into intraregion migration and interregion migration. Additionally, the transmission cost of a message is also classified into the costs of intraregion transmission and interregion transmission.


### 5.1. The Tracking Cost

The total tracking cost is denoted asCT in each scheme and is expressed as follows:(3)CTHP=n×Cul,CTFP=0,CTdU=nd×Cul,CTRatio=n×r×Cu(l),0<r<1,CTSPC=n×pr×2Cur+pl×Cur+3Cul,CTRAMD=n×pr×Cur+pl×Cur+2Cul.According to the operation of each scheme, the tracking cost in each scheme is explained as follows. In the HP scheme, the total number of update messages isn, because a mobile agent updates its location information every time it moves and the number of created message is 1 in each update. Owing to the assumption that the transmission of each update message is interregion transmission, the cost is Cu(l). The FP scheme creates no update messages, and the tracking cost is zero. For the dU scheme, the number of updates is n/d because a mobile agent updates its location information after d migrations. The number of update message is1 in each update. The transmission cost of each update message in it is the same as that in the HP scheme. In the SPC scheme, the number of updates is n, and the number of update messages in each update depends on the migration of a mobile agent. In the case of intraregion migration, a mobile agent creates two update messages because it updates to the previous host and the current ANS. In the case of interregion migration, the mobile agent generates four update messages because it updates to the previous host, the previous ANS, the current ANS, and the home ANS. In RAMD, the number of updates is n, and the number of created messages in each update also relies on the migration of a mobile agent. In the case of intraregion migration, the mobile agent only updates location information to the current RS; thus, the number of created message is 1. In the case of interregion migration, the mobile agent updates the home host, the home RS, and the current RS; hence, the number of update messages is 3.The tracking cost in DHS considers not only a mobile agent’s migration, but also which home the mobile agent updates to. There are four cases in the following:(1)
Intraregion migration and updates to the primary home: the probability is pr×pph, and the transmission cost of an update message is Cu(l).(2)
Intraregion migration and updates to the temporary home: the probability is pr×pth, and the transmission cost of an update message is Cu(r).(3)
Interregion migration and updates to the primary home: the probability is pl×pph, and the transmission cost of an update message is Cu(l).(4)
Interregion migration and updates to the temporary home: the probability is pl×pth, and the transmission cost of an update message is Cu(l).The total tracking cost in DHS is expressed as follows:(4)CTDHS=(n-ΔC)×pr×pph×Cul+pth×Cur+pl×pph×Cul+pth×Cul+CM=(n-ΔC)×pr×pph×Cul+pth×Curpph×Cul+pth×Cur+pl×Cul+CM.The reduced number of updates by using forwarding pointers is denoted as ΔC in the proposed DHS scheme. Simulation results indicate that ΔC could reduce 16–24% of all updates.Additionally, the tracking cost in DHS also includes the cost for calculating the transmission cost between a pair of hosts on the network. Assume that the cache miss rate is denoted asRCM, which represents the possibility that the transmission costs information of hosts required for making update decision cannot be found in themembership table of a local host. Moreover, assume that the transmission costs of update messages and network distance measurement messages are all the same. The cost of determining the transmission costs between hosts is denoted by CM. The following two cases are considered for defining CM:(1)
Intraregion migration: the probability is pr, and the transmission costs from current host to the primary home is Cu(l) and to the temporary home is Cu(r).(2)
Interregion migration: the probability is pl, and the transmission costs from current host to the primary home is Cu(l) and to the temporary home is Cu(l).The definition ofCM is expressed as follows:(5)CM=2×n×RCM×pr×Cul+Cur+pl×2Cul.


### 5.2. The Message Delivery Cost

The message delivery cost (CD) is the total cost of interaction messages created in the message delivery phase. Delivering an interaction message includes two phases: a sender agent sends the interaction message to the receiver agent’s responsible LMS and, then, the hosts on achannel cooperatively forward an interaction message to the receiver agent. The transmission costs of the two phases are denoted as CSH and CCH, respectively. Then, CI is formulated as (6)CI=CSH+CCH.The total number of interaction messages is denoted as NI, and the message delivery cost in each scheme is formulated as follows:(7)CDHP=NI×CSH+Cil,CDFP=NI×CSH+∑i=1NILch(i)×pr×Cir+pl×Cil,1≤Lchi≤n,CDdU=NI×CSH+∑i=1NILch(i)×[pr×Ci(r)+pl×Ci(l)],1≤Lchi≤d,CDRatio=NI×CSH+∑i=1NILchi×pr×Cir+pl×Cil,1≤Lchi≤1r,CDSPC=NI×2×psr⁡×Cqr+Cqlpsr⁡×Cqr+Cql+1-psr⁡×2CqlhhhhhCqr+Cql+psr⁡×Cir+1-psr⁡×Cil,CDRAMD=NI×CSH+Cil+Cir,CDDHS=NI×CSH+pph×Cil+pthCSH+pph×Cil+pth2×pr×Cil+Cir+pl×2Cil.In the HP scheme, a mobile agent’schannel moves directly from its home site to its current host; thus, CCH is equal to Ci(l). For the FP scheme, an interaction message is delivered by following the migration route of a mobile agent; hence, CCH depends on the location of the mobile agent. Moreover, with the increasing incidence of the number of the mobile agent’s migration, the transmission cost increases. In the equation of FP scheme, pr×Ci(r)+pl×Ci(l) represents the possible cost of delivering an interaction message between two hosts on mobile agent’s channel, in which pr+pl=1. Lch(i)×[pr×Ci(r)+pl×Ci(l)] represents the possible delivery costs that forward the ith message from LMS to the mobile agent. In the dU scheme, the expression of CCH is similar to that in FP scheme. However, the difference is that the length of achannel in dU scheme is at most d hosts. In SPC, the message delivery mechanism differs from other schemes in the way of locating the receiver agent. A sender agent locates the receiver agent by querying hosts on thechannel sequentially; it then sends interaction messages to the receive agent’s current location directly. Because hosts on a mobile agent’schannel are always the home ANS, the current ANS, and the current host, two queries are necessary for determining the receiver agent’s location. Moreover, each query generates a request and a reply message. If the sender and the receiver agent are within the same region, the costs of request and reply messages are 2×[Cq(r)+Cq(l)]; otherwise, the costs of request and reply messages are 4×Cq(l). In RAMD, two approaches for message delivery are push and pull. In this work, the formula of message delivery cost in RAMD is derived from the push approach. Hosts on a mobile agent’schannel in RAMD are the home host, the current RS, and the current host. Therefore, the message delivery cost is Ci(l)+Ci(r) on such achannel. In the proposed DHS scheme, the message delivery cost is formulated by considering the following four cases:(1)
Intraregion migration and updates to the primary home:CCH is equal to Ci(l).(2)
Intraregion migration and updates to the temporary home:CCH is equal to Ci(l)+Ci(r).(3)
Interregion migration and updates to the primary home:CCH is equal to Ci(l).(4)
Interregion migration and updates to the temporary home:CCH is equal to 2Ci(l).


### 5.3. Comparison

This section compares the proposed DHS scheme with HP, FP, dU, SPC, Ratio, and RAMD schemes by using the above derived formulae. The network latency metric used in the comparison is hop count. Assume the network scale is 30 hops for the longest distance between hosts, and the maximum migration of each region is 5 hops. In such a network, the transmission cost of a message is between 1 and 5 hops in a region and 6 to 30 hops between regions. Accordingly,Cu(r), Ci(r), and Cq(r) are set to 3 hops, and Cu(l), Ci(l), and Cq(l) are set to 18 hops. The transmission costs of update, interaction, and query messages are assumed to be the same owing to their small sizes.Since the probability that the home hosts of a sender agent and a receiver agent has been assumed to be very small,CSH is equivalent to Ci(l). Furthermore, parameters related to DHS, that is, pph and pth, are set to 0.6 and 0.4, respectively. The value of d in dU is set to 2 since an additional experimental finding indicates that when d=2dU has optimum overall performance. This finding also suggests that a mobile agent had better updated location information every two movements. Notably, NI, pr, and pl are variables in the comparison, in which NI represents the interaction rate pr, and pl is related to the migration locality. The tracking cost and the message delivery cost in each scheme can be determined by substituting the above values within formulae. Figures 4 and 5 summarize the calculation results.Figure 4
The total costs in tracking phase.Figure 5
The total costs in message delivery phase as (a)pr=0.1, (b) pr=1.
(a)
(b)Although slightly affecting the tracking cost in DHS, migration locality does not affect home-based schemes, that is, HP, dU, Ratio, and FP. This figure further demonstrates that the tracking costs in SPC and RAMD are especially high as the migration locality is low. This is because SPC and RAMD produce more than one update message in each update process for the reliability.Figure5 summarizes the results of message delivery costs. The message delivery cost depends mainly on the average length of channels created. This finding suggests that, in Figure 5, the average length ofchannels in SPC (psr⁡=0) is the longest; meanwhile, that in HP is the shortest. Undoubtedly, the message delivery cost in the HP scheme is the lowest because an interaction message is sent directly from the home host to a mobile agent’s current host. Furthermore, the tracking costs in DHS, dU, and RAMD decrease with an increasing migration locality.Assume that the transmission costs of update messages and interaction messages are the same. The total location management cost is then computed by summing up both the tracking cost and the message delivery cost. Figure6 summarizes the results.Figure 6
The total location management costs as (a)pr=0.1, (b) pr=1.
(a)
(b)In Figure6, the initial value (IR=0%) of each line is the tracking cost in each scheme because the message delivery cost is 0 as IR=0%. Moreover, the growth rate of the total location management cost in Figure 6 and that of the message delivery cost in Figure 5 in each scheme are the same. This phenomenon is owing to the fact that the increase of interaction rate does not affect the tracking costs. According to Figures 6(a) and 6(b), the total location management costs in the SPC and RAMD scheme significantly decreases with an increasing migration locality; this phenomenon is because migration locality significantly affects the tracking cost in both of them. In summary, the decrease of total location management costs in the region-based schemes is the greatest; that in the proposed DHS scheme is second; and that in the home-based schemes is the least as the migration locality increases. This work develops a mobile agent location management scheme that produces low location management costs in all migration localities and interaction rates. The proposed DHS scheme satisfies this objective.


## 5.1. The Tracking Cost

The total tracking cost is denoted asCT in each scheme and is expressed as follows:(3)CTHP=n×Cul,CTFP=0,CTdU=nd×Cul,CTRatio=n×r×Cu(l),0<r<1,CTSPC=n×pr×2Cur+pl×Cur+3Cul,CTRAMD=n×pr×Cur+pl×Cur+2Cul.According to the operation of each scheme, the tracking cost in each scheme is explained as follows. In the HP scheme, the total number of update messages isn, because a mobile agent updates its location information every time it moves and the number of created message is 1 in each update. Owing to the assumption that the transmission of each update message is interregion transmission, the cost is Cu(l). The FP scheme creates no update messages, and the tracking cost is zero. For the dU scheme, the number of updates is n/d because a mobile agent updates its location information after d migrations. The number of update message is1 in each update. The transmission cost of each update message in it is the same as that in the HP scheme. In the SPC scheme, the number of updates is n, and the number of update messages in each update depends on the migration of a mobile agent. In the case of intraregion migration, a mobile agent creates two update messages because it updates to the previous host and the current ANS. In the case of interregion migration, the mobile agent generates four update messages because it updates to the previous host, the previous ANS, the current ANS, and the home ANS. In RAMD, the number of updates is n, and the number of created messages in each update also relies on the migration of a mobile agent. In the case of intraregion migration, the mobile agent only updates location information to the current RS; thus, the number of created message is 1. In the case of interregion migration, the mobile agent updates the home host, the home RS, and the current RS; hence, the number of update messages is 3.The tracking cost in DHS considers not only a mobile agent’s migration, but also which home the mobile agent updates to. There are four cases in the following:(1)
Intraregion migration and updates to the primary home: the probability is pr×pph, and the transmission cost of an update message is Cu(l).(2)
Intraregion migration and updates to the temporary home: the probability is pr×pth, and the transmission cost of an update message is Cu(r).(3)
Interregion migration and updates to the primary home: the probability is pl×pph, and the transmission cost of an update message is Cu(l).(4)
Interregion migration and updates to the temporary home: the probability is pl×pth, and the transmission cost of an update message is Cu(l).The total tracking cost in DHS is expressed as follows:(4)CTDHS=(n-ΔC)×pr×pph×Cul+pth×Cur+pl×pph×Cul+pth×Cul+CM=(n-ΔC)×pr×pph×Cul+pth×Curpph×Cul+pth×Cur+pl×Cul+CM.The reduced number of updates by using forwarding pointers is denoted as ΔC in the proposed DHS scheme. Simulation results indicate that ΔC could reduce 16–24% of all updates.Additionally, the tracking cost in DHS also includes the cost for calculating the transmission cost between a pair of hosts on the network. Assume that the cache miss rate is denoted asRCM, which represents the possibility that the transmission costs information of hosts required for making update decision cannot be found in themembership table of a local host. Moreover, assume that the transmission costs of update messages and network distance measurement messages are all the same. The cost of determining the transmission costs between hosts is denoted by CM. The following two cases are considered for defining CM:(1)
Intraregion migration: the probability is pr, and the transmission costs from current host to the primary home is Cu(l) and to the temporary home is Cu(r).(2)
Interregion migration: the probability is pl, and the transmission costs from current host to the primary home is Cu(l) and to the temporary home is Cu(l).The definition ofCM is expressed as follows:(5)CM=2×n×RCM×pr×Cul+Cur+pl×2Cul.


## 5.2. The Message Delivery Cost

The message delivery cost (CD) is the total cost of interaction messages created in the message delivery phase. Delivering an interaction message includes two phases: a sender agent sends the interaction message to the receiver agent’s responsible LMS and, then, the hosts on achannel cooperatively forward an interaction message to the receiver agent. The transmission costs of the two phases are denoted as CSH and CCH, respectively. Then, CI is formulated as (6)CI=CSH+CCH.The total number of interaction messages is denoted as NI, and the message delivery cost in each scheme is formulated as follows:(7)CDHP=NI×CSH+Cil,CDFP=NI×CSH+∑i=1NILch(i)×pr×Cir+pl×Cil,1≤Lchi≤n,CDdU=NI×CSH+∑i=1NILch(i)×[pr×Ci(r)+pl×Ci(l)],1≤Lchi≤d,CDRatio=NI×CSH+∑i=1NILchi×pr×Cir+pl×Cil,1≤Lchi≤1r,CDSPC=NI×2×psr⁡×Cqr+Cqlpsr⁡×Cqr+Cql+1-psr⁡×2CqlhhhhhCqr+Cql+psr⁡×Cir+1-psr⁡×Cil,CDRAMD=NI×CSH+Cil+Cir,CDDHS=NI×CSH+pph×Cil+pthCSH+pph×Cil+pth2×pr×Cil+Cir+pl×2Cil.In the HP scheme, a mobile agent’schannel moves directly from its home site to its current host; thus, CCH is equal to Ci(l). For the FP scheme, an interaction message is delivered by following the migration route of a mobile agent; hence, CCH depends on the location of the mobile agent. Moreover, with the increasing incidence of the number of the mobile agent’s migration, the transmission cost increases. In the equation of FP scheme, pr×Ci(r)+pl×Ci(l) represents the possible cost of delivering an interaction message between two hosts on mobile agent’s channel, in which pr+pl=1. Lch(i)×[pr×Ci(r)+pl×Ci(l)] represents the possible delivery costs that forward the ith message from LMS to the mobile agent. In the dU scheme, the expression of CCH is similar to that in FP scheme. However, the difference is that the length of achannel in dU scheme is at most d hosts. In SPC, the message delivery mechanism differs from other schemes in the way of locating the receiver agent. A sender agent locates the receiver agent by querying hosts on thechannel sequentially; it then sends interaction messages to the receive agent’s current location directly. Because hosts on a mobile agent’schannel are always the home ANS, the current ANS, and the current host, two queries are necessary for determining the receiver agent’s location. Moreover, each query generates a request and a reply message. If the sender and the receiver agent are within the same region, the costs of request and reply messages are 2×[Cq(r)+Cq(l)]; otherwise, the costs of request and reply messages are 4×Cq(l). In RAMD, two approaches for message delivery are push and pull. In this work, the formula of message delivery cost in RAMD is derived from the push approach. Hosts on a mobile agent’schannel in RAMD are the home host, the current RS, and the current host. Therefore, the message delivery cost is Ci(l)+Ci(r) on such achannel. In the proposed DHS scheme, the message delivery cost is formulated by considering the following four cases:(1)
Intraregion migration and updates to the primary home:CCH is equal to Ci(l).(2)
Intraregion migration and updates to the temporary home:CCH is equal to Ci(l)+Ci(r).(3)
Interregion migration and updates to the primary home:CCH is equal to Ci(l).(4)
Interregion migration and updates to the temporary home:CCH is equal to 2Ci(l).


## 5.3. Comparison

This section compares the proposed DHS scheme with HP, FP, dU, SPC, Ratio, and RAMD schemes by using the above derived formulae. The network latency metric used in the comparison is hop count. Assume the network scale is 30 hops for the longest distance between hosts, and the maximum migration of each region is 5 hops. In such a network, the transmission cost of a message is between 1 and 5 hops in a region and 6 to 30 hops between regions. Accordingly,Cu(r), Ci(r), and Cq(r) are set to 3 hops, and Cu(l), Ci(l), and Cq(l) are set to 18 hops. The transmission costs of update, interaction, and query messages are assumed to be the same owing to their small sizes.Since the probability that the home hosts of a sender agent and a receiver agent has been assumed to be very small,CSH is equivalent to Ci(l). Furthermore, parameters related to DHS, that is, pph and pth, are set to 0.6 and 0.4, respectively. The value of d in dU is set to 2 since an additional experimental finding indicates that when d=2dU has optimum overall performance. This finding also suggests that a mobile agent had better updated location information every two movements. Notably, NI, pr, and pl are variables in the comparison, in which NI represents the interaction rate pr, and pl is related to the migration locality. The tracking cost and the message delivery cost in each scheme can be determined by substituting the above values within formulae. Figures 4 and 5 summarize the calculation results.Figure 4
The total costs in tracking phase.Figure 5
The total costs in message delivery phase as (a)pr=0.1, (b) pr=1.
(a)
(b)Although slightly affecting the tracking cost in DHS, migration locality does not affect home-based schemes, that is, HP, dU, Ratio, and FP. This figure further demonstrates that the tracking costs in SPC and RAMD are especially high as the migration locality is low. This is because SPC and RAMD produce more than one update message in each update process for the reliability.Figure5 summarizes the results of message delivery costs. The message delivery cost depends mainly on the average length of channels created. This finding suggests that, in Figure 5, the average length ofchannels in SPC (psr⁡=0) is the longest; meanwhile, that in HP is the shortest. Undoubtedly, the message delivery cost in the HP scheme is the lowest because an interaction message is sent directly from the home host to a mobile agent’s current host. Furthermore, the tracking costs in DHS, dU, and RAMD decrease with an increasing migration locality.Assume that the transmission costs of update messages and interaction messages are the same. The total location management cost is then computed by summing up both the tracking cost and the message delivery cost. Figure6 summarizes the results.Figure 6
The total location management costs as (a)pr=0.1, (b) pr=1.
(a)
(b)In Figure6, the initial value (IR=0%) of each line is the tracking cost in each scheme because the message delivery cost is 0 as IR=0%. Moreover, the growth rate of the total location management cost in Figure 6 and that of the message delivery cost in Figure 5 in each scheme are the same. This phenomenon is owing to the fact that the increase of interaction rate does not affect the tracking costs. According to Figures 6(a) and 6(b), the total location management costs in the SPC and RAMD scheme significantly decreases with an increasing migration locality; this phenomenon is because migration locality significantly affects the tracking cost in both of them. In summary, the decrease of total location management costs in the region-based schemes is the greatest; that in the proposed DHS scheme is second; and that in the home-based schemes is the least as the migration locality increases. This work develops a mobile agent location management scheme that produces low location management costs in all migration localities and interaction rates. The proposed DHS scheme satisfies this objective.


## 6. Simulation Evaluation

Evaluation results in the previous section are obtained from the formulae with many postulations. This section verifies the validity of the results from formulae by using the simulation approach which is more realistic to actual circumstances. This work devises a simulation environment in which experiments can be performed precisely. The network topology of the environment used here is established by using the nem [50] network topology generator that can create a network map that resembles an actual network. The nem can generate any size of network topology by setting the number of routers. The output topology is a text file in which each line is the number of two consecutive nodes. By manipulating the text file, the network distance is obtained by using the Depth-First-Search algorithm to compute the number of nodes between a pair of hosts. The simulated network has 20,000 routers, and the longest distance between hosts is 30 hops after calculating the distance between each pair of routers. Furthermore, the network is divided into regions, and the size of each region ranges from 3 to 7 hops. The mobile agent’s itinerary is set to 100 hosts. In the comparison of each issue, experiments are performed for 100 rounds for a mobile agent, and hosts in the mobile agent’s itinerary are selected randomly in each round. The experiment results are the average of each round. The reason of conducting 100 rounds for each experiment is that the average value of result is enough stable.


### 6.1. Comparison

This section evaluates and compares the tracking costs, message delivery costs, and total location management cost in each scheme by simulation experiments. The cost of determining network distance between hosts (CM) in DHS is computed by assuming RCM=10% and is included in the tracking cost of DHS in this experiment. Figures 7 and 8 show the results of tracking costs and message delivery costs, respectively.Figure 7
The total costs in tracking phase.Figure 8
The total costs in message delivery phase as (a)pr=0.1, (b) pr=1.
(a)
(b)The results in Figures7 and 4 are nearly the same. However, the tracking cost of the proposed DHS scheme shown in Figure 7 includes the cost of determining the network distance. Furthermore, according to Figure 7, the tracking cost in the proposed DHS scheme decreases rapidly as the migration locality approaches 100%. The results shown in Figures 8 and 5 slightly differ from each other. The most obvious is the performance of SPC (psr⁡=1). This is because the assumption that the possibility that the sender agent’s current host and the receiver agent’s home are within the same region is also extremely low. Figure 9 summarizes the results of the total location management cost in each scheme.Figure 9
The total location management costs as (a)pr=0.1, (b) pr=1.
(a)
(b)According to Figure9, the total location management cost of the proposed DHS scheme is nearly the lowest among all migration localities and interaction rates. In comparison with Figure 6, the experimental results of the proposed DHS scheme, as shown in Figure 9, are more satisfactory than those of other schemes.


### 6.2. Further Comparison

This section analyzes why the proposed DHS scheme in the simulation experiments performs better than that in the formulae evaluations. As mentioned earlier, the proposed DHS scheme reduces the total location management cost by preventing update and interaction messages from being transported on high transmission cost network links. Therefore, the values ofC(l) and C(r) in the proposed DHS scheme appear to be smaller than that in other schemes. An experiment was conducted to prove this postulation. Figure 10 summarizes those results.Figure 10
The comparison ofC(l) and C(r) in each scheme.According to Figure10, the values of C(l) and C(r) in DHS are smaller than those in other schemes. In the formulae evaluation, the values of C(l) or C(r) in each scheme are assumed to be the same, explaining why the proposed DHS scheme performs better in the simulation experiments than in the formulae evaluations.Moreover, that proposed DHS scheme can select a network link with a lower transmission cost for message because there are two homes for a mobile agent to update its location information. Theoretically, the possibility that a mobile agent updates to the temporary home increases when the migration locality increases. Nevertheless,pph and pth are constant values in the formulae evaluation. A simulation experiment is performed to estimate the values of pph and pth in all migration localities. Figure 11 summarizes those results.Figure 11
The values ofpph, pth, and ΔC in all migration localities.Obviously, the values ofpph and pth vary with an increasing migration locality, as shown in Figure 11, which also explains why the results in formulae evaluation and simulation experiments differ from each other. Figure 11 shows the number of updates (ΔC) that are reduced by using forwarding pointers. According to this figure, the reduced number of updates ranges from 16 to 24%.


## 6.1. Comparison

This section evaluates and compares the tracking costs, message delivery costs, and total location management cost in each scheme by simulation experiments. The cost of determining network distance between hosts (CM) in DHS is computed by assuming RCM=10% and is included in the tracking cost of DHS in this experiment. Figures 7 and 8 show the results of tracking costs and message delivery costs, respectively.Figure 7
The total costs in tracking phase.Figure 8
The total costs in message delivery phase as (a)pr=0.1, (b) pr=1.
(a)
(b)The results in Figures7 and 4 are nearly the same. However, the tracking cost of the proposed DHS scheme shown in Figure 7 includes the cost of determining the network distance. Furthermore, according to Figure 7, the tracking cost in the proposed DHS scheme decreases rapidly as the migration locality approaches 100%. The results shown in Figures 8 and 5 slightly differ from each other. The most obvious is the performance of SPC (psr⁡=1). This is because the assumption that the possibility that the sender agent’s current host and the receiver agent’s home are within the same region is also extremely low. Figure 9 summarizes the results of the total location management cost in each scheme.Figure 9
The total location management costs as (a)pr=0.1, (b) pr=1.
(a)
(b)According to Figure9, the total location management cost of the proposed DHS scheme is nearly the lowest among all migration localities and interaction rates. In comparison with Figure 6, the experimental results of the proposed DHS scheme, as shown in Figure 9, are more satisfactory than those of other schemes.


## 6.2. Further Comparison

This section analyzes why the proposed DHS scheme in the simulation experiments performs better than that in the formulae evaluations. As mentioned earlier, the proposed DHS scheme reduces the total location management cost by preventing update and interaction messages from being transported on high transmission cost network links. Therefore, the values ofC(l) and C(r) in the proposed DHS scheme appear to be smaller than that in other schemes. An experiment was conducted to prove this postulation. Figure 10 summarizes those results.Figure 10
The comparison ofC(l) and C(r) in each scheme.According to Figure10, the values of C(l) and C(r) in DHS are smaller than those in other schemes. In the formulae evaluation, the values of C(l) or C(r) in each scheme are assumed to be the same, explaining why the proposed DHS scheme performs better in the simulation experiments than in the formulae evaluations.Moreover, that proposed DHS scheme can select a network link with a lower transmission cost for message because there are two homes for a mobile agent to update its location information. Theoretically, the possibility that a mobile agent updates to the temporary home increases when the migration locality increases. Nevertheless,pph and pth are constant values in the formulae evaluation. A simulation experiment is performed to estimate the values of pph and pth in all migration localities. Figure 11 summarizes those results.Figure 11
The values ofpph, pth, and ΔC in all migration localities.Obviously, the values ofpph and pth vary with an increasing migration locality, as shown in Figure 11, which also explains why the results in formulae evaluation and simulation experiments differ from each other. Figure 11 shows the number of updates (ΔC) that are reduced by using forwarding pointers. According to this figure, the reduced number of updates ranges from 16 to 24%.


## 7. Analyses of Location Table

In this paper, the location tables are used to maintain location information for DHS to track the current position of mobile agent. Location tables use storage space in host servers. In our environment, a location table is created by the MySQL database management system. The space complexity of location tables is evaluated by analyzing the data structure. In this paper, a location table consists of two fields: AgentID andHost_Address.(i)
AgentID: this field stores the unique identification of a mobile agent with field type and size of varchar(29). The format of AgentID is the IP address of the host where the mobile agent is created plus a timestamp that is specific to millisecond. The IP address needs 12 bytes and the timestamp needs 17 bytes.(ii)
Host_Address: this field stores the IP address of a host where a mobile agent moves to. The type and size of the field are varchar(12).According to the above specification, an entry in thelocation table is about the size of 29+12=41 bytes. The actual size oflocation tables is depending on the number of mobile agents.When a mobile agent finishes the tasks in a host and moves to the next host, it updates the location table according to the tracking mechanism. Suppose that a LMS maintains location information forn mobile agents and the average time a mobile agent needs to complete a task is t in the system. Based on the tracking mechanism, if the probability that a mobile agent has to update the location information is p, the update frequency of a location table (fLT) is formulated as(8)fLT=n×pt.


## 8. Conclusion

This work develops a novel mobile agent location management scheme that can minimize total location management cost. A location management scheme called DHS is proposed for this purpose. The development of DHS involves considering the migration locality of mobile agent and the interaction rate between mobile agents, that is, two important factors that affect the location management cost in mobile agent based information retrieval applications. For reducing the location management cost in all migration localities and interaction rates, the proposed DHS scheme uniquely adopts dual home location management architecture. Additionally, a selective update strategy based on the proposed architecture is designed for cost-effective mobile agent location management. The proposed DHS scheme is initially compared with several conventionally adopted location management schemes by formulation. Simulations are then performed not only to verify the formulae, but also to evaluate the total location management cost of the proposed DHS scheme. Simulation results demonstrate that the total location management cost in the proposed DHS scheme is nearly the lowest in all migration localities and interaction rates.



---

*Source: 915648-2015-04-28.xml*