Problem
I am trying to look at streams usage on my OpenServer6 machine and am running the netstat -m command. My machine reports that -m is an illegal option. How can one track streams usage on an OpenServer6 machine?
Solution
A method to track streams usage on an OpenServer6 machine is to use the "strstat" command of the crash(ADM) utility:
# echo strstat | crashThis command provides output that looks like the following
and is similar to the output provided by OpenServer5
netstat -m command.root@testbox:/> echo strstat | crash
dumpfile = /dev/mem, namelist = /stand/unix, outfile =
stdout
Engine: 0 of 2 Procslot: 66 Lwpslot: 0 crash
> ITEM INUSE TOTAL FAIL
streams 178 39943 0
queues 858 101740 0
message blocks 0 47237 0
message triplets 215 1052205 0
link blocks 25 29 0
stream events 0 0 0
>
root@testbox:/>Additionally, if you would like to see the current streams usage in bytes, then you can use the command:
# echo "od -d Strcount" | crashroot@testbox:/> echo "od -d Strcount" | crash
dumpfile = /dev/mem, namelist = /stand/unix, outfile = stdout
Engine: 0 of 2 Procslot: 6 Lwpslot: 0 crash
> c04d522c: 0000168292
>
root@testbox:/>Here the byte count is 168292 bytes, or 164.35KB. This would match
the "streams memory in use:" provided by OpenServer5's `netstat -m`
command.