loopback在Linux上包含分区表的文件中安装单个分区 [英] loopback mounting individual partitions from within a file that contains a partition table on linux

查看:297
本文介绍了loopback在Linux上包含分区表的文件中安装单个分区的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

有什么新的/更好的方式来回放在Linux上包含分区表的文件中的单个分区?我看到以下内容,但有些过时。

http://linux.derkeiler.com/Mailing-Lists/Kernel/2005-01/7183.html



http://lists.gnu.org/archive /html/grub-devel/2005-01/msg00077.html



ftp://ftp.hq.nasa.gov/pub/ig/ccd/enhanced_loopback/

解决方案

假设$ IMAGE设置为图像文件的路径。
您可以使用

  fdisk -u sector -l $ IMAGE 

获取图像中的分区列表。然后使用一系列的

  mount -o ro,loop,offset = $ OFFSET -t auto $ IMAGE / media / $ DEST 

其中offset是指fdisk中的信息(扇区的起始扇区*大小,以字节为单位)和$ DEST每个分区的唯一名称。

这不是直接的解决方案,但我希望有一个很好的指示如何实现它。如果你一次做这个工作,那么对于一些取证工具来说,你有一些不错的开始!


Is there any new/better way of loopback mounting individual partitions from within a file that contains a partition table on linux? I see the following but they are somewhat dated.

http://linux.derkeiler.com/Mailing-Lists/Kernel/2005-01/7183.html

http://lists.gnu.org/archive/html/grub-devel/2005-01/msg00077.html

ftp://ftp.hq.nasa.gov/pub/ig/ccd/enhanced_loopback/

解决方案

Let's say $IMAGE is set to the path to your image file. You could write a small script by using

fdisk -u sectors -l $IMAGE

to get a list of partitions inside the image. And then use a sequence of

mount -o ro,loop,offset=$OFFSET -t auto $IMAGE /media/$DEST

Where offset is calculated means the info from fdisk (start sector * size of a sector in bytes) and $DEST a unique name for each of the partitions.

That's not directly the solution but I hope a pretty good indication on how to realize it. If you make the job once, you've some small nice beginning for some forensic toolkit!​​​​​​​​​​​​​​​​​​​​​

这篇关于loopback在Linux上包含分区表的文件中安装单个分区的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆