Hello,I saw on Apple mashines connected to AppleShare Server that they had something called 'Network Trash Folder'. That is if some is working on a server volume and deletes a file from the volume, the file appears in user's Trash on his Desktop (but?it is really placed on the server in volume's special folder called 'Network Trash Folder'). So he can restore the file if he needs.And when the user purges his Trash, the file is permanently deleted from server.?Is it possible to make the same thing with Samba (running on Linux server) and MS Windows users?
On Mon, 20 Oct 2003 bolek_chrobry@op.pl wrote:> Hello,I saw on Apple mashines connected to AppleShare Server that they had > something called 'Network Trash Folder'. That is if some is working on a > server volume and deletes a file from the volume, the file appears in user's > Trash on his Desktop (but?it is really placed on the server in volume's > special folder called 'Network Trash Folder'). So he can restore the file if > he needs.And when the user purges his Trash, the file is permanently deleted > from server.?Is it possible to make the same thing with Samba (running on > Linux server) and MS Windows users? >Refer to the Samba-HOWTO-Collection.pdf that shipped with Samba-3.0.0 and can be obtained from: http://pl.samba.org/samba/docs/Samba-HOWTO-Collection.pdf See Chapter 20.3.4 - John T. -- John H Terpstra Email: jht@samba.org
> Hello,I saw on Apple mashines connected to AppleShare Server that they had > something called 'Network Trash Folder'. That is if some is working on a > server volume and deletes a file from the volume, the file appears in user's > Trash on his Desktop (but it is really placed on the server in volume's > special folder called 'Network Trash Folder'). So he can restore the file if > he needs.And when the user purges his Trash, the file is permanently deleted > from server. Is it possible to make the same thing with Samba (running on > Linux server) and MS Windows users?There is a VFS module for moving "deleted" files to a special folder. Then you can share this folder as a type trash can. We simply purge these folders with a scheduled job; which is easy to write using "find". We run it every hour, and delete files larger than 8Mb after 1 day and smaller files after 7 days. find /usr/pcnet/trash -type f -mtime +1 -size +8192k -exec rm \{\} \; find /usr/pcnet/trash -type f -mtime +7 -size -8193k -exec rm \{\} \; Seems to work well enough. "-type f" make it only look at regular files, should avoid any wierdness if your get links or symblic links to directories in there some how.