Sun Microsystems 3.0.0 user manual Serial ports

Models: 3.0.0

1 259
Download 259 pages 49.67 Kb
Page 53
Image 53

3 Starting out with VirtualBox

In most cases, this default setup will work fine for you.

However, VirtualBox is extremely flexible in how it can virtualize networking. It supports up to eight virtual network cards per virtual machine, the first four of which can be configured in detail in the graphical user interface. All eight network cards can be configured on the command line with VBoxManage. Because of this, we have dedicated an entire chapter of this manual to discussing networking configuration; please see chapter 6, Virtual networking, page 82.

3.7.8 Serial ports

VirtualBox fully supports virtual serial ports in a virtual machine in an easy-to-use manner.2

Ever since the original IBM PC, personal computers have been equipped with one or two serial ports (also called COM ports by DOS and Windows). While these are no longer as important as they were until a few years ago (especially since mice are no longer connected to serial ports these days), there are still some important uses left for them. For example, serial ports can be used to set up a primitive network over a null- modem cable, in case Ethernet is not available. Also, serial ports are indispensable for system programmers needing to do kernel debugging, since kernel debugging software usually interacts with developers over a serial port. In other words, with virtual serial ports, system programmers can do kernel debugging on a virtual machine instead of needing a real computer to connect to.

If a virtual serial port is enabled, the guest operating system sees it a standard 16450-type serial port. Both receiving and transmitting data is supported. How this virtual serial port is then connected to the host is configurable, and details depend on your host operating system.

You can use either the graphical user interface or the command-line VBoxManage tool to set up virtual serial ports. For the latter, please refer to chapter 8.5, VBoxManage modifyvm, page 107; in that section, look for the --uart and --uartmode options.

In either case, you can configure up to two virtual serial ports simultaneously. For each such device, you will need to determine

1.what kind of serial port the virtual machine should see by selecting an I/O base address and interrupt (IRQ). For these, we recommend to use the traditional values3, which are:

a)COM1: I/O base 0x3F8, IRQ 4

b)COM2: I/O base 0x2F8, IRQ 3

c)COM3: I/O base 0x3E8, IRQ 4

d)COM4: I/O base 0x2E8, IRQ 3

2.Then, you will need to determine what this virtual port should be connected to. For each virtual serial port, you have the following options:

2Serial port support was added with VirtualBox 1.5.

3See, for example, http://en.wikipedia.org/wiki/COM_(hardware_interface).

53

Page 53
Image 53
Sun Microsystems 3.0.0 user manual Serial ports