PowerShell Basics Flashcards

1
Q

What is the verb to create?

A

New-

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

What is the verb to retreive/show?

A

Get-

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

What is the verb to make a configuration change?

A

Set-

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

What is the verb to delete?

A

Remove-

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

What is the verb to rename?

A

Rename-

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

What is the shortcut to complete a partially typed command?

A

Tab

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

What is the shortcut to go back in a partially typed command?

A

Shift + Tab

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

What is the pipeline?

A

Passing data from one command through to another

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

Why is the pipeline useful?

A

It pipes data object, text that has to be parsed

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

What is the parameter to see the outcome of executing a command without doing it?

A

-WhatIf

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

What is the naming convention in PowerShell?

A

Verb-Noun

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

What is the cmdlet to retrieve a list of all verbs?

A

Get-Verb

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

What is the symbol used to get all values associated to a parameter?

A

*

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

How would you get all values beginning with a set of characters?

A

(characters) *

i. e: ms*

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

What separates a parameter and its value?

A

A space

i.e: -Name vm

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

What strings together multiple parameter values?

A

A comma

i.e: Computername CL1,CL2,CL3

17
Q

What is a positional parameter?

A

Parameters that are associated without specifying based on order

18
Q

How do you get all the values containing a set of characters?

A
  • (characters)*

i. e: dns

19
Q

What command wold you issue to search for the help files about commands?

A

Get-Help -Name about

20
Q

When should you update help?

A

After installing new roles and features

21
Q

How do you output a commands response to a file?

A

Out-File C:\Location\Filename.extension

22
Q

How do you see a list of previously executed commands within the current session?

A

Get-History

23
Q

How do you invoke a command that has previously been run?

A

Invoke-History -id n

*n is the number of command to be invoked

24
Q

How do you create a log of all the command made?

A

Start-Transcript C:\Location\Filename.extension

Stop-Transcript

25
Q

How do you list the contents of a directory?

A

Get-Childitem C:\

26
Q

How do you list the contents of a directory and its sub folders?

A

Gt-Childitem C:\ -Recurse

27
Q

What is the Get-Member command used for?

A

To get the properties and methods of objects

Properties are values associated with objects
Methods are things that can be performed on objects