Is this a bug? 2 linux installs but one swap?

Questions about Grub, UEFI,the liveCD and the installer
Forum rules
Before you post read how to get help. Topics in this forum are automatically closed 6 months after creation.
Locked
User avatar
choochooal
Level 2
Level 2
Posts: 50
Joined: Tue Jun 28, 2011 7:54 pm

Is this a bug? 2 linux installs but one swap?

Post by choochooal »

I've installed linux mint, cinnamon, several times along side of another linux install. Every time I install the 2nd linux and tell it to make a swap, and IIRC even if I don't, the installer wants to use the swap from the 1st linux system. Thus I have 2 swaps.

Easy enough to fix post install, just edit the fstab and take one out, but I shouldn't need to.

Is this a bug? And should I, and where should I report it?
Last edited by LockBot on Tue Feb 07, 2023 11:00 pm, edited 1 time in total.
Reason: Topic automatically closed 6 months after creation. New replies are no longer allowed.
Linux Mint 20.3 Cinnamon 64-bit. Dual boot with Windows 10
User avatar
Dan-cer
Level 6
Level 6
Posts: 1161
Joined: Fri Jul 29, 2022 4:56 pm
Location: Germany, Lower Saxony

Re: Is this a bug? 2 linux installs but one swap?

Post by Dan-cer »

I can't answer directly, but if you have a newer computer with 8GB or more RAM, creating a separate swap partition is no longer necessary.

However, your question is not uninteresting.
How you get better results when searching for yourself.
Cosmo.
Level 24
Level 24
Posts: 22968
Joined: Sat Dec 06, 2014 7:34 am

Re: Is this a bug? 2 linux installs but one swap?

Post by Cosmo. »

Not a bug. A swap partition can be shared by several linux systems and if a swap partition does exist, it gets used by other systems by default. This is so far not a problem, except in one case:

If you use hibernation and wake the computer, you must carefully watch, that the last used and now hibernated system gets selected in the grub menu. As soon as you boot instead another system, the hibernated system cannot get reactivated anymore and this means in the consequence: data-loss. If no hibernation gets used, sharing swap is not a problem.
User avatar
zcot
Level 9
Level 9
Posts: 2838
Joined: Wed Oct 19, 2016 6:08 pm

Re: Is this a bug? 2 linux installs but one swap?

Post by zcot »

Dan-cer wrote: Sun Aug 07, 2022 9:48 am if you have a newer computer with 8GB or more RAM, creating a separate swap partition is no longer necessary.
That's really not good advice, no swap. A newer or older computer with RAM, should have swap. Maybe there's some debatable point with a much larger amount of RAM where it could be said that swap is not needed, but then even having a 1GB swap might at least prevent a direct system dump in a runaway case or something.


Whether a /swap partition is used or /swapfile should not make a difference.

Also, there's not a problem with using multiple swap spaces, you can span and prioritize as well.

/swapfile is automatically created within the root partition on Mint 20 or 21. But an existing /swap partition is mounted automatically during a live session, a convenience feature, and that will be used as set in the installer since it becomes a live functioning part. If you add more swap that it becomes functional also. You can unmount a swap partition in the live session before installation and it will be ignored in that case and any other swap you specify will be used(or automatically created).
Cosmo.
Level 24
Level 24
Posts: 22968
Joined: Sat Dec 06, 2014 7:34 am

Re: Is this a bug? 2 linux installs but one swap?

Post by Cosmo. »

zcot wrote: Sun Aug 07, 2022 11:56 pm
Dan-cer wrote: Sun Aug 07, 2022 9:48 am if you have a newer computer with 8GB or more RAM, creating a separate swap partition is no longer necessary.
That's really not good advice, no swap.
I agree, no swap is not a good advice. But not creating a swap partition - creating one means, that there is not already one existing - is a correct advice, as with the by default created swap file this is superfluous and makes probably later changes for the partition layout unnecessarily circumstantial, especially with a MBR partition table.
Locked

Return to “Installation & Boot”