package mem

Import Path
	github.com/shirou/gopsutil/v3/mem (on go.dev)

Dependency Relation
	imports 11 packages, and imported by one package

Involved Source Files mem.go mem_linux.go
Package-Level Type Names (total 4)
/* sort by: | */
FreeBytes uint64 Name string UsedBytes uint64 ( SwapDevice) String() string SwapDevice : expvar.Var SwapDevice : fmt.Stringer func SwapDevices() ([]*SwapDevice, error) func SwapDevicesWithContext(ctx context.Context) ([]*SwapDevice, error)
Free uint64 PgFault uint64 PgIn uint64 Linux specific numbers https://www.kernel.org/doc/Documentation/cgroup-v2.txt PgOut uint64 Sin uint64 Sout uint64 Total uint64 Used uint64 UsedPercent float64 ( SwapMemoryStat) String() string SwapMemoryStat : expvar.Var SwapMemoryStat : fmt.Stringer func SwapMemory() (*SwapMemoryStat, error) func SwapMemoryWithContext(ctx context.Context) (*SwapMemoryStat, error)
ActiveAnon uint64 ActiveFile uint64 InactiveAnon uint64 InactiveFile uint64 Unevictable uint64 ( VirtualMemoryExStat) String() string VirtualMemoryExStat : expvar.Var VirtualMemoryExStat : fmt.Stringer func VirtualMemoryEx() (*VirtualMemoryExStat, error) func VirtualMemoryExWithContext(ctx context.Context) (*VirtualMemoryExStat, error)
Memory usage statistics. Total, Available and Used contain numbers of bytes for human consumption. The other fields in this struct contain kernel specific values. OS X / BSD specific numbers: http://www.macyourself.com/2010/02/17/what-is-free-wired-active-and-inactive-system-memory-ram/ AnonHugePages uint64 RAM available for programs to allocate This value is computed from the kernel specific values. Linux specific numbers https://www.centos.org/docs/5/html/5.1/Deployment_Guide/s2-proc-meminfo.html https://www.kernel.org/doc/Documentation/filesystems/proc.txt https://www.kernel.org/doc/Documentation/vm/overcommit-accounting https://www.kernel.org/doc/Documentation/vm/transhuge.txt Cached uint64 CommitLimit uint64 CommittedAS uint64 Dirty uint64 This is the kernel's notion of free memory; RAM chips whose bits nobody cares about the value of right now. For a human consumable number, Available is what you really want. HighFree uint64 HighTotal uint64 HugePageSize uint64 HugePagesFree uint64 HugePagesRsvd uint64 HugePagesSurp uint64 HugePagesTotal uint64 Inactive uint64 FreeBSD specific numbers: https://reviews.freebsd.org/D8467 LowFree uint64 LowTotal uint64 Mapped uint64 PageTables uint64 Shared uint64 Slab uint64 Sreclaimable uint64 Sunreclaim uint64 SwapCached uint64 SwapFree uint64 SwapTotal uint64 Total amount of RAM on this system RAM used by programs This value is computed from the kernel specific values. Percentage of RAM used by programs This value is computed from the kernel specific values. VmallocChunk uint64 VmallocTotal uint64 VmallocUsed uint64 Wired uint64 WriteBack uint64 WriteBackTmp uint64 ( VirtualMemoryStat) String() string VirtualMemoryStat : expvar.Var VirtualMemoryStat : fmt.Stringer func VirtualMemory() (*VirtualMemoryStat, error) func VirtualMemoryWithContext(ctx context.Context) (*VirtualMemoryStat, error)