PowerShell Remoting: On execution of a command to start an exe (wmplayer for example), can't see the actual UI


i have test bed in lab consisting of windows server 2008 running powershell 2.0. using server manage 50 clients  connected wired , wireless server. running windows active directory on server , clients in domain created , using ad push different policies. have lot of basic scripts running (shutting down interfaces on clients, shutting down clients, fetching logs clients etc.). there 1 task in particular extremely important setup , facing lot of issues it. here details:

------------------------------------------
want start applications windows media player or vlc player on clients through script. script run on server , should try , establish connection clients , bring ui.

has been tried?

method 1:
**new-pssession -computername <computer_name> -credential <cred>
enter pssession -id <id>**

(brings prompt on remote machine)
**start-process wmplayer.exe**

runs correctly. process gets created on client, not see ui.

method 2:
created batch file on remote machine runs wmplayer.exe. works fine , brings ui if executed manually client, again if triggered remotely creates process , not bring ui.

missing while running commands? need configure more ui , running?

lot in advance.

-jenil

i think find answer here: http://msdn.microsoft.com/en-us/library/aa389769(v=vs.85).aspx.

"you can use win32_process.create execute script or application on remote computer. however, security reasons, process cannot interactive. when win32_process.create called on local computer, process can interactive.

...

you can use win32_scheduledjob.create create interactive process remotely. processes started win32_scheduledjob.create run under localsystem account can confer privilege."

so should go scheduledjob :) problem wmi class uses "at" job style deprecated since windows 8. maybe @ scheduledjob windows 7/vista machines , go "advanced" scheduled tasks in windows 8 powershell:
- scheduled tasks cmdlets in windows powershell http://technet.microsoft.com/en-us/library/jj649816(v=wps.620).aspx 

it looks dirty option can still use schtasks command so. create task read file video.mp4 somewhere in network , call tasks remotely every time need display video. instead of deleting tasks @ end, let without trigger , change video file in case need display video. don't see use of though besides massive prank users :) have other way inform users, logon message, ie homepage, emails, im etc.



Windows Server  >  Windows PowerShell



Comments

Popular posts from this blog

Error: 0x80073701 when trying to add Print Services Role in Windows 2012 Standard

difference between wuauclt1.exe and wuauclt.exe

Windows 2016 RDS event 1306 Connection Broker Client failed to redirect the user... Error: NULL