The dramatic growth of numerous internet-connected smart devices and frequent service requests generated by the users poses a heavy burden to the network bandwidth. Fog computing provides potential benefits for the IoT applications such as smart electrical grids, smart traffic light systems, and smart transportation. It has the potential to support the different innovative applications involve smart cities, smart switching systems, and smart home appliances. In the example of smart home appliances, if the sensors embedded in the home appliances detect anomalies, the home appliances send an automatic alert to the respective person.