pcblookup

How can I check the status of a TCP/IP connection? That is, given a
pair of address and ports, how can I check to see if the connection is
still active. In a filter I could call in_pcblookup_connect; how do I
do the same sort of thing if I’m not in a filter? Equivalently, how
does SNMP get at the information (or does SNMP live inside io-net?).

Murf

This currently isn’t a documented way to do this; however
I’ll point out that our ‘netstat’ utility (which closely
follows NetSD’s) uses the kvm_* functions to walk the stack’s
lists. The source to our kvm_*() can currently be found under
cvs.qnx.com.

-seanb

John A. Murphy <murf@perftech.com> wrote:
: How can I check the status of a TCP/IP connection? That is, given a
: pair of address and ports, how can I check to see if the connection is
: still active. In a filter I could call in_pcblookup_connect; how do I
: do the same sort of thing if I’m not in a filter? Equivalently, how
: does SNMP get at the information (or does SNMP live inside io-net?).

: Murf

I’ve used the kvm_* functions for the same purpose in FreeBSD, and I’d found
kvm.c at cvs.qnx.com, but it’s use is non obvious. I don’t suppose the
source to ‘netsat’ is available…

Murf

Sean Boudreau wrote:

This currently isn’t a documented way to do this; however
I’ll point out that our ‘netstat’ utility (which closely
follows NetSD’s) uses the kvm_* functions to walk the stack’s
lists. The source to our kvm_*() can currently be found under
cvs.qnx.com.

-seanb

John A. Murphy <> murf@perftech.com> > wrote:
: How can I check the status of a TCP/IP connection? That is, given a
: pair of address and ports, how can I check to see if the connection is
: still active. In a filter I could call in_pcblookup_connect; how do I
: do the same sort of thing if I’m not in a filter? Equivalently, how
: does SNMP get at the information (or does SNMP live inside io-net?).

: Murf

‘netstat’ isn’t generally available. You’d have to contact your sales
rep.

-seanb

John A. Murphy <murf@perftech.com> wrote:
: I’ve used the kvm_* functions for the same purpose in FreeBSD, and I’d found
: kvm.c at cvs.qnx.com, but it’s use is non obvious. I don’t suppose the
: source to ‘netsat’ is available…

: Murf

: Sean Boudreau wrote:

:> This currently isn’t a documented way to do this; however
:> I’ll point out that our ‘netstat’ utility (which closely
:> follows NetSD’s) uses the kvm_* functions to walk the stack’s
:> lists. The source to our kvm_*() can currently be found under
:> cvs.qnx.com.
:>
:> -seanb
:>
:> John A. Murphy <murf@perftech.com> wrote:
:> : How can I check the status of a TCP/IP connection? That is, given a
:> : pair of address and ports, how can I check to see if the connection is
:> : still active. In a filter I could call in_pcblookup_connect; how do I
:> : do the same sort of thing if I’m not in a filter? Equivalently, how
:> : does SNMP get at the information (or does SNMP live inside io-net?).
:>
:> : Murf

I took another look, and it’s more obvious than I thought:). Thanks for the
pointer!

Murf

Sean Boudreau wrote:

‘netstat’ isn’t generally available. You’d have to contact your sales
rep.

-seanb

John A. Murphy <> murf@perftech.com> > wrote:
: I’ve used the kvm_* functions for the same purpose in FreeBSD, and I’d found
: kvm.c at cvs.qnx.com, but it’s use is non obvious. I don’t suppose the
: source to ‘netsat’ is available…

: Murf

: Sean Boudreau wrote:

:> This currently isn’t a documented way to do this; however
:> I’ll point out that our ‘netstat’ utility (which closely
:> follows NetSD’s) uses the kvm_* functions to walk the stack’s
:> lists. The source to our kvm_*() can currently be found under
:> cvs.qnx.com.
:
:> -seanb
:
:> John A. Murphy <> murf@perftech.com> > wrote:
:> : How can I check the status of a TCP/IP connection? That is, given a
:> : pair of address and ports, how can I check to see if the connection is
:> : still active. In a filter I could call in_pcblookup_connect; how do I
:> : do the same sort of thing if I’m not in a filter? Equivalently, how
:> : does SNMP get at the information (or does SNMP live inside io-net?).
:
:> : Murf

Can you please tell where you found kvm.c?

Thanks in advance,
-Farooque

“John A. Murphy” <murf@perftech.com> wrote in message
news:3CD93DE3.7B211702@perftech.com

I’ve used the kvm_* functions for the same purpose in FreeBSD, and I’d
found
kvm.c at cvs.qnx.com, but it’s use is non obvious. I don’t suppose the
source to ‘netsat’ is available…

Murf

Sean Boudreau wrote:

This currently isn’t a documented way to do this; however
I’ll point out that our ‘netstat’ utility (which closely
follows NetSD’s) uses the kvm_* functions to walk the stack’s
lists. The source to our kvm_*() can currently be found under
cvs.qnx.com.

-seanb

John A. Murphy <> murf@perftech.com> > wrote:
: How can I check the status of a TCP/IP connection? That is, given a
: pair of address and ports, how can I check to see if the connection is
: still active. In a filter I could call in_pcblookup_connect; how do I
: do the same sort of thing if I’m not in a filter? Equivalently, how
: does SNMP get at the information (or does SNMP live inside io-net?).

: Murf

It’s under http://cvs.qnx.com/ under lib/socket/nto/kvm.c

-seanb

Farooque Khan <farooquek@concretioindia.com> wrote:
: Can you please tell where you found kvm.c?

: Thanks in advance,
: -Farooque

Thanks, I got it.

But how can I use kvm_* functions to get the ICMP statistics?

Thanks again, you have been a great help.

-Farooque

“Sean Boudreau” <seanb@qnx.com> wrote in message
news:aclbp1$8cq$1@nntp.qnx.com

It’s under > http://cvs.qnx.com/ > under lib/socket/nto/kvm.c

-seanb

Farooque Khan <> farooquek@concretioindia.com> > wrote:
: Can you please tell where you found kvm.c?

: Thanks in advance,
: -Farooque

If you don’t find this is enough information, you’ll have
to look into getting the source to netstat.

-seanb

Farooque Khan <farooquek@concretioindia.com> wrote:
: Thanks, I got it.

: But how can I use kvm_* functions to get the ICMP statistics?

: Thanks again, you have been a great help.

: -Farooque

: “Sean Boudreau” <seanb@qnx.com> wrote in message
: news:aclbp1$8cq$1@nntp.qnx.com
:>
:> It’s under http://cvs.qnx.com/ under lib/socket/nto/kvm.c
:>
:> -seanb
:>
:> Farooque Khan <farooquek@concretioindia.com> wrote:
:> : Can you please tell where you found kvm.c?
:>
:> : Thanks in advance,
:> : -Farooque

Thanks again.

How (or where) can I get the source to netstat?

-Farooque

“Sean Boudreau” <seanb@qnx.com> wrote in message
news:actbb8$41m$1@nntp.qnx.com

If you don’t find this is enough information, you’ll have
to look into getting the source to netstat.

-seanb

Farooque Khan <> farooquek@concretioindia.com> > wrote:
: Thanks, I got it.

: But how can I use kvm_* functions to get the ICMP statistics?

: Thanks again, you have been a great help.

: -Farooque

: “Sean Boudreau” <> seanb@qnx.com> > wrote in message
: news:aclbp1$8cq$> 1@nntp.qnx.com> …
:
:> It’s under > http://cvs.qnx.com/ > under lib/socket/nto/kvm.c
:
:> -seanb
:
:> Farooque Khan <> farooquek@concretioindia.com> > wrote:
:> : Can you please tell where you found kvm.c?
:
:> : Thanks in advance,
:> : -Farooque

See response number 3 in this thread.

-seanb

Farooque Khan <farooquek@concretioindia.com> wrote:
: Thanks again.

: How (or where) can I get the source to netstat?

: -Farooque

Hello John!
Iam aslo porting one application on to QNX platform.
My Application is supposed to retrieve ICMP statistics from kernel,which
raises a need to use the kvm*( ) functions.But unfortunately these are not
bringing proper results for my application.
Can u please tell ,in what sequence u called these functions in ur
application and exactly with what arguments u got the result.
Iam very thankful to u for extending any kind of help.
waiting for ur reply

warm regards
Nitin

“John A. Murphy” <murf@perftech.com> wrote in message
news:3CD95D51.A2FD0364@perftech.com

I took another look, and it’s more obvious than I thought:). Thanks for
the
pointer!

Murf

Sean Boudreau wrote:

‘netstat’ isn’t generally available. You’d have to contact your sales
rep.

-seanb

John A. Murphy <> murf@perftech.com> > wrote:
: I’ve used the kvm_* functions for the same purpose in FreeBSD, and I’d
found
: kvm.c at cvs.qnx.com, but it’s use is non obvious. I don’t suppose
the
: source to ‘netsat’ is available…

: Murf

: Sean Boudreau wrote:

:> This currently isn’t a documented way to do this; however
:> I’ll point out that our ‘netstat’ utility (which closely
:> follows NetSD’s) uses the kvm_* functions to walk the stack’s
:> lists. The source to our kvm_*() can currently be found under
:> cvs.qnx.com.
:
:> -seanb
:
:> John A. Murphy <> murf@perftech.com> > wrote:
:> : How can I check the status of a TCP/IP connection? That is, given
a
:> : pair of address and ports, how can I check to see if the connection
is
:> : still active. In a filter I could call in_pcblookup_connect; how
do I
:> : do the same sort of thing if I’m not in a filter? Equivalently,
how
:> : does SNMP get at the information (or does SNMP live inside
io-net?).
:
:> : Murf

I haven’t tried to read the ICMP stats, but I’ll email you a little test program
that reads the TCP stats.

Murf

Nitin wrote:

Hello John!
Iam aslo porting one application on to QNX platform.
My Application is supposed to retrieve ICMP statistics from kernel,which
raises a need to use the kvm*( ) functions.But unfortunately these are not
bringing proper results for my application.
Can u please tell ,in what sequence u called these functions in ur
application and exactly with what arguments u got the result.
Iam very thankful to u for extending any kind of help.
waiting for ur reply

warm regards
Nitin

“John A. Murphy” <> murf@perftech.com> > wrote in message
news:> 3CD95D51.A2FD0364@perftech.com> …
I took another look, and it’s more obvious than I thought:). Thanks for
the
pointer!

Murf

Sean Boudreau wrote:

‘netstat’ isn’t generally available. You’d have to contact your sales
rep.

-seanb

John A. Murphy <> murf@perftech.com> > wrote:
: I’ve used the kvm_* functions for the same purpose in FreeBSD, and I’d
found
: kvm.c at cvs.qnx.com, but it’s use is non obvious. I don’t suppose
the
: source to ‘netsat’ is available…

: Murf

: Sean Boudreau wrote:

:> This currently isn’t a documented way to do this; however
:> I’ll point out that our ‘netstat’ utility (which closely
:> follows NetSD’s) uses the kvm_* functions to walk the stack’s
:> lists. The source to our kvm_*() can currently be found under
:> cvs.qnx.com.
:
:> -seanb
:
:> John A. Murphy <> murf@perftech.com> > wrote:
:> : How can I check the status of a TCP/IP connection? That is, given
a
:> : pair of address and ports, how can I check to see if the connection
is
:> : still active. In a filter I could call in_pcblookup_connect; how
do I
:> : do the same sort of thing if I’m not in a filter? Equivalently,
how
:> : does SNMP get at the information (or does SNMP live inside
io-net?).
:
:> : Murf