Map a drive to a particular login and make it available all the time

  • curious_sqldba

    SSC-Dedicated

    Points: 36278

     

    I am not sure if this is something possible, i would like to map a share to a drive letter using a particular login and if that login tries to hit that server remotely it should be able to see that mapped drive.

  • Phil Parkin

    SSC Guru

    Points: 243596

    Please explain what you mean by "hit that server remotely". Is this from within SQL Server? What is the purpose of this?

    If the answer to your question can be found with a brief Google search, please perform the search yourself, rather than expecting one of the SSC members to do it for you.

  • curious_sqldba

    SSC-Dedicated

    Points: 36278

    This is related to another post i have , copy/pasting here

    "In a nutshell we have a package stored in SSIS catalogue on Server – S1 which reads files from Server – S2 ( NAS share) and then the  package stored in SSIS catalogue is executed via a C# app from Server – S3. All the servers are in the same domain and the process account executing package on S3 has full access to the  NAS location on S2.  Package is failing with an error message saying it cannot access the share, my hunch is the creds that is initiating the call from C# app is not propagating all the way to the NAS share, basically when it hits the NAS share the login is something like NT\Anonymous.  Looks like enabling delegation at the account level should fix this issue, is that the only solution. Also i think i will need to create SPN, what do i create SPN to? Is it the SSIS service?"

    I do have a work around, from server S3 i am using a execute SQL task and passing net use along with user name and password, there on all the tasks are able to use that share. Big concern is password is clear text, i know how to encrypt password using ps but then executing ps script via been a pain in neck.

     

  • Phil Parkin

    SSC Guru

    Points: 243596

    I do have a work around, from server S3 i am using a execute SQL task and passing net use along with user name and password, there on all the tasks are able to use that share. Big concern is password is clear text, i know how to encrypt password using ps but then executing ps script via been a pain in neck.

    Have you considered storing the password in a sensitive SSISDB environment variable and picking it up at runtime via a package parameter?

    • This reply was modified 5 days, 2 hours ago by  Phil Parkin. Reason: Fix typo

    If the answer to your question can be found with a brief Google search, please perform the search yourself, rather than expecting one of the SSC members to do it for you.

  • curious_sqldba

    SSC-Dedicated

    Points: 36278

    Not sure, how would that help in mapping a remote share? Any examples would be helpful

  • Phil Parkin

    SSC Guru

    Points: 243596

    curious_sqldba wrote:

    Not sure, how would that help in mapping a remote share? Any examples would be helpful

    My response was based on this comment by you:

    I do have a work around, from server S3 i am using a execute SQL task and passing net use along with user name and password, there on all the tasks are able to use that share.

    ExecuteSQL tasks can use sensitive parameters ...

    If the answer to your question can be found with a brief Google search, please perform the search yourself, rather than expecting one of the SSC members to do it for you.

  • Steve Jones - SSC Editor

    SSC Guru

    Points: 715370

    This might help: https://stackoverflow.com/questions/182750/map-a-network-drive-to-be-used-by-a-service/4763324#4763324

     

    If you want a mapping to persist, there's a flag. You need to be logged in as the user to do this.

Viewing 7 posts - 1 through 7 (of 7 total)

You must be logged in to reply to this topic. Login to reply