Categories:
Administration (10)
Adware Spyware (7)
Apache (10)
Bluetooth (125)
DOS Commands (1)
Edge (28)
General (2)
Internet Explorer (217)
Media Center (12)
Media Player (11)
Mozilla Firefox (18)
PHP (15)
Programming (8)
Security (4)
Silverlight (15)
Tips (17)
Tools (218)
Tutorials (5)
Windows 10 (166)
Windows 7 (636)
Windows 8 (1091)
Windows Phone (33)
Windows Server 2008 (165)
Windows Server 2012 (84)
Windows Server 2016 (23)
Windows Vista (52)
Collections:
Other Resources:
"Invoke-Command -AsJob" - Remote Background Jobs in PowerShell
How to start a background job on a remote computer in Windows PowerShell?
✍: FYIcenter.com
You can use the "Invoke-Command -AsJob" cmdlet to start a background job on
a remote computer.
Actually, the "Invoke-Command -AsJob" cmdlet is creating a local background job that runs the specified command on a remote computer. So "Invoke-Command office-server -AsJob {...}" is similar to "Start-Job {Invoke-Command office-server {...}}".
Here is an example of using the "Invoke-Command -AsJob" cmdlet:
PS C:\fyicenter>Invoke-Command office-server -ScriptBlock {Get-EventLog system} -AsJob Id Name State HasMoreData Location Command --- ---- ----- ----- ----------- --------------- 1 Job1 Running True office-server Get-EventLog system
Â
⇒ Introduction of Windows PowerShell ISE
⇠"Remove-Job" Cmdlet in Windows PowerShell
⇑ Managing Windows PowerShell Background Jobs
⇑⇑ Windows PowerShell Tutorials
2016-10-05, 3840👍, 0💬
Popular Posts:
How much does Windows Media Player 11 cost Windows Media Player 11 is a free update to the Windows M...
Can I disable Windows service "ASP.NET State Service" to speedup my computer? Windows service "ASP.N...
Understanding HelpSvc.exe, "Microsoft Help Center Service" - part of the "Help and Support Center" a...
In my MS Access 2000 database, I have 4 tables: Bank, Client, Account, and Transaction. How to build...
How to download and install HiJackThis? If you want to download and install HiJackThis to your Windo...