| Summary: | [PATCH] show service names in netstat and sockstat | ||||||
|---|---|---|---|---|---|---|---|
| Product: | Base System | Reporter: | Peter Pentchev <roam> | ||||
| Component: | bin | Assignee: | Dag-Erling Smørgrav <des> | ||||
| Status: | Closed FIXED | ||||||
| Severity: | Affects Only Me | ||||||
| Priority: | Normal | ||||||
| Version: | 4.1-STABLE | ||||||
| Hardware: | Any | ||||||
| OS: | Any | ||||||
| Attachments: |
|
||||||
|
Description
Peter Pentchev
2000-08-17 13:40:01 UTC
Responsible Changed From-To: freebsd-bugs->des Personally, I wouldn't add these options, but DES maintains one of these utilities, and whatever decision he makes for sockstat probably makes sense for netstat. Is this patch ok?
/assar
Index: sockstat.pl
===================================================================
RCS file: /home/ncvs/src/usr.bin/sockstat/sockstat.pl,v
retrieving revision 1.11
diff -u -w -u -w -r1.11 sockstat.pl
--- sockstat.pl 2000/10/13 16:25:37 1.11
+++ sockstat.pl 2001/06/15 23:58:36
@@ -53,7 +53,7 @@
if (!defined($pid = open(PIPE, "-|"))) {
die("open(netstat): $!\n");
} elsif ($pid == 0) {
- exec("/usr/bin/netstat", "-Aan");
+ exec("/usr/bin/netstat", "-AaS");
die("exec(netstat): $!\n");
}
while ($line = <PIPE>) {
Assar Westerlund <assar@freebsd.org> writes: > Is this patch ok? No. Sockstat purposedly does not resolve host or port names. Hiding a port number behind the first few letters of a name which more often than not bears no relation to the traffic actually passing through the port is simply idiotic. DES -- Dag-Erling Smorgrav - des@ofug.org On Sat, Jun 16, 2001 at 02:26:36AM +0200, Dag-Erling Smorgrav wrote:
> Assar Westerlund <assar@freebsd.org> writes:
> > Is this patch ok?
>
> No. Sockstat purposedly does not resolve host or port names. Hiding
> a port number behind the first few letters of a name which more often
> than not bears no relation to the traffic actually passing through the
> port is simply idiotic.
Actually, yes, this is true for high ports..
G'luck,
Peter
--
If you think this sentence is confusing, then change one pig.
Dag-Erling Smorgrav <des@ofug.org> writes: > Assar Westerlund <assar@freebsd.org> writes: > > Is this patch ok? > > No. Sockstat purposedly does not resolve host or port names. Hiding > a port number behind the first few letters of a name which more often > than not bears no relation to the traffic actually passing through the > port is simply idiotic. Ok, I will close the PR noting that the netstat option has appeared and that sockstat will not be changed. /assar State Changed From-To: open->closed the netstat option -S has been added sockstat will not be changed |