大网数据广告活动
服务器运维问答

Which EBS drive attached to my Amazon EC2 instance contains root volume?

· 52CE 我爱测

I have an Amazon EC2 instance that has two EBS drives associated with it: an 8 GB drive at /dev/sda1 , and a 20 GB drive at /dev/sdf . I didn't set this up so I'm not sure why this instance needs two drives of those sizes. I'm tr…

问题原文

原帖链接 · Eric · CC BY-SA 3.0

I have an Amazon EC2 instance that has two EBS drives associated with it: an 8 GB drive at /dev/sda1, and a 20 GB drive at /dev/sdf. I didn't set this up so I'm not sure why this instance needs two drives of those sizes.

I'm trying to figure out which of these two EBS drives contains the root (/) volume. (My goal is to disconnect that drive and attach it to another instance, where I can gain access to a key file I need at /home/ec2-user/.ssh/authorized_keys, per this excellent answer.)

How can I tell? (What is /sda1 and /sdf?)

已采纳解答

原帖链接 · Aditya Patawari · CC BY-SA 3.0

Just do a df -h. This will tell you if the 8G disk is mounted on / or the 20G one. Then just go to the EC2 web console and detach the disk.

"sda" term us usually used for SCSI drivers. I suggest you to read up a bit about Linux device files. It'll help you a lot.

摘自公开归档,保留原文语言,版式经整理,外部媒体与邮箱地址已移除。

资料来源与适用范围

资料来源
Server Fault
适用范围
以原帖系统、软件版本与发布日期为准(2013-02-22)
内容语言
中文;命令、路径和错误标识保留技术原文
本地收录日期
2026-11-15
授权说明
CC BY-SA 3.0

正文与所需资源由本站本地存储。查看来源及更新记录 ↗

请按适用版本和实际日志确认原因;本站没有对每一种系统或设备逐项执行文中的操作。