Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Needs '-v 9,msec24hour32' param for smartctl-5.41+svn3365-1 in Ubuntu LTS 12.04 precise #29

Closed
braveheartleo opened this issue Jul 4, 2013 · 9 comments
Assignees
Labels
Milestone

Comments

@braveheartleo
Copy link

Hello linrunner,

Thank you so much on making tlp power management available on Ubuntu.

There is a slight problem, however, concerning the display of hdd temp in tlp-stat. Without the '-v 9,msec24hour32' smartctl parameter, hdd temp looks like this:

+++ Storage Devices
/dev/sda:
Model = ST9500325AS
Firmware = 0011LVM1
APM Level = 254
Status = active/idle
scheduler = cfq

    SMART info:
        4 Start_Stop_Count          =      579 
        5 Reallocated_Sector_Ct     =        0 
        9 Power_On_Hours            =     30245159701825 [h]
      190 Airflow_Temperature_Cel   =       41 [°C]
      193 Load_Cycle_Count          =    17459 
      194 Temperature_Celsius       =       41 (0 23 0 [°C]

As you can see, the Power_On_Hours displays hours value that doesn't make sense. Using the formatting msec24hour32 for SMART attribute 9, it now shows:

       9 Power_On_Hours            =    3339 [h]

This seems to be an issue in smartctl-5.41+svn3365-1 that ships with this Ubuntu release. Later versions of smartctl doesn't exhibit such issue on another distro I run on this computer.

@ghost ghost assigned linrunner Jul 4, 2013
@linrunner
Copy link
Owner

Hi,

planned for the next release. Thanks for your report.

@braveheartleo
Copy link
Author

Good to hear about that.

@linrunner
Copy link
Owner

Did you try smartctl -A -v 9,msec24hour32 on the "other distro" you mentioned? Are the Power_On-Hours correct with the unneeded param?

@braveheartleo
Copy link
Author

The other distro is Debian sid. tlp-stat works flawless there. Power_On_Hours displays correctly. I need not tinker with the script.

But in Ubuntu 12.04, I had to slightly modify tlp-stat:

 readonly SMARTCTL="smartctl -v 9,msec24hour32"

so that tlp-stat displays Power_On_Hours correctly. Perhaps this is some issue between smartctl-5.41 and this particular hdd drive model? I don't have another PC to test 12.04 on to see if smartctl-5.41 will produce the same Power_On_Hours display on a different drive that needs the smartctl formatting parameter.

@linrunner
Copy link
Owner

I don't like case distinctions in the code very much. If you make the modification on Debian too, does tlp-stat still display the correct value?

BTW: none of my systems/disks shows this behavior with 12.04.

@braveheartleo
Copy link
Author

Correction:

 smartctl -A -v 9,msec24hour32 /dev/sda

still displays the correct time, but expanded to Xh+Ym+Z.Ms.

So I guess this is an isolated case between my particular hdd drive model, and smartctl-5.41.

Thank you for testing the premise of my issue. I would just have to make my modifications after each tlp update, to address this issue, or better yet, I'll see if I can compile a later version.

@linrunner
Copy link
Owner

Could you provide the relevant output of

smartctl -A -v 9,msec24hour32 /dev/sda

on Debian?

@braveheartleo
Copy link
Author

I went ahead and recompiled a recent smartmontools version for Ubuntu 12.04.

This was just an isolated case between my drive and smartctl-5.41. Sorry for the false alarm. Case closed. :-)

@linrunner
Copy link
Owner

OK :-)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants