summaryrefslogtreecommitdiff
path: root/usr.bin/systat
AgeCommit message (Collapse)Author
2015-04-18Convert many atoi() calls to strtonum(), adding range checks and failureTheo de Raadt
handling along the way. Reviews by Brendan MacDonell, Jeremy Devenport, florian, doug, millert
2015-04-18Avoid calling freeifaddrs() with an uninitialised pointer in anJonathan Gray
error path.
2015-03-12Switch the netstat view of systat to use the same kvm_getfiles()Claudio Jeker
function similar to netstat(1). The output still shows the same info but may be a bit differently sorted. Also it will now show connections that are not UDP or TCP. This was the last bit of systat that needed kvm access and so now systat no longer needs to be setgid kmem. With this commit OpenBSD is officially setgid kmem free and an almost 10 year journey finally comes to an end. OK deraadt@
2015-02-28Reduce usage of predefined strings in manpages.Anthony J. Bentley
Predefined strings are not very portable across troff implementations, and they make the source much harder to read. Usually the intended character can be written directly. No output changes, except for two instances where the incorrect escape was used in the first place. tweaks + ok schwarze@
2015-02-09Correct a test so synproxy states will display as "Syn" instead ofJonathan Gray
modulate states displaying as "Syn". ok henning@
2015-01-20Adjust <sys/param.h> comments regarding use of use of MSIZE, orTheo de Raadt
delete <sys/param.h> if now possible ok guenther
2015-01-19replace local MIN() with MINIMUM()Theo de Raadt
2015-01-16first batch of programs adapting to the namespace cleanupTheo de Raadt
(pfvar.h nameser.h proc.h ucred.h) ok guenther millert, and some review from doug as well.
2014-11-23<sys/buf.h> isn't actually needed herePhilip Guenther
ok tedu@
2014-11-06i renamed the mbuf pool.David Gwynne
2014-10-24This tool doesn't actually support networks(5).Ingo Schwarze
So remove the call to setnetent(3) which is a no-op here (except for consuming a file descriptor) and the call sethostent(3) which is a no-op in general. Also remove the misleading reference to networks(5) from the manual. OK okan@ henning@
2014-10-20fix if (statement);Jonathan Gray
ok dlg@
2014-10-11Userland reallocarray() audit.Doug Hogan
Avoid potential integer overflow in the size argument of malloc() and realloc() by using reallocarray() to avoid unchecked multiplication. ok deraadt@
2014-10-08userland reallocarray audit.Doug Hogan
Replace malloc() and realloc() calls that may have integer overflow in the multiplication of the size argument with reallocarray(). ok deraadt@
2014-09-15Remove non-standard <sys/dkstat.h> header. It has not contained anythingMiod Vallat
related to disk stastics for almost 17 years, and the remaining userland-visible defines duplicate those found in <sys/sched.h>. Move the remaining _KERNEL defines to <sys/tty.h> where they belong, and update all users to cope with this. ok kettenis@
2014-08-14No need for <netinet/in_systm.h> nor <netinet/tcpip.h>.Martin Pieuchot
2014-08-14Show only active pools by default, pressing 'A' shows all of them.Martin Pieuchot
ok deraadt@
2014-07-16zap trailing newlines; "go for it" deraadtOkan Demirmen
2014-07-10repair prototypesTheo de Raadt
2014-07-09instead of printf() use tbprintf() like elsewhere in systat.Jasper Lievisse Adriaanse
ok deraadt@ mpi@
2014-07-08cut things that relied on mclgeti for rx ring accounting/restriction overDavid Gwynne
to using if_rxr. cut the reporting systat did over to the rxr ioctl. tested as much as i can on alpha, amd64, and sparc64. mpi@ has run it on macppc. ok mpi@
2014-07-02info about pools is currently given to userland by copying eachDavid Gwynne
pools struct out. however, struct pool in the kernel contains lots of things that userland probably isnt interested in, like actual mutexes, and probably shouldnt get easy access to, like pointers to kernel memory via all the lists/trees. this implements a kinfo_pool structure that has only the data that userland needs to know about. it cuts the sysctl code over to building it from struct pool as required and copying that out instead, and cuts userland over to only handling kinfo_pool. the only problem with this is vmstat, which can read kernel images via kvm, which needs some understanding of struct pool. to cope, the struct pool definition is guarded by if defined(_KERNEL) || defined(_LIBKVM) as inspired by sysctl which needs to do the same thing sometimes. struct pool itself is generally not visible to userland though, which is good. matthew@ suggested struct kinfo_pool instead of struct pool_info. the kinfo prefix has precedent. lots of people liked this.
2014-06-23The second level of the CTL_NET sysctl is a PF_*, not an AF_*Philip Guenther
inconsistent usage in route(8) noted by Gregor Best (gbe (at) ring0.de)
2014-06-13Now that the water marks are updated on a per-pool basis indicate inMartin Pieuchot
the LIVELOCKS column if there is a pending (deferred) update. ok claudio@
2014-05-09print interface name with queues in "systat q"; ok henningStuart Henderson
2014-05-03remove unused variablesCharles Longeau
ok henning@
2014-04-26fix whitespaceStuart Henderson
2014-04-26Only remove queues from the TAILQ when the ticket changes; fixes PPS/BPSStuart Henderson
displays for queues in "systat q". From Arto Jonsson.
2014-04-18no more altqHenning Brauer
2014-04-08Use VM_UVMEXP instead of VM_METER for memory usages and directlyMartin Pieuchot
include <sys/vmmeter.h> where it is needed instead of relying on it being included by <uvm/uvm_extern.h>. miod@ likes it, ok guenther@
2014-02-11Stop leaking megabytes of memory at every queue refresh.pelikan
ok krw
2014-01-19newqueue support for the queue view, code mostly from pfctl. lifting doneHenning Brauer
by Arto Jonsson <ajonsson at kapsi dot fi>, many thanks!
2013-12-25final circleq to tailq fix. restore the previous pointer check by readingTed Unangst
the previous value again and checking prev.next is still next. maybe ok guenther
2013-12-24more fixing after circleq conversion. a better fix to check the prevTed Unangst
pointer is forthcoming.
2013-12-20Switch inpt_queue from CIRCLEQ to TAILQ. Thus ending use of CIRCLEQKenneth R Westerback
in the base. Ports fixes to follow shortly for the two ports (gkrellm and net-snmp) affected. ok zhuk@ millert@
2013-12-02views CIRCLEQ begone.Kenneth R Westerback
ok miller@
2013-11-26unsigned char casts for ctypeTheo de Raadt
ok okan
2013-11-01not just altq queues, queuesHenning Brauer
From: Arto Jonsson <ajonsson at kapsi.fi>
2013-10-31sometimes we find .h we no longer needTheo de Raadt
2013-10-12adopt to queueing changesHenning Brauer
2013-09-11Correctly NUL-terminate the cpu view array. Fix a segfault on powerpcMartin Pieuchot
and probably others. ok reyk@
2013-09-07Add a new screen "cpu" that simply lists the usage of each CPU core.Reyk Floeter
Also add a new -B command line flag that works like -b but waits some cycles before dumping anything to the console. With much help from jmc@ OK jj@ lambert@ jmc@
2013-07-09back out the cache flipper temporarily to work out of tree.Bob Beck
will come back soon. ok deraadt@
2013-06-11High memory page flipping for the buffer cache.Bob Beck
This change splits the buffer cache free lists into lists of dma reachable buffers and high memory buffers based on the ranges returned by pmemrange. Buffers move from dma to high memory as they age, but are flipped to dma reachable memory if IO is needed to/from and high mem buffer. The total amount of buffers allocated is now bufcachepercent of both the dma and the high memory region. This change allows the use of large buffer caches on amd64 using more than 4 GB of memory ok tedu@ krw@ - testing by many.
2013-06-02<sys/dir.h> isn't needed herePhilip Guenther
2013-05-14Don't display swapin/swapout uvmexp fieldsMiod Vallat
2013-03-20Do not expose a kernel address.Theo de Raadt
2012-12-23%zfod was removed in -r1.24; from NaughtyJason McIntyre
2012-12-05Remove excessive sys/cdefs.h inclusionTheo de Raadt
ok guenther millert kettenis
2012-12-04remove some unnecessary sys/param.h inclusionsTheo de Raadt