Recycle Bin (vfs recycle) for SMB Shares


dlandon

Recommended Posts

4 hours ago, comet424 said:

i was able to fix the error..  apparently it didnt like the 2  recycling bins on the disk..  when i delete the .recyclin.bin    and uninstalled and reinstall the recycling bin app   the error hasnt come back

 

trash can2.JPG

I have finally been able to reproduce this warning.  It will be fixed in the next release.

Link to comment

ah ok  i also found it came back when i mentioned i figured it was like a over flow error  cuz i was moving 10 TB  in krusader.. from Disk 5 to Disk 4  to reduce drives and make them all 1 size...    

 

im having a perfect storm issue lol

but really appreciate how hard you work on some of these addons  i very much appreciate it.. i used to do stuff like this 20 years+  for DOS   and windows   wish unraid was around back then  i really like it over windows home server etc

Link to comment
  • 2 weeks later...

I absolutely apologize, I went through the last 40+ pages of this thread and still didn't get my Recycle Bin working..

I'm sure it's not a hard fix, but I'm just wondering if there's anything that's obviously wrong?

I've attached a diagnostics from today.

It was installed, turned it on, then I deleted a few 4-5mb files, and nothing is coming up in the Recycle Bin app. 

 

tharja-diagnostics-20230609-2145.zip

Edited by Tharja
Link to comment
15 minutes ago, Tharja said:

I absolutely apologize, I went through the last 40+ pages of this thread and still didn't get my Recycle Bin working..

I'm sure it's not a hard fix, but I'm just wondering if there's anything that's obviously wrong?

I've attached a diagnostics from today.

It was installed, turned it on, then I deleted a few 4-5mb files, and nothing is coming up in the Recycle Bin app. 

tharja-diagnostics-20230609-2145.zip 251.3 kB · 0 downloads

A few things to check:

  • Does it say that the Recycle Bin is running in the upper right side if the Recycle Bin GUI?
  • Do you see deleted files in the Recycle Bin log?  Be sure 'Log Deleted FIles' is set to 'Yes'.
  • Deleted files are logged immediately, but may not show in the Shares for up to 5 Minutes if you are refreshing the Recycle Bin in the Background.
  • Only files deleted with SMB show in the Recyce Bin.  You cannot delete files in the Unraid File Manager or the Terminal and expect them to show in the Recycle Bin.
Link to comment

Thank you for your response.


Yes it does day it's running.
I do not see the files in the log. (I turned it off and on to see if that might have been an issue.)
I deleted it from a Windows PC having the SMB share mapped.

Edit: Also my shares don't show up in the "SMB Shares" list on the Recycle Bin settings page.

Edited by Tharja
Link to comment
12 minutes ago, Tharja said:

Thank you for your response.


Yes it does day it's running.
I do not see the files in the log. (I turned it off and on to see if that might have been an issue.)
I deleted it from a Windows PC having the SMB share mapped.

Show the output of this command:

testparm -s

 

Link to comment
Load smb config files from /etc/samba/smb.conf
lpcfg_do_global_parameter: WARNING: The "null passwords" option is deprecated
lpcfg_do_global_parameter: WARNING: The "syslog" option is deprecated
Loaded services file OK.
Weak crypto is allowed by GnuTLS (e.g. NTLM as a compatibility fallback)

Server role: ROLE_STANDALONE

# Global parameters
[global]
	disable netbios = Yes
	disable spoolss = Yes
	load printers = No
	logging = 0
	map to guest = Bad User
	max log size = 10000
	max open files = 40960
	multicast dns register = No
	ntlm auth = ntlmv1-permitted
	null passwords = Yes
	passdb backend = smbpasswd
	printcap name = /dev/null
	security = USER
	server min protocol = SMB2
	server multi channel support = No
	server string = Media server
	show add printer wizard = No
	smb1 unix extensions = No
	syslog = 0
	fruit:nfs_aces = No
	idmap config * : range = 3000-7999
	idmap config * : backend = tdb
	acl allow execute always = Yes
	aio read size = 0
	aio write size = 0
	create mask = 0777
	directory mask = 0777
	hide dot files = No
	include = /etc/samba/smb-shares.conf
	invalid users = root
	map archive = No
	map readonly = yes
	use sendfile = Yes
	wide links = Yes


[Serverfolders]
	comment = Serverfolders
	guest ok = Yes
	path = /mnt/user/Serverfolders
	read only = No
	vfs objects = catia fruit streams_xattr extd_audit recycle
	recycle:exclude_dir = .Recycle.Bin
	recycle:exclude = *.tmp
	recycle:versions = Yes
	recycle:minsize = 1
	recycle:touch_mtime = No
	recycle:touch = Yes
	recycle:keeptree = Yes
	recycle:directory_mode = 0777
	recycle:repository = .Recycle.Bin
	fruit:encoding = native


[isos]
	comment = saved VM instances
	guest ok = Yes
	path = /mnt/user/isos
	read only = No
	vfs objects = catia fruit streams_xattr extd_audit recycle
	recycle:exclude_dir = .Recycle.Bin
	recycle:exclude = *.tmp
	recycle:versions = Yes
	recycle:minsize = 1
	recycle:touch_mtime = No
	recycle:touch = Yes
	recycle:keeptree = Yes
	recycle:directory_mode = 0777
	recycle:repository = .Recycle.Bin
	fruit:encoding = native


Here you go.

Link to comment

Hi, just want to confirm how to make Recycle Bin work with rootshare. I have created a rootshare using UD plugin. When I navigate to the rootshare, I can see the .Recycle.Bin folder.

 

However, when I delete a file within the rootshare, it doesn't get sent to Recycle Bin. Did I miss out anything? The delete logs also don't show the files that I delete. I have tried restarting the Recycle Bin plugin. My unraid is on 6.12 release.

 

I also made sure that I have checked the "Enable on Unassigned Devices" checkbox in Recycle Bin plugin settings.

 

Somehow I unmounted and remount the rootshare, it starts to work. Sorry for the repeated editing of this post.

 

 

Edited by zellleonhart
Link to comment
  • 2 weeks later...

Probably a stupid question, but is there anything further to the install process I'm meant to be doing, other than just running the install from Community Applications?

 

I downloaded through CA, enabled it in the Plugin settings, but my share does not show in the Shares panel at the bottom. And after deleting multiple text files with text in, and an image file, nothing has showed up in the log section at all. No .recycle.bin folder has been created on my share either.

 

Do I need to restart my array or something to have everything propogate properly?

Seems I did. Whoops. All looks to be working after a full reboot.

 

 

Other question: Wouldn't enabling "Update Recycle Bin Size in the Background" spin up my drives every time it checks? If I wanted to keep my disks spun down as much as possible, should I keep the option on or off?

Edited by Jacksaur_
Link to comment
2 hours ago, Jacksaur_ said:

Other question: Wouldn't enabling "Update Recycle Bin Size in the Background" spin up my drives every time it checks? If I wanted to keep my disks spun down as much as possible, should I keep the option on or off?

If you have the cache dirs plugin installed, it shouldn't spin up disks.  Having the background check off will probably spin up disks whenever you access the recycle bin.

Link to comment
2 hours ago, sonic6 said:

Today i got a problem while updating to 6.12.3 and maybe it is a problem with recycle bin:

The log shows that the Recycle Bin started fine.  You probably had something going on that required another reboot and the Recycle Bin may not have been the issue.  Unless you can consistently reproduce the issue, there isn't much I can do.

 

You should also remove the unknown plugins to be sure they aren't interferring:

Jul 15 08:37:00 Unraid-1 root: Fix Common Problems Version 2023.04.26
Jul 15 08:37:26 Unraid-1 root: Fix Common Problems: Warning: The plugin un-get.plg is not known to Community Applications and is possibly incompatible with your server ** Ignored
Jul 15 08:37:26 Unraid-1 root: Fix Common Problems: Warning: The plugin unraid-versionchange.plg is not known to Community Applications and is possibly incompatible with your server ** 

 

Use NerdTools instead of un-get.

  • Thanks 1
Link to comment
9 minutes ago, dlandon said:

Unless you can consistently reproduce the issue, there isn't much I can do.

ok, i didn't tried that. server has to be online for now.

 

9 minutes ago, dlandon said:

You should also remove the unknown plugins to be sure they aren't interferring:

this plugins are fine and aren't the problem. i was asking the dev also.

 

10 minutes ago, dlandon said:

Use NerdTools instead of un-get.

good joke ;)

Link to comment

I didn't see it mentioned (maybe my search was insufficient) but it'd be handy if a share's recycle bin were emptied automatically when "free" dropped below a certain value or %, in case of emergencies.

 

I'm in the process of standardizing my media library with unmanic so lots of churn, which made me think of it.

 

I could do it with a simple user-script but that only solves it for me, and it's not as clean.

Something to consider if you end up with too much free time!

Link to comment
  • 2 weeks later...

Sorry if this is covered. I did search but it wasn't immediately cleared. My question is about 'aged files'. Does aged files mean *only* those files that have been deleted and have 'aged' the value specified as 'aged'? I.e., I have a file that it 10 days old. But it's not marked for delete. Thus, Recycle Bin does nothing. Now I delete the file. Its deleted age is '0', tomorrow it's 1, etc until I get to 3, which is the trigger to delete 'Aged files'. This is my understanding. Is that the actual implementation ?

Link to comment
25 minutes ago, zachlovescoffee said:

Sorry if this is covered. I did search but it wasn't immediately cleared. My question is about 'aged files'. Does aged files mean *only* those files that have been deleted and have 'aged' the value specified as 'aged'?

Yes.  The aged time is based on the file mtime (last modified), not the atime (last accessed).

 

26 minutes ago, zachlovescoffee said:

I have a file that it 10 days old. But it's not marked for delete.

Files are not "marked" for delete.  When the cron task runs, it determines what files are aged and deletes them.

 

27 minutes ago, zachlovescoffee said:

Now I delete the file. Its deleted age is '0', tomorrow it's 1, etc until I get to 3, which is the trigger to delete 'Aged files'. This is my understanding. Is that the actual implementation ?

Yes.  Based on the file's mtime which is updated to the time the file was deleted and moved to the Recycle Bin.

Link to comment

not sure when it stopped but the recycling bin for UD devices   like removable ntfs drive..  is not being detected in the recycling bin to delete it...   i do delete files and it goes into the recycling bin  but when i goto recyling bin and empty all it never detects or deletes the files in the .recycling.bin  on the UD drives...  not sure when it stopped just noticed my drives never loosing data when i empty

 

a stop start

a restart

a rescan of the recyling bin buttons  do not make a difference to detecting

 

Edited by comet424
Link to comment
1 hour ago, comet424 said:

not sure when it stopped but the recycling bin for UD devices   like removable ntfs drive..  is not being detected in the recycling bin to delete it...   i do delete files and it goes into the recycling bin  but when i goto recyling bin and empty all it never detects or deletes the files in the .recycling.bin  on the UD drives...  not sure when it stopped just noticed my drives never loosing data when i empty

 

a stop start

a restart

a rescan of the recyling bin buttons  do not make a difference to detecting

 

I just ran a test:

  • Mount a UD device.
  • Delete some files through the UD device share.
  • Empty UD share trash - success.
  • Delete some files through the UD device share.
  • Empty All Trash - success.

Let me know if you are doing something different than what I've done here and I'll see if I can reproduce your issue.

Link to comment

@dlandon   sorry delay  didnt have internet working right

 

so i mounted the UD    i made a folder on my ntfs UD drive   a test delete...  i put files in there and deleted the files

 

it creates the   .recyclie bin  folder..  

 

but i cant empty the UD Share  as it doesnt show up

all i can do is Trash All    but it doesnt delete  and i let it wait 20 min before i refreshed   incase it takes a bit for UD recyclin bin to populate

 

 

and i created the folder and deleted the folder and copied files to the test delete folder while running Windows 10 

 

i wonder if it has to do with this warning ?

Aug 7 21:39:16 Tardis unassigned.devices: Warning: Unassigned Devices are not set to be shared with NFS.

 

i never use the nfs  but  i always get that warning

 

 

recyclebin.JPG

tardis-diagnostics-20230807-2200.zip

Edited by comet424
Link to comment

@dlandon

here is a pic of my sisters ssd i trade back and forth with her to backup her files....  when i delete the files or move the files the copy goes to the .recylin.bin  folder   but it never registers  in Recycling bin plugin

 

i running 11.5  since 12.x  has been flaky for me..    so i cant get it to empty through the plugin

all i could think of is that NFS share issue  warning for UD    from the warning...  as i took a diagnostic.. before the  Authlimit error fills my logs with like 10k of the same authlimit  drives me mad

 

 

recyclebin2.JPG

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.