Skip to content

Instantly share code, notes, and snippets.

@MohiuddinAkib
Last active August 1, 2019 08:27
Show Gist options
  • Save MohiuddinAkib/943978516e92f98f776775f0b83d94a0 to your computer and use it in GitHub Desktop.
Save MohiuddinAkib/943978516e92f98f776775f0b83d94a0 to your computer and use it in GitHub Desktop.
Understanding the partition system in linux
1. 'dev' refers to device. in my case i have a ssd and a hdd. so while installing linux it will show
one of them as 'dev/sda' and other as 'dev/sdb'. 'sd' refers to disk and adds an alphabet to it's end to alphabetically organize.
2. under each disk we will have partition of that disk. each partition will append a number to organize them. ex: sda1, sda2, sdb1, sdb2 ...
follow this link on Step 4: Partition Magic https://medium.com/@killyourfm/the-beginners-guide-to-installing-ubuntu-linux-18-04-lts-6c8230036d84
The part which is the main focus of this gist:
Sidebar: Here’s how Linux identifies devices. “dev” simply means “a device that you can read from or write to.” Then we see “sda, sda1,
sda2,” etc. In Unix “sd” indicates a block device that can carry data. Then it identifies them alphabetically in the order they’re
discovered. Finally, the number (1, 2, 3) indicates the partitions. So /dev/sda1 simply means the first partition of the first drive.
Partitions? Think of them as slices of a pie. You can use one entire drive without doing anything to it. Or you can divide it into
partitions — logically but not physically separating them. One of my 2TB drives is divided into 1TB partitions.
The 2nd partition is just for Steam game installations, so even if I reinstall an operating system, that part of the drive remains
intact and loses no data. With Linux, partitions are necessary.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment