[HTML payload içeriği buraya]
30.9 C
Jakarta
Monday, November 25, 2024

Amazon ECS helps a local integration with Amazon EBS volumes for data-intensive workloads


Voiced by Polly

At the moment we’re asserting that Amazon Elastic Container Service (Amazon ECS) helps an integration with Amazon Elastic Block Retailer (Amazon EBS), making it simpler to run a wider vary of knowledge processing workloads. You may provision Amazon EBS storage in your ECS duties working on AWS Fargate and Amazon Elastic Compute Cloud (Amazon EC2) while not having to handle storage or compute.

Many organizations select to deploy their purposes as containerized packages, and with the introduction of Amazon ECS integration with Amazon EBS, organizations can now run extra forms of workloads than earlier than.

You may run knowledge workloads requiring storage that helps excessive transaction volumes and throughput, akin to extract, rework, and cargo (ETL) jobs for giant knowledge, which have to fetch present knowledge, carry out processing, and retailer this processed knowledge for downstream use. As a result of the storage lifecycle is absolutely managed by Amazon ECS, you don’t have to construct any further scaffolding to handle infrastructure updates, and in consequence, your knowledge processing workloads at the moment are extra resilient whereas concurrently requiring much less effort to handle.

Now you may select from a wide range of storage choices in your containerized purposes working on Amazon ECS:

  • Your Fargate duties get 20 GiB of ephemeral storage by default. For purposes that want further cupboard space to obtain massive container pictures or for scratch work, you may configure as much as 200 GiB of ephemeral storage in your Fargate duties.
  • For purposes that span many duties that want concurrent entry to a shared dataset, you may configure Amazon ECS to mount the Amazon Elastic File System (Amazon EFS) file system to your ECS duties working on each EC2 and Fargate. Widespread examples of such workloads embrace net purposes akin to content material administration techniques, inner DevOps instruments, and machine studying (ML) frameworks. Amazon EFS is designed to be out there throughout a Area and may be concurrently hooked up to many duties.
  • For purposes that want high-performance, low-cost storage that doesn’t must be shared throughout duties, you may configure Amazon ECS to provision and connect Amazon EBS storage to your duties working on each Amazon EC2 and Fargate. Amazon EBS is designed to offer block storage with low latency and excessive efficiency inside an Availability Zone.

To be taught extra, see Utilizing knowledge volumes in Amazon ECS duties and persistent storage greatest practices within the AWS documentation.

Getting began with EBS quantity integration to your ECS duties
You may configure the quantity mount level in your container within the activity definition and move Amazon EBS storage necessities in your Amazon ECS activity at runtime. For many use instances, you may get began by merely offering the dimensions of the quantity wanted for the duty. Optionally, you may configure all EBS quantity attributes and the file system you need the quantity formatted with.

1. Create a activity definition
Go to the Amazon ECS console, navigate to Activity definitions, and select Create new activity definition.

Within the Storage part, select Configure at deployment to set EBS quantity as a brand new configuration sort. You may provision and connect one quantity per activity for Linux file techniques.

While you select Configure at activity definition creation, you may configure present storage choices akin to bind mounts, Docker volumes, EFS volumes, Amazon FSx for Home windows File Server volumes, or Fargate ephemeral storage.

Now you may choose a container within the activity definition, the supply EBS quantity, and supply a mount path the place the quantity can be mounted within the activity.

You may as well use $aws ecs register-task-definition --cli-input-json file://instance.json command line to register a activity definition so as to add an EBS quantity. The next snippet is a pattern, and activity definitions are saved in JSON format.

{
    "household": "nginx"
    ...
    "containerDefinitions": [
        {
            ...
            "mountPoints": [
                "containerPath": "/foo",
                "sourceVolume": "new-ebs-volume"
            ],
            "title": "nginx",
            "picture": "nginx"
        }
    ],
    "volumes": [
       {
           "name": "new-ebs-volume",
           "configuredAtLaunch": true
       }
    ]
}

2. Deploy and run your activity with EBS quantity
Go to your ECS cluster and select Run new activity. Notice that you could choose the compute choices, the launch sort, and your activity definition.

Notice: Whereas this instance goes by way of deploying a standalone activity with an hooked up EBS quantity, you may as well configure a brand new or present ECS service to make use of EBS volumes with the specified configuration.

You’ve gotten a brand new Quantity part the place you may configure the extra storage. The quantity title, sort, and mount factors are people who you outlined in your activity definition. Select your EBS quantity varieties, sizes (GiB), IOPS, and the specified throughput.

You can not connect an present EBS quantity to an ECS activity. However if you wish to create a quantity from an present snapshot, you’ve got the choice to decide on your snapshot ID. If you wish to create a brand new quantity, then you may go away this subject empty. You may select the file system sort: ext3, ext4, or xfs file techniques on Linux.

By default, when a activity is terminated, Amazon ECS deletes the hooked up quantity. If you happen to want the information within the EBS quantity to be retained after the duty exits, uncheck Delete on termination. Additionally, you might want to create an AWS Id and Entry Administration (IAM) function for quantity administration that comprises the related permissions to permit Amazon ECS to make API calls in your behalf. For extra data on this coverage, see infrastructure function within the AWS documentation.

You may as well configure encryption by default in your EBS volumes utilizing both Amazon managed keys and buyer managed keys. To be taught extra in regards to the choices, see our Amazon EBS encryption within the AWS documentation.

After configuring all activity settings, select Create to start out your activity.

3. Deploy and run your activity with EBS quantity
As soon as your activity has began, you may see the quantity data on the duty particulars web page. Select a activity and choose the Volumes tab to search out your created EBS quantity particulars.

Your workforce can arrange the event and operations of EBS volumes extra effectively. For instance, software builders can configure the trail the place your software expects storage to be out there within the activity definition, and DevOps engineers can configure the precise EBS quantity attributes at runtime when the appliance is deployed.

This permits DevOps engineers to deploy the identical activity definition to completely different environments with differing EBS quantity configurations, for instance, gp3 volumes within the improvement environments and io2 volumes in manufacturing.

Now out there
Amazon ECS integration with Amazon EBS is accessible in 9 AWS Areas: US East (Ohio), US East (N. Virginia), US West (Oregon), Asia Pacific (Singapore), Asia Pacific (Sydney), Asia Pacific (Tokyo), Europe (Frankfurt), Europe (Eire), and Europe (Stockholm). Verify the full area checklist for future updates. You solely pay for what you employ, together with EBS volumes and snapshots. To be taught extra, see the Amazon EBS pricing web page and Amazon EBS volumes in ECS within the AWS documentation.

Give it a attempt now and ship suggestions to our public roadmap, AWS re:Submit for Amazon ECS, or by way of your standard AWS Assist contacts.

Channy

P.S. Particular because of Maish Saidel-Keesing, a senior enterprise developer advocate at AWS for his contribution in scripting this weblog put up.

A correction was made on January 12, 2024: An earlier model of this put up misstated: I modified 1) from “both ext3 or ext4” to “ext3, ext4, or xfs”, 2) from “verify Delete on termination” to “uncheck Delete on termination”, 3) from “configure encryption”, “by default configure encryption”, and 4) from “activity definition particulars web page” to “activity particulars web page”.



Related Articles

LEAVE A REPLY

Please enter your comment!
Please enter your name here

Latest Articles