Products > Programming
[GNU/Linux] looking for a iotop-like program but written in pure C
DiTBho:
iotop is written in Python, which I cannot support on my embedded router.
looking for an alternative, written in C.
is there anything? :-//
before I start writing by myself
SiliconWizard:
https://github.com/Tomas-M/iotop
--- Quote ---Inspired by iotop Python script from Guillaume Chazarain, rewritten in C by Vyacheslav Trushkin and improved by Boian Bonev so it runs without Python at all.
--- End quote ---
DiTBho:
--- Quote from: SiliconWizard on March 13, 2023, 12:01:39 am ---https://github.com/Tomas-M/iotop
--- Quote ---Inspired by iotop Python script from Guillaume Chazarain, rewritten in C by Vyacheslav Trushkin and improved by Boian Bonev so it runs without Python at all.
--- End quote ---
--- End quote ---
thanks!
have you already tried it?
Going to add it to the new Catalyst-stage4 profile ;D
it will be tested next week!
SiliconWizard:
Yes, just compiled it and tried on Arch Linux.
It seems to work fine so far.
DiTBho:
so, iotop-c compiled on different machines, and
1) it perfectly works on my PC, i686-GNU-Linux
2) it doesn't correctly work on my router, MIPS32/LE-GNU-Linux
reports are always zero, and something triggers prIO to fail with an error
--- Code: ---struct xxxid_stats *ms=cs->sor[i],*s;
...
if (!config.f.hideprio)
{
char c=' ';
if (k==-1&&th_prio_diff)
{
c='!';
}
if (s->error_i) <---------------- something triggers this
{
attron(config.f.nocolor?A_ITALIC:COLOR_PAIR(RED_PAIR));
printw("tp_#1 ");
attroff(config.f.nocolor?A_ITALIC:COLOR_PAIR(RED_PAIR));
}
else
{
printw("%c%4s ",c,str_ioprio(s->io_prio));
}
}
--- End code ---
(src/view_curses.c)
Navigation
[0] Message Index
[#] Next page
Go to full version