Trying to access SMART menu in the WebUI throw an error message

  • Hello all,


    after updating my system from OMV4 to OMV5 i am running into some issues, one of them is that the SMART menu in the Storage section, i get an error message and no drives are shown in the menu :


    Erreur #0:
    OMV\ExecException: Failed to execute command 'export PATH=/bin:/sbin:/usr/bin:/usr/sbin:/usr/local/bin:/usr/local/sbin; export LANG=C.UTF-8; smartctl -x '/dev/sdc' 2>&1' with exit code '1': smartctl 6.6 2017-11-05 r4594 [x86_64-linux-5.4.0-0.bpo.4-amd64] (local build)
    Copyright (C) 2002-17, Bruce Allen, Christian Franke, http://www.smartmontools.org

    /dev/sdc: requires option '-d cciss,N'
    Please specify device type with the -d option.

    Use smartctl -h to get a usage summary in /usr/share/php/openmediavault/system/storage/smartinformation.inc:166
    Stack trace:
    #0 /usr/share/php/openmediavault/system/storage/smartinformation.inc(198): OMV\System\Storage\SmartInformation->getData()
    #1 /usr/share/php/openmediavault/system/storage/smartinformation.inc(383): OMV\System\Storage\SmartInformation->getAttributes()
    #2 /usr/share/openmediavault/engined/rpc/smart.inc(91): OMV\System\Storage\SmartInformation->getTemperature()
    #3 /usr/share/php/openmediavault/rpc/serviceabstract.inc(635): Engined\Rpc\Smart->Engined\Rpc\{closure}()
    #4 /usr/share/openmediavault/engined/rpc/smart.inc(107): OMV\Rpc\ServiceAbstract->asyncProc(Object(Closure))
    #5 [internal function]: Engined\Rpc\Smart->enumerateDevices(NULL, Array)
    #6 /usr/share/php/openmediavault/rpc/serviceabstract.inc(123): call_user_func_array(Array, Array)
    #7 /usr/share/openmediavault/engined/rpc/smart.inc(174): OMV\Rpc\ServiceAbstract->callMethod('enumerateDevice...', NULL, Array)
    #8 [internal function]: Engined\Rpc\Smart->getList(Array, Array)
    #9 /usr/share/php/openmediavault/rpc/serviceabstract.inc(123): call_user_func_array(Array, Array)
    #10 /usr/share/php/openmediavault/rpc/serviceabstract.inc(149): OMV\Rpc\ServiceAbstract->callMethod('getList', Array, Array)
    #11 /usr/share/php/openmediavault/rpc/serviceabstract.inc(588): OMV\Rpc\ServiceAbstract->OMV\Rpc\{closure}('/tmp/bgstatusLf...', '/tmp/bgoutputmc...')
    #12 /usr/share/php/openmediavault/rpc/serviceabstract.inc(159): OMV\Rpc\ServiceAbstract->execBgProc(Object(Closure))
    #13 /usr/share/openmediavault/engined/rpc/smart.inc(209): OMV\Rpc\ServiceAbstract->callMethodBg('getList', Array, Array)
    #14 [internal function]: Engined\Rpc\Smart->getListBg(Array, Array)
    #15 /usr/share/php/openmediavault/rpc/serviceabstract.inc(123): call_user_func_array(Array, Array)
    #16 /usr/share/php/openmediavault/rpc/rpc.inc(86): OMV\Rpc\ServiceAbstract->callMethod('getListBg', Array, Array)
    #17 /usr/sbin/omv-engined(537): OMV\Rpc\Rpc::call('Smart', 'getListBg', Array, Array, 1)
    #18 {main}


    I am really not sure why this is happening, the only thing i can say from OMV4 to OMV5 is that now the swap drive is shown in the system file menu while it wasn't the case, at least for me, in OMV4. Any idea where to start looking ? i see in the log : "/dev/sdc: requires option '-d cciss,N'" funny enough is that my "/dev/sda" is a hardware raid drive, "/dev/sdb" is a hardware raid drive too, then, from "/dev/sdc" to "/dev/sdm" is a bunch of SAS drives connected to another raid card configured in JBOD with a software raid 6 created in the raid OMV menu. Hope this is helpful to help me troubleshooting this one ...


  • Hi Erikk, thanks for your help, this is the output, obviously the same as the beginning of the WEBui message :

    smartctl 6.6 2017-11-05 r4594 [x86_64-linux-5.4.0-0.bpo.4-amd64] (local build)

    Copyright (C) 2002-17, Bruce Allen, Christian Franke, http://www.smartmontools.org


    /dev/sdc: requires option '-d cciss,N'

    Please specify device type with the -d option.


    Use smartctl -h to get a usage summary



    Which hardware raid is /dev/sdc connected too? I assume it is a HP Smart Array, right?


    Damn, i am truly sorry i forgot to mention that in this post, did it in another post about a pihole docker issue. Yes you are right, the setup is the following quoting what i already said in my other thread :

    I am running an OMV setup on a HP Proliant DL380 G6 with a dual Xeon L5640 2.27Ghz, 36GB of RAM, with 3 volumes :

    - 4 x 2.5" SAS 15K RPM 300GB in hardware RAID6 for the system as /dev/sda1 (HP RAID P420 couldn't be setup as JBOD)

    - 4 x 2.5" SAS 10K RPM 600GB in hardware RAID10 for a data storage as /dev/sdb1 (Still the HP RAID P420 without JBOD)

    - 12 x 3.5" SAS 7.2K RPM 2TB in software RAID6 for an additional data storage as /dev/md0 (using one drive as a spare) running through a HP P822 in JBOD and an external HP StorageWorks connected with a SAS cable to the main server. (by the way, a second one is ready to get installed and extend the current /dev/md0)


    With OMV4, everything was running good in that menu.

    Thanks again for your help and great job.



    Edit : manually run the command suggest gives me this :


    root@media:~# sudo smartctl -x -d cciss,1 /dev/sdc

    smartctl 6.6 2017-11-05 r4594 [x86_64-linux-5.4.0-0.bpo.4-amd64] (local build)

    Copyright (C) 2002-17, Bruce Allen, Christian Franke, http://www.smartmontools.org


    === START OF INFORMATION SECTION ===

    Vendor: HITACHI

    Product: HUS72302CLAR2000

    Revision: C442

    Compliance: SPC-4

    User Capacity: 2,000,398,934,016 bytes [2.00 TB]

    Logical block size: 512 bytes

    Rotation Rate: 7200 rpm

    Form Factor: 3.5 inches

    Logical Unit id: 0x5000cca01b41ed60

    Serial number: YFH57ZMD

    Device type: disk

    Transport protocol: SAS (SPL-3)

    Local Time is: Mon Apr 27 14:17:56 2020 CEST

    SMART support is: Available - device has SMART capability.

    SMART support is: Enabled

    Temperature Warning: Disabled or Not Supported

    Read Cache is: Enabled

    Writeback Cache is: Disabled


    === START OF READ SMART DATA SECTION ===

    SMART Health Status: OK


    Current Drive Temperature: 31 C

    Drive Trip Temperature: 85 C


    Manufactured in week 15 of year 2012

    Specified cycle count over device lifetime: 50000

    Accumulated start-stop cycles: 35

    Specified load-unload count over device lifetime: 600000

    Accumulated load-unload cycles: 2078

    Elements in grown defect list: 0


    Vendor (Seagate) cache information

    Blocks sent to initiator = 4788733778778390528


    Error counter log:

    Errors Corrected by Total Correction Gigabytes Total

    ECC rereads/ errors algorithm processed uncorrected

    fast | delayed rewrites corrected invocations [10^9 bytes] errors

    read: 0 346849 0 346849 53757254 205651.477 0

    write: 0 7153604 0 7153604 864978 86505.179 0

    verify: 0 1952 0 1952 48953 62558.264 0


    Non-medium error count: 0


    SMART Self-test log

    Num Test Status segment LifeTime LBA_first_err [SK ASC ASQ]

    Description number (hours)

    # 1 Background short Completed - 48707 - [- - -]

    # 2 Background short Completed - 48539 - [- - -]

    # 3 Background short Completed - 48371 - [- - -]

    # 4 Background short Completed - 48205 - [- - -]

    # 5 Background short Completed - 48037 - [- - -]

    # 6 Background short Completed - 47869 - [- - -]

    # 7 Background short Completed - 47701 - [- - -]

    # 8 Background short Completed - 47533 - [- - -]


    Long (extended) Self Test duration: 6 seconds [0.1 minutes]


    Background scan results log

    Status: waiting until BMS interval timer expires

    Accumulated power on time, hours:minutes 49055:01 [2943301 minutes]

    Number of background scans performed: 300, scan progress: 0.00%

    Number of background medium scans performed: 300


    Protocol Specific port log page for SAS SSP

    relative target port id = 1

    generation code = 1

    number of phys = 1

    phy identifier = 0

    attached device type: expander device

    attached reason: unknown

    reason: unknown

    negotiated logical link rate: phy enabled; 3 Gbps

    attached initiator port: ssp=0 stp=0 smp=1

    attached target port: ssp=0 stp=0 smp=1

    SAS address = 0x5000cca01b41ed61

    attached SAS address = 0x50014380107dc700

    attached phy identifier = 1

    Invalid DWORD count = 972

    Running disparity error count = 970

    Loss of DWORD synchronization = 266

    Phy reset problem = 0

    Phy event descriptors:

    Invalid word count: 972

    Running disparity error count: 970

    Loss of dword synchronization count: 266

    Phy reset problem count: 0

    relative target port id = 2

    generation code = 1

    number of phys = 1

    phy identifier = 1

    attached device type: no device attached

    attached reason: unknown

    reason: power on

    negotiated logical link rate: phy enabled; unknown

    attached initiator port: ssp=0 stp=0 smp=0

    attached target port: ssp=0 stp=0 smp=0

    SAS address = 0x5000cca01b41ed62

    attached SAS address = 0x0

    attached phy identifier = 0

    Invalid DWORD count = 0

    Running disparity error count = 0

    Loss of DWORD synchronization = 0

    Phy reset problem = 0

    Phy event descriptors:

    Invalid word count: 0

    Running disparity error count: 0

    Loss of dword synchronization count: 0

    Phy reset problem count: 0



    so it looks good from there, how could we change the initial command from WebUI ?

    • Offizieller Beitrag

    how could we change the initial command from WebUI ?

    It's not possible. The problem here is that your RAID controller seems to use the sd driver (/dev/sdX) instead of the cciss driver (/dev/cciss/xxx) , thus OMV can not detect that it is a HP HPA which will add the necessary additional smartctl parameter.

    OMV does not support appending smartctl parameters manually,everything must be auto-detected to work in a generic way.

    • Offizieller Beitrag

    You may look into Where do I post fixes to misconfigurations in the code base? and We need your help to improve the SMART support of Areca RAID contollers in OMV.. Maybe it is possible to enhance the OMV backend to auto-detect your HPA if you provide the necessary information.


    Lets start with the output of

    Code
    # udevadm info /dev/sdc -a
    # ls -alh /sys/block/sdc/device/../../..
    # ls -alh /sys/block/sdc/device/../../../driver
    # realpath ls -alh /sys/block/sdc/device/../../../driver
  • quite weird that it was working with OMV4 then, the setup didn't changed at all. Basically for this particular hardware controller, i turned it to HBA only using JBOD drives, but that was done in my initial setup, and the drives were already set as /dev/sdX devices. Not sure what i can do here, no being able to monitor my drives is a pain.

  • You may look into Where do I post fixes to misconfigurations in the code base? and We need your help to improve the SMART support of Areca RAID contollers in OMV.. Maybe it is possible to enhance the OMV backend to auto-detect your HPA if you provide the necessary information.


    Lets start with the output of

    Code
    # udevadm info /dev/sdc -a
    # ls -alh /sys/block/sdc/device/../../..
    # ls -alh /sys/block/sdc/device/../../../driver
    # realpath ls -alh /sys/block/sdc/device/../../../driver


    Will do that asap, thanks ;)


    Edit :

    Just to be sure, i post the output of these commands only in the 2 threads you mentioned, no need to continue in this thread right ? I will just point it in the 2 other threads so we know where it started

  • I've created a PR to improve the host driver detection for HPSA HPA. See https://github.com/openmediavault/openmediavault/pull/687.


    Please execute the commands above to confirm that the code works.

    Hi votdev thanks for your help, basically it looks like it returns something as in on of my previous post in this thread where i corrected myself the command, but i placed 1 instead of 0 cciss,1 in post number 4, there is the result with 0 instead, doesn't seem to make any difference and i wasn't sure what is that ID made for from reading the manual, but at least it reads the info from the drive perfectly in that case :


  • However, i think there is a small issue, if i execute the same command with /dev/sdd for example, which should be another drive, i get the same answer back, look at the HDD serial number ;


  • And there using a combination of cciss,2 and /dev/sde i obviously get a different drive correctly... Looks like it is a combination of both we have to play with somehow...


    • Offizieller Beitrag

    And there using a combination of cciss,2 and /dev/sde i obviously get a different drive correctly... Looks like it is a combination of both we have to play with somehow...


    That's not possible, how should OMV detect that it should use 2 or any other numer) instead of 0 or 1?

    • Offizieller Beitrag

    I think this is a bug in the smartctl tool. You're not trying to access a device behind the controller that is not visible to the kernel (this is if the HBA has only ONE device file). Instead all devices are visible to the kernel, thus it shouldn't be necessary to use the -d cciss,X parameter because every device connected to the HBA can be accessed via /dev/sdX.


    Can you post the output of cat /proc/partitions please.

  • I think it is just an incremental value, like you start from /dev/sdc with 0, then /dev/sdd with 1, /dev/sde with 2, and so on ... But nevertheless, I think you got it right about the command, we can see all partitions from all devices using the command :

  • votdev , hello hope you are doing good ? I have seen that you merged your improvement branch to the main branch already some weeks ago, but i am wondering is the fix already published through the OMV updates, or when will it be ? I am not familiar when the updates are generated after a merge ? Because currently i am up to date but still see the issue. Thanks for your feedback.

  • According to the dashboard, i am on 5.5.0-1 but i unfortunately have no more success in the SMART menu :



    Could it be that it is because i have 2 hardware controller in this machine, one internal managing a hardware RAID and another PCI-e configured in HBA mode with a software RAID ?

Jetzt mitmachen!

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