CompTIA A+ Exam 220-902 sub-objective 1.3: Given a scenario, apply appropriate Microsoft command line tools

Back to the main 902 ExamNotes page

Detailed (and official) description of CompTIA A+ sub-objective 1.3:

1.3 Given a scenario, apply appropriate Microsoft command line tools.
TASKKILL
BOOTREC
SHUTDOWN
TASKLIST
MD
RD
CD
DEL
FORMAT
COPY
XCOPY
ROBOCOPY
DISKPART
SFC
CHKDSK
GPUPDATE
GPRESULT
DIR
EXIT
HELP
EXTRACT
[command name] /?
Commands available with standard privileges vs. administrative privileges

Welcome to ExamNotes by CertBlaster! In this section we will be looking at Microsoft command line tools. The knowledge of these commands and how they are used will save you time hunting down the new locations of your tools. They will always be in the “path” and easily accessible from the command prompt. These commands highlight the need for an in depth knowledge of the filesystem structure. Also notable here are commands that require elevation of privileges better known as “Run as Administrator”

We are given the commands as a list so we will treat them in that manner here. Remember that for any command typing command /?  will display the help text for that command including a list of the available parameters and their usage.

TASKKILL

This command ends one or more tasks or processes. TASKKILL is the replacement for the KILL tool. Processes can be ended by Process ID (PID) or image name.

BOOTREC

Is used to repair the Master Boot Record and the BCD Store on Windows Vista and later systems that are having startup problems. Some available options on this command are BOOTREC/FIXMBR. BOOTREC/FIXBOOT, and BOOTREC/FIXBOOT.

SHUTDOWN

Allows you to restart or shutdown a remote or local computer. In the default behavior SHUTDOWN logs off the current user the equivalent of the –l parameter. The –m parameter allows you to specify the computer you want to shut down and –s shuts down the local computer.

TASKLIST

Displays a list of the currently running processes. It can be used locally or on a remote machine. Its output can be modified using the parameters and filters shown on the help screen.

MD

Makes a directory (as in Make Directory) or subdirectory. If a path is not specified it will create the directory in the current location using the command and the desired directory name. If a path to another location in the file structure is specified the directory will be created there. This command is available from the Recovery Console. The mkdir command is used the same way, but is not listed in your test objectives.

RD

Deletes or removes a directory (as in Remove Directory) provided that the directory is empty contains no hidden or system files. You cannot delete the directory you are working in. This command is available from the Recovery Console.

CD

Displays the name of the current directory if used without parameters. It can also move to another directory (as in Change Directory) in a path is supplied. For example cd C:\Temp will move the prompt into the Temp directory on the C: drive if it exists. CD\ will take you to the root of your current drive. CD..  will take you to the parent directory of the current directory. The /D parameter is used when moving to a different disk or drive. The command is not case sensitive. The CHDIR command is used the same way but is not listed in your objectives. This command is available from the Recovery Console.

DEL

This command should be used with caution. The del command (as in DELete) will delete files and directories. Even directories containing directories. It is not advisable to use wildcards with del.  The files and directories deleted may be impossible to recover without specialized software. This command is available from the Recovery Console.

FORMAT

The Format command is used to create a new root directory and file system on a disk. When using Standard formatting (format C: /p) all data is overwritten with zeroes. Using the quick option (format C: /q) deletes the master file table and the root directory of a previously formatted disk. It does not zero out the sectors, meaning that the data is still present and recoverable with specialized software. This command is available from the Recovery Console.

COPY

There are several ways to move data  Each is best described using the help screen for the command. For copy you need to specify one or more source files and the destination path and filename(s). Use caution when copying multiple files. If the destination is not properly defined copy will combine all source files into a single file. Copy will not copy files that are zero bytes long use Xcopy (next) for those files. This command is available from the Recovery Console.

XCOPY

XCOPY copies files and directories including directory structure. Can copy zero byte files. There are multiple parameters. Practically /a to/z. Don’t worry about them concentrate on source and destination.

ROBOCOPY

ROBOCOPY (as in Robust File Copy, with an extra “o’ to be cool…) is a powerful file copy utility that was introduced as a standard feature in Windows Vista. It is capable of copying, moving or deleting files and directories. It is also capable of among other things the ability to create mirror images of entire directory trees. As well as allowing the administrator to copy data that he does not have permission to view. One drawback that prevents use on live machines is the fact that Robocopy cannot copy an open file. As you know as our systems become more complex they can open and close files that support processes so you can’t be 100% sure of a complete copy. Shadow copies are best suited to get a complete copy.

DISKPART

This is the command line replacement for the venerable fdisk command. With it you can add or delete partitions on system disks. This command is available from the Recovery Console.

SFC

SFC is the System File Checker. It is executed after a reboot and is scans all protected system files and verifies their versions and integrity.

CHKDSK

There are two operational modes of chkdsk one is available in the Recovery Console and the other can be scheduled from the drives properties window or the command line. The command checks the hard drive for errors and can attempt to recover data from bad sectors. The drive has to be locked during the process requiring the reboot.

GPUPDATE

Refreshes local and Active Directory Group policy and security settings.

GPRESULT

Displays the Resultant Set of Policy (RSoP) for a remote computer and user.

DIR

This is the command that displays file and directory information from a command prompt. This command is available from the Recovery Console.

EXIT

Is the command that is used you exit the Recovery Console and restart the machine.

HELP

Executed with no parameters HELP displays a list of commands that can be run from the command prompt that have Help documentation. For information about a specific command type HELP command name. This command is available from the Recovery Console. This information can also be obtained by typing the command name and /?

EXTRACT

Exatract is the command that is used to access files in a Windows cabinet file.

[command name] /?

Operates like HELP on a specific file.

Commands available with standard privileges vs. administrative privileges

If you are operating as a standard user you may have problems executing some commands that Microsoft deems too risky for the average user. To bypass this issue you can right click on any Command Prompt shortcut and choose Run as administrator. You can tell you are running as administrator when your Prompts title bar shows Administrator: Command Prompt and you are working in the C:\Windows\System32\> directory.

That’s it these are all the commands in A+ 22-902 sub-objective 1.3: “1.3 Given a scenario, apply appropriate Microsoft command line tools.” Pobably the best way to really learn these is to run them on a PC. Having said that look out for commands such as DEL or FORMAT as they can be pretty terminal on you system and/or data!

Back to the main 902 ExamNotes page

Good luck on the exam!

 

 

Leave a Reply

Your email address will not be published. Required fields are marked *

On Facebook

Share This
Real Time Web Analytics