1

Ubuntu behave sometimes different in Virtualbox client then standalone. I want, in terminal, to detect if Ubuntu is running in Virtualbox client. Even if Virtualbox Guest additions are not installed. Which happens sometimes. Is that possible? If so how?

My search direction was something similar as VBox guest addition. Guest additional does communicate with Virtualbox host. So maybe a signal can be capture. But this direction gets to complicated. I presume there must be a difference between Ubuntu running standalone, and Ubuntu in VM client what can be captured. virtualbox-server-client-topology title seems to cover the topic, but the content, in my view, not. But I have no idea what and even how to search.

Bernard
  • 461

1 Answers1

1

If I run lspci on a LiveCD booted in VirtualBox I see a couple of devices which give it away:

00:02.0 VGA compatible controller: InnoTek Systemberatung GmbH VirtualBox Graphics Adapter
00:04.0 System peripheral: InnoTek Systemberatung GmbH VirtualBox Guest Service

I haven't installed the Guest additions.

If this is scripted, you could do something as simple as:

if [[ lspci | grep VirtualBox >/dev/null ]]; then
   ...
fi
Oli
  • 299,380