invoke-command remote install

Hello All,

I’m trying to install a client on remote machines.

I copy exe to local folder with Copy-Item and that works without issues however when i’m trying to install it either stays in running state without anything happening on the client, or it would say complete and again nothing installed on the client.

i tried Invoke-Command -computername “test” -scriptblock {c:\folder\dump.exe \silent \norestart \install} AsJob

as well as

Invoke-Command -computername “test” -scriptblock {Start-Process -Wait -FilePath ‘c:\folder\dump.exe’ -ArgumentList “\silent \norestart \install”} AsJob

Anything i am missing?

I should add that if i run Start-Process -Wait -FilePath ‘c:\folder\dump.exe’ -ArgumentList “\silent \norestart \install” locally it works just fine

I can also run invoke-command -computername “test” -scriptblock {get-item -path ‘c:\folder\dump.exe’) and exe info

 

Looks like it requires interactive session to install the client, just a guess…

Can you try once with psexec which has interactive execution capability.

https://ss64.com/nt/psexec.html

Use the -i option and see if its getting installed or not.