1
0
mirror of https://github.com/shirou/gopsutil.git synced 2025-04-26 13:48:59 +08:00

16 Commits

Author SHA1 Message Date
mmorel-35
1e6b445a8a gofumpt 2021-12-22 21:54:41 +00:00
shirou
0969c9436b delete v2 directory, move v3 to top #1078 2021-11-30 23:47:59 +00:00
shirou
1f733a99dc [disk] move without context functions to disk.go. 2020-10-24 22:03:58 +09:00
shirou
fb1c75054a [disk] Partition returns all list even if argument is False.
According to https://github.com/giampaolo/psutil/issues/906,
all BSD system returns same information `df` and `df -a`.
2020-10-20 18:13:12 +09:00
Tobias Klauser
7f9e55b000 Use Getfsstat from golang.org/x/sys/unix on OpenBSD
Use the syscall wrapper and types from golang.org/x/sys/unix instead of
implementing them locally.

Also remove unused generated types and consts.

Follow-up for #810 and #812
2020-01-08 10:42:16 +01:00
Tobias Klauser
4d6c82fb03 Add missing OpenBSD mount option strings
Add missing mount option string decoding according to the OpenBSD
mount(8) manpage: https://man.openbsd.org/mount
2019-12-23 13:44:02 +01:00
Tobias Klauser
214c5bdb50 Use MNT_* consts from golang.org/x/sys/unix on freebsd and openbsd
Update vendored version of golang.org/x/sys/unix and use the MNT_*
constants there to replace the locally generated ones.
2019-12-23 13:31:05 +01:00
Simon Frei
fb73f7095e Revert "[disk][openbsd] Use fallback for openBSD not on amd64"
This reverts commit 3aa75af2ac502b28e078f653497a24d3809c63d4.
2019-07-16 12:25:53 +02:00
Simon Frei
3aa75af2ac [disk][openbsd] Use fallback for openBSD not on amd64 2019-07-13 00:54:37 +02:00
Michal Rostecki
ff2e736f72 disk: Check for error objects returned by Getfsstat 2018-06-21 16:48:16 +02:00
shirou
4c73494c78 Add WithContext functions. 2017-12-31 15:25:49 +09:00
Marco Pfatschbacher
d62768abc9 Fix IOCounters for OpenBSD
Use SysctlRaw instead of Sysctl.
The latter assumes NUL terminated strings
which returns the lenght off by one.
Therefore, only n-1 disks where reported.
2017-11-08 20:52:36 +01:00
Sean Chittenden
635b971c0e
Move from the syscall package to the golang.org/x/sys/{unix,windows} 2017-06-02 13:51:00 -07:00
Daniel Nelson
3830ed16b4
Make IOCounters a variadic function
Remove IOCountersForNames that was recently added in favor of variadic
function with same capabilities.
2017-04-13 18:53:09 -07:00
Daniel Nelson
3f35f001da
Add disk.IOCountersForNames function
Operates like disk.IOCounters, but accepts an array of names to limit
the results.
2017-04-06 18:00:54 -07:00
Marco Pfatschbacher
b4846b445b Add support for OpenBSD/amd64
This code is based on the FreeBSD version
and implements roughly the same feature set.
2016-11-24 22:30:29 +01:00