{"id":22832578,"url":"https://github.com/waldner/collectd-cpu_temp","last_synced_at":"2025-08-10T18:32:01.353Z","repository":{"id":92012181,"uuid":"148050505","full_name":"waldner/collectd-CPU_temp","owner":"waldner","description":"CPU temperature Perl plugin for collectd","archived":true,"fork":false,"pushed_at":"2018-09-12T20:28:36.000Z","size":24,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-03-31T02:18:54.088Z","etag":null,"topics":["collectd","collectd-perl-plugin","collectd-plugin","perl"],"latest_commit_sha":null,"homepage":null,"language":"Perl","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/waldner.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2018-09-09T17:45:52.000Z","updated_at":"2023-12-19T22:48:55.000Z","dependencies_parsed_at":"2024-06-05T09:17:24.508Z","dependency_job_id":null,"html_url":"https://github.com/waldner/collectd-CPU_temp","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/waldner/collectd-CPU_temp","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/waldner%2Fcollectd-CPU_temp","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/waldner%2Fcollectd-CPU_temp/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/waldner%2Fcollectd-CPU_temp/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/waldner%2Fcollectd-CPU_temp/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/waldner","download_url":"https://codeload.github.com/waldner/collectd-CPU_temp/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/waldner%2Fcollectd-CPU_temp/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":269770602,"owners_count":24473307,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-08-10T02:00:08.965Z","response_time":71,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["collectd","collectd-perl-plugin","collectd-plugin","perl"],"created_at":"2024-12-12T21:08:03.298Z","updated_at":"2025-08-10T18:32:01.348Z","avatar_url":"https://github.com/waldner.png","language":"Perl","funding_links":[],"categories":[],"sub_categories":[],"readme":"\n### What's this?\n\nThis is a [collectd](https://collectd.org/) plugin to collect CPU temperature by directly reading the sysfs [coretemp/hwmon interface](https://www.kernel.org/doc/Documentation/hwmon/coretemp), without external software (eg, no need to install lm_sensors). \n\n### Configuration\n\nPlace something similar to the following lines in your `collectd.conf`:\n\n```\n...\n# Load Perl plugin if you weren't loading it already\n\u003cLoadPlugin perl\u003e\n  Globals true\n\u003c/LoadPlugin\u003e\n...\n\n\u003cPlugin perl\u003e\n  IncludeDir \"/path/to/collectd_plugins\"\n  BaseName \"Collectd::Plugins\"\n\n  ...\n\n  LoadPlugin CPU_temp\n\n  \u003cPlugin CPU_temp\u003e\n#    Packages \"0\" \"1\"              # optional: which CPU packages (ie, sockets) to monitor, default: all\n#    IgnoreSelectedPackages False  # invert package selection, default false. Valid values: False, 0, Off or True, 1, On\n#    CoresByLabel \"^Phy\"           # within each package, select only cores whose lable matches the provided regexp\n#    IgnoreSelectedCores False     # ignore matched cores and only monitor the others\n#\n#    # CoresByLabel, CoresByFile and IgnoreSelectedCores can be overridden on a per-package basis\n#    \u003cPackage \"0\"\u003e\n#      CoresByLabel \"^Core\"\n#      IgnoreSelectedCores False\n#    \u003c/Package\u003e\n  \u003c/Plugin\u003e\n\n\u003c/Plugin\u003e\n```\n\nAll configuration directives are optional. Here's a bit longer explanation.\n\nValues in the `Packages` directive refer to the corresponding `coretemp.*` directory under `/sys/devices/platform/`, so if you have 2 CPU packages/sockets (`/sys/devices/platform/coretemp.0` and `/sys/devices/platform/coretemp.1`) and say\n\n```\n\u003cPlugin CPU_temp\u003e\n   Packages \"1\"\n\u003c/Plugin\u003e\n```\n\nonly `/sys/devices/platform/coretemp.1` will be read. You can use `IgnoreSelectedPackages` to exclude, rather than include, the listed packages. By default, all found packages are read.\n\nCores can be selected in two different, mutually-exclusive ways.\n\nLinux uses sets of files to store individual cores information, and may or may not correspond to the actual CPU core number (_they usually don't, so beware_). For example, you may have a file `/sys/devices/platform/coretemp.0/hwmon/hwmon3/temp2_input` which actually corresponds to **Core 0**, as shown by reading the contents of the associated label file:\n\n```\n# cat /sys/devices/platform/coretemp.0/hwmon/hwmon3/temp2_label\nCore 0\n\n```\n\nCore labels always seem to have the form `Core X` (corrections welcome).\n\n\nAlso, in some cases there's an extra file set that holds information for the package as a whole (usually it's `temp1_*`, from what I can see):\n\n```\n# cat /sys/devices/platform/coretemp.0/hwmon/hwmon3/temp1_label\nPackage id 0\n\n```\n\n(Note that this label can vary: on some systems it's `Package id X`, on others it's `Physical id X`, and perhaps even different in others - more information welcome).\n\nIf you use `CoresByFile`, you have to specify one or more numbers corresponding to those used for the `temp*_` file set you want.\nIf you use `CoresByLabel`, you have to specify one or more patterns (Perl RE in fact) to select the label content you want.\nFinally, you can use `IgnoreSelectedCores` to ignore the selected cores and use only those not selected by your expressions.\n\nThese directives can be used both at the global level, in which case they apply to all packages, or can be overridden on a per-package basis.\n\nFor example, let's use `CoresByFile` to only monitor the general package temperature for each package (ie, the one in the `temp1_*` files):\n\n```\n\u003cPlugin CPU_temp\u003e\n  CoresByFile \"1\"\n\u003c/Plugin\u003e\n```\n\nThe same thing can be done by using `CoresByLabel`, as follows:\n\n```\n\u003cPlugin CPU_temp\u003e\n  CoresByLabel \"^(Package|Physical)\"\n\u003c/Plugin\u003e\n```\n\nIn both cases, if you add a `IgnoreSelectedCores True` you'll get the effect of excluding the general measurement, and including all individual cores. By default, both general amd per-core temperatures are collected.\n\nAn example of per-package override (very unlikely that you need this, but just to demonstrate):\n\n```\n\u003cPlugin CPU_temp\u003e\n  CoresByLabel \"^(Package|Physical)\"\n  \u003cPackage \"0\"\u003e\n    CoresByLabel \"^Core \"\n  \u003c/Package\u003e\n\u003c/Plugin\u003e\n```\n\nSo if you have multiple packages, you'll get only the general package temperature for all of them, except for package 0, where you'll get the individual cores and not the general one.\n\nPut the actual plugin (`CPU_temp.pm`) inside `/path/to/collectd_plugins/Collectd/Plugins` (or whatever your `IncludeDir` and `BaseName` above are). Note however that the plugin package name assumes you're using Collectd::Plugins as `BaseName`.\nFinally, restart collectd and hopefully see the values being collected.\n\n\n### Caveats\n\nOnly works for Intel CPUs (AFAIK) and only on Linux.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fwaldner%2Fcollectd-cpu_temp","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fwaldner%2Fcollectd-cpu_temp","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fwaldner%2Fcollectd-cpu_temp/lists"}