On Alleviating Starvation in Wireless Sensor Networks
Yang-Sheng Chen, Yu-Shiang Wong, and Der-Jiunn Deng+ Department of Computer Science and Information Engineering
National Changhua University of Education Changhua, Taiwan, R.O.C
[email protected], [email protected], [email protected]
Jiann-Liang Chen
Department of Electrical Engineering National Taiwan University of Science and
Technology Taipei, Taiwan, R.O.C [email protected]
Abstract—Current medium access control (MAC) protocols for wireless sensor networks (WSNs) do not support prioritized channel access and often suffer from varying degrees of starvation and fairness problems. That is, with a little bad luck, a sensor node might have to wait arbitrarily long to send its frame, and thus results in the invisibility of some sensed area. In this paper we introduce a simple, but yet well performing starvation-free backoff scheme based on sensor MAC (S-MAC) protocol for WSNs. The proposed scheme allows a sensor node to adjust its backoff window size according to its re-transmission times. An analytical analysis is carried out to study the saturation throughput of proposed scheme under backlogged conditions. In addition to the theoretical analysis, simulations were also conducted to analyze the proposed scheme and the results show that our scheme can effectively alleviate the starvation and fairness problem and achieve better performance in high density WSNs.
Keywords: S-MAC, WSNs, starvation, backoff, priority I. INTRODUCTION
In recent years, the rapid growing of embedded systems and memory technique leads to the vigorous development of wireless sensor networks (WSNs). The core idea of wireless sensor networks is deploying a large number of small-sized sensors to collaboratively monitor physical and environment conditions. Generally, sensor nodes are operated with limited power and cooperated in unstable environment. Hence, in WSNs, the MAC protocol is the key component that provides the efficiency in sharing the common radio channel while satisfying the fairness requirements for each sensor node.
In the literatures there have been adequate discussions about the performance of various MAC protocols for WSNs.
Ye et al. [1] proposed a Sensor MAC (S-MAC) based on IEEE 802.11 protocol, which significant reduced power consumption by adding periodic sleep mechanism. S-MAC employs periodically relative synchronization by broadcasting next sleeping time of sensor nodes periodically and choosing large slot time to provide robustness when topology changes or clock drifts.
Due to the active time of sensor nodes in S-MAC is fixed, the energy efficiency of S-MAC is not satisfied. Hence, Tijs and Koen [2] proposed a Timeout MAC (T-MAC), which uses adaptive scheme to force a sensor node to enter sleeping mode when a sensor node is idle and channel is busy in active
stage. T-MAC improves the performance of S-MAC in terms of energy efficiency but the adaptive scheme also causes early sleeping problems.
To achieve better energy efficiency, there are many extended versions of S-MAC have been proposed. In [3] and [4], a dynamic control active time mechanism has been proposed to provide more efficient energy usage. In [5], the authors proposed a Berkeley-MAC (B-MAC) which attempts to use hardware technique, such as lower power listening (LSL) and clear channel assessment (CCA) to improve its power consumption. In [6], the authors pointed out that Z-MAC [7], a hybrid TDMA and CSMA/CA Z-MAC protocol for WSNs, can achieve better performance than the B-MAC, but the robustness of network could be another problem.
Although the aforementioned works achieve better performance than S-MAC, these approaches are not satisfactory since they did not take into account the fairness and starvation problems. Furthermore, many previous works, e.g. [1] and [2], choose to burst transmit its frames in order to get shorter transmission latency. However, this makes starvation problem worse because sensor nodes may face high contention from neighboring nodes. In [6], the authors mentioned that the fairness and starvation problems may cause significant parts of the network to be invisible, in that nodes sensing events in such areas are starved, and hence the sink never detects events from these areas.
Please note that fairness problem usually come with starvation of sensor nodes, but essentially they are different, as starvation is induced by a bad luck sensor node which always chooses a relatively large backoff number, and therefore this sensor node might have to wait arbitrarily long to send its frame. Binary Exponential Backoff (BEB) algorithm, the defacto standard contention resolution algorithm for wireless local area networks (WLANs) might lead to a fairness problem as well because BEB algorithm always favors the last successfully transmitted node.
In fact, the backoff algorithm of S-MAC is different from standard BEB algotithm. S-MAC uses fixed contention windows size and S-MAC does not freeze its timer if the channel becomes busy before time out. Hence, S-MAC eliminates the fairness problems but aggravates the starvation problem since a bad luck node may always choose a relatively large contention window size for each transmission. In [8],
+Correspondence: Der-Jiunn Deng
The work of this paper was partially sponsored by ROC NSC under Contract 97-2221-E-018-020-MY3
Chunsheng et al. proposed a modified backoff algorithm to improve the funneling effect of S-MAC. However, it does not take into account the starvation problem either.
In this paper, we introduce a simple but yet well performing backoff algorithm with the view of alleviating starvation problem for sensor nodes in high density WSNs.
Besides, it can eliminate fairness problem in a partially connected network topology. An analytical analysis is carried out to study the system saturation throughput of the proposed scheme. In addition, we also carried out comprehensive simulations to evaluate its performance. Compared with the S-MAC, the simulation results show that the proposed scheme can effectively reduce the fairness problem and achieve higher system throughput and lower blocking rate in high density WSNs.
The remainder of this paper is outlined as follows. In section 2, we describe proposed scheme and its numerical analysis in detail. Section 3 provides simulation results of proposed scheme comparing with S-MAC. Section 4 concludes this paper
II. PROPOSED SCHEME AND ITS NUMERICAL ANALYSIS
In this section we introduce the proposed scheme and its saturation throughput analysis.
A. Proposed Scheme
As we mention above, the S-MAC protocol suffers from the starvation problem and it lack of any priority scheme to cope with various type of multimedia traffic. Hence, we propose a backward compatible priority enforcement mechanism, thereby making the proposed scheme compliant sensor nodes to coexist with S-MAC enabled sensor nodes.
The basic idea behind our method is that the prioritized access to the wireless channel is provided by allowing shorter contention window size for sensor nodes with re-transmitted frame.
To support priority, we slightly decrease the size of initial contention windows for high priority sensor nodes. That is, when consecutive collision or frame lost happened, a sensor node will decrease both lower bound and upper bound of its backoff number for next transmission in order to obtain higher priority and avoid starvation. In addition, we define a resend time threshold so that a sensor node experienced consecutive collision or frame lost can access the wireless channel fast.
Hence, by using the sliding backoff window mechanism, the more re-transmission times a sensor node experienced, the higher priority this sensor node will get. Consequently, after a successful transmission, a sensor node has to concede the bandwidth to the retransmission nodes to avoid possible starvation caused to these sensor nodes. Please note that we still keep large contention windows size for both collided and non-collided nodes to reduce the collision rate.
The following pseudo code describes the proposed scheme.
Assume the retry limit, m , large or equal than four and small or equal than thirty two, the initial contention window size, W, large than thirty two, and the parameter eifs , W', and φ
represent small reserve space, sliding contention windows size, and retry limit threshold respectively.
B. Packet Transmission Probability
In this section, we present an analytical model that accurately evaluates the saturation throughput of proposed scheme. In our analysis, we assume that all nodes are deployed by random manner and located in a single-hop network.
According to our assumption and the feature of S-MAC [1], all sensor nodes have the same sleep schedule and within the same virtual cluster. Before we start to discuss our analysis, important notations and variables are define in Table 1, and they will be used throughout this paper.
TABLE I. VARIABLE USED IN ANALYTICAL ANALYSIS
Variables Meaning and explanation
W Contention window size
W Average contention window size
pf Probability of transmission failure
p Transmission probability
Ldata Data packet size
Lack ACK packet size
Algorithm Function Backoff
Initialization:
if ACK frame received then resend times =0 else // transmission fail
until no more frame to transmit end
() 2 2
eifs i Rand × W′+eifs− × ⎢ ⎥⎢ ⎥⎣ ⎦
Variables Meaning and explanation
P s Probability of a successful transmission
P I Probability of idle channel
P c Probability of a collided transmission
P err Probability of a transmission errors
m Retry limit
em Extended retransmission limit
eifs Extended interframe space
φ Resend time threshold
W ′ Sliding contention window size
n Number of sensor nodes
Ts Duration of a success transmission time
T I Duration of idle channel
Tc Duration of a collided transmission
T err Duration of a transmission error
frame
T Length of time frame
BER Channel bit error rate
σ Duration of time slot
Now let us try to calculate the average contention window size. According to the assumption and definition in section 2.1, both lower bound and upper bound of the random backoff number will decrease after a transmission failure, and we assume the geometric distributed random variable is used to choose the random backoff number. Hence, the average contention window size is
1
Herep is the probability of a transmission failure. f
In the beginning of an active period, a sensor node starts to transmit a frame with probability p , and defers the transmission with probability1−p. According to probability theory, the probability that there are x failures of transmission before the first success can be calculate as
( ) (1 )x1 , 1
P X =x = −p − p ≤ ≤ ∞ x (2) Hence, the average contention window size, W , is completely identified by the value of p, and thus we have
1 1
By solving the above equation, we get:
2
However, the probabilityp is still unknown. Since the f probability of transmission failure is defined as the probability that a transmitted frame collided or received with error, we have
1 (1 )n1 (1 )
f e
p = − −p − × −p (6)
Here pe is the probability that data frame error or ACK frame error consecutively occurred when transmitting a data frame. Since both lost of data or ACK frame will cause ACK timeout and force sender to immediately resend the data frame until it exceeds the extended retransmission limit or receive a ACK frame successfully, we can express pe as the summation of probability that data or ACK frame error happened consecutively. Hence, we have
( )( ) ( )
retransmission limit, the probability of data frame received with error, and the probability of ACK frame received with error. Thus, we have:1 (1 )Ldata
C. Saturation throughput analysis
Since the saturation throughput is defined as a relation of successfully transmitted payload size over a randomly chosen time slot in the active stage [9], the system saturation throughput can be defined as follows:
s data
I I s s c c err err
S P L
P T P T P T P T
= + + + (10)
According to the equation above, the successful transmission probability, P , is defined as the system s transmitted a data packet without collision or bit error. Hence we can express P as s
(1 )n 1(1 )
s e
P =np − p − − p (11)
Let P denote the probability that no sensor node try to I send data in a time frame, and P denote the probability that a c collision occurs in a time frame. Hence, they can be express as:
(1 )n
Let Perr denote the probability that a transmission errors occurs on a data frame or ACK frame, and then sender give up its transmission, i.e.,
(1 )n1
err e
P =np − p − p (14)
According to the periodic sleep mechanism in S-MAC, the time frame,Tframe, equal to the summation of listening time and sleeping time. Assume ST is the time needed for a successfully transmission. Therefore, we can define its values as follows:
3
DIFS CW RTS SIFS CTS SIFS data SIFS ack
DIFS CW RTS CTS data SIFS ack
ST T T T T T T T T T
T T T T T T T
= + + + + + + + +
= + + + + + + (15)
Where TDIFS, TCW, TRTS, TCTS, TSIFS, Tdata and Tack are the DIFS time, average contention window, transmitting time of a RTS packet, transmitting time of a CTS packet, a SIFS time, a data transmission time, and the transmission time of a ACK frame respectively. Since TIis the duration of channel idle, we have:
TI =σ (16)
Let RT stand for the remaining sleep time after a successfully transmission, which equal to the time between a successful transmitted ACK frame and the next awake time of sender node. Hence, we have:
Ts =ST+RT (17)
Because the collision could only happen with RTS packet, and sensor nodes would go to sleep after collision occurs, we can express T as: c
c DIFS CW RTS
T =T +T +T +RT (18)
According to S-MAC protocol, when data or ACK error occurs, sender will immediately retransmit its data. Hence, the penalty of transmission error will equal to a frame time. Thus, it follows that
err frame
T =T (19)
Hence, we can findT , s T , and c Terr are all equal to Tframe. Owing to the summation of Perrdata,Perrdata,P ,S P and C P equal to I 1, we can substitute Tframe into the equation (10), and then the system saturation throughput can be computed as follows:
S
( )
s data
frame I frame I
P L
T P T T
= − − (20)
III. SIMULATIONS AND PERFORMANCE EVALUATION
In this section, we evaluate the performance of the proposed scheme and provide a head-to-head comparison with S-MAC protocol.
A. Simulation Environment
Our simulation model is built using the Network Simulator version 2 (NS-2), and each simulation runs at least for 1000 simulation seconds. To focus on the access control issues and to reduce the complexity of simulations, we modified the original S-MAC NS-2 modules as following:
• We change the predefine value of maximum neighboring number, synchronization table, and the size of synchronization contention window in order to simulate high density environments.
• We use static routing and random topology in our simulation to focus on access control issues.
• All sensor nodes could communicate with each other in a single-hop coverage area.
• We implemented the proposed starvation-free backoff algorithm.
The evaluation was made with respect to the system saturation throughput and blocking rate under different offered duty cycle or number of sensor nodes. The default values used in the simulations are list in Table 2. The values for the simulation parameters are chosen carefully in order to closely reflect the realistic environments as well as to make the simulation feasible and reasonable.
TABLE II. DEFAULT ATTRIBUTE VALUES USED IN THE SIMULATION WITH EXPLANATION
Attribute Meaning and Explanation Value
β Radio bandwidth 20 kbps
L ctr Length of control packet 10 bytes
MAC header
L − Length of MAC header 10bytes
payload
L MAC layer payload size 50bytes
W Initial contention window size 63 WSYNC Contention window size for SYNC
frame 63
'
W Sliding contention window size 55
m Retry limit 5
em Extended retransmission limit 5
eifs Extended interframe Space 8 time slots
DC Duty cycle 10% to 90%
TDIFS DIFS time 5 ms
TSIFS SIFS time 5 ms
Tslot Slot time 1 ms
δ Propagation delay 5 us
B. Simulations Result
Fig. 1 compares the system throughput obtained from the proposed scheme with the S-MAC protocol. In this scenario there are fifteen sensor nodes within the simulation environment. As shown in the figure, the proposed scheme can provide a better performance in most cases. Besides, as we expected, when the duty cycle (the ratio of active time divided sleep time) increases, the system throughput increases linearly.
Fig. 2 depicts the system throughput as the number of sensor nodes increases when the duty cycle is 10 %. In general, for both scheme, the system throughput deteriorates as the number of sensor nodes increase. We can see there is not much difference in the values of the performance measures between two schemes in low density environment. However, as shown in figure 3, the proposed scheme obviously outperforms the S-MAC protocol in high density environment.
Fig. 3 shows the effect of number of sensor nodes by plotting the blocking rate of data frame. Note that the blocking rate of S-MAC protocol dramatically increase when the number of sensor nodes larger than 30 in contrast to the smoothness of the proposed scheme. Therefore, this result is evidence that the proposed scheme can effectively avoid starvation problem especially when the system becomes congested. It also reveals that the proposed scheme could avoid starvation problem without sacrificing the overall system performance.
0.2
Duty Cycle (%)
Proposed scheme simulation S-MAC simulation
Figure 1. Throughput versus duty cycle
0.15
Number of nodes
Proposed scheme S-MAC
Figure 2. Throughput versus number of sensor nodes
0
Number of nodes
Proposed scheme S-MAC
Figure 3. Blocking rate versus number of sensor nodes
IV. CONCLUSION
In this paper, we proposed a pragmatic starvation-free bakeoff algorithm based on S-MAC protocol for WSNs and the analytical model has also been conducted to study system throughput. Through extensive simulations, we have demonstrated quantitatively the effectiveness of our proposed scheme, and it offers a remarkable performance improvement in high density WSNs.
In our future work, we will extend our scheme to support for multimedia transmission and compare with other random access MAC protocols.
REFERENCES
[1] W. Ye, J. Heidemann, and D. Estrin, "Medium access control with coordinated adaptive sleeping for wireless sensor networks."
Networking, IEEE/ACM Transactions on, Volume 12, Issue 3, pp. 493- 506, June 2004.
[2] T. v. Dam, and K. Langendoen, "An Adaptive Energy-Efficient MAC Protocol for Wireless Sensor Networks.” Proceedings of the 1st international conference on Embedded networked sensor systems, Los Angeles, California, USA, pp. 171-180, November 05 - 07, 2003.
[3] P. Lin, C. Qiao, and X. Wang, "Medium access control with a dynamic duty cycle for sensor networks." Wireless Communications and Networking Conference, 2004. WCNC. 2004 IEEE , vol.3, no., pp.
1534- 1539 Vol.3, 21-25 March 2004.
[4] S.H. Yang, H.W. Tseng, E.H.-K. Wu, and G.H. Chen, "Utilization based duty cycle tuning MAC protocol for wireless sensor networks,"
Global Telecommunications Conference, 2005. GLOBECOM '05. IEEE, vol.6, no., pp.5 pp.-3262, 2-2 Dec. 2005.
[5] K. Fakih, J. F. Diouris, and G. Andrieux, "BMAC: Beamformed MAC protocol with channel tracker in MANET using smart antennas."
Wireless Technology, 2006. The 9th European Conference on , vol., no., pp.185-188, 10-12 Sept. 2006.
[6] A. Warrier, J. Min, and I. Rhee, "Mitigating Starvation in Wireless Sensor Networks," Military Communications Conference, 2006.
MILCOM 2006. IEEE, vol., no., pp.1-5, 23-25 Oct. 2006.
[7] I. Rhee, A. Warrier, M. Aia, and M. Jeongki, "Z-MAC: A Hybrid MAC for Wireless Sensor Networks." Networking, IEEE/ACM Transactions on, vol.16, no.3, pp.511-524, June 2008.
[8] C. Zhu, Y. Chen, L. Wang, L. Shu, and Y. Zhang, "SMAC-based proportional fairness backoff scheme in wireless sensor networks."
Proceedings of the 6th International Wireless Communications and Mobile Computing Conference, Caen, France, pp. 138-142 ,2010.
[9] Q. Ni, T. Li, T. Turletti, and Y. Xiao, “Saturation throughput analysis of error-prone 802.11 wireless networks,” Wireless Commun. and Mobile Computing, vol. 5, no. 8, pp. 945-956, Nov. 2005.