draios / sysdig

Linux system exploration and troubleshooting tool with first class support for containers
http://www.sysdig.com/
Other
7.8k stars 728 forks source link

Fails to build on newer 5.19 kernels #1899

Closed ionelmc closed 1 year ago

ionelmc commented 2 years ago

On fedora with 5.19.6-200.fc36:

Downloading Packages:
sysdig-0.29.3-x86_64.rpm                                                                                                                                                            13 MB/s |  12 MB     00:00
-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Total                                                                                                                                                                               13 MB/s |  12 MB     00:00
Running transaction check
Transaction check succeeded.
Running transaction test
Transaction test succeeded.
Running transaction
  Preparing        :                                                                                                                                                                                           1/1
  Running scriptlet: sysdig-0.29.3-1.x86_64                                                                                                                                                                    1/1
  Installing       : sysdig-0.29.3-1.x86_64                                                                                                                                                                    1/1
  Running scriptlet: sysdig-0.29.3-1.x86_64                                                                                                                                                                    1/1
Creating symlink /var/lib/dkms/scap/e5c53d648f3c4694385bbe488e7d47eaa36c229a/source -> /usr/src/scap-e5c53d648f3c4694385bbe488e7d47eaa36c229a
Sign command: /lib/modules/5.19.6-200.fc36.x86_64/build/scripts/sign-file
Signing key: /var/lib/dkms/mok.key
Public certificate (MOK): /var/lib/dkms/mok.pub

Building module:
Cleaning build area...
make -j15 KERNELRELEASE=5.19.6-200.fc36.x86_64 -C /lib/modules/5.19.6-200.fc36.x86_64/build M=/var/lib/dkms/scap/e5c53d648f3c4694385bbe488e7d47eaa36c229a/build...(bad exit status: 2)
Error! Bad return status for module build on kernel: 5.19.6-200.fc36.x86_64 (x86_64)
Consult /var/lib/dkms/scap/e5c53d648f3c4694385bbe488e7d47eaa36c229a/build/make.log for more information.
Sign command: /lib/modules/5.19.6-200.fc36.x86_64/build/scripts/sign-file
Signing key: /var/lib/dkms/mok.key
Public certificate (MOK): /var/lib/dkms/mok.pub

Building module:
Cleaning build area...
make -j15 KERNELRELEASE=5.19.6-200.fc36.x86_64 -C /lib/modules/5.19.6-200.fc36.x86_64/build M=/var/lib/dkms/scap/e5c53d648f3c4694385bbe488e7d47eaa36c229a/build...(bad exit status: 2)
Error! Bad return status for module build on kernel: 5.19.6-200.fc36.x86_64 (x86_64)
Consult /var/lib/dkms/scap/e5c53d648f3c4694385bbe488e7d47eaa36c229a/build/make.log for more information.
warning: %post(sysdig-0.29.3-1.x86_64) scriptlet failed, exit status 10

Error in POSTIN scriptlet in rpm package sysdig
  Verifying        : sysdig-0.29.3-1.x86_64                                                                                                                                                                    1/1

Installed:
  sysdig-0.29.3-1.x86_64

Complete!

Build log:

DKMS make.log for scap-e5c53d648f3c4694385bbe488e7d47eaa36c229a for kernel 5.19.6-200.fc36.x86_64 (x86_64)
Wed Sep  7 03:02:57 PM EEST 2022
make: Entering directory '/usr/src/kernels/5.19.6-200.fc36.x86_64'
  CC [M]  /var/lib/dkms/scap/e5c53d648f3c4694385bbe488e7d47eaa36c229a/build/main.o
  CC [M]  /var/lib/dkms/scap/e5c53d648f3c4694385bbe488e7d47eaa36c229a/build/dynamic_params_table.o
  CC [M]  /var/lib/dkms/scap/e5c53d648f3c4694385bbe488e7d47eaa36c229a/build/fillers_table.o
  CC [M]  /var/lib/dkms/scap/e5c53d648f3c4694385bbe488e7d47eaa36c229a/build/flags_table.o
  CC [M]  /var/lib/dkms/scap/e5c53d648f3c4694385bbe488e7d47eaa36c229a/build/ppm_events.o
  CC [M]  /var/lib/dkms/scap/e5c53d648f3c4694385bbe488e7d47eaa36c229a/build/ppm_fillers.o
  CC [M]  /var/lib/dkms/scap/e5c53d648f3c4694385bbe488e7d47eaa36c229a/build/event_table.o
  CC [M]  /var/lib/dkms/scap/e5c53d648f3c4694385bbe488e7d47eaa36c229a/build/syscall_table.o
  CC [M]  /var/lib/dkms/scap/e5c53d648f3c4694385bbe488e7d47eaa36c229a/build/ppm_cputime.o
  LD [M]  /var/lib/dkms/scap/e5c53d648f3c4694385bbe488e7d47eaa36c229a/build/scap.o
  MODPOST /var/lib/dkms/scap/e5c53d648f3c4694385bbe488e7d47eaa36c229a/build/Module.symvers
ERROR: modpost: "cc_mkenc" [/var/lib/dkms/scap/e5c53d648f3c4694385bbe488e7d47eaa36c229a/build/scap.ko] undefined!
make[1]: *** [scripts/Makefile.modpost:128: /var/lib/dkms/scap/e5c53d648f3c4694385bbe488e7d47eaa36c229a/build/Module.symvers] Error 1
make: *** [Makefile:1765: modules] Error 2
make: Leaving directory '/usr/src/kernels/5.19.6-200.fc36.x86_64'

Builds just fine on 5.17.5-300.fc36.x86_64

jasondellaluce commented 2 years ago

@ionelmc I think this may be solved by bumping the version of the falcosecurity/libs dependency. Will work on this.

hhoffstaette commented 2 years ago

The PR that fixed this was here. We carry the patch in Gentoo for the driver and it works fine with all newer kernels.

jasondellaluce commented 2 years ago

That should be part of the latest Sysdig 0.30.2 release. Is the issue still reproducible for you?

hhoffstaette commented 2 years ago

That should be part of the latest Sysdig 0.30.2 release. Is the issue still reproducible for you?

I'm not sure if that was addressed to me, but @ionelmc was trying to install an rpm without the patch; I was just trying to point out the solution.

ionelmc commented 1 year ago

Seems to install fine now on fedora 36, thanks.