linux - 无法将磁盘挂载到目录

标签 linux

我在将磁盘安装到目录时遇到此错误。请让我知道我该怎么办?

[root@ip-172-31-39-36 ec2-user]# lsblk
NAME    MAJ:MIN RM  SIZE RO TYPE MOUNTPOINT
xvda    202:0    0    8G  0 disk
└─xvda1 202:1    0    8G  0 part /
xvdf    202:80   0  100G  0 disk
[root@ip-172-31-39-36 ec2-user]# mkdir filesystem
[root@ip-172-31-39-36 ec2-user]# mount /dev/xvdf /filesystem
mount: mount point /filesystem does not exist
[root@ip-172-31-39-36 ec2-user]# ls
filesystem  
[root@ip-172-31-39-36 ec2-user]# mount /dev/xvdf /filesystem
mount: mount point /filesystem does not exist

最佳答案

您正在当前目录中而不是根目录下创建一个名为filesystem的目录。以下任一修复应该有效:

A.在根目录下创建文件系统目录

[root@ip-172-31-39-36 ec2-user]# mkdir /filesystem

[root@ip-172-31-39-36 ec2-user]# mount /dev/xvdf /filesystem

B.使用当前目录下创建的文件系统目录作为挂载点

[root@ip-172-31-39-36 ec2-user]# mkdir filesystem
[root@ip-172-31-39-36 ec2-user]# mount /dev/xvdf filesystem

关于linux - 无法将磁盘挂载到目录,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/60530436/

相关文章:

php - 使用 PHP 将 Linux 命令的结果输出到表中

c - 如何在 Linux 上编译 'C' 应用程序并在 Solaris 上正常编译和运行?

linux - 检查两个目录是否在haskell中的同一文件系统上

linux - GoogleTest CMake 无法识别 TEST_F : Like it's not recognizing GTest something

c++ - 在使用不同于目标发行版的编译器进行构建时,处理库依赖关系的常用方法是什么?

linux - 是否可以实现用 Apple Swift 语言编写的跨平台(在 OS X 和 Linux 上编译和运行)GUI 应用程序?

linux - 我怎样才能使我的 Makefile 更好?

c++ - 尝试使用 Qt 和 OpenCV 从高清网络摄像头获取 1080p 实时视频只能获取 480p

linux - 如何更改我的 git 的语言?

android - android中的pidstat命令?