From c6241ae97d81a7bd6d176deef6f7b0c256aa7d5c Mon Sep 17 00:00:00 2001 From: "rick.chan" Date: Thu, 7 Jan 2021 15:01:50 +0800 Subject: [PATCH] =?UTF-8?q?=E5=A2=9E=E5=8A=A0=20Linux=20=E6=8C=82=E8=BD=BD?= =?UTF-8?q?=20Image=20=E6=96=87=E4=BB=B6.?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: rick.chan --- .../System/Linux/Linux_挂载_Image_文件.md | 20 +++++++++++++++++++ 1 file changed, 20 insertions(+) create mode 100644 Software/System/Linux/Linux_挂载_Image_文件.md diff --git a/Software/System/Linux/Linux_挂载_Image_文件.md b/Software/System/Linux/Linux_挂载_Image_文件.md new file mode 100644 index 0000000..e2e5a20 --- /dev/null +++ b/Software/System/Linux/Linux_挂载_Image_文件.md @@ -0,0 +1,20 @@ +# Linux 挂载 Image 文件 + +```bash +sudo fdisk -lu +# 显示类似如下信息 +Device Boot Start End Blocks Id System + * 2048 1026047 512000 83 Linux +``` + +将 Start\*512 得到 mount 的 offset(512 是一个扇区的大小,以上面为例子就是 2048\*512)。 + +```bash +sudo mount -o loop,offset= +``` + +使用完毕后用如下命令卸载: + +```bash +sudo umount +```