psexec command line giving me access denied error while trying to copy a file from local machine to remote machine RRS feed

  • Question

  • psexec \\ -u administrator -p demo -w c:\one.txt -c \\\zin_eng

    remote machine name

    username administrator

    password demo

    destination file c:\one.txt

    source file \\\zin_eng

    i am getting access denied

    i am using pstools psexec.exe

    help required


    • Moved by Bob Shen Monday, July 1, 2013 5:42 AM
    Friday, June 28, 2013 11:44 AM


All replies

  • Hi vinayrajaram,

    I’m afraid that it is not the correct forum about this issue. I am moving your question to the moderator forum ("Where is the forum for..?"). The owner of the forum will direct you to a right forum. Thanks for your understanding.

    Bob Shen
    MSDN Community Support | Feedback to us
    Develop and promote your apps in Windows Store
    Please remember to mark the replies as answers if they help and unmark them if they provide no help.

    Monday, July 1, 2013 5:42 AM
  • Those options don't do what I think you think they do. See http://technet.microsoft.com/en-gb/sysinternals/bb897553.aspx for syntax list.

    In this case -w sets the working directory of the process relative to the remote machine, so obviously "c:\one.txt" isn't right.

    And -c says to "Copy the specified program to the remote system for execution. If you omit this option then the application must be in the system's", in which case the folder you're listing obviously isn't right.

    There's a bunch of examples at the above link, and even more here http://ss64.com/nt/psexec.html from which I wonder if this might be more what you're after :

    "Connect to workstation64 and copy a file from another server:
    psexec \\workstation64 -s cmd /c copy \\server21\share45\file.ext c:\localpath"

    Monday, July 1, 2013 6:01 AM
  • I's ask them over here.





    Regards, Dave Patrick ....
    Microsoft Certified Professional
    Microsoft MVP [Windows]

    Disclaimer: This posting is provided "AS IS" with no warranties or guarantees , and confers no rights.

    Monday, July 1, 2013 9:25 AM