tutorials

Launching an instance on Jetstream 2

Overview

This tutorial provides instructions for launching an instance (virtual server) on Jetstream 2 using the Exosphere user interface.

Outcomes

  • Configure, launch, and manage an instance on Jetstream 2

Prerequisites

Background

This section provides a bit of background on the key technologies involved in this tutorial.

What is Jetstream 2

Jetstream 2 is a large, feature-rich national computing resource hosted at Indiana University.

What's ACCESS?

ACCESS is a way for you to gain free access to national computing resources distributed across the US.

From the official docs, …

ACCESS is a program established and funded by the U.S. National Science Foundation to help researchers and educators, with or without supporting grants, to utilize the nation's advanced computing systems and services – at no cost to you.

Why use ACCESS?

  • Free: Unlike most commercial cloud providers, US students and researchers can usually gain access to national compute infrastructure at no cost.

  • Familiarize yourself with cloud computing practices: Many of the concepts you'll learn translate directly to commercial cloud provider like AWS.

Prerequisites

Before starting, ensure that …

Part 1: Your SSH key

In this tutorial, we'll be connecting to our instance over the Secure Shell (SSH) protocol. To do so, we'll need to create a cryptographic key with two parts: a public key and a private key.

You can think of the public key as a fancy lock and the private key as the key to that lock. You can put the lock on whatever door you want (…and as many doors as you want), but you want to keep your key somewhere safe.

Locks out and about in public

1. Create an SSH key

In order to connect to the instance you'll be creating, you'll need to create an SSH key and copy the public portion:

ssh-keygen -t ed25519 -C "yournetid@arizona.edu"

You'll be prompted to specify a location to save your file. Try /path/to/home/.ssh/jetstream2 replacing /path/to/home/ with the path (from the root) to your home directory.

Next, you'll be prompted to set a password. If you'd prefer to do so, you can leave this blank.

take note of the the public portion of the key .pub.

2. Register your SSH key

With you SSH key in hand, you can now begin configuring your instance. First, navigate to https://jetstream2.exosphere.app/exosphere/ . Initially you probaby won't see any allocations listed:

jetstream-2-add-allocation

To add an allocation, select Add allocation and then Add ACCESS account:

jetstream-2-login-to-access

After completing the login step, you'll be redirected to https://jetstream2.exosphere.app/exosphere/. You should now see an available allocation. Select it by clicking on it:

jetstream-2-overview

You'll be redirected to a view with an overview of available resources. In the top right-hand corner, click Create and select SSH Public Key from the dropdown that appears:

jetstream-2-ssh-public-key

In the next screen, you'll add your public SSH key that you created in Part 1. Paste in the complete contents of your .pub file. Give your uploaded key a name (ex. your ACCESS ID or your Net ID), so that you'll be able to easily recognize it when configuring your instance:

jetstream-2-ssh-public-key-2

You're now ready to configure and launch your first instance.

Part 2: Configuring an instance

From the Create dropdown menu, select Instance:

jetstream-2-select

In the new view, select an instance "source":

jetstream-2-choose-instance

Next, name your instance and select an instance type ("flavor"):

jetstream-2-create-instance-1

Configure your disk size. Consider datasets and model artifacts (initial model, snapshots during training, etc.). Once ready, click Create:

jetstream-2-create-instance-2

…and wait until your instance is ready ⏳:

jetstream-2-wait-to-build

Part 3: Using your instance

Connect to your instance

Click on the instance.

jetstream-2-connect-to-instance

Once ready, you'll see a view similar to the one below:

jetstream-2-connect-to-instance-2

Under Interactions (lower left panel in the image), use the Native SSH command provided in your terminal to connect to your instance:

# replace with your key's path
# and your instance's IP
ssh -i ~/.ssh/your-private-key exouser@xxx.xxx.xxx.xxx

Part 4: Managing your instance

When you're not using your instance, please shelve it to save compute time for others. Once you've finished using it, please terminate (delete your instance).

jetstream-2-shelve-or-destroy

FAQ

How do I keep stuff running after logging out?

Consider using a terminal multiplexer. I use tmux (pretty heavily). You can learn more about first-time setup of tmux here: https://github.com/tmux/tmux/wiki

That's a lot of manual steps! Is this how everyone does it?

Jetstream 2 is built on top of an open source cloud computing platform called OpenStack. There are a number of tools for interacting programmatically with OpenStack.

If you're wanting to design a custom "instance source" (ex. a particular version of some OS with particular CUDA drivers pre-installed), you may find tools like Packer useful. There are tools like Terraform/OpenTofu that will allow you to configure and manage compute infrastructure as code. These tools can have a steep learning curve1, but they make deployments more reproducible and portable to other clouds.

Footnotes

  1. Part of the steepness of the learning curve is due to also needing to learn fundamental concepts of networking, storage, and access permissions for cloud computing.