Blob Blame History Raw
diff --git a/tests/probes/sysctl/test_sysctl_probe_all.sh b/tests/probes/sysctl/test_sysctl_probe_all.sh
index bc9513347..2f17adc8b 100755
--- a/tests/probes/sysctl/test_sysctl_probe_all.sh
+++ b/tests/probes/sysctl/test_sysctl_probe_all.sh
@@ -73,10 +73,14 @@ if [ "$procps_ver" != "$lowest_ver" ]; then
 	sed -i '/.*vm.stat_refresh/d' "$sysctlNames"
 fi
 
+if ! grep -q "hugepages" "$ourNames"; then
+	sed -i "/^.*hugepages.*$/d" "$sysctlNames"
+fi
 diff "$sysctlNames" "$ourNames"
 
 # remove oscap error message related to permissions from stderr
 sed -i -E "/^E: oscap: +Can't read sysctl value from /d" "$stderr"
+sed -i "/^.*hugepages.*$/d" "$stderr"
 [ ! -s $stderr ]
 
 rm $stderr $result $ourNames $sysctlNames