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
相关推荐
三言老师5 小时前
K8s集群运行时自动化运维全覆盖落地实操(下)
linux·运维·服务器·网络
ltl6 小时前
HAProxy HTX 与 HTTP 路径:内部表示、改写落点与协议分叉
linux
ltl6 小时前
可拆分 OS:CXL 内存池化如何动摇本地 DRAM 假设
linux
ltl6 小时前
Tetragon 强制执行:Override 与 SIGKILL 各自保证什么
linux
lengjingzju6 小时前
编译与调试完全指南—第6章 性能分析工具
linux
躺不平的理查德7 小时前
嵌入式 Linux 系统移植与 SD 卡量产镜像制作
linux·运维·服务器
Mr.亮先生8 小时前
# 把 DeepSeek 官方 Agent 工作台,直接装进 Windows 启动器里
windows·deepseek·harness
一直走下去-明8 小时前
centos7无法安装tcpreplay
linux·运维
吹什么轩8 小时前
linux网络:TCP套接字基础
linux·网络·tcp/ip
时空无限9 小时前
ubuntu dpkg -l 输出第一列解释
linux·运维·ubuntu