Serial port behavior (autodetection?)

Discussions related to using VirtualBox on Linux hosts.
Post Reply
lostrail
Posts: 1
Joined: 12. Oct 2017, 18:56

Serial port behavior (autodetection?)

Post by lostrail »

Hello to everyone,

Recently, there was a need for me to configure a serial port on a Linux host for Windows guest. So far, so good. The port works, everything seems to be fine. However...
The port is located on a docking station and after undocking, VirtualBox will popup VERR_NOT_SUPPORTED everytime I start the guest (and the guest will not boot), most probably because the serial port is no longer physically present (The system is DELL E6420 with E-Port plus docking station). I use that guest for other tasks as well, so manual disconnecting of the port each time the laptop is undocked and configuring it back each time I need it again is a real pain.
Is there any way to manage that Virtualbox will start to behave in any intelligent way, like, detect whether the port is accessible or not and start the guest OS with or without the port attached (supported) depending on the actual state of the hardware?

I tried to search for this particular problem finding many issues with serial ports, but I did not manage to find any thread specifically for this.
socratis
Site Moderator
Posts: 27329
Joined: 22. Oct 2010, 11:03
Primary OS: Mac OS X other
VBox Version: PUEL
Guest OSses: Win(*>98), Linux*, OSX>10.5
Location: Greece

Re: Serial port behavior (autodetection?)

Post by socratis »

lostrail wrote:most probably because the serial port is no longer physically present
That would be a correct assumption.
lostrail wrote:so manual disconnecting of the port each time the laptop is undocked and configuring it back each time I need it again is a real pain.
It's a check box. That's it. You enable it when you're docked, you disable it when you're not docked. Either that or you get the error.
lostrail wrote:Is there any way to manage that VirtualBox will start to behave in any intelligent way, like, detect whether the port is accessible or not and start the guest OS with or without the port attached (supported) depending on the actual state of the hardware?
Not really. It's not even your VirtualBox. Does your host OS detect the lack of the serial port? If it does then it may pass the information to VirtualBox. But such functionality does not exist in VirtualBox as far as I know. Not on the fly at least.

You got to realize that your setup is not the most common around, especially with the serial port. The network cards/cables have a way of notifying the host OS and VirtualBox, same with USB. But serial ports? That's a rather old one and there was no notification about its existence, only a failure or success.
Do NOT send me Personal Messages (PMs) for troubleshooting, they are simply deleted.
Do NOT reply with the "QUOTE" button, please use the "POST REPLY", at the bottom of the form.
If you obfuscate any information requested, I will obfuscate my response. These are virtual UUIDs, not real ones.
mpack
Site Moderator
Posts: 39134
Joined: 4. Sep 2008, 17:09
Primary OS: MS Windows 10
VBox Version: PUEL
Guest OSses: Mostly XP

Re: Serial port behavior (autodetection?)

Post by mpack »

socratis wrote:But serial ports? That's a rather old one and there was no notification about its existence
Serial ports are still widely used in industry and in hardware development. Most microcontrollers have built in serial ports and you don't need complex network stacks to get them going. Personally I despair when I see people putting a web interface on a washing machine... :)
socratis
Site Moderator
Posts: 27329
Joined: 22. Oct 2010, 11:03
Primary OS: Mac OS X other
VBox Version: PUEL
Guest OSses: Win(*>98), Linux*, OSX>10.5
Location: Greece

Re: Serial port behavior (autodetection?)

Post by socratis »

I couldn't agree with you more. But the truth of the matter is that they're missing the functionality that the OP is looking for, something akin to Plug & Play (PnP). Serial ports were invented a long, long time ago and as far as I know they can't be retrofitted to accommodate PnP. Some of them cards or break out boxes still have DIP switches ;)
Do NOT send me Personal Messages (PMs) for troubleshooting, they are simply deleted.
Do NOT reply with the "QUOTE" button, please use the "POST REPLY", at the bottom of the form.
If you obfuscate any information requested, I will obfuscate my response. These are virtual UUIDs, not real ones.
WFV
Posts: 83
Joined: 7. Mar 2016, 13:28
Primary OS: Linux other
VBox Version: OSE other
Guest OSses: ArchLinux; Fedora; Ubuntu; Win7pro64; WinXP
Contact:

Re: Serial port behavior (autodetection?)

Post by WFV »

Does the DELL E6420 have a PCMCIA slot? I've found on some laptops where USB/Serial adapters don't work, PCMCIA do due major difference in how they interact with the system hardware. PCMCIA more likely to provide a true serial port interface for laptops that don't have serial ports (much the same as the docking station provides a true serial port). Haven't tried it in Linux yet but recently purchased a laptop with PCMCIA slot due to need for serial port connection to industrial controllers (in Windows). Quatech and Brainbox make good serial/parallel pcmcia port adapters, I'm sure there are others, providing the laptop has pcmcia slot.
Post Reply