Cayley: A Robust Overlay with Simple Routing and Small-World Features for Wireless Sensor Networks

Cayley: A Robust Overlay with Simple Routing and Small-World Features for Wireless Sensor Networks

Available online at www.sciencedirect.com Available online at www.sciencedirect.com Procedia Engineering Procedia Engineering 00 (2011) 000–000 Proc...

386KB Sizes 0 Downloads 25 Views

Available online at www.sciencedirect.com Available online at www.sciencedirect.com

Procedia Engineering

Procedia Engineering 00 (2011) 000–000 Procedia Engineering 15 (2011) 3008 – 3016 www.elsevier.com/locate/procedia

Advanced in Control Engineering and Information Science

Cayley: A Robust Overlay with Simple Routing and SmallWorld Features for Wireless Sensor Networks Wenjun Xiaoa ∗ , Yunyan Xionga,b and Huomin Lianga b

a School of Software Engineering, South China University of Technology, Guangzhou 510641, P. R. China Depart of Computer Scinece,Guangdong Vocaltional College of Industry and commerce, Guangzhou 510510, P. R. China

Abstract Efficient data processing techniques are needed in Wireless Sensor Networks (WSNs) to handle issues related to limited resources, e.g. energy, memory, bandwidth, as well as limited connectivity. Self-organizing and cooperative algorithms are thought to be the optimal solution to overcome these limitations. In this paper, we present the Virtual Cayley Protocol , a virtual relative position based efficient routing protocol that also provides means for data operation, e.g. insert, get, and delete, as known from typical Distributed Hash Table (DHT) services. The key contributions of this protocol are independence of real location information by relying on relative positions of neighboring nodes, short virtual paths because direct neighbors are in their vicinity, and high scalability because only information about direct neighbors is needed for routing. Furthermore, Cayley inherently prevents dead-ends and it is easy to be implemented. Cayley is a generalization of the Virtual Cord Protocol (VCP) and has more robust and efficient routing.

© 2011 Published by Elsevier Ltd. Selection and/or peer-review under responsibility of [CEIS 2011] Keywords: P2P; Sensor network; Small world; Cayley graph; Overlay; Searching;

1. Introduction Wireless Sensor Networks (WSNs) provide an interesting research field because they represent a class of massively distributed systems in which nodes are required to work in a cooperative and self-organized fashion to overcome scalability problems [1, 2]. Additionally, WSNs are facing strong resource

* Corresponding author. Tel.: +0-000-000-0000 ; fax: +0-000-000-0000 . E-mail address: [email protected].

1877-7058 © 2011 Published by Elsevier Ltd. doi:10.1016/j.proeng.2011.08.565

Wenjun XiaoXiao et al. Procedia Engineering 1500 (2011) 3008 – 3016 Wenjun et /al/ Procedia Engineering (2011) 000–000

2

limitations as a large number of sensor nodes with CPU, energy, and bandwidth restrictions need to be operated to build stable and operational networks. This includes the need to solve problems with high dynamics introduced by joining and leaving nodes. As of today, WSNs are used in a wide range of applications such as wildlife monitoring, disaster prediction and management [2, 3]. In many cases the produced sensor data is enormous, thus an efficient data management is essential. Distributed Hash Tables (DHTs) [4] ensure O(1) complexity to insert and lookup data items. Moreover they work in a distributed and self-organized manner. These characteristics make them attractive for use in WSNs. The main idea is simple: Data items are associated with numbers and each node in the network is responsible for a range of these numbers. Therefore, it is easy to find the node at which a data item is stored. Usually, DHTs are built on the application layer and rely on an underlying routing protocol that provides connectivity between the nodes. Systems like Chord [5], Pastry [6], and CAN [7] have been implemented to work on the Internet. The nodes communicate taking advantage of the already existing routing protocols on the Internet. Implementing DHTs in WSNs as an overlay and relying on typical Mobile Ad Hoc Network(MANET) routing protocols [8] (best known examples are DSR [9], DSDV [10], or AODV [11]) has the drawback that these routing protocols already need to maintain globally valid topology information of the entire network [12, 13]. This cannot scale well because additional overhead is needed to maintain the overlay. In addition, the DHTs have not been designed to take advantage of physically neighboring nodes. On the other hand, routing protocols that use geographic location like Greedy Perimeter Stateless Routing (GPSR) [14] and Geographic Routing Without Location Information (GRWLI) [15] can scale well. Unfortunately, obtaining the location is not only costly and susceptible to localization errors, but also is not always available and greedy forwarding cannot guarantee reachability of all destinations because of possible dead ends [16]. This paper presents the Virtual Cayley Protocol, a DHT-like protocol that offers in addition to standard DHT functions (e.g., insert, get, and delete) and more efficient routing mechanism than VCP [17]. The key important characteristics of this protocol besides the efficient routing are: • The exact physical location is not required, which can be expensive in terms of communication or system requirements. Instead, we use an easy-to-be-obtained relative position. • Cayley is scalable because it only needs information about direct neighbors for routing. • Greedy routing on the cayley always leads to a path to the destination (it cannot suffer from packets getting stuck in dead-ends). • The protocol is easy to be implemented on top of the MAC layer. The rest of the paper is organized as follows. In Section 2, we outline relevant related work. In Section 3, an overview to the working principles of our Virtual Cayley Protocol is presented. Afterwards, the implementation and selected evaluation results are presented in Section 4. Finally, Section 5 concludes the paper. 2. Related work [14-15, 18-22] Omitted. 3. Virtual Cayley Protocol We shall use Cayley Graph Γ as the range of data items. The definition of Γ and related terminology are presented in this section. Definition 1. Let G = Z 2q ⊗ Z q , that is, G is the semi-direct product of the commutative group of order

2q and the cyclic group of order q. We have

3009

3010

Wenjun Xiao / Procedia Engineering 15 (2011) 3008 – 3016 Wenjun Xiao et et al/al. Procedia Engineering 00 (2011) 000–000

Proposition 1. G is a group. Given any 〈c, r〉 ∈ G, we refer to c ∈ Z 2q as group identifier (column number in diagrams), r ∈ Z q as region identifier (row number in diagrams), and 〈c, r〉 as vertex identifier. In order to define Γ, a subset S of G should be specified. Let q−1 q−2 q− 2 Sc = {〈1,0 , 0〉, 〈0,1,0 , 0〉, 〈1,1,0 , 0〉} q Sr = {〈0 , γ〉 | γ = ±1 } Definition 2. Let S = Sc ∪ Sr, where Sc and Sr are as defined above. The graph Γ = Cay(G, S) is a Cayley graph defined on G and S. The graph Γ is a 5-regular graph and the diameter of Γ is less than or equal to 5q/2. We now define a sorting order for the identifiers 〈c1, r1〉 and 〈c2, r2〉 by setting 〈c1, r1〉 < 〈c2, r2〉 when c1 < c2 or when c1 = c2 and r1 < r2. In order to distribute the hash table items among peers, data items and search keywords are hashed to two-component keys 〈α, γ〉, where α is a fixed-length string and γ ∈ Zq. Actually, the identifier space for keys coincides with the identifier space for vertices in Γ. The real network location of a data item, that is the value associated with the key having hash key 〈α, γ〉, is at a peer 〈c, γ〉 such that 〈α, γ〉 belongs to the q–l zone VSet(c, γ) of responsibility of 〈c, γ〉. Here, c0c1…cl-1 is a prefix of α when c = c0c1…cl-1* for some q–l q–l integer l and VSet(c, γ) = {〈c0c1…cl-1* , γ〉}, with |VSet(c, γ)| = 2 , as the zone of responsibility for the peer 〈c, γ〉, where c must be with the (prefix) substring c0c1…cl-1 followed by an arbitrary string of 0s and 1s of length q – l. As stated previously, Virtual Cayley Protocol is a DHT-like protocol. All data items are associated q with numbers in a pre-determined range [ψψ2 q − 1 ] and the available nodes (peers) capture this range. Thus, each peer captures a part of the entire range.

3.1. Joining operation We employ hello messages to discover the network structure, i.e. all neighboring nodes and their position in the Cayley. In the current implementation of Cayley, the hello messages are transmitted by means of broadcasting, i.e. each node broadcasts a hello every ψψseconds. Basically, the joining operation can also be executed using an on-demand mechanism, which has advantages in static networks or those with a high density. Based on the hello messages, the joining node gets information about its physical neighbors and their adjacent peers. The first node is pre-programmed with the smallest value of l q −l the entire range ( (0 * ,0) , for “ψ”). The second node joining the network gets the larger number of l q−l this range ( (0 * ,1) , for “ψ”). The basic join algorithm is shown in Algorithm 1. The joining of a new peer P1 proceeds in four phases: finding its network location, updating identifiers, updating routing tables, and updating the distributed hash table. Input: None

Output: Identifier 〈c1, r1〉 of the new joining peer P1, its routing table, and its hash table Assumption: Each peer knows 〈c2, r2〉, the identifier of peer P2 with the largest identifier currently in use 1 Assign P1 to the identifier 〈c1, r1〉 which is the next larger after 〈c2, r2〉 2 if 〈c2, r2〉 is connected to 〈c1, r1〉 then 3 add P1’s routing table to those of all its neighbors 4 augment the routing table of P1 from the routing tables of all its neighbors 5 add the hash table of P1 6 endif

3

Wenjun XiaoXiao et al. Procedia Engineering 1500 (2011) 3008 – 3016 Wenjun et /al/ Procedia Engineering (2011) 000–000

4

Algorithm 1. Joining of a new peer in Cayley

Each further node joining the network has to received at least with one hello message from a node that already exist in the network to get a relative position, i.e. its value, in the Cayley.

3.2. Routing There are two objectives for routing in Cayley. One is to find a peer with a given identifier and the other is to locate a given hash key. However, the two can be reduced into one problem. If the identifier of a peer is viewed as a hash key, then the peer would be responsible for its identifier. Therefore, the routing problem is actually to find a path to a peer that is responsible for a given identifier (i.e. identifier of a peer or hash key of a data item). Algorithm 2 “corrects” one bit of the difference between source and destination identifiers in each step. Note that Algorithm 2 does not guarantee that the routing path is a shortest one. In fact, the path may first go to 〈c1, 0〉 from the current peer having the identifier 〈c1, r1〉. q–l

Inputs: Identifier of the current peer 〈c1, r1〉, with c1 = x0x1…xl-1* item 〈α, γ〉, with α = y0y1…yl–1 . . . yq-1 Output: Identifier of the next-hop vertex 〈c2, r2〉 1 if (x0 x1…xl-1 = y0y1…yl-1∧ γ= r1) then 2 the destination has been reached 3 else if (x0 x1…xl-1 = y0y1…yl-1) then 4 if 〈c1, γ〉 is faulty then 5 the destination is temporarily inaccessible 6 else set 〈c2, r2〉 := 〈c1, r2 +1〉 7 endif 8 else 9 set i = r1 ; 10 if (xi ≠ yi) then q–l 11 set 〈c2, r2〉 := 〈x0...xi-1yixi+1...xq-1* , r1〉 12 else set < c2 , r2 >=< c1 , i + 1 > 13 endif 14 endif 15 endif

, and destination identifier or hash key of a data

Algorithm 2. Routing in Cayley.

For routing, each node has to know its virtual as well as the physical neighbors. Then a greedy algorithm is employed to send packets to the node of the physical neighbors that has the closest position to the destination until there is no more progress. Cayley inherently relies on a previously established join algorithm. Therefore, greedy routing will always lead to a path to the destination – it is not possible to run into a dead end. Additionally, Cayley allows to take shortcuts whenever a physical neighbor with a virtual number is available that is closer to the destination. 4. Performance Evaluation In this section, a number of important performance metrics are derived using system simulation. The obtained results are described, following a review of metrics and model.

3011

3012

Wenjun Xiao / Procedia Engineering 15 (2011) 3008 – 3016 Wenjun Xiao et et al/al. Procedia Engineering 00 (2011) 000–000

4.1. Metrics and System Model The performance metrics used in our evaluation include: 1) Query path length; 2) Routing table size; 3) Robustness; 4) The fraction of intragroup neighbors (FIN); 5) Small-world features [23]. The same set of system parameters is used for all experiments: q = 16 and l = 4, 5, 6, 7, 8. A Cayley topology with a specified number of peers is first constructed using the joining process of Algorithm 1. After finishing the topology construction, no peer will join in or leave the system during the evaluation process. Then, the average size of routing table, FIN, and the clustering coefficient of the constructed network are calculated. In Section 4.2, we assume that the system is reliable, which means that no faulty peers exist in the network. In Section 4.4, all faulty peers are generated in the previously constructed network, before robustness evaluation starts. In the latter two sections, two peers are randomly selected, and the routing scheme of Algorithm 2 is applied to find out how many logical hops are required to route from one peer to another.

4.2. Query Path Length Figure 3 plots the average query path length of Cayley as a function of the number of peers. A particular type of simulation is used to evaluate this metric, which aims at finding the number of hops in the routing path between two randomly selected peers. The simulation is run for a network size varying from 256 to about 4K. We can see from Figure 3 that when the number of peers in Cayley reaches 4K, the average query path length is still less than 11. However, the average query path length in VCP [17] is more than that of Cayley.

Average routing path length

14 12 10 8 6 4

Cayley

2

VCP

0 256

512

1K

2K

4K

Number of peers in the network

Figure 3. Average routing path length in Cayley networks of different sizes compared with routing path length for VCP.

5

Wenjun XiaoXiao et al. Procedia Engineering 1500 (2011) 3008 – 3016 Wenjun et /al/ Procedia Engineering (2011) 000–000

6

4.3. Size of Routing Table Figure 4 plots the average routing table size in networks of different sizes.

Average routing table size

14

Cayley

12

VCP

10 8 6 4 2 0 256

512

1K

2K

4K

Number of peers in the network Figure 4. The size of routing table in Cayley networks of different sizes compared with the size of routing table for VCP.

4.4. Robustness In this section, we compute the probability that a query ends in failure, as well as the average length of a successful routing path when different fractions of peers fail in Cayley. All simulation runs are performed for a network with 4K peers. The probability that a peer fails is varied from 5% to 20%. One thousand test cases are run for each failure probability. Figure 5 plots the probability that routing ends in failure as a function of the peer failure probability. For the same peer failure percentage, the probability that the Cayley routing algorithm ends in failure is lower than in VCP. For example, when 20% of the peers fail in a network, Cayley has a failure probability of about 55%, and 70% in VCP [17].

Probability that a query fails

1 0.9 0.8 0.7 0.6 0.5

Cayley VCP

0.4 0.3 0.2 0.1 0 0

5%

10%

15%

Probability that a peer fails Figure 5. The probability that routing ends in failure as a function of peer failure probability.

20%

3013

3014

Average length of successful routing

Wenjun Xiao / Procedia Engineering 15 (2011) 3008 – 3016 Wenjun Xiao et et al/al. Procedia Engineering 00 (2011) 000–000

13 12

Cayley

11

VCP

10 9 8 7 6 5 4 0

5%

10%

15%

20%

Probability that a peer fails

Figure 6. The average path length for successful queries as a function of peer failure probability.

The query path length would inevitably increase when a query encounters a faulty peer on its way to the destination. Figure 6 plots the average number of hops required for successful routing in the presence of different fractions of failed peers. The flatness of the curve in Figure 6 indicates that routing length is minimally influenced by faulty peers. For example, the average length of routing path is 5 with no faulty peers. When the percentage of faulty peers becomes as high as 20%, average routing path length in Cayley increases by 30%, reaching 8. However, average routing path length in VCP increases by 100%, reaching 12.

4.5. The Fraction of Intragroup Neighbors

Fraction of Intragroup neighbors

Figure 7 plots the average fraction of intragroup neighbors in networks of different sizes. We can see from Figure 7 that the fraction of intragroup neighbors in Cayley is higher than that in VCP as the network size grows, because the fraction of intragroup neighbors in VCP is near zero. 0.7 0.65 0.6 0.55 0.5 Cayley

0.45 0.4 256

512

1K

2K

Number of peers in the network Figure 7. Fraction of intragroup neighbors as a function of network size for Cayley.

4K

7

Wenjun XiaoXiao et al. Procedia Engineering 1500 (2011) 3008 – 3016 Wenjun et /al/ Procedia Engineering (2011) 000–000

8

Clustering coefficient

4.6. Small-World Features 0.5 0.45 0.4 0.35 0.3 0.25 0.2 0.15 0.1 0.05 0

Cayley

256

512

1K

2K

4K

Number of peers in the network Figure 8. The clustering coefficient for Cayley

The topology of Cayley captures the link structure of Γ, so it also inherits its small-world properties. Figure 8 plots the clustering coefficient of Cayley [23]. Figure 8 clearly shows that Cayley is highly clustered, because its clustering coefficient is very large compared with that of random graph. Note that the clustering of VCP is very close to zero, so that they are indistinguishable in Figure 8. 5. Conclusion Cayley is a new DHT-like protocol that is based on virtual relative positions for routing. It offers traditional DHT services as well as efficient packet routing. As VCP [17], Cayley has the attractive characteristics as stated in the introduction. In this paper, we studied the performance of Cayley for different scenarios. We showed that the path length is almost optimal and greedy forwarding guarantees packet delivery. Additionally, there is no extra delay needed before packet forwarding. Therefore,− Cayley represents a promising technique. however more investigation is needed to explore the Performance of the protocol in different environments. Future work on Cayley includes further research on handling of node failures and data aggregation in sensor networks. Acknowledgements This work has been supported by the Natural Science Foundation of China (60973150) and the Guangdong Laboratory for Software and Application Technologies (2006B80407001). References [1] I. F. Akyildiz, W. Su, Y. Sankarasubramaniam, and E. Cayirci. Wireless sensor networks: a survey. Elsevier Computer Networks, 38:393–422, 2002. [2] D. Culler, D. Estrin, and M. B. Srivastava. Overview of Sensor Networks. Computer, 37(8):41–49, August 2004.

3015

3016

Wenjun Xiao et al. / Procedia Engineering 15 (2011) 3008 – 3016 Wenjun Xiao et al/ Procedia Engineering 00 (2011) 000–000

[3] D. Estrin, D. Culler, K. Pister, and G. S. Sukhatme. Connecting the Physical World with Pervasive Networks. IEEE Pervasive Computing, 1(1):59–69, January 2002. [4] R. Steinmetz and K. Wehrle, editors. Peer-to-Peer Systems and Applications, volume LNCS 3485. Springer, 2005. [5] I. Stoica, R. Morris, D. Liben-Nowell, D. R. Karger, F. Kaashoek, F. Dabek, and H. Balakrishnan. Chord: A Scalable Peerto-Peer Lookup Protocol for Internet Applications. IEEE/ACM Transactions on Networking (TON), 11(1):17– 32, February 2003. [6] A. Rowstron and P. Druschel. Pastry: Scalable, distributed object location and routing for large-scale peer-to-peer systems. In IFIP/ACMInternational Conference on Distributed Systems Platforms (Middleware), pages 329–350, Heidelberg, Germany, November 2001. [7] S. Ratnasamy, P. Francis, M. Handley, R. Karp, and S. Shenker. A Scalable Content-Addressable Network. In ACM SIGCOMM 2001, pages 161–172, San Diego, CA, USA, 2001. [8] K. Akkaya and M. Younis. A Survey of Routing Protocols in Wireless Sensor Networks. Elsevier Ad Hoc Networks, 3(3):325–349, 2005. [9] D. B. Johnson and D. A. Maltz. Dynamic Source Routing in Ad Hoc Wireless Networks. In T. Imielinski and H. F. Korth, editors, Mobile Computing, volume 353, pages 152– 181. Kluwer Academic Publishers, 1996. [10] C. E. Perkins and P. Bhagwat. Highly Dynamic Destination- Sequenced Distance-Vector Routing (DSDV) for Mobile Computers. Computer Communications Review, pages 234– 244, 1994. [11] C. E. Perkins and E.M. Royer. Ad hoc On-Demand Distance Vector Routing. In 2nd IEEE Workshop on Mobile Computing Systems and Applications, pages 90–100, New Orleans, LA, February 1999. [12] I. Chakeres and C. Perkins. Dynamic MANET On-Demand (DYMO) Routing. Internet-Draft (work in progress) draft-ietfmanet-dymo-10.txt, July 2007. [13] C. Sommer, I. Dietrich, and F. Dressler. A Simulation Model of DYMO for Ad Hoc Routing in OMNeT++. In 1st ACM/ICST International Conference on Simulation Tools and Techniques for Communications, Networks and Systems (SIMUTools 2008): 1st ACM/ICST International Workshop on OMNeT++ (OMNeT++ 2008), Marseille, France, March 2008. ACM. [14] B. Karp and H. T. Kung. GPSR: Greedy Perimeter Stateless Routing for Wireless Networks. In 6th ACM International Conference on Mobile Computing and Networking (ACM MobiCom 2000), pages 243–254, Boston, Massachusetts, USA, 2000. [15] A. Rao, S. Ratnasamy, C. Papadimitriou, S. Shenker, and I. Stoica. Geographic Routing without Location Information. In 9th ACM International Conference on Mobile Computing and Networking (ACM MobiCom 2003), San Diego, CA, USA, September 2003. [16] M. Mauve and J. Widmer. A Survey on Position-Based Routing in Mobile Ad-Hoc Networks. IEEE Network, 15(6):30–39, 2001. [17] A. Awad, R. German, and F. Dressler. P2P-based Routing and Data Management using the Virtual Cord Protocol (VCP). In 9th ACM International Symposium on Mobile Ad Hoc Networking and Computing (ACM Mobihoc 2008), Poster Session, pages 443–444, Hong Kong, China, May 2008. ACM. [18] S. Ratnasamy, B. Karp, S. Shenker, D. Estrin, R. Govindan, L. Yin, and F. Yu. Data-Centric Storage in Sensornets with GHT, a Geographic Hash Table. ACM/Springer Mobile Networks and Applications (MONET), Special Issue onWireless Sensor Networks, 8(4):427–442, August 2003. [19] S. Ratnasamy, B. Karp, L. Yin, F. Yu, D. Estrin, R. Govindan, and S. Shenker. GHT: A Geographic Hash Table for DataCentric Storage. In 1st ACM International Workshop on Wireless Sensor Networks and Applications (WSNA2002), Atlanta, Georgia, September 2002. [20] K. Liu and N. Abu-Ghazaleh. Aligned Virtual Coordinates for Greedy Routing in WSNs. In 3rd IEEE International Conference on Mobile Ad Hoc and Sensor Systems (IEEE MASS 2006), pages 377–386, Vancouver, Canada, October 2006. IEEE. [21] M. Caesar, M. Castro, E. B. Nightingale, G. O’Shea, and A. Rowstron. Virtual Ring Routing: Network routing inspired by DHTs. In SIGCOMM 2006, Pisa, Italy, September 2006. [22] Y. Zhao, Y. Chen, B. Li, and Q. Zhang. Hop ID: A Virtual Coordinate-Based Routing for Sparse Mobile Ad Hoc Networks. IEEE Transactions on Mobile Computing, 6(9):1075–1089, September 2007. [23] W. Xiao and B. Parhami, Cayley Graph as Models of Deterministic Small-World Networks, Information Processing Letters, (97:3): 115-117, 2006.

9