| About the Author |
|
xiii | |
| About the Technical Reviewer |
|
xv | |
| Acknowledgments |
|
xvii | |
| Introduction |
|
xix | |
|
Chapter 1 The Internet of Things and Data |
|
|
1 | (28) |
|
|
|
2 | (9) |
|
IOT Is More Than Just Connected to the Internet |
|
|
3 | (3) |
|
|
|
6 | (1) |
|
|
|
7 | (4) |
|
|
|
11 | (5) |
|
IOT Predictions: Data Overload? |
|
|
16 | (4) |
|
|
|
16 | (3) |
|
|
|
19 | (1) |
|
|
|
20 | (8) |
|
|
|
23 | (2) |
|
|
|
25 | (3) |
|
|
|
28 | (1) |
|
Chapter 2 Hardware for IOT Solutions |
|
|
29 | (50) |
|
|
|
29 | (33) |
|
|
|
30 | (1) |
|
|
|
31 | (5) |
|
|
|
36 | (9) |
|
|
|
45 | (7) |
|
Additional Arduino Hardware |
|
|
52 | (10) |
|
Low-Powered Computing Platforms |
|
|
62 | (10) |
|
|
|
63 | (3) |
|
|
|
66 | (6) |
|
|
|
72 | (5) |
|
|
|
73 | (1) |
|
|
|
73 | (1) |
|
|
|
74 | (1) |
|
|
|
74 | (3) |
|
|
|
77 | (1) |
|
|
|
78 | (1) |
|
Chapter 3 How IOT Data Is Stored |
|
|
79 | (22) |
|
|
|
80 | (2) |
|
|
|
81 | (1) |
|
Data Collectors with Storage |
|
|
81 | (1) |
|
|
|
81 | (1) |
|
|
|
81 | (1) |
|
|
|
82 | (1) |
|
|
|
82 | (8) |
|
Local Storage on the Raspberry Pi |
|
|
83 | (2) |
|
Local Storage on the Arduino |
|
|
85 | (5) |
|
Passing the Buck to Aggregators |
|
|
90 | (2) |
|
|
|
92 | (4) |
|
|
|
93 | (1) |
|
|
|
94 | (1) |
|
|
|
95 | (1) |
|
Distributed IOT Network Best Practices |
|
|
96 | (3) |
|
|
|
96 | (1) |
|
|
|
97 | (2) |
|
|
|
99 | (1) |
|
|
|
99 | (2) |
|
Chapter 4 Data Transformation |
|
|
101 | (40) |
|
|
|
102 | (4) |
|
|
|
102 | (1) |
|
Is There Another Way to Make the Observation? |
|
|
102 | (1) |
|
How Often Do You Need to Record the Observation? |
|
|
103 | (1) |
|
What Type of Data Does the Sensor Produce? |
|
|
104 | (1) |
|
Are There Interpretations Needed for the Observation Data? |
|
|
104 | (1) |
|
What Level of Accuracy Do You Need? |
|
|
105 | (1) |
|
What Is the Lifetime of the Data? |
|
|
105 | (1) |
|
|
|
106 | (28) |
|
Recording the Sensor Name or Adding Notes |
|
|
107 | (3) |
|
Recording the Date and Time |
|
|
110 | (6) |
|
Data Type Transformations |
|
|
116 | (7) |
|
Adding Derived or Calculated Data |
|
|
123 | (7) |
|
|
|
130 | (4) |
|
|
|
134 | (6) |
|
Data from Multiple Sensors |
|
|
134 | (3) |
|
|
|
137 | (2) |
|
|
|
139 | (1) |
|
|
|
140 | (1) |
|
|
|
141 | (54) |
|
|
|
141 | (16) |
|
|
|
142 | (2) |
|
How to Get and Install MySQL |
|
|
144 | (13) |
|
How Data Is Stored and Retrieved |
|
|
157 | (7) |
|
How and Where MySQL Stores Data |
|
|
158 | (6) |
|
Common MySQL Commands and Concepts |
|
|
164 | (12) |
|
|
|
164 | (7) |
|
|
|
171 | (5) |
|
Planning Database Storage for IOT Data |
|
|
176 | (17) |
|
Example 1 Plant-Monitoring System |
|
|
176 | (15) |
|
Recommendations and Best Practices |
|
|
191 | (2) |
|
|
|
193 | (2) |
|
Chapter 6 Building Low-Cost MySQL Data Nodes |
|
|
195 | (56) |
|
Introducing the Raspberry Pi |
|
|
195 | (11) |
|
|
|
197 | (1) |
|
|
|
198 | (2) |
|
|
|
200 | (1) |
|
|
|
201 | (1) |
|
|
|
202 | (1) |
|
|
|
203 | (3) |
|
|
|
206 | (9) |
|
Choosing a Boot Image (Operating System) |
|
|
206 | (6) |
|
|
|
212 | (3) |
|
MySQL Installation and Setup |
|
|
215 | (10) |
|
Partitioning and Formatting the Drive |
|
|
216 | (2) |
|
Setting Up Automatic Drive Mounting |
|
|
218 | (2) |
|
|
|
220 | (5) |
|
|
|
225 | (5) |
|
|
|
225 | (1) |
|
|
|
226 | (1) |
|
|
|
227 | (3) |
|
MySQL Clients: How to Connect and Save Data |
|
|
230 | (1) |
|
Introducing Connector/Arduino |
|
|
230 | (19) |
|
Introducing Connector/Python |
|
|
242 | (7) |
|
|
|
249 | (2) |
|
Chapter 7 High Availability IOT Solutions |
|
|
251 | (22) |
|
What Is High Availability? |
|
|
251 | (2) |
|
High Availability Options for IOT Solutions with MySQL |
|
|
253 | (3) |
|
|
|
253 | (1) |
|
|
|
254 | (1) |
|
|
|
255 | (1) |
|
|
|
255 | (1) |
|
High Availability Techniques |
|
|
256 | (15) |
|
|
|
256 | (8) |
|
|
|
264 | (6) |
|
Fault Tolerance in IOT Nodes |
|
|
270 | (1) |
|
|
|
271 | (2) |
|
Chapter 8 Demonstration of High Availability Techniques |
|
|
273 | (38) |
|
MySQL Replication Techniques |
|
|
273 | (18) |
|
|
|
274 | (2) |
|
Advanced Replication with Global Transaction Identifiers |
|
|
276 | (6) |
|
Replication and Database Maintenance Tips |
|
|
282 | (3) |
|
Example: Scaling Applications |
|
|
285 | (6) |
|
High Availability IOT Nodes |
|
|
291 | (19) |
|
Example: Redundant Data Collectors |
|
|
291 | (9) |
|
Example: Fault-Tolerant Data Collector |
|
|
300 | (10) |
|
|
|
310 | (1) |
| Index |
|
311 | |