7.1 Introduction to Windows Flashcards
While many IT professionals prefer Mac OS and Linux, _________ is still the leader for desktop operating systems.
While many IT professionals prefer Mac OS and Linux, Windows is still the leader for desktop operating systems.
_________ is one of the most important Windows tools for troubleshooting resource usage.
Task Manager is one of the most important Windows tools for troubleshooting resource usage.
True or False Command Prompt uses / like Linux
False
False Command Prompt uses ****
Linux variables are designated with a ___, while Windows ENV variables are enclosed with ___ signs.
Linux variables are designated with a $, while Windows ENV variables are enclosed with % signs.
_____________ is a tool used to query system information and diagnostics, such as OS and hard disk info.
Windows Management Instrumentation Command (wmic) is a tool used to query system information and diagnostics, such as OS and hard disk info.
wmic Structure and Conventions
Explain [global switches]
[global switches] are global commands called on by wmic. For example: wmic /APPEND:report.txt os get caption will append the Windows build number to report.txt file. This will add the output content to the file and not overwrite the file.
wmic Structure and Conventions
Explain [alias]
[alias] is the Windows component that wmic queries. Common aliases include: os (operating system): Contains properties specific to the operating system, such as the Windows edition name and build number. Logicaldisk: Contains properties specific to the disk drives, such as drive name, filesystem, free space, size, and volume serial number.
wmic Structure and Conventions
Explain [verbs]
[verbs] are actions we want to complete with the wmic command. For example, if we are using wmic os to find operating system information, we can then use the get verb, followed by the various [properties] we want to find.
wmic Structure and Conventions
Explain [properties]
Common [properties] to retrieve using get: get caption: Returns a one-line description of the given alias. get /value: Gets all of the properties and values of an alias and lists each on separate line.
Explain what this command will do:
wmic /APPEND:report.txt os get caption
It will append the Windows build number to report.txt
file. This will add the output content to the file, and **not** overwrite the file.
What does this command do: wmic /APPEND:report.txt useraccount get name, sid, description
Finds all user’s last login information, and all user info, SID, important directories, and files.
How would you list all the different values that can be retrieved from the os
wmic
alias.
wmic os get /value
Use net user
to:
Add, remove and manage users
Use net localgroup
to:
Add, remove and manage groups
Use net accounts
to:
View password and logon requirments for users to enforce password security policies
net lets us set the following password policies:
Time before a password expires. Minimum number of characters required for password. Minimum number of days before a password can be changed. Number of times a password must be unique before it can be reused again. E.g., if using the PW apples2apples, you’ll have to change it to two new passwords before you can use apples2apples again.
Common and Important Windows Directories
C:\
C:\ (or whichever root drive Windows is installed on) : is a root drive
Common and Important Windows Directories
C:\Program Files\
C:\Program Files\ is where 64-bit applications are installed.
Common and Important Windows Directories
C:\Program Files (x86)\
C:\Program Files (x86)\ is where 32-bit applications are installed.
Common and Important Windows Directories
C:\ProgramData\
C:\ProgramData\ [hidden] is a hidden directory where application-specific settings reside.
Common and Important Windows Directories
C:\Users\
C:\Users` is the directory for all users, including our sysadmin
user. This is similar to Linux’s /home
directory.
CMD Interaction and Navigation
What is cd
or chdir
?
cd
or chdir
is to change directories, just like with Linux’s cd
Common and Important Windows Directories
C:\Windows\System32\
C:\Windows\System32\ is where (counterintuitively) 64-bit main component Windows system applications configuration settings are located.
CMD Interaction and Navigation
What is dir?
Lists the contents of a directory, similarly to Linux’s ls
CMD Interaction and Navigation
What is md or mkdir?
Creates directories.
CMD Interaction and Navigation
What is del or erase?
Deletes files and directories. Directories will prompt a user to confirm. Note that files deleted with this command do not go to the Recycle Bin
, unlike when they are deleted with the GUI.
CMD Interaction and Navigation
What is rd or rmdir?
rd or
rmdir removes a directory if it's empty. Non-empty directories must be removed with
rmdir /S or
rd /S`.
CMD Interaction and Navigation
What is find?
find
will search a file for whatever is defined. For example, find "hello" greeting.txt
will search the greeting.txt
file for the string hello
.
CMD Interaction and Navigation
What is type?
type
followed by a file name will show the contents of a file. Similar to cat
in Linux.
CMD Interaction and Navigation
What is | more?
more` or “pipe more” shows contents of the command-line in a per-screen format.
Provide the corresponding Default Value :
%CD%
%DATE%
%OS%
%ProgramFiles%
%ProgramFiles(x86)%
%TIME%
%USERPROFILE%
%SYSTEMDRIVE%
%SYSTEMROOT%
%CD% ———————-Current directory
%DATE% ——————–Current date
%OS%————————Windows
%ProgramFiles%———Program Files
%ProgramFiles(x86)%–Program Files (x86)
%TIME% ——————–Current Time
%USERPROFILE%——-C:\Users{username}
%SYSTEMDRIVE%——C:\
%SYSTEMROOT%——C:\Windows
Was does WMIC
stand for?
WMIC
Windows Management Instrumentation Command
What is the WMIC query structure?
wmic [global switches] [alias] [verbs] [properties]