Turn Your Vehicle Into a Smart Earning Asset

While you’re not driving your car or bike, it can still be working for you. MOTOSHARE helps you earn passive income by connecting your vehicle with trusted renters in your city.

🚗 You set the rental price
🔐 Secure bookings with verified renters
📍 Track your vehicle with GPS integration
💰 Start earning within 48 hours

Join as a Partner Today

It’s simple, safe, and rewarding. Your vehicle. Your rules. Your earnings.

AWS Tutorial: How to Attach and Mount an EBS volume to EC2 Linux Instance?

Step 1 – Create a Volume

Step 2 – Attach a Volume to EC2 Instance

Step 3 – Verify if Volume is attached or not

Verify if Volume is attached or not by running linux command in Ec2-instance

$ lsblk

Step 4 – Check if the volume has any data using the following command.

If the above command output shows “/dev/xvdf: data“, it means your volume is empty.

$ sudo file -s /dev/xvdf

Step 5: Format the volume to the ext4 filesystem using the following command.

Alternatively, you can also use the xfs format. You have to use either ext4 or xfs.

$ sudo mkfs -t ext4 /dev/xvdf
$ sudo mkfs -t xfs /dev/xvdf

Step 6: Create a directory of your choice to mount our new ext4 volume. I am using the name “newvolume“. You can name it something meaningful to you.

$ sudo mkdir /newvolume

Step 7: Mount the volume to “newvolume” directory using the following command.

$ sudo mount /dev/xvdf /newvolume/

Step 8: cd into newvolume directory and check the disk space to validate the volume mount.

$ cd /newvolume
$ df -h .

The above command should show the free space in the newvolume directory.
To unmount the volume, use the unmount command as shown below..
umount /dev/xvdf

Mount one EBS volume to Multiple EC2 Instances

If you have any use case to mount an EBS volume to multiple ec2 instances, you can do it via EBS multi-attach functionality.

This option only serves specific use-cases where multiple machines need to read/write to the same storage location concurrently.

EBS multi attach option is available only for Provisioned IOPS (PIOPS) EBS volume types.

Note: EBS multi-attach does not support XFSEXT2EXT4, and NTFS file systems. It supports only cluster-aware file systems.

Subscribe
Notify of
guest
0 Comments
Newest
Oldest Most Voted
Inline Feedbacks
View all comments

Certification Courses

DevOpsSchool has introduced a series of professional certification courses designed to enhance your skills and expertise in cutting-edge technologies and methodologies. Whether you are aiming to excel in development, security, or operations, these certifications provide a comprehensive learning experience. Explore the following programs:

DevOps Certification, SRE Certification, and DevSecOps Certification by DevOpsSchool

Explore our DevOps Certification, SRE Certification, and DevSecOps Certification programs at DevOpsSchool. Gain the expertise needed to excel in your career with hands-on training and globally recognized certifications.

0
Would love your thoughts, please comment.x
()
x