batch file - Windows access denied error message on using net use -
i having following issue when try use net use using batch file configured in hudson.
i added test user administrator in remote windows server 2012 , set password.
my batch script:
net use p: /delete net use p: "\\cazrt\c$" /user:test /persistent:no xxxxx set "source=%~1" set "target=p:/%~2" echo "%source%" "%target%" echo f|xcopy /s /i /q /y "%source%" "%target%" output on execution:
[exec] c:\hudsonprojects\nga>net use p: /delete [exec] [exec] c:\hudsonprojects\apps>net use p: "\\cazrt\c$" /user:test /persistent:no xxxxx [exec] system error 5 has occurred. [exec] [exec] access denied. if try use net use without persistent, same access denied error , network connection not found.
output on execution:
[exec] c:\hudsonprojects\nga>net use p: /delete [exec] [exec] c:\hudsonprojects\apps>net use p: "\\cazrt\c$" /user:test xxxxx [exec] network connection not found. [exec] more available typing net helpmsg 2250. [exec] [exec] [exec] [exec] c:\hudsonprojects\apps>set "source=d:/target/drop" [exec] [exec] c:\hudsonprojects\apps>set "target=p:/c:/temp" [exec] [exec] c:\hudsonprojesystem error 5 has occurred. [exec] [exec] access denied. if type net use local windows machine, showing:
\\cazrt\c$ command executed successful.
Comments
Post a Comment