Get System Information

View: New views
3 Messages — Rating Filter:   Alert me  

Get System Information

by ateista :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

How can I get system information like Free/Total RAM memory, Disks sizes, etc?
In windows I can use WMI, but there is a way to do it with MONO running on linux?

If not, maybe I can get this info by executing a "FREE" and "DF" (executing those on command line gives the free memory and disks sizes)... but then how can I get the result from a command line application on my MONO app?

Thanks, and sorry for my bad english :/


Re: Get System Information

by mitcheloc :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

I'm interested in any responses to this as well.

Ateista, If you execute a system command you can redirect the console
input. Google "Console Redirection C#" and you should find an example
on it.

On 6/9/07, ateista <ateista@...> wrote:

>
> How can I get system information like Free/Total RAM memory, Disks sizes,
> etc?
> In windows I can use WMI, but there is a way to do it with MONO running on
> linux?
>
> If not, maybe I can get this info by executing a "FREE" and "DF" (executing
> those on command line gives the free memory and disks sizes)... but then how
> can I get the result from a command line application on my MONO app?
>
> Thanks, and sorry for my bad english :/
>
>
> --
> View this message in context: http://www.nabble.com/Get-System-Information-tf3896512.html#a11046269
> Sent from the Mono - General mailing list archive at Nabble.com.
>
> _______________________________________________
> Mono-list maillist  -  Mono-list@...
> http://lists.ximian.com/mailman/listinfo/mono-list
>


--
________________
Mitchel Constantin
Snap - A desktop user interface for Asterisk
www.snapanumber.com
_______________________________________________
Mono-list maillist  -  Mono-list@...
http://lists.ximian.com/mailman/listinfo/mono-list

Re: Get System Information

by evilpete :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Hi

on linux you can read the /proc and /sys 'files'. Like:

$ cat /sys/block/hda/size
488397168

I don't know what this is, blocks or bytes, but you can read all kinds
of info from the kernel

greetz

Peter

ateista wrote:

> How can I get system information like Free/Total RAM memory, Disks sizes,
> etc?
> In windows I can use WMI, but there is a way to do it with MONO running on
> linux?
>
> If not, maybe I can get this info by executing a "FREE" and "DF" (executing
> those on command line gives the free memory and disks sizes)... but then how
> can I get the result from a command line application on my MONO app?
>
> Thanks, and sorry for my bad english :/
>
>
_______________________________________________
Mono-list maillist  -  Mono-list@...
http://lists.ximian.com/mailman/listinfo/mono-list