Outdoor Distributed Computing* Cristian Borcea Department of Computer Science New Jersey Institute of Technology * Work done at Rutgers prior to September.

Slides:



Advertisements
Similar presentations
Threads, SMP, and Microkernels
Advertisements

Threads, SMP, and Microkernels Chapter 4. Process Resource ownership - process is allocated a virtual address space to hold the process image Scheduling/execution-
Using DSVM to Implement a Distributed File System Ramon Lawrence Dept. of Computer Science
Adapting Asynchronous Messaging Middleware to Ad Hoc Networking Mirco Musolesi Cecilia Mascolo Stephen Hailes Dept. of Computer Science University College.
1 Self-Routing in Pervasive Computing Environments using Smart Messages Cristian Borcea, Chalermek Intanagonwiwat, Akhilesh Saxena (Rutgers University),
Beneficial Caching in Mobile Ad Hoc Networks Bin Tang, Samir Das, Himanshu Gupta Computer Science Department Stony Brook University.
Cooperative Computing: A Computing Model for Large Networks of Embedded Systems Cristian Borcea, Phillip Stanley-Marbell, Kiran Nagaraja, Liviu Iftode.
1 Migratory TCP: Connection Migration for Service Continuity in the Internet* Florin Sultan, Kiran Srinivasan, Deepa Iyer, Liviu Iftode Department of Computer.
Turning Ad Hoc Networks into Distributed Service Providers Cristian Borcea Department of Computer Science New Jersey Institute of Technology.
EEC-681/781 Distributed Computing Systems Lecture 3 Wenbing Zhao Department of Electrical and Computer Engineering Cleveland State University
1 Cooperative Computing for Distributed Embedded Systems* Cristian Borcea, Deepa Iyer, Porlin Kang, Akhilesh Saxena, and Liviu Iftode Division of Computer.
Outdoor Distributed Computing Cristian Borcea Department of Computer Science New Jersey Institute of Technology.
Middleware for Cooperative Computing on Large Ad-hoc Networks of Embedded Systems* Cristian Borcea, Deepa Iyer, Porlin Kang, Akhilesh Saxena and Liviu.
Spatial Programming using Smart Messages: Design and Implementation Cristian Borcea, Chalermek Intanagonwiwat, Porlin Kang, Ulrich Kremer, and Liviu Iftode.
Programming Computers Embedded in the Physical World Liviu Iftode, Andrzej Kochut University of Maryland Cristian Borcea, Chalermek Intanagonwiwat, Ulrich.
Tcl Agent : A flexible and secure mobile-agent system Paper by Robert S. Gray Dartmouth College Presented by Vipul Sawhney University of Pennsylvania.
TrafficView: A Driver Assistant Device for Traffic Monitoring based on Car-to-Car Communication Sasan Dashtinezhad, Tamer Nadeem Department of CS, University.
Peer-to-peer file-sharing over mobile ad hoc networks Gang Ding and Bharat Bhargava Department of Computer Sciences Purdue University Pervasive Computing.
DISTRIBUTED PROCESS IMPLEMENTAION BHAVIN KANSARA.
Operating Systems Concepts 1. A Computer Model An operating system has to deal with the fact that a computer is made up of a CPU, random access memory.
Design and Implementation of a Single System Image Operating System for High Performance Computing on Clusters Christine MORIN PARIS project-team, IRISA/INRIA.
Self-Organizing Adaptive Networks Hari Balakrishnan MIT Laboratory for Computer Science
Chapter 3.1:Operating Systems Concepts 1. A Computer Model An operating system has to deal with the fact that a computer is made up of a CPU, random access.
P2P Systems Meet Mobile Computing A Community-Oriented Software Infrastructure for Mobile Social Applications Cristian Borcea *, Adriana Iamnitchi + *
Spatial Approaches to Pervasive Computing Tutorial at IEEE SASO 2008 Jacob Beal (BBN Technologies) Jonathan Bachrach (MIT)
CS 712 | Fall 2007 Using Mobile Relays to Prolong the Lifetime of Wireless Sensor Networks Wei Wang, Vikram Srinivasan, Kee-Chaing Chua. National University.
The MobiSoC Middleware for Mobile Social Computing Cristian Borcea, Ankur Gupta, Achir Kalra, Quentin Jones, Liviu Iftode* Department of Computer Science.
Context-aware Adaptive Routing for Delay Tolerant Networking Mirco Musolesi Joint work with Cecilia Mascolo Department of Computer Science University College.
Chapter 4 Threads, SMP, and Microkernels Patricia Roy Manatee Community College, Venice, FL ©2008, Prentice Hall Operating Systems: Internals and Design.
Rapid Development and Flexible Deployment of Adaptive Wireless Sensor Network Applications Chien-Liang Fok, Gruia-Catalin Roman, Chenyang Lu
Operating Systems ECE344 Ashvin Goel ECE University of Toronto Threads and Processes.
1 Heterogeneity in Multi-Hop Wireless Networks Nitin H. Vaidya University of Illinois at Urbana-Champaign © 2003 Vaidya.
Processes and Threads Processes have two characteristics: – Resource ownership - process includes a virtual address space to hold the process image – Scheduling/execution.
Silberschatz, Galvin and Gagne  Operating System Concepts Chapter 3: Operating-System Structures System Components Operating System Services.
Lecture 3 Process Concepts. What is a Process? A process is the dynamic execution context of an executing program. Several processes may run concurrently,
Heavy and lightweight dynamic network services: challenges and experiments for designing intelligent solutions in evolvable next generation networks Laurent.
Hardware process When the computer is powered up, it begins to execute fetch-execute cycle for the program that is stored in memory at the boot strap entry.
A Cyclic-Executive-Based QoS Guarantee over USB Chih-Yuan Huang,Li-Pin Chang, and Tei-Wei Kuo Department of Computer Science and Information Engineering.
An IP Address Based Caching Scheme for Peer-to-Peer Networks Ronaldo Alves Ferreira Joint work with Ananth Grama and Suresh Jagannathan Department of Computer.
Toward Fault-tolerant P2P Systems: Constructing a Stable Virtual Peer from Multiple Unstable Peers Kota Abe, Tatsuya Ueda (Presenter), Masanori Shikano,
OSes: 3. OS Structs 1 Operating Systems v Objectives –summarise OSes from several perspectives Certificate Program in Software Development CSE-TC and CSIM,
Mobile Agent Migration Problem Yingyue Xu. Energy efficiency requirement of sensor networks Mobile agent computing paradigm Data fusion, distributed processing.
Processes Introduction to Operating Systems: Module 3.
Cache Coherence Protocols 1 Cache Coherence Protocols in Shared Memory Multiprocessors Mehmet Şenvar.
CS533 - Concepts of Operating Systems 1 The Mach System Presented by Catherine Vilhauer.
Middleware Services. Functions of Middleware Encapsulation Protection Concurrent processing Communication Scheduling.
Context-Aware Fault Tolerance in Migratory Services Oriana Riva +, Josiane Nzouonta *, and Cristian Borcea * + ETH Zurich * New Jersey Institute of Technology.
Latency Reduction Techniques for Remote Memory Access in ANEMONE Mark Lewandowski Department of Computer Science Florida State University.
Lecture 5: Threads process as a unit of scheduling and a unit of resource allocation processes vs. threads what to program with threads why use threads.
Distributed System Services Fall 2008 Siva Josyula
Department of Computer Science and Software Engineering
M. Accetta, R. Baron, W. Bolosky, D. Golub, R. Rashid, A. Tevanian, and M. Young MACH: A New Kernel Foundation for UNIX Development Presenter: Wei-Lwun.
Mobile Computing and Wireless Communication Pisa 26 November 2002 Roberto Baldoni University of Roma “La Sapienza”
Introduction Why are virtual machines interesting?
Thread basics. A computer process Every time a program is executed a process is created It is managed via a data structure that keeps all things memory.
Hardware process When the computer is powered up, it begins to execute fetch-execute cycle for the program that is stored in memory at the boot strap entry.
Operating Systems: Summary INF1060: Introduction to Operating Systems and Data Communication.
IHP Im Technologiepark Frankfurt (Oder) Germany IHP Im Technologiepark Frankfurt (Oder) Germany ©
W4118 Operating Systems Instructor: Junfeng Yang.
On Detecting Termination in Cognitive Radio Networks Shantanu Sharma 1 and Awadhesh Kumar Singh 2 1 Ben-Gurion University of the Negev, Israel 2 National.
-1/16- Maximum Battery Life Routing to Support Ubiquitous Mobile Computing in Wireless Ad Hoc Networks C.-K. Toh, Georgia Institute of Technology IEEE.
Introduction to Operating Systems Concepts
File System Implementation
Wireless Sensor Network Architectures
Operating System Structure
Main Memory Management
Introduction to Operating Systems
Threads, SMP, and Microkernels
Virtual Memory: Working Sets
COMP755 Advanced Operating Systems
Presentation transcript:

Outdoor Distributed Computing* Cristian Borcea Department of Computer Science New Jersey Institute of Technology * Work done at Rutgers prior to September 2004

2 Computers Embedded Everywhere

3 Distributed object tracking over a large geographical area Cars collaborating for a safer and more fluid traffic Outdoor Distributed Applications How to write distributed programs over outdoor networks of embedded systems? How to write distributed programs over outdoor networks of embedded systems?

4 Traditional (Indoor) Distributed Computing Commonly, computation is distributed for performance or fault tolerance Commonly, computation is distributed for performance or fault tolerance Relatively easy to program Relatively easy to program –Nodes are computationally equivalent –Networking is robust and has acceptable delays –Configuration is stable

5 Outdoor Distributed Computing Computation is physically distributed Computation is physically distributed –Nodes distributed across the physical space –Location-aware computing Hard to program Hard to program –Nodes are functionally heterogeneous and potentially mobile –Ad hoc wireless networks of embedded systems –Volatile configurations

6 Outdoor Programming Example Left Hill Right Hill Mobile robot with camera Motion Sensor Intrusion detection across the hills using motion sensors and autonomous mobile robots with cameras Intrusion detection across the hills using motion sensors and autonomous mobile robots with cameras Number and location of systems are unknown Number and location of systems are unknown Configuration is not stable over time Configuration is not stable over time –Intrusions can appear randomly –Robots can move

7 Traditional Distributed Computing Does Not Work Well Outdoors End-to-end data transfers may hardly complete End-to-end data transfers may hardly complete Fixed address naming and routing (e.g., IP) are too rigid Fixed address naming and routing (e.g., IP) are too rigid Difficult to deploy new applications in existing networks Difficult to deploy new applications in existing networks Outdoor distributed computing requires novel programming models and system architectures Outdoor distributed computing requires novel programming models and system architectures

8Outline Motivation Motivation Spatial Programming Model Spatial Programming Model Smart Messages System Architecture Smart Messages System Architecture Implementation Details Implementation Details Experimental Results Experimental Results Conclusions Conclusions

9 Traditional (Indoor) Programming Programs access data through variables Programs access data through variables Variables mapped to physical memory locations Variables mapped to physical memory locations Page Table and OS guarantee reference consistency Page Table and OS guarantee reference consistency Access time has an (acceptable) upper bound Access time has an (acceptable) upper bound Program Virtual Address Space Page Table + OS Physical Memory Variable access

10 From Indoor to Outdoor Computing Virtual Address Space Space Region Variables Spatial References Variables mapped to physical memory Spatial references mapped to systems embedded in the physical space Reference consistency Bounded access time ? ?

11 Spatial Programming (SP) at a Glance Provides a virtual name space over outdoor networks of embedded systems Provides a virtual name space over outdoor networks of embedded systems Embedded systems named by their locations and properties Embedded systems named by their locations and properties Runtime system takes care of name resolution, reference consistency, and networking aspects Runtime system takes care of name resolution, reference consistency, and networking aspects Implementation on top of Smart Messages: SP applications execute, sequentially, on each system referenced in their code Implementation on top of Smart Messages: SP applications execute, sequentially, on each system referenced in their code

12 radius Hill = new Space({lat, long}, radius); {lat,long} Space Regions Virtual representation of a physical space Virtual representation of a physical space Similar to a virtual address space in a conventional Similar to a virtual address space in a conventional computer system computer system Defined statically or dynamically Defined statically or dynamically

13 Spatial References Defined as {space:property} pairs Defined as {space:property} pairs Virtual names for embedded systems Virtual names for embedded systems Similar to variables in conventional programming Similar to variables in conventional programming Indexes used to distinguish among similar systems Indexes used to distinguish among similar systems in the same space region in the same space region {Hill:robot[0]} {Hill:robot[1]} {Hill:motion[0]} Hill r2 r7 m5

14 From Indoor to Outdoor Computing Virtual Address Space Space Region Variables Spatial References Variables mapped to physical memory Spatial references mapped to systems embedded in the physical space Reference consistency Bounded access time ? ?

15 Reference Consistency At first access, a spatial reference is mapped to an embedded system located in the specified space At first access, a spatial reference is mapped to an embedded system located in the specified space Mappings maintained in per-application Mapping Table (MT) – similar to a page table Mappings maintained in per-application Mapping Table (MT) – similar to a page table Subsequent accesses to the same spatial reference will reach the same system (using MT) as long as it is located in the same space region Subsequent accesses to the same spatial reference will reach the same system (using MT) as long as it is located in the same space region {space, property, index} {unique_address, location}

16 Reference Consistency Example Left Hill Right Hill {Left_Hill:robot[0]}.move = ON; r2 r7 r5 {Left_Hill:robot[0]}.move = OFF;

17 Space Casting {Left_Hill:robot[0]} Left Hill Right Hill {Right_Hill:(Left_Hill:robot[0])}r7

18 From Indoor to Outdoor Computing Virtual Address Space Space Region Variables Spatial References Variables mapped to physical memory Spatial references mapped to systems embedded in the physical space Reference consistency Bounded access time Mapping Table ?

19 Bounding the Access Time How to bound the time to access a spatial reference? How to bound the time to access a spatial reference? –Systems may move, go out of space, or disappear Solution: associate an explicit timeout with each spatial reference access Solution: associate an explicit timeout with each spatial reference access try{ {Hill:robot[0], timeout}.move = ON; {Hill:robot[0], timeout}.move = ON; }catch(TimeoutException e){ // the programmer decides the next action // the programmer decides the next action}

20 for(i=0; i<1000; i++) for(i=0; i<1000; i++) try{ try{ if ({Left_Hill:motion[i], timeout}.detect > Max_motion) if ({Left_Hill:motion[i], timeout}.detect > Max_motion) Max_motion = {Left_Hill:motion[i], timeout}.detect; Max_motion = {Left_Hill:motion[i], timeout}.detect; Max_id = i; Max_id = i; }catch(TimeoutException e) }catch(TimeoutException e) break; break; intrusionSpace = rangeOf({Left_Hill:motion[Max_id].location}, Range); intrusionSpace = rangeOf({Left_Hill:motion[Max_id].location}, Range); {intrusionSpace:robot[0]}.camera = ON; {intrusionSpace:robot[0]}.camera = ON; {intrusionSpace:robot[0]}.focus = {Left_Hill:motion[Max_id].location}; {intrusionSpace:robot[0]}.focus = {Left_Hill:motion[Max_id].location}; Spatial Programming Example - Find the sensor that detected the “strongest” motion on Left Hill - Turn on a camera in the proximity of this sensor Left Hill Right Hill

21Outline Motivation Motivation Spatial Programming Model Spatial Programming Model Smart Messages System Architecture Smart Messages System Architecture Implementation Details Implementation Details Experimental Results Experimental Results Conclusions Conclusions

22 “Dumb” Messages vs. “Smart” Messages Data migration Lunch: Lunch:AppetizerEntreeDessert Execution migration

23 Smart Messages at a Glance User-defined distributed applications User-defined distributed applications Composed of code bricks, data bricks, and execution control state Composed of code bricks, data bricks, and execution control state Execute on nodes of interest named by properties Execute on nodes of interest named by properties Migrate between nodes of interest Migrate between nodes of interest Self-route at every node in the path during migrations Self-route at every node in the path during migrations

24 Cooperative Node Architecture Network SMPlatform AdmissionManagerAdmissionManager Network SMSM Operating System & I/O CodeCacheCodeCache VirtualMachineVirtualMachine TagSpaceTagSpace SM Ready Queue AuthorizationAuthorization

25 SM Execution at a Node Takes place over a virtual machine Takes place over a virtual machine Non-preemptive, but time bounded Non-preemptive, but time bounded Ends with a migration, or terminates Ends with a migration, or terminates During execution, SMs can During execution, SMs can –Spawn new SMs –Create smaller SMs out of their code and data bricks –Access the tag space –Block on a tag to be updated (update-based synchronization)

26 Tag Space Collection of application tags and I/O tags Collection of application tags and I/O tags –Essentially, tags are (name, value) pairs Application tags: persistent memory across SM executions Application tags: persistent memory across SM executions I/O tags: access to operating system and I/O subsystem I/O tags: access to operating system and I/O subsystem Tags used for Tags used for –Content-based naming migrate(tag) –Inter-SM communication write(tag, data), read(tag) –Synchronization block(tag, timeout) –I/O access read(temperature)

27 Protection Domains for Tag Space Owner: SM that creates the tag Owner: SM that creates the tag Family: all SMs having a common ancestor with the SM that owns the tag Family: all SMs having a common ancestor with the SM that owns the tag Origin: all SMs created on the same node as the family originator of the tag owner Origin: all SMs created on the same node as the family originator of the tag owner Code: all SMs carrying a specific code brick Code: all SMs carrying a specific code brick Others: all the other SMs Others: all the other SMs Family Code Origin Others Owner

28 Access Control Example (Code-based protection domain) Node5 Node3 Node4 SM2 C2 Cr Node1 Node2 Code Bricks Tag Owner = SM1 [Hash(Cr), RW] SM1 C1 Cr SM1 SM3 C3 C4 Access permission granted for SM2 Access permission denied for SM3 Cr Same routing used by SM1 and SM2

29 SM Admission Ensures progress for all SMs in the network Ensures progress for all SMs in the network Prevents SMs from migrating to nodes that cannot provide enough resources Prevents SMs from migrating to nodes that cannot provide enough resources SMs specify lower bounds for resource requirements (e.g., memory, bandwidth) SMs specify lower bounds for resource requirements (e.g., memory, bandwidth) SMs accepted if the node can satisfy these requirements SMs accepted if the node can satisfy these requirements More resources can be granted according to admission policy More resources can be granted according to admission policy –If not granted, SMs are allowed to migrate

30 Application Example n=0 while (n<NumTaxis) migrate(Taxi); migrate(Taxi); if (readTag(Available)) if (readTag(Available)) writeTag(Available, false); writeTag(Available, false); writeTag(Location, myLocation); writeTag(Location, myLocation); n++; n++; n=0 Taxi Taxi n=0n=0n=1n=1n=2 need 2 taxis data brick application code brick routing SM

31 migrate() migrate() – migrates application to next node of interest – names nodes by tags – implements routing algorithm sys_migrate() sys_migrate() – one hop migration – used by migrate to implement routing SM Migration migrate(Taxi) sys_migrate(2) sys_migrate(3) sys_migrate(4) TaxiTaxi 1 234

32 Network Routing Example 12i RouteToTaxi = 2 Taxi RouteToTaxi = ?RouteToTaxi = j migrate(Taxi){ while(readTag(Taxi) == null) if (readTag(RouteToTaxi)) sys_migrate(readTag(RouteToTaxi)); else create_SM(DiscoverySM, Taxi); createTag(RouteToTaxi, lifetime, null); block_SM(RouteToTaxi, timeout); }

33 SM Self-Routing SMs carry the routing and execute it at each node SMs carry the routing and execute it at each node Routing information stored in tag space Routing information stored in tag space SMs control their routing SMs control their routing –Select routing algorithm (migrate primitive) Multiple library implementations Multiple library implementations Implement a new one Implement a new one –Change routing algorithm during execution in response to Adverse network conditions Adverse network conditions Application’s requirements Application’s requirements

34 Self-Routing Simulation Results starting node node of interest other node Geographic + On-Demand Routing performs better than simple on-demand routing 25%-40% decrease in completion time 62%-92% reduction in amount of bytes sent in the network - Less energy and bandwidth consumption

35Outline Motivation Motivation Spatial Programming Model Spatial Programming Model Smart Messages System Architecture Smart Messages System Architecture Implementation Details Implementation Details Experimental Results Experimental Results Conclusions Conclusions

36 Spatial Programming Implementation Using Smart Messages SP application translates into an SM SP application translates into an SM –Spatial reference access translates into an SM migration to the mapped node –Embedded system properties: Tags SM self-routes using geographical routing and content-based routing SM self-routes using geographical routing and content-based routing Reference consistency Reference consistency − Unique addresses (stored in mapping table) are unique tags created at nodes − SM carries the mapping table

37 Max_motion = {Left_Hill:motion[1], timeout}.detect; Max_motion = {Left_Hill:motion[1], timeout}.detect; SP to SM Translation: Example Spatial Reference Access Smart Message ret = migrate_geo(location, timeout); if (ret == LocationUnreachable) ret = migrate_tag(yU78GH5, timeout); ret = migrate_tag(yU78GH5, timeout); if ((ret == OK) && (location == Left_Hill)) return readTag(detect); return readTag(detect); else throw TimeoutException {Left_Hill,motion,1}{yU78GH5,location} MappingTable CodeBrick Left Hill Right Hill

38 SM Prototype Implementation Modified version of Sun’s Java K Virtual Machine Modified version of Sun’s Java K Virtual Machine –Small memory footprint (160KB) SM and tag space primitives implemented inside virtual machine as native methods (efficiency) SM and tag space primitives implemented inside virtual machine as native methods (efficiency) I/O tags: GPS location, neighbor discovery, image capture, light sensor, system status I/O tags: GPS location, neighbor discovery, image capture, light sensor, system status Ad hoc networks of HP iPAQ PDAs running Linux

39 Lightweight Migration Traditional process migration difficult Traditional process migration difficult –Strong coupling between execution entity and host –Needs to take care of operating system state (e.g., open sockets, file descriptors) Tag space decouples the SM execution state from the operating system state Tag space decouples the SM execution state from the operating system state SM migration transfers only SM migration transfers only –Data bricks explicitly specified by programmer –Minimal execution control state required to resume the SM at the next instruction (e.g., instruction pointer, operand stack pointer)

40Outline Motivation Motivation Spatial Programming Model Spatial Programming Model Smart Messages System Architecture Smart Messages System Architecture Implementation Details Implementation Details Experimental Results Experimental Results Conclusions Conclusions

41 Micro-benchmark Results Cost of data serialization Cost of single hop migration

42 Experimental Results for Simple Routing Algorithms Completion Time Routing algorithmCode not cached (ms)Code cached (ms) Geographic On-demand user node node of interest intermediate node 8 HP iPAQs running Linux and using IEEE for wireless communication

43 SP Application: Intrusion Detection 10 HP iPAQs with cards and GPS devices user node light sensor camera node regular node monitoredspace

44Conclusions Spatial Programming makes outdoor distributed computing simple Spatial Programming makes outdoor distributed computing simple –Volatility, mobility, configuration dynamics, ad hoc networking are hidden from programmer Implementation on top of Smart Messages Implementation on top of Smart Messages –Easy to deploy new applications in the network –Quick adaptation to highly dynamic network configurations Acknowledgments: Liviu Iftode, Ulrich Kremer, Chalermek Intanagonwiwat, Porlin Kang Acknowledgments: Liviu Iftode, Ulrich Kremer, Chalermek Intanagonwiwat, Porlin Kang

45 Other projects based on Smart Messages Portable Smart Messages: work over unmodified JVMs using bytecode instrumentation (done by Nishkam) Portable Smart Messages: work over unmodified JVMs using bytecode instrumentation (done by Nishkam) – –Tested on iPAQs, Ericsson P900, and Nokia Communicator Context-aware Migratory Services in Ad Hoc Networks (Oriana will present it after this talk) Spatial Views: A location-aware, declarative programming language (Uli Kremer will present it on Friday)

46 Two of my current projects Intelligent distributed transportation systems – –Sponsored by NSF, collaboration with Rutgers University (Pravin will talk about it in the afternoon) – –Design a vehicular network architecture and build a prototype for distributed computing over vehicular networks SmartCampus – –Sponsored by NSF, joint work with IS & ECE departments at NJIT – –Investigate mobile computing applications, protocols, middleware over a campus-wide, location-aware, mobile community test-bed (100s of users with mobile devices)

47 Thank you!