LinuxQuestions.org
Visit Jeremy's Blog.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Debian
User Name
Password
Debian This forum is for the discussion of Debian Linux.

Notices


Reply
  Search this Thread
Old 04-12-2023, 06:56 AM   #31
business_kid
LQ Guru
 
Registered: Jan 2006
Location: Ireland
Distribution: Slackware, Slarm64 & Android
Posts: 16,314

Rep: Reputation: 2328Reputation: 2328Reputation: 2328Reputation: 2328Reputation: 2328Reputation: 2328Reputation: 2328Reputation: 2328Reputation: 2328Reputation: 2328Reputation: 2328

First a correction
Code:
I'm seeing 30 posts here, which is crazy
  • Do the filesystems check out with e2fsck and smartctl's comprehensive tests?
  • Post the output of sensors with the pc running slow.
  • Post the bootup errors. I don't read full logs, except my own.
 
Old 04-12-2023, 07:05 AM   #32
pan64
LQ Addict
 
Registered: Mar 2012
Location: Hungary
Distribution: debian/ubuntu/suse ...
Posts: 21,876

Rep: Reputation: 7315Reputation: 7315Reputation: 7315Reputation: 7315Reputation: 7315Reputation: 7315Reputation: 7315Reputation: 7315Reputation: 7315Reputation: 7315Reputation: 7315
Quote:
Originally Posted by dedec0 View Post
Right. Thank you for this list.

I will try this starting list, for now. I have already checked how to disable swap, I will just prepare a few details to avoid losing anything, in the case of the system killing running programs.

A problem of very slow network should not be the problem, I think. The network for these 2 computers is the same: both connected with a cable to the same modem (and it receives data with a coaxial cable, from the network company). I would see the slowness in the other computer, I think.
before you disable your swap:
https://chrisdown.name/2018/01/02/in...e-of-swap.html
 
1 members found this post helpful.
Old 04-26-2023, 11:49 PM   #33
dedec0
Senior Member
 
Registered: May 2007
Posts: 1,372

Original Poster
Rep: Reputation: 51
Question What happened here?

Hello, people. A good number of days has passed, and i did not look into this problem anymore. There are a few things, important to mention here, that happened in all these days:

1. The computer with the slowness problem was never turned off, or rebooted. Since the last few messages i posted here, it was already fairly slow. I closed the browser 2 times. In the first time, i took several minutes to change to a text only session - ctrl+alt+f6 - which i usually use to:

Check the id of 2 "important" processes, using pstree and view (which is Vim editor, anyway), or an alias i have to quickly search the output of ps -Af. The process I usually search is vivaldi - that i have mentioned here before, because it uses a lot of memory, as time passes and i use more pages and new tabs, both in normal and private windows, not usually always growing the number of open tabs. Just closing the tabs or windows, does not free as much memory as killing vivaldi (never with signal 9, it will not need much time to close, although it does not close immediately in these slowness periods). Telegram process is the only other process, of things i use in this computer, that could be imagined using a lot of memory, as time passes, with it being used to do everything it can.

2. I had much patience to wait the slowness moments. The RAM was basically full all the time, including the moments after my "cleaning memory" habits, cited in step 1. The swap usage slowly increased to an amount i never saw before, in this computer! More than half of swap seemed to be in use! This is just a visual guess, and i compare the graphic of swap that got used, with the biggest swap use i ever saw, before and during this thread - until now. The slowness was kind of extreme. Moving the mouse to click a window button, its window manager focus button, or do anything, took several seconds, sometimes a few minutes. Keyboard actions were also slow to happen in all programs, most of the time. This is true even for the basic and simple actions programs, like vim or view in a terminal, the common terminal commands, etc. I could still keep my habit of using this computer to hear online radios or videos, live programs, some live, some recorded. It was slow to start or change them, but it worked. The computer was not locked, and maybe the frozen state i imagined for it before, it was like all this, in fact. To do these things i cited here, i use the browser or vlc. But i did not watch several programs that need more action to be found, played, and so on. The ones with less actions to start were the only chosen. The other computer does not have something to audio output, now, thus, some wanted to watch things got lost.

3. Since yesterday, I was preparing the compo with the slowness problem to make the commands that i found to "clear RAM memory cache and buffer, and to clear swap too" (this is a link of a nice tutorial with good explanations). Since it seems something that may not always be safe, given the warning made here, and another one in this site itself, i was making sure everything would be safe and backed up. But before i finished this process, i slept before the usual time. Not even an hour ago (now is 1:10 here, 24h clock), i woke up again. At the point i slept, the computer had all, or nearly all, the RAM in use; a lot of swap in use too, something i never saw before; vivaldi and telegram were not running, but this did not release much RAM, as it usually happens, in both computers.

4. Now, after i woke up, in a sleep of not many hours, the RAM usage is, checking the Mate graphs i always have on: 24% in use by programs; 16% usage as cache. Swap usage is 4%. I cannot explain! I almost never use other programs in this computer, that can be imagined to use a lot of memory and/or processor and/or disk. The most used ones are the browser; vlc media player to watch videos or listen to live streams; Telegram. Besides these, what is always opened is just Pluma, the simple text editor that Mate has, and a Mate Terminal with a few tabs. Vim and its children, Gimp, xpdf, the other PDF viewer, and LibreOffice are programs i use rarely with it. Most of the time, these are not open, or opened without anything being used or created with them. Most of the time, i will open and work with these kinds of files in the other computer.

So, what happened? Was all the memory not freed until hours passed, without it being used at all, and having no process associated with it?

The commands we find in the site pointed in step 3 would make this action happen before such time elapses? If it is not, is there a way to do it?
 
Old 04-27-2023, 01:26 AM   #34
pan64
LQ Addict
 
Registered: Mar 2012
Location: Hungary
Distribution: debian/ubuntu/suse ...
Posts: 21,876

Rep: Reputation: 7315Reputation: 7315Reputation: 7315Reputation: 7315Reputation: 7315Reputation: 7315Reputation: 7315Reputation: 7315Reputation: 7315Reputation: 7315Reputation: 7315
see this: www.linuxatemyram.com
 
1 members found this post helpful.
Old 04-27-2023, 08:26 AM   #35
_blackhole_
Member
 
Registered: Mar 2023
Distribution: FreeBSD
Posts: 88

Rep: Reputation: 67
Quote:
Originally Posted by dedec0 View Post
But the problematic computer gets reeeeeeeeeeeeally really slow with a lot of swap still being free!
Once all memory is in use and it starts swapping, you will see a dramatic decline in performance - the problem is that you are getting to that stage in the first place. From what you have described, you have too much running on a system with too little RAM.
 
Old 04-28-2023, 04:48 AM   #36
business_kid
LQ Guru
 
Registered: Jan 2006
Location: Ireland
Distribution: Slackware, Slarm64 & Android
Posts: 16,314

Rep: Reputation: 2328Reputation: 2328Reputation: 2328Reputation: 2328Reputation: 2328Reputation: 2328Reputation: 2328Reputation: 2328Reputation: 2328Reputation: 2328Reputation: 2328
Are you guys running linux with a stable kernel? I'm beginning to doubt it.
Memory is used for memory until it runs out, which is rare unless you're being stupid. As the memory fills up, a buffer is kept and as ram is low, swap is used. You slow your ram access to the speed of spinning rust, but otherwise life goes on.

What's inclined to slow a system are memory faults (check with memtest86), disk faults (check with smartctl), opening piles of bloatware, or cramming huge ramdisks. Running windows VMs might do it too, or gaming. Basically, if you're not a server, normal operation uses less than 4 Gig.

Rebooting is generally a good thing, as it closes all the crap you had open. Linux uses clever techniques like 'copy on write' to minimize memory use.

When people provide all details, do what what is suggested, and use their brains, most problems are solved inside 8-12 posts. I'm unsubscribing because at 35 posts, it's clear you aren't doing any of that. You apparently want to talk rather than solve anything.

In the unlikely event that you are seeking a solution and I have woken you up, re read the thread.
 
Old 04-28-2023, 03:41 PM   #37
dedec0
Senior Member
 
Registered: May 2007
Posts: 1,372

Original Poster
Rep: Reputation: 51
Quote:
Originally Posted by _blackhole_ View Post
Once all memory is in use and it starts swapping, you will see a dramatic decline in performance - the problem is that you are getting to that stage in the first place. From what you have described, you have too much running on a system with too little RAM.
In my previous post, I have said everything that is used - and besides what I mentioned, it is rare that I use other things, and they will not be memory or disk intensive things: no games, no VMs of any kind, no "strange" software.

And what business_kid says in post #36 is useless. It mentions an usual fact, but "usual fact" is far from being "all cases such fact is possible and easy".
 
Old 04-28-2023, 03:56 PM   #38
dedec0
Senior Member
 
Registered: May 2007
Posts: 1,372

Original Poster
Rep: Reputation: 51
Quote:
Originally Posted by pan64 View Post
Thank you very much for this page. It explained several useful things.

From that page, one fact shown by free -mh command, now, makes me think:

Code:
               total        used        free      shared  buff/cache   available
Mem.:          3,8Gi       2,6Gi       919Mi       250Mi       628Mi       645Mi
Swap:           59Gi       3,9Gi        55Gi
I have not yet done several things that are mentioned above, to test the computer in important aspects. I will do them when i can. I wrote the post about the "magically freed" memory because it could be an explanation to everything happening here - so, i imagined.
 
  


Reply

Tags
debian, memory, ram, swap



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] Why is my Debian computer only using 2GB RAM? (i686 2013 Macbook Pro running Debian KDE) theOakBaron Linux - Hardware 4 02-03-2018 04:18 PM
Why swap space did not function when physical memory ( RAM ) is full ? subankar Linux - Server 7 10-11-2012 12:02 PM
Why size of swap space is 2x of RAM??? Why not 1.5x of RAM or 2.5x of RAM??? Saurav Ghosh Linux - Newbie 7 11-01-2011 03:49 AM
Why should you give the size of the swap disk as twice the size of RAM vmniza Linux - Newbie 3 09-17-2004 02:13 AM
why swap should be twice of RAM? whitefox Slackware 17 04-19-2003 02:51 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Debian

All times are GMT -5. The time now is 12:21 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration