Remote process run by PAExec fails to get temporary folder or file, why?
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)
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"
This also happens on Windows 7 Enterprise 32-bit, Windows Server 2003 R2 64-bit, 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 to\file.exe" file.exe
Any ideas?
Thank you very much.