EzDevInfo.com

virtual-machine interview questions

Top virtual-machine frequently asked interview questions

How to move VirtualBox files?

By default VirtualBox stores all data in a directory below the home directory. I know how to change it but how can I change the location of existing images (without editing VirtualBox.xml manually)?

I'm working on Windows and don't want to try using any NTFS links.


Source: (StackOverflow)

Is it possible to convert virtual machines to physical environments?

Is is possible to convert a .vdi file into a .iso that can be burned to a cd or dvd and make it like an installer. Or Is it possible to convert virtual machines to physical environments?


Source: (StackOverflow)

Advertisements

Virtual Box - not filling entire screen

I am new to VirtualBox and am trying to set up an instance of Windows 7 64.

I have the virtual machine instance running with Windows 7 now installed, but it only fills up a small portion of my screen. Even when I go full screen, the window stays the same size and the rest of the screen is filled with gray space.

I have installed VirtualBox Guest Additions, which allowed me to go from a resolution of 800x600 to 1024x768, but this still isn't satisfactory as my laptop display is 1600x900.

Any help on this would be most appreciated. Thanks.


Source: (StackOverflow)

Limiting CPU speed in a virtual machine?

Does anyone know of a way to limit the CPU speed in a virtual machine? Or if there is even a virtualization software that allows you to do this?

I am trying to find the minimum requirements for a system, given a specific OS image that I have. I see ways to limit RAM and hard disk size and number of cores, but I need to slow the CPU down to 800 MHz in order to really simulate the system configuration. Also, the computer running the virtual machine is a Windows 7 machine.


Source: (StackOverflow)

Can I "transfer" my Windows 7 license to a virtual machine running on the same computer?

I've read the blog post on license transfer, but I'm not clear in the case where I already have a licensed, activated copy of Windows 7 running on my PC but want to move that license to a VM running in Ubuntu on the same PC. Am I allowed?


Source: (StackOverflow)

Virtual Machine and Virus

I have a requirement for which I have to get online without protection (firewall, anti-virus). At the same time, I don't want to risk getting infected with viruses.

If I install a virtual machine (VirtualBox) to test, and it does get infected with viruses, will it also infect my host system? In other words, can I use the virtual machine for testing without being concerned about a virus on the virtual machine infecting my host?


Source: (StackOverflow)

How can virtual machines consume so little RAM on the physical host machine?

I'm running VirtualBox on a Windows XP machine with 2GB RAM. I've created a virtual Ubuntu machine and allocated it a base memory of 750MB.

Just to put it to a test, I ran 20 things at once on the virtual machine. According to "top" in ubuntu, 750 megs of memory were being used, as well as considerable swap space.

However, back in Windows Task Manager, VitrualBox was using only 45,000K of memory. As I asked the virtual machine to do more and more, the CPU usage of the VirtualBox process went up (in Windows) but memory usage stayed the same.

How can a virtual machine that is using 750 MB of memory only consume 45 MB of memory on a physical machine?

I assume the answer is that the virtual machine is not using real memory, but simulated memory (i.e. swap space), but it sure feels snappy like it is running in RAM.

UPDATE: I've played around with perfmon as suggested. Even summing up everything I can think of, it still seems to take up less than 300 megs ... so it is still a mystery.

Process               VirtualBox     VirtualBox#1     Total
PoolNonpagedBytes     5,840          42,552           48,392
PoolPagedBytes        119,796        166,892          286,688
PrivateBytes          8,884,224      52,719,616       61,603,840
VirtualBytes          75,939,840     161,202,176      237,142,016
Sum                   84,949,700     214,131,236      299,080,936

Source: (StackOverflow)

Save the output of command in file MS-DOS 1.x

It seems that [COMMAND]>[FILE] does not work in the early versions of MS-DOS. I am using MS-DOS 1.25 and the above expression gives the statement invalid argument.

Update:Since it is true that it does not work in DOS 1.x then is it possible to get that output using some functionality of virtual box or say by getting the output from some log files.


Source: (StackOverflow)

How to convert .img to usable VirtualBox format

I have a .img file for Windows 1, and I need to turn it into something which I can use in VirtualBox, such as an ISO, or turning it into a bootable virtual disk for an ICT project.

If you need any additional information, please send me a comment.


Source: (StackOverflow)

How to run a minimal Linux inside a running 64-bit Windows 7

On my previous Windows Vista laptop, I used to run Portable Ubuntu Remix for Windows, which is based on coLinux, like the similar andLinux. This worked fairly well with limited system resources (a Ubuntu 08.04 VM with 256 MB RAM on a 2 GB 32-bit Windows Vista host). It allowed me to quickly port my development efforts from Windows to Linux, or just to have a "real" (vs. just Cygwin, which I have, too) Linux system available while on the road.

Now, I've moved to a 64-bit Windows 7 laptop with 8 GB, but unfortunately coLinux has not been ported to 64-bit yet, and it doesn't look like this will happen soon. Even though most 32-bit software "just works" on Windows, coLinux wouldn't because of its kernel driver. So, it seems like the preferred approach (cp. Running Linux inside Windows XP, ie no dual booting, What is the most efficient way to run Windows and Linux at the same time?) doesn't work any more.

My best idea is setting up a 64-bit Ubuntu 12.10 VM in VirtualBox, but despite Seamless Mode, I'm afraid the integration with the host Windows OS won't be as smooth as with Portable Ubuntu (which uses Xming for displaying the windows), and I have to constantly fiddle with the Host key to move between both worlds.

How do you tackle this?

  1. Does any (preferably free and non-intrusive) virtualization solution handle the host integration better?
  2. Or should I just boot into non-GUI mode and launch X applications through SSH with Xming?
  3. What are your sizing recommendations for the guest OS (assuming just some terminals, editor, and compiler)?
  4. Would a specialized minimal Linux distribution be better suited for running with little resources?

Source: (StackOverflow)

How does VirtualBox's memory usage work?

I've been running several VM's with VirtualBox, and the memory usage reported from various perspectives, and I'm having trouble figuring how much memory my VMs actually use. Here is an example:

  • I have a VM running Windows 7 (as the Guest OS) on my windows XP Host machine.
  • The Host Machine Has 3 GB of RAM
  • The Guest VM is setup to have a base memory of 1 GB
  • If I run Task Manger on the Guest OS, I see memory usage of 430 MB
  • If I run Task Manger on the host OS, I see 3 processes that seem to belong to VirtualBox:
    1. VirtualBox.exe (1), using 60 MB of memory (This one seems to have the most CPU usage)
    2. VirtualBox.exe (2), using 20 MB of memory
    3. VBoxSvc.exe, using 11.5 MB of memory
  • While running the VM, the Host OS's memory usage is about 2 GB
  • When I shut down the VM, the Host OS's it goes back to memory usage goes down to about 900 MB

So clearly, there are some huge differences here. I really don't understand how the GuestOS can use 400+ MB, while the Host OS only shows about 75 MB allocated to the VM. Are there other processes used by VirtualBox that aren't as obviously named?

Also, I'd like to know if I run a machine with 1 GB, is that going to take 1 GB away from my host OS, or only the amount of memory the Guest machine is currently using?

Update:

Someone expressed distrust over my memory usage numbers, and I'm not sure if that distrust was directed at me, or my Host OS's Task Manager's reporting (which is perhaps the culprit), but for any skeptics, here is a screenshot of those processes on the host machine:

VirtualBox task manager


Source: (StackOverflow)

Is it possible to "virtualize" an existing PC?

I'm running Ubuntu Desktop 12.04, and I was wondering if it was possible to somehow take my whole filesystem (everything under /) and create an ISO from it. Then, perhaps, use that ISO as the file system of a VBox VM (obviously, it would have to be Ubuntu, and probably 12.04).

Basically, I've spent a lot of time configuring my development machine, but need to be able to work on it from whatever computer I happen to be at. VMs seem like the perfect solution. Thanks in advance!


Source: (StackOverflow)

Getting a VMnet0 error in VMWare workstation after updating host computer from Windows 8 to 8.1

Yesterday, I updated my computer from Windows 8 to 8.1. I have VMWare Workstation 10 running Windows XP on this computer and prior to the update I had no issues connecting to my network. However, since updating, I haven't been able to connect to any network and I'm getting the following error:

The network bridge on device VMnet0 is not running. The firtual machine will not be able to communicate with the host or with other machines on your network.

Failed to connect virtual device Ethernet0

I've checked all of my settings which currently have my network adapter set for a bridged connection and under device status "connected" is checked.

Not really sure where to go from here, but after doing some research I have seen that others users have reported getting this error when updating the OS (any OS, not windows 8 specifically) of the host computer.


Source: (StackOverflow)

Is my host machine completely isolated from a virus-infected virtual machine?

If I am running a Windows 7 virtual machine on a Windows 7 host using VMWare or VirtualBox (or anything else) and the virtual machine is completely overloaded with viruses and other malicious software, should I worry about my host machine?

If I have an anti-virus program on host machine will it detect any problems?


Source: (StackOverflow)

How do I install and use Windows Virtual PC in Windows 8?

I really liked the integrated Virtual Machine that Windows had built-in with Windows 7, known as the Windows Virtual PC. I'm looking to install that again. I'd like to be able to install multiple virtual machines as I did before (running XP, Ubuntu, etc.) but I can't seem to find Windows Virtual PC for Windows 8.

Is it still available? If not, is there something that replaces it? How do I use it?

NOTE TO ALL: While this is an accepted self-posted answer, feel free to edit, comment or add an answer of your own. If your answer is better than mine, I will accept it.


This question was a Super User Question of the Week.
Read the blog entry for more details or contribute to the blog yourself.


Source: (StackOverflow)