Skip to content

Conversation

oliverkurth
Copy link
Contributor

This adds a utility to mount a vmdk file as a raw disk image in read-only mode. The raw disk image can then be used with kpartx, or partfs (see https://github.com/braincorp/partfs) to access partitions, which can then be mounted. Example:

$ touch vmdk
$ vmdk-fuse --file=$(pwd)/minimal.vmdk ./vmdk
before fuse_main
$ ls -l
total 456800
-rw-r--r-- 1 okurth okurth  467756544 Mar 23 17:35 minimal.vmdk
-rw-r--r-- 1 okurth okurth 8589934592 Mar 23 17:35 vmdk     
$ mkdir partfs
$ partfs -o dev=./vmdk ./partfs/
$ ls -l partfs/
total 0
-rw-r--r-- 1 okurth okurth   10485760 Mar 23 17:35 p1
-rw-r--r-- 1 okurth okurth 7586430464 Mar 23 17:35 p2
-rw-r--r-- 1 okurth okurth  134217728 Mar 23 17:35 p3
-rw-r--r-- 1 okurth okurth  428867584 Mar 23 17:35 p4
-rw-r--r-- 1 okurth okurth  428867584 Mar 23 17:35 p5
$ mkdir p2
$ fuse2fs ./partfs/p2 ./p2 -o fakeroot,ro
Mounting read-only.
$ ls p2
bin  boot  dev  etc  extra  home  lib  lib64  lost+found  media  mnt  opt  proc  root  run  sbin  srv  sys  tmp  usr  var
$ 

Original PR was #54, but the branch was renamed and this closed it.

Signed-off-by: Oliver Kurth <[email protected]>
Signed-off-by: Oliver Kurth <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant