How to copy Windows 10 x86 in VMDK file to USB Drive/Stick ?

Hello,

I am struggling a bit here to copy a virtual harddisk created with VMDK and a windows 10 x86 installation to a usb stick so the usb stick can booted.

So far I have discovered and tried some things:

  1. VMDK2Phys tool available on sourceforge.

When this tool is used, the partitions of windows 10 are "swapped". Meaning the partitions number are changed from 1, 2 to 0, 1. Not sure if this migh t cause boot issue.

The windows 10 fails to boot from usb in virtual machine. It boots from the recovery partition.

Windows 10 has two partitions when installed:

  1. Recovery Partition
  2. Windows 10/C Drive Partition.

  1. VMWare Workstation 8 creates these two partitions in a file .vdmk.

Inside this file, which can be opened with z-zip are two or three files:

0.ntfs 1.ntfs
  1. The first one is the recover partition roughly 550+ MB The second one is the c drive partition which I set to roughly 27+ GB or so . The third one I am unsure of, it does not seem to be a 7-zip archive.

The first two 0.ntfs and 1.ntfs can be opened with 7-zip too.

I am not sure if these are compressed files or just flat files with a certa in file structure.

  1. Some problems with VMWare mapping of VMDK files:

First of all since it's two partitions it creates problems, second of all t hey must be marked as not read only otherwise won't even be readable in win dows explorer and third and most important of all, they are not registered as true physical drive, so they don't integrate with windows enough to fool other tools that this is a physical disk, so it won't show up when mapping these drives to a drive letter with workstation map tool, which kinda suck s.

  1. Further trying to convert this VMDK all at once to VHD also failed with t2ware conversion tool. The VHD was unbootable in oracle virtualbox.

So I am having a really hard time trying to copy this VMDK to anything else that is sensible and booting it.

So I need help with two things I want to achieve:

  1. Copy this VMDK to something else then VMWare and then try and boot it in side a virtual machine.

However step 1 can be skipped.

My ultimate goal is to:

  1. Copy the VMDK contents to a USB stick, so windows 10 can boot from a USB stick.

It is absolutely required to able to "burn" virtual disks to usb stick and usb drives and usb mass storage devices.

Installing windows from usb stick to harddisk might be possible or perhaps even to other usb sticks, but is probably not possible because of missing u sb drives in windows iso, also updating works better in vmware/virtual mach ines and allows multi-tasking and other things to be done, so for me installing windows and updating it outside VM is a big fat NO-NO for now. I need windows 7 x64 ed ition to go through this procedure as well.

So I need windows 7 x64 virtual disk VMDK to be copied to harddisk later or USB stick as well if I decide it's usuable and so far it seems highly usua ble. I created a Windows x64 Ultimate Integrated ISO with ntlite and windowsupda tedownloader and such.

So far it worked by installing in vmware workstation 15 which is running on newer hardware: laptop toshiba from 2012. Windows update is far from flawl ess failed many times, it wants to install service pack 1, 9 MB I think tha t is a bug in windows update, might try later.

So far the slip streaming proceeded nicely.

This would allow me to have two versions of windows 7 x64:

  1. Non-platform update.
  2. Platform update.

So games run only on 1, some games run only on 2.

Plus it's interesting to see how a fully patched windows 7 might function o n my dreampc.

So the method to copy from virtual harddisk to usb drive/harddisk should be somewhat generic and well usuable for anything really if possible.

This would also allow experimentation with windows updates in virtual machi nes and if approved applied to usb sticks and harddisks, without risking ma in installations. Plus it can also run in virtual machines and be used in f uture and such, so that beats backup solutions that don't run in vm's.

Any ideas ? preferably non-linux solutions. I don't have time to debug linu x and compile and scripts and such, must be gui based and not to hard to us e, also no complexity to prevent f*ck ups.

So far I was going to try:

AOMEI Backupper

It seems to have cloning and parition cloning and such but it probably can' t read vmdk files.

I tried mounting part of the vmdk file but as written above it does not sho w up as a physical drive in this program so it's useless.

So I am at a loss right now, no tool seems to be able to deal with this "mu lti-volume" vmdk file and burn it to usb disk properly ?!? At least not the ones I tried.

You know of any tool that can do this ?

7-zip seems to indicate offsets into this file vmdk. BEGIN CHS and such.

Perhaps that can be used to "burn" ntfs files to disk ?

I am not sure if it will work to "burn" ntfs files to usb disk ?

Perhaps it's compressed and needs to be extracted during the burn process, this could explain the slowness of VMDK2Phys tool.

It's software is avialable so I could check.

Maybe even fix it myself, but hehe... that is a bit much to ask for and wou ld take a long time and I don't know file systems and partition tables that well, maybe somebody else might know though how to fix this program.

Any C programmer care to take a look, maybe you can spot what is wrong ?

For now my assumption is that the VMDK file of Windows 10 is OK, cause it d oes boot ok in VMWare 8 and seems to work just fine, though virtual machine do tend to be somewhat resilient against wrong offsets, but for now since

7-zip seems to be working ok as well, it seems vmware and 7 zip are ok tool s, and the other tools are simply bugged for this case.

I need a good tool, that can "burn" "multi-parition/volume" vmdk to any sto rage medium that allows booting, harddisk, usb drives, perhaps even ssd in future.

Should be as easy as writing boot sector 0 properly ?!? and the rest as wel l ?!

Though perhaps these usb/ssd drives require certain aligning of partitions, saw something about that for ssd. Don't need SSD functionality for now cau se bios can't boot from SSD drives, though it is a usb device I think so th at is kinda weird.

SCSI controllers were used in VMWare cause they recommended but then later it says dual-something is slow ? confused about that, so far seems to be ok .

Not sure if maybe scsi is causing wrong sector location writes in vmdk or s o, not sure.

Anything is possible really... Let's suppose VMWare writes the sectors up-s ide down... then other tools would never copy it properly, same if it was r andom or offset or wholes inside of it... how can we be sure it's truely fl at ? ;)

For now it's assumptions at best ;)

(Would have to write values likes 0,1,2,3,4,5,6 and such with a fake OS emb edded in it to see how VMWare and other tools truely behave when it comes t o writing/reading sectors/data and such and see if they produce any holes or wrong offsets and such)

Bye for now, Skybuck.

Reply to
skybuck2000
Loading thread data ...

For backup AND restore purposes compressed archives are horrible, VMDK coul d be a compressed archive and is therefore horrible to restore, slow and ne eds presumeable needs special software to decode it's file format.

This guy has an idea though:

formatting link
a-physical-system

First convert the VMDK to a "raw" format like IMG.

So this could be a first good step to convert this VMDK mess into something which might burn a bit easier.

I think I did have a tool for VHD to IMG. But VMDK to IMG might be a differ ent story.

So I will try to find a tool like this, don't hesitate to mention it if you know one too, in case I don't find it =D

And then I will still need an IMG to DISK cloning tool or something.

IMG could be tested in PCem but I doubt it can run windows 10, but who know s lol.

Maybe also other VM tools might be able to run IMG... not sure...

I dont care about compression, I rather work with raw images files for Virt ualization, I am finding these VHD and VMDK files to be more trouble then w orth it, costing me HUGE ammount of time trying to work around there shitty file formats.

Hope VM guys see this and abadon VMDK and VHD completely for something tha t is easier to burn but for now VHD works nicely in Windows... Maybe window s needs to start using something more RAW too, and maybe a descriptor file like VMDK uses, but for gods sakes no compression.

It's hard enough already as it is ! ;):) Don't bring back bad memories of g host explorer or something... with compression 1 bit error and all data is lost, with raw... maybe you be lucky and it was 1 bit error in free space.

Bye, Skybuck.

Reply to
skybuck2000

snipped-for-privacy@hotmail.com wrote in news:a0b2c46c-e569-4b9f-a6c1- snipped-for-privacy@googlegroups.com:

Putting an operating system which relies almost 100% on "virtual memory" "arrays" onto a USB drive is asking for problems. A USB stick does not provide 'multiple access', like a hard drive can. So while it is trying to write to the stick's newly allocated 'virtual RAM', it also wants access to Windows' file elements and the registry... yada yada yada...

Trying to put Windows on a USB stick has to be one of the most retarded things you could do.

Now trying to do this with a USB attached external SSD or such MIGHT work, but a single file storage stick... Likely not ever.

Reply to
DecadentLinuxUserNumeroUno

It'd rather not use a strange command line utility but it's starting to see m I might be running out of options, at least I will mention this tool:

formatting link

It's website description:

" qemu-img for Windows

QEMU disk image utility for Windows. It is used for converting, creating an d consistency checking of various virtual disk formats. It?s compat ible with Hyper-V, KVM, VMware, VirtualBox and Xen virtualization solutions .This build has been optimized for Windows Server (x64), including Windows Nano Server. "

At least this runs on windows and I can avoid using linux based versions, t he horror avoided :)

It also seems to have some virtual machine as well,

" What is QEMU?

QEMU is a generic and open source machine emulator and virtualizer. "

Most of it is for linux but it seems there are also windows versions availa ble.

Maybe I tried this long ago and it ran like a dog, or maybe that was someth ing else, I can remember some kind of tool where you had to build your own PC completely... I hope this is not it cause then I am wasting my time.

But maybe I give this emulator a try too later, to see what it can do and h ow well/stable and fast it runs ;)

If this converter tool works then I would only need some IMG to DISK tool.

So one step closer hopefully to achieving my goal ;)

Bye, Skybuck.

Reply to
skybuck2000

Some more help with figuring out VMDK file formats and conversions:

formatting link

It mentions XEN which is kinda interesting.

Seems to be some open source,well supported virtualization environment for linux ?! =D

Probably not for windows ?! LOL.

Probably too advanced for me but might be interesting to look into this later.

Especially after I start experiment with linux some more ;)

But first need windows working ! LOL FOR GAMING ! ;) =D

Bye, Skybuck ;) =D

Reply to
skybuck2000

I know you don't want Linux solution, but it's much easier to do it with dd . I believe there is a dos version of dd some where.

We build fully loaded Window 10 image with all updates. Shrink partition t o around 30GB. Put the image in a 64GB USB liunx (or dos with dd). Dd if =win10 of=/dev/sda. Boot Win10, extend partition, and activate with ne w key. With several USB drives, we can clone hundreds of Windows 10 a day.

Reply to
edward.ming.lee

snipped-for-privacy@gmail.com wrote in news: snipped-for-privacy@googlegroups.com:

You never heard of slipstreaming?

Reply to
DecadentLinuxUserNumeroUno

But MS does not include all the third parties apps we need. And dd is faster than install from iso. No click and no key at all.

Reply to
edward.ming.lee

snipped-for-privacy@gmail.com wrote in news: snipped-for-privacy@googlegroups.com:

Our corporate contract with them was for thousands of units. But our in-house stuff was a slipstreamed image, and MS definitely wanted all MS Office aps installed individually afterward. But we had a contract for that too, so I was able to get a key for office pro at home too.

But yea... I can see some utility there. Just not likely the way MS would like it. Depends on the seat count too I suppose.

We had thousands of machines right there just on the one campus. So there was an IT dept that did nothing all day but new box set-ups. Then they did full tear downs and hard drive destruction on the old stuff.

Reply to
DecadentLinuxUserNumeroUno

Only app we need to install separately is a client/server program that need s to generate a unique key locally for the client.

Yes, MS probably does not like it. We have enough licenses for number of s taffs, but probably not for the number of machines. Our staffs use several computers, instead of running back and forth to their desktops. We also h ave copies loaded on hot and cold spare backups. But MS office is not our main app, so we can just take a chance legally.

Well, we have an IT guy who hate to use keyboard and mouse. So, he just se t up a USB drive to boot and immediately copy the window image to the SSD d rive. Very often, he is too lazy to even hook up the keyboard and mouse to clone the drive. Oh yes, he is me.

Reply to
edward.ming.lee

ElectronDepot website is not affiliated with any of the manufacturers or service providers discussed here. All logos and trade names are the property of their respective owners.