#!/bin/sh Line used in a script to execute with the Bourne shell, or a compatible shell, with path /bin/sh.   Wikipedia         
$host.PrivateData.ErrorBackgroundColor Error background color in PowerShell.            
$host.UI.RawUI.BackgroundColor             
/? displays help            
AAA IOS Configuration
username (name>) privilege 15 secret (password)
aaa new-model
aaa authentication login { default | (list-name) } local enable
aaa local authentication attempts max-fail (number-of-unsuccessful-attempts)
tacacs-server host (server IP) single-connection
tacacs-server key (key)
username JR-ADMIN secret Str0ngPa55w0rd
username ADMIN secret Str0ng5rPa55w0rd
aaa new-model
aaa authentication login default local-case enable
aaa authentication login TELNET-LOGIN local-case
aaa local authentication attempts max-fail 3
line vty 0 4
login authentication TELNET-LOGIN
Add-Computer PowerShell command to add a computer to a domain or workgroup.
PS C:\> Add-Computer -DomainName Domain01 -Restart |
PS C:\> Add-Computer -WorkGroupName WORKGROUP-A |
adduser Bash command to add a user account. sudo adduser username
   Linuxers         
append Adds to the end of a file. Use >>
instead of >
.   Wikipedia         
apropos Linux utility used to search for other utilities.            
arp -a DOS command used to list current ARP cache.            
arp -d DOS command used to refresh the ARP cache.            
assoc Command that displays or modifies file extension associations.   Wikipedia  Microsoft Support       
at Command that schedules other commands and programs to run on a computer.   Wikipedia  Wikipedia       
ATTRIB DOS command that displays or changes file attributes.   Wikipedia         
background (bg) Send a job to the background.   Website  Wikipedia       
bang bang (!!
) Executes the previous command in UNIX.   Wikipedia         
cacls Windows command that displays or modifies ACLs of files.   Wikipedia         
call Command that calls one batch program from another.   Microsoft         
cd Command that displays the name of or changes the current directory.   Wikipedia         
change mode (chmod) chmod
UNIX command used to change access permissions. Example:
chmod -x script_name | Makes a script executable |
chcp DOS command that displays or sets the active code page number.            
CHDIR Displays the name of or changes the current directory.   Wikipedia         
CHKDSK DOS command that checks a disk and displays a status report.   Wikipedia         
CHKNTFS DOS command that displays or modifies the checking of disk at boot time.   Wikipedia         
chsh Linux command to change the shell.            
clear Command that clears the screen.            
clock set Set the time and date. Use show clock
to display the time in IOS.            
cls DOS command that clears the screen.            
cmd DOS command that starts a new instance of the Windows command interpreter.            
Cmdlet Commands used in PowerShell. Follow a Verb-Noun naming convention. (i.e.
color DOS command that sets the default console foreground and background colors. (color a, color b2...)            
COMP Compares the contents of two files or sets of files.            
COMPACT DOS command that displays or alters the compression of files on NTFS partitions.            
Compare-Object (aliases: compare, diff) PowerShell cmdlet that compares two sets of objects. Example:
Compare-Object $foo $bar |
concatenation (cat) Can show one or more files together in the same output. The command split
can separate files while cat
can merge files.   Wikipedia  YouTube       
CONVERT DOS command that converts FAT volumes to NTFS.             
copy Command that copies one or more files to another location in DOS or IOS. Use cp
for Bash.            
cp Command that copies one or more files to another location in Bash. (copy for DOS.)            
createinstallmedia Terminal command used to create a bootable installer for macOS.   Apple Support         
date Command that displays or sets the date and time in many operating systems. Examples:
Linux: | sudo date -s "Jul 5 08:10" | |
Windows: | date | (Output is the same as Get-Date in PowerShell) |
dd Vi command used to delete the current line.            
ddate Shows the Discordian date.     About.com       
debug ip bgp             
debug ip nat s=source address, a.b.c.d--->w.x.y.z=source address--->translated address, d=destination ip address, [xxxx]=ip identification number            
del Command that deletes one or more files. Use rm
in UNIX.   Wikipedia         
dir Command that displays a list of files and subdirectories in a directory. Use ls
in UNIX-based systems or Windows through PowerShell.   Wikipedia  TechNet       
DISKCOMP Compares the contents of two floppy disks.            
DISKCOPY Copies the contents of one floppy disk to another.            
DISKPART DOS command used to manage disk partitions.    TechNet         
dism.exe /online /cleanup-image /restorehealth Command that will attempt to repair your corrupted file from a trusted online source (Windows Update). Requires administrative privileges.   Tom's Hardware         
DOSKEY Edits command lines, recalls Windows commands, and creates macros.            
dpkg (Debian package) A command that can be used to install and remove packages in a Debian based OS. It can also be used to view the currently installed packages.   Wikipedia         
dpkg-reconfigure tzdata Reconfigure the date and timezone on a Debian-based Linux distribution. Example:
sudo dpkg-reconfigure tzdata |
echo A command that prints to the display whatever it is told to say or turns command echoing on or off.
echo $0 | Linux command that will return the name of shell you are working in or the currently running program. |
enable Command that enters privilege EXEC mode on a network device.            
Enable-WindowsOptionalFeature PowerShell command to enable features in Windows. Example:
Enable-WindowsOptionalFeature -Online -FeatureName Microsoft-Hyper-V | Enable Hyper-V |
ENDLOCAL Command Prompt command that ends localization of environment changes in a batch file.            
erase Command that deletes one or more files.            
exit Quits the CMD.EXE program (command interpreter).            
fc Command that compares two files or sets of files, and displays the differences between them.            
fi Closes an if
statement in Bash.   Stack Overflow         
File Checksum Integrity Verifier (FCIV) Command-prompt utility that computes and verifies MD5 or SHA-1 cryptographic hash values of files.   Microsoft Support         
find Command that searches for a text string in a file or files.            
findstr Command that searches for strings in files.            
FOR DOS command that runs a specified command for each file in a set of files.            
ForEach-Object PowerShell cmdlet.   TechNet         
foreground (fg) Send a job to the foreground.   Wikipedia         
form Used to gather information.            
FORMAT DOS command that formats a disk for use.            
Format Set of PowerShell cmdlets that allow you to control which properties are displayed for particular objects.   TechNet         
FROM DOS command.            
FROM SQL command.            
FTYPE DOS command that displays or modifies file types used in file extension associations.   Wikipedia         
Get-Date PowerShell command that displays the date and time.   TechNet         
Get-ExecutionPolicy             
Get-History PowerShell cmdlet that shows the history of the shell.            
Get-Host PowerShell command that information about the installed version of PowerShell.   StackOverflow         
Get-Item WSMan:\localhost\Client\TrustedHosts             
Get-Member (gm) PowerShell cmdlet. Displays the properties and methods of an object.            
Get-NetConnectionProfile PowerShell cmdlet that gets a connection profile. Introduced in Windows Server 2012 and Windows 8.  TechNet         
Get-NetIPAddress PowerShell cmdlet that displays the IP address configuratoin. Introduced in Windows Server 2012 and Windows 8.  TechNet         
Get-NetIPConfiguration PowerShell cmdlet.            
Get-Process PowerShell command to show the running processes on a computer.    TechNet         
Get-SmbServerConfiguration PowerShell cmdlet used to check the status of SMB. Get-SmbServerConfiguration | Select EnableSMB1Protocol
   Microsoft Support         
Get-WindowsDriver PowerShell cmdlet that displays driver information. Example: Get-WindowsDriver -Online -All
   TechNet         
Get-WmiObject SoftwareLicensingService PowerShell command that returns the Windows Licence Key.   The Windows Club         
Get-WmiObject Win32_ComputerSystem Display system information in PowerShell.            
git commit             
git config --list             
git init Command in Git to start tracking a project and create the .git
directory.   Git Documentation         
git log             
GNU zip (gzip) Compresses files but not directories. Initially released October 31, 1992  Wikipedia         
GOTO Jump between parts of a program.   Wikipedia         
gpupdate Command to update group policy.
/force |
GRAFTABL Enables Windows to display an extended character set in graphics.            
grep Utility that searches strings of text using regular expressions. First released November 1974.  Wikipedia         
head Command that displays the beginning of a file. Tail shows the end.   Linux 101 Hacks  YouTube       
help Command that provides Help information. Examples include;
? |
/? |
-help |
--help |
Get-Help |
HOME ~ Environment variable for the home directory in Bash. Use echo $HOME
or echo ~
to display.            
hostname The network name of a host. Can be show in the CLI of Windows and UNIX-Like operating systems by entering hostname
.   Wikipedia         
if Performs conditional processing in programs or batch files. Pseudo code: if red {do option 1} else {do option 2}
   Wikipedia         
ifconfig Command that displays network information such as the current IP address on a UNIX based computer Use ipconfig
on Windows.   Wikipedia         
include PHP statement. include 'example.php'
   PHP Documentation         
inline-block CSS value for the display
property. Ued to arange boxes.   W3Schools         
Install-WindowsFeature PowerShell command to install rolls, services, or features to Windows Server.
Install-WindowsFeature Server-Gui-Mgmt-Infra,Server-Gui-Shell -Restart | Install a GUI on Server Core |
interface loopback Cisco IOS command used to configure a loopback address.
Router(config)# interface loopback value
INTO SQL command used in databases to specify a table name.            
Invoke-Expression PowerShell cmdlet. Invoke-Expression
or iex
            
Invoke-WebRequest PowerShell cmdlet. Invoke-WebRequest
or iwr
            
ip route Command to configure a static route.
ipaddress Python library for manipulating IP addresses.   Python Documentation         
ipconfig Command that displays network information such as the current IP address on a Windows based computer. Use ifconfig
on a UNIX-based machine.
Options: | |
---|---|
/all | Display full configuration information. |
/displaydns | Display the contents of the DNS Resolver Cache. |
/flushdns | Purges the DNS Resolver cache. |
/registerdns | Refreshes all DHCP leases and re-registers DNS names. |
/release | Release the IPv4 address for the specified adapter. |
/release6 | Release the IPv6 address for the specified adapter. |
/renew | Renew the IPv4 address for the specified adapter. |
/renew6 | Renew the IPv6 address for the specified adapter. |
/setclassid | Modifies the DHCP class id. |
/setclassid6 | Modifies the IPv6 DHCP class id. |
/showclassid | Displays all the DHCP class IDs allowed for adapter. |
/showclassid6 | Displays all the IPv6 DHCP class IDs allowed for adapter. |
IS NOT NULL SQL operator for data that is present or known.   W3Schools         
IS NULL SQL operator for data that is missing or unknown.   W3Schools         
label DOS command that creates, changes, or deletes the volume label of a disk.            
LIKE SQL   W3Schools         
Line Printer (lpr) Command that sends a file to the printer. Exameple: lpr foobar
   CUPS  Microsoft       
lm-sensors CLI tool that can monitor temperature, fan speed, and voltage.   Ubuntu Community  Websiste       
ls UNIX command that displays the contents of a directory.   Wikipedia         
mkdir Command that creates a directory.   Wikipedia         
MODE Configures a system device.            
MORE Displays output one screen at a time. Can be used to open files in the command line.   Wikipedia         
mountvol Creates, deletes, or lists a volume mount point. Mountvol is a way to link volumes without requiring a drive letter.   TechNet         
MOVE Moves one or more files from one directory to another directory in DOS. Use mv
in UNIX-based operating systems.
syntax: move [file name to move] [destination]
mv UNIX command that moves files. Use move
on Windows-based systems.
syntax: mv (file name to move) (destination) |
nbtstat Displays protocol statistics and current TCP/IP connections using NetBIOS over TCP/IP (NBT).   Wikipedia  Netacad       
ncpa.cpl Command to open Network Properties in Windows. Introduced with Windows NT 4.0. July 31, 1996  Microsoft         
net start wuauserv    Website         
net stop wuauserv    Website         
net user Adds or modifies user accounts, or displays user account information. Examples:
net user Administrator /active yes | Enables the Administrator user account. |
net localgroup administrators {username} /add |
netplwiz  Adjust Windows user account settings including automatic login.    About.com       
netstat (aka: network statistics) Command-line utility the displays incoming and outgoing TCP connections, including port usage. Example:
netstat -a | Displays all active connections on which the device is listening. |
network shell (netsh) Command line utility in Windows used to modify the network configuration.   Wikipedia  TechNet (Using Netsh)       
new line python: \n
            
nice Example: nice -n19 vi
            
no shutdown command that turns a network devices interface on            
noclobber Shell parameter that will prevent clobbering a file. set -o noclobber
(bash, ksh) or set noclobber
(csh, tcsh)   Wikipedia         
nslookup Command to manually query the name servers to resolve a given hostname. Can also be used to troubleshoot name servers.            
or ||
            
ORDER BY             
passwd Command to change a password in Linux.            
PATH Environment variable that displays or sets a search path for executable files.   Wikipedia  LINFO       
PAUSE DOS command that suspends processing of a batch file and displays a message.            
popd Restores the previous value of the current directory saved by PUSHD.   Wikipedia         
POST POST and PUT are used to upload data files to the web server. When a user submits data in a form the POST message is sent along with the data.            
PowerShell Windows Command Prompt with a more Linux feel. Comes in blue by default. First released November 14, 2006.  Website  Wikipedia  PowerShell.org     
PRINT DOS command that prints a text file.            
process status (ps) Displays the currently-running processes.   Wikipedia         
PROMPT Changes the Windows Command Prompt.            
psdrive             
pstree Shows the running processes as a tree in Bash.   Wikipedia         
PSVersionTable ($PSVersionTable
) PowerShell variable that contains information regarding the installed PowerShell version.
$PSVersionTable.PSVersion |
pushd Saves the current directory then changes it.   Wikipedia         
PUT POST and PUT are used to upload data files to the web server. PUT uploads resources or content to the web server such as an image or file.            
pwd Command that prints the working directory.            
question mark (?
Can be used in IOS to show the rest of a command.            
rand =rand(x,y) Adds random text to a word document.            
raw_input() Wait for 'Enter' to be pressed before terminating in Python.   StackOverflow         
rd Command that removes a directory.            
Read-Host PowerShell cmdlet that prompts a user for input.   TechNet         
RECOVER DOS command that recovers readable information from a bad or defective disk.   Wikipedia         
REM Command that records comments (remarks) in batch files or CONFIG.SYS.            
ren Bash Command that renames a file or files in.   Wikipedia         
rename DOS command that renames a file or files.   Wikipedia         
Rename-Computer PowerShell command to change the hostname after restart.
Rename-Computer -NewName DC1 -Restart |
Rename-Item (aka: ren, rni) PowerShell cmdlet used to rename files and folders.   TechNet  Wikipedia       
replace DOS command that replaces files.            
Restart-Computer PowerShell command that restarts Windows.            
Restart-NetAdapter PowerShell command to restart a network adapter by disabling and then re-enabling the network adapter.
PS C:\> Restart-NetAdapter -Name "Ethernet 2"
Restart-Service PowerShell command to restart services.
Restart-Service -Name Spooler -Force | Restart the print spooler. |
Resultant Set of Policy (RSoP) Command rsop
   TechNet         
rm UNIX command to delete. Use del
in DOS or OS/2.   Wikipedia         
rmdir DOS command that removes a directory.            
Robust File Copy for Windows (ROBOCOPY)    Wikipedia  Microsoft TechNet       
route -n Linux command to show the routing table. (Use route print
for Windows.)            
route print Shows the routing table in Windows. (Use route -n
for Linux.)            
router eigrp IOS command used to enable EIGRP (no router eigrp turns it off)            
router rip command used on routers to enable RIP            
rsync Backup utility for Linux-based computers.   Wikipedia         
scutil Command used on a Mac to set the hostname.   OS X Man Pages         
Secure Copy (SCP) (TCP port 22) Secure way to copy files between two computers. Example: scp SourceFile user@host:directory/TargetFile
   Wikipedia  John Veldboom       
SELECT SQL statement that returns a set of records from one or more tables. Main data retrieval command in SQL.   Wikipedia         
SET Displays, sets, or removes Windows environment variables.            
Set-Date PowerShell command that changes the date or time.   TechNet         
Set-Item WSMan:\localhost\Client\TrustedHosts -Value hostname -Force             
Set-ItemProperty PowerShell cmdlet. Can be used to change registry values. Introduced in PowerShell 3.0.  TechNet         
Set-NetConnectionProfile PowerShell cmdlet that changes the network category of a connection profile. Introduced in Windows Server 2012 and Windows 8.  TechNet         
Set-SmbServerConfiguration PowerShell cmdlet used to disable SMB1. Set-SmbServerConfiguration -EnableSMB1Protocol $false
   Microsoft Support         
SETLOCAL Begins localization of environment changes in a batch file.            
show commands Commands in Cisco IOS that show.., stuff.
show arp | IOS command to show the ARP table. |
show interfaces | |
show ip eigrp neighbors | |
show ip eigrp topology | |
show ip interface brief | Command to show a list of interfaces and any IPv4 addresses that might be assigned to them. Use show ipv6 interface brief to show IPv6 interfaces |
show ip ospf | process ID, router, id, OSPF SPF, OSPF, area information |
show ip ospf database | Shows LSDB area, link id |
show ip ospf interface | Shows details about all OSPF enabled interfaces the router ID. |
show ip ospf interface interface id | Details about a particular OSPF enabled interface |
show ip ospf interface brief | Concise OSPF-related information of OSPF-enabled interfaces, OSPF process id, area, cost, brief |
show ip ospf neighbor | OSPF adjacencies and the router IDs of those routers |
show ip protocols | Shows the protocols on a router. OSPF process ID, router ID, advertised networks, neighbors the router is receiving updates from, and the administrative distance. |
show ip route | Command used to display IPv4 routing table of a router |
show ip route eigrp | |
show ip route ospf | Shows only OSPF routes in the routing table |
show ipv6 route | Shows the IPv6 routing table on a network device |
show running configuration | Shows the running configuration file |
show flash | Contents of the flash |
show boot | Location of the configuration file |
show version | Current IOS version |
show ip bgp ipv4 unicast             
show license             
show spanning-tree             
shutdown Command that turns a network devices interface off.            
Shutdown /o Go to the advanced boot options menu and restart the computer. Must be used with /r option. Introduced in Windows 8.  MSDN  The Windows Club       
socket.gethostname() Prints the hostname in python. import socket
   Python Documentation         
socket.gethostname()
SORT Command that sorts input.            
Sort-Object Used to sort objects in PowerShell.   TechNet         
spanning-tree cost
syntax: spanning-tree cost (value 1-200,000,000) |
split Split can separate files while cat can merge files.   YouTube         
ssh -p (port number between 1025 and 65536) (username@server ip address) Linux SSH login.            
standard error 2>
            
standard input Comes from the keyboard by default. 0<
(Shorthand: <
)            
standard output Goes to the display by default. 1>
(Shorthand: >
)            
START Starts a separate window to run a specified program or command.            
Start-Process powershell -Verb runAs Start PowerShell as Administrator.   StackOverflow         
Stop-Process  Introduced with PowerShell version 1.0.  TechNet         
Structured Query Language (SQL) Special programming language made for databases. Not case sensitive but best practice is to write commands in all-caps.   Wikipedia  W3Schools  Khan Academy     
SUBST DOS command that associates a path with a drive letter.            
substitute user (su
) Execute a command as another user.            
sudo    Website         
SYS    Wikipedia         
Système International (SI) (aka: International System of Units or metric system)   Wikipedia         
systeminfo Command that displays the system information of a Windows based system.            
tail Command that displays the end of a file. (head
shows the beginning.) For example tail -f /var/log/messages
can be used with the -follow
switch to see syslog messages and print new data as the file grows.   Wikipedia  YouTube  Linux 101 Hacks     
tar (tape archive) Both a file format and a program. Example:
tar -zxvf |
tee Outputs to a file and writes to standard output.   Wikipedia         
terminal length Used in conjunction with another command to specify number of lines displayed in terminal.            
test Builtin utility for Bash. Brackets [ ]
can be put around what is being tested instead.            
Test-Path PowerShell cmdlet.            
time Used to determine the duration of execution for a particular command.   Wikipedia         
time Command that displays or sets the system time. Use date
for UNIX-based systems or clock set/show clock
for IOS.   Wikipedia         
title Command that sets the window title for a CMD.EXE session.            
traceroute Network Command-line utility that displays the path (route) and measures the delay of packets. Traces packets to a destination address for troubleshoot issues. UNIX-like systems use traceroute
, while Windows-based systems use the shorter tracert
.   Wikipedia         
tracert Windows version of the traceroute command. Use traceroute
for UNIX based systems.   Wikipedia         
translate (tr) Replace or remove specific characters in its input data set.   Man Page  Wikipedia       
tree Command to graphically display the directory structure of a drive or path.   Wikipedia         
type Shell builtin. Command that describes how its arguments would be interpreted if used as command names. Added to the Bourne Shell in 1984.  Wikipedia (UNIX)         
TYPE Command that displays the contents of a text file.   Wikipedia (DOS)         
uname Unix command to display the name and version of the computer. Use ver
or winver
on Windows.            
uptime The amount of time a computer has been on since the last reboot. Can be viewed on UNIX-like systems with the uptime
command. Use wmic os get lastbootuptime
(written as: yyyymmddhhmmss.nnn) for Windows.   Wikipedia         
useradd Bash command to add a user account.   Linuxers         
VALUES Used with INSERT INTO to tell the DBMS what to insert.   Wikipedia  Wikipedia       
variable Named memory location that stores the current value of a data type. Can be integer, real number, string, or Boolean. Shell Examples:
Bash | VARIABLE=value | echo $VARIABLE |
tcsh | set VARIABLE = value | echo $VARIABLE |
PowerShell | $VARIABLE = value | Write-Output $VARIABLE |
vcgencmd measure_temp Show raspberry pi temprature.            
ver DOS command used in to displays the OS version. Use uname
on UNIX.   Wikipedia         
verify Command Prompt command that tells Windows whether to verify that your files are written.            
vi Text editor that is standard in most UNIX based operating systems. vi comes from the visual mode in the ex text editor.   YouTube  Linux Command       
virsh Command line tool for managing guests and the hypervisor.   CentOS Docs  Oracle Documentation       
visudo Configure root privileges            
vol Displays a disk volume label and serial number in DOS.            
Wildcard mask The inverse of a subnet mask. 255.255.255.255 - subnet mask = wildcard address (0.0.0.255 wildcard for a 255.255.255.0 subnet). When configured with the network command in EIGRP, it is used to exclude some interfaces from the EIGRP process. Minimize load cost and SPF calculations in OSPF.             
Windows Management Instrumentation Command-line (WMIC) Command line version of WMI.   Wikipedia         
winver Displays the Windows version.   Wikipedia         
Write-Debug PowerShell cmdlet.            
Write-Error PowerShell cmdlet.            
Write-Host PowerShell cmdlet.            
Write-Information PowerShell cmdlet.            
Write-Output PowerShell cmdlet.            
Write-Progress PowerShell cmdlet.            
Write-Verbose PowerShell cmdlet.            
Write-Warning PowerShell cmdlet.            
xcopy Command Prompt command that copies files and directory trees.            
yank y
Copy text inside of vim.   Vim Wiki