diff options
Diffstat (limited to 'collectors/ebpf.plugin/ebpf_shm.c')
-rw-r--r-- | collectors/ebpf.plugin/ebpf_shm.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/collectors/ebpf.plugin/ebpf_shm.c b/collectors/ebpf.plugin/ebpf_shm.c index 156ae9aa5..0cfb3abdc 100644 --- a/collectors/ebpf.plugin/ebpf_shm.c +++ b/collectors/ebpf.plugin/ebpf_shm.c @@ -821,8 +821,9 @@ void *ebpf_shm_thread(void *ptr) goto endshm; } - probe_links = ebpf_load_program(ebpf_plugin_dir, em, kernel_string, &objects); + probe_links = ebpf_load_program(ebpf_plugin_dir, em, running_on_kernel, isrh, &objects); if (!probe_links) { + em->enabled = CONFIG_BOOLEAN_NO; goto endshm; } @@ -845,11 +846,15 @@ void *ebpf_shm_thread(void *ptr) pthread_mutex_lock(&lock); ebpf_create_shm_charts(em->update_every); + ebpf_update_stats(&plugin_statistics, em); pthread_mutex_unlock(&lock); shm_collector(em); endshm: + if (!em->enabled) + ebpf_update_disabled_plugin_stats(em); + netdata_thread_cleanup_pop(1); return NULL; } |