Trending questions in AWS

+1 vote
2 answers

Read file content from S3 bucket with boto3

s3_client=boto3.resource('s3') bucket = s3_client.Bucket('test') for obj in bucket.objects.all(): contents=obj.get()['Body'].read().decode(encoding="utf-8",errors="ignore") for line ...READ MORE

Jul 4, 2019 in AWS by reddy

edited Jul 4, 2019 by Kalgi 43,357 views
0 votes
1 answer

ImportError: No module named boto3

Hi@akhtar, I think boto3 module is missing from ...READ MORE

Apr 28, 2020 in AWS by MD
• 95,440 points
24,096 views
0 votes
2 answers

An error occurred (AuthFailure) when calling the DescribeInstances operation: AWS was not able to validate the provided access credentials

After checking time and aws configure settings, ...READ MORE

Apr 11, 2020 in AWS by Arun Kumar
23,110 views
0 votes
2 answers

How to recover lost private key of an EC2 instance?

I'm afraid it's not possible When you launch ...READ MORE

Sep 25, 2018 in AWS by Archana
• 4,170 points
21,443 views
0 votes
1 answer

How to list contents of a bucket with boto3?

Hi@akhtar, You can create a session for an ...READ MORE

Sep 21, 2020 in AWS by MD
• 95,440 points
13,097 views
0 votes
1 answer

The Amazon CloudFront distribution is configured to block access from your country. We can't connect to the server for this app or website at this time.

Hi@akhtar, You got this error because you restricted ...READ MORE

Jun 5, 2020 in AWS by MD
• 95,440 points
17,759 views
0 votes
1 answer

An error occurred (ResourceNotFoundException) when calling the DescribeCluster operation: No cluster found for name: fargate-cluster.

Hi@akhtar, I think you need to tell your ...READ MORE

Jul 6, 2020 in AWS by MD
• 95,440 points
15,928 views
0 votes
1 answer

How to connect an EC2 linux instance to another Linux instance?

AWS EC2 instances are more like a ...READ MORE

Jul 16, 2019 in AWS by ArchanaNagur
• 2,360 points
30,914 views
0 votes
1 answer
0 votes
1 answer

How to execute commands on AWS Instance using Boto3?

Hi@akhtar, Boto represents an Amazon Web Services (AWS) ...READ MORE

Oct 7, 2020 in AWS by MD
• 95,440 points
9,892 views
+1 vote
1 answer

How to delete a folder in S3 bucket using boto3 using Python?

You can delete the folder by using ...READ MORE

Nov 30, 2018 in AWS by Aniket
38,872 views
0 votes
1 answer

dynamodb.ServiceResource' object has no attribute 'exceptions'.

Hi@akhtar, You'll need to use boto3.client('dynamodb') to be able to ...READ MORE

Jul 13, 2020 in AWS by MD
• 95,440 points
13,303 views
0 votes
1 answer

An error occurred (InvalidBucketName) when calling the CreateBucket operation: The specified bucket is not valid.

Hi@akhtar, You can't use an uppercase letter in ...READ MORE

Oct 7, 2020 in AWS by MD
• 95,440 points
8,553 views
+1 vote
1 answer

'No module named 'requests'' on the AWS Python Lambda function?

Hi@akhtar, For a detailed, You can even check ...READ MORE

Apr 15, 2020 in AWS by MD
• 95,440 points
16,015 views
+1 vote
1 answer

How to host a dynamic website on aws?

For hosting a dynamic website on AWS, ...READ MORE

Jan 27, 2020 in AWS by Oliver
19,349 views
0 votes
1 answer

How to get the last stopped time & date of EC2 instance?

Hi@akhtar, To get the details of your last ...READ MORE

Jun 16, 2020 in AWS by MD
• 95,440 points
13,190 views
0 votes
1 answer

Boto3 - python script to view all directories and files

There are no folders, only S3 object ...READ MORE

Sep 14, 2018 in AWS by Priyaj
• 58,090 points
40,882 views
0 votes
1 answer

How to download a file from S3 buckets using boto3?

Hi@akhtar, Boto3 supports upload_file() and download_file() APIs to ...READ MORE

Oct 8, 2020 in AWS by MD
• 95,440 points
7,901 views
0 votes
1 answer

Not able to browse image from s3 bucket, image downloading instead of displaying in browser.

Hi@akhtar, You have to pass the content_type of ...READ MORE

Jun 16, 2020 in AWS by MD
• 95,440 points
12,782 views
0 votes
2 answers

In AWS Cloud formation when I upload template it shows error: At least one Resources member must be defined

that's because you have resources defined in ...READ MORE

Oct 25, 2020 in AWS by Spyder
7,117 views
0 votes
1 answer

How to temporarily change the state of an alarm in CloudWatch?

Hi@akhtar, You can temporarily set the state of ...READ MORE

Nov 18, 2020 in AWS by MD
• 95,440 points
5,797 views
+1 vote
4 answers

AWS CLI - couldn't connect to endpoint URL

You probably have something wrong in your ...READ MORE

Oct 5, 2018 in AWS by Archana
• 4,170 points
32,727 views
+2 votes
1 answer

How to fix 504 error on AWS CloudFront?

This usually happens if it couldn't either ...READ MORE

Aug 5, 2020 in AWS by Sirajul
• 59,230 points
9,724 views
0 votes
1 answer

Unable to import module 'lambda_function': No module named 'pymongo' for mongodb with python in aws lambda.

Hi@pradip, I think you need to import some ...READ MORE

Nov 3, 2020 in AWS by MD
• 95,440 points
5,871 views
0 votes
1 answer

How to describe EC2 instances using Boto3?

Hi@akhtar, An EC2 instance is a virtual server ...READ MORE

Oct 8, 2020 in AWS by MD
• 95,440 points
6,350 views
0 votes
1 answer

Difference between Amazon ec2 and AWS Elastic Beanstalk.

EC2 EC2 is Amazon's service that allows you ...READ MORE

Jul 9, 2018 in AWS by Priyaj
• 58,090 points
41,923 views
+1 vote
1 answer

bash: aws: command not found...

Hi@akhtar, Actually this is not an error. When ...READ MORE

Apr 27, 2020 in AWS by MD
• 95,440 points
13,179 views
0 votes
1 answer

How to delete huge data from DynamoDB table in AWS?

Hi@akhtar, If you required to delete all the ...READ MORE

Dec 16, 2020 in AWS by MD
• 95,440 points
2,948 views
+3 votes
10 answers

Difference between s3n, s3a and s3?

S3 Native FileSystem (URI scheme: s3n) A ...READ MORE

Oct 25, 2018 in AWS by Rishab rohan
39,561 views
+2 votes
1 answer

What is Inbound and Outbound rule in aws?

Hi@akhtar, Inbound means incoming traffic coming to your ...READ MORE

Mar 4, 2020 in AWS by MD
• 95,440 points

edited Sep 6, 2023 by Khan Sarfaraz 15,234 views
0 votes
1 answer

How to Describe security groups with Boto3?

Hi@akhtar, An EC2 instance is a virtual server ...READ MORE

Oct 8, 2020 in AWS by MD
• 95,440 points
5,822 views
0 votes
1 answer

How to terminate EC2 instance using boto3?

Hi@akhtar, We can create and modify an EC2 ...READ MORE

Oct 7, 2020 in AWS by MD
• 95,440 points
5,856 views
0 votes
1 answer

How to disable actions for an alarm in AWS?

Hi@akhtar, You can disable the actions for the specified ...READ MORE

Nov 18, 2020 in AWS by MD
• 95,440 points
4,005 views
0 votes
1 answer

How to clear the credentials in AWS Configure?

Hi@akhtar, You need to remove the configuration file ...READ MORE

Nov 17, 2020 in AWS by MD
• 95,440 points
3,945 views
0 votes
1 answer

A characteristic of edge locations is

Hi@anjali, An edge location is where end-users access services located ...READ MORE

Nov 19, 2020 in AWS by MD
• 95,440 points
3,800 views
+3 votes
6 answers

Renaming files in S3

You can either use AWS CLI or ...READ MORE

Oct 16, 2018 in AWS by petter dj
29,917 views
0 votes
1 answer

How to delete a file from a branch in AWS CodeCommit?

Hi@akhtar, The following delete-file example demonstrates how to ...READ MORE

Nov 24, 2020 in AWS by MD
• 95,440 points
3,534 views
+1 vote
1 answer

How should we need to pay for AWS ACM CA Private Certificate?

Hi@Lakshminarayanan, In the document it is written that ...READ MORE

Dec 24, 2020 in AWS by MD
• 95,440 points
1,823 views
0 votes
1 answer

How to install eksctl command in Windows?

Hi@akhtar, You can use the below-given steps to ...READ MORE

Jul 5, 2020 in AWS by MD
• 95,440 points
9,230 views
0 votes
1 answer

How to find exact stopped time of AWS EC2 instances?

Hi@Lakshminarayanan, You can use InstanceState Data Types in your ...READ MORE

Dec 3, 2020 in AWS by MD
• 95,440 points
2,711 views
0 votes
3 answers

How to check instance state and status via Lambda function in AWS?

import boto3 from pprint import pprint def lambda_handler(event, context):          # ...READ MORE

Sep 8, 2020 in AWS by Shrikant
• 180 points
9,668 views
0 votes
1 answer

What does ECU units, CPU core and memory mean in EC2 instance?

Hi@MD, ECU means Amazon EC2 compute unit. Amazon ...READ MORE

Dec 16, 2020 in AWS by akhtar
• 38,230 points
1,943 views
0 votes
1 answer

How to decrease my AMI size in AWS Cloud?

Hi@Lakshminarayanan, You can't decrease the volume size directly. ...READ MORE

Dec 10, 2020 in AWS by MD
• 95,440 points
2,197 views
0 votes
1 answer

How to uninstall aws-cli?

Hi@akhtar, I also faced a similar type of ...READ MORE

Dec 8, 2020 in AWS by MD
• 95,440 points
2,247 views
+3 votes
6 answers

How to move files from amazon ec2 to s3 bucket using command line

Hey, 3 ways you can do this: To ...READ MORE

Oct 9, 2018 in AWS by Omkar
• 69,210 points
19,250 views
+2 votes
1 answer

How to print all the instance-id and instance-state using Python boto3

You can simply loop through using a ...READ MORE

Dec 3, 2018 in AWS by Nabarupa
33,864 views
0 votes
1 answer

How to delete an origin access identity in Cloudfront?

Hi@akhtar, You can delete your origin access identity ...READ MORE

Nov 2, 2020 in AWS by MD
• 95,440 points
3,703 views
0 votes
1 answer

AttributeError: 'ec2.ServiceResource' object has no attribute 'send_command'

Hi@Lakshminarayanan, The send_command attribute is not available in ...READ MORE

Oct 7, 2020 in AWS by MD
• 95,440 points
4,669 views
0 votes
1 answer

An error occurred (BadRequestException) when calling the UpdateRestApi operation: Invalid patch path /tags/keytest.

Hi@akhtar, You need to use the tag-resource method instead ...READ MORE

Dec 8, 2020 in AWS by MD
• 95,440 points
1,923 views