Azure HNS Directory Error
Overview
Currently, on version 3.3.5
and prior of SFTP Gateway, there is an error where a storage account with HNS enabled is unable to delete directories using an SFTP client.
What is Hierarchical Namespace (HNS)
Hierarchical namespace is a Blob storage account feature that lets you create empty subfolders. Normally, empty subfolders get pruned within Blob storage. However, with HNS enabled they remain intact.
HNS can be enabled when creating a Blob storage account. But, you cannot enable or disable HNS after a Blob storage account has already been created.
You are able to find out if your storage account has hierarchical namespace enabled under Overview -> Properties -> Data Lake Storage.
The behavior of the problem
If you are running SFTP Gateway version 3.3.5
or prior and connect to a Blob storage account with HNS enabled you will be unable to delete any directories from your SFTP client.
To delete a directory, you would need to delete it in Blob Storage. Once the directory has been deleted from Blob Storage, reconnect to your SFTP Gateway server and the folder should be gone.
Solutions and workarounds
The best approach is to migrate to the latest version of SFTP Gateway. This issue is resolved in versions 3.3.6
and later.
One workaround would be to configure a new Blob Storage account that does not have HNS enabled.