Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

The mount is making unraid unable to stop array #28

Open
rqi14 opened this issue Feb 13, 2021 · 6 comments · May be fixed by #30
Open

The mount is making unraid unable to stop array #28

rqi14 opened this issue Feb 13, 2021 · 6 comments · May be fixed by #30

Comments

@rqi14
Copy link

rqi14 commented Feb 13, 2021

I am using unraid 6.8.3

When clicking stop array, the status is stuck at Array Stopping Retry unmounting user share(s)...

there are two issues.

  1. /mnt/user cannot be unmounted by the system. I have to manually do fusermount -uz /mnt/user
  2. The script left an empty folder in /mnt/user0/mount_rclone. The system cannot delete it automatically and thus failed to umount /mnt/user0 as it is not empty.

Please see the log below
Feb 13 19:50:21 unraidServer emhttpd: shcmd (545): exit status: 32
Feb 13 19:50:21 unraidServer emhttpd: shcmd (546): rmdir /mnt/user
Feb 13 19:50:21 unraidServer root: rmdir: failed to remove '/mnt/user': Device or resource busy
Feb 13 19:50:21 unraidServer emhttpd: shcmd (546): exit status: 1
Feb 13 19:50:22 unraidServer emhttpd: shcmd (548): /usr/local/sbin/update_cron
Feb 13 19:50:22 unraidServer emhttpd: Retry unmounting user share(s)...
Feb 13 19:50:27 unraidServer emhttpd: shcmd (549): umount /mnt/user0
Feb 13 19:50:27 unraidServer root: umount: /mnt/user0: not mounted.
Feb 13 19:50:27 unraidServer emhttpd: shcmd (549): exit status: 32
Feb 13 19:50:27 unraidServer emhttpd: shcmd (550): rmdir /mnt/user0
Feb 13 19:50:27 unraidServer root: rmdir: failed to remove '/mnt/user0': Directory not empty
Feb 13 19:50:27 unraidServer emhttpd: shcmd (550): exit status: 1
Feb 13 19:50:27 unraidServer emhttpd: shcmd (551): umount /mnt/user
Feb 13 19:50:27 unraidServer root: umount: /mnt/user: target is busy.
Feb 13 19:50:27 unraidServer emhttpd: shcmd (551): exit status: 32
Feb 13 19:50:27 unraidServer emhttpd: shcmd (552): rmdir /mnt/user
Feb 13 19:50:27 unraidServer root: rmdir: failed to remove '/mnt/user': Device or resource busy
Feb 13 19:50:27 unraidServer emhttpd: shcmd (552): exit status: 1
Feb 13 19:50:27 unraidServer emhttpd: shcmd (554): /usr/local/sbin/update_cron
Feb 13 19:50:27 unraidServer emhttpd: Retry unmounting user share(s)...
Feb 13 19:50:32 unraidServer emhttpd: shcmd (555): umount /mnt/user0
Feb 13 19:50:32 unraidServer root: umount: /mnt/user0: not mounted.
Feb 13 19:50:32 unraidServer emhttpd: shcmd (555): exit status: 32
Feb 13 19:50:32 unraidServer emhttpd: shcmd (556): rmdir /mnt/user0
Feb 13 19:50:32 unraidServer root: rmdir: failed to remove '/mnt/user0': Directory not empty
Feb 13 19:50:32 unraidServer emhttpd: shcmd (556): exit status: 1
Feb 13 19:50:32 unraidServer emhttpd: shcmd (557): umount /mnt/user
Feb 13 19:50:32 unraidServer root: umount: /mnt/user: target is busy.
Feb 13 19:50:32 unraidServer emhttpd: shcmd (557): exit status: 32
Feb 13 19:50:32 unraidServer emhttpd: shcmd (558): rmdir /mnt/user
Feb 13 19:50:32 unraidServer root: rmdir: failed to remove '/mnt/user': Device or resource busy
Feb 13 19:50:32 unraidServer emhttpd: shcmd (558): exit status: 1
Feb 13 19:50:32 unraidServer emhttpd: shcmd (560): /usr/local/sbin/update_cron
Feb 13 19:50:32 unraidServer emhttpd: Retry unmounting user share(s)...
Feb 13 19:50:37 unraidServer emhttpd: shcmd (561): umount /mnt/user0
Feb 13 19:50:37 unraidServer root: umount: /mnt/user0: not mounted.
Feb 13 19:50:37 unraidServer emhttpd: shcmd (561): exit status: 32
Feb 13 19:50:37 unraidServer emhttpd: shcmd (562): rmdir /mnt/user0
Feb 13 19:50:37 unraidServer root: rmdir: failed to remove '/mnt/user0': Directory not empty
Feb 13 19:50:37 unraidServer emhttpd: shcmd (562): exit status: 1
Feb 13 19:50:37 unraidServer emhttpd: shcmd (563): umount /mnt/user
Feb 13 19:50:37 unraidServer root: umount: /mnt/user: target is busy.
Feb 13 19:50:37 unraidServer emhttpd: shcmd (563): exit status: 32
Feb 13 19:50:37 unraidServer emhttpd: shcmd (564): rmdir /mnt/user
Feb 13 19:50:37 unraidServer root: rmdir: failed to remove '/mnt/user': Device or resource busy
Feb 13 19:50:37 unraidServer emhttpd: shcmd (564): exit status: 1
Feb 13 19:50:37 unraidServer emhttpd: shcmd (566): /usr/local/sbin/update_cron
Feb 13 19:50:37 unraidServer emhttpd: Retry unmounting user share(s)...
Feb 13 19:50:42 unraidServer emhttpd: shcmd (567): umount /mnt/user0
Feb 13 19:50:42 unraidServer root: umount: /mnt/user0: not mounted.
Feb 13 19:50:42 unraidServer emhttpd: shcmd (567): exit status: 32
Feb 13 19:50:42 unraidServer emhttpd: shcmd (568): rmdir /mnt/user0
Feb 13 19:50:42 unraidServer root: rmdir: failed to remove '/mnt/user0': Directory not empty
Feb 13 19:50:42 unraidServer emhttpd: shcmd (568): exit status: 1
Feb 13 19:50:42 unraidServer emhttpd: shcmd (569): umount /mnt/user
Feb 13 19:50:42 unraidServer root: umount: /mnt/user: target is busy.
Feb 13 19:50:42 unraidServer emhttpd: shcmd (569): exit status: 32
Feb 13 19:50:42 unraidServer emhttpd: shcmd (570): rmdir /mnt/user
Feb 13 19:50:42 unraidServer root: rmdir: failed to remove '/mnt/user': Device or resource busy
Feb 13 19:50:42 unraidServer emhttpd: shcmd (570): exit status: 1
Feb 13 19:50:42 unraidServer emhttpd: shcmd (572): /usr/local/sbin/update_cron
Feb 13 19:50:42 unraidServer emhttpd: Retry unmounting user share(s)...

@Justawebguy
Copy link

Having the same issue. Did you figure out a resolution?

@thegreenemachine55
Copy link

I was having the same problem, found a script that southloven posted over on the unraid forums and customized it for my use.

Run "lsof | grep /mnt/user/ " when the array is stuck unmounting disks and customize the script for your needs.

#!/bin/bash

#######################

unmount Script

#######################

Version 0.0.1

#######################

echo "$(date "+%d.%m.%Y %T") INFO: *** Starting rclone_unmount script ***"

umount -l /mnt/user/RcloneRemoteName/RcloneRemoteName
umount -l /mnt/user/mount_mergerfs/gdrive_vfs
umount -l /mnt/user/mount_mergerfs/RcloneRemoteName
umount -l /mnt/user/mount_rclone/gdrive_vfs
umount -l /mnt/user/mount_rclone/RcloneRemoteName
umount -l /mnt/user0/mount_rclone/cache/RcloneRemoteName
umount -l /mnt/user/local/RcloneRemoteName

echo "$(date "+%d.%m.%Y %T") INFO: *** Ending rclone_unmount script ***"

exit

@Torqu3Wr3nch
Copy link

Same issue here. Confirmed fixed by @thegreenemachine55's suggestion.

I've updated the the unmount script to use the share location variables used in the rclone_mount script and will issue a pull request this weekend.

@Torqu3Wr3nch Torqu3Wr3nch linked a pull request Sep 20, 2021 that will close this issue
@thekiefs
Copy link

thekiefs commented May 1, 2022

Same problem here. Can this #30 please get merged?

@NineBall8
Copy link

@BinsonBuzz Works fine here, should we merge?

@Sildenafil99
Copy link

Sildenafil99 commented Aug 14, 2022

I have the same problem.
I used the script, and also added "umount -l /mnt/user0/" but now i stucked in
rmdir: failed to remove '/mnt/user0': Directory not empty
and
rmdir: failed to remove '/mnt/user': Directory not empty

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

7 participants