File System Navigation & Basics
How to move around, view files, and understand paths in both Windows and Linux.
Files & Storage
File System Navigation & Basics
How to move around, view files, and understand paths in both Windows and Linux.
Directory Structures
Both operating systems use a tree structure, but the roots and path separators differ.
Windows
Windows uses drive letters (like C:) as the root of the tree, and backslashes (\) to separate directories.
- Root:
C:\ - User Home:
C:\Users\Username - System Files:
C:\Windows
Linux
Linux uses a single unified root directory (/), and forward slashes (/) to separate directories. Drives are mounted within this tree.
- Root:
/ - User Home:
/home/username(or/rootfor admin) - System Files:
/etc,/bin,/var
Basic Navigation Commands
Get-ChildItem
or ‘dir’ or ‘ls’ (aliases)
Set-Location C:\Users
or ‘cd C:\Users’
Get-Location
or ‘pwd’
ls -la
cd /home/user
pwd