Local Machine:
Windows 7 Enterprise 64-bit SP1
Joined to a domain
Logged in as domain user "domain\firstname.lastname"

Remote Machine (IP Address = 192.168.0.225):
Windows XP Professional 64-bit SP2
Joined to a workgroup
Administrator is logged into the desktop

Elevated command prompt command line:
paexec.exe /AcceptEula \\192.168.0.225 -u 192.168.0.225\Administrator -p password -s -e -i 0 -c -f -w c:\windows\temp -csrc "C:\path to\file.exe" "file.exe"

Output:
PAExec v1.21 - Execute Programs Remotely
Copyright (c) 2012-2013 Power Admin LLC
www.poweradmin.com/PAExec

Connecting to 192.168.0.225...
Starting PAExec service on 192.168.0.225...
Copying Setup Installer.exe remotely...

Setup Installer.exe returned -1

PAExec returning exit code -1

The log file that file.exe creates indicates that a call to the windows API function GetTempFileNameW fails with the error 0x8007010b (The directory name is invalid)

GetTempFileNameW is called passing the result of GetTempPathW as the first parameter.

GetTempPathW returns C:\WINDOWS\system32\config\systemprofile\Local Settings\Temp\

Using PsExec with an equivalent command line works as expected:
psexec.exe /AcceptEula \\192.168.0.225 -u 192.168.0.225\Administrator -p password -s -e -i 0 -c -f -w c:\windows\temp "C:\path to\file.exe"

When using PsExec, GetTempPathW returns C:\WINDOWS\Temp\

This also happens on Windows Server 2003 R2 64-bit and Windows Server 2003 64-bit.

However, when I run the following command, it works although file.exe is run as the Administrator user: paexec.exe /AcceptEula \\192.168.0.225 -u 192.168.0.225\Administrator -p password -c -f -csrc -c "C:path tofile.exe" file.exe

Any ideas?

Thank you very much.

asked 08 Aug '13, 00:15

rami's gravatar image

rami
1124
accept rate: 0%

edited 09 Aug '13, 15:16

Be the first one to answer this question!
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Tags:

×52
×17
×15
×12
×11

Asked: 08 Aug '13, 00:15

Seen: 7,526 times

Last updated: 09 Aug '13, 15:16