-
-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Automated deployment to update community posts 2024-09-30
- Loading branch information
github-actions
committed
Sep 30, 2024
1 parent
903c3a8
commit 050dde6
Showing
1 changed file
with
177 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,177 @@ | ||
--- | ||
author: Thinking Out Loud | ||
author_tag: ajdecon | ||
blog_subtitle: works in progress and scattered thoughts, often about computers | ||
blog_title: Computing – thinking out loud | ||
blog_url: https://thinking.ajdecon.org | ||
category: ajdecon | ||
date: '2024-09-29 22:22:51' | ||
layout: post | ||
original_url: https://thinking.ajdecon.org/2024/09/29/the-hpc-cluster-platform-as-a-reflection-of-values/ | ||
slug: the-hpc-cluster-as-a-reflection-of-values | ||
title: The HPC cluster as a reflection of values | ||
--- | ||
|
||
<p>Yesterday while I was cooking dinner, I happened to re-watch Bryan Cantrill’s talk on “<a href="https://www.youtube.com/watch?v=Xhx970_JKX4">Platform as a Reflection of Values</a>“. (I watch a lot tech talks while cooking or baking — I often have trouble focusing on a video unless I’m doing something with my hands, but if I know a recipe well I can often make it on autopilot.)</p> | ||
|
||
|
||
|
||
|
||
<p>If you haven’t watched this talk before, I encourage checking it out. Cantrill gave it in part to talk about why the node.js community and Joyent didn’t work well together, but I thought he had some good insights into how values get built into a technical artifact itself, as well as how the community around those artifacts will prioritize certain values.</p> | ||
|
||
|
||
|
||
|
||
<p>While I was watching the talk (and chopping some vegetables), I started thinking about what values are most important in the “HPC cluster platform”.</p> | ||
|
||
|
||
|
||
|
||
<span id="more-339"></span> | ||
|
||
|
||
|
||
<h2 class="wp-block-heading">Technical values</h2> | ||
|
||
|
||
|
||
<p>This slide from the talk shows some examples of what Cantrill thinks of as platform values:</p> | ||
|
||
|
||
|
||
|
||
<figure class="wp-block-image size-full"><img alt="A slide with the title "Some platform values". The list includes approachability, availability, compatibility, composability, debuggability, expressiveness, extensibility, interoperability, integrity, maintainability, operability, performance, portability, resiliency, rigor, robustness, safety, security, simplicity, thoroughness, transparency, and velocity." class="wp-image-340" height="538" src="https://thinking.ajdecon.org/wp-content/uploads/2024/09/image.png" width="969" /></figure> | ||
|
||
|
||
|
||
<p>A key point from the talk is that all of these are good things! Ideally you want to have <em>all</em> of these things when you build a new platform, whether that’s a programming language, a cloud platform, or whatever. But any given platform will choose to<em> </em>prioritize some set of values over others. You want them all, but when they come into tension, which ones will win?</p> | ||
|
||
|
||
|
||
|
||
<p>One example that Cantrill gives in the talk is the original Unix out of Bell Labs, which prioritized simplicity, composability, and portability. Certainly Unix wanted other features, like performance and maintainability, but if forced into a choice like performance vs simplicity, it would generally choose simplicity. Similarly, he talked about how JavaScript and node.js are built around values like approachability, expressiveness, and velocity, and how that contrasted with values like robustness and debuggability that Joyent valued as a cloud provider.</p> | ||
|
||
|
||
|
||
|
||
<h2 class="wp-block-heading">The HPC cluster platform</h2> | ||
|
||
|
||
|
||
<p>When I saw “HPC cluster platform”, I’m loosely talking about the collection of hardware and software that is most often used to build high-performance computing clusters for workloads like scientific research or machine learning training.</p> | ||
|
||
|
||
|
||
|
||
<p>This generic platform consists of a large collection of identical compute nodes, orchestrated by a batch scheduler like <a href="https://github.com/SchedMD/slurm">Slurm</a> or <a href="https://github.com/openpbs/openpbs">PBS</a>, and with one or more “login nodes” serving as a front-end where users SSH in to prepare and run jobs on the cluster. For multi-node jobs and high-speed storage access, the compute nodes are connected by a very high-speed network, like 100Gb Ethernet or InfiniBand, which needs specific libraries to use effectively. Users on the cluster have access to command-line editors and development tools like compilers and scientific libraries, but mostly interact with the platform in a purely command line environment.</p> | ||
|
||
|
||
|
||
|
||
<p>See also, this really ugly Google Draw diagram:</p> | ||
|
||
|
||
|
||
|
||
<figure class="wp-block-image size-large"><img alt="A simple diagram showing a login node, a set of compute nodes, and network storage. The login node is connected to compute nodes by a management network. The storage is connected to compute nodes by a high-speed network." class="wp-image-348" height="488" src="https://thinking.ajdecon.org/wp-content/uploads/2024/09/image-1-1024x488.png" width="1024" /></figure> | ||
|
||
|
||
|
||
<p>What values does this platform prioritize? In general, I tend to think that HPC platforms prioritize <em>performance</em>, <em>portability</em>, and <em>approachability</em>.</p> | ||
|
||
|
||
|
||
|
||
<p><strong>Performance: </strong>This might seem obvious given the name “HPC”, but it’s worth thinking a little more about. When faced with a choice between performance and some other value, HPC clusters <em>almost always</em> choose performance. <br /><br />Performance is generally performance above cost, with most clusters using expensive compute and networking hardware. It’s prioritized over observability (“measurability” on Cantrill’s slide?), with most HPC clusters I’m aware of disabling most active monitoring features if they have a performance cost. It’s even prioritized above security, often turning off security features if they lead to lower performance or even measurable performance <em>variability</em>.</p> | ||
|
||
|
||
|
||
|
||
<p><strong>Portability: </strong>Mindful of the difficulty in writing high-performance, correct scientific code, the HPC platform works reasonably hard to maintain portability to new hardware and software over time. </p> | ||
|
||
|
||
|
||
|
||
<p>A lot of this is due to a robust ecosystem of libraries and middleware. Most applications that scale across multiple nodes still use <a href="https://en.wikipedia.org/wiki/Message_Passing_Interface">MPI</a>; code doing linear algebra still depends on long-lived libraries like <a href="https://www.netlib.org/lapack/">LAPACK</a> and <a href="https://www.netlib.org/blas/">BLAS</a>; and platform tools like the scheduler tend to be remarkably stable over time. New hardware features are often abstracted by middleware, especially at the networking level where support is built into your MPI library of choice.</p> | ||
|
||
|
||
|
||
|
||
<p>This story isn’t perfect — applications usually need recompilation on a new cluster, and still often need major changes to take advantages of new features. That’s why I chose “portability” instead of “compatibility”. But as a cluster admin, I’ve worked with many researchers who have maintained the same app on many different clusters for 10, 20, or even 30 years, which is a pretty impressive portability story.</p> | ||
|
||
|
||
|
||
|
||
<p><strong>Approachability: </strong>This one may be controversial! The average HPC cluster can seem pretty arcane, especially for someone new to the platform. But I do think that HPC prioritizes a particular <em>kind</em> of approachability, which is that it is designed to onboard scientific researchers who are not themselves expert developers.</p> | ||
|
||
|
||
|
||
|
||
<p>A new user onboarding to a research HPC cluster frequently needs to understand three main tools:</p> | ||
|
||
|
||
|
||
|
||
<ul class="wp-block-list"> | ||
<li><strong>The Linux shell:</strong> Most HPC cluster environments are entirely command-line oriented (though <a href="https://openondemand.org/">Open OnDemand</a> is helping change this!). You log in with SSH; edit using nano, vim, or emacs; and interact with the system entirely using a shell.</li> | ||
|
||
|
||
|
||
<li><strong>The cluster scheduler: </strong>When you have your application ready to go, you submit your job to a queue using a cluster scheduler like Slurm and wait for it to complete. Cluster schedulers have a lot of moving parts and a user can often find endless knobs to tune, but it’s easy to get started with just a few commands. (And interestingly, almost all HPC cluster schedulers define their jobs as… shell scripts! You’re back to needing to know the shell. Annoying, sure, but at least it ain’t YAML!)</li> | ||
|
||
|
||
|
||
<li><a href="https://modules.readthedocs.io/en/latest/"><strong>Environment modules</strong></a>: This tool allows the cluster admins to provide a large library of libraries and tools, with specific versions, such that a cluster user just needs to type “module load openmpi/3”. While the tool munges the shell environment variables as needed to set up PATH, LD_LIBRARY_PATH, etc just so.</li> | ||
</ul> | ||
|
||
|
||
|
||
<p>Now if this doesn’t sound like a robust software engineering environment… it isn’t! There are endless things that can go wrong, especially with environment modules interacting with the user’s own shell rc files and who knows what else. And there’s very little in this environment to encourage best practices like linting, pinned library versions, or even version control at all!</p> | ||
|
||
|
||
|
||
|
||
<p>But this environment is <em>approachable</em>… if you’re a graduate student in a field like physics or biology, running an existing application or writing your own simulation or data processing code. But who never got to take a class on software engineering, and where the code itself is not a first class deliverable. The deliverable is the published paper.</p> | ||
|
||
|
||
|
||
|
||
<h2 class="wp-block-heading">But what about all those other values?</h2> | ||
|
||
|
||
|
||
<p>They’re still important! But the point of this exercise is to think about which values are will “win” when they come into tension. And I do think that, if you look at HPC clusters in general, this is the set of values that will win.</p> | ||
|
||
|
||
|
||
|
||
<p>Availability is important, but not if that work costs us (much) performance. Velocity is great, but we’ll de-prioritize it in the name of workload portability. Security is essential — but we don’t want to make it harder to onboard new grad students…</p> | ||
|
||
|
||
|
||
|
||
<h2 class="wp-block-heading">You cluster is not the generic platform (and neither is mine)</h2> | ||
|
||
|
||
|
||
<p>A last point I want to make is that there’s actually <em>no such thing</em> as the “generic HPC cluster platform”. Each individual cluster, at a university or company or government lab, is often configured in a unique way based on the hardware, performance goals, and whims of the person setting it up.</p> | ||
|
||
|
||
|
||
|
||
<p>Because of this, each <em>individual</em> HPC cluster may prioritize different values. A cluster at a national lab may choose security at the expense of approachability; or a different cluster may choose to sacrifice portability in the name of velocity if they’re developing on a new hardware or software system.</p> | ||
|
||
|
||
|
||
|
||
<p>(Also, the systems I build as part of my day job also make <em>very</em> different choices than the “generic” cluster would. To a first approximation, I think I’d say we choose performance/debuggability/portability/security… but we also make different choices depending on what we’re building!)</p> | ||
|
||
|
||
|
||
|
||
<p>But I still think that <em>performance</em>, <em>portability</em>, and <em>approachability</em> represent the most common platform values I’ve seen in the HPC field as a whole. And I think the tools and practices we use bias towards those values.</p> | ||
|
||
|
||
|
||
|
||
<p>However… all of that is what I thought about while making dinner! If you think a different set of values makes more sense, feel free to <a href="mailto:[email protected]">send me an email</a> and let me know. <img alt="😉" class="wp-smiley" src="https://s.w.org/images/core/emoji/15.0.3/72x72/1f609.png" style="height: 1em;" /></p> |