hands-on lab

Using Attributes to Constrain Marathon Container Scheduling in DC/OS

Difficulty: Beginner
Duration: Up to 50 minutes
Students: 50
This lab is currently under maintenance and unavailable. We are actively working to resolve this issue and we apologize for any inconvenience.

DC/OS was declared end of life October 31, 2021 and the content is no longer maintained

Get guided in a real environmentPractice with a step-by-step scenario in a real, provisioned environment.
Learn and validateUse validations to check your solutions every step of the way.
See resultsTrack your knowledge and monitor your progress.

Description

Lab Overview

Agents in a DC/OS cluster can be assigned attributes. Attributes are a kind of metadata that you can use to organize your infrastructure. Attributes can be used to indicate which physical server rack an agent resides in, what special hardware or software capabilities an agent has access to or anything else that can be useful in identifying agents. The Marathon container orchestration tool can incorporate attribute constraints when it schedules applications in the cluster. By using attributes to constrain Marathon container scheduling in DC/OS you will launch fault-tolerant, resource-aware container applications in this Lab.

Lab Objectives

Upon completion of this Lab you will be able to:

  • Assign attributes to agents in a DC/OS cluster
  • Write Marathon application definitions with constraints
  • Diagnose Marathon scheduling failures in the DC/OS GUI

Lab Prerequisites

You should be familiar with:

  • Basic DC/OS concepts including master nodes, agents, services, tasks, and Marathon
  • Working at the command-line in Linux
  • AWS services knowledge is useful in order to understand the architecture of the pre-created DC/OS cluster, but not required

Lab Environment

Before completing the Lab instructions, the environment will look as follows:

After completing the Lab instructions, the environment should look similar to:

Updates

August 1st, 2021 - Resolved an issue preventing the DC/OS cluster from provisioning

October 2nd, 2020 - Replaced CoreOS virtual machines (no longer available in AWS) with CentOS

January 10th, 2019 - Added a validation Lab Step to check the work you perform in the Lab

Covered topics

Lab steps

Logging In to the Amazon Web Services Console
Understanding the DC/OS Cluster Architecture
Connecting to the DC/OS Cluster NAT Instance using SSH with Agent Forwarding
Adding Agent Attributes to DC/OS Nodes
Using Attributes to Constrain Marathon Applications
Validate AWS Lab