VirtualBox

Ticket #20941 (closed defect: fixed)

Opened 3 months ago

Last modified 4 weeks ago

Can't compile Kernel Modules on Centos9 Stream (stdarg.h missing) => fixed in SVN

Reported by: powerschlumpf Owned by:
Component: other Version: VirtualBox 6.1.34
Keywords: kernel module centos stdarg.h Cc:
Guest type: Linux Host type: Linux

Description

I'm running an old notebook as a small "server" that runs a few services. One of these is HomeAssistant running in a VirtualBox Machine and is automatically booted at system start.

Virtualbox was installed using the Fedora Repo. Tried the "all distributions" version as well...

[root@hp-notebook-server klaus]# rpm -qa | grep Virtual
VirtualBox-6.1-6.1.34_150636_fedora33-2.x86_64

Since a few days (assuming after an auto update) it stopped working. Had a look at it and it can't compile the vbox kernel modules. /var/log/vbox-setup.log states (sorry for the german phrases, But I guess you get the import part...)

In Datei, eingebunden von /tmp/vbox.0/include/iprt/types.h:34,
                 von /tmp/vbox.0/include/VBox/types.h:33,
                 von /tmp/vbox.0/SUPDrvInternal.h:38,
                 von /tmp/vbox.0/SUPDrv.c:33:
/tmp/vbox.0/include/iprt/stdarg.h:51:13: schwerwiegender Fehler: stdarg.h: Datei oder Verzeichnis nicht gefunden
   51 | #   include <stdarg.h>
      |             ^~~~~~~~~~
In Datei, eingebunden von /tmp/vbox.0/include/iprt/types.h:34,
                 von /tmp/vbox.0/include/VBox/types.h:33,
                 von /tmp/vbox.0/linux/../SUPDrvInternal.h:38,
                 von /tmp/vbox.0/linux/SUPDrv-linux.c:32:
/tmp/vbox.0/include/iprt/stdarg.h:51:13: schwerwiegender Fehler: stdarg.h: Datei oder Verzeichnis nicht gefunden
   51 | #   include <stdarg.h>
      |             ^~~~~~~~~~
In Datei, eingebunden von /tmp/vbox.0/include/iprt/types.h:34,
                 von /tmp/vbox.0/include/VBox/types.h:33,
                 von /tmp/vbox.0/SUPDrvInternal.h:38,
                 von /tmp/vbox.0/SUPDrvSem.c:33:
/tmp/vbox.0/include/iprt/stdarg.h:51:13: schwerwiegender Fehler: stdarg.h: Datei oder Verzeichnis nicht gefunden
   51 | #   include <stdarg.h>
      |             ^~~~~~~~~~
In Datei, eingebunden von /tmp/vbox.0/include/iprt/types.h:34,
                 von /tmp/vbox.0/include/VBox/types.h:33,
                 von /tmp/vbox.0/SUPDrvInternal.h:38,
                 von /tmp/vbox.0/SUPDrvGip.c:33:
/tmp/vbox.0/include/iprt/stdarg.h:51:13: schwerwiegender Fehler: stdarg.h: Datei oder Verzeichnis nicht gefunden
   51 | #   include <stdarg.h>
      |             ^~~~~~~~~~
Kompilierung beendet.
Kompilierung beendet.
Kompilierung beendet.
Kompilierung beendet.
make[2]: *** [scripts/Makefile.build:271: /tmp/vbox.0/SUPDrvSem.o] Fehler 1
make[2]: *** Es wird auf noch nicht beendete Prozesse gewartet....
make[2]: *** [scripts/Makefile.build:271: /tmp/vbox.0/SUPDrv.o] Fehler 1
make[2]: *** [scripts/Makefile.build:271: /tmp/vbox.0/SUPDrvGip.o] Fehler 1
make[2]: *** [scripts/Makefile.build:271: /tmp/vbox.0/linux/SUPDrv-linux.o] Fehler 1
make[1]: *** [Makefile:1862: /tmp/vbox.0] Fehler 2
make: *** [/tmp/vbox.0/Makefile-footer.gmk:117: vboxdrv] Fehler 2

So it claims stdarg.h is missing

kernel-header and kernel-devel are installed

[root@hp-notebook-server klaus]# rpm -qa | grep kernel*
kernel-srpm-macros-1.0-11.el9.noarch
kernel-core-5.14.0-80.el9.x86_64
kernel-modules-5.14.0-80.el9.x86_64
kernel-5.14.0-80.el9.x86_64
kernel-core-5.14.0-85.el9.x86_64
kernel-modules-5.14.0-85.el9.x86_64
kernel-5.14.0-85.el9.x86_64
kernel-core-5.14.0-86.el9.x86_64
kernel-modules-5.14.0-86.el9.x86_64
kernel-tools-libs-5.14.0-86.el9.x86_64
kernel-tools-5.14.0-86.el9.x86_64
kernel-5.14.0-86.el9.x86_64
kernel-devel-5.14.0-86.el9.x86_64
kernel-devel-5.14.0-85.el9.x86_64
kernel-devel-5.14.0-80.el9.x86_64
kernel-headers-5.14.0-86.el9.x86_64

For me it seems there are some libraries missing, which should be available... stdarg.h is available in the kernel sources

[root@hp-notebook-server klaus]# locate stdarg.h
/usr/include/c++/11/tr1/stdarg.h
/usr/lib/gcc/x86_64-redhat-linux/11/include/cross-stdarg.h
/usr/lib/gcc/x86_64-redhat-linux/11/include/stdarg.h
/usr/share/man/man0p/stdarg.h.0p.gz
/usr/share/virtualbox/src/vboxhost/vboxdrv/include/iprt/stdarg.h
/usr/share/virtualbox/src/vboxhost/vboxnetadp/include/iprt/stdarg.h
/usr/share/virtualbox/src/vboxhost/vboxnetflt/include/iprt/stdarg.h
/usr/src/kernels/5.14.0-85.el9.x86_64/include/linux/stdarg.h
/usr/src/kernels/5.14.0-85.el9.x86_64/include/linux/stdarg.h.hardlink-temporary
/usr/src/kernels/5.14.0-86.el9.x86_64/include/linux/stdarg.h
/usr/src/kernels/5.14.0-86.el9.x86_64/include/linux/stdarg.h.hardlink-temporary

It was working for a few month, but stopped...

Change History

comment:1 Changed 3 months ago by foracle

I can confirm this happening

comment:2 Changed 3 months ago by galitsyn

Hi guys,

Could you please give it a try to the test build: https://www.virtualbox.org/download/testcase/VirtualBox-6.1.35-151478-Linux_amd64.run. If you would like to run CentOS Stream 9 as a guest, the following Guest Additions need to be installed: https://www.virtualbox.org/download/testcase/VBoxGuestAdditions_6.1.35-151478.iso.

We will include this fix into the next release.

comment:3 Changed 3 months ago by powerschlumpf

The mentioned test version works fine!

Thanks for your work

comment:4 Changed 3 months ago by galitsyn

  • Summary changed from Can't compile Kernel Modules on Centos9 Stream (stdarg.h missing) to Can't compile Kernel Modules on Centos9 Stream (stdarg.h missing) => fixed in SVNTh

Thank you for the feedback.

comment:5 Changed 3 months ago by galitsyn

  • Summary changed from Can't compile Kernel Modules on Centos9 Stream (stdarg.h missing) => fixed in SVNTh to Can't compile Kernel Modules on Centos9 Stream (stdarg.h missing) => fixed in SVN

comment:6 Changed 3 months ago by foracle

i can confirm the test build works

comment:7 Changed 3 months ago by Manjeet

even using VirtualBox-6.1.35-151478-Linux_amd64.run I am facing installation error. I m using CENTOS stream desktop 9 as guest and ubuntu Ubuntu 20.04.4 LTS as host. I m using VirtualBox-6.1.35-151478 version. Following is command output on my guest:

[vagrant@localhost ~]$ sudo /tmp/vbox/VBoxLinuxAdditions.run --nox11
true

Verifying archive integrity... All good. Uncompressing VirtualBox 6.1.35 Guest Additions for Linux........ VirtualBox Guest Additions installer Removing installed version 6.1.35 of VirtualBox Guest Additions... Copying additional installer modules ... Installing additional modules ... VirtualBox Guest Additions: Starting. VirtualBox Guest Additions: Building the VirtualBox Guest Additions kernel modules. This may take a while. VirtualBox Guest Additions: To build modules for other installed kernels, run VirtualBox Guest Additions: /sbin/rcvboxadd quicksetup <version> VirtualBox Guest Additions: or VirtualBox Guest Additions: /sbin/rcvboxadd quicksetup all VirtualBox Guest Additions: Building the modules for kernel 5.14.0-86.el9.x86_64.

VirtualBox Guest Additions: Look at /var/log/vboxadd-setup.log to find out what went wrong ValueError: File context for /opt/VBoxGuestAdditions-6.1.35/other/mount.vboxsf already defined modprobe vboxguest failed The log file /var/log/vboxadd-setup.log may contain further information.

[vagrant@localhost ~]$

/var/log/vboxadd-setup.log contains following error:

/tmp/vbox.0/include/iprt/stdarg.h:51:13: fatal error: stdarg.h: No such file or directory

comment:8 Changed 3 months ago by galitsyn

Hi Manjeet,

Please make sure you installed Guest Additions from the link mentioned in comment 2.

comment:9 Changed 2 months ago by Manjeet

Yes I installed guest additions from link mentioned in comment no. 2. Still I m facing error stdarg.h: No such file or directory

comment:10 follow-up: ↓ 13 Changed 2 months ago by galitsyn

Hi Manjeet,

Just updated my CentOS Stream 9 guest up to kernel 5.14.0-105.el9.x86_64. No issue with Additions from https://www.virtualbox.org/download/testcase/VBoxGuestAdditions_6.1.35-151478.iso. What "VBoxClient -V" shows in your guest?

comment:11 Changed 2 months ago by spinicist

Hello,

I'm having this problem as well. The link to version 6.1.35 of the Guest Additions appears to be dead - I get a 404 from it. Is there a new link? Thanks.

comment:12 follow-up: ↓ 17 Changed 2 months ago by galitsyn

Hi spinicist,

You can pick up Additions iso from the "Latest 6.1.x test builds" at https://www.virtualbox.org/wiki/Testbuilds.

comment:13 in reply to: ↑ 10 ; follow-up: ↓ 14 Changed 8 weeks ago by Manjeet

Replying to galitsyn:

Hi Manjeet,

Just updated my CentOS Stream 9 guest up to kernel 5.14.0-105.el9.x86_64. No issue with Additions from https://www.virtualbox.org/download/testcase/VBoxGuestAdditions_6.1.35-151478.iso. What "VBoxClient -V" shows in your guest?

VBoxClient -V commands in my guest shows: VBoxClient: error while loading shared libraries: libX11.so.6: cannot open shared object file: No such file or directory

comment:14 in reply to: ↑ 13 ; follow-up: ↓ 15 Changed 8 weeks ago by galitsyn

Replying to Manjeet:

Replying to galitsyn:

Hi Manjeet,

Just updated my CentOS Stream 9 guest up to kernel 5.14.0-105.el9.x86_64. No issue with Additions from https://www.virtualbox.org/download/testcase/VBoxGuestAdditions_6.1.35-151478.iso. What "VBoxClient -V" shows in your guest?

VBoxClient -V commands in my guest shows: VBoxClient: error while loading shared libraries: libX11.so.6: cannot open shared object file: No such file or directory

Right, VBoxClient requires X11 libraries to be installed in the system. I still have suspicion that somehow installed Additions are not those which mentioned above. Could you please post the output of "VBoxService -V"?

comment:15 in reply to: ↑ 14 Changed 8 weeks ago by Manjeet

Replying to galitsyn:

Replying to Manjeet:

Replying to galitsyn:

Hi Manjeet,

Just updated my CentOS Stream 9 guest up to kernel 5.14.0-105.el9.x86_64. No issue with Additions from https://www.virtualbox.org/download/testcase/VBoxGuestAdditions_6.1.35-151478.iso. What "VBoxClient -V" shows in your guest?

VBoxClient -V commands in my guest shows: VBoxClient: error while loading shared libraries: libX11.so.6: cannot open shared object file: No such file or directory

Right, VBoxClient requires X11 libraries to be installed in the system. I still have suspicion that somehow installed Additions are not those which mentioned above. Could you please post the output of "VBoxService -V"?

I have installed X11 libraries and I reinsalled vboxadditions from https://www.virtualbox.org/download/testcase/VBoxGuestAdditions_6.1.35-151478.iso. but now it is showing error when I run command sudo ./VBoxLinuxAdditions.run --nox11 :

Kernel headers not found for target kernel 5.14.0-86.el9.x86_64. Please install them and execute

/sbin/rcvboxadd setup

Output from commands: [vagrant@localhost ~]$ uname -r 5.14.0-86.el9.x86_64 [vagrant@localhost ~]$ VBoxClient -V 6.1.35r151466 [vagrant@localhost ~]$ VBoxService -V 6.1.35r151466

comment:16 Changed 8 weeks ago by galitsyn

Hi Manjeet,

$ VBoxService -V
6.1.35r151466

This shows that installed Additions are not r151478 (probably you ran this before installing Additions from mentioned iso). r151466 not yet have the fix.

Kernel headers not found for target kernel 5.14.0-86.el9.x86_64. Please install them and execute

/sbin/rcvboxadd setup

This is what needs to be done. You need to install kernel headers package for currently running kernel.

comment:17 in reply to: ↑ 12 Changed 8 weeks ago by spinicist

Replying to galitsyn:

Hi spinicist,

You can pick up Additions iso from the "Latest 6.1.x test builds" at https://www.virtualbox.org/wiki/Testbuilds.

Thanks so much. I confirm the latest build installs correctly.

comment:18 Changed 4 weeks ago by galitsyn

  • Status changed from new to closed
  • Resolution set to fixed

Thank you for reporting the issue. It should be fixed in VirtualBox 6.1.36. Please refer to https://www.virtualbox.org/wiki/Downloads page.

Note: See TracTickets for help on using tickets.

www.oracle.com
ContactPrivacy policyTerms of Use