Server Layout Plugin for unRAID v6


Recommended Posts

Hello,

 

I am proud to present:

Server Layout plugin for unRAID v6

 

The Server Layout plugin enables you to view the devices (HDDs, CD/DVD ROMS) in a physical manner.

You can configure the server’s disk tray layout, assign each storage device to a drive tray and enter additional data manually (Purchase Date, etc…)

 

To install under unRAID v6:

1. In the unRAID Plugin Manager under "Install Plugin" tab enter link https://raw.githubusercontent.com/theone11/serverlayout_plugin/master/serverlayout.plg

2. Wait for installation to complete.

3. Go to plugin WEGUI and change initial settings

 

To update the plugin:

* For WEBUI and functionality updates - Use the unRAID Plugin Manager

 

The WEBUI is divided into 4 parts/tabs:

1. Layout:

  - Shows the Server Layout as was configured in the Settings tab.

2. Data:

  - Shows the Server Data (Installed and Historical) and allows adding and editing of manual data.

  - Preview the drive tray assignments.

3. Settings:

  - Configure Server Layout (Rows/Comlumns) and Drive orientation (Horizontal/Vertical).

  - Configure which fields should be shown per drive on the Layout tab and data field columns in Data tab.

4. Report:

  - Show raw data for all devices (current and historical).

 

Notes:

* Changing the Rows and/or Columns will reset the hidden trays and reset tray assignments for all installed devices but keep other data

 

Please comment on any problems encountered and any enhancements or missing features, that you would like added.

(In this thread or here: https://github.com/theone11/serverlayout_plugin/issues)

 

 

Initial Configuration steps:

1. Go to "Settings" tab

2. Enable the layout editing checkbox

3. Define your server's physical layout - Rows, Columns and Disk Trays' Orientation

4. Save the configuration (button)

 

5. Go to "Data" tab

6. Enable the data editing checkbox

7. For each device you have select the appropriate Disk Tray # - You can see a preview of the server layout

8. Enter any other data you wish (currently only purchase date is available)

9. Save the data (button)

 

10. Go to "Layout" tab and see the result :)

 

11. You can further configure the view settings in the "Settings" tab under "Data View Settings" table

 

Enjoy the plugin :)

 

 

Open Issues:

 

* Tooltip is not displayed in the correct location in FF and MSIE browsers.

 

Changelog:

 

2018.03.09

- Update for unRAID v6.5 RC - Strict PHP regarding non-quoted constant - Thank you Squid

 

2018.01.25
- Updated for unRAID v6.4 - Thank you Squid
2017.03.03
- Added TRAY_NUM to HISTORICAL data - If drives fails you can see in which tray it was last seen
- Added debug option - Time Profiling for data gathering performance analysis and future optimizations

- Fixed support for ARECA controllers

2015.09.25

- Added support for ARECA controllers

2015.09.22

- Fixed USB location in "Layout" tab when trays are configured as Vertical and the array is "narrow"

- Removed all duration other than hours in Power-On-Hours

- Added support for SCSI (SAS) drives

2015.06.15

- Fixed indexing of tooltip table CSS

- Added triangle/arrow to the Tooltip frame

- Added USB devices on "Layout" tab - see here

2015.06.12

- Added device status icon (same as unRAID icons) - see here

- Added option to delete historical devices (per device) from database under "Historical Device" table - see here

2015.06.11

- Remove EMPTY row and columns pull-down options in Layout Settings

- HW scan speed optimization - Changed USB path from "lsusb" to "lsscsi -t"

- HW scan speed optimization - Changed USB data gathering from "lsusb -D" to "udevadm" so I can scan only USB storage devices

2015.06.08-2

- Fixed bug - introduced by new parameter array "TRAY_SHOW"

- Fixed bug - introduced by new parameter array "GENERAL"

2015.06.08

- Added support for HIDDEN TRAYS - click on preview tray to show/hide it - don't forget to save settings - see here

- Increased number of maximum trays to 99 (from 26) - Supports better usage of HIDDEN TRAYS

- Removed "User Utilities" icon - part of unRAID v6 RC4

- Add Enable/Disable for Tooltips

- Fixed "UNRAID" functionality recognition for USB devices

2015.06.01

- Added transform (rotation and translate) support for other browsers (-webkit, -ms)

- Added Tooltip Disk information for each tray on "Layout" tab and settings for each field in "Settings" tab - see here

- Compacted data and settings tables rows

- Added "User Utilities" icon

2015.05.31

- Moved plugin to "Settings" --> "User Utilities" on unrAID WEBUI

- Added "Set All" and "Clear All" buttons for each field view setting columns in "Settings" tab

2015.05.30

- Removed PATH change clears TRAY_NUM assignment

- Allow editing of FIRST_INSTALL_DATE

- Add POWER_ON_HOURS for HDDs

- Add START_STOP_COUNT for HDDs

- Add NOTES field

2015.05.28-3

- Changed "packageVER" to be same as "version"

- Changed "launch" to be dependent on "name" of plugin

- Added button on "Data" tab for updating Smartmontools database

- Added "Report" tab

- Fix: New disk scraped data was not being saved

2015.05.28-2

- Changed EOL from Windows to Unix

- Add launch option for the Plugin Manager

- Removed icon references from .page files

- Removed "---" from main .page file (remove empty tab)

2015.05.28-1

- Replaced "-sata" with "-ata" when searching drives[/b]

2015.05.28

- Initial Release

Icon.gif.cecadcc55159e503dde910ff212ac6b1.gif

Layout.gif.396e5ba6f013b632be19561e5336fbc2.gif

Data.gif.c1f4f6113dbca50f203939f9e8fc97ed.gif

Settings.gif.de10699e0cd90673e7f20452eafe510f.gif

Edited by theone
  • Upvote 2
Link to comment

Am I doing something wrong?

 

Under Data, the only device that I see is my thumbdrive.  None of the hard drives are populating into it.

 

I too can only see my thumb drive and one USB drive that I am testing with the Unassigned Devices plugin. This plugin shows promise, but also it would be nice if it could be configured with some different case layouts such as LimeTech's own AVS 10/4, which is the case that I am using.

Link to comment

Am I doing something wrong?

 

Under Data, the only device that I see is my thumbdrive.  None of the hard drives are populating into it.

 

What does

 

ls -las /dev/disk/by-id

 

show?

 

The disk list is built out of those devices that start with sata- (and don't contain -part).

 

If your devices began ata- for example, they wouldn't be found..

 

Link to comment

Am I doing something wrong?

 

Under Data, the only device that I see is my thumbdrive.  None of the hard drives are populating into it.

 

What does

 

ls -las /dev/disk/by-id

 

show?

 

The disk list is built out of those devices that start with sata- (and don't contain -part).

 

If your devices began ata- for example, they wouldn't be found..

 

 

 

Why are ata devices being skipped?

 

 

Mine are all SATA devices (in a SAS Expander Tower)

Link to comment

Mine is also only seeing my flash drive

 

my layout tab also goes out past the header on the right side - so scree is lopsided.....

 

root@Tower:~# ls -las /dev/disk/by-id
total 0
0 drwxr-xr-x 2 root root 1520 May 21 00:50 ./
0 drwxr-xr-x 7 root root  140 May 21 00:50 ../
0 lrwxrwxrwx 1 root root    9 May 21 00:51 ata-Crucial_CT240M500SSD1_1332095464B2 -> ../../sdb
0 lrwxrwxrwx 1 root root   10 May 21 00:51 ata-Crucial_CT240M500SSD1_1332095464B2-part1 -> ../../sdb1
0 lrwxrwxrwx 1 root root    9 May 21 00:51 ata-HDS725050KLA360_KRVN6CZBHVS5AL -> ../../sdc
0 lrwxrwxrwx 1 root root   10 May 21 00:51 ata-HDS725050KLA360_KRVN6CZBHVS5AL-part1 -> ../../sdc1
0 lrwxrwxrwx 1 root root    9 May 21 00:51 ata-Hitachi_HDS5C3020ALA632_ML2220F32S5M4E -> ../../sdn
0 lrwxrwxrwx 1 root root   10 May 21 00:51 ata-Hitachi_HDS5C3020ALA632_ML2220F32S5M4E-part1 -> ../../sdn1
0 lrwxrwxrwx 1 root root    9 May 21 00:51 ata-SAMSUNG_HD203WI_S1UYJ1KSC00985 -> ../../sdr
0 lrwxrwxrwx 1 root root   10 May 21 00:51 ata-SAMSUNG_HD203WI_S1UYJ1KSC00985-part1 -> ../../sdr1
0 lrwxrwxrwx 1 root root    9 May 21 00:51 ata-SAMSUNG_HD203WI_S1UYJ1KSC00987 -> ../../sde
0 lrwxrwxrwx 1 root root   10 May 21 00:51 ata-SAMSUNG_HD203WI_S1UYJ1KSC00987-part1 -> ../../sde1
0 lrwxrwxrwx 1 root root    9 May 21 00:51 ata-ST1000DM000-9TS15E_5YA00H6T -> ../../sdo
0 lrwxrwxrwx 1 root root   10 May 21 00:51 ata-ST1000DM000-9TS15E_5YA00H6T-part1 -> ../../sdo1
0 lrwxrwxrwx 1 root root    9 May 21 00:51 ata-ST2000DL003-9VT166_5YD741R0 -> ../../sdq
0 lrwxrwxrwx 1 root root   10 May 21 00:51 ata-ST2000DL003-9VT166_5YD741R0-part1 -> ../../sdq1
0 lrwxrwxrwx 1 root root    9 May 21 00:51 ata-ST2000DL003-9VT166_5YD88DSE -> ../../sdd
0 lrwxrwxrwx 1 root root   10 May 21 00:51 ata-ST2000DL003-9VT166_5YD88DSE-part1 -> ../../sdd1
0 lrwxrwxrwx 1 root root    9 May 21 00:51 ata-ST2000NM0011_Z1P01RAB -> ../../sdm
0 lrwxrwxrwx 1 root root   10 May 21 00:51 ata-ST2000NM0011_Z1P01RAB-part1 -> ../../sdm1
0 lrwxrwxrwx 1 root root    9 May 21 00:51 ata-ST3000DM001-1CH166_Z1F3RTF7 -> ../../sds
0 lrwxrwxrwx 1 root root   10 May 21 00:51 ata-ST3000DM001-1CH166_Z1F3RTF7-part1 -> ../../sds1
0 lrwxrwxrwx 1 root root    9 May 21 00:51 ata-ST3000DM001-1CH166_Z1F3RTLP -> ../../sdj
0 lrwxrwxrwx 1 root root   10 May 21 00:51 ata-ST3000DM001-1CH166_Z1F3RTLP-part1 -> ../../sdj1
0 lrwxrwxrwx 1 root root    9 May 21 00:51 ata-ST3000DM001-1CH166_Z1F3TQ81 -> ../../sdh
0 lrwxrwxrwx 1 root root   10 May 21 00:51 ata-ST3000DM001-1CH166_Z1F3TQ81-part1 -> ../../sdh1
0 lrwxrwxrwx 1 root root    9 May 21 00:51 ata-ST3000DM001-9YN166_S1F0JW3Z -> ../../sdg
0 lrwxrwxrwx 1 root root   10 May 21 00:51 ata-ST3000DM001-9YN166_S1F0JW3Z-part1 -> ../../sdg1
0 lrwxrwxrwx 1 root root    9 May 21 00:51 ata-ST3000DM001-9YN166_Z1F18VA2 -> ../../sdp
0 lrwxrwxrwx 1 root root   10 May 21 00:51 ata-ST3000DM001-9YN166_Z1F18VA2-part1 -> ../../sdp1
0 lrwxrwxrwx 1 root root    9 May 21 00:51 ata-ST31000524AS_5VP8KR1W -> ../../sdk
0 lrwxrwxrwx 1 root root   10 May 21 00:51 ata-ST31000524AS_5VP8KR1W-part1 -> ../../sdk1
0 lrwxrwxrwx 1 root root    9 May 21 00:51 ata-ST4000DM000-1F2168_W3008YF1 -> ../../sdl
0 lrwxrwxrwx 1 root root   10 May 21 00:51 ata-ST4000DM000-1F2168_W3008YF1-part1 -> ../../sdl1
0 lrwxrwxrwx 1 root root    9 May 21 00:51 ata-WDC_WD30EZRX-00DC0B0_WD-WMC1T0371321 -> ../../sdi
0 lrwxrwxrwx 1 root root   10 May 21 00:51 ata-WDC_WD30EZRX-00DC0B0_WD-WMC1T0371321-part1 -> ../../sdi1
0 lrwxrwxrwx 1 root root    9 May 21 00:51 ata-WL2000GSA6472C_WOL240221877 -> ../../sdf
0 lrwxrwxrwx 1 root root   10 May 21 00:51 ata-WL2000GSA6472C_WOL240221877-part1 -> ../../sdf1
0 lrwxrwxrwx 1 root root    9 May 27 22:11 usb-Generic_Flash_Disk_1177DBEF-0:0 -> ../../sda
0 lrwxrwxrwx 1 root root   10 May 21 00:51 usb-Generic_Flash_Disk_1177DBEF-0:0-part1 -> ../../sda1
0 lrwxrwxrwx 1 root root    9 May 21 00:51 wwn-0x5000c5002a40de1c -> ../../sdk
0 lrwxrwxrwx 1 root root   10 May 21 00:51 wwn-0x5000c5002a40de1c-part1 -> ../../sdk1
0 lrwxrwxrwx 1 root root    9 May 21 00:51 wwn-0x5000c5002e98b8f3 -> ../../sdo
0 lrwxrwxrwx 1 root root   10 May 21 00:51 wwn-0x5000c5002e98b8f3-part1 -> ../../sdo1
0 lrwxrwxrwx 1 root root    9 May 21 00:51 wwn-0x5000c5003527f2b0 -> ../../sdm
0 lrwxrwxrwx 1 root root   10 May 21 00:51 wwn-0x5000c5003527f2b0-part1 -> ../../sdm1
0 lrwxrwxrwx 1 root root    9 May 21 00:51 wwn-0x5000c50044d89f5d -> ../../sdq
0 lrwxrwxrwx 1 root root   10 May 21 00:51 wwn-0x5000c50044d89f5d-part1 -> ../../sdq1
0 lrwxrwxrwx 1 root root    9 May 21 00:51 wwn-0x5000c50048f8223a -> ../../sdd
0 lrwxrwxrwx 1 root root   10 May 21 00:51 wwn-0x5000c50048f8223a-part1 -> ../../sdd1
0 lrwxrwxrwx 1 root root    9 May 21 00:51 wwn-0x5000c5004e62eb4d -> ../../sdp
0 lrwxrwxrwx 1 root root   10 May 21 00:51 wwn-0x5000c5004e62eb4d-part1 -> ../../sdp1
0 lrwxrwxrwx 1 root root    9 May 21 00:51 wwn-0x5000c50051043f1e -> ../../sdg
0 lrwxrwxrwx 1 root root   10 May 21 00:51 wwn-0x5000c50051043f1e-part1 -> ../../sdg1
0 lrwxrwxrwx 1 root root    9 May 21 00:51 wwn-0x5000c500608668f3 -> ../../sdl
0 lrwxrwxrwx 1 root root   10 May 21 00:51 wwn-0x5000c500608668f3-part1 -> ../../sdl1
0 lrwxrwxrwx 1 root root    9 May 21 00:51 wwn-0x5000c50064cf92c8 -> ../../sdj
0 lrwxrwxrwx 1 root root   10 May 21 00:51 wwn-0x5000c50064cf92c8-part1 -> ../../sdj1
0 lrwxrwxrwx 1 root root    9 May 21 00:51 wwn-0x5000c50064cf9d99 -> ../../sds
0 lrwxrwxrwx 1 root root   10 May 21 00:51 wwn-0x5000c50064cf9d99-part1 -> ../../sds1
0 lrwxrwxrwx 1 root root    9 May 21 00:51 wwn-0x5000c50064db298e -> ../../sdh
0 lrwxrwxrwx 1 root root   10 May 21 00:51 wwn-0x5000c50064db298e-part1 -> ../../sdh1
0 lrwxrwxrwx 1 root root    9 May 21 00:51 wwn-0x5000cca20eda4023 -> ../../sdc
0 lrwxrwxrwx 1 root root   10 May 21 00:51 wwn-0x5000cca20eda4023-part1 -> ../../sdc1
0 lrwxrwxrwx 1 root root    9 May 21 00:51 wwn-0x5000cca369e6b8a1 -> ../../sdn
0 lrwxrwxrwx 1 root root   10 May 21 00:51 wwn-0x5000cca369e6b8a1-part1 -> ../../sdn1
0 lrwxrwxrwx 1 root root    9 May 21 00:51 wwn-0x50014ee002c420c2 -> ../../sdf
0 lrwxrwxrwx 1 root root   10 May 21 00:51 wwn-0x50014ee002c420c2-part1 -> ../../sdf1
0 lrwxrwxrwx 1 root root    9 May 21 00:51 wwn-0x50014ee0ae15cb6b -> ../../sdi
0 lrwxrwxrwx 1 root root   10 May 21 00:51 wwn-0x50014ee0ae15cb6b-part1 -> ../../sdi1
0 lrwxrwxrwx 1 root root    9 May 21 00:51 wwn-0x50024e900293f54c -> ../../sdr
0 lrwxrwxrwx 1 root root   10 May 21 00:51 wwn-0x50024e900293f54c-part1 -> ../../sdr1
0 lrwxrwxrwx 1 root root    9 May 21 00:51 wwn-0x50024e900293f558 -> ../../sde
0 lrwxrwxrwx 1 root root   10 May 21 00:51 wwn-0x50024e900293f558-part1 -> ../../sde1
0 lrwxrwxrwx 1 root root    9 May 21 00:51 wwn-0x500a0751095464b2 -> ../../sdb
0 lrwxrwxrwx 1 root root   10 May 21 00:51 wwn-0x500a0751095464b2-part1 -> ../../sdb1

Link to comment

Am I doing something wrong?

 

Under Data, the only device that I see is my thumbdrive.  None of the hard drives are populating into it.

 

What does

 

ls -las /dev/disk/by-id

 

show?

 

The disk list is built out of those devices that start with sata- (and don't contain -part).

 

If your devices began ata- for example, they wouldn't be found..

 

 

 

Why are ata devices being skipped?

 

 

Mine are all SATA devices (in a SAS Expander Tower)

 

theone - all SATA devices show as "ata" device when you run the command:

 

ls -las /dev/disk/by-id

 

You need to updated the code in your /usr/local/emhttp/plugins/serverlayout/php/serverlayout_constants.php file on line 198 from "sata-" to "ata-". As a test I did that on my server and now all of my drives are now showing up and I am able to assign them to the layout.

Link to comment

I will fix the -ata -sata issue.

 

Funny thing is that I tested it using -ata (but it was under a VirtualBox unRAID and I thought that it was a Virtualbox issue because under unRAID v5 they appear as -sata.

I do not have a v6 "real" server yet.

 

MyKroFt,

don't you have a scroll bar? please post screenshot

You can disable some of the columns undet "settings"

 

 

 

It would be nice to get screenshots of anyone who is willing on posting it (you can disable the serial number column display if you don't want to expose it on the forum)

 

 

Link to comment

any option that would be nice, is a report tab with a plain text listing everything for a nice printout etc

 

Thanks for the plugin!

 

Myk

 

Added to request list (1st request  :))

 

When you change either the Row or Column parameters the tray assignments are cleared (all other manually entered data should be kept - currently only purchase date)

It is stated in the OP.

 

The assignments are cleared because the tray numbering changes and the previous numbers have no meaning.

 

 

Link to comment

Released update:

 

2015.05.28-1 - Replaced "-sata" with "-ata" when searching drives

 

Good job!

 

Can I ask for one change and one addition !?

 

Change - file format of your *.page and *.php to linux instead of windows

Add - option to reverse the numbering. I have a stack of 12 disks with disk 1 at the bottom and 12 at the top.

 

Thanks.

 

Link to comment

Good job!

 

Can I ask for one change and one addition !?

 

Change - file format of your *.page and *.php to linux instead of windows

Add - option to reverse the numbering. I have a stack of 12 disks with disk 1 at the bottom and 12 at the top.

 

Thanks.

 

Regarding the "Change" - I will fix this - this sometimes happens when I work with Github (windows) - annoying  :(

 

Regarding the "Option" - Please explain - numbering of what?

I plan on adding in the near future the ability to sort the table by pressing the table headers or another way.

 

Link to comment

With numbering I mean the numbers of the slot positions, see attached picture. In real situation - for me - slot (tray) 1 is at the bottom.

 

Some other things for your consideration:

 

1. In the PLG file you can add a "launch" entity which adds a direct link to the Server Layout image on the plugins page to settings page. Like this:

 

<!ENTITY version    "2015.05.28-1">

<!ENTITY launch      "Settings/serverlayout">

<!ENTITY pluginURL  "https://raw.githubusercontent.com/theone11/serverlayout_plugin/master/&name;.plg">

...

...

<PLUGIN  name="&name;"

        author="&author;"

        version="&version;"

        launch="&launch;"

        pluginURL="&pluginURL;"

>

 

2. In the data, layout and settings pages you don't need to specify the icon file. The name is automatically generated based on the title of the page (small error: Settings.png -> settings.png)

 

3. Remove the "---" and lower part in the "serverlayout.page" file, this will prevent it from being displayed as a tab as well.

 

Thanks again for your plugin.

stack-numbering.png.dfc8f8b1463a4e58d473bc5baed49d31.png

Link to comment

I removed the plugin, removed the setting folder, rebooted, reinstalled plugin and am still getting blank pages for all 3 tabs.  Page is rendering, as I have footer at the bottom....

 

Ideas?

 

Myk

 

I needed to change the file format from 'windows' to 'linux' to make it work.

 

Also the "Server Layout" page causes an empty tab to be displayed first, this can be corrected by suggestion 3 I gave in my previous answer.

 

Link to comment

With numbering I mean the numbers of the slot positions, see attached picture. In real situation - for me - slot (tray) 1 is at the bottom.

 

The numbering is just for reference so when you choose the tray number you can see on the preview table which slot it means.

I could change the tray numbers to X,Y axis parameters (Row/Column).

 

1. In the PLG file you can add a "launch" entity which adds a direct link to the Server Layout image on the plugins page to settings page. Like this:

 

<!ENTITY version    "2015.05.28-1">

<!ENTITY launch      "Settings/serverlayout">

<!ENTITY pluginURL  "https://raw.githubusercontent.com/theone11/serverlayout_plugin/master/&name;.plg">

...

...

<PLUGIN  name="&name;"

        author="&author;"

        version="&version;"

        launch="&launch;"

        pluginURL="&pluginURL;"

>

 

Will do.

 

2. In the data, layout and settings pages you don't need to specify the icon file. The name is automatically generated based on the title of the page (small error: Settings.png -> settings.png)

 

I will check it

 

3. Remove the "---" and lower part in the "serverlayout.page" file, this will prevent it from being displayed as a tab as well.

 

I don't have this problem - weird...

I will remove anyway.

 

Thanks for your inputs

 

Link to comment

Maybe we can have arbitrary groups of disks? I have an external SAS enclosure and a few disks inside the case.

A 2 column layout is wrong since the number of disks are not the same.

 

 

Just a guess.

Probably allow the user to mark the disks as SATA/ATA/etc.

 

 

Odd that WD Reds of 4GB and higher are not in the smartctl db as of v6rc3

 

 

Link to comment

Maybe we can have arbitrary groups of disks? I have an external SAS enclosure and a few disks inside the case.

A 2 column layout is wrong since the number of disks are not the same.

 

Will look into it for future versions

 

Just a guess.

Probably allow the user to mark the disks as SATA/ATA/etc.

 

Why is this needed? What is wrong with automatic detection?

 

Odd that WD Reds of 4GB and higher are not in the smartctl db as of v6rc3

 

If you run lsscsi what do you get?

 

Link to comment

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...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.