Partitioning Linux
Forum rules
Before you post read how to get help. Topics in this forum are automatically closed 6 months after creation.
Before you post read how to get help. Topics in this forum are automatically closed 6 months after creation.
Partitioning Linux
Hi guys.
I am wanting to setup my hdd like I would with windows...I'm kind of confused on how to do that with Linux.
I normally create a 60-80gb partition for the OS, then whatever is remaining i'll create my storage drive.
When I open GParted it doesn't show a swap file, but when I check using swapon -s it shows I have a 2gb swap.
I am wanting to setup my hdd like I would with windows...I'm kind of confused on how to do that with Linux.
I normally create a 60-80gb partition for the OS, then whatever is remaining i'll create my storage drive.
When I open GParted it doesn't show a swap file, but when I check using swapon -s it shows I have a 2gb swap.
Last edited by LockBot on Wed Dec 28, 2022 7:16 am, edited 1 time in total.
Reason: Topic automatically closed 6 months after creation. New replies are no longer allowed.
Reason: Topic automatically closed 6 months after creation. New replies are no longer allowed.
Re: Partitioning Linux
It is because it is a file and not a partition. If you don't create any swap partition when installing the system, the installer creates a swapfile automatically. Look under root for /swapfile.
Re: Partitioning Linux
True! What is the difference between a swap file and partition and which is better?
Am I able to partition Linux like I would Windows? Explained in the OP
Last edited by Overkill on Fri Dec 25, 2020 5:52 pm, edited 1 time in total.
Re: Partitioning Linux
Here are a couple of ArchWiki articles that might give you some start point for researching further:
PARTITIONING
https://wiki.archlinux.org/index.php/Partitioning
Re: Partitioning Linux
All I basically need to know is, can it be done in Linux? I don't see why, I know how to partition, I just wasn't sure about how ext4 works compared to ntfs.pebcak wrote: ⤴Fri Dec 25, 2020 5:45 pm Here are a couple of ArchWiki articles that might give you some start point for researching further:
PARTITIONING
https://wiki.archlinux.org/index.php/Partitioning
Re: Partitioning Linux
You could use Gparted from the live USB and partiton the disk, format partitons etc. Just format to EXT4 if that is the format you need.
Re: Partitioning Linux
Depends on what you want to do? I've got a swap partition because I've always had one, but from LM19 onwards mint by default will use a swap file. If you have 8GB RAM swap will rarely get used. If you hibernate then I think you still need a swap partition (I don't).
As to partitioning, there are two basic choices:
You will find advocates for both approaches in this forum. I'm in the have a
If you go down this route, then make your
If you go for separate
timeshift takes care of the system (default backs up
How to do it? - the way I do it is to set up the partitions with gparted before installing mint. gparted is the standard linux partition editor, there is a copy on the mint install media. Then when you install mint, choose the 'something else' option. The next screen allows you to point at the partitions you created and tell the installer what to use them for.
Happy Christmas!
As to partitioning, there are two basic choices:
- A single ext4 partition for
/
with/home
living within this partition.
- Separate ext4 partitions for
/
and/home
.
You will find advocates for both approaches in this forum. I'm in the have a
/home
partition camp. Back in my win days I always partitioned my drive so that C: = system & programs and D: = data. Having a separate /home
partition is the equivalent (but it also stores your config files). It also makes it easier on a major version change, e.g. LM20 to LM21 - you can do a clean install on /
leaving your data in /home
untouched.If you go down this route, then make your
/
partition 30-40GB (mine is 32GB and 20GB used, lot of stuff installed but I don't use flatpaks). Note - programs in linux don't suffer the bloat you get with win programs = less disk space.If you go for separate
/
and /home
partitions it is imperative that you set up timeshift to store snapshots on a separate drive (or separate partition = 2nd best choice). Too many posts on the forum from newbies using the defaults with timeshift (saves to /timeshift) and filling up their /
partition = no boot. Think of timeshift as the equivalent of a win restore point.timeshift takes care of the system (default backs up
/
excluding /home
). You will then need something to take care of your data in /home
. I use backintime, another alternative is luckybackup. Their default is to backup only /home
, so complimentary to timeshift. Don't expect much sympathy on the forum if you bork your system and don't have backups in place. Screwing up is part of learning linux so make sure you are prepared.How to do it? - the way I do it is to set up the partitions with gparted before installing mint. gparted is the standard linux partition editor, there is a copy on the mint install media. Then when you install mint, choose the 'something else' option. The next screen allows you to point at the partitions you created and tell the installer what to use them for.
Happy Christmas!
Thinkcentre M720Q - LM21.3 cinnamon, 4 x T430 - LM21.3 cinnamon, Homebrew desktop i5-8400+GTX1080 Cinnamon 19.0
Re: Partitioning Linux
This really helped! especially how you explained it comparing windows with linux!AndyMH wrote: ⤴Fri Dec 25, 2020 6:21 pm Depends on what you want to do? I've got a swap partition because I've always had one, but from LM19 onwards mint by default will use a swap file. If you have 8GB RAM swap will rarely get used. If you hibernate then I think you still need a swap partition (I don't).
As to partitioning, there are two basic choices:
- A single ext4 partition for
/
with/home
living within this partition.In addition, if you are booting UEFI you need a small (100MB, format fat32, flags = esp & boot) EFI partition. If you really want a swap partition then make it the same size as your RAM.
- Separate ext4 partitions for
/
and/home
.
You will find advocates for both approaches in this forum. I'm in the have a/home
partition camp. Back in my win days I always partitioned my drive so that C: = system & programs and D: = data. Having a separate/home
partition is the equivalent (but it also stores your config files). It also makes it easier on a major version change, e.g. LM20 to LM21 - you can do a clean install on/
leaving your data in/home
untouched.
If you go down this route, then make your/
partition 30-40GB (mine is 32GB and 20GB used, lot of stuff installed but I don't use flatpaks). Note - programs in linux don't suffer the bloat you get with win programs = less disk space.
If you go for separate/
and/home
partitions it is imperative that you set up timeshift to store snapshots on a separate drive (or separate partition = 2nd best choice). Too many posts on the forum from newbies using the defaults with timeshift (saves to /timeshift) and filling up their/
partition = no boot. Think of timeshift as the equivalent of a win restore point.
timeshift takes care of the system (default backs up/
excluding/home
). You will then need something to take care of your data in/home
. I use backintime, another alternative is luckybackup. Their default is to backup only/home
, so complimentary to timeshift. Don't expect much sympathy on the forum if you bork your system and don't have backups in place. Screwing up is part of learning linux so make sure you are prepared.
How to do it? - the way I do it is to set up the partitions with gparted before installing mint. gparted is the standard linux partition editor, there is a copy on the mint install media. Then when you install mint, choose the 'something else' option. The next screen allows you to point at the partitions you created and tell the installer what to use them for.
Happy Christmas!
So, basically rather than C:/=Windows OS and D:/=Storage i'll just have 2 /home partitions? And I can store my files one the second /home partition?
40gb is enough for Linux/updates etc.?
Would it be better to save snapshots on a flash drive?
Re: Partitioning Linux
No, you don't have twoSo, basically rather than C:/=Windows OS and D:/=Storage i'll just have 2 /home partitions? And I can store my files one the second /home partition?
/home
partitions, you have one /
partition and one /home
partition. 40GB is plenty for /
.This is what the drive looks like in gparted for one of my laptops: Legacy boot so no EFI partition.
Thinkcentre M720Q - LM21.3 cinnamon, 4 x T430 - LM21.3 cinnamon, Homebrew desktop i5-8400+GTX1080 Cinnamon 19.0
Re: Partitioning Linux
Sorry, that's actually what I meant. Thanks for the visual, it helps alot!AndyMH wrote: ⤴Sat Dec 26, 2020 7:42 amNo, you don't have twoSo, basically rather than C:/=Windows OS and D:/=Storage i'll just have 2 /home partitions? And I can store my files one the second /home partition?/home
partitions, you have one/
partition and one/home
partition. 40GB is plenty for/
.
This is what the drive looks like in gparted for one of my laptops:
Screenshot from 2020-12-26 11-39-01.png
Legacy boot so no EFI partition.
Re: Partitioning Linux
I'm trying to install Mint 20 on my laptop, but it's not cooperating!
When it tells me to change it to EFI, it says I have no root partition but I don't see an option for that???
When it tells me to change it to EFI, it says I have no root partition but I don't see an option for that???
Re: Partitioning Linux
It's because your BIOS is set to UEFI boot and you haven't got an EFI partition. You can either:
I prefer making these changes with gparted, but you can do it in the mint installer (I think).
The other thing you should check - in gparted, view > device information. It will open up a panel on the left. When installing in UEFI mode, your drive should have a GPT partition table. When installing in legacy mode, it should have an MSDOS partition table. Given its name, legacy/msdos, it is the old standard for partition tables and comes with some limitations, GPT is the modern standard and does away with the limitations of an msdos partition table.
- wipe the existing partitions and start again, creating a small EFI partition and then two ext4 partitions for / and /home, or
- shrink the /home partition, think it's sda3 - screenshot difficult to read, to create space at the end of the drive and create an EFI partition there.
I prefer making these changes with gparted, but you can do it in the mint installer (I think).
The other thing you should check - in gparted, view > device information. It will open up a panel on the left. When installing in UEFI mode, your drive should have a GPT partition table. When installing in legacy mode, it should have an MSDOS partition table. Given its name, legacy/msdos, it is the old standard for partition tables and comes with some limitations, GPT is the modern standard and does away with the limitations of an msdos partition table.
Thinkcentre M720Q - LM21.3 cinnamon, 4 x T430 - LM21.3 cinnamon, Homebrew desktop i5-8400+GTX1080 Cinnamon 19.0
Re: Partitioning Linux
Sorry, I tried to upload the orginal images but when I tried to attach them, they were to large, so I had to resize them.
I am going to try again tonight and see how it goes.
I am going to try again tonight and see how it goes.
Re: Partitioning Linux
you can also tell which Mode that you have used .. EFI / legacy .. ms-dos mode
as you do have to select that, at startup, and before the Boot Media is started.
if there is no /efi partition, available, then you can create that partition with the Gparted program.
- - 500Mb is more than enough.
try to place that /efi partition, at the start of the drive, if possible.
as you do have to select that, at startup, and before the Boot Media is started.
if there is no /efi partition, available, then you can create that partition with the Gparted program.
- - 500Mb is more than enough.
try to place that /efi partition, at the start of the drive, if possible.
Please edit your original post title to include [SOLVED] - when your problem is solved!
and DO LOOK at those Unanswered Topics - - you may be able to answer some!.
Re: Partitioning Linux
What's the purpose of a 500mb EFI partition?Pierre wrote: ⤴Tue Dec 29, 2020 2:46 am you can also tell which Mode that you have used .. EFI / legacy .. ms-dos mode
as you do have to select that, at startup, and before the Boot Media is started.
if there is no /efi partition, available, then you can create that partition with the Gparted program.
- - 500Mb is more than enough.
try to place that /efi partition, at the start of the drive, if possible.
Re: Partitioning Linux
in any 64bit system, there is an /efi folder & /efi partition,
that contains the system boot files, without which, the machine won't boot up.
this applies to both the Windows System & the Linux System,
and YES .. they do conflict with each other.
that contains the system boot files, without which, the machine won't boot up.
this applies to both the Windows System & the Linux System,
and YES .. they do conflict with each other.
Please edit your original post title to include [SOLVED] - when your problem is solved!
and DO LOOK at those Unanswered Topics - - you may be able to answer some!.
Re: Partitioning Linux
I'd appreciate some understanding since I'm new to Linux...I installed Pop OS on my laptop and I only assigned a /, /home and a swap partition, so it must have installed the EFI partition automatically because it boots just fine.
What is the best bios settings to install Linux on laptops that came installed with Windows 8 or 10? I'm having issues with my other laptop which is a Samsung, no matter what settings i've tried in partitioning or the BIOS, at boot it gives me this error...“All boot options are tried. Press <F4> key to recover with factory image using Recovery or any keys for next boot loop iteration.”
Re: Partitioning Linux
that Pop OS must have Installed as MBR / legacy, if there was no mention of an /efi thing.
your Samsung would be 64bit, if it had either win-8x or win-10 installed on it.
thus the LinuxMint will also have to be 64bit & /efi as well.
you will need to select the /efi mode at boot, of your LinuxMint Live Media,
or the Installation will be wrong .. it won't 'see' any other system, either.
your Samsung would be 64bit, if it had either win-8x or win-10 installed on it.
thus the LinuxMint will also have to be 64bit & /efi as well.
you will need to select the /efi mode at boot, of your LinuxMint Live Media,
or the Installation will be wrong .. it won't 'see' any other system, either.
Please edit your original post title to include [SOLVED] - when your problem is solved!
and DO LOOK at those Unanswered Topics - - you may be able to answer some!.
Re: Partitioning Linux
I figured everything out! I created a EFI partition at the beginning of the drive and swap, then / and /home and it finally boots!
https://i.imgur.com/whPbvFW.jpg
I will do the same with my Mint install. Thanks
https://i.imgur.com/whPbvFW.jpg
I will do the same with my Mint install. Thanks
- David Chiang
- Level 3
- Posts: 102
- Joined: Sun Jul 01, 2007 4:42 am
- Location: Higashiōsaka, Japan
- Contact:
Re: Partitioning Linux
We should also mention at this point that this only applies in the event that no boot loader like GRUB has been installed beforehand.
LMDE 5 Elsie (64-bit), Linux Kernel 5.10.0, Cinnamon 5.6.8, inxi 3.3.28;
HTPC: ASUS TUF B450M-Pro Gaming, 3.6 GHz AMD Ryzen 7 3700X (8 cores),
AMD Radeon Pro WX 7100, 2 × 4 TiB Seagate BarraCuda ES.3, 4 × 16 GiB HyperX Predator DDR4;
HTPC: ASUS TUF B450M-Pro Gaming, 3.6 GHz AMD Ryzen 7 3700X (8 cores),
AMD Radeon Pro WX 7100, 2 × 4 TiB Seagate BarraCuda ES.3, 4 × 16 GiB HyperX Predator DDR4;