question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Name tag not applied for volume when creating a snapshot

See original GitHub issue

Hi all,

I have an issue regarding the process of creating a snapshot for a certain EBS volume class by using boto3. It seems that, even though i declare a Name tag explicitly, that tag doesn’t get saved. I eventually end up with a blank name tag on the Snapshot declaration: screen shot 2016-10-27 at 4 55 29 pm

This is how my code essentially looks like: I have a volume object:

type(volume)
<class 'boto3.resources.factory.ec2.Volume'>

The rest:

tags = [{'Key': 'Name', 'Value': 'some-name'}]
    volume.create_tags(Tags=tags)
    volume.create_snapshot(
        VolumeId=volume.id,
        Description=description
    )

Am i missing something here, or is this a bug? Please help

Issue Analytics

  • State:closed
  • Created 7 years ago
  • Comments:5 (2 by maintainers)

github_iconTop GitHub Comments

1reaction
mpavlisincommented, Oct 28, 2016

I see your point. Thank you @JordonPhillips . I will close this then, appreciate the help!

1reaction
JordonPhillipscommented, Oct 28, 2016

boto2 would do that, however doing so is an opinionated decision that could not be opted out of. That additional request costs you both money and time and prevents you from adding other tags in the request to make the most out of it. For those reasons (and several others) we avoid making requests on your behalf when you haven’t explicitly initiated them.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Tag Amazon EBS Snapshots on Creation and Implement ...
be present on the volume from which snapshots are being created. It requires that this tag be applied to all newly created snapshots....
Read more >
Tagging AWS EC2 unnamed EC2 volumes with a PowerShell ...
The NoNameTagVolumeList is iterated over and name tags are created from either the name tag of the instance the volume the snapshot was...
Read more >
create a snapshot to a EBS volume with tags
I found a better Lambda script which takes snapshot of EBS volume(Secondary volume) based on ec2 instance tags. For example, if your ec2 ......
Read more >
Given a tag, search for the most recent snapshot, create ...
Given a tag, search for the most recent snapshot, create a volume and mount it. print 'done! '
Read more >
create-snapshot — AWS CLI 2.1.29 Command Reference
The ID of the EBS volume. --tag-specifications (list). The tags to apply to the snapshot during creation. (structure). The tags to apply to...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found