Skip to content
View in the app

A better way to browse. Learn more.

Unraid

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

[PLUGIN] Disk Location

Featured Replies

20 hours ago, FlamongOle said:

Then I assume it's still bugged.

 

Just uninstall it, then install it again.

That fixed it. Now I'm on the newest Version. Thank you!

  • 2 weeks later...
  • Replies 1.7k
  • Views 249.8k
  • Created
  • Last Reply

Top Posters In This Topic

Most Popular Posts

  • olehj is the maintainer and it's his choice to do with the plugin what he sees fit.   It is, however, unusual to release to production a version that requires a beta OS release, instead of r

  • FlamongOle
    FlamongOle

    Update 2025.05.29 Commit #446 - BUG: Fatal error in page_system - causing furious rage in the forums :P Syntax error, misplaced parentheses 😅 @Mr Q I have an idea for you. Why don't you save your o

  • You guys please settle down.  The fact that sqlite support was in php in the first place was an oversight.  We never intended that a plugin would utilize a database application and honestly, I didn't

Posted Images

Exist an ignore or approved Option for Warnings? A USB/Unassigned Device is not every Time attached and his Icon are red blinking when he not attached.

  • Author
1 hour ago, Revan335 said:

Exist an ignore or approved Option for Warnings? A USB/Unassigned Device is not every Time attached and his Icon are red blinking when he not attached.

Nah, not really made for this kind of configurations anyway

3 hours ago, FlamongOle said:

Nah, not really made for this kind of configurations anyway

OK, I found this a good Option to displayed the USB Backup Disks and warn ... he have any errors/warnings. Like the Array/Cache Disks.

I havent looked at my unraid for almost a month but noticed Disk locator now looks like this after doing the force update, did the latest update break it? The numbering is on 0 for some reason

image.png.e833a2cba9b97c11c50d42cc99577a44.png

Edited by Hellomynameisleo

  • Author
On 4/6/2025 at 1:00 PM, Hellomynameisleo said:

I havent looked at my unraid for almost a month but noticed Disk locator now looks like this after doing the force update, did the latest update break it? The numbering is on 0 for some reason

image.png.e833a2cba9b97c11c50d42cc99577a44.png

That's a bit stoopid isn't it? Which version you at, and how's the config?

On 4/8/2025 at 2:40 PM, FlamongOle said:

That's a bit stoopid isn't it? Which version you at, and how's the config?

I'm on UNRAID 7.0.0 and latest version 2025.03.18 disk location.

this is the config settings, and its also deleted all the Purchased and Warranty info on all the disks :(

image.thumb.png.1bae4138d972836c3fbfea1850a32173.png

Edited by Hellomynameisleo

  • Author
On 4/9/2025 at 6:26 PM, Hellomynameisleo said:

I'm on UNRAID 7.0.0 and latest version 2025.03.18 disk location.

this is the config settings, and its also deleted all the Purchased and Warranty info on all the disks :(

 

Sorry, was maybe a bit unclear. I need the Layout config. You can give me the output of this instead of screenshots:

cat /boot/config/plugins/disklocation/groups.json


Purchased and warranty is not carried over anymore from the database and should only use the settings from Unraid config itself. There's a command some few pages back where you can receive the dates (if you still have the sqlite file, should be backed up too). Then you can add them either via Disk Location (if "Allow editing of Unraid config" is set to "Yes") or the normal Unraid way. I added the post in the recommended section.

28 minutes ago, FlamongOle said:

Sorry, was maybe a bit unclear. I need the Layout config. You can give me the output of this instead of screenshots:

cat /boot/config/plugins/disklocation/groups.json


Purchased and warranty is not carried over anymore from the database and should only use the settings from Unraid config itself. There's a command some few pages back where you can receive the dates (if you still have the sqlite file, should be backed up too). Then you can add them either via Disk Location (if "Allow editing of Unraid config" is set to "Yes") or the normal Unraid way. I added the post in the recommended section.

thanks heres the config:

image.thumb.png.3f33bd4da7cd77e80504f8b389899963.png

  • Author
7 minutes ago, Hellomynameisleo said:

thanks heres the config:

 

I will look into why this happens later, but you can change your config to be more correct anyway:

 

Tray assignment count properties: count rows

Tray assignment count direction: left/top

I've just installed this plugin and it looks promising (apart from the default colors being nearly unreadable with the "Azure" theme, but that was quickly fixed by changing the colors to lighter ones)

The main issue I'm facing right now is that, after following the instructions on the dashboard and subsequently setting up the layout and assigning the disks, the dashboard just shows a Go to System and initialize a "Force SMART+DB" warning.
Executing this options has no effect on the warning though.

Screenshot2025-04-16at23_20_57.thumb.png.8a2a1bce76a1fe71402c7ad071d75e33.pngScreenshot2025-04-16at23_26_35.thumb.png.1f9d4463fff560bea07be2f591d4872b.png

Let me know if there is anything I can provide or if this is an easy fix.

The plugin also doesn't detect one of my NVMe drives. 11 drives total is correct, but under allocations there is only 10 options to select. /dev/nvme0n1p1 is detected as nvme0n1 but /dev/nvme1n1p1 isn't.

regards

Edited by Thx And Bye

Upgraded to 7.0.1 today and also picked up the latest version of disklocation (2025.03.18).  Dashboard is failing to load now, PHP log is showing:

 

PHP Fatal error:  Uncaught DateMalformedIntervalStringException: Unknown or bad format (PT2984722970400S) in /usr/local/emhttp/plugins/disklocation/pages/functions.php:651

 

Any ideas how to fix?

 

Full stack trace:

Stack trace:
#0 /usr/local/emhttp/plugins/disklocation/pages/functions.php(651): DateInterval->__construct('PT2984722970400...')
#1 /usr/local/emhttp/plugins/disklocation/pages/array_devices.php(91): seconds_to_time(2984722970400)
#2 /usr/local/emhttp/plugins/disklocation/pages/devices.php(36): require_once('/usr/local/emht...')
#3 /usr/local/emhttp/plugins/dynamix/include/DefaultPageLayout.php(778) : eval()'d code(16): require_once('/usr/local/emht...')
#4 /usr/local/emhttp/plugins/dynamix/include/DefaultPageLayout.php(778): eval()
#5 /usr/local/emhttp/plugins/dynamix/template.php(94): require_once('/usr/local/emht...')
#6 {main}
  thrown in /usr/local/emhttp/plugins/disklocation/pages/functions.php on line 651

 

Edited by smeehrrr

  • Author
On 4/22/2025 at 2:43 AM, smeehrrr said:

Upgraded to 7.0.1 today and also picked up the latest version of disklocation (2025.03.18).  Dashboard is failing to load now, PHP log is showing:

 

PHP Fatal error:  Uncaught DateMalformedIntervalStringException: Unknown or bad format (PT2984722970400S) in /usr/local/emhttp/plugins/disklocation/pages/functions.php:651

 

Any ideas how to fix?

 

Full stack trace:

Stack trace:
#0 /usr/local/emhttp/plugins/disklocation/pages/functions.php(651): DateInterval->__construct('PT2984722970400...')
#1 /usr/local/emhttp/plugins/disklocation/pages/array_devices.php(91): seconds_to_time(2984722970400)
#2 /usr/local/emhttp/plugins/disklocation/pages/devices.php(36): require_once('/usr/local/emht...')
#3 /usr/local/emhttp/plugins/dynamix/include/DefaultPageLayout.php(778) : eval()'d code(16): require_once('/usr/local/emht...')
#4 /usr/local/emhttp/plugins/dynamix/include/DefaultPageLayout.php(778): eval()
#5 /usr/local/emhttp/plugins/dynamix/template.php(94): require_once('/usr/local/emht...')
#6 {main}
  thrown in /usr/local/emhttp/plugins/disklocation/pages/functions.php on line 651

 

I don't know what is happening here, but is one of your drives reporting over 829089714 hours of power on time in SMART? That is roughly over 94000 years. As far as I know DateTime in PHP supports only year 0000-9999.

If you can identify this drive, please give me make and model, if it's on a RAID HW card or anything special involved. Is it passthrough from proxmox or anything like that, or running via some odd backplane. I'm not sure why it power on hours would be this high unless a specific drive shows different data in SMART.

 

You might run

cat /boot/config/plugins/disklocation/devices.json

 

To identify it, check for "poweronhours" with an unrealistic high value.

  • Author
On 4/16/2025 at 11:27 PM, Thx And Bye said:

I've just installed this plugin and it looks promising (apart from the default colors being nearly unreadable with the "Azure" theme, but that was quickly fixed by changing the colors to lighter ones)

The main issue I'm facing right now is that, after following the instructions on the dashboard and subsequently setting up the layout and assigning the disks, the dashboard just shows a Go to System and initialize a "Force SMART+DB" warning.
Executing this options has no effect on the warning though.

Screenshot2025-04-16at23_20_57.thumb.png.8a2a1bce76a1fe71402c7ad071d75e33.pngScreenshot2025-04-16at23_26_35.thumb.png.1f9d4463fff560bea07be2f591d4872b.png

Let me know if there is anything I can provide or if this is an easy fix.

The plugin also doesn't detect one of my NVMe drives. 11 drives total is correct, but under allocations there is only 10 options to select. /dev/nvme0n1p1 is detected as nvme0n1 but /dev/nvme1n1p1 isn't.

regards

 

Do you see any files under /tmp/disklocation ? If there's no files, then there might be a write permission issue (should typically not happen, a reboot might solve that as /tmp is recreated every boot)

 

You can check if the nvme drive was seen by the SMART+DB by typing in the terminal:

cat /tmp/disklocation/cron_smart.log

 

then check if it generated a file under smart:

ls /tmp/disklocation/smart/

Feel free to open the file and see if it has any real content (serial number and model name is the most important info)

 

You can manually just delete the disklocation temp folder and run "SMART+DB" again in case there's some corruption involved:

rm -rf /tmp/disklocation

 

 

If nothing above help, try to reset the devices under "System", scroll to the bottom, select "devices" and reset. Then do SMART+DB again.

Otherwise check for Disk Location contents in the PHP log under Unraid Tools. Debugging data might help me as well, but then you must enable debugging, run SMART+DB, disable debugging, then send the file to me, but this is the last thing you should do.

On 4/27/2025 at 3:18 PM, FlamongOle said:

You can check if the nvme drive was seen by the SMART+DB by typing in the terminal:

cat /tmp/disklocation/cron_smart.log
[2025-04-16 23:07:23] SMART: /dev/sg1             UNKNOWN  (1b7852b855)  done in 42ms.
[2025-04-16 23:07:24] SMART: /dev/sg0             UNKNOWN  (3f4304780f)  done in 226ms.
[2025-04-16 23:07:24] SMART: /dev/sg2             IDLE     (ee963138ac)  done in 576ms.
[2025-04-16 23:07:24] SMART: /dev/sg3             ACTIVE   (deb7fcf9fa)  done in 331ms.
[2025-04-16 23:07:25] SMART: /dev/sg4             ACTIVE   (fb5b981762)  done in 125ms.
[2025-04-16 23:07:25] SMART: /dev/sg5             ACTIVE   (626427ef2d)  done in 339ms.
[2025-04-16 23:07:25] SMART: /dev/sg6             ACTIVE   (e51311a5b7)  done in 109ms.
[2025-04-16 23:07:25] SMART: /dev/sg7             IDLE     (8b0e9492c0)  done in 203ms.
[2025-04-16 23:07:25] SMART: /dev/sg8             ACTIVE   (53d30157b3)  done in 97ms.
[2025-04-16 23:07:26] SMART: /dev/sg9             ACTIVE   (9c84f2f252)  done in 183ms.
[2025-04-16 23:07:26] SMART: /dev/nvme0n1         ACTIVE   (4a9eeecc90)  done in 75ms.
[2025-04-16 23:07:26] SMART: /dev/nvme1n1         ACTIVE   (1b7852b855)  done in 43ms.

Writing to the database... done in 2.7 seconds.

In this list both NVMe drives seem to be listed.

 

On 4/27/2025 at 3:18 PM, FlamongOle said:

then check if it generated a file under smart:

ls /tmp/disklocation/smart/

Feel free to open the file and see if it has any real content (serial number and model name is the most important info)

INTEL_SSDSC2CT060A3_CVMP213502QX060AGN.json     ST16000NM001G-2KK103_ZL2P97RS.json     TOSHIBA_MG08ACA16TE_13U0A059FVGG.json
KIOXIA-EXCERIA_G2_SSD_X2EB70WHKME5.json         ST4000VN008-2DR166_ZDHALT30.json       WDC__WDS200T1R0A-68A4W0_23292T800029.json
MKNSSDTS1TB-D8_MK23021714C44E8B3.json           ST4000VN008-2DR166_ZM40Y4EY.json       WDC__WUH721816ALE6L4_5EG2NW7P.json
SPCC_Solid_State_Disk_AA230217S302KG00435.json  TOSHIBA_MG08ACA16TE_13U0A058FVGG.json

 

For both NVMe drives the json file do contain valid data.

Should I proceed and remove the files or reset the devices? The RAM I have is ECC, so if it's corrupted I don't think it's related to the device itself.

Just in case it might be important: The NVMe drives are on a bifucation card in a single x8 PCIe slot.

Edited by Thx And Bye

  • Author
5 minutes ago, Thx And Bye said:
[2025-04-16 23:07:23] SMART: /dev/sg1             UNKNOWN  (1b7852b855)  done in 42ms.
[2025-04-16 23:07:24] SMART: /dev/sg0             UNKNOWN  (3f4304780f)  done in 226ms.
[2025-04-16 23:07:24] SMART: /dev/sg2             IDLE     (ee963138ac)  done in 576ms.
[2025-04-16 23:07:24] SMART: /dev/sg3             ACTIVE   (deb7fcf9fa)  done in 331ms.
[2025-04-16 23:07:25] SMART: /dev/sg4             ACTIVE   (fb5b981762)  done in 125ms.
[2025-04-16 23:07:25] SMART: /dev/sg5             ACTIVE   (626427ef2d)  done in 339ms.
[2025-04-16 23:07:25] SMART: /dev/sg6             ACTIVE   (e51311a5b7)  done in 109ms.
[2025-04-16 23:07:25] SMART: /dev/sg7             IDLE     (8b0e9492c0)  done in 203ms.
[2025-04-16 23:07:25] SMART: /dev/sg8             ACTIVE   (53d30157b3)  done in 97ms.
[2025-04-16 23:07:26] SMART: /dev/sg9             ACTIVE   (9c84f2f252)  done in 183ms.
[2025-04-16 23:07:26] SMART: /dev/nvme0n1         ACTIVE   (4a9eeecc90)  done in 75ms.
[2025-04-16 23:07:26] SMART: /dev/nvme1n1         ACTIVE   (1b7852b855)  done in 43ms.

Writing to the database... done in 2.7 seconds.

In this list both NVMe drives seem to be listed.

 

INTEL_SSDSC2CT060A3_CVMP213502QX060AGN.json     ST16000NM001G-2KK103_ZL2P97RS.json     TOSHIBA_MG08ACA16TE_13U0A059FVGG.json
KIOXIA-EXCERIA_G2_SSD_X2EB70WHKME5.json         ST4000VN008-2DR166_ZDHALT30.json       WDC__WDS200T1R0A-68A4W0_23292T800029.json
MKNSSDTS1TB-D8_MK23021714C44E8B3.json           ST4000VN008-2DR166_ZM40Y4EY.json       WDC__WUH721816ALE6L4_5EG2NW7P.json
SPCC_Solid_State_Disk_AA230217S302KG00435.json  TOSHIBA_MG08ACA16TE_13U0A058FVGG.json

 

For both NVMe drives the json file do contain valid data.

Should I proceed and remove the files or reset the devices? The RAM I have is ECC, so if it's corrupted I don't think it's related to the device itself.

 

Which of the drives (json file) is it?

 

Are there any PHP warnings/errors in the PHP log?

 

Can't hurt trying to refresh the temp directory as written earlier, but if it doesn't help, the PHP log might give any clues, otherwise I must get the debugging file later.

20 hours ago, FlamongOle said:

 

Which of the drives (json file) is it?

nvme1n1 is missing. That would be the MKNSSDTS1TB-D8_MK23021714C44E8B3.json (file attached)

 

 

20 hours ago, FlamongOle said:

Are there any PHP warnings/errors in the PHP log?

Sorry that I didn't check earlier there is this error in the log (but nothing on the 16th when I initially tried to setup the plugin):

[29-Apr-2025 00:00:01 Europe/Berlin] PHP Fatal error:  Uncaught TypeError: end(): Argument #1 ($array) must be of type array, false given in /usr/local/emhttp/plugins/disklocation/pages/page_system.php:414
Stack trace:
#0 /usr/local/emhttp/plugins/disklocation/pages/page_system.php(414): end(false)
#1 {main}
  thrown in /usr/local/emhttp/plugins/disklocation/pages/page_system.php on line 414

 

MKNSSDTS1TB-D8_MK23021714C44E8B3.json

On 4/27/2025 at 6:01 AM, FlamongOle said:

I don't know what is happening here, but is one of your drives reporting over 829089714 hours of power on time in SMART? That is roughly over 94000 years. As far as I know DateTime in PHP supports only year 0000-9999.

If you can identify this drive, please give me make and model, if it's on a RAID HW card or anything special involved. Is it passthrough from proxmox or anything like that, or running via some odd backplane. I'm not sure why it power on hours would be this high unless a specific drive shows different data in SMART.

 

Yes, devices.json has 829089714 as the powerontime for one drive. The model number is MB2000GCWDA which Google tells me is some HP refurb drive. It's hooked up to a Broadcom / LSI SAS2008 PCI-Express Fusion-MPT SAS-2 card.

 

Just for the hell of it, I went and edited that field in the json field to be something reasonable, and the dashboard came up. The power on hours I see reported in the SMART report in the dash for this drive is 27607, so maybe something just got out of whack with the json file? 

 

One additional data point: Running SMART + DB from the disklocation system tab once again read an incorrect value (a different one this time) and bricked the dashboard again. Editing devices.json fixed it this time too.

Edited by smeehrrr

  • Author
2 minutes ago, smeehrrr said:

Yes, devices.json has 829089714 as the powerontime for one drive. The model number is MB2000GCWDA which Google tells me is some HP refurb drive. It's hooked up to a Broadcom / LSI SAS2008 PCI-Express Fusion-MPT SAS-2 card.

 

Just for the hell of it, I went and edited that field in the json field to be something reasonable, and the dashboard came up. The power on hours I see reported in the SMART report in the dash for this drive is 27607, so maybe something just got out of whack with the json file? Anyway, looks like my bug is fixed for now.

But if you do a SMART+DB now, will it stay, or will it overwrite with 829089714 (or higher) again? And do you find that number somewhere in smartctl?

This might reveal it (skipping the two last digits):

smartctl /dev/sd(?) -x --all --json | grep "8290897"

 

  • Author
On 4/29/2025 at 7:32 PM, Thx And Bye said:

nvme1n1 is missing. That would be the MKNSSDTS1TB-D8_MK23021714C44E8B3.json (file attached)

 

 

Sorry that I didn't check earlier there is this error in the log (but nothing on the 16th when I initially tried to setup the plugin):

[29-Apr-2025 00:00:01 Europe/Berlin] PHP Fatal error:  Uncaught TypeError: end(): Argument #1 ($array) must be of type array, false given in /usr/local/emhttp/plugins/disklocation/pages/page_system.php:414
Stack trace:
#0 /usr/local/emhttp/plugins/disklocation/pages/page_system.php(414): end(false)
#1 {main}
  thrown in /usr/local/emhttp/plugins/disklocation/pages/page_system.php on line 414

 

MKNSSDTS1TB-D8_MK23021714C44E8B3.json 2.41 kB · 1 download

Alright, I think that error is irrelevant, but I will fix that sometime anyway. I can't really see what's going on here, so I might need the entire debug file from you:

Go to System, click Enable debugging, click SMART+DB, click Disable debugging (no page refresh in-between, as the debug file will just grow rapidly). Then download the file and send to me if you don't mind. Remember, serial numbers and comments etc. are included in the file (send as private message).

This error is strange and I can't see why it would not see it.

16 minutes ago, FlamongOle said:

But if you do a SMART+DB now, will it stay, or will it overwrite with 829089714 (or higher) again? And do you find that number somewhere in smartctl?

This might reveal it (skipping the two last digits):

smartctl /dev/sd(?) -x --all --json | grep "8290897"

 

 

"power_on_time": {
    "hours": 829093509
  },
 

So it's wrong but it's still increasing.

  • Author
20 minutes ago, smeehrrr said:

 

"power_on_time": {
    "hours": 829093509
  },
 

So it's wrong but it's still increasing.

Strange, what if you grep the other number 2760 or so?

 

Just wonder if there's any duplicate power on hours reported

29 minutes ago, FlamongOle said:

Strange, what if you grep the other number 2760 or so?

 

Just wonder if there's any duplicate power on hours reported

 

Here's the relevant sections from the .json.

 

    {
        "id": 9,
        "name": "Power_On_Hours",
        "value": 69,
        "worst": 69,
        "thresh": 0,
        "when_failed": "",
        "flags": {
          "value": 50,
          "string": "-O--CK ",
          "prefailure": false,
          "updated_online": true,
          "performance": false,
          "error_rate": false,
          "event_count": true,
          "auto_keep": true
        },
        "raw": {
          "value": 27607,
          "string": "27607"
        }
      },
...
  "power_on_time": {
    "hours": 829093510
  },

 

  • Author

Update 2025.05.01

  • Commit #414 - MINOR: Empty array error occurs when there's no backup made during auto backup. Creates a new backup if none is found. Should then make auto backups as expected.
  • Commit #413 - MINOR: Wrong Power On Hours might be picked up. In some instances the power_on_time could crash the Dashboard because the value was too high for DateTime.
     
On 4/30/2025 at 10:34 PM, FlamongOle said:

Go to System, click Enable debugging, click SMART+DB, click Disable debugging (no page refresh in-between, as the debug file will just grow rapidly). Then download the file and send to me if you don't mind. Remember, serial numbers and comments etc. are included in the file (send as private message).

This error is strange and I can't see why it would not see it.

 

I've just now fond the time to run the steps with debugging. I've reset devices first and then ran SMART+DB again with debugging enabled. I've send you the .log file via PM.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.