请教mount loop

isrunnIng 2005-03-05 08:11:52
mount -o loop boot.rom /mnt/xxx

什么意思?其中的loop到底有什么用的?
...全文
1383 6 打赏 收藏 转发到动态 举报
AI 作业
写回复
用AI写文章
6 条回复
切换为时间正序
请发表友善的回复…
发表回复
蓝色玺印 2005-04-06
  • 打赏
  • 举报
回复
挂载iso镜像文件
isrunnIng 2005-03-12
  • 打赏
  • 举报
回复
没有人回答吗?
tkit 2005-03-06
  • 打赏
  • 举报
回复
可以拆分成两个步骤:
losetup /dev/loop1 boot.rom
mount /dev/loop1 /mnt/xxx

boot.rom 是一个普通文件,但是其内容包含文件内容
Wolf0403 2005-03-06
  • 打赏
  • 举报
回复
mount(1):

THE LOOP DEVICE
One further possible type is a mount via the loop device. For example, the command

mount /tmp/fdimage /mnt -t msdos -o loop=/dev/loop3,blocksize=1024

will set up the loop device /dev/loop3 to correspond to the file /tmp/fdimage, and then mount this device on /mnt.
This type of mount knows about three options, namely loop, offset and encryption, that are really options to los-
etup(8). If no explicit loop device is mentioned (but just an option ‘-o loop’ is given), then mount will try to
find some unused loop device and use that. If you are not so unwise as to make /etc/mtab a symbolic link to
/proc/mounts then any loop device allocated by mount will be freed by umount. You can also free a loop device by
hand, using ‘losetup -d’, see losetup(8).

简而言之就是用一个文件系统中的普通文件虚拟成一个设备文件用于挂载的方法。
tukey 2005-03-06
  • 打赏
  • 举报
回复
up
isrunnIng 2005-03-06
  • 打赏
  • 举报
回复
谢谢了
mount -o loop boot.rom /mnt/xxx
这loop后面没带参数,有什么区别?
还有这个命令之后需不需要umount?

19,620

社区成员

发帖
与我相关
我的任务
社区描述
系统使用、管理、维护问题。可以是Ubuntu, Fedora, Unix等等
社区管理员
  • 系统维护与使用区社区
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧