How to configure shared folder with Self Hosted Integration Runtime to copy files to Azure

CoulterJames 20 Reputation points
2023-03-28T09:46:42.4533333+00:00

I have a self hosted integration runtime installed on a Windows laptop for demo purposes. Laptop is running Windows 11 and I have successfully configured and used the SHIR to connect to a local SQL Server database and copy tables to ADLS container. I now want to use the same SHIR to copy files from a shared folder to ADLS.

I have run dmgcmd -DisableLocalFolderPathValidation to enable local folder browsing on the computer.

I have configured a shared folder with Read/Write access to Everyone. The file I want to copy is in a subfolder of the shared folder. For instance, if the shared folder is called Demo, then the test file is in Demo\SourceData\Demo.csv.

I cannot set up the FileServer linked service in ADF. No combination of hostname, username and password seems to work.

Username is in email format: firstname.lastname@company.com (not domain format domain\username) and the password is correct (it is my own password).

Host name is in format: \computername\sharedfolder

I have tried \computername\sharedfolder\subfolder too and that does not work

I have also tried adding a trailing slash to the host name and that does not work

The error message I currently get is "The system could not find the environment option that was entered".

Has anyone managed to successfully get this working at all?

Azure Data Lake Storage
Azure Data Lake Storage
An Azure service that provides an enterprise-wide hyper-scale repository for big data analytic workloads and is integrated with Azure Blob Storage.
1,338 questions
Azure Data Factory
Azure Data Factory
An Azure service for ingesting, preparing, and transforming data at scale.
9,533 questions
0 comments No comments
{count} votes

Accepted answer
  1. BhargavaGunnam-MSFT 26,136 Reputation points Microsoft Employee
    2023-03-28T20:40:12.49+00:00

    Hello CoulterJames,

    Welcome to the MS Q&A platform.

    Here are the possible root causes for this issue.

    If the account of the "User name" assigned to the linked service does not have permission to the directory entered in the "Host"

    (or)

    The firewall blocks the linked service connection.

    Please make sure to input the correct username and password. If you are connecting to a domain-joined machine, you need to use domainname\username and password. and make sure the user account has read and write permissions to the shared folder and it's subfolders.

    I could connect to a network share on my domain machine using my credentials.

    User's image

    But if I enter the wrong password or username, then I see the same error message that you have encountered.

    User's image

    Here is a document explained about the filesystem connector configuration details:

    https://learn.microsoft.com/en-us/azure/data-factory/connector-file-system?tabs=data-factory#connector-configuration-details

    Please follow the below to troubleshoot the issue

    • Ensure the shared folder is accessible from the computer where the SHIR is installed. You can test this by accessing the shared folder from Windows Explorer on the SHIR machine.
    • Double-check that the hostname is in the correct format. It should be in the format \\computername\sharedfolder. Ensure you are using the correct computer name and shared folder name.
    • Check that the username and password are correct. The username should be in an email format (firstname.lastname@company.com) and the password should be correct. for the domain machine, use domainname\username
    • Ensure that the SHIR runs under a user account with access to the shared folder. You can check this by going to the SHIR machine and checking the user account running the SHIR service.
    • Try using a different account to access the shared folder. This can help you determine if the issue is related to the account you are using.
    • Check the Windows event logs on the SHIR machine for any errors related to the SHIR service or the shared folder access.

    I hope this helps you resolve the issue. Let me know if you have any further questions.

    Here are the similar issue discussed on the below URLs:

    https://stackoverflow.com/questions/57056928/copy-on-prem-flat-file-to-azure-blob-using-azure-data-factory-v2
    https://learn.microsoft.com/en-us/answers/questions/396059/how-do-i-resolve-this-error-with-creating-adf-file
    https://stackoverflow.com/questions/66306691/azure-data-factory-the-system-could-not-find-the-environment-option-that-was-e

    If this answers your question, please consider accepting the answer by hitting the Accept answer and up-vote as it helps the community look for answers to similar questions


0 additional answers

Sort by: Most helpful