Bird
0
0

Which of the following best describes the function of the Invoke-Command cmdlet in PowerShell?

easy📝 Conceptual Q1 of 15
PowerShell - Remote Management
Which of the following best describes the function of the Invoke-Command cmdlet in PowerShell?
AList all running processes on the local machine
BCreate new PowerShell sessions
CExecute commands or scripts on local or remote computers
DSchedule tasks to run at a later time
Step-by-Step Solution
Solution:
  1. Step 1: Understand Invoke-Command

    The cmdlet is designed to run commands or script blocks either locally or remotely.
  2. Step 2: Evaluate other options

    Creating sessions is done with New-PSSession, listing processes with Get-Process, and scheduling tasks with Task Scheduler or Register-ScheduledJob.
  3. Final Answer:

    Execute commands or scripts on local or remote computers -> Option C
  4. Quick Check:

    Invoke-Command runs commands remotely or locally [OK]
Quick Trick: Invoke-Command runs commands remotely or locally [OK]
Common Mistakes:
  • Confusing Invoke-Command with New-PSSession
  • Thinking it only works locally
  • Assuming it schedules tasks

Want More Practice?

15+ quiz questions · All difficulty levels · Free

Free Signup - Practice All Questions
More PowerShell Quizzes