"The average person checks his phone 110 times a DAY"
Well, if this number indicates something, it’s how much we’ve become dependent on our beloved smartphones to survive through a day. The reason? Mobile Applications, obviously. Whether you’re an “iCustomer”, an “Androider” or an ever-loyal Windows fan, various services are being easily provided to you by your corresponding app store: from the most interesting and useful, to the most silly and time-wasting. In fact, the past few years witnessed an explosive growth of mobile applications that’s not going to stop anytime soon. Mobile computing largely developed in a relatively short time, and is still developing by the hour after becoming one of the most trending topics in the IT world, and also one of the most lucrative businesses. However, all of the computation your smartphone is struggling to achieve is crazily draining the battery, overwhelming the bandwidth and consuming what’s left from the poor storage space. No matter how smart it may seem, your phone is still after all a device with limited resources.
On the other hand, the tech world also witnessed in the past few years the rise of the so-called Cloud. Cloud computing revolves mainly around the concept that a user has access to computing resources on-demand and without the need for their physical presence at his location. A service provider, like Google or Amazon, provides servers, storages, operating systems, applications and much more for the user to access via internet, at a low cost. Seeing its many benefits, Cloud Computing quickly became a very attractive option.
What now? Merge the two concepts, you get Mobile Cloud Computing!
Integration of Cloud Computing into the mobile environment seemed to be an obvious solution to the many mobile computation bottlenecks. The Cloud is a place of plentiful resources that can ensure huge computations quickly and accurately, without exhausting the limited mobile phone resources from energy to processing capability. The main idea is to benefit from the many services provided by the cloud, and enhance the performance of the mobile applications, by offloading the computation workload to the Cloud. Many Mobile Cloud Computing technologies emerged in the past few years. One of them is CloneCloud, a technology from Intel Research, developped by Byung-Gon Chun and Petros Maniatishave.
CloneCloud consists of off-loading some tasks from your mobile to the cloud, where they will be executed in a cloned image of the system of your device.
A "copy" of your smartphone is first made in the cloud-computing world on distant server(s). Processes will be sent via your high speed smartphone connectivity (Wifi, 3G, 4G) to the distant servers to be executed there instead of local execution on the phone. The results will be reintegrated to the smartphone upon completion in a fraction of the time. This concept transforms a single-machine execution to a distributed execution.
Clonecloud functions can be classified into five features:
The partitioning in CloneCloud has to choose which parts of the execution to run on the mobile device, and which ones should be sent to the cloud.
The partitioning of the service between client and server portions is not done statically in the design phase. In CloneCloud, the programmer has no role at all in the application partitioning. Instead, CloneCloud tries to automatically find the right spots in the application where the execution
has to can be partitioned and sent to the cloud.
For this, a partitioning mechanism is applied. The output of this mechanism is a partition, meaning an indication of the execution points where the application has to transfer part of its execution and state to the clone. Depending on the expected workload and the execution conditions (like CPU speed, and energy consumption), the partitioning decision could result in having different amounts of the original application planned to be executed at the cloud. The partitioning mechanism also tries to obtain the partitions that are optimal regarding execution time and energy consumption. Therefore, it is run several times with different conditions at each run. All the yielded partitions are stored in one database. At run time, the execution picks one partition from the stored ones, and sends it to the Cloud.
Technically speaking, the partitioning framework has three components: static analyzer, dynamic profiler and optimization solver. The static analyzer performs static analysis in order to find the constraints. The dynamic profiler tries to build the cost model for execution and migration under different partitions. This cost model is the result of profiling the executable on the mobile device as well as on the cloud clone. Finally, the optimizer uses the constraints determined by the static analyzer and the cost models of the profiler, in order to derive the best partition.
For more details on each step of the partitioning mechanisms, Check this article from Intel Research.
Note that CloneCloud migration operates using threads. This means a multi-threaded process can still work. Consider that two threads of the same process are running on the mobile device and then one of them is offloaded to the cloud at a certain point. The other thread can proceed with the processing. However, if it also reaches a migration point, it will block until the other thread comes back. For instance, while the worker thread of an application is offloaded to the cloud, the user interface thread of this application can still be running and interacting with the user. There’s no disruption in the processing.
There are 3 components that effectively assure the migration process:
A CloneCloud prototype was created and tested. The prototype runs on Google’s Android mobile with the clones executing on a Dell desktop running Ubuntu. Many applications were used for testing like image search, virus scanner, and privacy-preserving targeted advertising which are all processor, memory and power consuming tasks. The applications were executed on a phone (alone), and with the CloneCloud implementations: one with WiFi connectivity and one with 3G. In general, CloneCloud with Wifi connection gave the best results.
In the following, the first figure represents the results obtained for an image search application with different number of images in each case, and the second shows the results obtained for virus scanning. The plots show mean execution times (1st row) & mean phone energy consumption (2nd row) caused by the apps. Each graph shows three different cases: Phone, CloneCloud with WiFi (CC-WiFi), and CloneCloud with 3G (CC-3G).
I’ll let the graphs speak for themselves about the obvious benefits of CloneCloud and the obvious gain made in processing speed and energy consumption.
Results from image search app
Results from virus scanning app
So CloneCloud seems to be the perfect solution for your smartphone after all... But is it really?
Even though prototypes proved the efficiency of implementing CloneCloud to extend the battery lifetime and achieve faster processing, CloneCloud is not perfect (yet). Many flaws could further cause limitations to this promising technology.
Is it really secure? This question is legitimate here like in all the cloud-based services. Security vulnerabilities could arise in CloneCloud seeing that all of the user’s private data could be cloned into a public server. Using private cloud systems is an option. Moreover, Authentication has to be considered: Immunity against IP spoofing, ARP poisoning, DNS poisoning is a must when exchanging data. On the other hand, Data tampering, Data loss and Data theft are also serious concerns. CloneCloud must prove it is a trust-worthy technology or it is doomed.
Furthermore CloneCloud is highly dependent on the network reliability. Coupling between the mobile and the cloud is done via the internet connection. Network latency and bandwidth limitations are the deciding factors when it comes to suitable tasks for CloneCloud. It is mainly the phone's connection speed that determines what CloneCloud can and cannot achieve. So if you don't have the perfect internet connection, CloneCloud is not for you.
Moreover, this connection must be very reliable in order to assure a flawless information exchange. Hence, mobility can be harmful. If the user is mobile, the connection speed varies when moving through different coverage zones. In the worst case scenario, the connection is cut-off. If this happens, it would lead to severe data losses. If you think about it, it is somehow ironic how mobility could lead to performance degradation, seeing that this method was in the first place implemented for "mobile" devices, we use when we're "mobile"...
From a technical point of view, limitations in CloneCloud reside in the fact that methods that require access to special features in the mobile device like the camera or GPS cannot be offloaded. Well, how many applications not using GPS or camera can you name?
Finally, the (previously mentioned) idea that processing can get blocked if some thread is offloaded is also one of the limitations. In fact as long as the state on the mobile device remains unchanged, and the running thread does not attempt to change it, the thread can run at peace while the other is at the clone. Otherwise, it has to block. There is no full concurrency between the mobile device and clones.
All of these reflections prove that CloneCloud still has many margins for improvement and development while it is still in its prototype phase. Security, latency, connectivity range and Data transfer cost are all important setbacks for this technology to handle in order to prove its efficiency.
One might wonder, what if the battery life, the processing capability and the never-ending relationship between them were dramatically enhanced in smartphones before CloneCloud is fully developed?
With an up to 20 times speedup and 20 times energy reduction for simple applications, and without intervention from the programmer, CloneCloud proves to be a promising, effective technology. It opens up further research opportunities and paves the way for practical deployments on large scales.
Eventually, it seems that our smartphones and their power-hungry applications can finally satisfy their urgent needs from the power of Cloud Computing, the technology that took the world by storm.