Thermald sysfs read failed /sys/class/thermal/thermal_zoneX/temp

Bug #1764320 reported by Marc Pignat on 2018-04-16
12
This bug affects 1 person
Affects Status Importance Assigned to Milestone
linux (Ubuntu)
Undecided
Unassigned
thermald (Ubuntu)
Medium
Colin Ian King

Bug Description

My /var/log/syslog contains a lot of "sysfs read failed /sys/class/thermal/thermal_zone4/temp".

What is the problem and how to fix it (ubutuntu 18.04 / kernel 4.15.0-13-generic / thermald 1.7.0-3)?

lsb_release -rd
Description: Ubuntu Bionic Beaver (development branch)
Release: 18.04

apt-cache policy thermald
thermald:
  Installed: 1.7.0-3
  Candidate: 1.7.0-3
  Version table:
 *** 1.7.0-3 500
        500 http://ch.archive.ubuntu.com/ubuntu bionic/main amd64 Packages
        100 /var/lib/dpkg/status

cat /proc/version
Linux version 4.15.0-13-generic (buildd@lgw01-amd64-023) (gcc version 7.3.0 (Ubuntu 7.3.0-11ubuntu1)) #14-Ubuntu SMP Sat Mar 17 13:44:27 UTC 2018
---
ApportVersion: 2.20.9-0ubuntu5
Architecture: amd64
AudioDevicesInUse:
 USER PID ACCESS COMMAND
 /dev/snd/controlC0: pim 1581 F.... pulseaudio
DistroRelease: Ubuntu 18.04
InstallationDate: Installed on 2018-04-13 (4 days ago)
InstallationMedia: Xubuntu 18.04 LTS "Bionic Beaver" - Alpha amd64 (20180413)
Lsusb:
 Bus 002 Device 002: ID 0b95:1790 ASIX Electronics Corp. AX88179 Gigabit Ethernet
 Bus 002 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub
 Bus 001 Device 003: ID 04f2:b56d Chicony Electronics Co., Ltd
 Bus 001 Device 002: ID 8087:0a2a Intel Corp.
 Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
MachineType: HP HP Pavilion x360 Convertible
Package: thermald 1.7.0-3
PackageArchitecture: amd64
ProcFB: 0 inteldrmfb
ProcKernelCmdLine: BOOT_IMAGE=/vmlinuz-4.15.0-15-generic.efi.signed root=UUID=40ad8820-11eb-4e0b-8556-906bb965f2d1 ro rootflags=subvol=@ quiet splash vt.handoff=1
ProcVersionSignature: Ubuntu 4.15.0-15.16-generic 4.15.15
RelatedPackageVersions:
 linux-restricted-modules-4.15.0-15-generic N/A
 linux-backports-modules-4.15.0-15-generic N/A
 linux-firmware 1.173
Tags: bionic
Uname: Linux 4.15.0-15-generic x86_64
UpgradeStatus: No upgrade log present (probably fresh install)
UserGroups: adm cdrom dialout dip libvirt lpadmin plugdev sambashare sudo
_MarkForUpload: True
dmi.bios.date: 11/10/2016
dmi.bios.vendor: Insyde
dmi.bios.version: F.21
dmi.board.asset.tag: Type2 - Board Asset Tag
dmi.board.name: 81A9
dmi.board.vendor: HP
dmi.board.version: 57.52
dmi.chassis.type: 10
dmi.chassis.vendor: HP
dmi.chassis.version: Chassis Version
dmi.modalias: dmi:bvnInsyde:bvrF.21:bd11/10/2016:svnHP:pnHPPavilionx360Convertible:pvrType1ProductConfigId:rvnHP:rn81A9:rvr57.52:cvnHP:ct10:cvrChassisVersion:
dmi.product.family: 103C_5335KV G=N L=CON B=HP S=PAV
dmi.product.name: HP Pavilion x360 Convertible
dmi.product.version: Type1ProductConfigId
dmi.sys.vendor: HP

Marc Pignat (swid) on 2018-04-16
description: updated
Changed in thermald (Ubuntu):
importance: Undecided → Medium
assignee: nobody → Colin Ian King (colin-king)
status: New → In Progress
Colin Ian King (colin-king) wrote :

Can you run the following and report back the output:

cat /sys/class/thermal/thermal_zone4/type

and:

ls -al /sys/class/thermal/thermal_zone4/device

thanks

Marc Pignat (swid) wrote :

Sure, here are the outputs:

cat /sys/class/thermal/thermal_zone4/type
SEN1

ls -al /sys/class/thermal/thermal_zone4/device
ls: cannot access '/sys/class/thermal/thermal_zone4/device': No such file or directory

Colin Ian King (colin-king) wrote :

Are you able to boot into a previous non-4.15 kernel and repeat the steps in message #1?

Colin Ian King (colin-king) wrote :

And with the 4.15 kernel can you run the following and report back the output:

find /sys/class/thermal/thermal_zone4/ -type f -print -exec cat {} \;

and:

ls -al /sys/class/thermal/thermal_zone4/

and run the following and attach the log to the bug report.

journalctl -n 10000 > journalctl.log

Changed in thermald (Ubuntu):
status: In Progress → Incomplete
Marc Pignat (swid) wrote :
Download full text (4.4 KiB)

With 4.14 :
cat /sys/class/thermal/thermal_zone4/type
B0D4

ls -al /sys/class/thermal/thermal_zone4/device
ls: cannot access '/sys/class/thermal/thermal_zone4/device': No such file or directory

with 4.15:
find /sys/class/thermal/thermal_zone4/ -type f -print -exec cat {} \;
find /sys/class/thermal/thermal_zone4/ -type f -print -exec cat {} \;
/sys/class/thermal/thermal_zone4/trip_point_3_type
passive
/sys/class/thermal/thermal_zone4/trip_point_2_type
hot
/sys/class/thermal/thermal_zone4/trip_point_4_temp
63000
/sys/class/thermal/thermal_zone4/available_policies
power_allocator user_space bang_bang fair_share step_wise
/sys/class/thermal/thermal_zone4/policy
user_space
/sys/class/thermal/thermal_zone4/trip_point_1_type
passive
/sys/class/thermal/thermal_zone4/trip_point_3_temp
83000
/sys/class/thermal/thermal_zone4/trip_point_4_hyst
2000
/sys/class/thermal/thermal_zone4/emul_temp
cat: /sys/class/thermal/thermal_zone4/emul_temp: Permission denied
/sys/class/thermal/thermal_zone4/offset
0
/sys/class/thermal/thermal_zone4/integral_cutoff
0
/sys/class/thermal/thermal_zone4/power/runtime_active_kids
0
/sys/class/thermal/thermal_zone4/power/runtime_suspended_time
0
/sys/class/thermal/thermal_zone4/power/autosuspend_delay_ms
cat: /sys/class/thermal/thermal_zone4/power/autosuspend_delay_ms: Input/output error
/sys/class/thermal/thermal_zone4/power/runtime_enabled
disabled
/sys/class/thermal/thermal_zone4/power/runtime_active_time
0
/sys/class/thermal/thermal_zone4/power/control
auto
/sys/class/thermal/thermal_zone4/power/async
disabled
/sys/class/thermal/thermal_zone4/power/runtime_usage
0
/sys/class/thermal/thermal_zone4/power/runtime_status
unsupported
/sys/class/thermal/thermal_zone4/k_d
0
/sys/class/thermal/thermal_zone4/trip_point_0_type
passive
/sys/class/thermal/thermal_zone4/trip_point_2_temp
100000
/sys/class/thermal/thermal_zone4/trip_point_3_hyst
2000
/sys/class/thermal/thermal_zone4/type
SEN1
/sys/class/thermal/thermal_zone4/trip_point_1_temp
0
/sys/class/thermal/thermal_zone4/trip_point_2_hyst
2000
/sys/class/thermal/thermal_zone4/slope
0
/sys/class/thermal/thermal_zone4/k_po
0
/sys/class/thermal/thermal_zone4/k_i
0
/sys/class/thermal/thermal_zone4/sustainable_power
0
/sys/class/thermal/thermal_zone4/trip_point_0_temp
0
/sys/class/thermal/thermal_zone4/trip_point_1_hyst
2000
/sys/class/thermal/thermal_zone4/k_pu
0
/sys/class/thermal/thermal_zone4/temp
cat: /sys/class/thermal/thermal_zone4/temp: Input/output error
/sys/class/thermal/thermal_zone4/trip_point_4_type
active
/sys/class/thermal/thermal_zone4/uevent
/sys/class/thermal/thermal_zone4/trip_point_0_hyst
2000

ls -al /sys/class/thermal/thermal_zone4/
total 0
drwxr-xr-x 3 root root 0 Apr 16 13:35 .
drwxr-xr-x 15 root root 0 Apr 16 13:34 ..
-r--r--r-- 1 root root 4096 Apr 16 13:35 available_policies
--w------- 1 root root 4096 Apr 16 13:35 emul_temp
-rw-r--r-- 1 root root 4096 Apr 16 13:35 integral_cutoff
-rw-r--r-- 1 root root 4096 Apr 16 13:35 k_d
-rw-r--r-- 1 root root 4096 Apr 16 13:35 k_i
-rw-r--r-- 1 root root 4096 Apr 16 13:35 k_po
-rw-r--r-- 1 root root 4096 Apr 16 13:35 k_pu
-rw-r--r-- 1 root root 4096 Apr 16 13:35 offset
-rw-r--r-- 1 root root 4096 Apr 16 13...

Read more...

Colin Ian King (colin-king) wrote :

I believe the iwlwifi driver is providing a iwlwifi-virtual-0 thermal zone but the temperature information cannot be read, hence thermald can't read this and produces the warning. However, it was my expectation that thermald should disable reading this and hence you shouldn't see many of these warnings appear.

Colin Ian King (colin-king) wrote :

Ah, I'm mistaken, that gets loaded later. Do you mind supplying the list of modules loaded on your machine so I can see if I can find the driver that is failing on the thermal zone 4. Can you run:

lsmod

and paste the output into the bug report. Thanks!

On Tue, 2018-04-17 at 11:56 +0000, Colin Ian King wrote:
> Ah, I'm mistaken, that gets loaded later. Do you mind supplying the
> list of modules loaded on your machine so I can see if I can find the
> driver that is failing on the thermal zone 4. Can you run:
>
> lsmod
>
I am thinking wifi. If this is it, then I will do something for this.

> and paste the output into the bug report. Thanks!
>

Marc Pignat (swid) wrote :
Download full text (8.9 KiB)

lsmod
Module Size Used by
ax88179_178a 24576 0
usbnet 45056 1 ax88179_178a
mii 16384 2 usbnet,ax88179_178a
rfcomm 77824 16
ccm 20480 6
ebtable_filter 16384 0
ebtables 32768 1 ebtable_filter
devlink 45056 0
ip6table_filter 16384 0
ip6_tables 28672 1 ip6table_filter
iptable_filter 16384 0
cmac 16384 1
bnep 20480 2
hid_multitouch 20480 0
snd_hda_codec_hdmi 49152 1
snd_soc_skl 90112 0
snd_soc_skl_ipc 65536 1 snd_soc_skl
arc4 16384 2
snd_hda_ext_core 24576 1 snd_soc_skl
snd_soc_sst_dsp 32768 1 snd_soc_skl_ipc
snd_hda_codec_realtek 102400 1
nls_iso8859_1 16384 1
snd_soc_sst_ipc 16384 1 snd_soc_skl_ipc
snd_soc_acpi 16384 1 snd_soc_skl
snd_hda_codec_generic 73728 1 snd_hda_codec_realtek
snd_soc_core 241664 1 snd_soc_skl
snd_compress 20480 1 snd_soc_core
ac97_bus 16384 1 snd_soc_core
snd_pcm_dmaengine 16384 1 snd_soc_core
snd_hda_intel 40960 3
snd_hda_codec 126976 4 snd_hda_intel,snd_hda_codec_hdmi,snd_hda_codec_generic,snd_hda_codec_realtek
snd_hda_core 81920 7 snd_hda_intel,snd_hda_codec,snd_hda_ext_core,snd_soc_skl,snd_hda_codec_hdmi,snd_hda_codec_generic,snd_hda_codec_realtek
snd_hwdep 20480 1 snd_hda_codec
snd_pcm 98304 8 snd_hda_intel,snd_hda_codec,snd_pcm_dmaengine,snd_hda_ext_core,snd_hda_core,snd_soc_skl,snd_hda_codec_hdmi,snd_soc_core
intel_rapl 20480 0
iwlmvm 364544 0
x86_pkg_temp_thermal 16384 0
intel_powerclamp 16384 0
coretemp 16384 0
kvm_intel 204800 0
mac80211 778240 1 iwlmvm
kvm 593920 1 kvm_intel
snd_seq_midi 16384 0
snd_seq_midi_event 16384 1 snd_seq_midi
snd_rawmidi 32768 1 snd_seq_midi
irqbypass 16384 1 kvm
uvcvideo 86016 0
intel_cstate 20480 0
iwlwifi 278528 1 iwlmvm
snd_seq 65536 2 snd_seq_midi_event,snd_seq_midi
intel_rapl_perf 16384 0
input_leds 16384 0
videobuf2_vmalloc 16384 1 uvcvideo
snd_seq_device 16384 3 snd_seq,snd_rawmidi,snd_seq_midi
snd_timer 32768 2 snd_seq,snd_pcm
videobuf2_memops 16384 1 videobuf2_vmalloc
btusb 45056 0
joydev 24576 0
videobuf2_v4l2 24576 1 uvcvideo
btrtl 16384 1 btusb
serio_raw 16384 0
snd 81920 19 snd_compress,snd_hda_intel,snd_hwdep,snd_seq,snd_hda_codec,snd_timer,snd_rawmidi,snd_hda_codec_hdmi,snd_hda_codec_generic,snd_seq_device,snd_hda_codec_realtek,snd_soc_core,snd_pcm
hp_wmi 16384 0
videobuf2_core 40960 2 uvcvideo,videobuf2_v4l2
btbcm 16384 1 btusb
cfg80211 622592 3 iwlmvm,iwlwifi,mac80211
intel_wmi_thunderbolt 16384 0
idma64 20480 0
wmi_bmof 1...

Read more...

Colin Ian King (colin-king) wrote :

I'm adding a small change to thermald so it does not continually spam the log.

Changed in thermald (Ubuntu):
status: Incomplete → In Progress

This bug is missing log files that will aid in diagnosing the problem. While running an Ubuntu kernel (not a mainline or third-party kernel) please enter the following command in a terminal window:

apport-collect 1764320

and then change the status of the bug to 'Confirmed'.

If, due to the nature of the issue you have encountered, you are unable to run this command, please add a comment stating that fact and change the bug status to 'Confirmed'.

This change has been made by an automated script, maintained by the Ubuntu Kernel Team.

Changed in linux (Ubuntu):
status: New → Incomplete
tags: added: bionic

apport information

tags: added: apport-collected
description: updated
Marc Pignat (swid) wrote : CRDA.txt

apport information

apport information

apport information

apport information

Marc Pignat (swid) wrote : Lspci.txt

apport information

apport information

apport information

apport information

apport information

apport information

apport information

apport information

apport information

Andy Whitcroft (apw) on 2018-04-18
Changed in linux (Ubuntu):
status: Incomplete → Confirmed
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package thermald - 1.7.0-5

---------------
thermald (1.7.0-5) unstable; urgency=medium

  * Don't continually re-read broken temperature sysfs file (LP: #1764320)
    log once that is unreadble, thereafter don't re-read as this
    will spam the log with read failure messages

 -- Colin King <email address hidden> Tue, 17 Apr 2018 16:22:21 +0100

Changed in thermald (Ubuntu):
status: In Progress → Fix Released
Marc Pignat (swid) wrote :

Tested on my machine using http://launchpadlibrarian.net/366148394/thermald_1.7.0-5_amd64.deb, working fine!

Thank you @colin-king

@swid by "working fine!" do you just mean that the log entries are gone, or do you mean that thermald still works properly, including controlling temperature?

I just reported this CRITICAL bug against 1.7.0-5 in Debian:

Bug#896132: thermald uninitialised member causes loss of temperature control
https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=896132

The bug was introduced by the patch for the issue you reported. I have attached a patch that fixes it.

Colin Ian King (colin-king) wrote :

Thanks Ben for spotting the bug and for the fix, I'm uploading that to Debian right now and will sync it into Ubuntu as soon as it is ready for syncing. Much appreciated.

Thanks, Colin. I will test it as soon as I can.

Confirmed fixed in Debian 1.7.0-6 (amd64 from incoming). Thanks, Colin.

tags: added: patch
Marc Pignat (swid) wrote :

I tried restarting thermald (1.7.0-5) at least 10 times, and the system always see the same broken sensor, the same as in 1.7.0-4 and the same as in 1.7.0-6.

Perhaps by luck (or perhaps because some library or compiler version difference) thermald 1.7.0-5 worked fine on my 18.04 setup.

Colin Ian King (colin-king) wrote :

I'm tracking the fix in Ubuntu with bug report 1765572

Andy Whitcroft (apw) on 2019-08-15
Changed in thermald (Ubuntu Bionic):
status: New → Fix Committed
tags: added: verification-needed verification-needed-bionic
Colin Ian King (colin-king) wrote :

The bionic SRU test message occurred because I accidentally uploaded the package with the entire old history. This bug has already been fixed and the verification for bionic can be ignored.

no longer affects: thermald (Ubuntu Bionic)
tags: added: verification-done
removed: verification-needed verification-needed-bionic
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.