Unassigned Devices - Managing Disk Drives and Remote Shares Outside of The Unraid Array


Recommended Posts

I've been going through my mountain of retired hard drives and using the plugin to see what's on them, get what I need, if any, then zeroing them out.

 

I found a NTFS partitioned drive with the label "Server (IDE)". The label reported by the UNRAID OS is "Server\\x20\\x28IDE\\x29". After mounting & sharing with this plugin, the shared path is "Server_\134x28IDE\134x29" which is an invalid Windows network path due to the backslashes.

 

Fixed in the next release.

Link to comment

Is there a way to Mount, Run a Script and then un-mount from command line?

 

The reason I'm asking is I'd like to use a device that is connected, but currently not mounted and what I normally do is mount the device via this plugin, run a script which I guess I should just add it to this plugin. Then I normally un-mount. 

Link to comment

Is there a way to Mount, Run a Script and then un-mount from command line?

 

The reason I'm asking is I'd like to use a device that is connected, but currently not mounted and what I normally do is mount the device via this plugin, run a script which I guess I should just add it to this plugin. Then I normally un-mount.

 

/usr/local/sbin/rc.unassigned mount /dev/sdX

 

run script

 

/usr/local/sbin/rc.unassigned umount /dev/sdX

 

Link to comment

Ah..... I'll have to take a look at this. Thanks for the info

 

Why not just use UD?  You can set up a script and just click the mount button and the script will do what you want.  Add the un-mount at the end of the script and it will be automatically be unmounted.

 

Yes totally understand. Sometimes I do things that are automated so I don't forget like early in the AM. I have a little NAS drive Dlink-323 toaster style NAS that I have connected, but unmounted currently that I sometimes re-mount and run a few backups off the server. However I've forgotten now and then and well I figured if I could automate the process some I wouldn't have to worry about it.

 

I do plan on dropping in the script so when it is connected it just does what I need. Just looking for some more flexibility honestly. =)

The reason I keep it unmounted just incase your wondering is because I can swap out the drives now and then and run scripts based on which ever drive is installed.

Link to comment

Ah..... I'll have to take a look at this. Thanks for the info

 

Why not just use UD?  You can set up a script and just click the mount button and the script will do what you want.  Add the un-mount at the end of the script and it will be automatically be unmounted.

 

Yes totally understand. Sometimes I do things that are automated so I don't forget like early in the AM. I have a little NAS drive Dlink-323 toaster style NAS that I have connected, but unmounted currently that I sometimes re-mount and run a few backups off the server. However I've forgotten now and then and well I figured if I could automate the process some I wouldn't have to worry about it.

 

I do plan on dropping in the script so when it is connected it just does what I need. Just looking for some more flexibility honestly. =)

The reason I keep it unmounted just incase your wondering is because I can swap out the drives now and then and run scripts based on which ever drive is installed.

 

I understand.  I have a UD drive I leave mounted and use the User Scripts plugin to schedule a daily backup to the UD drive.

Link to comment

Does this still apply to a NAS drive? Meaning if I mount/unmount it wont run custom scripts? Or is that onlly for your code example?

 

If you mount and unmount the drive from the Unassigned Devices gui, the drive will mount and unmount but the script will not run because it has detected the 'OWNER' as 'user' and will skip the backup.

Link to comment

Does this still apply to a NAS drive? Meaning if I mount/unmount it wont run custom scripts? Or is that onlly for your code example?

 

If you mount and unmount the drive from the Unassigned Devices gui, the drive will mount and unmount but the script will not run because it has detected the 'OWNER' as 'user' and will skip the backup.

 

It's only my example.  Look at the default script and read about the parameter that can be used by the script to make decisions on whether the drive was plugged in or the mount button was clicked.

Link to comment

What's involved in getting drives mounted with the UD plugin to appear in the Disk Stats page?

 

That would involve work by bonienl to include the UD disks in the disk stats plugin.  You'll need to lobby him to see if he is interested, feels it adds value, and if he has the time.

Link to comment

I experience some trouble with the unassigned devices plugin.

 

I use it to get access to shares on 2 Qnap NASes.

 

But when these shares go off line the plugin slows down unraids GUI.

The plugin shows a spinning wheel on the webpage after it finally opens, which already takes fairly long.

 

Switching from Main to settings or docker or whatever tab takes several minutes, making the UI useless until UD gives up on the shares that are setup.

 

Is there a work around for this? Or can UD wait less longer for the shares to appear, say 1 minute?

Link to comment

I experience some trouble with the unassigned devices plugin.

 

I use it to get access to shares on 2 Qnap NASes.

 

But when these shares go off line the plugin slows down unraids GUI.

The plugin shows a spinning wheel on the webpage after it finally opens, which already takes fairly long.

 

Switching from Main to settings or docker or whatever tab takes several minutes, making the UI useless until UD gives up on the shares that are setup.

 

Is there a work around for this? Or can UD wait less longer for the shares to appear, say 1 minute?

 

Can you post a UD log when this happens?  Click on 'Help' and you'll see a 'Download' button at the bottom of the help to download the log.

Link to comment

I experience some trouble with the unassigned devices plugin.

 

I use it to get access to shares on 2 Qnap NASes.

 

But when these shares go off line the plugin slows down unraids GUI.

The plugin shows a spinning wheel on the webpage after it finally opens, which already takes fairly long.

 

Switching from Main to settings or docker or whatever tab takes several minutes, making the UI useless until UD gives up on the shares that are setup.

 

Is there a work around for this? Or can UD wait less longer for the shares to appear, say 1 minute?

 

It looks like UD is trying to calculate size and used/free space on a disconnected SMB or NFS share and probably taking a long time to fail out.  I added a check to see if the mount has disconnected and bypassing these calculations if it is.

 

I have a release ready to go today and I'll include this fix.  Let me know if it helps.

Link to comment

Updated to the latest 29a version. I'll see what happens later this evening when my NAS goes off line.

 

It was more involved than I thought.  It is related to doing a 'df' to get the size of the mounted device.  Doing a 'df' will hang if a device is offline.  I had to do 'df /dev/sdX', etc.  I only partially solved it in 29a.  I will be releasing a 29b today.

 

EDIT: 207.01.29b is available.

Link to comment

Updated to the latest 29a version. I'll see what happens later this evening when my NAS goes off line.

 

It was more involved than I thought.  It is related to doing a 'df' to get the size of the mounted device.  Doing a 'df' will hang if a device is offline.  I had to do 'df /dev/sdX', etc.  I only partially solved it in 29a.  I will be releasing a 29b today.

 

EDIT: 207.01.29b is available.

 

Much better already, the spiining wheel only appeared a few seconds and GUI is responsive immediately.

Link to comment

The latest version has smb and nfs indicators next to the 'Share' text in the device header to show the share setting in the Settings->Unassigned Devices for the smb and nfs shares.  Hopefully this will help people know whether or not setting the share switch will actually share anything and the share protocol being used.

Link to comment

So i think i am doing something wrong. I have read through the form but must be missing something. I am trying to use UD on UnRaid in order to use it with Plex to connect to an old NAS that i am trying to off load. I have installed both UD and Plex and have created a SMB share using UD (Movies = \\OldNas\Movies. It creates /mnt/Disks/OldNas_Movies. I then go into Plex and make a path to point /Movies to /mnt/Disks/OldNas_Movies. I go into the Plex web UI and add that path to my Movies library and nothing shows up? Did i miss something? Using UnRaid 6.2.4 with the LinuxServer community Plex Docker.

Link to comment

So i think i am doing something wrong. I have read through the form but must be missing something. I am trying to use UD on UnRaid in order to use it with Plex to connect to an old NAS that i am trying to off load. I have installed both UD and Plex and have created a SMB share using UD (Movies = \\OldNas\Movies. It creates /mnt/Disks/OldNas_Movies. I then go into Plex and make a path to point /Movies to /mnt/Disks/OldNas_Movies. I go into the Plex web UI and add that path to my Movies library and nothing shows up? Did i miss something? Using UnRaid 6.2.4 with the LinuxServer community Plex Docker.

 

Can you browse the smb share through UD?

Link to comment
  • trurl pinned this topic

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.