AWS EC2另添加新的EBS
总步骤:
- 去到AWS console 创建新的EBS和attach去原有的EC2 instance
注意:EBS和EC2必须是同一个可用区,否则无法绑定 - Attach了之后就需要SSH进OS当中mount起来
EBS Mouting的方法(Linux)
- lsblk 显示所有的EBS

2. sudo file -s /dev/xvdf
这个命令是查看这硬碟当中有没有文件系统,如果出现data就是没有。

3. sudo mkfs -t xfs -f /dev/xvdf
这命令是创建文件系统,如果根据上一步有文件系统的话这一步就略过

4. 创建Test 文件夹,然后跟硬碟绑定,最后是查看是否绑定成功
sudo mkdir /test
sudo mount /dev/xvdf /test
df -h

参考资料:
https://www.youtube.com/watch?v=VnO3Lz7Qr0U
https://docs.aws.amazon.com/zh_cn/AWSEC2/latest/UserGuide/ebs-using-volumes.html
Facebook评论