mirror of
https://github.com/ClusterCockpit/cc-metric-collector.git
synced 2024-11-10 04:27:25 +01:00
Fix clock frequency coming from LikwidCollector and update docs
This commit is contained in:
parent
c09d8fb118
commit
58461f1f72
@ -159,7 +159,8 @@ func getBaseFreq() float64 {
|
||||
data := strings.Replace(string(buffer), "\n", "", -1)
|
||||
x, err := strconv.ParseInt(data, 0, 64)
|
||||
if err == nil {
|
||||
freq = float64(x) * 1e6
|
||||
freq = float64(x)
|
||||
break
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -168,11 +169,11 @@ func getBaseFreq() float64 {
|
||||
C.power_init(0)
|
||||
info := C.get_powerInfo()
|
||||
if float64(info.baseFrequency) != 0 {
|
||||
freq = float64(info.baseFrequency) * 1e6
|
||||
freq = float64(info.baseFrequency)
|
||||
}
|
||||
C.power_finalize()
|
||||
}
|
||||
return freq
|
||||
return freq * 1e3
|
||||
}
|
||||
|
||||
func (m *LikwidCollector) Init(config json.RawMessage) error {
|
||||
|
@ -7,6 +7,9 @@ The `likwid` collector is probably the most complicated collector. The LIKWID li
|
||||
"likwid": {
|
||||
"force_overwrite" : false,
|
||||
"invalid_to_zero" : false,
|
||||
"liblikwid_path" : "/path/to/liblikwid.so",
|
||||
"accessdaemon_path" : "/folder/that/contains/likwid-accessD",
|
||||
"access_mode" : "direct or accessdaemon or perf_event",
|
||||
"eventsets": [
|
||||
{
|
||||
"events" : {
|
||||
|
Loading…
Reference in New Issue
Block a user