Accessing "default" VBox serial port directly

Discussions about using Linux guests in VirtualBox.
Post Reply
Lapsio
Posts: 13
Joined: 24. Jun 2017, 17:15

Accessing "default" VBox serial port directly

Post by Lapsio »

I have VM that doesn't support GPU. VirtualBox is displaying VM window using serial console (when I disabled serial console in guest VBox window gone black and I couldn't interact with guest in any way). However this machine seems to support only 1 serial console. I need to save console output to file on host OS (possibly without OCR from screenshots) so I need VirtualBox to force not use serial for default monitor or even better - access its output in character form.

How do?
mpack
Site Moderator
Posts: 39134
Joined: 4. Sep 2008, 17:09
Primary OS: MS Windows 10
VBox Version: PUEL
Guest OSses: Mostly XP

Re: Accessing "default" VBox serial port directly

Post by mpack »

VirtualBox doesn't emulate any serial consoles. Nobody has AFAIK made them since the early 1980s. They were certainly never used by PCs, which is what VirtualBox emulates. All PC displays are electronic, managed by a display/graphics card, and that is what the VM will emulate.

It's the guest OS which is rendering text on a physical display - however no serial ports are involved.

By the same token, it's the guest OS which you have to tell to redirect its output, from the display to somewhere else. VirtualBox knows nothing about this and is not involved. I see no problem with redirecting stream output to a shared folder.

Moved to "Linux Guests" for want of anywhere better, since this clearly has nothing to do with "Linux Hosts".

Pedantic note: You confused me when you said that your guest doesn't support a GPU. My first thought was "well of course not - no VirtualBox VM has a GPU". I later understood that you meant that your guest OS has a text based UI (not a GUI). A GPU is a graphics coprocessor/accelerator. It is not necessary to have a GPU to show graphics, it just means less work for the main CPU if you have one. Also GUI is not a synonym for GPU, just as "arithmetic" is not a synonym for "electronic calculator".
Lapsio
Posts: 13
Joined: 24. Jun 2017, 17:15

Re: Accessing "default" VBox serial port directly

Post by Lapsio »

By "it doesn't support GPU" I meant that guest doesn't support framebuffer. It displays output in pure text mode, not capable of rendering image in pixel form on its own (not like Linux guests which allocate framebuffer for TTY capable of displaying some graphics as long as application can write to framebuffer. For example some distros display penguins images during boot log)

It's embedded, proprietary OS for devices that do not have any kind of display. Whole VM drive is few megabytes. It's either VGA in text mode like vintage OSes (eg. Minix 2.0) or serial. But as I said disabling serial in this OS makes VirtualBox display blank so I'd still lean towards serial unless this OS does some weird magic with redirecting serial 0 to VGA text mode.
mpack
Site Moderator
Posts: 39134
Joined: 4. Sep 2008, 17:09
Primary OS: MS Windows 10
VBox Version: PUEL
Guest OSses: Mostly XP

Re: Accessing "default" VBox serial port directly

Post by mpack »

"Embedded, proprietary OS" may not run in a VM at all. A VM is a simulation of a PC, as already mentioned. A VM on startup runs a PC compatible BIOS, which boots the PC from disk media on which the BIOS expects to see traditional boot sectors. Embedded devices usually don't have these things
Post Reply