Implementing Ant Algorithm to Enhance the Performance of Hybrid Network

DOI : 10.17577/IJERTV3IS061107

Download Full-Text PDF Cite this Publication

Text Only Version

Implementing Ant Algorithm to Enhance the Performance of Hybrid Network

Harpreet Kaur Ranjit Singh

M. Tech (CSE) Assistant Prof. (CSE Dept.)

LLRIET College LLRIET College

Moga Punjab (India) Moga-Punjab (India)

Abstract- Hybrid Network combines the best features of two or more different networks. This work combines the client server and centralized unstructured peer to peer (P2P) network to form hybrid network along with Ant algorithm implemented over it. To enhance the performance the work includes six modules. These are: (1) Network traffic analysis module, (2) Service mode switching module, (3) Central directory module,

(4) Ant based algorithm module, (5) Node selection module and

(6) Napster P2P module. This technique uses an Ant based algorithm. As Ant based algorithm does not require any pre information like network topology, so this algorithm can be used in unstructured peer to peer network. Thus the extra burden on server for maintaining structured peer to peer system like chord is not required. This algorithm makes the system very efficient for handling temporary as well as permanent changes in peer to peer networks. The algorithm can be updated or adjusted according to the need of dynamic networks. This technique is useful to find out the peer which is at the shortest distance. This work reduces the load and the congestion up to reasonable extent. The performance of the proposed method is compared to that of existing in terms of throughput, congestion and packet dropping.

Keywords: P2P(Peer-to-Peer), Network Simulator-2(NS-2), Packet loss (PL), Packet loss threshold value(PLTV)

I.INTRODUCTION

In networking terminology, a hybrid network combines the best features of two or more different networks for providing information. According to "Information Technology Control and Audit", hybrid topologies are reliable and versatile. They provide a large number of connections and data transmission paths to users. Through hybrid network, people can obtain a large quantity of digital content more efficiently like text, image, voice, video and animated content etc. The transmission of image, video and voice data makes relatively high demands on the bandwidth and stability of a network. To achieve these ones the following two networks are combined to make a hybrid network: (1) Client-Server network (2) Peer-to-Peer network.

Client server technique is used to improve the work load on the network through enabling the responsibilities of a computing system that are to be distributed among several independent computers. The main advantage of this model is greater ease of maintenance. In such network there exists a central controller called server. A server is a specialized computer that controls the network resources and provides services to other computers in the network. All other

computers in the network are called clients. A client computer receives the requested services from the server. A server performs all the major operations like security and network management. All the clients communicate with each other via centralized server as shown in the figure 1. If client1 wants to send the data to client2,it first sends request to server to seek permission for it. The server then sends a signal to client1 allowing it to initiate the communication.

Fig 1: Client Server Network

A server is also responsible for managing all network resources such as files, directories and shared devices like printer etc. If any of the clients want to access these services, it first seeks permission from the server by sending a request. Most local area networks are based on client server relationship. In Client Server Architecture each computer or process on the network is either a client or a server. Servers are powerful computers or processes dedicated to managing disk drives, printers, or network traffic. Clients are PCs or workstations on which users run applications. Clients rely on servers for resources, such as files, devices, and even processing power. Traffic congestion on the network is very high. When number of simultaneous client requests to a given server increases, the server may overload. In client-server, if a critical server fails, clients requests cannot be fulfilled.

In P2P networks, all the devices have same status in the network and share the link equally as shown in figure 2.Each device is responsible for setting up and maintaining its own security and each device act as client as well as server. P2P Networks are easy to set up and maintain as each computer manages itself. Since each device is master of its own, they are not dependent on other computers for their operation

Fig.2: Peer to Peer Network

Peer to Peer technology can be used to balance the server load without adding the extra cost. Peer to Peer network can replace the traditional structure of separated client and server, giving the dual roles of server and client to each node.

Under Peer to Peer Network this research adopts Centralized P2P network which is also known as hybrid unstructured network. These networks apply an index sever to store all the file address information. When node makes a request for a data item, it searches at the server and returns the desired data address, then access the node that stores the data directly. The example of typical system is Napster. It works by operating a central server which directs traffic between individual registered users. Each time a user submits a request for data, the central server creates a list of user who are currently connected to Napster whose collections include the specified data.

This work uses the ant net algorithm for performance enhancement. This section includes the description of ant algorithms. Ant Algorithms are used to find the shortest paths which are based on the behavior of ants. Ants are able to find the best way to and from food source, in spite of being practically blind. Ants deposit a chemical substance called pheromone for marking path from food source to nest. By sensing pheromone trails, foragers can follow the path to food discovered by other ants. Shortest routes have high concentration of pheromone and almost all ants end up using this path. For building a solution each ant collects information on the problem characteristics. At first, the ants wander randomly when an ant finds a source of food; it walks back to the colony leaving pheromone that shows the path has food. Because the ants drop pheromone every time they bring food, shorter paths are more likely to be stronger. Ant algorithm uses two type of packets that are forward and backward ant packets for collection of pheromone.

This research presents hybrid network combination of client server and Centralized P2P network and the Ant algorithm which is implemented over hybrid network to enhance its performance. This reduces the network congestion and packet loss and increases its throughput. Verifications through the NS2 is performed to test the performance as whether this technique is superior to the traditional one.

II. OBJECTIVES

The main objectives of this work are described as follows:

  • To reduce the congestion between client and server and increases the data transfer rate.

  • To reduce the load of internet content providers server without adding the extra cost.

  • To detect temporary and permanent changes in the network. To get the node status as whether the node is temporarily leaving or joining the system.

  • To find the peer that is at shortest distance from the client. To reduce the packet loss rate and packet droping.

  • To find the alternative peer quickly in the network if the peer which is communicating with the client gets failed.

    1. LITERATURE REVIEW

      1. Delay

        Network delay is an important design and performance characteristic of a computer network or telecommunications network. The delay of a network specifies how long it takes for a bit of data to travel across the network from one node or endpoint to another. It is typically measured in multiples or fractions of seconds. Delay may differ slightly, depending on the location of the specific pair of communicating nodes. Packet transfer delay is influenced by the level of network congestion and the number of routers along the way of transmission.

      2. Throughput

        Throughput refers to how much data can be transferred from one location to another in a given amount of time. It is used to measure the performance of Internet and network connections. A typical method of performing a measurement is to transfer a 'large' file from one system to another system and measure the time required to complete the transfer or copy of the file. The throughput is then calculated by dividing the file size by the time to get the throughput in megabits, kilobits, or bits per second.

      3. Packet Loss Rate

        Partial packet loss will occur when the traffic volume on the network is too large for network devices to handle. Network communication protocols will automatically resend packets in case of packet loss. Provided that the total packet number reaching the server is T and the number of packets lost to overflow in the buffer is L, then the packet loss rate is (L/T)*100%. Packet loss can't be completely avoided in the operation of a network, especially at the peak of network usage [1].

      4. Total Transmission Time

        The total transmission time refers to the total time from the moment that the user begins to submit the request of file transfer service to the time at which the service terminates completely. Generally speaking, large quantities of data transmissions can influence the efficiency of the external network of the server: if the user sends a service request to the server, it will result in low transmission speed or prolonged response time due to network congestion, making the total service time longer than expected by users, decreasing user satisfaction [2]

      5. Client Server Network

        In these networks there exists a central controller called Server. A server is a specialized computer that controls the network resources and provides services to other computers in the network. All other computers in the network are called clients. This network have some disadvantages which are listed as: It requires specialized servers with large memory and storage, this leads to increases in the cost. It requires dedicated network administrated. If the server fails then the working of whole network is halted.

      6. P2P Network

      A P2P Network does not depend on a centralized server. It enables each joined node to search, store and share data with others. P2P is mainly divided in to two types: Unstructured P2P and Structured P2P Network [3]. The difference between the two topologies is that a structured system provides a routing algorithm, which makes the network more effective [5]. The two kinds of networks are discussed as below:

      1. Unstructured P2P

        In terms of network topology, unstructured P2P can further be divided into two types: centralized and decentralized [4]. These types are discussed as:

        Centralized Network: The advantages of centralized P2P are to provide the file hash table while not directly providing file transfer service for nodes. Each node obtains IP addresses corresponding to required files from the server and sends data transmission requests to other nodes. The disadvantage of a centralized P2P network is that the whole system will not operate if the central server stops its service [5].

        Decentralized Network: Decentralized P2P architectures are not based on any centralized or coordinating entity to locate data items within the network. To find all relevant items in the network, the unstructured P2P approaches peers recursively by forwarding received requests to neighboring peers. When a node receives a request for a key which represent the data item, it attempt to retrieve the file locally if possible; Otherwise, forwards the request to another node. When a request is successful or failed, the desired data item or failure report is returned to the requester along the same path of incoming request. In few networks, enhancement of routing performance is done by caching or forwarding request to the neighbor that are more likely to store the desired data. The local forwarding decision may depend on former routing information or maintaining extra data index information. The disadvantages of this unstructured P2P network are as: No guaranteed reliable content locating information. Non deterministic search is the only option since peer has no way of guessing where the file may be, Broadcast storm problem and Scalability is very less. The main advantage of unstructured P2P networks is that there is no need to proactively maintain a network structure. Peers maintain only pointers to an upper bounded number of direct neighbors. In unstructured peer-to-peer there is no enforcement of a specific storage location for data items, they can be located anywhere in the network.

      2. Structured Network:

      Structured P2P architectures utilize particular overlay structures to map peers and data items into a common address space, enabling a unique mapping from data items to peers gives the current state of the network. In structured P2P each peer manages a small number of pointers to carefully select other peers. If these structured overlays are used for routing, then O(logN) messages is needed for reaching the peer currently responsible for a given data item. In structured peer to peer network data items have to be distributed as uniformly as possible for balancing the storage and retrieval loads at the peers.

      A structured peer to peer network is used a distributed data structure based on a hash table to allow the insertion and retrieval of key/value pairs for providing routing functionality. For inserting or retrieving a key/value pair, the peer responsible for a key in the network as defined by the structured P2P network is used. This peer stores and maintains all appropriate key/value pairs for a key from across the directory. The data placement is not arbitrary in this system it is accurately determined by the underlying overlay architecture, and this provides a guarantee to find data items indexed by the network. Structured peer to peer network uses the distributed hash table for the storage of keys. Structured peer to peer network is a DHT based network.

    2. PROPOSED APPROACH

      This approach is using a centralized P2P system like Napster [7]. There is a central server facilitating the interaction between peers by maintaining directories of the shared files stored on the respective PCs of registered users to the network, in the form of meta-data. The end-to-end interaction is between two peer clients with the help of the central server. This server facilitates the interaction by performing the lookups and identifying the nodes of the network where the files are located. The systems comprise a network of registered users running some client software, and a central directory server have to maintain: An index with metadata of all the files in the network, A table of registered user connection information IP addresses, connection speeds etc and A table listing the files that each user holds and shares in the network.

      The proposed work includes six modules: (1) Network traffic analysis module, (2) Service mode switching module, (3) Central directory module, (4) Ant based algorithm module, (5) Node selection module and (6) Napster P2P module. As shown in fig 3. Modules 1, 2, 3 are set up in the server site while Module 4, 5 is set up in the peer site. When external nodes send service requests to the server, Module 1 will judge the present network loading and inform Module 2, which will judge whether to provide direct service for nodes or to start up the P2P module. Module 3 contains an index with metadata of all the files in the network, a table of registered user connection information, a table listing the files that each user holds and shares in the network. Module 4 starts when service mode switching module receives the order to start up the P2P system. It takes the list of nodes from central directory module and runs the ant algorithm. This

      module also creates the pheromone table; this table shows the pheromone value for a link and next hop that can be used to reach at destination. This module mainly receives commands from Module 2, and informs all online nodes to start up the P2P module when the packet loss rate is higher than the packet loss threshold. Module 5 is node selection module it is required for selecting the best set of peer who have higher pheromone value for a destination in pheromone table. It uses the pheromone table generated by ant based algorithm. Module 6 is used at both client and server site. At server site it helps the server as it contains centralized services and at client site it is used for establishing P2P connections.

      Fig 3: Architecture of Hybrid Network with Ant Algorithm

      1. Network traffic analysis module: This module is responsible to detect the actual network loading and return the results to the module 2 for statistics. This thesis adopts packet loss rate as the basis of judging network loading. Monitoring software on the server uses a network card to detect network load in real-time. Under Unix-like operating systems such as FreeBSD and Linux, the TCP-based network measurement software is used as the detection tool. The forward loss rate and reverse loss rate together form the basis for judgment. Forward loss rate is one-way packet loss rate from the testing machine to the target. Reverse loss rate is one-way packet loss rate from the target to the testing machine.

      2. Service mode switching modules: This module will judge the suitable service mode according to the network conditions provided by Module 1. When the value of network loading is lower than the server's packet loss threshold, the server will directly transfer the digital content to the client. Service mode switching module is basically used to decide about services that are to be provided by the server. On receiving the request the server activates its traffic analysis module to judge the network traffic and results of the network traffic load are provided to the service mode switching module. On the basis of the result this module decides whether the server directly provide the services to the client or the service is provided by another peer which is present in the network. This module adds the advantage of time efficiency and better services when compared to existing system.

      3. Central Directory Module: This module contains an index with metadata of all the files in the network and table of

        registered user connection information and table listing the files that each user holds and shares in the network. The module provides the information needed by peer to peer system like IP addresses of nodes those contains the demanded data by client. It also sends the information which is required by the Ant based algorithm like IP addresses and connection speeds of the nodes

      4. Ant based algorithm module: This module runs at the client. It gets started after receiving start instruction from service switch module. It uses the information provided by the server such as IP addresses of the nodes and connection speed. Before start, this module requires the list of nodes, this list of nodes provided by the server to client. This module produces the pheromone routing table. The list of node provided by server, form a peer to peer network as a connected graph G having (V, E) where, V is the set of nodes and E is the set of links. Assume that a node D which can be considered as client and D has requested a data with rate . It has found a group T of nodes that provide the data. A pair (Ri, Ai) is assigned to each peer where (Ri, Ai) represent the rate and availability of node i respectively. Ri is the rate that node i claims. The availability of node i, represented by Ai, is a measure of time during which node i is on. The set T contains all the nodes that have the requested stream available. In the first step, the node D initializes its pheromone table.

        Then according to its desirable rate , it generates a number of agents, which are called ants. Now it creates a network in which the source has a link to each receiver. Here, by the source it mean the source of ants and in the same fashion, receivers are peers who receive forward ants. The only thing to do is to assign pheromone to links. Having done that, ants follow the links with more pheromone in a probabilistic manner. Pheromone is added to links according to the rate and availability of the peers at the end of the link.

      5. Node Selection Module: This module uses the pheromone table which was generated by ant based algorithm. With the help of table it selects the node which has highest pheromone here highest pheromone means less congested node. If a node gets failure it selects the second highest pheromone and selects the node corresponding to that pheromone. A system does not halt even a node failure and system can run for a long time without communicating the server with help of pheromone table. This module removes the congestion between client and server.

      6. Napster P2P module: This module maintained the centralized server with the help of central directory module. This module handles the situation like node leaving the system and joining the system. All peers joining the system have to register their data with this centralized server thus allowing a comfortable way for other peers in the system to locate any data in the network by presence of a physically centralized directory. When the load on the network is higher in that case this module uses its P2P property with this each peer could directly communicate with other peers that store the data in a decentralized manner.

      On startup, the client contacts the central server and reports a list with the files it maintains. When the server

      receives a query from a user, and then the working of this technique starts. The fig 4 shows the step by step working of proposed work.

      Start

      Clients report the central

      Client requests server for data

    3. EXPERIMENT DESIGN

      After verifying the performance of the hybrid network using Ant algorithm, this research compared its performance with that of existing network under network simulation environment on the NS2 platform. The performance criteria are: (1) Server's packet loss rate/Packet dropping rate (2) Total transmission Delay time 3) Throughput. Ant algorithm is used in this proposed work to find the shortest path. Ant algorithms are preferably good option for detecting the shortest paths. According to the Ant algorithm pseudo code is generated. Figure 5 shows the pseudo-code after the client node receives the P2P start-up signal from the server.

      t := Current time;

      tend := Time length of the algorithm;

      t := time interval between ant generations; Foreeach(Node) /* Concurrent activity over the network */ M = Local traffic mode;

      T = Node routing table; While (t tend) in_parallel

      if(t mod t = 0) destination_node:=SelectDestinationNode(data_traffic_distributio n);

      Launch Forwared Ant (destination_node, source_node);

      end if

      foreach(Activeforwared Ant [source_node, current_node, destination_node ] ) While(current_nodedestination_node)

      next_hop_node:=SelectLink (current_node, destination_node, T, link_queues);

      PutAntOninkQueue (current_node, next_hop_node); WaitOnDataLinkQueue (current_node, next_hop_node); CrossTheLink (current_node, next_hop_node); PushOnTheStack (next_hop_node, elapsed_time); current_node:= next_hop_node;

      end while

      LaunchBackwardAnt (destination_node, source_node, stack_data); Die ( );

      endforeach

      foreach (ActiveBackwardAnt [ source_node, current_node, destination_node])

      while(current_node destination_node) next_hop_node:=PoPTheStack( ); WaitOnHighPriorityLinkQueue(current_node,next_hop_node); Cross The Link (current_node, next_hop_node); UpdateLocalTrafficModel(M, current_node,source_node, stack_data);

      Reinforcement:=GetReinforcement (current_node, source_node, stack_data,M);

      UpdateLocalRoutingTable (T, current_node, source_node, reinforcement);

      end while endforeach endin_parallel end while endforeach

      A

      Server activates its traffic analysis module

      Server transfer data to client directly

      Is PL>PLTV

      Client activates ant based algorithm module

      List of users of interest is returned

      Server searches users of interest

      ?

      Routing table with pheromone values is produced

      Client then activates node selection module

      Shortest distance node from the client is determined

      Connection is made between client & peer and information is

      Complete the request of client

      Breaks connection

      Stop

      Fig 4: Workflow Diagram of proposed work

      Fig 5:Pseudo-Code of Proposed Approach

      The steps followed for proposed work are explained in this section. Here are the steps which are followed for simulation:

      Step 1: Extending ns-2 to implement AntNet simulation. Step2: A topology created in tcl file.

      Step3: Pheromone Table creation with the help of AntNet Agent.

      Step4: Connection establishment between the nodes according to pheromone table.

      Step5: Observation of number of packets on a link between client and server and number of packets received at the client for a certain time interval.

      Following simulation parameters are considered to test the validity of this approach. They are listed in the Table 1.

      Table1: Network Environment and Configuration

    4. RESULTS AND DISCUSSION

      This section, describes how the simulations were done and what results were achieved during the simulations. The simulation results show that there is less delay and packet loss in this approach as compared to the traditional one. This technique is more effective to reduce the load on the network and remove congestion the congestion up to a reasonable extent.

      Fig 6: Proposed Simulated Network1

      Fig 7: Proposed Simulated Network2

      Figure 6 and figure 7 show the proposed network. This is a simulated hybrid network. This network is achieved through the simulations on ns-2.

      Fig 8: Pheromone table produced by Antnet during simulation

      Figure 8 shows the pheromone table. This is obtained by running the ant algorithm on client site. This describes the set of shortest distance nodes. According to the pheromone values, the client selects the shortest distance node or peer for communication. The node which has the highest value in table is the one which is more likely to be chosen for communication.

      Fig 9: Packet loss rate in traditional Approach

      Fig 10: Transmission Delay in traditional approach

      Fig 11: Throughput of traditional approach

      Fig 12: Packet loss rate in proposed technique

      Fig 13: Transmission delay in proposed technique

      Fig 14: Throughput of proposed technique

      Figure 12, 13 and 14 shows that in proposed technique there is less packet loss and less delay in the transmission of data and throughput of the network is higher as compared to the existing one.

      Fig 15: Comparison of Packets between Client and Server

      Figure 15 shows that the system has less number of packets between client and server it means less congestion between client and server. Packets between client and server may be higher for sometime than older approach because in these periods client request to the server to provide data. For providing the data to client, the server takes the charge on the network which forms the higher packet value.

      Fig 16: Packets Received at the Client

      Results in Figure 16 shows that the system performed better than the older MCSP system. In the system client receive more number of packets than the older one. Result shows that efficiency of the system increases with the time this is because the ants takes less time to find out the best and shortest path.

    5. CONCLUSIONS AND FUTURE SCOPE

  1. Conclusion:

    This work represents centralized P2P system with Ant algorithm, to remove congestion. This technique increases the rate of data transfer. This is able for finding the nodes that are leaving or joining the network so that there is reduction in node failures. This work there are three extra modules named as Ant module, Napster P2P module and Node selection module, through which the system performance will be enhanced. It is able to detect the dynamics of the network. It reduces the load on the network. The developed system is able to find the suitable node for communication. Even in the case of node failure the working of the network is not halted. It can also check the availability of the nodes in the network. The network uses the ant algorithm which gives the better route and shortest route for communication.

  2. Future Scope:

The work is dedicated for small Internet Content Providers which have small number of peers and suitable for Napster system. Future work may be for large Internet Content Provider for which unstructured peer-to-peer network with AntNet algorithm can be used. An ant based query algorithm can be used at server site for searching a data at the server which can make the system faster.

REFERENCES

[1]. Cidon, A. Khamisy, and M. Sidi, "Analysis of packet loss processes in high-speed networks", IEEE Trans. Info. Theory, vol. 39, no. 1, pp. 98- 108, Jan. 1993.

  1. X. Xiao and L.M. Ni. "Internet qos: A big picture. IEEE Network,"13(2):8-18, March/April, 1999.

  2. E. K. Lua, J. Crowcroft, M. Pias, R. Sharma and S. Lim, "A Survey and Comparison of Peer-to-Peer Overlay Network Schemes," IEEE Communications Survey and Tutorial, March 2004.

  3. StephanosAndroutsellis-Theotokis, "White Paper: A Survey of Peer-to- Peer File Sharing Technologies, " ELTRUN, Athens University of Economics and Business, Greece, 2002.

  4. T.-Y. Tseng, R. Lee, S.-W. Lin, T. Han, Mixed Client Server and Peer to Peer System for Internet Content Providers, IEEE International Conference on Systems, Man, and Cybernetics October 8-11, 2006, Taipei, Taiwan.

  5. Klaus Wehrle, Stefan Gotz, and Simon Rieche, Peer to Peer systems and applications Distributed hash tables, In Lecture Notes in Computer Science. Springer- Verlag, Berlin Heidelberg New York 2005.

  6. Napster. http://www.napaster.com/.

  7. I Stoica, R.morris, D. Karger, M.F.Kaashoek, and H.Balakrishnan, Chord:A scalable peer-to-peer lookup service for internet applications, in IEEE/ACM Transaction on Networking, volume 11,

    February 2003

  8. S.Saroiu, K.Gummadi, and S.Gribble, A measurement study of peer- to-peer file sharing systems, in Proceedings of Multimedia Conferencing and Networking, San Jose,January 2002.

  9. Gianine Di Caro Marco Dorigo, AntNet: Distributed Stigmergetic Control for Communication Networks, IRIDIA University Libre de Bruxelles 50,av. F.Roosevelt,CP 194/6, 1050 Brusseles, Belgium.

  10. Amir HesamSalavati, HadiGoudarzi, Mohammad Reza Pakravan, An Ant Based Rate Allocation Algorithm for Media Streaming in Peer to Peer Network, School of Electrical Engineering Sharif University of Technology Tehran, ran

  11. V. Cholvi P. Felber and E. Biersack, Efficient search in unstructured peer-to-peer networks, Proc. 16th ACM Symposium on Parallelism in Algorithms and Architectures, 2004.

  12. Hsiao and S.-D. Wang,"Jelly: A Dynamic Hierarchical P2P Overlay Network with Load Balance and Locality ", ICDCS Workshops, 2004: 534-540.

  13. V.Laxmi, Lavina Jain, M.S.Gaur, Ant Colony Optimization based Routing on ns-2, To be published in the proceedings of International Conference On Wireless Communication and Sensor Networks,WCSN 2006

  14. Ling chen,HayingSun,Shuwang, Solving continuous optimization Using ant algorithm, 2009 Second conference on future tchnology and management enginreering, FITME.2009.29

  15. C. Gkantsidis, M. Mihail, and A. Saberi, Hybrid search schemes for unstructured peer-to-peer networks, Proc.of INFOCOM, 2005.

Leave a Reply