According to wiki, VHD (Virtual Hard Disk) may contain what is found on a physical HDD, such as disk partitions and a file system, which in turn can contain files and folders.
I have found the VHD image of the WP7 in the following directory.
I read that Hyper-V features offline VHD manipulation, providing administrators with the ability to securely access files within a VHD without having to instantiate a virtual machine. The Windows Disk Management MMC plugin can directly attach a .vhd as a drive letter in Windows 7. I tried the same thing.
The result was this error.
Now, I want to know if there is anyway to mount this VHD and explore the file system ? I mean can I take this VHD to a linux environment and explore ? Is this VHD really corrupt or I lack some access privileges ?
I have tried it too, but get the same message as you get. Probably a kind of restriction Microsoft has build in to protect users from sniffing around. (Especially in the period that there where no hardware devices and only the emulator was available or periods where the updated SDK is delivered earlier than the actual update)
If there is a way too mount this VHD than they definitly know how to do it at the XDA developers forum. I think posting your question overthere will result in more/better answers than on StackOverflow which has more focus on application development.
Related
I have a qcow2 file that contains windows 10. The operating system is RHEL8.2. The virtualization stack is kvm, qemu, virt-viewer. And the command line used to manipulate the virtual machine is 'virsh'.
I need to update the windows drivers and kernel, change some registry, uninstall some applications, add things to the task scheduler and more.
My question, is what is the best process to acheive this? Is the result should be a new qcow2 file? Are there changes required for the xml configuration file of the virtual machine?
There are 2 modes of editing the virtual machine, online and offline. The difference is if the virtual machine is running during the edit or not. What mode is best to perform the task described above?
As I understand, snapshots are stored inside the qcow2 file, and then the user needs to pick between them. The users, on the system I am working on, are not aware they run on virtual machines, so I can not use this path, unless I am missing something.
Also there is the 'managedsave' and 'save' commands for virsh, but they don't create a new qcow2 file, and I don't think that the commands are meant for it.
Finally I found that the qcow2 file can be mounted as a device, perform changes in it, and unmount it. But then how can I uninstall applications and more in this way?
Thank you!
All the changes you described (update the windows drivers and kernel, change some registry, uninstall some applications, add things to the task scheduler and more) affect only the guest disk - qcow2 file, and guest memory.
You can run the guests, do these changes and power off. All changes will be saved to the guest disk. When instead of poweroff you will suspend the guests, some of the changes can be saved in guest memory.
There are no changes needed for the xml configuration file of the virtual machine, no new qcow2 files will be created.
Yes, snapshots are stored inside the qcow2 file, but since you have a copy, you dont need to create snapshots. Also no need for 'managedsave' and 'save' commands.
Is there anyway to access files from usb without mounting it (in a terminal)?
copying or accessing files without mounting it!!
First of all: I think it would be better to post this question on "superuser.com", not on "stackoverflow.com" because this is a question about usage of Linux, not about programming for Linux.
In the 1990s there was a tool which allowed you to read FAT-formatted media (floppys and hard disk partitions) under Linux.
The tool was intended for older Linux versions that did not have FAT file system support.
Because today all Linux versions have FAT file system support I think that tool is no longer maintained however the source codes should still be available somewhere!
FAT32 did not exist, yet, the time when this tool was used so the tool only supported FAT12 and FAT16.
To access the media "root" rights are required in any case.
A friend of mine asked me if it's possible to take a hyper-v snapshot of a running (Non virtual) windows 2012 server (Which I think also runs SQL Server). He wants to be able to run and experiment with the Snapshot in the event that the server goes down.
Thanks,
Ole
Yes, It is possible with the tool Disk2vhd.
Disk2vhd is a utility that creates VHD (Virtual Hard Disk - Microsoft's Virtual Machine disk format) versions of physical disks for use in Microsoft Virtual PC or Microsoft Hyper-V virtual machines (VMs). The difference between Disk2vhd and other physical-to-virtual tools is that you can run Disk2vhd on a system that’s online. Disk2vhd uses Windows' Volume Snapshot capability, introduced in Windows XP, to create consistent point-in-time snapshots of the volumes you want to include in a conversion. You can even have Disk2vhd create the VHDs on local volumes, even ones being converted (though performance is better when the VHD is on a disk different than ones being converted).
The Disk2vhd user interface lists the volumes present on the system:
It will create one VHD for each disk on which selected volumes reside. It preserves the partitioning information of the disk, but only copies the data contents for volumes on the disk that are selected. This enables you to capture just system volumes and exclude data volumes, for example.
Note: Virtual PC supports a maximum virtual disk size of 127GB. If you create a VHD from a larger disk it will not be accessible from a Virtual PC VM.
To use VHDs produced by Disk2vhd, create a VM with the desired characteristics and add the VHDs to the VM's configuration as IDE disks. On first boot, a VM booting a captured copy of Windows will detect the VM's hardware and automatically install drivers, if present in the image. If the required drivers are not present, install them via the Virtual PC or Hyper-V integration components. You can also attach to VHDs using the Windows 7 or Windows Server 2008 R2 Disk Management or Diskpart utilities.
Note: do not attach to VHDs on the same system on which you created them if you plan on booting from them. If you do so, Windows will assign the VHD a new disk signature to avoid a collision with the signature of the VHD’s source disk. Windows references disks in the boot configuration database (BCD) by disk signature, so when that happens Windows booted in a VM will fail to locate the boot disk.
Disk2vhd runs on Windows Vista, Windows Server 2008, and higher, including x64 systems.
Command Line Usage
Disk2vhd includes command-line options that enable you to script the creation of VHDs. Specify the volumes you want included in a snapshot by drive letter (e.g. c:) or use "*" to include all volumes.
Usage: disk2vhd <[drive: [drive:]...]|[*]>
Example: disk2vhd * c:\vhd\snapshot.vhd
Note: Physical-to-virtual hard drive migration of a Windows installation is a valid function for customers with Software Assurance and full retail copies of Windows XP, Windows Vista, and Windows 7. Software Assurance provides users valuable benefits—please contact Microsoft Corporation for further information. Windows XP, Windows Vista and Windows 7 installed by Original Equipment Manufacturers (OEM) using OEM versions of these products may not be transferred to a virtual hard drive in accordance with Microsoft licensing terms.
From: Technet.microsoft.com
apologies for vague description but essentially I have a Linux box (Ubuntu) which has three drives. The first drive is formatted with a Linux format (I'm not sure which one but probably irrelevant) and the second and third drives are NTFS as they have been shares on a windows network.
Can I just reformat the first drive to NTFS and install windows? Would I expect windows to see drives 2 and 3 as they are already NTFS drives?
Thanks
Backup/Image your system before doing any changes, if the system is critical.
Yes, begin Windows installation process. There will be a point in the installation where you will be asked to select the drive/partition on which Windows should be installed. Your first drive will be listed. You can wipe it off and choose the entire drive for Windows. Default NTFS will be created for you.
If you have trouble, create gparted live CD and boot system with it. It will allow you to wipe off the first drive. Then install Windows on that drive.
Yes, Windows will see drive 2 and 3.
Also, you will get some nice help on https://serverfault.com/ if there are complications with disk setup (RAID/LVM etc.).
I'm a (noob) administrator of a little network. For business purpose I have some Windows 7 PCs and a 2008 Server.
While doing the setup, something has come to my mind: is it possible for a user without high privileges to install some kind of software using a live usb?
Ok, it's possible to reset admin password, manage partitions, etc. but can someone do that without change admin settings? just putting software in admin's (or else) directory and editing the windows register?
Thanks!
I would say: Yes. If someone manages to boot the machine from a live usb-stick, cd, dvd or whatever, he can:
Mount the disk with the windows-installation.
Read and Write to that disk.
Install software on that disk: Installing software is not much more than copying files from one place to another.
Possibly modify the registry: The registry must also be stored somewhere on the disc. If the user can access that file, he can modify it and therefore modify the registry (its another question if this are valid manipulations).
You can prevent access to the harddisk by using Windows 7 BitLocker.
It is not possible to mount the drive from a live system when it is activated:
Here is a guide how to do this:
BitLocker Guide