April 10, 2017 Rob Farber
Containers are an extremely mobile, safe and reproducible computing infrastructure that is now ready for production HPC computing. In particular, the freely available Singularity container framework has been designed specifically for HPC computing. The barrier to entry is low and the software is free.
At the recent Intel HPC Developer Conference, Gregory Kurtzer (Singularity project lead and LBNL staff member) and Krishna Muriki (Computer Systems Engineer at LBNL) provided a beginning and advanced tutorial on Singularity. One of Kurtzers key takeaways: setting up workflows in under a day is commonplace with Singularity.
Many people have heard about code modernization and are familiar with how it addresses scaling and performance challenges, but code modernization also implies modifying applications so they are mobile and have the ability to deliver reproducible science across systems and software versions both now and in the future.
The proof of the pudding lies in the tasting, which is highlighted by the global acceptance of Singularity at HPC centers around the world on large systems. Following are a few large-scale examples:
Figure 1: Partial list of organizations. (Full list available here.)
Singularity was designed so that applications which run in a container have the same distance to the host kernel and hardware as natively running applications as shown below.
Figure 2: Singularity preserves the nearness of native applications to the OS
This translates to performance, jitter reduction, and the ability to directly utilize GPUs and communications fabrics such as InfiniBand and Intel Omni-Path Architecture (Intel OPA).
Intel supports Singularity containers on HPC products and provides Application Notes showing how to import large, complex HPC applications such as NWChem into Singularity containers so they can run on Intel processors and Intel OPA. Intel recommends that users run like on like container images that match the same kernel and OS distribution to the Intel OPA-basic release. They state, Other combinations may work, but there is no support implied. (Source Intel Application Note J57474-1.0 page 9.)
Figure 3: Identifying compute nodes for containers (Source Intel)
Unlike Docker (currently the most well-known enterprise container system) and other container systems, Singularity preserves the security of the host HPC system and does not represent a breach of security. Plus Singularity includes MPI an essential part of HPC computing.
Succinctly, if a user wants to be root inside a Singularity container, they must first be root on the system outside the container. A user with root access can view and change any file on the system either inadvertently or maliciously. Thus, HPC security models tightly control root access and forbid non-authorized people (e.g. general users) from gaining root access. Due to the design of Docker and other enterprise container systems that utilize root-level user-writable daemons and other security-permeable design features, HPC systems managers have to isolate the both HPC networks and user access to data before these containers can be allowed on the system.
Succinctly, if a user wants to be root inside a Singularity container, they must first be root on the system outside the container Singularity Permissions, Access, and Privilege
The ramifications are far-reaching and precludes access to InfiniBand and Intel OPA high performance and optimized storage platforms as well as locally mounted file-systems. Thus a typical Docker solution uses a virtual cluster within the physical machine. Unfortunately, virtual machines introduce jitter, which can degrade HPC application performance by a factor of 4x or more. (See the paper, The Case of the Missing Supercomputer Performance for more information about the impact of even tiny amounts of jitter on HPC applications.) Network isolation, jitter, and other issues explain why Kurtzer tells people that Docker and other enterprise container systems, Remove High Performance from HPC.
Further, MPI is included in Singularity where it is omitted in enterprise container systems. In particular Kurtzer notes that Docker has, No reasonable support or timeline for MPI. Current estimates are that MPI support in Docker is at least two years out. Succinctly, Kurtzer observes that HPC is not a use case for Docker or other enterprise container systems like runC and RKT. Kurtzer created Singularity in part because, Patches to help make Docker/runC/RKT a better solution for HPC have been submitted, but most have not been accepted!
Patches to help make Docker/runC/RKT a better solution for HPC have been submitted, but most have not been accepted! Gregory Kurtzer (Singularity project lead and LBNL staff member).
This explains why Kurtzer created Singularity to address enterprise design omissions (security, performance, and MPI) plus other issues. The lack of these features in currently popular container systems also provides the reason for HPC users to evaluate and adopt Singularity on their HPC systems.
Please see the security documents for more information about the Singularity security model.
Singularity is also used to perform HPC in the cloud on AWS, Google Cloud, Azure and other cloud providers. This makes it possible to develop a research workflow on a laboratory or a laboratory server, then bundle it to run on a departmental cluster, on a leadership class supercomputer, or in the cloud.
Singularity containers can be built to include all of the programs, libraries, data and scripts such that an entire workflow can be contained and either archived or distributed for others to replicate no matter what version of Linux they are running. Singularity also runs on Mac and Windows systems.
Singularity also blurs the line between container and host such that local directories can exist within the container. Applications within the container have full and direct access to these files, which enables arbitrary and persistent workflow configurations. Meanwhile, users can get results reported to their local file-system.
Containers can also be bundled so they contain commercial code. Essentially, the container can be installed using a certified version of the operating system. The Singularity documentation then states, The application environment, libraries, and certified stack would all continue to run exactly as it is intended inside the container.
The advantage of containers is that legacy workflows will continue running far into the future. This is a double-edged sword because workflows will continue working as-is far into the future, which puts the onus is on the maintainers of the containerized workflow to ensure the code stays current rather than becoming fossilized. Still, even ancient containers can be exhumed to provide result validation.
Users are finding that they deploy an application on an HPC cluster with an installed workload manager such as Slurm, HTCondor or Torque code with little effort and similar performance to workflows in other container systems. Kurtzer tells people, Setting up workflows in under a day is commonplace with Singularity
Setting up workflows in under a day is commonplace with Singularity Greg Kurtzer
The National Institute of Health wrote, Weve had many users ask for programs like TensorFlow and OpenCV3 that are difficult or impossible to install with our current OS. Many users have also been asking for Docker to create portable reproducible data analysis pipelines. Singularity allows us to provide this functionality to our users in a secure environment. Our admins have found it easy and intuitive to use Singularity. Some of our staff have even begun to install tricky applications into Singularity containers and write wrapper scripts and module files that make the Singularity environment transparent to the end user. (Source: Singularity Registry download file)
Nextflow wrote a detailed blog about their work to containerize a bioinformatics pipeline at the Center for Genomic Regulation (CRG). Their benchmarks show that there isnt any significant difference in the execution times between Docker and Singularity. (Source: The Nextflow blog, More fun with containers in HPC.)
Figure 4: Docker vs. Singularity runtimes (time in minutes. Reprinted courtesy NextFlow)
The February 2017 Intel Application Note, Building Containers for Intel Omni-Path Fabrics using Docker and Singularity shows how to configure and run Singularity on Intel OPA fabrics. They provide a specific example of building and running NWChem in a Singularity container and note in the conclusion:
When comparing the container technologies, we found Singularity to be a viable alternative to Docker for running MPI applications in our test HPC cluster environment. Singularity interfaces with the MPI mechanisms installed on the host machines and can be used with external resource managers. It is also possible to run Singularity directly as a normal user without needing root permissions to run certain tasks.
This same Application Note also shows how to convert a Docker container into a Singularity container.
Gorgolewski et. al. wrote in PLOS Computational Biology, Previous containerized data processing solutions were limited to single user environments and not compatible with most multi-tenant High Performance Computing systems. BIDS Apps overcome this limitation by taking advantage of the Singularity container technology. As a proof of concept, this work is accompanied by 22 ready to use BIDS Apps, packaging a diverse set of commonly used neuroimaging algorithms.
Carlos Eduardo Arango Gutierrez at the Universidad del Valle says that Singularity helps them, in reducing development, deployment and optimization effort in our objective of building a large-scale, organized and self-managed cluster, offering a distro and vendor neutral environment for the development of heterogeneous HPC applications.
Lai Wei-Hwa at roboco.com notes that, Finally, a solution for Dockers security holes. In particular, they find the following advantages:
Containers are a new concept for the scientific and HPC communities. For security, mobility, and reproducibility reasons, developers are strongly encouraged to look into a container solution like Singularity.
Categories: Control, HPC
Tags: Containers, Docker, Singularity
From Mainframes to Deep Learning Clusters: IBMs Speech Journey Risk or Reward: First Nvidia DGX-1 Boxes Hit the Cloud
See the original post here:
Singularity Containers for HPC, Reproducibility, and Mobility - The Next Platform
- Singularity University - Solving Humanity's Grand Challenges [Last Updated On: June 10th, 2016] [Originally Added On: June 10th, 2016]
- Singularity Viewer [Last Updated On: June 12th, 2016] [Originally Added On: June 12th, 2016]
- Technological singularity - Wikipedia, the free encyclopedia [Last Updated On: June 14th, 2016] [Originally Added On: June 14th, 2016]
- Singularity HUB - News and Insights on Technology, Science ... [Last Updated On: June 16th, 2016] [Originally Added On: June 16th, 2016]
- Singularity on Steam [Last Updated On: June 22nd, 2016] [Originally Added On: June 22nd, 2016]
- The Best Definition of Singularity [Last Updated On: June 22nd, 2016] [Originally Added On: June 22nd, 2016]
- Amazon.com: Singularity - Xbox 360: Video Games [Last Updated On: June 22nd, 2016] [Originally Added On: June 22nd, 2016]
- Singularity - Microsoft Research [Last Updated On: June 22nd, 2016] [Originally Added On: June 22nd, 2016]
- Singularity - GameSpot [Last Updated On: June 22nd, 2016] [Originally Added On: June 22nd, 2016]
- Singularity Q&A | KurzweilAI [Last Updated On: June 27th, 2016] [Originally Added On: June 27th, 2016]
- Singularity - RationalWiki [Last Updated On: July 18th, 2016] [Originally Added On: July 18th, 2016]
- Amazon.com: Singularity [Online Game Code]: Video Games [Last Updated On: August 25th, 2016] [Originally Added On: August 25th, 2016]
- Singularity - Mass Effect Wiki - Wikia [Last Updated On: August 25th, 2016] [Originally Added On: August 25th, 2016]
- Downloads - Singularity Viewer [Last Updated On: August 25th, 2016] [Originally Added On: August 25th, 2016]
- Singularity | Singularity [Last Updated On: October 31st, 2016] [Originally Added On: October 31st, 2016]
- What is Singularity (the)? - Definition from WhatIs.com [Last Updated On: October 31st, 2016] [Originally Added On: October 31st, 2016]
- Singularity University - Wikipedia [Last Updated On: November 29th, 2016] [Originally Added On: November 29th, 2016]
- Technological singularity - Wikipedia [Last Updated On: December 15th, 2016] [Originally Added On: December 15th, 2016]
- The Singularity Is Near - Wikipedia [Last Updated On: January 22nd, 2017] [Originally Added On: January 22nd, 2017]
- Singularity Art Show Tonight In San Francisco! [Last Updated On: January 23rd, 2017] [Originally Added On: January 23rd, 2017]
- When Electronic Witnesses Are Everywhere, No Secret's Safe - Singularity Hub [Last Updated On: February 6th, 2017] [Originally Added On: February 6th, 2017]
- GEMS Education and Singularity University organises 1st annual Global Innovation Challenge - Al-Bawaba [Last Updated On: February 6th, 2017] [Originally Added On: February 6th, 2017]
- Do you believe in the Singularity? - Patheos (blog) [Last Updated On: February 6th, 2017] [Originally Added On: February 6th, 2017]
- Report: AMD Ryzen Performance in Ashes of the Singularity Benchmark - PC Perspective [Last Updated On: February 6th, 2017] [Originally Added On: February 6th, 2017]
- Donald Trump Is the Singularity - Bloomberg View - Bloomberg.com - Bloomberg [Last Updated On: February 6th, 2017] [Originally Added On: February 6th, 2017]
- Editorial Note From the Singularity Hub Team - Singularity Hub [Last Updated On: February 6th, 2017] [Originally Added On: February 6th, 2017]
- Discover the Most Advanced Industrial Technologies at Exponential Manufacturing - Singularity Hub [Last Updated On: February 6th, 2017] [Originally Added On: February 6th, 2017]
- 10th Letter looks at nature in the time of the Singularity - Creative Loafing Atlanta [Last Updated On: February 7th, 2017] [Originally Added On: February 7th, 2017]
- Wearable Devices Can Actually Tell When You're About to Get Sick - Singularity Hub [Last Updated On: February 7th, 2017] [Originally Added On: February 7th, 2017]
- Video: Singularity Containers for Science, Reproducibility, and HPC - insideHPC [Last Updated On: February 7th, 2017] [Originally Added On: February 7th, 2017]
- Robot Cars Can Teach Themselves How to Drive in Virtual Worlds - Singularity Hub [Last Updated On: February 9th, 2017] [Originally Added On: February 9th, 2017]
- Rowe FTC robotics team RSF Singularity takes top honors at Championship - Rancho Santa Fe Review [Last Updated On: February 10th, 2017] [Originally Added On: February 10th, 2017]
- Physicists Unveil Blueprint for a Quantum Computer the Size of a ... - Singularity Hub [Last Updated On: February 10th, 2017] [Originally Added On: February 10th, 2017]
- Singularity Containers for Science, Reproducibility, and HPC - Linux.com (blog) [Last Updated On: February 10th, 2017] [Originally Added On: February 10th, 2017]
- How Robots Helped Create 100,000 Jobs at Amazon - Singularity Hub - Singularity Hub [Last Updated On: February 11th, 2017] [Originally Added On: February 11th, 2017]
- Ready to Change the World? Apply Now for Singularity University's 2017 Global Solutions Program - Singularity Hub [Last Updated On: February 11th, 2017] [Originally Added On: February 11th, 2017]
- Families Finally Hear From Completely Paralyzed Patients Via New Mind-Reading Device - Singularity Hub [Last Updated On: February 13th, 2017] [Originally Added On: February 13th, 2017]
- The fear of a technological singularity - ETtech.com [Last Updated On: February 13th, 2017] [Originally Added On: February 13th, 2017]
- Holograms Aren't The Stuff of Science Fiction Anymore - Singularity Hub [Last Updated On: February 15th, 2017] [Originally Added On: February 15th, 2017]
- How the World Has Changed From 1917 to 2017 - Singularity Hub [Last Updated On: February 15th, 2017] [Originally Added On: February 15th, 2017]
- Preparing for the Singularity - Inverse [Last Updated On: February 15th, 2017] [Originally Added On: February 15th, 2017]
- Ashes of the Singularity merges with standalone expansion Escalation, no upgrade fee - PCGamesN [Last Updated On: February 18th, 2017] [Originally Added On: February 18th, 2017]
- Just Stand Inside this Room and it Will Wirelessly Charge Your Phone - Singularity Hub [Last Updated On: February 18th, 2017] [Originally Added On: February 18th, 2017]
- Ashes of the Singularity: Escalation being merged with the original game - PC Invasion (blog) [Last Updated On: February 18th, 2017] [Originally Added On: February 18th, 2017]
- Europe's TREASURE Will Be the King of All GPSs - Singularity Hub [Last Updated On: February 18th, 2017] [Originally Added On: February 18th, 2017]
- AMD bundles Ashes of the Singularity with FX processors ahead of Ryzen's launch - PCWorld [Last Updated On: February 18th, 2017] [Originally Added On: February 18th, 2017]
- The roots of technological singularity can be traced backed to the Stone Age - Wired.co.uk [Last Updated On: February 20th, 2017] [Originally Added On: February 20th, 2017]
- Jide's new OS is like an Android version of Windows 10's Continuum - The Verge [Last Updated On: February 22nd, 2017] [Originally Added On: February 22nd, 2017]
- Jide's Remix Singularity OS will turn your Android phone into a PC - Android Authority (blog) [Last Updated On: February 22nd, 2017] [Originally Added On: February 22nd, 2017]
- Remix tries its hand at the mobile-desktop hybrid OS with Singularity - Android Police [Last Updated On: February 23rd, 2017] [Originally Added On: February 23rd, 2017]
- Financial Leaders: Make Your Mark on the Future at Exponential Finance - Singularity Hub [Last Updated On: February 23rd, 2017] [Originally Added On: February 23rd, 2017]
- After Man? From Singularity to Specificity - Peace Research Institute Oslo (PRIO) (press release) (blog) [Last Updated On: February 23rd, 2017] [Originally Added On: February 23rd, 2017]
- Ashes of Singularity: Escalation Gets an Update - CGMagazine [Last Updated On: February 24th, 2017] [Originally Added On: February 24th, 2017]
- One Android company wants to use smartphones to make PCs truly ... - BGR [Last Updated On: February 24th, 2017] [Originally Added On: February 24th, 2017]
- Jide Announces Remix Singularity: The Continuum Alternative for Android - XDA Developers (blog) [Last Updated On: February 24th, 2017] [Originally Added On: February 24th, 2017]
- Why the Potential of Augmented Reality Is Greater Than You Think - Singularity Hub [Last Updated On: February 24th, 2017] [Originally Added On: February 24th, 2017]
- Damon Wayans Jr. Will Star in Seth Rogen's AI Comedy 'Singularity' for FX - /FILM [Last Updated On: February 24th, 2017] [Originally Added On: February 24th, 2017]
- Google Updates: Scuba, Singularity, SMS and suing - The INQUIRER [Last Updated On: February 24th, 2017] [Originally Added On: February 24th, 2017]
- Damon Wayans Jr. Joins FX Sci-Fi Comedy Singularity - Den of Geek US [Last Updated On: February 28th, 2017] [Originally Added On: February 28th, 2017]
- This Neural Probe Is So Thin, The Brain Doesn't Know It's There - Singularity Hub [Last Updated On: February 28th, 2017] [Originally Added On: February 28th, 2017]
- Video: AI Is Getting Smarter, Says Singularity University's Neil Jacobstein - Wall Street Journal (subscription) (blog) [Last Updated On: February 28th, 2017] [Originally Added On: February 28th, 2017]
- Jami Attenberg's funny-sad 'All Grown Up' all about the singularity - Milwaukee Journal Sentinel [Last Updated On: February 28th, 2017] [Originally Added On: February 28th, 2017]
- Citizen Science Means Anyone Could Discover Planet NineEven You - Singularity Hub [Last Updated On: February 28th, 2017] [Originally Added On: February 28th, 2017]
- Does Zapping Your Brain Actually Help You Learn Faster? - Singularity Hub [Last Updated On: March 1st, 2017] [Originally Added On: March 1st, 2017]
- What You Need to Know About Elon Musk's Plan to Fly People to the Moon - Singularity Hub [Last Updated On: March 1st, 2017] [Originally Added On: March 1st, 2017]
- Singularity University opening organisation in Denmark The Post - The Copenhagen Post - Danish news in english [Last Updated On: March 1st, 2017] [Originally Added On: March 1st, 2017]
- Singularity: Explain It to Me Like I'm 5-Years-Old - Futurism - Futurism [Last Updated On: March 4th, 2017] [Originally Added On: March 4th, 2017]
- See How This House Was 3D Printed in Just 24 Hours - Singularity Hub [Last Updated On: March 5th, 2017] [Originally Added On: March 5th, 2017]
- NYC's Metrograph theater is running a sci-fi film series featuring Blade Runner, Ex Machina, and Metropolis - The Verge [Last Updated On: March 7th, 2017] [Originally Added On: March 7th, 2017]
- 3 Exciting Biotech Trends to Watch Closely in 2017 - Singularity Hub - Singularity Hub [Last Updated On: March 9th, 2017] [Originally Added On: March 9th, 2017]
- New Burger Robot Will Take Command of the Grill in 50 Fast Food Restaurants - Singularity Hub [Last Updated On: March 9th, 2017] [Originally Added On: March 9th, 2017]
- Are These Giant Neurons the Seat Of Consciousness in the Brain? - Singularity Hub [Last Updated On: March 10th, 2017] [Originally Added On: March 10th, 2017]
- How Fully Synthetic Complex Life Just Got a Lot Closer - Singularity Hub [Last Updated On: March 12th, 2017] [Originally Added On: March 12th, 2017]
- The Singularity is Coming in 2029 and Will Make Humans 'Sexier' - Inverse [Last Updated On: March 17th, 2017] [Originally Added On: March 17th, 2017]
- NYC Weekend Watch: 'Taipei Story,' the Singularity, 'The Last Movie' & More - The Film Stage (blog) [Last Updated On: March 17th, 2017] [Originally Added On: March 17th, 2017]
- The Singularity: US Navy calls on gamers to help it plan for the rise ... - International Business Times UK [Last Updated On: March 17th, 2017] [Originally Added On: March 17th, 2017]
- Have a big idea to tackle climate change? Singularity U's Global Impact Challenge wants you - Miami Herald [Last Updated On: March 17th, 2017] [Originally Added On: March 17th, 2017]
- The singularity: AI will make humans sexier and funnier, says ... - The Independent [Last Updated On: March 17th, 2017] [Originally Added On: March 17th, 2017]
- Silicon Valley's top brains try to sort out the singularity - TechEye [Last Updated On: March 21st, 2017] [Originally Added On: March 21st, 2017]
- World Order's 'Singularity' raises profile of singular girls group - Japan Today [Last Updated On: March 27th, 2017] [Originally Added On: March 27th, 2017]