VMware: Difference between revisions

1,134 bytes added ,  1 month ago
m
Added a new note saying that VMware Workstation & Fusion Pro became free for personal use
[unchecked revision][unchecked revision]
m (Added a new note saying that VMware Workstation & Fusion Pro became free for personal use)
 
(8 intermediate revisions by 6 users not shown)
Line 1:
{{Emulators}}
'''VMWare''' is basically the rich man's Virtualizer. It can run any number of "Guest Operating Systems" and can boot from real media or image files. It comes with a GUI that makes it easier to configure than [[Bochs]] or [[QEMU]].
 
'''VMWareVMware''' is basically the rich man's Virtualizer''virtualizer''. It can run any number of "Guest Operating Systems" and can boot from real media or image files. It comes with a GUI that makes it easier to configure than [[Bochs]] or [[QEMU]].
Please note: VMware is not an emulator. There is lot of differnce between an emulator and a virtual machine monitor. Emulators, like Bochs, emulate each instruction, whereas VMWare (and Virtual PC) try to run most of the code on the host PC directly, and only emulate instructions that create invalid instruction faults or access system-level memory.
 
Please note: VMware is not an emulator. There is lot of differncedifference between an emulator and a virtual machine monitor. Emulators, like Bochs, emulate each instruction, whereas VMWareVMware (and Virtual PC) try to run most of the code on the host PC directly, and only emulate instructions that create invalid instruction faults or access system-level memory.
 
The VMware BIOS supports booting from a CD (use mkisofs to make a bootable CD, attach cdrom device to the .iso file) or a floppy drive (attach the floppy disk to a file), plus hard drives. These are the easiest options for loading your own kernel.
 
=== Versions= ==
 
VMware's usefulness for hobbyists depends on the code's generation. Broadly:
Line 14 ⟶ 16:
 
* NOTE: VMware Player is totally free for use, and has smaller size than VMware Workstation. The new versions of VMware Player (from 3.0 up) are able to create new virtual machines. Thus this VMM is *perfect* for testing.
* NOTE: VMware Workstation/Fusion Pro became totally free to use for personal use only. [https://twitter.com/mikeroysoft/status/1790386458546823245]
 
=== Guest debugging= ==
These options are valid in Workstation 6.0+, and should be set in the virtual machine's .vmx file.
 
Line 23 ⟶ 25:
If using these options, Workstation prints a message "VMware Workstation is listening for debug connection on port 8832." into the vmware.log file. Start a GDB session (using a copy of your kernel that includes debug information), then:
* target remote localhost:8832
 
Note that some versions of VMWare contain a bug: after you disconnect GDB from port 8832, VMWare will actually continue listening on port 8833 not 8832. The actual port can always be located by looking at the latest "Debug stub" entry in the vmware.log file:
 
<code>vmx| W110: Debug stub: VMware Workstation is listening for debug connection on port 8833.</code>
 
Standard gdb commands work in this mode (e.g. printing memory, backtrace). Note that this is a debug stub attached to the KERNEL, not a userspace program.
Line 30 ⟶ 36:
* debugStub.listen.guest64.remote = "TRUE" # Same, but for 64-bit code
* monitor.debugOnStartGuest32 = "TRUE" # Breaks into debug stub on first instruction (warning: in BIOS!) # This will halt the VM at the very first instruction at 0xFFFF0, you could set the next breakpoint to break *0x7c00 to break when the bootloader is loaded by the BIOS
* debugStub.hideBreakpoints = "TRUE" # AllowsEnables gdbthe use of hardware breakpoints toinstead workof software (INT3) breakpoints
* bios.bootDelay = "3000" # Delay booting the BIOS code.
 
=== Triple faults= ==
 
VMware products emulate a triple fault by resetting the machine. On beta products, however, a guest triple fault results in Bug 19580. Sometimes this represents a bug in VMware's emulation; usually, this represents a bug in your kernel.
 
==See AlsoGuest Tools ==
{{Main|VMware_tools}}
As a virtualization product aimed at regular users, VMware provides a number of facilities through its "tools" package for major OSes, such as absolute mouse positioning and display resizing.
 
== Compatibility with IDEs ==
* IDA Pro supports debugging Windows kernels via the VMWare stub [https://www.hex-rays.com/products/ida/support/tutorials/debugging_gdb_linux_vmware.pdf]
* VisualKernel supports debugging Linux kernels from Visual Studio with VMWare gdb stub [http://visualkernel.com/tutorials/vmware/]
 
== See Also ==
 
=== External Links ===
* http://www.vmware.com/ - VMware homepage.
* http://communities.vmware.com/index.jspa - Community forums. Engineers are present; if asked politely, some will provide very exact technical details
* http://www.pagetable.com/?p=25 - A description of a problem encountered using VMware on AMD Opteron RevC processors.
* http://stackframe.blogspot.com/2007/04/debugging-linux-kernels-with.html - VMware engineer describes how to debug Linux kernel with debug stub.
* http://sourceforge.net/projects/open-vm-tools/ - Open source client tools. Good source for VMWareVMware proprietary hardware and host/client hooks
[[Category:Emulators]]
1

edit