{"id":937,"date":"2025-06-15T17:19:13","date_gmt":"2025-06-15T22:19:13","guid":{"rendered":"https:\/\/wp.jkhayer.us\/?p=937"},"modified":"2025-06-15T17:37:08","modified_gmt":"2025-06-15T22:37:08","slug":"if-you-want-to-see-the-temperature-in-the-status","status":"publish","type":"post","link":"https:\/\/wp.jkhayer.us\/?p=937","title":{"rendered":"Pi hole"},"content":{"rendered":"\n<pre class=\"wp-block-code\"><code>sudo pihole -up\nsudo pihole setpassword\nsudo reboot <\/code><\/pre>\n\n\n\n<pre id=\"block-a5668cbc-3629-42d8-ac6a-d3a1e71b6d72\" class=\"wp-block-preformatted\">Net Change:<\/pre>\n\n\n\n<pre id=\"block-cc28af4f-5934-46e0-ae95-43745ce74bec\" class=\"wp-block-code\"><code>sudo nano -w \/etc\/dhcpcd.conf <\/code><\/pre>\n\n\n\n<pre id=\"block-a5668cbc-3629-42d8-ac6a-d3a1e71b6d72\" class=\"wp-block-preformatted\">Install Pi-hole<\/pre>\n\n\n\n<pre class=\"wp-block-code\"><code>curl -sSL https:\/\/install.pi-hole.net | bash<\/code><\/pre>\n\n\n\n<p><\/p>\n\n\n\n<p class=\"has-text-align-center has-medium-font-size\"><strong><em><mark style=\"background-color:rgba(0, 0, 0, 0)\" class=\"has-inline-color has-vivid-green-cyan-color\">If you want to see the temperature in the status<\/mark><\/em><\/strong><\/p>\n\n\n\n<p>After the update, the temperature information disappeared. It wasn\u2019t too important, but I liked seeing that everything was fine.<\/p>\n\n\n\n<figure class=\"wp-block-image\"><a href=\"https:\/\/preview.redd.it\/if-you-want-to-see-the-temperature-in-the-status-v0-xr9irlogi6ke1.png?width=484&amp;format=png&amp;auto=webp&amp;s=07edb6be9aa09837bd7ccf4c2b5b2dcda263eb29\" target=\"_blank\" rel=\"noreferrer noopener\"><img decoding=\"async\" src=\"https:\/\/preview.redd.it\/if-you-want-to-see-the-temperature-in-the-status-v0-xr9irlogi6ke1.png?width=484&amp;format=png&amp;auto=webp&amp;s=07edb6be9aa09837bd7ccf4c2b5b2dcda263eb29\" alt=\"r\/pihole - If you want to see the temperature in the status\"\/><\/a><\/figure>\n\n\n\n<p>Here\u2019s a simple guide on how to display it in the status:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>sudo nano \/var\/www\/html\/admin\/scripts\/lua\/sidebar.lp<\/code><\/pre>\n\n\n\n<p>Find the following code:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>...\n&lt;div class=\"pull-left info\"&gt;\n    &lt;p&gt;Status&lt;\/p&gt;\n    &lt;span id=\"status\"&gt;&lt;\/span&gt;&lt;br\/&gt;\n    &lt;span id=\"query_frequency\"&gt;&lt;\/span&gt;&lt;br\/&gt;\n    &lt;span id=\"cpu\"&gt;&lt;\/span&gt;&lt;br\/&gt;\n    &lt;span id=\"memory\"&gt;&lt;\/span&gt;\n&lt;\/div&gt;\n...<\/code><\/pre>\n\n\n\n<p>And simply add the following line (in Fahrenheit):<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>&lt;span id=\"temperature\"&gt;&amp;nbsp;&amp;nbsp;&lt;i class=\"fa-solid fa-temperature-three-quarters text-green-light\"&gt;&lt;\/i&gt;&amp;nbsp;&amp;nbsp; Temp: &lt;%= string.format(\"%.1f\u00b0F\", (tonumber(io.open(\"\/sys\/class\/thermal\/thermal_zone0\/temp\"):read(\"*a\")) \/ 1000) * 9\/5 + 32) %&gt;&lt;\/span&gt;&lt;br\/&gt;<\/code><\/pre>\n\n\n\n<p>or this code if you need in Celsius:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>&lt;span id=\"temperature\"&gt;&amp;nbsp;&amp;nbsp;&lt;i class=\"fa-solid fa-temperature-three-quarters text-green-light\"&gt;&lt;\/i&gt;&amp;nbsp;&amp;nbsp; Temp: &lt;%= string.format(\"%.1f\u00b0C\", tonumber(io.open(\"\/sys\/class\/thermal\/thermal_zone0\/temp\"):read(\"*a\")) \/ 1000) %&gt;&lt;\/span&gt;&lt;br\/&gt;<\/code><\/pre>\n\n\n\n<p>Right below:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>&lt;p&gt;Status&lt;\/p&gt;<\/code><\/pre>\n\n\n\n<p>To save the changes, press <strong>[Ctrl+S]<\/strong>,<br>To exit, press <strong>[Ctrl+X]<\/strong>.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Net Change: Install Pi-hole If you want to see the temperature in the status After the update, the temperature information<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[15,3],"tags":[],"class_list":["post-937","post","type-post","status-publish","format-standard","hentry","category-linux","category-tutorials"],"_links":{"self":[{"href":"https:\/\/wp.jkhayer.us\/index.php?rest_route=\/wp\/v2\/posts\/937","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/wp.jkhayer.us\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/wp.jkhayer.us\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/wp.jkhayer.us\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/wp.jkhayer.us\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=937"}],"version-history":[{"count":7,"href":"https:\/\/wp.jkhayer.us\/index.php?rest_route=\/wp\/v2\/posts\/937\/revisions"}],"predecessor-version":[{"id":946,"href":"https:\/\/wp.jkhayer.us\/index.php?rest_route=\/wp\/v2\/posts\/937\/revisions\/946"}],"wp:attachment":[{"href":"https:\/\/wp.jkhayer.us\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=937"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/wp.jkhayer.us\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=937"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/wp.jkhayer.us\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=937"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}