Re: Wish-List for GTOP



> 
> Hello,
> 
> I'd like to work a little bit on GTop. In the TODO-List I found:
> 
>       Add a way to examine processes (ie, like gmemusage on IRIX,
>       so that you can walk the VM of the process and even lookup
>       symbols and see where functions are, pretty slick IRIX toy).
> 
> What exactly should this do? How system-dependent should/can it be (ie.
> using the proc filesystem should be ok, but what about the symbols, should
> it read the output of some tool like nm?)
> 
> What about SysV IPC?
> 
> Does anyone have some other ideas?

Yes, I do ;-)

I also thought about working on gtop, but do not have time actually. But
I would propose one thing:

1. Define a set of 'top'-relevant information. a good orientation surly
is gtop. (this set should be an union in the sense of the set theory for
different systems). 

2. Define a function to return which of these infos are available in
this particular implementation.

3. Define a set of functions to return the available data. (e.g.
memory-usage; maybe net-usage; of course process-info and so on.)

4. write a program, that reads a short command and raw data on stdin and
writes the result to the stdout. (you will see later, why)

5. reprogram the in point 2. and 3. mentioned functions using only the
in point 4. mentioned program.

4. and 5. are necessary for platforms like mine (solaris), where a
humble user (like me) can't read such data. Here all kind of
top-programs need to be setuid root, which a gnome-based (gtk-based, for
that matter) program certainly never should be. So you achieve a strict
separation between the setuid-root program (see point 4.) and an API,
that provides all this information to every user (see point 5). That
library (what about libtop as name ;-) is then portable (Of course there
has to be someone to write an implementaion for every system) and
flexible (You can write thousend different top-programs without asking
your sysop to compile it everytime.) and it is more secure than a
setuid-root-gtop hack on systems like solaris.

On top of this libtop you could then easily make a truly
system-independent gtop.

Just my thoughts. 
I haven't got far in designing such an interface, but I would like to
discuss this idea (if not here, via pm)

Bye
Sebastian.

BTW: CC to the author of gtop.

-- 
+--------------============##################============--------------+
| Sebastian Wilhelmi, Institut fuer Rechnerentwurf und Fehlertoleranz, |
| Universitaet Karlsruhe;  Gebaeude 20.20, Raum 263, D-76128 Karlsruhe |
| mail: wilhelmi@ira.uka.de; fax: +49 721 370455; fon: +49 721 6084353 |
+----------------> http://goethe.ira.uka.de/~wilhelmi <----------------+



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]