Linux Basics Flashcards
cp
cp: Copy file
Copies file and keeps both copies
mkdir
mkdir: Make directory
Creates a new directory
Directories in Linux are the same as folders in Windows
vim
Used to edit any text based file in terminal
rm
rm: Remove
Deletes a file
mv
mv: Move file
Moves a file into another directory or subdirectory
rm -r
rm -r: Remove recursively
Delete an entire directory and all of its contents
touch
Creates a blank file; can be used to verify write permissions in a directory or to work around error messages showing a file is missing
df
df: Disk file system
Displays a full summary of the available and used disk space usage of a file system
-h
-h: Human readable
Since this starts with a - this is called a flag or modifier, it cannot be run on it’s own
Shows data sizes in KB/MB/GB, etc. instead of in Bytes
head
Shows the first 10 lines of a file
tail
Shows the last 10 lines of a file
tar
Compresses file; like Zip for Windows
Linux also can use zip/unzip for files
wget
wget: Website file get
Download a file from the web
top
Task Manager for terminal; same as Task Manager in Windows
k (Used within top)
Kill process by PID
PID
Process ID used in top