VictoriaMetrics/lib/fs/fs_nix.go
Nikolay Khramchikhin cc90a548b1
added openbsd implementations (#790)
https://github.com/VictoriaMetrics/VictoriaMetrics/issues/785

removed fadvise for openbsd, added freespace implemenation for openbsd
2020-09-29 00:29:04 +03:00

9 lines
172 B
Go

// +build linux darwin freebsd
package fs
import "golang.org/x/sys/unix"
func freeSpace(stat unix.Statfs_t) uint64 {
return uint64(stat.Bavail) * uint64(stat.Bsize)
}