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


Recommended Posts

Attached.

 

Errors in Windows 10 are consistent now but Mac is fine. Strange.

 

The "Windows" is actually Parallels VM.

I thought that might affect it but the same VM writes to standard unRAID shares without issue.

 

In case it's helpful:

# smbstatus

Samba version 4.17.5
PID     Username     Group        Machine                                   Protocol Version  Encryption           Signing              
----------------------------------------------------------------------------------------------------------------------------------------
15540   windows      users        10.0.1.3 (ipv4:10.0.1.3:49285)            SMB3_11           -                    partial(AES-128-CMAC)

Service      pid     Machine       Connected at                     Encryption   Signing     
---------------------------------------------------------------------------------------------
file_history 15540   10.0.1.3      Mon Mar 27 03:08:49 PM 2023 EDT  -            -           


Locked files:
Pid          User(ID)   DenyMode   Access      R/W        Oplock           SharePath   Name   Time
--------------------------------------------------------------------------------------------------
15540        99         DENY_NONE  0x100081    RDONLY     NONE             /mnt/disks/file_history   .   Mon Mar 27 15:08:49 2023

 

nas-diagnostics-20230327-1510.zip

Link to comment

Done. I'm getting strange results. It works except for a handful of files which always error out. If I skip them it copies fine. And they copy fine to a standard unraid share. I checked their permissions, etc, no issues.

 

These files might have thrown off my earlier reports of what was or wasn't working.

 

I think you've caught the major issue though, some conflict with the "MacOS interoperability" setting. Thanks for helping me solve it.

Link to comment

I have a share I need to mount using SMB v1.0. 

 

I can see under Settings->Unassigned Devices that I can set the option to specify the SMB version to Yes, but I cannot see where I set the actual version.   Is this just me being blind :(  I have tested with a manual mount from the Command line to check that the mount works if I specify v1.0.

Link to comment
3 minutes ago, itimpi said:

I have a share I need to mount using SMB v1.0. 

 

I can see under Settings->Unassigned Devices that I can set the option to specify the SMB version to Yes, but I cannot see where I set the actual version.   Is this just me being blind :(  I have tested with a manual mount from the Command line to check that the mount works if I specify v1.0.

UD will mount the remote share with the highest protocol the remote server will support.  It does a sequence of mounts starting at 3.X, then 2.X, then 1.X until the remote share mounts.  Just try to mount the remote share with UD,  It should mount it.  You have to have NetBIOS enabled to mount with SMB v1.0.

 

The "Specify SMB Version when Mounting Remote Shares?" setting when set to "No" will tell UD to mount the device on the first try without specifying a version.  Newer servers will mount the share with the hghest protocol it can support.  Legacy servers do not mount this way and the version needs to be speficied.  The "Yes" setting tellls UD to specify the version when it sequences through mount attempts on the remote share.

Link to comment
4 minutes ago, dlandon said:

UD will mount the remote share with the highest protocol the remote server will support.  It does a sequence of mounts starting at 3.X, then 2.X, then 1.X until the remote share mounts.  Just try to mount the remote share with UD,  It should mount it.  You have to have NetBIOS enabled to mount with SMB v1.0.

 

The "Specify SMB Version when Mounting Remote Shares?" setting when set to "No" will tell UD to mount the device on the first try without specifying a version.  Newer servers will mount the share with the hghest protocol it can support.  Legacy servers do not mount this way and the version needs to be speficied.  The "Yes" setting tellls UD to specify the version when it sequences through mount attempts on the remote share.

Ok - I need to set NetBios support at the Unraid level?   This is not at all obvious from the UD message in the syslog, and it is still not obvious why I need to enable netBios locally (which I would rather not do) when it is only the remote system that is demanding SMB v1.0.    I was expecting to see it as something I could specify for a particular remote mount.

 

Link to comment
17 minutes ago, itimpi said:

Ok - I need to set NetBios support at the Unraid level?

I just reviewed the UD code and see that I only mount a SMB v1.0 remote share when NetBIOS is enabled.  NetBIOS does not have to be enabled to mount a remote share with SMB v1.0.  It does have to be enabled for a remote server to mount a share with SMB v1.0.  The next release of UD will fix this.

Screenshot 2023-03-28 080842.png

Link to comment
8 minutes ago, dlandon said:

I just reviewed the UD code and see that I only mount a SMB v1.0 remote share when NetBIOS is enabled.  NetBIOS does not have to be enabled to mount a remote share with SMB v1.0.  It does have to be enabled for a remote server to mount a share with SMB v1.0.  The next release of UD will fix this.

Screenshot 2023-03-28 080842.png

It sounds like that will give the behaviour I was expecting.    Thanks.

Link to comment

Hi there. I assume that this is the best part of the forum to post this, but apologies if not.

I use UD to trigger a backup script when I plugin one of two USB hard drives. One I plug in every week, and another I do sporadically.

Every so often when I connect a disk and it kicks off the script, it begins to instead copy EVERYTHING.

It happened again yesterday when I plugged in the sporadic hard drive, so I cancelled the script through the UI's "Abort" button, but it seemed that rsync kept running - not knowing what else to do I rebooted the server, forcing a parity check on reboot 🙄

Today I ran my weekly backup and it ran fine. But then I plugged in the sporadic disk again, and it picked up where it left off yesterday, and continues to copy over everything. So that's about 1.5TB to be copied, which not only takes forever, but makes the disk get hot hot hot, so this is not ideal.

Any idea why this could be happening? Could it somehow (though I don't see how) be related to daylight savings starting last Sunday, and this being the first time I've attached the disk since then? (FWIW, the server time updated automatically, and I don't use the disk on any other machine, so I don't see how... but worth pondering). Or is there something silly in my script?

 

The script that fires is as follows (I nabbed from either this forum or somewhere else on the internet - apologies to the original author):

#!/bin/bash
PATH=/usr/local/sbin:/usr/sbin:/sbin:/usr/local/bin:/usr/bin:/bin
PATH=/usr/local/sbin:/usr/sbin:/sbin:/usr/local/bin:/usr/bin:/bin
## Available variables:
# ACTION     : if mounting, ADD; if unmounting, UNMOUNT; if unmounted, REMOVE; if error, ERROR_MOUNT, ERROR_UNMOUNT
# DEVICE     : partition device, e.g /dev/sda1
# SERIAL     : disk serial number
# LABEL      : partition label
# FSTYPE     : partition filesystem
# MOUNTPOINT : where the partition is mounted
# OWNER      : "udev" if executed by UDEV, otherwise "user"
# PROG_NAME  : program name of this script
# LOGFILE    : log file for this script

case $ACTION in
  'ADD' )
    #
    # Beep that the device is plugged in.
    #
    beep  -l 200 -f 600 -n -l 200 -f 800
    sleep 2

    if mountpoint -q $MOUNTPOINT; then
      if [ $OWNER = "udev" ]
      then
        beep  -l 100 -f 2000 -n -l 150 -f 3000
        beep  -l 100 -f 2000 -n -l 150 -f 3000

        logger Started -t$PROG_NAME
        echo "Started: `date`" > $LOGFILE

        logger MyMusic share -t$PROG_NAME
        echo "MyMusic share" >> $LOGFILE
        rsync -vrltD --delete --exclude '.Recycle.Bin' /mnt/user/mymusic $MOUNTPOINT 2>&1 >> $LOGFILE

        logger Syncing -t$PROG_NAME
        sync -f $MOUNTPOINT

        beep  -l 100 -f 2000 -n -l 150 -f 3000
        beep  -l 100 -f 2000 -n -l 150 -f 3000
        beep  -r 5 -l 100 -f 2000

        logger Unmounting ExtBackup -t$PROG_NAME
        /usr/local/sbin/rc.unassigned umount $DEVICE

       echo "Completed: `date`" >> $LOGFILE
        logger Music Backup drive can be removed -t$PROG_NAME

        /usr/local/emhttp/webGui/scripts/notify -e "Unraid Server Notice" -s "Server Backup" -d "Music Backup completed" -i "normal"
    fi
    else
        logger Music Backup Drive Not Mounted -t$PROG_NAME
  fi
  ;;

  'REMOVE' )
    #
    # Beep that the device is unmounted.
    #
    beep  -l 200 -f 800 -n -l 200 -f 600
  ;;

  'ERROR_MOUNT' )
	/usr/local/emhttp/webGui/scripts/notify -e "Unraid Server Notice" -s "Server Backup" -d "Could not mount Music Backup" -i "normal"
  ;;

  'ERROR_UNMOUNT' )
	/usr/local/emhttp/webGui/scripts/notify -e "Unraid Server Notice" -s "Server Backup" -d "Could not unmount Music Backup" -i "normal"
  ;;
esac

 

Thanks for your help!

Link to comment

I installed a 2TB SSD into my NVME slot today and booted the server.  It showed up in unassigned devices and I was able to format it with XFS but now I only get the greyed out MOUNT button.  I'm not sure why it wont mount.  It is not passed through.  I have read through the instructions but everything makes it seem as though once formatted everything works.  What did I do wrong here?

Thanks

Link to comment

I have spent a few days racking my brain on how to get my windows 10 pro mapped share drives to mount to unraid. I can go to smb share see pc and see the shared drives but one I select mount they never mount. Pc group is on homegroup, Pc shows master in lanscan, Smb is set to private, have two users on unraid. i added dword and check all of the smb boxes on pc in settings. New to unraid and need advice.

Link to comment
8 minutes ago, poloconway said:

I have spent a few days racking my brain on how to get my windows 10 pro mapped share drives to mount to unraid. I can go to smb share see pc and see the shared drives but one I select mount they never mount. Pc group is on homegroup, Pc shows master in lanscan, Smb is set to private, have two users on unraid. i added dword and check all of the smb boxes on pc in settings. New to unraid and need advice.

Post diagnostics.

Link to comment

This is a really minor issue and no pressure on this (if you don't fix it it's also okay for me but I just wanted to report it), I noticed that if you remove a disk with a really long name that it gets a bit out of bounds (this is a disk mounted through iSCSI):
grafik.png.45dda72a0117479e6fa87999454a0c56.png

Link to comment

Having an issue with a couple of historical devices not removing. I made several changes to my server and had roughly 6 historical devices. 4 of which removed without issue. but 2 are acting as though they are removed successfully but they dont. Is there a command I can run to force remove them?

Link to comment
Just now, tazire said:

Having an issue with a couple of historical devices not removing. I made several changes to my server and had roughly 6 historical devices. 4 of which removed without issue. but 2 are acting as though they are removed successfully but they dont. Is there a command I can run to force remove them?

I am seeing the same issue after updating to the latest UD plugin.  I successfully removed a few historical devices yesterday, but today I am seeing the behavior described above.  After installing the 2023.03.30 update, UD reports the device has been successfully removed but it remains in the historical devices list.

Link to comment
On 3/29/2023 at 6:26 AM, jademonkee said:

Thanks for your help!

I would do the following:

  • Turn off auto mount.
  • Click on the 'File System Check' and see if the file system needs repaired.
  • Add '--bwlimit=X' to your rsync to slow things down.
  • Turn on auto mount and let your script run.

If the script still takes a long time, it is working and needs to copy everything.

  • Thanks 1
Link to comment
On 4/1/2023 at 1:01 PM, dlandon said:

I would do the following:

  • Turn off auto mount.
  • Click on the 'File System Check' and see if the file system needs repaired.
  • Add '--bwlimit=X' to your rsync to slow things down.
  • Turn on auto mount and let your script run.

If the script still takes a long time, it is working and needs to copy everything.

Hi there,

I ran the fs check and it returned errors. I ran it again with the "Run with correct flag" button, and it returned the same errors and didn't fix them (maybe coz it's exFAT?):

 

FS: exfat

Executing file system check: /usr/sbin/fsck.exfat /dev/sdl1 2>&1
exfatfsck 1.3.0
Checking file system on /dev/sdl1.
File system version 1.0
Sector size 512 bytes
Cluster size 128 KB
Volume size 1863 GB
Used space 1719 GB
Available space 144 GB
ERROR: file '01 - No Clue Of Life.flac' has invalid cluster 0xffffffff.
ERROR: file '02 - Lost In The Forest.flac' has invalid cluster 0xffffffff.
ERROR: file '04 - Treated By Herbs And Fire.flac' has invalid cluster 0xffffffff.
ERROR: file '05 - Dual Expression.flac' has invalid cluster 0xffffffff.
ERROR: unknown entry type 0xfb.
ERROR: unknown entry type 0x86.
ERROR: unknown entry type 0xc5.
ERROR: unknown entry type 0xaf.
ERROR: unknown entry type 0xb1.
ERROR: unknown entry type 0xfc.
ERROR: invalid cluster 0x23058b2a in clusters bitmap.
ERROR: unknown entry type 0xae.
ERROR: unknown entry type 0xc0.
ERROR: unknown entry type 0xf7.
ERROR: unknown entry type 0xb5.
ERROR: unknown entry type 0x8a.
ERROR: unknown entry type 0x87.
ERROR: unknown entry type 0x98.
ERROR: unknown entry type 0xfb.
ERROR: unknown entry type 0x8d.
ERROR: unknown entry type 0xe3.
ERROR: unknown entry type 0xe2.
ERROR: unknown entry type 0xf4.
ERROR: unknown entry type 0xb2.
ERROR: unknown entry type 0xfc.
ERROR: unknown entry type 0xad.
ERROR: unknown entry type 0x97.
ERROR: unknown entry type 0x8b.
ERROR: unknown entry type 0xae.
ERROR: unknown entry type 0xad.
ERROR: unknown entry type 0xf1.
ERROR: unknown entry type 0xa7.
ERROR: unknown entry type 0xa5.
ERROR: unknown entry type 0x96.
ERROR: unknown entry type 0x90.
ERROR: unknown entry type 0xad.
ERROR: unknown entry type 0x91.
ERROR: unknown entry type 0xe3.
ERROR: unknown entry type 0xd8.
ERROR: unknown entry type 0x95.
ERROR: unknown entry type 0xcb.
ERROR: unknown entry type 0xf5.
Totally 8625 directories and 62460 files.
File system checking finished. ERRORS FOUND: 42, FIXED: 0.

File system corruption detected!

 

How do I go about fixing it?

Or should I reformat and start over?

Or is this a sign that my disk is failing and should be replaced (it's around 9 years old)?

And, how can I be sure of the integrity of my backup data in the future? This isn't the only backup of the files, but if I suffered a failure and needed to use this disk to restore, I would be pretty bummed to find out that something was corrupt on it but I was never notified. Should I just periodically run the fscheck option?

Thanks for your help.

Link to comment
43 minutes ago, jademonkee said:

How do I go about fixing it?

Or should I reformat and start over?

Look at the SMART report and see if the disk is worth a reformat.

 

Why are you using exfat formatting?  It's not that robust.  I'd suggest NTFS.  It's more robust and can be mounted on a Windows PC or a Mac with an addon.

Link to comment
40 minutes ago, dlandon said:

Look at the SMART report and see if the disk is worth a reformat.

 

Why are you using exfat formatting?  It's not that robust.  I'd suggest NTFS.  It's more robust and can be mounted on a Windows PC or a Mac with an addon.

It's for Mac compatibility. But yeah, maybe I should just look at getting NTFS on my Mac. Cheers for the tip.

I can't figure out how to run a SMART test on the disk, as there doesn't seem to be an option anywhere, and my Windows disk monitoring software wouldn't let me either (maybe it's blocked on this model?).

I did plug it into my Windows machine and ran a disk check and repair though. I have now plugged it back into Unraid and the UD disk check has passed. I synced it again to see if it copies over the identified corrupt files, but it did not (it did copy over other files correctly, though).

In saying that, I don't recognise the files listed as corrupt, so they might be in one of the directories that were left over when the wrong backup script fired one time after I plugged it in (UD identified it as my other backup disk and as such ran its backup script and started copying files that aren't meant to be on this disk. I forcefully cancelled that operation, so it makes sense that some of those files would be corrupt).

Seems good enough for me at the moment. I'll periodically run a disk check, and if it fails again I'll move over to NTFS. Then if that ever corrupts I'll replace the disk.

Thanks for your help and insight.

Link to comment

I know this is most likely a very simple issue but on one of my 3 pro unraid servers, my unassigned devices constantly looking for devices and never populates, on top of that i can not search or connect a remote share... i have matched settings from all 3 systems and just this one does this.

Suggestions? what information can i post that you can use to check it?

 

image.thumb.png.53dd458bdc494839a60f06278773d968.png

 

ibm3650-diagnostics-20230403-0914.zip

Edited by Wiseone001
Link to comment
1 hour ago, zzgus said:

NO_MOUNT.png

 

Click on the "Nuevo_vol" names and make sure to set them differently.

 

Also some of those dual enclosures will only work with one drive at a time on unraid because they report both drives with the same ID, doesn't seem to be the case here though.

  • Like 1
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.