This is the mail archive of the
systemtap@sourceware.org
mailing list for the systemtap project.
problem when run tcp/udp probing script
- From: ch huang <justlooks at gmail dot com>
- To: systemtap at sourceware dot org
- Date: Mon, 19 Mar 2012 13:25:06 +0800
- Subject: problem when run tcp/udp probing script
i write the following script ( from book 'Instrumenting the Linux
Kernel for Analyzing Performance and Functional Problems )
probe udp.recvmsg {
printf("%s: UDP: Receiving message. Socket %d. Size %d\n", execname(),
sock, size)
}
probe tcp.recvmsg {
printf("%s: TCP: Receiving message. Socket %d. Size %d\n", execname(),
sock, size)
}
probe udp.sendmsg {
printf("%s: UDP: Sending message. Flags %d. Size %d\n", execname(),
$sk->sk_flags, size)
}
probe tcp.sendmsg {
printf("%s: TCP: Sending message. Flags %d. Size %d\n", execname(),
$sk->sk_flags, size)
}
probe udp.disconnect {
printf("%s: UDP: Disconnected %d with flags %d\n", execname(), sock,
flags)
}
probe tcp.disconnect {
printf("%s: TCP: Disconnected %d with flags %d\n", execname(), sock,
flags)
}
but why the value of socket is negative?
mysqld: TCP: Receiving message. Socket -131937697852800. Size 4
mysqld: TCP: Receiving message. Socket -131937398508736. Size 16384
mysqld: TCP: Receiving message. Socket -131938374336384. Size 1
mysqld: TCP: Receiving message. Socket -131937398508736. Size 16384