A Practical Routing Protocol Based on WiFi for Resources
Transcription
A Practical Routing Protocol Based on WiFi for Resources
Journal of Information & Computational Science 12:2 (2015) 787–796 Available at http://www.joics.com January 20, 2015 A Practical Routing Protocol Based on WiFi for Resources-constrained Opportunistic Networks ? Ding Liu ∗, Xiaoming Wang, Junling Lu, Yufei Gao School of Computer Science, Shaanxi Normal University, Xi’an 710062, China Abstract Opportunistic networks based on WiFi technology can be widely deployed in special area which wired network can not cover or the infrastructure of mobile telephone network is paralysed in consequence of severe earthquakes, floods, or other natural calamities. Two most important issues should be considered to guarantee message delivery in opportunistic networks: routing protocols and efficient buffer management strategy. Considering above two issues, we propose an opportunistic networks routing protocol based on WiFi (ONRWF) which aims to make up for the lack of bandwidth and buffer space. ONRWF contains delivery prediction which can decide next hop routing by comparing the prediction of future meeting time of all nodes. In the strategy of buffer management, scheduling policy aims to improve message delivery of high priority, and the proposed drop policy focuses on improving the efficiency of buffer space. Finally, a testbed is also set up to validate the ONRWF in real life. Compared with the traditional WiFi and SVSS (our previous work), experimental results demonstrate significant performance benefits in terms of message delivery for opportunistic networks based on WiFi. Keywords: Opportunistic Networks; WiFi; Resources-constrained; Buffer Management 1 Introduction Delay Tolerant Networks (DTNs) are a class of emerging networks where disconnections may occur frequently due to node mobility, power outages and communication uncertainty. As one type of Delay Tolerant Networks, opportunistic networks do not need lay out communication infrastructure, and use node mobility to set up delay-tolerant routines for communication [1, 2]. In recent years, with the rapid development of mobile communication, network communications are gradually moving towards the trajectory of the mobile internet. Some of the mobile devices (such as smart phone, PDA, etc.) have become increasingly diverse. They not only have embedded operating system, Bluetooth communications, GPS positioning, WiFi communications and video cameras feature, but also have strong data calculation and processing capabilities. ? Project supported by the National Nature Science Foundation of China (No. 60970054, No. 60773224) and the Scientific Research Foundation for the Returned Overseas Chinese Scholars, State Education Ministry (No. 61173094). ∗ Corresponding author. Email address: [email protected] (Ding Liu). 1548–7741 / Copyright © 2015 Binary Information Press DOI: 10.12733/jics20105259 788 D. Liu et al. / Journal of Information & Computational Science 12:2 (2015) 787–796 Current mobile phones with WiFi enabled are becoming increasingly popular. It is especially noteworthy that WiFi (IEEE 802.11-based wireless local area network) is taking the leading role for the wireless communication due to its greater coverage, free-of-charge and higher transmission rates. In opportunistic networks, routing and buffer management are challenging issues [3, 4, 5]. The conventional routing protocols are not applicable for opportunistic networks based on WiFi technology (known as WiFi peer-to-peer). Opportunistic networks usually composed of human beings equipped with smart phones, can be applied to many scenarios. In these scenarios, self-organizing opportunistic networks are located in special areas where wired or wireless network can not cover caused by natural disasters. China, a multi-earthquake shock country, lies in the earthquake belt along the west of the Pacific Ocean. Many earthquakes happen in China, which would have caused the deaths of many people. How to use more advanced technology to reduce human loss is a serious problem. Imagine a major earthquake happens in a mountainous area of western China. The earthquake devastates most infrastructures of mobile telephone networks, leading to the collapse of mobile telephone networks services for a long time. In this critical scenario, the rescuers should move to the disaster area quickly, and immediately return information to the headquarters. The rescuers equipped with smart phones can construct an opportunistic networks based on WiFi. At the beginning of the earthquake, all the rescuers would try to send the information of the disaster situation to the headquarters as early as possible. Also, each mobile node may be both a sender and receiver. All of these will result in a large number of data flows that may overburden the limited bandwidth and buffer space of mobile nodes. To cope with such a disaster scenario, we need to design a WiFi-based routing protocol for the resources-constrained opportunistic networks. Usually information sharing in wireless mobile environment is achieved by the method of information diffusion. SVSS was introduced in our previous work [8] in order to make up for the lack of broken-point continuingly-transferring file transfer mechanisms to support for third party. The SVSS can increase the packet forwarding of network, balance the energy consumption of mobile phones, and get more data transmission practical in mobile opportunistic network. But in a disaster scenario, disaster information needs to be timely convergence. Moreover, rescuers are often facing harsh natural conditions, and mobile nodes they equipped maybe receive and forward large amount of data in a very short time. Therefore, we propose a WiFi-based routing protocol for resource-constrained opportunistic networks, which aims to maximize the message delivery probability in the case of limited bandwidth and buffer space. The main contributions of this paper are summarized as follows: • We propose the formula to calculate the prediction of the future meeting between two nodes as the next hop routing decision based on WiFi for opportunistic networks, in which the average prediction of probability value is used to maximize the delivery probability. • In order to improve the efficient of resource-constrained node’s buffer space, we propose the buffer management strategy which contains scheduling policy and drop policy. The proposed scheduling policy aims to improve message delivery of high priority, while the proposed drop policy focuses on improving the efficiency of buffer space. • We implement our protocol in Android testbed based on WiFi and obtain significant performance in term of message forwarding in opportunistic networks. The remainder of the paper is organized as follows: In Section 2, we introduce the system model. The proposed delivery prediction of all nodes is described in Section 3. Section 4 presents D. Liu et al. / Journal of Information & Computational Science 12:2 (2015) 787–796 789 the buffer management strategy which contains scheduling policy and drop policy, and the testbed and performance evaluation are discussed in Section 5. Finally, we conclude the paper in Section 6. 2 System Model An opportunistic network can be represented as G(V, E, D), where V = {v1 , v2 , · · · , vm |m ∈ N } is a finite set of mobile nodes, vm ∈ V denotes any node in the network, and the number of node m = |V |; E = {(vi , vj )|vi , vj ∈ V } is a finite set of links between nodes, vj is in the transmission range of vi , and vice versa, one link (vi , vj ) can be simply represented as eij ; D = {dij |i, j ∈ m} is a set of delivery probability between nodes, dij represents the delivery probability when a message moves from node vi to node vj , among in the set D, any link between two nodes, eij ∈ V , corresponds to a delivery rate dij ∈ D. We assume that the transmission range of each node is R. Given any two nodes vi and vj , let (vix , viy ) and (vjx , vjy ) represent coordinate position of two nodes, respectively. They can communicate with each other at time t only if their geographical locations are within the transmission range. So, the Euclidean Distance between vi and vj is dij (t) at time t, which is described as follows: q dij (t) = (vix − vjx )2 + (viy − vjy )2 . (1) In order to determine whether two nodes can communicate, we define the formula as follows: ( 1 when x 6 R, Cp = (2) 0 when otherwise, where Cp represents the result of the judgment. If Cp is 1, it indicates that the two nodes can communicate. Otherwise, if Cp is 0, two nodes can not perceive each other. ij We define the meeting duration time tij md (s) of node vi and node vj . tmd (s) can be calculated according to the formula as follows: ij ij tij md (s) = te (s) − ts (s), (3) where tij s (s) represents the start time between two nodes vi and vj when they first come within their transmission range, and tij e (s) represents the end time between two nodes vi and vj when they depart their transmission range. The start time and end time can be calculated according to the formulas (4) and (5), respectively. ij tij s (s) = min{di,j 6 R, t>te (s − 1)}, (4) where tij e (s − 1) represents the last depart time of nodes i and j. ij tij e (s) = min{di,j > R, t>ts (s)}. 3 (5) Delivery Prediction Suppose there are four nodes A, B, C and D, and A wants to send messages to D. B and C are all within A’s transmission range. In traditional WiFi communication, A can not broadcast the 790 D. Liu et al. / Journal of Information & Computational Science 12:2 (2015) 787–796 messages to B and C at the same time. So A can only use a transmission manner similar to the “Three Handshakes” in internet. If A forwards messages to B firstly, then C can only choose to wait, and vice versa. In Fig. 1 (a), A decides to send messages to B at time t1 . At time t2 when B encounters D, and forwards messages to D directly (Fig. 1 (b)). This indicates that the process of message forwarding is end. On the other hand, as shown in Fig. 1 (c), if A forwards messages to C firstly, we can see that D will not receive the message in the next time (Fig. 1 (d)). B B A A A A C C C C B D D (a) t1 B D D (b) t2 (c) t3 (d) t4 Fig. 1: Message delivery in opportunistic network based on WiFi From Fig. 1 we can see that, due to the randomness of node mobility in opportunistic networks, the message should be delivered by the node which has a greater probability of hit the target node. In this paper, we use the prediction of the future meeting between two nodes as the next hop routing decision. In opportunistic networks, as mentioned in the system model of Section 2, each node record the meeting duration time between itself and all the other nodes. Because the two nodes may encounter many times, so the set of meeting duration time between node i and j can be described as follows: i,j i,j i,j mdti,j = {mdti,j 1 , mdt2 , mdt3 , ..., mdtn }, (6) where mdti,j represents total meeting duration time between node i and j, and an element of the set mdti,j represents one meeting duration time between two nodes which can be calculated by the formula (3). When vi and vj encounter, they will all calculate the new meeting duration time with each other, and add it into their set of meeting duration time. After that, if node vi needs to send messages to the destination node vs , it will forward the messages to the node which is in its transmission range and has a greater probability value of hitting the target node vs . The prediction of probability value between node vi and vj can be calculated by the formula as follows: n i,j mdt 4 1X = mdti,j k . n k=1 (7) Buffer Management Strategy Designing an efficient strategy of buffer management is also the main issue in opportunistic networks. In critical scenarios, the network will generate a large number of data flows that may overburden the limited bandwidth and buffer space of mobile nodes. But the current situation D. Liu et al. / Journal of Information & Computational Science 12:2 (2015) 787–796 791 is that the traditional store-carry-and-f orward mechanism may easily make node’s buffer fully used and drop some important messages. Therefore, it is necessary to design an efficient buffer management strategy which can provide fewer drops of important messages and high delivery probability. 4.1 Scheduling Policy In order to build the proposed scheduling and drop policies, we introduced the following message properties in Table 1. For one node, F T is introduced in order to record the forwarding times of message in the network, and it is one part of node attributes. Suppose that after node A forwarding message i to node B, F Ti of node B is inherited from node A, then F Tb,i ← F Ta,i , and F Ta,i ← F Ta,i + 1. If node C and B come within their transmission range, and C does not have message i, they will update F Tb,i and F Tc,i as follows: F Tc,i ← F Tb,i , F Tb,i ← F Tb,i + 1. Table 1: Message properties notation Properties Description T T Li Initial Time To Live for message i T Ei Time of Entering queue for message i RTi Remaining Time To Live for message i Ti = T T Li - RTi Elapsed Time for message i F Ti Forwarding Times of message i Scheduling policy reassigns the priorities for each message and determines which messages should be transmitted when two nodes need to exchange messages. Our scheduling policy depends a lot on the incoming traffic queue, which considers the priority class of a message and its F T , RT and T E. The attribute of each message is represented as: M essagei (P Li , F Ti , RTi , T Ei ), where P Li denotes the priority class of a message i. We define that a priority with a smaller number has a higher priority than a priority with a larger number. In the process of scheduling, the message with the highest priority in incoming message queue is scheduled first. If two messages have the same priority level, then the message with smaller F T will be scheduled first. If the P L and F T of two messages are the same, the scheduling policy will sequentially compare the RT and T E of the messages, and then determine which one should be firstly scheduled. In summary, the scheduling order is P L >F T >RT >T E. As shown in Fig. 2, suppose there are 8 messages in incoming message queue of one node. In traditional scheduling, all the messages will be scheduled following by F IF O (First Input First Output). In our proposed scheduling policy, message 8 with the higher P L and smallest F T is scheduled first. Then message 7 is scheduled subsequently. As message 1’s T E is shorter than that of message 4, message 1 is scheduled after message 7. The remaining messages are also scheduled according to this policy. So the dispatching order of 8 messages is: 8 → 7 → 1 → 4 → 3 → 6 → 2 → 5. 792 D. Liu et al. / Journal of Information & Computational Science 12:2 (2015) 787–796 (PL, FT, RT, TE) Receiving message Forwarding message 1 (1, 12, 1800, 5) 2 (2, 15, 3000, 12) 3 (2, 5, 1800, 13) 4 (1, 12, 1800, 10) 5 (2, 15, 3000, 16) 6 (2, 8, 2200, 1) 7 (1, 12, 1000, 8) 8 (1, 6, 1000, 3) Incoming message queue 8 (1, 6, 1000, 3) 7 (1, 12, 1000, 8) 1 (1, 12, 1800, 5) 4 (1, 12, 1800, 10) 3 (2, 5, 1800, 13) 6 (2, 8, 2200, 1) 2 (2, 15, 3000, 12) 5 (2, 15, 3000, 16) Transmitting queue Fig. 2: An example of use of the scheduling policy 4.2 New Drop Policy Drop policy decides which messages should be dropped when a node exhausts all available storage. Under a disaster scenario, the traditional store-carry-and-f orward mechanism may easily make one node’s buffer fully used, so the node needs to drop some messages in its buffer. We propose a new drop policy which is based on the optimal drop policy [5], and can optimize the average delivery delay for Delay Tolerant Networks. The optimal drop policy aims at minimizing the average delivery delay of all messages, which uses the following utility for each message i: mi (Ti ) ´ 1 ³ , (8) 1− L−1 ni Ti 2 λ where L is the number of nodes in opportunistic networks. mi (Ti ) and ni (Ti ) are the number of nodes (excluding source) that have seen message i since its creation until elapsed time Ti and number of copies of message i in the network after elapsed time Ti , respectively. λ is the meeting rate between two nodes under the given mobility model, λ= 1 , E[U ] (9) where E[U ] is the average meeting time. In this paper, we use the Random W aypoint (RW P ) mobility model [6]. So λ can be calculated by the following formula: E[U ]rwp = 1 N (T + T stop ), pm verwp + 2(1 − pm ) 2KL (10) where N , K, verwp , L, T and T stop represent the size of network area, the transmission range, the average node speed, the expected epoch length, the expected epoch duration and the average pause time after an epoch, respectively. When buffer overflow happens, the optimal drop policy drops the message with the smallest value calculated by formula (8). But mi (Ti ) and ni (Ti ) in formula (8) are also global variables which each nodes can hardly get. In order to facilitate the calculation, we try to replace both mi (Ti ) and ni (Ti ) with F Ti . Then we can get an approximate result of drop value as follows: F Ti ´ 1 ³ 1 − . (11) L−1 Ti 2 λ D. Liu et al. / Journal of Information & Computational Science 12:2 (2015) 787–796 793 Otherwise, taking into account the importance of different messages in a real disaster scenario, for example, messages of the staff emergency is more important than messages of the extent of damaged houses, we divide the messages into two priority classes: 1 presents an emergency message, 2 presents a normal message, and class 1’s level is higher than class 2’s level. So formula (11) with priority classes can be described as follows: Di = 1 1 ³ F Ti ´ , +α 1 − P Li L−1 F Ti 2 λ (12) where Di is the drop value of message i, message with smallest Di in node’s buffer will be dropped first, P Li = 1 or 2 represents the priority classes of message i, and α is a control parameter. 5 Experiment Configurations and Results To evaluate our proposed opportunistic networks routing protocol based on WiFi, we illustrate the effectiveness of ONRWF by comparing it with the traditional WiFi and our proposed SVSS in previous work. We will also analyze the effects of network with the three performance metrics: delivery ratio, average energy consumption and average queue length. 5.1 Experiment Configurations • Mobility model and topology. To describe the characteristics of the movement of nodes in mobile environment, mobility models are defined and studied as a critical part in the research of wireless networks. However, a majority of mobility models are commonly defined by hypothesis and they can not reflect how mobile nodes really move. In order to reflect the relatively movement of hosts in opportunistic networks, we attempt to get truthful data in real life situations. The scenarios include dormitories, university library and buildings, where the students equipped with smart phones can move optionally in accordance with the Random Waypoint (RWP) mobility model. The topology includes 50 students equipped with smart phones randomly placed in an area of 2000 m by 2000 m of Shaanxi Normal University (SNNU). The students move at 0-1.5 m/s speed optionally according to the RWP mobility model during the period of 20 minutes, and the pause interval is 10 seconds. In our evaluation, we perform experiments on an Android testbed. All the smart phones install the ONRWF protocol that we implemented and use Android (2.3) as their operating systems. Considering the gap between the theoretical transmission speed and the actual transmission speed of WiFi, we set the message size to 100 KB. • Experiment settings. We use two different real scenarios to verify the ONRWF and compare with conventional WiFi and SVSS in transmission performance. One is “multi-source with the same priority messages” which has 6 smart phones only with the same priority messages. The other one is “multi-source with multi-priority messages” where there are 3 smart phones with priority 1 messages and 3 smart phones with priority 2 messages. With the elapse of the time, messages spread in the network, and this experiment is based on the two different real scenarios and aims at getting high spread performance in size per unit time. 794 D. Liu et al. / Journal of Information & Computational Science 12:2 (2015) 787–796 5.2 Experiment Results By analyzing the following performance metrics of opportunistic networks, our research attempts to evaluate the routing performance between WiFi, SVSS and ONRWF. • Delivery ratio. The delivery ratio is the ratio of the number of successfully delivered messages to the number of all the generated messages, reflecting the degree of successfully received messages in networks. Fig. 3 (a) and (b) respectively show the delivery ratio performance under “multi-source with the same priority messages” and “multi-source with multi-priority messages” background cases. From the experiment results, it is obvious that the ONRWF shows a good performance in delivery ratio. In Fig. 3 (a) we can see, the delivery ratio of SVSS and ONRWF are much higher than WiFi. The main reason is that the SVSS and ONRWF can provide more powerful broken-point continuingly-transferring mechanism to support for third party, by which more smart phones can receive the data from source phones. The details can be found in our previous work [8]. Fig. 3 (b) shows the delivery ratio performance of priority 1 message under “multi-source with multi-priority messages” background case. Due to the proposed scheduling policy which schedules high priority messages preferentially, the delivery ratio performance of ONRWF achieves the highest delivery ratio, even much higher than WiFi and SVSS. 0.6 0.5 0.7 WiFi SVSS ONRWF Delivery ratio (%) Delivery ratio (%) 0.7 0.4 0.3 0.2 0.1 0 240 360 480 600 720 840 Times (s) (a) 960 1080 1200 0.6 0.5 WiFi SVSS ONRWF 0.4 0.3 0.2 0.1 0 240 360 480 600 720 840 Times (s) (b) 960 1080 1200 Fig. 3: Comparison chart of delivery ratio under (a) “multi-source with the same priority messages” and (b) “multi-source with multi-priority messages” scenarios • Average energy consumption. We observe from Fig. 4 (a) and (b) that the ONRWF has less battery consumption compared to WiFi and SVSS at a given time, e.g., 1200 seconds. Before the experiment, all 50 smart phones are fully charged. During the experiment, the battery states are recorded by the batteryM anager class. If we look at the battery levels when the message transmission is completed, we see that the battery consumption levels of WiFi, SVSS and ONRWF are similar. But ONRWF can bring lower energy consumption in mobile environment. The main reason is that ONRWF can provide more powerful broken-point continuingly-transferring mechanism to support for third party, just like SVSS. Moreover, the efficient routing mechanism and buffer management strategy of ONRWF can bring lower message loss rate, thereby increase the life cycle of the network. • Average queue length. Fig. 5 shows the average queue length performance under “multisource with multi-priority messages” at 840 seconds during the experiment. We observe that the ONRWF provides a good data reception performance of messages with high priority. The longer queue length of high priority messages in buffer indicates that network has better storage and transmission performance. We provide excellent buffer management strategy of ONRWF, which 400 350 300 Energy consumption (mAh) Energy consumption (mAh) D. Liu et al. / Journal of Information & Computational Science 12:2 (2015) 787–796 WiFi SVSS ONRWF 250 200 150 100 50 0 120 240 360 480 600 720 840 Times (s) (a) 960 1080 1200 400 350 300 795 WiFi SVSS ONRWF 250 200 150 100 50 0 120 240 360 480 600 720 840 Times (s) (b) 960 1080 1200 Fig. 4: Comparison chart of average energy consumption under (a) “multi-source with the same priority Data in transmitting quue (kb) messages” and (b) “multi-source with multi-priority messages” scenarios 180000 160000 140000 120000 100000 80000 60000 40000 20000 0 Class 2 message Class 1 message WiFi SVSS Routing mechanism ONRWF Fig. 5: The average queue length performance under “multi-source with multi-priority messages” at 840 seconds during the experiment can significantly improve the data reception performance in mobile environment. 6 Conclusions In this paper, we designed, implemented and evaluated a novel routing protocol based on WiFi for opportunistic networks, namely ONRWF, which aims to make up for the lack of bandwidth and buffer space. We proposed the formula to calculate the prediction of the future meeting between two nodes as the next hop routing decision, in which the average prediction of probability value is used to maximize the delivery probability. In order to improve the efficiency of resourceconstrained node’s buffer space, we proposed the buffer management strategy which contains scheduling policy and drop policy. The proposed scheduling policy aims to improve message delivery of high priority, while the proposed drop policy focuses on improving the efficiency of buffer space. Finally, we conduct the experiment in the real world to verify the effectiveness of the proposed routing protocol. 796 D. Liu et al. / Journal of Information & Computational Science 12:2 (2015) 787–796 References [1] Marco Conti, Mohan Kumar, Opportunities in opportunistic computing [J], Computer, 43(1), 2010, 42-50 [2] Chungming Huang, Kunchan Lan, Changzhou Tsai, A survey of opportunistic networks [C], in: Proceedings of the 22nd International Conference on Advanced Information Networking and Applications Advanced Information Networking and Applications (AINA’08), Singapore, 2008, 16721677 [3] Honglong Chen, Wei Lou, GAR: Group aware cooperative routing protocol for resource-constraint opportunistic networks [J], Computer Communications, Vol. 48, 2014, 20-29 [4] Kwangcheol Shin, Kyungjun Kim, Soontae Kim, Traffic management strategy for Delay-tolerant Networks [J], Journal of Network and Computer Applications, 35(6), 2012, 1762-1770 [5] Amir Krifa, Chadi Barakat, Thrasyvoulos Spyropoulos, An optimal joint scheduling and drop policy for Delay Tolerant Networks [C], in: Proceedings of the World of Wireless, Mobile and Multimedia Networks (WoWMoM), 2008, 1-6 [6] Thrasyvoulos Spyropoulos, Konstantinos Psounis, Cauligi S. Raghavendra, Performance analysis of mobility-assisted routing [C], in: Proceedings of the 7th ACM Interational Symposium on Mobile Ad Hoc Networking and Computing, MobiHoc 2006, Florence, Italy, May 22-25, 2006 [7] Lijun Tang, Yi Chai, Yun Li, Binbin Weng, Buffer management policies in opportunistic networks [J], Journal of Computational Information Systems, 8(12), 2012, 5149-5159 [8] Ding Liu, Xiaoming Wang, Junling Lu, Yufei Gao, Shared video on-demand streaming ststem in practical WiFi-based for mobile opportunistic networks [J], Jorunal of Computational Information Systems, 10(16), 2014, 6891-6901 [9] Qilie Liu, Guangde Li, Yun Li, Zhihui Zhang, Cache scheduling policy for opportunistic networks based on message priority [J], Journal of Information and Computational Science, 10(2), 2013, 621-632 [10] Abraham Mart´ın-Campillo, Ramon Mart´ı, Energy-efficient forwarding mechanism for wireless opportunistic networks in emergency scenarios [J], Computer Communications, 35(14), 2012, 17151724 [11] Haythem Ahmad Bany Salameh, Resource management with probabilistic performance guarantees in opportunistic networks [J], AEU-International Journal of Electronics and Communications, 67(7), 2013, 632-636 [12] Maziar Nekovee, Radhika S. Saksena, Simulations of large-scale WiFi-based wireless networks: Interdisciplinary challenges and applications [J], Future Generation Computer Systems, 26(3), 2010, 514-520 [13] S. Chieochan, E. Hossain, Network coding for unicast in a WiFi hotspot: Promises, challenges, and testbed implementation [J], Computer Networks, 56(12), 2012, 2963-2980 [14] Zhaolong Ning, Qingyang Song, Yang Huang, Lei Guo, A channel estimation based opportunistic scheduling scheme in wireless bidirectional networks [J], Journal of Network and Computer Applications, 39, 2014, 61-69 [15] Na Li, Sajal K. Das, A trust-based framework for data forwarding in opportunistic networks [J], Ad Hoc Networks, 11(4), 2013, 1497-1509