Mint and Chrome and no swap

All Gurus once were Newbies
Forum rules
There are no such things as "stupid" questions. However if you think your question is a bit stupid, then this is the right place for you to post it. Please stick to easy to-the-point questions that you feel people can answer fast. For long and complicated questions prefer the other forums within the support section.
Before you post please read how to get help
Menard
Level 1
Level 1
Posts: 40
Joined: Wed May 08, 2019 5:14 am
Location: Angers (France)

Mint and Chrome and no swap

Post by Menard » Sun Jun 09, 2019 5:24 am

Hi

I installed Mint with no swap because 8 Go DDR3 is enough, and I see that when Chrome uses all the RAM, something happen, very big disk access freezes the PC and I can do nothing to stop that, then the display freezes too and I must power off ... very risky for mounted crypted volumes, mounted usb drives and perhaps for mounted NTFS partitions and in use ... so it seems to be worse with windows to do this ... but with windows (XP) in these cases if it is Firefox, the firefox process or else juste crashes without to warn, or sometimes there is an alert of full memory so nothing severe may happen.
And why does it try to swap as we chose no swap ?

So this might be a reason for me to stop with MInt and try another Linux distribution.
Linux Mint 19.1 64bits Cinnamon (Kernel 4.18.0-15)
AMD APU A8 7600 (3100 MHz to 3800 MHz) with DDR3 1833 MHz 4 GB x2
(CPU limited to 4x 3100 Mhz default by no support of the Turbo-core, then after editing grub, supports up to only 3600 MHz)

User avatar
karlchen
Level 20
Level 20
Posts: 11495
Joined: Sat Dec 31, 2011 7:21 am
Location: Germany

Re: Mint and Chrome and no swap

Post by karlchen » Sun Jun 09, 2019 5:32 am

Hello, Menard.
Menard wrote:
Sun Jun 09, 2019 5:24 am
I installed Mint with no swap because 8 Go DDR3 is enough
This is what you think. But you are wrong.
Whether 8 GB of memory are sufficient depends on how many memory greedy applications you run in parallel. And e.g. browsers today are real resource hogs today.
The moment that Linux has used up all the 8 GB of memory it will freeze. What else could it do, because by not permitting it to swap you have made it impossible to Mint to relocate application code and data into the swap area, thus freeing up main memory which it needs in order to go on.
You are free to blame Mint for your own incorrect setup decision of running without swap space and to switch to a different Linux distribution; but that distribution will to the same thing without swap space, freeze as soon as all memory is in use.

Regards,
Karl
Image
Linux Mint 19.2 64-bit Cinnamon, Total Commander 9.22a 64-bit
Haß gleicht einer Krankheit, dem Miserere, wo man vorne herausgibt, was eigentlich hinten wegsollte. (Goethe)

User avatar
AndyMH
Level 9
Level 9
Posts: 2668
Joined: Fri Mar 04, 2016 5:23 pm
Location: Wiltshire

Re: Mint and Chrome and no swap

Post by AndyMH » Sun Jun 09, 2019 5:41 am

You haven't said which version of mint you are using. In LM19 if there is no swap partition LM will use a swap file.
Homebrew i5-8400+GTX1080 Cinnamon 19.0, 3 x Thinkpad T430 Cinnamon 19.0, i7-3632 , i5-3320, i5-3210, Thinkpad T60 19.0 Mate

User avatar
karlchen
Level 20
Level 20
Posts: 11495
Joined: Sat Dec 31, 2011 7:21 am
Location: Germany

Re: Mint and Chrome and no swap

Post by karlchen » Sun Jun 09, 2019 5:48 am

Hi, AndyMH.
Menard may have switched swapping off completely. You can do so no matter whether your swap space is a swap disk partition or a swapfile.
Karl
Image
Linux Mint 19.2 64-bit Cinnamon, Total Commander 9.22a 64-bit
Haß gleicht einer Krankheit, dem Miserere, wo man vorne herausgibt, was eigentlich hinten wegsollte. (Goethe)

Menard
Level 1
Level 1
Posts: 40
Joined: Wed May 08, 2019 5:14 am
Location: Angers (France)

Re: Mint and Chrome and no swap

Post by Menard » Sun Jun 09, 2019 6:37 am

karlchen wrote:
Sun Jun 09, 2019 5:32 am
Hello, Menard.
Menard wrote:
Sun Jun 09, 2019 5:24 am
I installed Mint with no swap because 8 Go DDR3 is enough

You are free to blame Mint for your own incorrect setup decision of running without swap space and to switch to a different Linux distribution; but that distribution will to the same thing without swap space, freeze as soon as all memory is in use.

Regards,
Karl
OK but it is a possiblility for which the installer gives us the choice without pointing out any specific possible issue. So i'm just logic.
Linux Mint 19.1 64bits Cinnamon (Kernel 4.18.0-15)
AMD APU A8 7600 (3100 MHz to 3800 MHz) with DDR3 1833 MHz 4 GB x2
(CPU limited to 4x 3100 Mhz default by no support of the Turbo-core, then after editing grub, supports up to only 3600 MHz)

User avatar
AndyMH
Level 9
Level 9
Posts: 2668
Joined: Fri Mar 04, 2016 5:23 pm
Location: Wiltshire

Re: Mint and Chrome and no swap

Post by AndyMH » Sun Jun 09, 2019 1:21 pm

Menard may have switched swapping off completely.
I can't think of a single good reason to do that.
Andy :)
Homebrew i5-8400+GTX1080 Cinnamon 19.0, 3 x Thinkpad T430 Cinnamon 19.0, i7-3632 , i5-3320, i5-3210, Thinkpad T60 19.0 Mate

User avatar
Larry78723
Level 7
Level 7
Posts: 1657
Joined: Wed Jan 09, 2019 7:01 pm
Location: Jasper County, SC, USA

Re: Mint and Chrome and no swap

Post by Larry78723 » Sun Jun 09, 2019 1:51 pm

Maybe he did it because of his mistaken assumption of
because 8 Go DDR3 is enough
Image

Menard
Level 1
Level 1
Posts: 40
Joined: Wed May 08, 2019 5:14 am
Location: Angers (France)

Re: Mint and Chrome and no swap

Post by Menard » Sun Jun 09, 2019 3:15 pm

AndyMH wrote:
Sun Jun 09, 2019 1:21 pm
Menard may have switched swapping off completely.
I can't think of a single good reason to do that.
Andy :)
The fact that Linux Mint propose it is a very good reason
the fact that Windows XP works very well with 2 GB RAM without swap too
Linux Mint 19.1 64bits Cinnamon (Kernel 4.18.0-15)
AMD APU A8 7600 (3100 MHz to 3800 MHz) with DDR3 1833 MHz 4 GB x2
(CPU limited to 4x 3100 Mhz default by no support of the Turbo-core, then after editing grub, supports up to only 3600 MHz)

User avatar
karlchen
Level 20
Level 20
Posts: 11495
Joined: Sat Dec 31, 2011 7:21 am
Location: Germany

Re: Mint and Chrome and no swap

Post by karlchen » Sun Jun 09, 2019 4:52 pm

The fact that Linux Mint propose it is a very good reason
Where does Linux Mint suggest to install and run without any swap space?
As far as I remember the Linux Mint installer defaults to creating a swap device or on Mint 19.x a swapfile and to configuring the newly installed system to use it.
and I see that when Chrome uses all the RAM
How have you determined that Chrome uses most of the available 8 GB of memory? Could you explain, please?
Even for a known memory hog like Chrome, occupying almost 8 GB of memory would be really a lot memory.
And if Chrome really can be proven to do so, would this not be a reason to blame Chrome rather than Linux Mint?
Image
Linux Mint 19.2 64-bit Cinnamon, Total Commander 9.22a 64-bit
Haß gleicht einer Krankheit, dem Miserere, wo man vorne herausgibt, was eigentlich hinten wegsollte. (Goethe)

Menard
Level 1
Level 1
Posts: 40
Joined: Wed May 08, 2019 5:14 am
Location: Angers (France)

Re: Mint and Chrome and no swap

Post by Menard » Mon Jun 10, 2019 4:04 am

karlchen wrote:
Sun Jun 09, 2019 4:52 pm
The fact that Linux Mint propose it is a very good reason
Where does Linux Mint suggest to install and run without any swap space?
As far as I remember the Linux Mint installer defaults to creating a swap device or on Mint 19.x a swapfile and to configuring the newly installed system to use it.
and I see that when Chrome uses all the RAM
How have you determined that Chrome uses most of the available 8 GB of memory? Could you explain, please?
Even for a known memory hog like Chrome, occupying almost 8 GB of memory would be really a lot memory.
And if Chrome really can be proven to do so, would this not be a reason to blame Chrome rather than Linux Mint?
Probably because I am used to use Firefox on Win XP without swap, and when all the memory is used, I am not obliged to set the power button on off.
At the worse I can run ctrl+alt+suppr to close the user's session properly. So it is not proven but it is like a feeling :)

I determine this usage of 7 GB memory used by the gnome-system-monitor seeing that I am at 100% used but you point out the fact that i am not sure of that it is Chrome which uses all ... so how to do ? In Chrome there must be a command to have this no ?
Linux Mint 19.1 64bits Cinnamon (Kernel 4.18.0-15)
AMD APU A8 7600 (3100 MHz to 3800 MHz) with DDR3 1833 MHz 4 GB x2
(CPU limited to 4x 3100 Mhz default by no support of the Turbo-core, then after editing grub, supports up to only 3600 MHz)

Menard
Level 1
Level 1
Posts: 40
Joined: Wed May 08, 2019 5:14 am
Location: Angers (France)

Re: Mint and Chrome and no swap

Post by Menard » Mon Jun 17, 2019 5:13 am

karlchen wrote:
Sun Jun 09, 2019 4:52 pm

Even for a known memory hog like Chrome, occupying almost 8 GB of memory would be really a lot memory.
And if Chrome really can be proven to do so, would this not be a reason to blame Chrome rather than Linux Mint?
You are right, I examined the tasks and when my RAM is 100% occupied I have in fact the task Cinnamon which occupies 2 GB,what is very unnormal
Linux Mint 19.1 64bits Cinnamon (Kernel 4.18.0-15)
AMD APU A8 7600 (3100 MHz to 3800 MHz) with DDR3 1833 MHz 4 GB x2
(CPU limited to 4x 3100 Mhz default by no support of the Turbo-core, then after editing grub, supports up to only 3600 MHz)

ColdBootII
Level 5
Level 5
Posts: 521
Joined: Wed Aug 02, 2017 8:19 am

Re: Mint and Chrome and no swap

Post by ColdBootII » Mon Jun 17, 2019 6:00 am

I use Chrome(75.x) in LM 19.1 Mate without swap partition or swap file with just 8GB RAM and it is doable. Previously, I did the same in LM 18 Cinnamon. Nothing undesirable ever happend.

The system never tries to swap and I even set OOM killer to finish off all processes if they try funny stuff with memory. But you should consider using the The Great Suspender extension for Chrome as it does reduce its memory appetites considerably. Then you can even direct Chrome to use memory for caching with --disk-cache-dir command argument and all will be well.

User avatar
Pjotr
Level 21
Level 21
Posts: 13850
Joined: Mon Mar 07, 2011 10:18 am
Location: The Netherlands (Holland)
Contact:

Re: Mint and Chrome and no swap

Post by Pjotr » Mon Jun 17, 2019 6:02 am

1. First of all, disable all visual effects in Cinnamon:
https://easylinuxtipsproject.blogspot.c ... html#ID5.1
(item 5.1)

2. Which desklets / extensions have you installed in Cinnamon (if any)?

3. Which extensions have you installed in Chrome (if any)?
Tip: 10 things to do after installing Linux Mint 19.2 Tina
Keep your Linux Mint healthy: Avoid these 10 fatal mistakes
Twitter: twitter.com/easylinuxtips
All in all, horse sense simply makes sense.

Menard
Level 1
Level 1
Posts: 40
Joined: Wed May 08, 2019 5:14 am
Location: Angers (France)

Re: Mint and Chrome and no swap

Post by Menard » Mon Jun 17, 2019 6:43 am

Pjotr wrote:
Mon Jun 17, 2019 6:02 am
1. First of all, disable all visual effects in Cinnamon:
https://easylinuxtipsproject.blogspot.c ... html#ID5.1
(item 5.1)

2. Which desklets / extensions have you installed in Cinnamon (if any)?

3. Which extensions have you installed in Chrome (if any)?
1 - OK, thanks ... I disabled it now

2 - Redshift, IP Indicator, Disk read and write speed, Workrave and CPU freq which show no icon so i have just uninstalled it
I have an icon which shows the CPU Freq governors to change frequency

3 - Session Buddy, Edit this cookie, Video Downloader Plus, Video Download Helper
Linux Mint 19.1 64bits Cinnamon (Kernel 4.18.0-15)
AMD APU A8 7600 (3100 MHz to 3800 MHz) with DDR3 1833 MHz 4 GB x2
(CPU limited to 4x 3100 Mhz default by no support of the Turbo-core, then after editing grub, supports up to only 3600 MHz)

User avatar
Pjotr
Level 21
Level 21
Posts: 13850
Joined: Mon Mar 07, 2011 10:18 am
Location: The Netherlands (Holland)
Contact:

Re: Mint and Chrome and no swap

Post by Pjotr » Mon Jun 17, 2019 8:04 am

Disable all extensions / desklets both in Cinnamon and in Chrome, and then test again.

Afterwards, re-enable your extensions / desklets, one by one, and test after each re-enablement. This should help you to pinpoint the potential culprit.
Tip: 10 things to do after installing Linux Mint 19.2 Tina
Keep your Linux Mint healthy: Avoid these 10 fatal mistakes
Twitter: twitter.com/easylinuxtips
All in all, horse sense simply makes sense.

Menard
Level 1
Level 1
Posts: 40
Joined: Wed May 08, 2019 5:14 am
Location: Angers (France)

Re: Mint and Chrome and no swap

Post by Menard » Thu Jun 20, 2019 5:43 am

Yes ok thanks but it may be long to conclude doing this because It is quite rare when I have to use Chrome at its maximum capacities and so disabling all this features all the time for an event which occurs once a week or two weeks ... that's also why it took me time to answer this.
For example now I am at h+1 and with Chrome+Firefox+Opera+LibreOffice+Nemo(1) and it takes 55% of the memory (Cinnamon itself uses only 75 MB)

Is there a command to see how much memory an application uses ?
Linux Mint 19.1 64bits Cinnamon (Kernel 4.18.0-15)
AMD APU A8 7600 (3100 MHz to 3800 MHz) with DDR3 1833 MHz 4 GB x2
(CPU limited to 4x 3100 Mhz default by no support of the Turbo-core, then after editing grub, supports up to only 3600 MHz)

User avatar
Pjotr
Level 21
Level 21
Posts: 13850
Joined: Mon Mar 07, 2011 10:18 am
Location: The Netherlands (Holland)
Contact:

Re: Mint and Chrome and no swap

Post by Pjotr » Thu Jun 20, 2019 5:55 am

Menard wrote:
Thu Jun 20, 2019 5:43 am
Is there a command to see how much memory an application uses ?
Sure:

Code: Select all

top
Tip: 10 things to do after installing Linux Mint 19.2 Tina
Keep your Linux Mint healthy: Avoid these 10 fatal mistakes
Twitter: twitter.com/easylinuxtips
All in all, horse sense simply makes sense.

ColdBootII
Level 5
Level 5
Posts: 521
Joined: Wed Aug 02, 2017 8:19 am

Re: Mint and Chrome and no swap

Post by ColdBootII » Thu Jun 20, 2019 6:41 am

Also worth trying this script: https://raw.githubusercontent.com/pixel ... /ps_mem.py Nice, compact, sorted, per app readings.


Image

ColdBootII
Level 5
Level 5
Posts: 521
Joined: Wed Aug 02, 2017 8:19 am

Re: Mint and Chrome and no swap

Post by ColdBootII » Thu Jun 20, 2019 7:13 am

Menard wrote:
Mon Jun 17, 2019 6:43 am
2 - Redshift, IP Indicator, Disk read and write speed, Workrave and CPU freq which show no icon so i have just uninstalled it
I have an icon which shows the CPU Freq governors to change frequency
Off topic: Menard, bolded may be a consequence of an incomplete icon theme. Maybe, you've installed something third-party? Try switching back to some of the LM icons and you might find their icons reapearing.

Hoser Rob
Level 15
Level 15
Posts: 5646
Joined: Sat Dec 15, 2012 8:57 am

Re: Mint and Chrome and no swap

Post by Hoser Rob » Thu Jun 20, 2019 7:14 am

Menard wrote:
Sun Jun 09, 2019 6:37 am
karlchen wrote:
Sun Jun 09, 2019 5:32 am
Hello, Menard.
Menard wrote:
Sun Jun 09, 2019 5:24 am
I installed Mint with no swap because 8 Go DDR3 is enough

You are free to blame Mint for your own incorrect setup decision of running without swap space and to switch to a different Linux distribution; but that distribution will to the same thing without swap space, freeze as soon as all memory is in use.

Regards,
Karl
OK but it is a possiblility for which the installer gives us the choice without pointing out any specific possible issue. So i'm just logic.
It's actually completely illogical to assume that the installer will inform you of probable bad decisions on your part, like that one. There's an ancient saying in the computer world, that data always multiplies to fill available storage. It was true in the 1950s and still is.

As mentioned if you're using 19.1 it should be relatively easy to set up swap since you wouldn't need a separate swap partition.

Post Reply

Return to “Newbie Questions”