Unable to detect device type Smartctl: please specify device type with the -d option

  • Hi,


    I'm new to OMV, please be gentle if I ask noob questions.


    I have installed OMV as guest under KVM (in Proxmox). I have two sata HDD's defined as virtio to the OMV guest, like:


    qm set 101 -virtio0 /dev/disk/by-id/ata-ST1000DM003-xxxxxxxxxx


    I try to get SMART data from the GUI of OMV (S.M.A.R.T. --> Devices --> Information), but that turns out to give an error:


    Error #6000: exception 'OMVException' with message 'Failed to get S.M.A.R.T. information (device=/dev/vda): ... /dev/vda: Unable to detect device type Smartctl: please specify device type with the -d option.


    When I logon via SSH, the following command runs OK, on command line: smartctl --all -d sat /dev/vda ----> it reurns the proper SMART data were I'm looking for




    Found some suggestions to update config.xml, without further instructions. I tried the following:


    <smart>
    ....
    <device>
    <uuid>8a19c120-2a62-4d7a-a568-abf36314eb36</uuid>
    <devicefile>/dev/vda</devicefile>
    <enable>1</enable>
    <type>sat</type>
    </device>
    ....
    </smart>



    So I inserted the type 'sat', before my update it read as <type></type>


    After that a re-boot, but no luck. Still no SMART info through the OMV GUI.


    Any suggestions?



    Running OMV

    • Offizieller Beitrag

    I use cow images on my proxmox server. So, I can't help much.

    omv 7.0.4-2 sandworm | 64 bit | 6.5 proxmox kernel

    plugins :: omvextrasorg 7.0 | kvm 7.0.10 | compose 7.1.2 | k8s 7.0-6 | cputemp 7.0 | mergerfs 7.0.3


    omv-extras.org plugins source code and issue tracker - github


    Please try ctrl-shift-R and read this before posting a question.

    Please put your OMV system details in your signature.
    Please don't PM for support... Too many PMs!

  • ryecoaaron, subzero79, All,


    Thank you for your responses. Maybe I was not clear in explaining my 'problem'.


    OMV is issueing the smartctl command without the -d option. I need the -d option to explicitly state that the drives are SATA drives.
    This explicit -d option 'sat' is needed in my case, because OMV runs as a guest under KVM, the drives are 'virtio' defined (/dev/vda and /dev/vdb). This 'virtio' definition alows to collect SMART data. See also my initial question for details.


    When OMV would add the -d option to the smartctl command it issues, the problem would be solved.


    I do not passthrough the two 1TB HDD's in my HP Gen8 Microserver, because I do not have a separate IO controller, the IO controller is also being used for an SSD drive, containing my Proxmox partitions and Proxmox 'data stores', and more.

  • Hi,


    Is anybody able to explain how to use these options written in the bugtacker report below? I want to specify the -d option for smartctl (see thread above), but I have still not been able to solve my prolem. Without this I feel OpenMediaVault is not helping me a lot ;( . I have changed config.xml and sepcified <type>sat</type> , however it does not solve the issue.



    I read at http://bugtracker.openmediavault.org/view.php?id=691#c1945



    There are already some ways to tweak the config generation under the hood:


    Defaults:


    OMV_SMARTMONTOOLS_DEFAULTDIRECTIVES=${OMV_SMARTMONTOOLS_DEFAULTDIRECTIVES:-"-a -o on -S on -T permissive"}


    Since 0.4.12 the device type (-d) option is stored in config.xml. This
    can me modified manually without problems. This is only modified if the
    user changes the physical disk properties of the given device.

  • Thanks, I've located the environmental configuration file, but now I do not understand the syntax, how can I specify the -d option in there? I have tried several ways, without result. The SMART report of my drives is still in error and complaining about the missing -d option.


    The bug tracker report also suggest to use the config.xml specification, preferred above the environmental file, why is specifying the type as "sat" not working?

  • OK, I now think I understand how that environmental variable OMV_SMARTMONTOOLS_DEFAULTDIRECTIVES needs to be set, I can see that it results in setting the proper parameters in /etc/smart.conf (-d sat) . However, still no results from the OpenMediaVault GUI, still missing '-d' parameter error message.


    So it looks like OMV_SMARTMONTOOLS_DEFAULTDIRECTIVES environmental setting is not helping me :(


    I would like to pursue the config.xml suggestion, as seen in a previous post above:


    Since 0.4.12 the device type (-d) option is stored in config.xml. This
    can me modified manually without problems. This is only modified if the
    user changes the physical disk properties of the given device.


    I updated config.xml with <type>sat</type> and a re-boot, but no results, still missing -d error message for smartctl
    What is my mistake/misunderstanding?

    • Offizieller Beitrag

    When you change config.xml, you typically have to make a new config with omv-mkconf. Try: omv-mkconf smartmontools

    omv 7.0.4-2 sandworm | 64 bit | 6.5 proxmox kernel

    plugins :: omvextrasorg 7.0 | kvm 7.0.10 | compose 7.1.2 | k8s 7.0-6 | cputemp 7.0 | mergerfs 7.0.3


    omv-extras.org plugins source code and issue tracker - github


    Please try ctrl-shift-R and read this before posting a question.

    Please put your OMV system details in your signature.
    Please don't PM for support... Too many PMs!

  • Updating /etc/default/openmediavault with :


    OMV_SMARTMONTOOLS_DEFAULTDIRECTIVES="-d sat -a -o on -S on -T permissive" (I added -d sat at the beginning of the string, others are the deafults)


    results in running S.M.A.R.T. tests from the smartd (smatmontools) and shows up in the log for S.M.A.R.T, so that is good :)


    Updating config.xml did not help, running omv-mkconf smartmontools did not make a difference.


    I'm happy the S.M.A.R.T. monitoring now runs, unfortunately the S.M.A.R.T. information in the GUI still does not work. Apparently the GUI interface takes a different path to run smartctl. Does anybody know how the GUI kicks of the smartctl tests?

    • Offizieller Beitrag

    Here is the method it uses to call smartctl.

    omv 7.0.4-2 sandworm | 64 bit | 6.5 proxmox kernel

    plugins :: omvextrasorg 7.0 | kvm 7.0.10 | compose 7.1.2 | k8s 7.0-6 | cputemp 7.0 | mergerfs 7.0.3


    omv-extras.org plugins source code and issue tracker - github


    Please try ctrl-shift-R and read this before posting a question.

    Please put your OMV system details in your signature.
    Please don't PM for support... Too many PMs!

  • when the issue is raised in the bug tracker, would it be a good idea to have a library of possible devices or would this work with any kind of underlying controller? I have a LSI MegaRAID SAS 9260-16i here which faces the same problem, my smartctl command line would be


    Code
    smartctl -d sat+megaraid,? -a /dev/sda


    and ? can be read with for instance: (the DID columns)


  • I have a LSI MegaRAID SAS 9260-16i here which faces the same problem, my smartctl command line would be


    The problem with that is that on 3ware controllers you have to talk via /dev/twa0 or so to your drives...


    Greetings
    David

    "Well... lately this forum has become support for everything except omv" [...] "And is like someone is banning Google from their browsers"


    Only two things are infinite, the universe and human stupidity, and I'm not sure about the former.

    Upload Logfile via WebGUI/CLI
    #openmediavault on freenode IRC | German & English | GMT+1
    Absolutely no Support via PM!

  • That is a very very fast response votdev, I'm impressed :thumbup:


    I have run the omv-release-upgrade command, which results in release 2.0.3. (stoneburner). How do I get to 2.0.4? Which is apparently the level I need to have the feature/fix included?

  • Wait a couple of days until Volker uploads that version. ;)


    Greetings
    David

    "Well... lately this forum has become support for everything except omv" [...] "And is like someone is banning Google from their browsers"


    Only two things are infinite, the universe and human stupidity, and I'm not sure about the former.

    Upload Logfile via WebGUI/CLI
    #openmediavault on freenode IRC | German & English | GMT+1
    Absolutely no Support via PM!

Jetzt mitmachen!

Sie haben noch kein Benutzerkonto auf unserer Seite? Registrieren Sie sich kostenlos und nehmen Sie an unserer Community teil!