Can't rename a folder that was duplicated (copy of the original folder - template)

eduardooliveira

Dabbler
Joined
Feb 10, 2023
Messages
13
Hi,

We just started to use Truenas Scale coming from Truenas Core. This is brand new install not a migration from one system (Core) to the other (Scale).

So, accessing folders from a Windows machine is fine and all permissions are set properly (no one has issues creating files, folders etc) except for one thing...

There is one specific folder that is considered a template which holds a few subfolders and maybe 30-40 MS Word and Excel files (the folder 15MB in size so, not big at all). This folder (lets call it "Folder A") is to be duplicated (copy and pasted at the same location) and renamed according to the new task. When doing this (a copy of the folder being created with the name "Folder A Copy) and trying to rename it will say that the folder is already open on another machine or another person when it is not! If we wait a couple of minutes (5 min or so) it will allow us to rename the folder with no problems. Oh, we rename the original folder no problems, only the new folder copy cannot be renamed....

That said, this is not a permissions issue but something that is getting stuck right after the copy of the folder is being created and preventing it to be renamed. That does not happen with any other folders but only with this one.

Has anyone experienced something similar? These folders came from a Windows 10 computer that was acting as a file server before where this issue was not happening. It only started after we deployed the Truenas Scale. I have implemented Truenas Core performing the same (moving from a Windows Machine action as a file server to Truenas) and that was not a problem at all... Wondering if someone has seem this scenario already before I start digging into the folders and contents trying to figure out if any specific file or subfolder it is to be blamed.

Thanks in Advance
 

Samuel Tai

Never underestimate your own stupidity
Moderator
Joined
Apr 24, 2020
Messages
5,399
This sounds like server-side copies aren’t enabled, or if they are, aren’t working, so the copy task is routing the copy through the SMB client, preventing renaming the destination folder until all the folder contents have flowed through the client to the destination folder.
 

eduardooliveira

Dabbler
Joined
Feb 10, 2023
Messages
13
What seems odd to me is that this happens with one folder only so I am guessing that it it was the server-side it would happen with any other folder.
 

Samuel Tai

Never underestimate your own stupidity
Moderator
Joined
Apr 24, 2020
Messages
5,399
So what’s unique about this folder? How deeply are the contents nested? Are there special or hidden characters in any names?
 

eduardooliveira

Dabbler
Joined
Feb 10, 2023
Messages
13
Thank for the follwoup Samuel!

So, no hidden characters or special characters', all folder names and paths are under 30 characters long as well and "folderwhise" there are 4 of 5 subfolders under the root or the path.
It also happens on other computers so, not isolated to one user but only with that given folder (which also makes me believe that if it was the Server-Side Copy it would affect other folders as well). Additionally, 15MB copy on a 1Gbps network is not a big deal really specially with about 5 clients total.
 

eduardooliveira

Dabbler
Joined
Feb 10, 2023
Messages
13
There is nothing unique about this folder really. only a few subfolders, some empty and some with work/excel files as templates.
I am about to copy all content one by one and test but decided to post before digging this way so maybe someone saw something similar before. Specially because it was ok before when folders were hosted by a Windows 10 machine.
 
Joined
Oct 22, 2019
Messages
3,641
Does this also occur if you immediately try to delete the copied folder? Or does this only happen when you try to immediately rename it?
 

eduardooliveira

Dabbler
Joined
Feb 10, 2023
Messages
13
can delete but some subfolder will say that they are open and/or cannot be deleted (even some there were already empty when copied from the template folder)

And after a few min everything is ok.

Also, one interesting fact, if I try to rename or delete that new folder that was duplicated but now from a DIFFERENT machine (all Windows 10 running the same build) that will work just fine. But not from the machine that created the copy
 

eduardooliveira

Dabbler
Joined
Feb 10, 2023
Messages
13
Well, I just confirmed that it happens with all existing folders if we create a copy. so it is not isolated to one folder or directory only.
 

Samuel Tai

Never underestimate your own stupidity
Moderator
Joined
Apr 24, 2020
Messages
5,399
Well, I just confirmed that it happens with all existing folders if we create a copy. so it is not isolated to one folder or directory only.

I reiterate: This sounds like server-side copy isn't working, so all copies are flowing through the client that initiated the copy, which prevents the rename until the flow-through completes.

Server-side copy for Samba should be enabled by default, but if the clients don't support the required FSCTLs, Samba will revert to client-side copy.

 

eduardooliveira

Dabbler
Joined
Feb 10, 2023
Messages
13
HI Samuel,

That is not the case for sure! they are all Windows 10 and we do not have issues with any other deployment other than this one of Truenas Scale. Also, At the exact same second the copy is completed if I try from ANOTHER machine with the SAME user it will work (I can rename) and from that moment on I can rename the folder or do what ever I want from the original machine that created the copy of the folder. That means that the copy was completed and the files are there

Also, any folder (sizes from 2Kb to 6MB) will have the same issue and even if it was an issue with the Server-Side Copy that would not even be noticed as duplicating a 2Kb folder on a 1GB network would be instantaneous so, renaming would not be a problem having users to wait for 5-10 min to be able to do it.

Also, would not happen to all computers even a machine that we just reinstalled Windows 10 22H2 from scratch.
 
Last edited:
Top