0

Trying to mount volume but not working. lsblk saying:

NAME                          MAJ:MIN RM   SIZE RO TYPE MOUNTPOINT
nvme0n1                       259:4    0    20G  0 disk 
├─nvme0n1p1                   259:5    0     8G  0 part /
└─nvme0n1p128                 259:6    0     1M  0 part 
nvme3n1                       259:3    0 838.2G  0 disk 
nvme2n1                       259:2    0 838.2G  0 disk 
nvme1n1                       259:0    0    22G  0 disk 
└─nvme1n1p1                   259:1    0    22G  0 part 
  ├─docker-docker--pool_tdata 253:1    0  21.7G  0 lvm  
  │ └─docker-docker--pool     253:2    0  21.7G  0 lvm  
  └─docker-docker--pool_tmeta 253:0    0    24M  0 lvm  
    └─docker-docker--pool     253:2    0  21.7G  0 lvm

and I want to mount either those 12G unmounted from nvme0n1 or 22G from nvme1n1. sudo file -s /dev/nvme1n1 is returning:

/dev/nvme1n1: DOS/MBR boot sector; partition 1 : ID=0x8e, start-CHS (0x0,32,33), end-CHS (0x3ff,254,63), startsector 2048, 46135296 sectors

Does it mean I have the file system? If yes, when I run sudo mount /dev/nvme1n1 /data it returns

mount: /dev/nvme1n1 is already mounted or /home/ec2-user/data busy

What am I doing wrong?

MTT
  • 101
  • 2

2 Answers2

1

lsblk shows that nvme1n1 contains one partition, which contains two LVMs.

You need to use LVM tools to enable the logical volumes:

vgchange -ay activates all LVM volumes.

Then you can mount volumes: mount /dev/vg/docker-docker--pool_tdata /data.

However, it might be that those are backing stores for Docker volumes, that are supposed to be used with Docker containers. In that case, you need to start the containers that use these as backing store.

Tero Kilkanen
  • 36,796
  • 3
  • 41
  • 63
1

As you shared details: root volume /dev/nvme0n1 has a partition /dev/nvme0n1p1 and size of the root volume is showing 20GB and 8GB of the partition.

It must be extended, and to extend the partition on the root volume, you can use the following growpart command.

sudo growpart /dev/nvme0n1 1

After that you can check your partition details by using the lsblk command and then you can extend you file system.

Click here is link of AWS user guide or https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/recognize-expanded-volume-linux.html

kenlukas
  • 3,101
  • 2
  • 16
  • 26
Tyagi
  • 111
  • 1