Package Details: netatop 3.1-1

Git Clone URL: https://aur.archlinux.org/netatop.git (read-only, click to copy)
Package Base: netatop
Description: Atop network kernel module, enables network statistics in atop
Upstream URL: http://www.atoptool.nl/
Keywords: atop kernel module netatop
Licenses: GPL
Groups: modules
Submitter: Spider.007
Maintainer: batot
Last Packager: Spider.007
Votes: 27
Popularity: 0.018573
First Submitted: 2013-02-16 11:58 (UTC)
Last Updated: 2020-05-30 09:43 (UTC)

Latest Comments

1 2 3 4 5 6 Next › Last »

batot commented on 2023-04-05 20:28 (UTC) (edited on 2023-04-05 20:28 (UTC) by batot)

Hi all. I was testing with Archlinux with kernel 5.15.84 and working property.

If I will be find time, I put file PKGBUILD to replace for MANJARO systems.

valandil commented on 2021-12-12 18:50 (UTC)

Have you updated your kernel without rebooting? I believe Manjaro (like Arch) will delete the /lib/modules/<old_kernel_version> when doing an upgrade, so you can't install kernel modules after you've updated it.

pranaypratyush commented on 2021-12-12 18:17 (UTC)

Errors out

:: Processing package changes...
(1/1) installing netatop                                                                                                                                                 [#########################################################################################################] 100%
depmod: ERROR: could not open directory /lib/modules/5.15.6-2-MANJARO: No such file or directory
depmod: FATAL: could not search modules: No such file or directory
modprobe: FATAL: Module netatop not found in directory /lib/modules/5.15.6-2-MANJARO
error: command failed to execute correctly

valandil commented on 2020-04-27 13:18 (UTC)

I have submitted a patch to upstream by building on eggz' work, and my own grep fu :)

This time, it is related to a change in the timespec struct in the kernel, and a move to proc_ops from filesystem_operations. See commits 22b17db4ea05561c7c8e4d770f10751e22e339f9 and d56c0d45f0e27f814e87a1676b6bdccccbc252e9 of the kernel repo.

Here's the patch:

diff -aur src.pristine/netatop-3.0/module/netatop.c src.new/netatop-3.0/module/netatop.c
--- src.pristine/netatop-3.0/module/netatop.c   2020-04-27 08:28:05.649361867 -0400
+++ src.new/netatop-3.0/module/netatop.c    2020-04-27 09:00:29.473109963 -0400
@@ -270,7 +270,12 @@

 static struct task_struct  *knetatop_task;

-static struct timespec boottime;
+
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(5, 6, 0)
+               static struct timespec64    boottime;
+#else
+               static struct timespec  boottime;
+#endif

 /*
 ** function prototypes
@@ -346,14 +351,22 @@
         .owner          = THIS_MODULE,
 };

+#if LINUX_VERSION_CODE >= KERNEL_VERSION(5, 6, 0)
+static struct proc_ops netatop_proc_fops = {
+   .proc_open          = netatop_open,
+   .proc_read          = seq_read,
+   .proc_lseek         = seq_lseek,
+   .proc_release       = single_release,
+};
+#else
 static struct file_operations netatop_proc_fops = {
-   .open           = netatop_open,
-   .read           = seq_read,
-   .llseek         = seq_lseek,
-   .release    = single_release,
-   .owner          = THIS_MODULE,
+   .open           = netatop_open,
+   .read           = seq_read,
+   .llseek         = seq_lseek,
+   .proc_release   = single_release,
+   .owner                  = THIS_MODULE
 };
-
+#endif

 /*
 ** hook function to be called for every incoming local packet
@@ -1745,7 +1758,11 @@
        spin_lock_init(&shash[i].lock);
    }

-   getboottime(&boottime);
+   #if LINUX_VERSION_CODE >= KERNEL_VERSION(5, 6, 0)
+       getboottime64(&boottime);
+   #else
+       getboottime(&boottime);
+   #endif

    /*
    ** register getsockopt for user space communication

frankspace commented on 2020-04-25 19:54 (UTC)

FYI, eggz provided some amendments to prepare() in the comments for the netatop-dkms package that worked for me.

3ndymion commented on 2020-04-09 22:40 (UTC)

Thanks for reporting. I noticed it too, but I've been very busy. If the developer got your message, it will probably take him some time to find the changes that were made in the kernel again. As long as you mentioned the same things you mentioned here, then he'll probably know what to look for.

frankspace commented on 2020-04-09 15:23 (UTC) (edited on 2020-04-09 20:12 (UTC) by frankspace)

It seems that this is broken again with kernel 5.6. I am not entirely sure why, but it seems to have something to do with getboottime or getboottime64, maybe involving changes in timekeeping.h or "struct timespc"... but to be honest, I'm nowhere near clever enough to figure out exactly what changed.

Edit: I have sent a message to the maintainer.

Spider.007 commented on 2020-03-04 17:58 (UTC)

@bartus why are you flagging this package out of date?

3ndymion commented on 2020-03-03 15:43 (UTC)

Please Note: The maintainer of netatop on the atop website has responded to me. Netatop v3.0 is now available. I already tested it with this makepkg, & it works perfectly fine now. He also added a SystemD service file which I have not looked into yet.

Please test it all & see. This should be able to be implemented without any patches now.

bartus commented on 2020-02-28 14:56 (UTC)

Patch for kernel>=5.5

git am < <(curl -s http://ix.io/1DAW)