windows or ubuntu mount 文件

windows

实测环境:windows 11, 64 bit.

ref:

Mount-DiskImage (Storage) | Microsoft Learn

Dismount-DiskImage (Storage) | Microsoft Learn

Get-DiskImage (Storage) | Microsoft Learn

bash 复制代码
# 查询
Get-DiskImage -ImagePath "f:\wsl\ext4.vhdx"

# mount
Mount-DiskImage -ImagePath "E:\ISO-Files\My US Visit Fall 2010 Pictures.iso"
Mount-DiskImage -ImagePath "f:\wsl\ext4.vhdx"

# unmount
Dismount-DiskImage -ImagePath "f:\wsl\ext4.vhdx"

ubuntu

对应版本:

bash 复制代码
# http://libguestfs.org/guestmount.1.html
sudo apt-get install libguestfs-tools

# 查询
mount

# mount
sudo guestmount --add ext4.vhdx --inspector --ro /mnt/mymount

--add
Add a block device or virtual machine image.

--inspector
Using virt-inspector(1) code, inspect the disks looking for an operating system and mount filesystems as they would be mounted on the real virtual machine.

--ro
Add devices and mount everything read-only. Also disallow writes and make the disk appear read-only to FUSE.

# unmount
sudo umount /mnt/mymount
相关推荐
xlp666hub12 小时前
Leetcode第五题:用C++解决盛最多水的容器问题
linux·c++·leetcode
张宏23613 小时前
原子操作 (基于Linux 应用层 C 语言)
linux
唐宋元明清218821 小时前
.NET Win32磁盘动态卷/跨区卷触发“函数不正确”问题排查
windows·c#·存储
kymjs张涛1 天前
OpenClaw 学习小组:初识
android·linux·人工智能
程序设计实验室1 天前
经历分享,发现挖矿木马后,服务器快速备份与重装(腾讯云平台)
linux
Miku161 天前
OpenClaw-Linux+飞书官方Plugin安装指南
linux·人工智能·agent
Miku161 天前
OpenClaw 接入 QQ Bot 完整实践指南
linux·人工智能·agent
Yogurt_cry2 天前
[树莓派4B] 闲置近10年的爱普生 L310 打印机爆改无线打印机
linux·物联网·树莓派
Johny_Zhao2 天前
OpenClaw中级到高级教程
linux·人工智能·信息安全·kubernetes·云计算·yum源·系统运维·openclaw
Sheffield3 天前
Docker的跨主机服务与其对应的优缺点
linux·网络协议·docker