Problem

After complete a new installation of ASMlib v3 on Oracle Linux 9.5, the command “oracleasm init” failed with the following error:

[root@oel9 ~]# oracleasm init
Mounting ASMlib driver filesystem: Not applicable with kernel 5.15.0
Setting up iofilter map for ASM disks: Failed to setup iofilter map

When validating the status, the I/O filter status showed the value ‘no’:

[root@oel9 ~]# oracleasm status
Checking if the oracleasm kernel module is loaded: no (Not required with kernel 5.15.0)
Checking if /dev/oracleasm is mounted: no (Not required with kernel 5.15.0)
Checking which I/O Interface is in use: io_uring (KABI_V3)
Checking if io_uring is enabled: yes
Checking if ASM disks have the correct ownership and permissions: yes
Checking if ASM I/O filter is set up: no

But this feature is enabled by default in the configuration file:

[root@oel9 ~]# grep -i iofilter /etc/sysconfig/oracleasm
# ORACLEASM_ENABLE_IOFILTER: 'true' means to setup iofilter for ASM disks
ORACLEASM_ENABLE_IOFILTER=true

Testing with scandisks we can see the same error:

[root@oel9 ~]# oracleasm scandisks
Reloading disk partitions: done
Cleaning any stale ASM disks...
Setting up iofilter map for ASM disks: Failed to setup iofilter map
Failed to setup iofilter map

Validating that the OS, Kernel and ASMlib rpm are in the expected version:

[root@oel9 ~]# cat /etc/oracle-release
Oracle Linux Server release 9.5

[root@oel9 ~]# uname -a
Linux oel9 5.15.0-304.171.4.el9uek.x86_64 #2 SMP Tue Dec 24 06:36:58 PST 2024 x86_64 x86_64 x86_64 GNU/Linux

[root@oel9 ~]# rpm -qa | grep oracleasm
oracleasm-support-3.0.0-6.el9.x86_64
oracleasmlib-3.0.0-13.el9.x86_64

Cause

The ASMlib v3 require the “libbpf” package installed on OS. After comparing this machine with another where the ASMlib v3 was successfully started, I noticed that the version of libbpf rpm were different. The ASMlib require the libbpf with version 1.4.0-1 or higher.

[root@oel9 ~]# rpm -qa | grep bpf
libbpf-0.6.0-6.el9.x86_64  <<==== version below of the minimal required (1.4.0-1)
libbpf-devel-0.6.0-6.el9.x86_64
bpftool-7.4.0-503.21.1.el9_5.x86_64
libpfm-4.13.0-4.el9.x86_64

Also, the “libbpf-devel” package is not required. The problem here can be caused by some test that I executed previously in the same machine.

Solution

Update the libbpf to the version 1.4.0-1 or higher.

When I tried to update all installed packages with “yum update”, I received this error indicating that the libbpf package can’t be updated, because of “libbpf-devel” dependencies, and the “libbpf-devel” don’t have a higher version to be updated together.

[root@oel9 ~]# yum update
Last metadata expiration check: 0:59:10 ago on Mon 20 Jan 2025 05:15:04 PM -03.
Error:
 Problem 1: package libbpf-devel-2:0.6.0-6.el9.x86_64 from @System requires libbpf.so.0()(64bit), but none of the providers can be installed
...
...
...
 Problem 2: problem with installed package libbpf-devel-2:0.6.0-6.el9.x86_64
...
...
...
(try to add '--allowerasing' to command line to replace conflicting packages or '--skip-broken' to skip uninstallable packages or '--nobest' to use not only best candidate packages)

As libbpf-devel is not used by ASMlib, I just forced the update with –allowerasing option, which forces the removal of conflicting packages:

[root@oel9 ~]# sudo yum update --allowerasing
Last metadata expiration check: 0:59:58 ago on Mon 20 Jan 2025 05:15:04 PM -03.
Dependencies resolved.
============================================================================================================================================================================================================================================
 Package                                                     Architecture                                  Version                                                           Repository                                                Size
============================================================================================================================================================================================================================================
Installing:
 kernel-uek-devel                                            x86_64                                        5.15.0-304.171.4.1.el9uek                                         ol9_UEKR7                                                 41 M
Upgrading:
 NetworkManager                                              x86_64                                        1:1.48.10-5.0.1.el9_5                                             ol9_baseos_latest                                        2.3 M
 NetworkManager-libnm                                        x86_64                                        1:1.48.10-5.0.1.el9_5                                             ol9_baseos_latest                                        1.8 M
 NetworkManager-team                                         x86_64                                        1:1.48.10-5.0.1.el9_5                                             ol9_baseos_latest                                         38 k
 NetworkManager-tui                                          x86_64                                        1:1.48.10-5.0.1.el9_5                                             ol9_baseos_latest                                        251 k
 iproute                                                     x86_64                                        6.8.0-1.el9_4                                                     ol9_UEKR7                                                912 k
 iproute-tc                                                  x86_64                                        6.8.0-1.el9_4                                                     ol9_UEKR7                                                498 k
 kexec-tools                                                 x86_64                                        2.0.28-1.0.10.el9_5                                               ol9_baseos_latest                                        539 k
 libbpf                                                      x86_64                                        2:1.4.0-1.el9                                                     ol9_baseos_latest                                        176 k
 libudisks2                                                  x86_64                                        2.9.4-11.0.1.el9                                                  ol9_appstream                                            200 k
 udisks2                                                     x86_64                                        2.9.4-11.0.1.el9                                                  ol9_appstream                                            565 k
Installing group/module packages:
 kernel-uek                                                  x86_64                                        5.15.0-304.171.4.1.el9uek                                         ol9_UEKR7                                                2.9 M
Installing dependencies:
 kernel-uek-core                                             x86_64                                        5.15.0-304.171.4.1.el9uek                                         ol9_UEKR7                                                 51 M
 kernel-uek-modules                                          x86_64                                        5.15.0-304.171.4.1.el9uek                                         ol9_UEKR7                                                 53 M
Removing:
 kernel-uek                                                  x86_64                                        5.15.0-205.149.5.1.el9uek                                         @ol9_UEKR7                                                 0
 kernel-uek-core                                             x86_64                                        5.15.0-205.149.5.1.el9uek                                         @ol9_UEKR7                                               100 M
 kernel-uek-modules                                          x86_64                                        5.15.0-205.149.5.1.el9uek                                         @ol9_UEKR7                                                47 M
Removing dependent packages:
 libbpf-devel                                                x86_64                                        2:0.6.0-6.el9                                                     @ol9_UEKR7                                               320 k

Transaction Summary
============================================================================================================================================================================================================================================
Install   4 Packages
Upgrade  10 Packages
Remove    4 Packages

Total download size: 154 M
Is this ok [y/N]: y
Downloading Packages:
(1/14): kernel-uek-5.15.0-304.171.4.1.el9uek.x86_64.rpm                                                                                                                                                     5.5 MB/s | 2.9 MB     00:00
(2/14): kernel-uek-core-5.15.0-304.171.4.1.el9uek.x86_64.rpm                                                                                                                                                 27 MB/s |  51 MB     00:01
(3/14): NetworkManager-1.48.10-5.0.1.el9_5.x86_64.rpm                                                                                                                                                        18 MB/s | 2.3 MB     00:00
(4/14): NetworkManager-libnm-1.48.10-5.0.1.el9_5.x86_64.rpm                                                                                                                                                  16 MB/s | 1.8 MB     00:00
(5/14): NetworkManager-team-1.48.10-5.0.1.el9_5.x86_64.rpm                                                                                                                                                  1.6 MB/s |  38 kB     00:00
(6/14): NetworkManager-tui-1.48.10-5.0.1.el9_5.x86_64.rpm                                                                                                                                                   7.9 MB/s | 251 kB     00:00
(7/14): kexec-tools-2.0.28-1.0.10.el9_5.x86_64.rpm                                                                                                                                                           15 MB/s | 539 kB     00:00
(8/14): libbpf-1.4.0-1.el9.x86_64.rpm                                                                                                                                                                       6.1 MB/s | 176 kB     00:00
(9/14): libudisks2-2.9.4-11.0.1.el9.x86_64.rpm                                                                                                                                                              7.2 MB/s | 200 kB     00:00
(10/14): udisks2-2.9.4-11.0.1.el9.x86_64.rpm                                                                                                                                                                 14 MB/s | 565 kB     00:00
(11/14): kernel-uek-devel-5.15.0-304.171.4.1.el9uek.x86_64.rpm                                                                                                                                               16 MB/s |  41 MB     00:02
(12/14): iproute-6.8.0-1.el9_4.x86_64.rpm                                                                                                                                                                   4.2 MB/s | 912 kB     00:00
(13/14): iproute-tc-6.8.0-1.el9_4.x86_64.rpm                                                                                                                                                                 14 MB/s | 498 kB     00:00
(14/14): kernel-uek-modules-5.15.0-304.171.4.1.el9uek.x86_64.rpm                                                                                                                                             18 MB/s |  53 MB     00:02
--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Total                                                                                                                                                                                                        44 MB/s | 154 MB     00:03
Running transaction check
Transaction check succeeded.
Running transaction test
Transaction test succeeded.
Running transaction
  Preparing        :                                                                                                                                                                                                                    1/1
  Upgrading        : libbpf-2:1.4.0-1.el9.x86_64                                                                                                                                                                                       1/28
  Upgrading        : NetworkManager-libnm-1:1.48.10-5.0.1.el9_5.x86_64                                                                                                                                                                 2/28
  Running scriptlet: NetworkManager-libnm-1:1.48.10-5.0.1.el9_5.x86_64                                                                                                                                                                 2/28
  Running scriptlet: NetworkManager-1:1.48.10-5.0.1.el9_5.x86_64                                                                                                                                                                       3/28
  Upgrading        : NetworkManager-1:1.48.10-5.0.1.el9_5.x86_64                                                                                                                                                                       3/28
  Running scriptlet: NetworkManager-1:1.48.10-5.0.1.el9_5.x86_64                                                                                                                                                                       3/28
  Running scriptlet: kernel-uek-core-5.15.0-304.171.4.1.el9uek.x86_64                                                                                                                                                                  4/28
  Installing       : kernel-uek-core-5.15.0-304.171.4.1.el9uek.x86_64                                                                                                                                                                  4/28
  Running scriptlet: kernel-uek-core-5.15.0-304.171.4.1.el9uek.x86_64                                                                                                                                                                  4/28
  Installing       : kernel-uek-modules-5.15.0-304.171.4.1.el9uek.x86_64                                                                                                                                                               5/28
  Running scriptlet: kernel-uek-modules-5.15.0-304.171.4.1.el9uek.x86_64                                                                                                                                                               5/28
  Upgrading        : iproute-6.8.0-1.el9_4.x86_64                                                                                                                                                                                      6/28
  Upgrading        : libudisks2-2.9.4-11.0.1.el9.x86_64                                                                                                                                                                                7/28
  Upgrading        : udisks2-2.9.4-11.0.1.el9.x86_64                                                                                                                                                                                   8/28
  Running scriptlet: udisks2-2.9.4-11.0.1.el9.x86_64                                                                                                                                                                                   8/28
  Upgrading        : iproute-tc-6.8.0-1.el9_4.x86_64                                                                                                                                                                                   9/28
  Installing       : kernel-uek-5.15.0-304.171.4.1.el9uek.x86_64                                                                                                                                                                      10/28
  Upgrading        : NetworkManager-team-1:1.48.10-5.0.1.el9_5.x86_64                                                                                                                                                                 11/28
  Upgrading        : NetworkManager-tui-1:1.48.10-5.0.1.el9_5.x86_64                                                                                                                                                                  12/28
  Upgrading        : kexec-tools-2.0.28-1.0.10.el9_5.x86_64                                                                                                                                                                           13/28
  Running scriptlet: kexec-tools-2.0.28-1.0.10.el9_5.x86_64                                                                                                                                                                           13/28
  Installing       : kernel-uek-devel-5.15.0-304.171.4.1.el9uek.x86_64                                                                                                                                                                14/28
  Running scriptlet: kernel-uek-devel-5.15.0-304.171.4.1.el9uek.x86_64                                                                                                                                                                14/28
  Cleanup          : NetworkManager-tui-1:1.48.10-3.0.1.el9_5.x86_64                                                                                                                                                                  15/28
  Cleanup          : iproute-tc-5.18.0-1.0.1.el9.x86_64                                                                                                                                                                               16/28
  Erasing          : libbpf-devel-2:0.6.0-6.el9.x86_64                                                                                                                                                                                17/28
  Erasing          : kernel-uek-5.15.0-205.149.5.1.el9uek.x86_64                                                                                                                                                                      18/28
  Cleanup          : iproute-5.18.0-1.0.1.el9.x86_64                                                                                                                                                                                  19/28
  Running scriptlet: udisks2-2.9.4-11.el9.x86_64                                                                                                                                                                                      20/28
  Cleanup          : udisks2-2.9.4-11.el9.x86_64                                                                                                                                                                                      20/28
  Running scriptlet: udisks2-2.9.4-11.el9.x86_64                                                                                                                                                                                      20/28
  Erasing          : kernel-uek-modules-5.15.0-205.149.5.1.el9uek.x86_64                                                                                                                                                              21/28
  Running scriptlet: kernel-uek-modules-5.15.0-205.149.5.1.el9uek.x86_64                                                                                                                                                              21/28
  Cleanup          : NetworkManager-team-1:1.48.10-3.0.1.el9_5.x86_64                                                                                                                                                                 22/28
  Running scriptlet: kernel-uek-core-5.15.0-205.149.5.1.el9uek.x86_64                                                                                                                                                                 23/28
  Erasing          : kernel-uek-core-5.15.0-205.149.5.1.el9uek.x86_64                                                                                                                                                                 23/28
  Running scriptlet: kernel-uek-core-5.15.0-205.149.5.1.el9uek.x86_64                                                                                                                                                                 23/28
  Running scriptlet: NetworkManager-1:1.48.10-3.0.1.el9_5.x86_64                                                                                                                                                                      24/28
  Cleanup          : NetworkManager-1:1.48.10-3.0.1.el9_5.x86_64                                                                                                                                                                      24/28
  Running scriptlet: NetworkManager-1:1.48.10-3.0.1.el9_5.x86_64                                                                                                                                                                      24/28
  Cleanup          : NetworkManager-libnm-1:1.48.10-3.0.1.el9_5.x86_64                                                                                                                                                                25/28
  Running scriptlet: NetworkManager-libnm-1:1.48.10-3.0.1.el9_5.x86_64                                                                                                                                                                25/28
  Cleanup          : libudisks2-2.9.4-11.el9.x86_64                                                                                                                                                                                   26/28
  Cleanup          : libbpf-2:0.6.0-6.el9.x86_64                                                                                                                                                                                      27/28
  Running scriptlet: kexec-tools-2.0.28-1.0.9.el9.x86_64                                                                                                                                                                              28/28
  Cleanup          : kexec-tools-2.0.28-1.0.9.el9.x86_64                                                                                                                                                                              28/28
  Running scriptlet: kexec-tools-2.0.28-1.0.9.el9.x86_64                                                                                                                                                                              28/28
  Running scriptlet: kernel-uek-core-5.15.0-304.171.4.1.el9uek.x86_64                                                                                                                                                                 28/28
  Running scriptlet: kexec-tools-2.0.28-1.0.10.el9_5.x86_64                                                                                                                                                                           28/28
  Running scriptlet: kexec-tools-2.0.28-1.0.9.el9.x86_64                                                                                                                                                                              28/28
  Verifying        : kernel-uek-5.15.0-304.171.4.1.el9uek.x86_64                                                                                                                                                                       1/28
  Verifying        : kernel-uek-core-5.15.0-304.171.4.1.el9uek.x86_64                                                                                                                                                                  2/28
  Verifying        : kernel-uek-devel-5.15.0-304.171.4.1.el9uek.x86_64                                                                                                                                                                 3/28
  Verifying        : kernel-uek-modules-5.15.0-304.171.4.1.el9uek.x86_64                                                                                                                                                               4/28
  Verifying        : NetworkManager-1:1.48.10-5.0.1.el9_5.x86_64                                                                                                                                                                       5/28
  Verifying        : NetworkManager-1:1.48.10-3.0.1.el9_5.x86_64                                                                                                                                                                       6/28
  Verifying        : NetworkManager-libnm-1:1.48.10-5.0.1.el9_5.x86_64                                                                                                                                                                 7/28
  Verifying        : NetworkManager-libnm-1:1.48.10-3.0.1.el9_5.x86_64                                                                                                                                                                 8/28
  Verifying        : NetworkManager-team-1:1.48.10-5.0.1.el9_5.x86_64                                                                                                                                                                  9/28
  Verifying        : NetworkManager-team-1:1.48.10-3.0.1.el9_5.x86_64                                                                                                                                                                 10/28
  Verifying        : NetworkManager-tui-1:1.48.10-5.0.1.el9_5.x86_64                                                                                                                                                                  11/28
  Verifying        : NetworkManager-tui-1:1.48.10-3.0.1.el9_5.x86_64                                                                                                                                                                  12/28
  Verifying        : kexec-tools-2.0.28-1.0.10.el9_5.x86_64                                                                                                                                                                           13/28
  Verifying        : kexec-tools-2.0.28-1.0.9.el9.x86_64                                                                                                                                                                              14/28
  Verifying        : libbpf-2:1.4.0-1.el9.x86_64                                                                                                                                                                                      15/28
  Verifying        : libbpf-2:0.6.0-6.el9.x86_64                                                                                                                                                                                      16/28
  Verifying        : libudisks2-2.9.4-11.0.1.el9.x86_64                                                                                                                                                                               17/28
  Verifying        : libudisks2-2.9.4-11.el9.x86_64                                                                                                                                                                                   18/28
  Verifying        : udisks2-2.9.4-11.0.1.el9.x86_64                                                                                                                                                                                  19/28
  Verifying        : udisks2-2.9.4-11.el9.x86_64                                                                                                                                                                                      20/28
  Verifying        : iproute-6.8.0-1.el9_4.x86_64                                                                                                                                                                                     21/28
  Verifying        : iproute-5.18.0-1.0.1.el9.x86_64                                                                                                                                                                                  22/28
  Verifying        : iproute-tc-6.8.0-1.el9_4.x86_64                                                                                                                                                                                  23/28
  Verifying        : iproute-tc-5.18.0-1.0.1.el9.x86_64                                                                                                                                                                               24/28
  Verifying        : kernel-uek-5.15.0-205.149.5.1.el9uek.x86_64                                                                                                                                                                      25/28
  Verifying        : kernel-uek-core-5.15.0-205.149.5.1.el9uek.x86_64                                                                                                                                                                 26/28
  Verifying        : kernel-uek-modules-5.15.0-205.149.5.1.el9uek.x86_64                                                                                                                                                              27/28
  Verifying        : libbpf-devel-2:0.6.0-6.el9.x86_64                                                                                                                                                                                28/28

Upgraded:
  NetworkManager-1:1.48.10-5.0.1.el9_5.x86_64   NetworkManager-libnm-1:1.48.10-5.0.1.el9_5.x86_64   NetworkManager-team-1:1.48.10-5.0.1.el9_5.x86_64   NetworkManager-tui-1:1.48.10-5.0.1.el9_5.x86_64   iproute-6.8.0-1.el9_4.x86_64
  iproute-tc-6.8.0-1.el9_4.x86_64               kexec-tools-2.0.28-1.0.10.el9_5.x86_64              libbpf-2:1.4.0-1.el9.x86_64                        libudisks2-2.9.4-11.0.1.el9.x86_64                udisks2-2.9.4-11.0.1.el9.x86_64
Installed:
  kernel-uek-5.15.0-304.171.4.1.el9uek.x86_64           kernel-uek-core-5.15.0-304.171.4.1.el9uek.x86_64           kernel-uek-devel-5.15.0-304.171.4.1.el9uek.x86_64           kernel-uek-modules-5.15.0-304.171.4.1.el9uek.x86_64
Removed:
  kernel-uek-5.15.0-205.149.5.1.el9uek.x86_64               kernel-uek-core-5.15.0-205.149.5.1.el9uek.x86_64               kernel-uek-modules-5.15.0-205.149.5.1.el9uek.x86_64               libbpf-devel-2:0.6.0-6.el9.x86_64

Complete!

After completing the yum update, I can see the libbpf installed with the expected version:

[root@oel9 ~]# rpm -qa | grep bpf
bpftool-7.4.0-503.21.1.el9_5.x86_64
libpfm-4.13.0-4.el9.x86_64
libbpf-1.4.0-1.el9.x86_64 <<==== 1.4.0-1 is the minimal required for ASMlib v3

Now I’m able to successfully restart the ASMlib service:

[root@oel9 ~]# systemctl restart oracleasm
[root@oel9 ~]# systemctl status oracleasm
● oracleasm.service - Load oracleasm Modules
     Loaded: loaded (/usr/lib/systemd/system/oracleasm.service; enabled; preset: disabled)
     Active: active (exited) since Mon 2025-01-20 18:17:59 -03; 4s ago
    Process: 81025 ExecStartPre=/usr/bin/udevadm settle -t 120 (code=exited, status=0/SUCCESS)
    Process: 81036 ExecStart=/usr/sbin/oracleasm.init start_sysctl (code=exited, status=0/SUCCESS)
   Main PID: 81036 (code=exited, status=0/SUCCESS)
        CPU: 184ms

Jan 20 18:17:59 oel9clone systemd[1]: Starting Load oracleasm Modules...
Jan 20 18:17:59 oel9clone oracleasm.init[81036]: Initializing the Oracle ASMLib driver: OK
Jan 20 18:17:59 oel9clone oracleasm.init[81036]: Scanning the system for Oracle ASMLib disks: OK
Jan 20 18:17:59 oel9clone systemd[1]: Finished Load oracleasm Modules.

Testing the scandisks manually again, we can see that everithing is working now:

[root@oel9 ~]# oracleasm scandisks
Reloading disk partitions: done
Cleaning any stale ASM disks...
Setting up iofilter map for ASM disks: done
Scanning system for ASM disks...

Finally, the status of I/O filter was updated to ‘yes’:

[root@oel9clone ~]# oracleasm status
Checking if the oracleasm kernel module is loaded: no (Not required with kernel 5.15.0)
Checking if /dev/oracleasm is mounted: no (Not required with kernel 5.15.0)
Checking which I/O Interface is in use: io_uring (KABI_V3)
Checking if io_uring is enabled: yes
Checking if ASM disks have the correct ownership and permissions: yes
Checking if ASM I/O filter is set up: yes

2 thoughts on “ASMlib v3 Error: “Setting up iofilter map for ASM disks: Failed to setup iofilter map””
  1. At core, this seems to be a packaging issue. I assume that when the dependency issue with the packages is solved in the repository, new installations will not have this issue, right?

Leave a Reply to Maicon CarneiroCancel reply

Discover more from Blog do Dibiei

Subscribe now to keep reading and get access to the full archive.

Continue reading