Quantcast
Channel: Forum SQL Server Database Engine
Viewing all articles
Browse latest Browse all 15694

Map Drive in SQL agent Job

$
0
0

Hi All . I am trying to do the following

exec xp_cmdshell 'net use \\192.168.0.1\sharing2'
exec xp_cmdshell 'copy F:\test.txt \\192.168.0.1\sharing2\'
exec xp_cmdshell 'net use \\192.168.0.1\sharing2 /delete'

what credential it's using?

I found the security log on 192.168.0.1 shows domain administrator is using this file sharing.

The DB is also in the same domain, but I haven't type the login and and credential in the above script.

How could it happens?


Viewing all articles
Browse latest Browse all 15694

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>