Documentation ¶
Overview ¶
Package sysmonitor monitor system status
Index ¶
- Constants
- func AllProcess() (map[int][2]string, error)
- func FindMemberOffsetFromFile(fp string, typeName, memberName string) (int64, error)
- func FindStructMemberOffset(data *dwarf.Data, typeName, memberName string) (int64, error)
- func FindSymbol(path string, re *regexp.Regexp) ([]elf.Symbol, error)
- func GetEnv(key string, dfault string, combineWith ...string) string
- func HostProc(combineWith ...string) string
- func NewRegisterFunc(m *manager.Manager, bpfFuncName []string) registerFunc
- func NewSchedManger(handler perfHandler) (*manager.Manager, error)
- func NewUnRegisterFunc(m *manager.Manager, bpfFuncName []string) unregisterFunc
- func SetLogger(nl *logger.Logger)
- func ShortID(binPath string) string
- type ProcInjectC
- type ProcessAttachInfo
- func (procAttach *ProcessAttachInfo) AddAtach(name string, tn time.Time)
- func (procAttach *ProcessAttachInfo) AddCannotAttach(name string, tn time.Time)
- func (procAttach *ProcessAttachInfo) GetAttachInfo(name string) (time.Time, bool)
- func (procAttach *ProcessAttachInfo) GetCannotAndAttachInfo(name string) (time.Time, bool)
- type ProcessInfo
- type ProcessSchedC
- type ProcessSchedWithFNameC
- type SchedTracer
- type SymLoc
- type UprobeProcessRegister
- type UprobeRegRule
- type UprobeRegister
Constants ¶
View Source
const ( SchedFork = 0b1 << iota SchedExec SchedExit )
Variables ¶
This section is empty.
Functions ¶
func AllProcess ¶
func FindStructMemberOffset ¶
func GetEnv ¶
GetEnv retrieves the environment variable key. If it does not exist it returns the default. Copy from vendor/github.com/shirou/gopsutil/v3/internal/common/common.go:common.GetEnv
func HostProc ¶
HostProc returns the value of the host proc path. Context from vendor/github.com/shirou/gopsutil/v3/internal/common/common.go:common.HostProc
func NewRegisterFunc ¶
func NewSchedManger ¶
func NewUnRegisterFunc ¶
Types ¶
type ProcInjectC ¶
type ProcInjectC C.struct_proc_inject
type ProcessAttachInfo ¶
func (*ProcessAttachInfo) AddAtach ¶
func (procAttach *ProcessAttachInfo) AddAtach(name string, tn time.Time)
func (*ProcessAttachInfo) AddCannotAttach ¶
func (procAttach *ProcessAttachInfo) AddCannotAttach(name string, tn time.Time)
func (*ProcessAttachInfo) GetAttachInfo ¶
func (procAttach *ProcessAttachInfo) GetAttachInfo(name string) (time.Time, bool)
func (*ProcessAttachInfo) GetCannotAndAttachInfo ¶
func (procAttach *ProcessAttachInfo) GetCannotAndAttachInfo(name string) (time.Time, bool)
type ProcessInfo ¶
type ProcessSchedC ¶
type ProcessSchedC C.struct_rec_process_sched_status
type ProcessSchedWithFNameC ¶
type ProcessSchedWithFNameC C.struct_rec_process_sched_status_with_filename
type SchedTracer ¶
type SchedTracer struct { Manager *manager.Manager sync.Mutex // contains filtered or unexported fields }
func NewProcessSchedTracer ¶
func NewProcessSchedTracer(filter *tracing.ProcessFilter) (*SchedTracer, error)
func (*SchedTracer) GetGOSchedMap ¶
func (tracer *SchedTracer) GetGOSchedMap() (map[string]*ebpf.Map, bool)
func (*SchedTracer) ProcessSchedHandler ¶
func (*SchedTracer) Stop ¶
func (tracer *SchedTracer) Stop() error
type UprobeProcessRegister ¶
type UprobeProcessRegister struct{}
type UprobeRegRule ¶
type UprobeRegister ¶
func NewUprobeDyncLibRegister ¶
func NewUprobeDyncLibRegister(rules []UprobeRegRule) (*UprobeRegister, error)
func (*UprobeRegister) CleanAll ¶
func (register *UprobeRegister) CleanAll()
func (*UprobeRegister) Monitor ¶
func (register *UprobeRegister) Monitor(ctx context.Context, scanInterval time.Duration)
func (*UprobeRegister) ScanAndUpdate ¶
func (register *UprobeRegister) ScanAndUpdate()
Source Files ¶
Click to show internal directories.
Click to hide internal directories.