Module Expr Str Import alias Import alias Import alias Import alias Import alias Assign NameStore Num Assign NameStore Str TryExcept body If CompareIn Str AttributeLoad NameLoad attr body Assign NameStore Call NameLoad SubscriptLoad AttributeLoad NameLoad attr Index Str handlers ExceptHandler type NameLoad body Pass FunctionDef arguments args defaults body Expr Str TryExcept body Assign NameStore Call AttributeLoad NameLoad attr NameLoad handlers ExceptHandler type NameLoad name TupleStore NameStore NameStore body If CompareEq NameLoad Num body Return ListLoad Raise Assign NameStore ListComp NameLoad comprehension NameStore NameLoad Call AttributeLoad NameLoad attr Str Assign NameStore ListLoad For NameStore NameLoad body TryExcept body Expr Call AttributeLoad NameLoad attr Call NameLoad Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad NameLoad Str handlers ExceptHandler type NameLoad name TupleStore NameStore NameStore body If CompareEq NameLoad Num body Continue Raise Return NameLoad decorator_list FunctionDef arguments args NameParam defaults body Expr Str For NameStore NameLoad body Expr Call AttributeLoad NameLoad attr Num Assign NameStore Call NameLoad SubscriptLoad AttributeLoad NameLoad attr Slice BinOpAdd Call AttributeLoad AttributeLoad NameLoad attr attr Str Num Num Assign NameStore Call NameLoad Call AttributeLoad NameLoad attr Assign NameStore Call NameLoad GeneratorExp Call AttributeLoad NameLoad attr comprehension NameStore Call AttributeLoad Call AttributeLoad NameLoad attr attr For TupleStore NameStore NameStore TupleLoad TupleLoad Str Str TupleLoad Str Str body Print BinOpMod Str TupleLoad NameLoad SubscriptLoad NameLoad Index NameLoad NameLoad NameLoad Print BinOpMod Str TupleLoad NameLoad SubscriptLoad NameLoad Index Str NameLoad For TupleStore NameStore NameStore TupleLoad TupleLoad Str Str TupleLoad Str Str body Print BinOpMod Str TupleLoad NameLoad SubscriptLoad NameLoad Index NameLoad NameLoad NameLoad Print BinOpMod Str TupleLoad NameLoad SubscriptLoad NameLoad Index Str NameLoad decorator_list FunctionDef arguments args defaults body Expr Str Assign NameStore Call NameLoad Str Str Assign NameStore Call NameLoad Str Str Assign NameStore Call NameLoad Str Str Assign NameStore Call NameLoad Str Str Assign NameStore Call NameLoad Str Str Assign NameStore Call NameLoad Str Str Assign NameStore Call NameLoad While NameLoad body If CompareEq Call AttributeLoad NameLoad attr Num body Expr Call AttributeLoad NameLoad attr Num Expr Call AttributeLoad NameLoad attr Num Assign NameStore Call NameLoad Call AttributeLoad NameLoad attr For NameStore NameLoad body Assign NameStore Call AttributeLoad NameLoad attr Str NameLoad If NameLoad body Print BinOpMod Str TupleLoad NameLoad Call AttributeLoad NameLoad attr Num Print BinOpMod Str TupleLoad NameLoad Call AttributeLoad NameLoad attr Num Expr Call AttributeLoad NameLoad attr Num Assign NameStore Call NameLoad Call AttributeLoad NameLoad attr For NameStore NameLoad body Assign NameStore Call AttributeLoad NameLoad attr Str NameLoad If NameLoad body Print BinOpMod Str TupleLoad Call AttributeLoad Call AttributeLoad NameLoad attr Num attr NameLoad Call AttributeLoad NameLoad attr Num Expr Call AttributeLoad NameLoad attr Num Assign NameStore Call NameLoad Call AttributeLoad NameLoad attr For NameStore NameLoad body Assign NameStore Call AttributeLoad NameLoad attr Str NameLoad If UnaryOpNot NameLoad body Continue If CompareIn Call AttributeLoad NameLoad attr Num TupleLoad Str Str Str Str Str Str body Print BinOpMod Str TupleLoad Call AttributeLoad NameLoad attr Num NameLoad Call AttributeLoad NameLoad attr Num Expr Call AttributeLoad NameLoad attr Num Assign NameStore Call NameLoad Call AttributeLoad NameLoad attr For NameStore NameLoad body Assign NameStore Call AttributeLoad NameLoad attr Str NameLoad If UnaryOpNot NameLoad body Continue If CompareEq Call AttributeLoad NameLoad attr Num Str body Assign NameStore Call AttributeLoad Call AttributeLoad NameLoad attr Num attr Print BinOpMod Str TupleLoad NameLoad SubscriptLoad NameLoad Index Num Print BinOpMod Str TupleLoad NameLoad SubscriptLoad NameLoad Index Num Print BinOpMod Str TupleLoad NameLoad SubscriptLoad NameLoad Index Num Print BinOpMod Str TupleLoad NameLoad SubscriptLoad NameLoad Index Num Print BinOpMod Str TupleLoad NameLoad SubscriptLoad NameLoad Index Num Print BinOpMod Str TupleLoad NameLoad SubscriptLoad NameLoad Index Num Print BinOpMod Str TupleLoad NameLoad SubscriptLoad NameLoad Index Num If CompareGt Call NameLoad NameLoad Num body Print BinOpMod Str TupleLoad NameLoad SubscriptLoad NameLoad Index Num If CompareGt Call NameLoad NameLoad Num body Print BinOpMod Str TupleLoad NameLoad SubscriptLoad NameLoad Index Num orelse If CompareEq Call AttributeLoad NameLoad attr Num Str body Print BinOpMod Str TupleLoad NameLoad SubscriptLoad Call AttributeLoad Call AttributeLoad NameLoad attr Num attr Index Num orelse If CompareEq Call AttributeLoad NameLoad attr Num Str body Print BinOpMod Str TupleLoad NameLoad Call AttributeLoad NameLoad attr Num orelse If CompareEq Call AttributeLoad NameLoad attr Num Str body Print BinOpMod Str TupleLoad NameLoad Call AttributeLoad NameLoad attr Num orelse If CompareEq Call AttributeLoad NameLoad attr Num Str body Print BinOpMod Str TupleLoad NameLoad Call AttributeLoad NameLoad attr Num Expr Call AttributeLoad NameLoad attr Num Assign NameStore Call NameLoad Call AttributeLoad NameLoad attr For NameStore NameLoad body Assign NameStore Call AttributeLoad NameLoad attr Str NameLoad If UnaryOpNot NameLoad body Continue Print BinOpMod Str TupleLoad NameLoad Call AttributeLoad NameLoad attr Num Print BinOpMod Str TupleLoad NameLoad Call AttributeLoad NameLoad attr Num Print BinOpMod Str TupleLoad NameLoad Call AttributeLoad NameLoad attr Num Print BinOpMod Str TupleLoad NameLoad Call AttributeLoad NameLoad attr Num Print BinOpMod Str TupleLoad NameLoad Call AttributeLoad NameLoad attr Num Expr Call AttributeLoad NameLoad attr Num Assign NameStore Call NameLoad Call AttributeLoad NameLoad attr For NameStore NameLoad body Print BinOpMod Str TupleLoad NameLoad Call AttributeLoad NameLoad attr Expr Call NameLoad NameLoad Expr Call AttributeLoad AttributeLoad NameLoad attr attr Expr Call AttributeLoad NameLoad attr NameLoad decorator_list If CompareEq NameLoad Str body Expr Call NameLoad
N/A N/A import various /proc stats from /proc into TSDB N/A os N/A sys N/A time N/A socket N/A re N/A COLLECTION_INTERVAL 30 N/A NUMADIR /sys/devices/system/node N/A N/A N/A N/A TCOLLECTOR_SAMPLE_INTERVAL N/A os environ N/A N/A COLLECTION_INTERVAL N/A float N/A N/A os environ N/A TCOLLECTOR_SAMPLE_INTERVAL N/A N/A N/A ValueError N/A N/A open_sysfs_numa_stats N/A N/A N/A N/A N/A Returns a possibly empty list of opened files. N/A N/A N/A nodes N/A N/A os listdir NUMADIR N/A N/A N/A OSError N/A N/A errno msg N/A N/A N/A errno 2 N/A N/A N/A N/A N/A nodes N/A node N/A node nodes N/A N/A node startswith node N/A numastats N/A N/A node nodes N/A N/A N/A N/A N/A N/A numastats append N/A open N/A N/A N/A os path join NUMADIR node numastat N/A N/A N/A OSError N/A N/A errno msg N/A N/A N/A errno 2 N/A N/A N/A N/A numastats N/A print_numa_stats N/A N/A numafiles N/A N/A N/A From a list of opened files, extracts and prints NUMA stats. N/A numafile numafiles N/A N/A N/A N/A numafile seek 0 N/A node_id N/A int N/A N/A numafile name N/A N/A N/A N/A N/A numafile name find /node/node 10 -9 N/A ts N/A int N/A N/A time time N/A stats N/A dict N/A N/A N/A line split N/A line N/A N/A N/A N/A numafile read splitlines N/A N/A stat tag N/A N/A numa_hit hit N/A numa_miss miss N/A N/A N/A sys.numa.zoneallocs %d %s node=%d type=%s N/A ts N/A stats N/A stat node_id tag N/A N/A sys.numa.foreign_allocs %d %s node=%d N/A ts N/A stats N/A numa_foreign node_id N/A N/A stat tag N/A N/A local_node local N/A other_node remote N/A N/A N/A sys.numa.allocation %d %s node=%d type=%s N/A ts N/A stats N/A stat node_id tag N/A N/A sys.numa.interleave %d %s node=%d type=hit N/A ts N/A stats N/A interleave_hit node_id N/A main N/A N/A N/A N/A N/A procstats main loop N/A f_uptime N/A open /proc/uptime r N/A f_meminfo N/A open /proc/meminfo r N/A f_vmstat N/A open /proc/vmstat r N/A f_stat N/A open /proc/stat r N/A f_loadavg N/A open /proc/loadavg r N/A f_entropy_avail N/A open /proc/sys/kernel/random/entropy_avail r N/A numastats N/A open_sysfs_numa_stats N/A True N/A N/A N/A N/A N/A os getppid 1 N/A N/A N/A N/A sys exit 1 N/A N/A N/A f_uptime seek 0 N/A ts N/A int N/A N/A time time N/A line f_uptime N/A N/A m N/A N/A re match (\S+)\s+(\S+) line N/A m N/A N/A N/A proc.uptime.total %d %s N/A ts N/A N/A m group 1 N/A N/A proc.uptime.now %d %s N/A ts N/A N/A m group 2 N/A N/A N/A f_meminfo seek 0 N/A ts N/A int N/A N/A time time N/A line f_meminfo N/A N/A m N/A N/A re match (\w+):\s+(\d+) line N/A m N/A N/A N/A proc.meminfo.%s %d %s N/A N/A N/A N/A N/A m group 1 lower ts N/A N/A m group 2 N/A N/A N/A f_vmstat seek 0 N/A ts N/A int N/A N/A time time N/A line f_vmstat N/A N/A m N/A N/A re match (\w+)\s+(\d+) line N/A N/A m N/A N/A N/A N/A N/A N/A m group 1 N/A pgpgin pgpgout pswpin pswpout pgfault pgmajfault N/A N/A N/A proc.vmstat.%s %d %s N/A N/A N/A m group 1 ts N/A N/A m group 2 N/A N/A N/A f_stat seek 0 N/A ts N/A int N/A N/A time time N/A line f_stat N/A N/A m N/A N/A re match (\w+)\s+(.*) line N/A N/A m N/A N/A N/A N/A N/A N/A m group 1 cpu N/A N/A fields N/A N/A N/A N/A m group 2 split N/A N/A proc.stat.cpu %d %s type=user N/A ts N/A fields N/A 0 N/A N/A proc.stat.cpu %d %s type=nice N/A ts N/A fields N/A 1 N/A N/A proc.stat.cpu %d %s type=system N/A ts N/A fields N/A 2 N/A N/A proc.stat.cpu %d %s type=idle N/A ts N/A fields N/A 3 N/A N/A proc.stat.cpu %d %s type=iowait N/A ts N/A fields N/A 4 N/A N/A proc.stat.cpu %d %s type=irq N/A ts N/A fields N/A 5 N/A N/A proc.stat.cpu %d %s type=softirq N/A ts N/A fields N/A 6 N/A N/A N/A len fields 7 N/A N/A N/A proc.stat.cpu %d %s type=steal N/A ts N/A fields N/A 7 N/A N/A N/A len fields 8 N/A N/A N/A proc.stat.cpu %d %s type=guest N/A ts N/A fields N/A 8 N/A N/A N/A N/A N/A m group 1 intr N/A N/A N/A proc.stat.intr %d %s N/A ts N/A N/A N/A N/A N/A m group 2 split N/A 0 N/A N/A N/A N/A N/A m group 1 ctxt N/A N/A N/A proc.stat.ctxt %d %s N/A ts N/A N/A m group 2 N/A N/A N/A N/A N/A m group 1 processes N/A N/A N/A proc.stat.processes %d %s N/A ts N/A N/A m group 2 N/A N/A N/A N/A N/A m group 1 procs_blocked N/A N/A N/A proc.stat.procs_blocked %d %s N/A ts N/A N/A m group 2 N/A N/A N/A f_loadavg seek 0 N/A ts N/A int N/A N/A time time N/A line f_loadavg N/A N/A m N/A N/A re match (\S+)\s+(\S+)\s+(\S+)\s+(\d+)/(\d+)\s+ line N/A N/A m N/A N/A N/A N/A proc.loadavg.1min %d %s N/A ts N/A N/A m group 1 N/A N/A proc.loadavg.5min %d %s N/A ts N/A N/A m group 2 N/A N/A proc.loadavg.15min %d %s N/A ts N/A N/A m group 3 N/A N/A proc.loadavg.runnable %d %s N/A ts N/A N/A m group 4 N/A N/A proc.loadavg.total_threads %d %s N/A ts N/A N/A m group 5 N/A N/A N/A f_entropy_avail seek 0 N/A ts N/A int N/A N/A time time N/A line f_entropy_avail N/A N/A N/A proc.kernel.entropy_avail %d %s N/A ts N/A N/A line strip N/A N/A print_numa_stats numastats N/A N/A N/A N/A sys stdout flush N/A N/A N/A time sleep COLLECTION_INTERVAL N/A N/A N/A __name__ __main__ N/A N/A N/A main