Sysinternals Homepage
Forum Home Forum Home > Sysinternals Utilities > PsTools
  New Posts New Posts RSS Feed - Psexec - process exited with error
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

Psexec - process exited with error

 Post Reply Post Reply
Author
Message
dexter View Drop Down
Newbie
Newbie


Joined: 11 April 2018
Status: Offline
Points: 3
Post Options Post Options   Thanks (0) Thanks(0)   Quote dexter Quote  Post ReplyReply Direct Link To This Post Topic: Psexec - process exited with error
    Posted: 11 April 2018 at 2:17pm
Hello. I'm trying to remotely execute a process using psexec. Both systems are logged in as the same local account with administrator rights. When I run the command:

psexec \\SYSTEM "c:\program files\..." 

It seems to successfully connects and load pstools on the remote system but I get an error back:

c:\program files\... exited on SYSTEM with error code -1066598274

Some searching lead me to believe this error has something to do with accounts not having local administrator rights. Like I said the account I'm using is a local account that is on both systems and are in the administrator group. I've tried running as the Administrator account with the same result. 

SYSTEM 1 is running Windows 7 Pro and SYSTEM 2 (remote) is running Windows Embedded POSReady 2009.

I have no issues using Pskill on this same setup. Please help. Thanks.


Edited by dexter - 11 April 2018 at 3:43pm
Back to Top
Aditza View Drop Down
Groupie
Groupie
Avatar

Joined: 07 November 2007
Location: .RO
Status: Offline
Points: 40
Post Options Post Options   Thanks (0) Thanks(0)   Quote Aditza Quote  Post ReplyReply Direct Link To This Post Posted: 14 April 2018 at 3:03am
on POSReady 2009 if you installed (as you should) the updates regularly then starting with kb4056615 it changes the way NTFS.SYS is processing the ACL rules.
https://www.catalog.update.microsoft.com/Search.aspx?q=kb4056615

this ntfs.sys change conflicts with some antivirus packages that expect a different ntfs.sys and when you try to create files you will get this error message in some folders:
"This security ID may not be assigned as the owner of this object. "
in my case the problem is with Symantec Endpoint Protection v12.1.6 MP9 - if i uninstall the antivirus then the error does not occur. Their support team in India is useless and at the end of january 2018 i gave up because their only concern was to close the ticket faster (it was 3-weeks old by that point, for a CRITICAL issue).
The problem with Symantec is still present today but i hope to dump any remaining POSReady 2009 systems by the end of the year because it becomes EOL in 2019.

in short: even if you have administrative or full access rights, if you are not the owner of the folder then you are not allowed to create new files in that folder.

the work-around solution is to take ownership of the folder where you are trying to create the files (or temporary files) because full-access or administrative rights are not enough anymore in this case.
Not even the SYSTEM account is spared from this feature/bug and a LOT of installs will fail with MSI pemissions errors.

This is also the reason why practically ALL Microsoft .NET framework patches for POSReady 2009 will fail to install on such systems - they try to use a temporary folder that is not OWNED by the SYSTEM account.
The solution for that is to use 'psexec -sdi ' and manually install the failing updates from a command-prompt that runs as SYSTEM account. Make sure to change the ntfs owner for "C:\Windows\Installer" to also be SYSTEM.

When the first setup screen appears then let it wait and go check that the permissions of the temporary folder used by the installer also have SYSTEM as the owner. This temporary folder is created by the .NET installer in the root of a random non-removable drive on the system and it will have a randomly-generated name.


Edit: hmmmm... i just saw that KB4101864 was published a few days ago... i'll have to test it next week, hopefully it fixes the owner-only file creation limitation.
https://www.catalog.update.microsoft.com/Search.aspx?q=KB4101864

File name File version File size Date Time Platform SP requirement Service branch
Ntfs.sys 5.1.2600.7459 576,640 02-Apr-2018 23:28 x86 SP3 SP3QFE

This update replaces the following updates:
2018-01 Security Update for Windows XP Embedded SP3 for x86-based Systems (KB4056615)



Edited by Aditza - 14 April 2018 at 5:06am
Back to Top
Aditza View Drop Down
Groupie
Groupie
Avatar

Joined: 07 November 2007
Location: .RO
Status: Offline
Points: 40
Post Options Post Options   Thanks (0) Thanks(0)   Quote Aditza Quote  Post ReplyReply Direct Link To This Post Posted: 16 April 2018 at 5:20am
update: just tested it, KB4101864 does indeed fix the ntfs acl error message "This security ID may not be assigned as the owner of this object" that appears when the user tries to create a new file, has full access rights but is not the owner of the folder.


Edited by Aditza - 16 April 2018 at 5:44am
Back to Top
dexter View Drop Down
Newbie
Newbie


Joined: 11 April 2018
Status: Offline
Points: 3
Post Options Post Options   Thanks (0) Thanks(0)   Quote dexter Quote  Post ReplyReply Direct Link To This Post Posted: 17 April 2018 at 12:36am
Thank you Aditza. I will try the update.
Back to Top
 Post Reply Post Reply
  Share Topic   

Forum Jump Forum Permissions View Drop Down

Forum Software by Web Wiz Forums® version 11.06
Copyright ©2001-2016 Web Wiz Ltd.