Recycle Bin (vfs recycle) for SMB Shares


dlandon

794 posts in this topic Last Reply

Recommended Posts

2 hours ago, Energen said:

 

Just wanted to chime in that I had to do this step as well to get the recycle bin working.  Don't know if there's a way to do this automatically when the plugin is installed, or if that's just bad form to do automatically, but seems to be a required step.  Perhaps add the command to the plugin install info or something?

 

Thanks for this, very useful plugin.

You shouldn't have to do that.  The recycle bin issues the command for samba to reload it's configuration and works just fine for me.

 

EDIT: When the samba configuration is reloaded, unRAID will reconfigure the share settings on an event.  The recycle bin will add the settings it needs when the event is triggered.  This is done on a one minute interval so there might be a delay before the vfs_recycle is initiated in samba.

Edited by dlandon
Link to post
  • 1 month later...
  • Replies 793
  • Created
  • Last Reply

Top Posters In This Topic

Top Posters In This Topic

Popular Posts

This is a plugin that will create a per share .Recycle.Bin folder on each smb share for files deleted on that share.  Built into samba is a module called "vfs recycle" that handles the deletion of fil

Shares were not displaying when "Log Deleted Files" was set to "No".  This has been fixed in the latest version.

No longer true.  I'm releasing a new version that will not show any remote mounted shares and the local recycle bin will not remove any files from the remote share recycle bins.  Only the local server

Posted Images

New release of the Recycle Bin plugin.  The 'Shares' tab now displays only the shares with Recycle Bin contents.  Each share has an 'Empty' button so you can empty the Recycle Bin trash for a single share.

Link to post

Hey, great plugin. Thank you. 

 

Three questions:

  1. Is there a limit on the amount of excluded files you can enter. It seems in the GUI i've run out of space to enter more exclusions
  2. Is it possible to exclude folders within a share from the recycle bin
  3. For Recycle Bin Parameters do you have any more examples of what can be done in there? No specific need but there might be a use case I'm not aware of. 

Thanks

Link to post

Answers:

1. Only the length of the ui input line.  Can you do a wild card exclusion?

2. No.  Only the complete share.  You might be able to exclude the folder in the excluded files.  I've not tried that.

3. No.  The best source for the additional parameters is the samba documentation.

Link to post
58 minutes ago, dlandon said:

Answers:

1. Only the length of the ui input line.  Can you do a wild card exclusion?

2. No.  Only the complete share.  You might be able to exclude the folder in the excluded files.  I've not tried that.

3. No.  The best source for the additional parameters is the samba documentation.

 

Thanks.. I can always edit the config file directly I believe to fix the input line issue. 

 

Appreciate the help.

Link to post
39 minutes ago, JoshFink said:

 

Thanks.. I can always edit the config file directly I believe to fix the input line issue. 

 

Appreciate the help.

 

How many shares are you trying to exclude?

 

EDIT: I can increase the line length.  It is currently set at 100 characters.

Edited by dlandon
Link to post
4 hours ago, JoshFink said:

It's not the shares that I'm excluding but files. Wildcards won't work with them because I want some but not all (they're certain jpgs and pngs that I want to exclude). 

 

Not a huge rush on it but I appreciate the help. 

 

Sorry.  I misunderstood.

Link to post
7 hours ago, JoshFink said:

It's not the shares that I'm excluding but files. Wildcards won't work with them because I want some but not all (they're certain jpgs and pngs that I want to exclude). 

 

Not a huge rush on it but I appreciate the help. 

 

The excluded files input field in the settings is now 150 characters.

Link to post
  • 2 weeks later...

I am trying to clear my recycle bin after deleting some data

i now have a problem where the recycle bin GUI isn't even opening. The page just keeps spinning and asking if I want to wait for the unresponsive page

 

any advice on how to clear the recycle bin and expedite the process as the GUI won't load ?

Link to post
7 hours ago, dlandon said:

Enter this at the command line:


/usr/local/emhttp/plugins/recycle.bin/scripts/rc.recycle.bin empty

This will empty the recycle bins on all shares.

 

thanks. so i emptied now. but the page at http://10.0.0.21/Settings/RecycleBin is just spinning and chrome is doing the not responding wait thing. any idea why it would be doing that and how to fix it?

 

the bin is empty so i would expect it to relatively quick with nothing to compute?

Link to post
6 minutes ago, kingy444 said:

 

thanks. so i emptied now. but the page at http://10.0.0.21/Settings/RecycleBin is just spinning and chrome is doing the not responding wait thing. any idea why it would be doing that and how to fix it?

 

the bin is empty so i would expect it to relatively quick with nothing to compute?

I don't have any idea.  How about posting some diagnostics to help troubleshoot?

Link to post
2 minutes ago, kingy444 said:

Have done that actually since posting. No difference. 

You have the nerd pack plugin installed.  One of the packages there may be interfering.  I would uninstall it for the moment and see if that makes any difference.

Link to post
3 minutes ago, dlandon said:

You have the nerd pack plugin installed.  One of the packages there may be interfering.  I would uninstall it for the moment and see if that makes any difference.

 

no dice

 

same thing. any other suggestions?

Link to post
9 hours ago, kingy444 said:

 

attached. thanks for your help

unraid-diagnostics-20170713-1251.zip

There seems to be a lot of mover activity on the recycle bin.

Jul  8 03:40:10 unRAID root: >f+++++++++ BackUp/.Recycle.Bin/Scripts/logs/Copy #734 of sonarrlog.txt

 

Jul  8 03:40:32 unRAID root: >f+++++++++ BackUp/MediaBrowser/Emby Backup - 2017-07-08 12.10.1 - Auto/branding.xml
Jul  8 03:40:32 unRAID root: >f+++++++++ BackUp/MediaBrowser/Emby Backup - 2017-07-08 12.10.1 - Auto/fanart.xml
Jul  8 03:40:33 unRAID root: >f+++++++++ BackUp/MediaBrowser/Emby Backup - 2017-07-08 12.10.1 - Auto/chapters.xml
Jul  8 03:40:33 unRAID root: .d..t...... BackUp/MediaBrowser/Emby Backup - 2017-07-08 12.10.1 - Auto/
Jul  8 03:40:33 unRAID root: >f+++++++++ BackUp/MediaBrowser/Emby Backup - 2017-07-08 12.10.1 - Auto/encoding.xml
Jul  8 03:40:33 unRAID root: >f+++++++++ BackUp/MediaBrowser/Emby Backup - 2017-07-08 12.10.1 - Auto/metadata.xml

You are probably flooding the recycle bin with these files and the plugin can't do anything with that much activity.

 

Exclude some of these files, or the shares and clean it up.

Link to post
On 13/07/2017 at 10:00 PM, dlandon said:

There seems to be a lot of mover activity on the recycle bin.


Jul  8 03:40:10 unRAID root: >f+++++++++ BackUp/.Recycle.Bin/Scripts/logs/Copy #734 of sonarrlog.txt

 


Jul  8 03:40:32 unRAID root: >f+++++++++ BackUp/MediaBrowser/Emby Backup - 2017-07-08 12.10.1 - Auto/branding.xml
Jul  8 03:40:32 unRAID root: >f+++++++++ BackUp/MediaBrowser/Emby Backup - 2017-07-08 12.10.1 - Auto/fanart.xml
Jul  8 03:40:33 unRAID root: >f+++++++++ BackUp/MediaBrowser/Emby Backup - 2017-07-08 12.10.1 - Auto/chapters.xml
Jul  8 03:40:33 unRAID root: .d..t...... BackUp/MediaBrowser/Emby Backup - 2017-07-08 12.10.1 - Auto/
Jul  8 03:40:33 unRAID root: >f+++++++++ BackUp/MediaBrowser/Emby Backup - 2017-07-08 12.10.1 - Auto/encoding.xml
Jul  8 03:40:33 unRAID root: >f+++++++++ BackUp/MediaBrowser/Emby Backup - 2017-07-08 12.10.1 - Auto/metadata.xml

You are probably flooding the recycle bin with these files and the plugin can't do anything with that much activity.

 

Exclude some of these files, or the shares and clean it up.

 

apologies mate. i must not have hit reply - it was a browser thing. Working fine in IE EDGE. Cleared cache in Chrome and its working again

 

Thanks for the help

Link to post

I had a Plex folder still living on my array in /mnt/user/appdata.  It had 5,000,000 files and directories in it.  Took about 90 minutes to delete with rm -rf

 

Saw that it was moved to the Recycle Bin.  Emptied it, that took less than a minute.

 

How exactly does the Recycle Bin work in this specific case?

Link to post
13 hours ago, tucansam said:

I had a Plex folder still living on my array in /mnt/user/appdata.  It had 5,000,000 files and directories in it.  Took about 90 minutes to delete with rm -rf

 

Saw that it was moved to the Recycle Bin.  Emptied it, that took less than a minute.

 

How exactly does the Recycle Bin work in this specific case?

Empty recycle bin:

rm -rf /mnt/user/*/.Recycle.Bin

 

Edited by dlandon
Link to post
  • dlandon changed the title to Recycle Bin (vfs recycle) for SMB Shares

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.