It took me a while to get a clearer view of what seems to be happening, although I’m only aware of the results and not the cause. I’m not sure if it’s a normal thing on Linux, though I don’t see any reason for this behavior. Here is the problem:
My machine has 9GB of DDR3 memory (triple-channel hence the impair value) plus 8GB of SWAP. Typically about 2GB of RAM and 0GB of SWAP are used by the system. Everything is 64bit, including the processes involved.
If I open a process that uses a lot of RAM (I estimate over 1 GB triggers this visibly) the system becomes very slow while some applications begin to crash. The victim processes seem to be those that use a bit more memory themselves (even 300 MB can make them targeted). Even after I close the process eating +1GB of RAM, the system continues to be slow for a while, which I assume means it’s freeing and optimizing the memory.
The most common test case for me is Blender 3D (memory eater) and Firefox (common victim). If I open a blend file that makes Blender use +2GB of RAM, Firefox occasionally crashes and I think plasma-desktop does too. Trying to open and use other small processes (such as Dolphin or Kwrite) is also very slow.
I’m confused because this is the behavior I’d expect when memory is full. Yet it happens when the RAM is barely half filled. I have 9GB out of which 2GB are normally used, so a new process eating 2GB only fills the memory up to 4GB (leaving 5GB free). Still, it acts like memory is full and the system barely manages. I don’t remember getting this back when I used Windows on the same hardware either.
Why does the system get so slow and unstable at this RAM usage? Are there any safe ways to tweak how memory is handled by the Kernel? Perhaps a BIOS setting could be the cause also… or Linux issues with triple-channel RAM?
On 08/12/2013 11:46 AM, MirceaKitsune wrote:
> slow and unstable
i can not answer your questions but have a few of my own:
what happens if you turn off desktop effects?
-if using a proprietary video driver, what happens if you switch to
an open driver (or vice versa)
what other process are involved (downloading movies/music/install
disk images, etc etc etc…or active Skype, or a TOR
server/redirector…etc etc etc…are you listening to music or
music video at the same time…that is, what happens if you are only using Blender)
which DE shows you this behavior? if KDE, what happens in GNOME?
LXDE? etc?
-any hints in /var/log/messages or ~/.xsession-errors
-any factory software being run?
-any software not from oss, non-oss, updates or packman?
-if you boot a live DVD/or do a fresh install+update repo updates
ONLY and run it, do you see the same slow/crashing? if not, it must
be something about your mix of software, right? drill down until you
find the bad actor, and then bugzilla it.
On 2013-08-12, MirceaKitsune <MirceaKitsune@no-mx.forums.opensuse.org> wrote:
> My machine has 9GB of DDR3 memory (triple-channel hence the impair
> value) plus 8GB of SWAP. Typically about 2GB of RAM and 0GB of SWAP are
> used by the system. Everything is 64bit, including the processes
> involved.
Very strange behaviour. I have a similar box with 6GB RAM + 12GB swap with no such problems. I take it you using
openSUSE 12.3 64-bit KDE with everything up to date? Clearly there’s something wrong; whether it’s RAM or CPU issues
causing the issues it’s difficult to tell; does a…
sh-4.2$ top
…before and during a slow-down show up any obvious culprits.
If all’s normal, my first guess (and I admit it would be a guess) would actually be a dying hard drive. Symptoms include
a slowing startup-speed over time, random freezes, and drive-thrashing during slow-ups. Bear in mind solid-state drives
(especially early generations ones) tend fail sooner that traditional drives. If you use RAID, it only takes one faulty
drive to cause problems.
> Why does the system get so slow and unstable at this RAM usage? Are
> there any safe ways to tweak how memory is handled by the Kernel?
> Perhaps a BIOS setting could be the cause also… or Linux issues with
> triple-channel RAM?
I use triple-channel RAM on 5 boxes, and Linux has never had a problem. You can tweak the swap settings manually and
safely but I don’t think that will help you solve the problem.
I use the proprietary ATI driver (fglrx) from the Geeko repository (9.012-1). I’ll be switching to the Radeon driver once it starts running high-end games better, but until then I prefer not to touch the drivers (I am a bit paranoid about my system). I am tempted to suspect fglrx could be a cause, since the latest version causes the X client limit to be reached and blocks my system (that’s why I use 9.012 and not the latest driver). In case it might be related, more info about the bug can be found here:
I use only KDE, latest stable version (4.10.5). Haven’t tried without desktop effects, I shall next time. Doubt it could be a cause however, this is likely a deeper system issue. I don’t run any torrents or anything that heavily uses network in the background… only Skype, Pidgin, KVIrc and Thunderbird. No software from Factory that I can think of, and the only programs from custom repositories apart from Packman that come to mind are the Second Life clients and Oxygen Transparent. Not going to reinstall my system, as for a live DVD I might try it later. And here are /var/log/messages and ~/.xsession-errors (warning, very large):
I doubt a dying hard drive is the cause also. This seems to be precisely related to memory, causes process slowdowns, and happens when SWAP seems to be empty. Never experienced issues with hard my drive either, which is a fairly recent Seagate disk with no doubts regarding quality and integrity.
Oh… something else I forgot to mention: Although I didn’t test it intensely there, this also seems to happen on my laptop (4GB of RAM). System gets way slower when a process uses 1GB although memory is about half full. Both my laptop and PC use the same software however, and have a Radeon / Mobility Radeon card with the same fglrx package.
>
> It took me a while to get a clearer view of what seems to be happening,
> although I’m only aware of the results and not the cause. I’m not sure
> if it’s a normal thing on Linux, though I don’t see any reason for this
> behavior. Here is the problem:
>
> My machine has 9GB of DDR3 memory (triple-channel hence the impair
> value) plus 8GB of SWAP. Typically about 2GB of RAM and 0GB of SWAP are
> used by the system. Everything is 64bit, including the processes
> involved.
>
> If I open a process that uses a lot of RAM (I estimate over 1 GB
> triggers this visibly) the system becomes very slow while some
> applications begin to crash. The victim processes seem to be those that
> use a bit more memory themselves (even 300 MB can make them targeted).
> Even after I close the process eating +1GB of RAM, the system continues
> to be slow for a while, which I assume means it’s freeing and optimizing
> the memory.
>
> The most common test case for me is Blender 3D (memory eater) and
> Firefox (common victim). If I open a blend file that makes Blender use
> +2GB of RAM, Firefox occasionally crashes and I think plasma-desktop
> does too. Trying to open and use other small processes (such as Dolphin
> or Kwrite) is also very slow.
>
> I’m confused because this is the behavior I’d expect when memory is
> full. Yet it happens when the RAM is barely half filled. I have 9GB out
> of which 2GB are normally used, so a new process eating 2GB only fills
> the memory up to 4GB (leaving 5GB free). Still, it acts like memory is
> full and the system barely manages. I don’t remember getting this back
> when I used Windows on the same hardware either.
>
> Why does the system get so slow and unstable at this RAM usage? Are
> there any safe ways to tweak how memory is handled by the Kernel?
> Perhaps a BIOS setting could be the cause also… or Linux issues with
> triple-channel RAM?
I’m hitting a similar issue here - 12.3 x86-64, stock KDE, core-I7 with 12GB
RAM and Nvidia GT630 video. Here, having Firefox 23 running seems to be one
common factor and the hassle seems to be related to opening a VirtualBox Win
session (memory hog). Watching the progression with top, it appears that
xorg is the root of the problem as it begins to grow memory usage
drastcally. Once it hits about 6GB of memory usage the crash follows
shortly - but my typical result is that the whole xorg session draps out.
If I simply log out and back in, the situation clears and I can press on for
a while. I only have a small swap - 2GB - but that never fills beyond about
40-50%.
The most noticable clues I’ve seen are that this all started after I updated
to FF 23. That puppy has given me some other problems sporadically and
seems to be involved every time. Dmesg after the xorg crash confirms that
it dies on an oom problem.
Running out of memory with xorg using over half of the available 12GB seems
a bit ridiculous…
I’ve had KDE desktop crash twice with heavy memory usage. Started with the last KDE update. nut before that and still I have had FireFox crash when I also have a 512meg VM running. I only have 2 gig so it is tight. Have not seen swap more then 50% full. Could be a Kernel issue maybe???
Another note I forgot to put up: This seems to be happening since I moved to openSUSE from Windows (almost an year), so it’s not a recent thing either. During this time I’ve had KDE 4.8, 4.9, and now at 4.10.