Professional Documents
Culture Documents
Simulation For Grid Computing: Henri Casanova Univ. of California, San Diego Casanova@cs - Ucsd.edu
Simulation For Grid Computing: Henri Casanova Univ. of California, San Diego Casanova@cs - Ucsd.edu
Grid Research
Grid researchers often ask questions in the broad
area of distributed computing
Which scheduling algorithm is best for this application on a given Grid? Which design is best for implementing a distributed Grid resource information service? Which caching strategy is best for enabling a community of users that to distributed data analysis? What are the properties of several resource management policies in terms of fairness and throughput? What is the scalability of my publish-subscribe system under various levels of failures ...
Edinburgh, Scotland, June 2005 Grid Performance Workshop 2005 2
Grid Research
Analytical or Experimental? Analytical Grid Computing research
Some have developed purely analytical / mathematical models for Grid computing
makes it possible to prove interesting theorems often too simplistic to convince practitioners but sometimes useful for understanding principles in spite of
dubious applicability
Grid Experiments
Real-world experiments are good
Eminently believable Demonstrates that proposed approach can be implemented in practice
Can be labor-intensive
Entire application needs to be built and functional
including all design / algorithms alternatives include all hooks for deployment
Is it a bad engineering practice to build many full-fledge solutions to find out which ones work best?
Edinburgh, Scotland, June 2005 Grid Performance Workshop 2005 5
experiments Platform configuration may change drastically while experiments are being conducted Experiments are uncontrolled and unrepeatable
even if disruption from other users is part of the experiments, it prevents back-to-back runs of competitor designs / algorithms
Edinburgh, Scotland, June 2005 Grid Performance Workshop 2005 6
appropriate testbed
And to make things worse... Experiments are limited to the testbed
What part of the results are due to idiosyncrasies of the testbed? Extrapolations are possible, but rarely convincing Must use a collection of testbeds... Still limited explorations of what if scenarios
what if the network were different? what if we were in 2015?
Simulation
Simulation can solve many (all) of these difficulties
No need to build a real system Conduct controlled / repeatable experiments In principle, no limits to experimental scenarios Possible for anybody to reproduce results ...
Simulation
representation of the operation of one system (A) through the use of another (B)
Computer simulation: B a computer program
Networking
A few standard packet-level simulators
NS-2, DaSSF, OMNeT++
Well-known datasets for network topologies Well-known generators of synthetic topologies SSF standard: http://www.ssfnet.org/ Possible to reproduce simulation results
Grid Computing?
None of the above up until a few years ago
Most people built their own ad-hoc solutions
a bus (simple communication interference) Communication and computation are perfectly overlappable
Grid Simulations?
Simple models:
perhaps justifiable for a switched dedicated cluster
Overhead of middleware Complex resource access/management policies Interference of communication and computation
11
Grid Simulations
Recognized as a critical area
Grid eXplorer (GdX) project (INRIA)
Presentation Outline
Introduction
13
14
15
16
Compute Resources
And other resources
17
Compute Resources
And other resources
Background Conditions
Load and unavailability
18
X
X
X
Compute Resources
And other resources
Background Conditions
Load and unavailability
Failures
19
X
X
X
Compute Resources
And other resources
Background Conditions
Load and unavailability
Failures
Waxman [JSAC88]
Place N nodes randomly in a CxC square P(u,v) = e-d / ( C 2), 0 < , 1
d = Euclidian distance between u and v
Others
Exponential, Locality-based, ...
Structural Generators
... the primary structural characteristic affecting
the paths between nodes in the Internet is the distribution between stub and transit domains... In other words, there is a hierarchy imposed on nodes... [Zegura et al, 1997] Both at the AS level (peering relationships) and at the router level (Layer 2) Quickly became accepted wisdom:
Transit-Stub [Calvert et al., 1997] Tiers [Doar, 1996] GT-ITM [Zegura et al., 1997]
Edinburgh, Scotland, June 2005 Grid Performance Workshop 2005 23
Power-Laws!
In 1999, Faloutsos et al. [SIGCOMM99] rocked
topology generation with power laws
Results obtained both for AS-level and router-level information from real networks
24
Power-Laws!
Random Generators do not
agree with Power-laws
25
Degree-based Generators
New common wisdom: A topology that does not
agree with power-laws cannot be representative Flurry of development of power-law generators after the Faloutsos paper
CMU power law graph generator [Palmer et al., 2000] Inet [Jin et al., 2000] BRITE [Medina et al., 2001] PLRG [Aiello et al., 2000]
26
Short story
What generator?
To model large networks (e.g., > 500 routers)
use degree-based generators
28
Compute Resources
What resources do we put at the endpoints? Option #1: ad-hoc generalization
Look at the TeraGrid Generate new sites based on existing sites
31
Synthetic Clusters?
Many Grid resources are clusters What is the typical distribution of clusters? Commodity Cluster synthesizer [Kee et al.,
SC04]
Examined 114 production clusters (10K+ procs) Came up with statistical models Validated model against a set of 191 clusters (10K+ procs) Models allow extrapolation for future configurations Models implemented in a resource generator
Edinburgh, Scotland, June 2005 Grid Performance Workshop 2005 32
Architecture/Clock Models
Processor Pentium2 Celeron Pentium3 Pentium4 Itanium Athlon Fraction (%)
4.0
Pentium2
Celeron
Pentium3
Pentium4
Itanium
1.4
Clock Rate (Ghz)
3.5 3.0
5000
1998 1999 2000 2001 Year 2002 2003 2004 2005
4000
AthlonMP
AthlonXP Opteron
12.4
1.3 2.0
1000
# of Processors
3000
2000
Current distribution of proc families Linear fit between clock-rate and release year within a processor family Quadratic fraction of processors released on a given year
1998 1999 2000 Year 2001 2002 2003
Other models?
Other models
Cache size: grows logarithmically
These clusters have been added to the training set More clusters are added every month GridG
Provide a generic framework in which such laws and other correlations can be encoded
Edinburgh, Scotland, June 2005 Grid Performance Workshop 2005 34
Traces
NWS, etc. Desktop Grid resources [Kondo, SC04]
Workload models
e.g., Batch schedulers
Traces Models [Feitelson, JPDC03] job inter-arrival times: Gamma amount of work requested: Hyper-Gamma number of processors requested: Compounded (2^, 1, ...)
Edinburgh, Scotland, June 2005 Grid Performance Workshop 2005 35
37
Presentation Outline
Introduction
38
Simulation Levels
Simulating applications on a synthetic platform? Spectrum of simulation levels
more abstract
Based solely on equations Abstraction of system as a set of dependent actions and events (fine- or coarse-grain) Trapping and virtualization of low-level application/system actions
less abstract
Emulation
Boundaries above are blurred (d.e. simulation ~ emulation) A simulation can combine all paradigms at different levels
Edinburgh, Scotland, June 2005 Grid Performance Workshop 2005 39
Simulation Options
Network
Macroscopic: Flows in pipes
coarse-grain d.e. simulation + mathematical simulation
more abstract
less abstract
CPU
Macroscopic: Flows in a pipe
coarse-grain d.e. simulation + mathematical simulation
more abstract
less abstract
40
Simulation Options
Application
Macroscopic: Application = analytical flow Less Macroscopic: sets of abstract tasks with resource needs and dependencies
coarse-grain d.e. simulation Application specification or pseudo-code API
more abstract
Virtualization
emulation of actual code with trapping of
application-generated events
less abstract
Two projects
MicroGrid (UCSD) SimGrid (UCSD + IMAG + Univ. Nancy)
41
MicroGrid
Set of simulation tools for evaluating middleware,
applications, and network services for Grid systems Applications are supported by emulation and virtualization
Actual application code is executed on virtualized resources
Application
Virtual Resources
Virtualization
MicroGrid
Physical Resources
42
MicroGrid Virtualization
Resource virtualization
resource names are virtualized
gethostname, sockets, Globus GIS, MDS, NWs, etc.
Time virtualization
Simulating the TeraGrid on a 4 node cluster Simulating a 4 node cluster on the TeraGrid
CPU virtualization
Direct execution on (a fraction of) a physical resource No application modification
Main challenge
Synchronization between real time and virtual time
43
MicroGrid Network
Packet-level simulation
Network calls are intercepted Are sent to a network simulator that has been configured with the virtual network topology
Main challenges
scaling (20,000 routers on a 128-node cluster) synchronization with computation
Edinburgh, Scotland, June 2005 Grid Performance Workshop 2005 44
MicroGrid in a NutShell
Virtualization via another CPU
(emulation) Can be really slow But hopefully accurate Virtualization via trapping of application events (emulation) Can have high overhead But captures the overhead!
Emulation
Discrete-event Simulation
Grid Performance Workshop 2005
Mathematical Simulation
more abstract
45
SimGrid
Originally developed for scheduling research
Must be fast to allow for thousands of simulation
Application
No real application code is executed Consists of tasks that have
dependencies resource consumptions
Resources
No virtualization A resource is defined by
a rate a which it does work a fixed overhead that must be paid by each task traces of the above if needed + failures
SimGrid
Uses a combination of mathematical simulation
and coarse-grain discrete event simulation
Simple API to specify an application rather than having it already implemented Fast simulation
Drawback: slow simulation How can one do something faster that is still reasonable?
Come up with macroscopic models of resource sharing
Edinburgh, Scotland, June 2005 Grid Performance Workshop 2005 47
Bandwidth Sharing
Macroscopic TCP modeling is a field
Fluid in Pipe analogy Rule of Thumb: Share of what a flow gets on its bottleneck link is inversely proportional to its Round-Trip Time
10 Mb/sec 2 Mb/sec 8 Mb/sec 8 Mb/sec 8 Mb/sec 8 Mb/sec 10 Mb/sec 10 Mb/sec 10 Mb/sec
Max-Min Fairness
Principle
Consider the set of all network links, L
cl is the capacity of link l
Bandwidth capacities are respected l L, r R | l r xr cl TCP in steady-state is such that: minr R xr is maximized
SimGrid
Uses the Max-Min fairness principle for all
resource sharing
fast validated in the real-world for CPUs validated with NS-2 for networks
Limitation
Max-Min fairness is for steady-state
e.g., no TCP slow-start e.g., no process priority boosts
Unclear when it starts breaking down Is justified for long enough transfers and computations
reasonable for scientific applications not so much for applications such as a Grid information service
51
SimGrid in a NutShell
Macroscopic: Flows in a pipe
(mathematical simulation + coarse-grain d.e. simulation) Very fast Not accurate for short transfers Macroscopic: abstract tasks with resource needs and dependencies (coarse-grain d.e. simulation) Very fast Abstract application model
CPU
Application
less abstract
Network
Mathematical Simulation
more abstract
Emulation
Discrete-event Simulation
Grid Performance Workshop 2005
52
Other Projects
ModelNet
Network emulation unmodified application packets routed through a core cluster
GigaBit-switched nodes running a modified kernel Emulates router queues
More emulation than MicroGrid Only for networking, but plans to add support for computation
Simulation Validation
The crux of most simulation work in most domains of
Argue that although absolute values are off, the trends are respected Conclude that the simulator is useful to compare algorithms/designs Obtain scientific results?????
Edinburgh, Scotland, June 2005 Grid Performance Workshop 2005 55
The authors went back and compared simulation to the real world!
Simulation error is unavoidable
30% error in their case was not rare Negating the impact of we got 1.5% improvement
One should focus on simulating the important things A more complex simulator does not ensure better simulation
simple simulators worked better than sophisticated ones, which were unstable simple simulators predicted trends as well as slower, sophisticated ones
Conclusion: for FLASH, the simple simulator was all that was needed
56
Presentation Outline
Introduction
57
It doesnt lead to many papers Its eminently politically incorrect Results depend on what the simulation is used for
Therefore nobody does it The story one would like to tell is, e.g.:
Start with SimGrid simulations at first to identify promising approaches Move to MicroGrid emulations to precisely quantify the trade-offs
Current work
Adding a MaSSF back-end (i.e., MicroGrid) Adding a ModelNet back-end
SimGrid
SURF MaSSF ModelNet
Goals
smooth transition from design to prototyping to production easy validation and simulation calibration
Plan
Use GRAS to easily compare SimGrid, MaSSF, ModelNet, and real world networks Move on to full applications
Edinburgh, Scotland, June 2005 Grid Performance Workshop 2005 60
Conclusion
Simulation is difficult
Eternal question: What does really matters?
61
Questions?
62
63
A Simple Experiment
- Sent out files of 500MB up to 1.5GB with TTCP - Using from 1 up to 16 simultaneous connections - Recorded the data transfer rate per connection
Edinburgh, Scotland, June 2005 Grid Performance Workshop 2005 64
Experimental Results
Normalized data rate per connection
Max-Min Fairness
Captures other resource sharing beyond networks!
Interference of Communication and Computation
[kreaseck et al., IJHPCA05]
CPU sharing
70