system information of solaris

system information of solaris

Post by arko3.. » Tue, 11 Jan 2000 04:00:00



hi all:

Anyone do me a favor?

Is there any system call to read the following system information:
1) swap size
2) file system type/file system size/file system use rate
3) device name such as "Ultra 5"

I want to use system call,not command line utility.

Thanks a lot!

Sent via Deja.com http://www.deja.com/
Before you buy.

 
 
 

system information of solaris

Post by KJRic » Tue, 11 Jan 2000 04:00:00


Do your own school work and you might learn something!

> hi all:

> Anyone do me a favor?

> Is there any system call to read the following system information:
> 1) swap size
> 2) file system type/file system size/file system use rate
> 3) device name such as "Ultra 5"

> I want to use system call,not command line utility.

> Thanks a lot!

> Sent via Deja.com http://www.deja.com/
> Before you buy.


 
 
 

system information of solaris

Post by Richard L. Hamilt » Wed, 12 Jan 2000 04:00:00


That's a little cold.  Give the guy a bit of a hint, as in
run "truss" on a command that reports one or more of what you
want.  (You'll have to be root if the command is setuid; if you don't
have root, you don't have any business trying to write stuff to do
these things anyway.)  Swap is easy, see swapctl(2).  File system
type and size can be obtained with statvfs(2) (which df(1) uses),
but statvfs does _not_ provide utilization or performance info
(hint: truss iostat;man kstat).  Hardware type name is really easy,
so I won't quite tell you the system call (hint: truss uname).

If it's literally homework, I left the slacker a tiny bit yet to do,
esp. on the filesystem utilization info.  :-)  If it's not, and this
is just a case of clueless trying to get a clue, well that _is_ one
of the reasons people come here...



> Do your own school work and you might learn something!


>> hi all:

>> Anyone do me a favor?

>> Is there any system call to read the following system information:
>> 1) swap size
>> 2) file system type/file system size/file system use rate
>> 3) device name such as "Ultra 5"

>> I want to use system call,not command line utility.

>> Thanks a lot!

>> Sent via Deja.com http://www.deja.com/
>> Before you buy.

--
ftp> get |fortune
377 I/O error: smart remark generator failed

Bogonics: the primary language inside the Beltway


 
 
 

system information of solaris

Post by arko3.. » Thu, 13 Jan 2000 04:00:00


Why your guys look down on newbie ?
However i still thanks to your help...

Sent via Deja.com http://www.deja.com/
Before you buy.

 
 
 

system information of solaris

Post by tony_barr.. » Thu, 13 Jan 2000 04:00:00


Not me. If you look on www.backupcentral.com, you will find details of
SysAudit. Which is a shell script which creates a report which contains
the info u seek (and more).

HTH


> Why your guys look down on newbie ?
> However i still thanks to your help...

> Sent via Deja.com http://www.deja.com/
> Before you buy.

Sent via Deja.com http://www.deja.com/
Before you buy.