CLOUD COMPUTING LAB
List of Experiments
1. Establish an AWS account. Use the AWS Management Console to launch an EC2
instance and connect to it.
2. Create your First AWS S3 Bucket and Upload Content to Bucket and Manage their
Access and Create Static Website using AWS S3 .
3. Create and configure storage services and upload files and objects using Amazon EBS
4. Create and configure storage services and upload files and objects using Amazon EFS
5. Creation of Amazon Lex Chat bot
6. Creation of S3 bucket and trigger by lambda to dynamo DB and make it available with
Cloud Front.
7. Pull the image from Docker to EC2 Instance and access it publicly.
8. Creation of Dynamo DB .
9. Create loosely coupled services with Amazon SQS and Amazon SNS to process data
received from the applications.
10. Create image recognition capability application using AWS Amazon Recognition.
EXPERIMENT 1
Establish an AWS account. Use the AWS Management Console to launch an EC2
instance and connect to it.
Creation of aws account:
Go to the AWS Website
• Visit https://aws.amazon.com
Click “Create an AWS Account”
• It's usually in the top right corner of the homepage.
Enter Your Account Information
• Email address (this will be your login)
• Account name (e.g., your business name or personal name)
• Password
Verify Your Email
• You’ll get a code sent to your email. Enter it to continue.
Choose Account Type
• Personal or Professional (for businesses)
• Fill in your name, phone number, and address.
Add Payment Information
• AWS requires a credit/debit card. You won’t be charged for services under the Free Tier,
but they need the info for identity and billing.
Identity Verification
• You might need to verify using a phone number or text message/voice call.
Choose a Support Plan
• Most people start with the Basic (Free) plan.
Login to AWS Console
• Once everything is set, go to https://console.aws.amazon.com
• Use your email and password to log in.
Step by step Procedure for EC2 Instance Creation
1. Open “EC2” in services
2. Launch an instance from EC2 dashboard
3. Provide name to the instance
4. Select the Operating system also known as AMI “ ubuntu”
5. Click on create a key pair
6. Enter a key pair name
7. A file will be downloaded. Save it for connect with SSH or Putty gen
8. In network settings create security group enable all the three SSH,HTTP,HTTPS.
9. Configure storage to 15GB (storage is our wish)
10. Click on launch instance
11. Successful initiation of instance
12. Goback to dash board of instances where an instance is initialized and is running then
Right click onto the instance and click on connect it.
13. Connect to instance, click on connect
14. Ec2 instance connect
15. Type sudo apt update
16. Type sudo apt install nginx
17. Do u want to continue: types yes
18. Copy and paste the IP address in the browser.
19. It Opens nginx server in the browser.
If the nginx is not opening in the browser then follow the following steps
20. The site can’t be reached so need to change the security settings
21. Go back to ec2 instance dashboard ,downside u have security tab
22. Click on security tab and select blue line security groups
23. The launch wizard will be as shown and edit the inbound rules
24. Add the rules -custom to “Alltrafic” and custom to “anywhere ipv4” and save rules
25. Saved changes and connect again then console will be opened.
26. Now paste the IP address in the browser.
Output:
EXPERIMENT 2
Create your First AWS S3 Bucket and Upload Content to Bucket and Manage their
Access and Create Static Website using AWS S3
Step by Stpe Procedure to create S3 bucket:
1. Click on S3 services.
2. Provide bucket name and enable the ACL’s enabled.
3. Unblock all the public access settings for the bucket
4. Check box the acknowledgement, disable bucket versioning.
5. Provide default encryption as amazon s3-managed keys and click on create bucket.
6. Bucket is successfully created.
7. After creation of bucket ,click on the bucket and go to permission tab, enable the ACL’s
permission to list and read.
8. Now right click on the bucket created, click on upload to upload A file here I uploaded cse.jpeg
9. Click on upload and the file is uploaded successfully.
10. After upload of file once again go to permission tab of object check whether ACL’s permission
to list and read is enabled or not.
11. Now go back to the file been uploaded into the bucket
12. Right click onto the file and go to properties, Copy the object url and paste in browser,will be
able to see the object uploaded publicly.
Output:
Cse.jpg
EXPERIMENT 3
(a) Create and configure storage services and upload files and objects using Amazon
EBS.
Step by step procedure for creation of EBS in same zone:
1. Open the Amazon EC2 console and Launch Ec2 Instance .
2. In the Left navigation pane, choose Elastic Block store..select Volumes.
3. Choose Create volume.
4. For Volume type, choose the type of volume to create select default ssd
5. For Size, enter the size of the volume, in GiB example 15GB.
6. For Availability Zone, choose the Availability Zone in which to create the volume. A volume
can be attached only to an instance that is in the same Availability Zone.
7. Choose Create volume and in actions selct attach and connect to the Running instance.
8. Note : The volume is ready for use when the Volume state is available.
9. Again In the left navigation pane, choose Volumes.
10. Select the volume which was created with 15GB ,enable it and choose Actions , Attach
volume.
11. Note :You can attach only volumes that are in the Available state.
12. For Instance, enter the ID of the instance or select the instance from the list of options.
13. Note :.The volume must be attached to an instance in the same Availability Zone.
14. For Device name, enter a supported device name for the volume. This device name is used by
Amazon EC2..
15. Choose Attach volume
16. Connect to the instance and mount the volume.
17. After that go t the instance dash board and click on storage then you will be able to see the
attached EBS volume to the instance.
Output:
(b) Step by step procedure for creation of EBS in Different zone:
Note: create 2 EC2 instances in 2 zones and create snapshot at one region and copy it to other
destination.
(1) Creating instance in Ohio:
•Go to the EC2 dashboard and Create a new instance by launching it.
•The Zone is at Ohio region.
•Click on launch Instance to create instance
•Name the instance as cse1
•The OS must be Ubuntu
•Now create a new key pair
•Provide name to the key pair something as key1
•Click on create key pair and key pair is successfully created
•Click on Launch Instance
•Instance is successfully Launched
(2) Another instance in Virginia :
• Now in another tab change the zone to Virginia
• The Zone is successfully changed to Virginia
• Click on launch Instance to create instance
• Name the instance as cse2
• The OS must be Ubuntu
• Now click on create new key pair to create a new keypair
• Create a new key pair
• Provide name to the key pair something as key2
• Click on create key pair and key pair is successfully created
• Configure the storage from 8 to 10 • Click on Launch Instance
• Instance is successfully Launched
(3) Creation of snapshot
• Go back to the instance 1 dashboard ,in the left pane at EBS select snapshot.
• Now in actions click on create a snapshot
• Now create a snapshot
• Add the description something as snapshot1 and create snapshot
• Snapshot is created successfully
• Now go to the snapshots
• The snapshot created will be shown. Now select the snapshot and go to actions
• Select copy snapshot option
• Now in copy snapshot add destination region as us-east1
• Snapshot is created successfully
(4)Accessing from second zone:
• Now go to the second instance created. In that check for snapshots
• We will find our snapshot that we created and status will be completed
Output:
EXPERIMENT 4
Create and configure storage services and upload files and objects using Amazon EFS
Note: Select OS Linux while doing EFS , use same security group and key pair for both instances and
select the subnet id for second instance other than first instance while creating security group
(1) Creating first instance and note down the availability zone and security group
• Create the first instance by launching the Instance
• Name the first instance to be launched as efs1
• Select The operating System as AWS Linux
• Create a Key pair and name it as nfs
• Create the key pair.
• Configure the network settings
• Provide all the permissions as shown by checking the boxes.
• Configure the storage from 8GB to 10GB
• Now Launch the instance.
• Instance 1 named efs1 is successfully launched.
(2) Creating Second instance and adding same security group, keypair and different availability zone
• Go back to the Dashboard of EC2 instance to create another instance.
• Check the availability zone and Security group in another tab so that for the second instance the
availabilty zone should be different and security group to be the same.
• Repeat the same process and create another instance with name as efs2 same as the previous
instance and use same key and security group for instance 2.
• Checking the Security group in another tab so that to apply it same to the instance 2 that we are
creating.
• Changing the security group as wizard2 as it was in instance1
• Now edit the same for the second instance2
• Select the existing security group for instance2
• Launch the instance2
• Instance 2 is also successfully launched
• The availability zones are different.
(3) Adding security group New Rule with NFS
• The Security groups are same, if we add both instances can be reflected.
• Select the first instance efs1
• Click on the security tab in dashboard of instance of efs1 click on the security groups
• Now select the inbound rules and edit the inbound rules,in the edit inbound rules click on add rule
• Add the rule , Select NFS and anywhere in IPV4.
• Save the changes and the saved changes will be successful.
(4) Creating EFS Service
• Go back to the dashboard and search for EFS, Now click on create file system
• Provide name to the file system something as efsdemo ,Let VPC be default and Storage class as
Standard and click on customize
• Click on Next and Removed all the previous provided Security Groups Network access.
• Apply the security group name same as the EC2 instances security group
• Click on next, Now click on Create.
• EFS created successfully.
(5) Mounting the EFS with instances from console
• Go back to instances
• Now go to efs1 i.e, instance 1 and right click the instance and connect to the instance.
• Connect to the instance, by Click on connect to establish connection
• Connection is being established
• After connection is established, Same step must be repeated for the second instance efs2 and
connection must be established.
• After connection is established, Type the below all commands in two instance consoles
1) sudo su
2) mkdir efs
3) yum install-y amazon-efs-utils
• Go back to the amazon aws console , in the services go back to efs service, right click on created efs
i.e. efsdemo
• Click on attach to mount efs,We are ,mounting via DNS ,Copying the command and pste in two
consoles.
(6) Creating EFS directory and files
• Type the commands in two consoles
- ls
- cd efs
• Now create a file in any one of the ec2 instance such that it must reflect in another instance
even. For example create file in instance1 must reflect in instance 2
• Type the command in one console
- touch file1 file2
- ls in any one of the instance.
• Touch file1 file2 to create files and ls to list the created files.
• In another instance(instance where touch command not used) type ls. It shows the created files l1
and l2
• In the other instance ,to remove the file type the command
- rm file1
- ls
Check the same ls command in the instance where we have created file1 and file2 after removal of
file1. It shows only file2 In this process Efs can be shared among ec2 instances with in the regions
Output:
EXPERIMENT 5
Creation of Amazon Lex chatbot.
Step by Step procedure to create amazon lex chatbot
• Select Amazon Lex service from console
• Now here click on -> create bot
• Here we have to select the Create a blank bot
• Give the name to the Bot here I have given BookingHotel
• we have select the create a role with basic Amazon Lex permission
• we have to give the children online privacy protection Act as No
• Select the language as English US
• We have different options ,here we select the “This is only text based application”
• We give the name for Intend, name as BookHotel
• Here we add the Sample Utterances
- Book a Hotel
- I want a make hotel reservations
- Book a {days} stay in {location} sample :Book a 3 nights stay in Mumbai
• Slots
(a)Name : days type: Amazon.number
Prompts : How many days want to stay
(b)Name : Location type: Amazon.city
Prompts : What city will you be staying in ?
• Again come back to sample utternaces and add the following :
- Book a {days} stay in {location}
• Save the intend ,build it and test it again
• Now test the chatbot.
Output:
EXPERIMENT 6
Creation of S3 bucket and trigger by lambda to dynamo DB and make it available
with Cloud Front.
1. Create S3 Bucket
2. Give Bucket Name
3. ACL should be enabled
4. Uncheck Block all public access
5. Check the box for I acknowledge that the current settings ….
6. Create Bucket., Upload the HTML file and grant ACL’s permissions.
7. Choose Properties of bucket →Edit Static website hosting → Enable static website hosting
→ Enter file name.html(the file what you have uploaded in the bucket, Example index.html)
8. Choose Permissions of the bucket and enable all the ACL’s read, write and so on.
9. Change object (html file uploaded) permissions also by enabling the all ACL; s permissions.
10. Save Changes.
11. Copy the Object URL and Test the URL, if not open check for the bucket and object permissions.
12. Search for Cloud front Distribution in aws services bar.
13. Create CloudFront Distribution
14. Select Bucket Name by dragging or placing the cursor, after that enable web site
checkpoint(showed after selecting the name )
15. Enable security firewall.
16. Click on Create Distribution, copy the distributed domain name and paste in browser.
17. If the DNS is not opening, edit the DNS link by removing the “s” in “https”
Example: https://d2nj.dns remove https://d2nj.dns
18. The DNS after removing also not opening, then go for bucket properties aand click the link
below to the web page hosting.
Output:
EXPERIMENT 7
Pull the image from Docker to EC2 Instance and access it publicly.
Step by Step procedure to pull the image from Docker to EC2 instance
1. Create the EC2 instance and connect with EC2 Console.
2. In the opened Console of EC2, Type the following commands to pull the image from docker
- sudo apt update / sudo apt-get update
- sudo apt install docker.io / sudo apt-get install docker .io
- sudo docker version
- sudo docker image ls (it shows the images list present in our Instance)
Note: we don’t have images in the instance because we didn’t pulled the image from docker
- sudo docker pull scott2srikanth/fileshare_docker-fdp (pull the image)
- sudo docker image ls (shows the image pulled in the list)
- sudo docker run –d –p 3000:3000 scott2srikanth/fsdreactdemo
Note: 3000:3000 first is inbound values we can change it….. but right side 3000 value is docker
bound values
we can changethe first value , example we can give 3008:3000- we can give the values between
3010 to 3090
• After run command it shows the image downloaded.
• Now we can access it publicly, by copying the EC2 public IP address shown below of the
console or EC2 dashboard.
• Copy the public ip and paste it on browser with inbound value.
Example: http://3.12.123.4:3008
Note: if it is not opening check
(a) whether u have given https or http or
(b) Go to dashboard, click on EC2 instance, it shows security tab. click on Edit inbound rules.
click on Add rule. select All traffic and anywhere from IPV4 and save it and refresh the
browser.
Finally, the pulled image will be displayed.
Output:
EXPERIMENT 8
Creation of Dynamo DB.
Step by Step Procedure for creation of DynamoDB
1.In the AWS services search for Dynamo DB
2. On the right side of the console, choose Create Table.
3.Enter the table details as follows:
For the table name, enter Music.
For the partition key, enter Artist.
Enter SongTitle as the sort key.
Leave Default settings selected
4.In the table list, choose the Music table.
5.Select Explore Table Items.
6. In the Items view, choose Create item.
7. Choose Add new attribute, and then choose Number. Name the field Awards.
8.Repeat this process and create another item with the following values:
- For Artist, enter Acme Band.
- For SongTitle enter Happy Day.
- For AlbumTitle, enter Songs About Life.
- For Awards, enter 10.
9. The table created.
10. To check the table items , go to the navigation pane on the left side of the console, choose Tables.
11. Choose the Music table from the table list.
12. Select the Explore table items.
13.On the Items tab, view the list of items stored in the table
14.To Update the data in tables
- Choose the Music table from the table list.
- Choose View items.
- Choose the item whose Artist value is Acme Band and SongTitle value is Happy Day.
- Update the AlbumTitle value to Updated Album Title, and then choose Save.
- It shows the updated item on the console.
15. To Search/Query the data in Tables Choose the Music table from the table list.
- Choose View items.
- Choose Query.
- For Partition key, enter Acme Band, and then choose Run.
Output:
EXPERIMENT 9
Create loosely coupled services with Amazon SQS and Amazon SNS to process data
received from the applications.
(a) Step by Step Procedure of Amazon SNS
Step 1: Open AWS SNS Console
• Go to: https://console.aws.amazon.com/sns/
• You can search “SNS” in the AWS console search bar and select Simple Notification Service
Step 2: Create a Topic
1. Click “Topics” from the sidebar
2. Click “Create topic”
3. Choose Topic type:
o Standard (default): High throughput, best-effort ordering
4. Enter a Topic name:
o E.g., MyTestTopic
5. Leave other settings as default or adjust based on your needs
6. Click “Create topic”
Step 3: Subscribe to the Topic
1. After creating the topic, click on its name
2. Click “Create subscription”
3. Configure the subscription:
o Protocol: Choose Email, SMS, Lambda, SQS, or HTTP/S
o For this example, choose Email
o Endpoint: Enter your email address (e.g., you@example.com)
4. Click “Create subscription”
Step 4: Confirm the Subscription
• Go to your email inbox
• You’ll receive a confirmation email from AWS SNS
• Click the confirmation link in the email to confirm the subscription
• Status will change from “Pending Confirmation” to “Confirmed” in the SNS console
Step 5: Publish a Message
1. Go back to the topic
2. Click “Publish message”
3. Fill out the message form:
o Subject: Test Subject
o Message body: Hello from AWS SNS!
4. Click “Publish message”
Step 6: Check Your Email
• The message will be delivered to your inbox from AWS Notifications
• Subject and body should match what you sent
Output:
(b) Step by Step Procedure of Amazon SQS
Step 1: Log into AWS Console
• Go to: https://console.aws.amazon.com/
• Navigate to Simple Queue Service (SQS) via search bar or Services > Application Integration >
SQS
Step 2: Create a New Queue
1. Click “Create queue”
2. Choose a Queue type:
o Standard: Best effort ordering, at-least-once delivery.
o FIFO: Strict ordering, exactly-once processing.
3. Enter Queue Name
o E.g., MyTestQueue
o FIFO queues must end with .fifo
4. Configure optional settings (leave default for basic setup)
o Visibility timeout, message retention, delivery delay, etc.
5. Click Create Queue
Step 3: Send a Message to the Queue
1. Select your queue from the list
2. Click “Send and receive messages”
3. Under Message body, enter a test message:
o E.g., Hello from SQS!
4. Click “Send message”
Step 4: Receive Messages from the Queue
1. Click “Poll for messages”
2. If a message is in the queue, it will appear in the list
3. You can click on the message to see:
o Message ID
o Body (your message)
o Attributes
4. After receiving, the message becomes invisible temporarily (due to the visibility timeout)
Step 5: Delete the Message
1. Select the message you want to delete
2. Click “Delete”
3. Confirm deletion
Output:
EXPERIMENT 10
Create image recognition capability application using AWS Amazon Recognition.
(a) Step by Step Procedure of AWS Amazon Recognition
Step 1: Open Amazon Rekognition Console
• Go to: https://console.aws.amazon.com/rekognition/
• You can search “Rekognition” from the AWS console search bar.
Step 2: Choose "Use Custom Labels" or "Demo Applications"
For basic testing:
• On the Rekognition console homepage, scroll down to "Demo applications"
• Click "Try Rekognition" under Image section
Step 3: Upload an Image
1. Under "Image Analysis", choose "Upload image"
2. Select an image from your local computer (e.g., a photo with objects, animals, etc.)
3. Click "Upload" or wait for the image to load
Step 4: View Detected Labels
• After uploading, Rekognition will process the image and display results like:
Step 5 (Optional): Use Other Features
You can also try:
• Face Detection: Shows number of faces and attributes (e.g., eyes open, smile)
• Text Detection: Extracts readable text from the image
• Celebrity Recognition: Identifies celebrities in the image
• Moderation Labels: Flags potentially unsafe content
Step 6: Programmatic Access (Optional)
You can use the AWS SDK (e.g., Python/Boto3) to use Rekognition programmatically:
Output: