14
votes

Trying to mount a 384G volume from old instance to a newly configure instance (8G). Attached 384G volume shows up on lsblk but on df -h it doesn't come up at all. What am I doing wrong?

[ec2-user@ip-10-111-111-111 ~]$ lsblk
NAME  MAJ:MIN RM  SIZE RO TYPE MOUNTPOINT
xvdf  202:80   0  384G  0 disk 
xvda1 202:1    0    8G  0 disk /

[ec2-user@ip-10-111-111-111 ~]$ df -h
Filesystem      Size  Used Avail Use% Mounted on
/dev/xvda1      7.9G  1.5G  6.4G  19% /
tmpfs           1.9G     0  1.9G   0% /dev/shm

Note: On EC2 instance dashboard it displays

Root device: /dev/sda1 Block devices: /dev/sda1 /dev/sdf

2
For reference, Amazon has a page detailing how to mount EBS volumes here: docs.aws.amazon.com/AWSEC2/latest/UserGuide/…Nick Chammas

2 Answers

15
votes

For those landing here after not finding their xvdf devices on aws ec2 c5 or m5 instances, it's renamed to /dev/nvme... as per the docs

For C5 and M5 instances, EBS volumes are exposed as NVMe block devices. The device names that you specify are renamed using NVMe device names (/dev/nvme[0-26]n1). For more information, see Amazon EBS and NVMe.

14
votes

The df -k will only show mounted volumes. You will need to mount your volume first, like this mount /dev/xvdf /mnt then you will be able to access it's content from /mnt and see it when typing df -k