How to kill everything when Puppy is going to freeze due to 100% CPU usage?

New to Puppy and have questions? Start here

Moderator: Forum moderators

Post Reply
bob93
Posts: 53
Joined: Fri Nov 25, 2022 8:29 am
Location: Fossapup64 9.5
Has thanked: 21 times
Been thanked: 1 time

How to kill everything when Puppy is going to freeze due to 100% CPU usage?

Post by bob93 »

Hi. I am careful not to overload the system. Only use 2 apps at a time when needed, and when browsing the internet I only use two tabs.
But there are some pages which are just too heavy or badly made and tend to get cpu usage at 100%. When I see that beginning to happen I right click Palemon (or Chromium) on the tray > Kill and then > OK on the confirmation dialog.
But today I couldn't do it. The system was so frozen the mouse stopped responding and I had to hold the poweroff button to force hardware shutdown which is not good.
Is there anything else I can do so that I don't have to force hardware shutdown? I would like to be able to prevent this, perhaps some function to make puppy automatically kill all running apps if CPU usage has been near 100% for more than 2 minutes, or a keyboard hotkey to kill everything without asking for confirmation. Is it possible?

My CPU is Intel Core Duo P8700 2.53 GHz and there's 2 GB, but it is always the CPU that hangs both according to conky and gatotray
I'm on Fossa 9.5 x64

Thank you

Fossapup64 9.5

williwaw
Posts: 1960
Joined: Tue Jul 14, 2020 11:24 pm
Has thanked: 172 times
Been thanked: 371 times

Re: How to kill everything when Puppy is going to freeze due to 100% CPU usage?

Post by williwaw »

some websites do this to my browser frequently.

maybe a way to get a terminal without the mouse? then you could kill the browser with a command.
I usually try to get the mouse to the tray and bring up this kill option

capture718.png
capture718.png (133.67 KiB) Viewed 1692 times
User avatar
MochiMoppel
Posts: 1241
Joined: Mon Jun 15, 2020 6:25 am
Location: Japan
Has thanked: 21 times
Been thanked: 440 times

Re: How to kill everything when Puppy is going to freeze due to 100% CPU usage?

Post by MochiMoppel »

bob93 wrote: Fri Dec 09, 2022 2:02 am

a keyboard hotkey to kill everything without asking for confirmation.

Ctrl+Alt+Backspace

williams2
Posts: 1062
Joined: Sat Jul 25, 2020 5:45 pm
Been thanked: 305 times

Re: How to kill everything when Puppy is going to freeze due to 100% CPU usage?

Post by williams2 »

Many (or most or all) Linux kernels have a builtin Out Of Memory killer (OOM)
which for most kernels doesn't work well, if it works at all.

EarlyOOM works very well. My machine has not slowed down because of out of memory, since I installed earlyoom.

See viewtopic.php?t=2980

About 34kb.

I have been running it with these parameters:

Code: Select all

earlyoom -r0 -m1 --avoid Xorg
User avatar
amethyst
Posts: 2420
Joined: Tue Dec 22, 2020 6:35 am
Has thanked: 57 times
Been thanked: 506 times

Re: How to kill everything when Puppy is going to freeze due to 100% CPU usage?

Post by amethyst »

Happens relatively frequently on my old laptop. Have to hit the power off button nothing else can be done mouse and keyboard frozen. Internet is getting too heavy for old machines running with new browsers. Too much sh*t running in the background. I use Opera Mini for general browsing. You can clear the memory caches every now and then. The latter helps (sometimes).

User avatar
bigpup
Moderator
Posts: 7003
Joined: Tue Jul 14, 2020 11:19 pm
Location: Earth, South Eastern U.S.
Has thanked: 915 times
Been thanked: 1532 times

Re: How to kill everything when Puppy is going to freeze due to 100% CPU usage?

Post by bigpup »

Go into the browser preferences settings.

Look for settings to control cache, images, pop ups, etc... that web pages are trying to do.
Look for any settings about running stuff in the background.

The things you do not tell us, are usually the clue to fixing the problem.
When I was a kid, I wanted to be older.
This is not what I expected :o

User avatar
Flash
Moderator
Posts: 979
Joined: Tue Dec 03, 2019 3:13 pm
Location: Arizona, U.S.
Has thanked: 52 times
Been thanked: 127 times

Re: How to kill everything when Puppy is going to freeze due to 100% CPU usage?

Post by Flash »

As MochiMoppel says, Ctrl+Alt+Backspace will restart the X server, which will kill all running processes. But if the keyboard isn't responding there's no hope.

Chaos coordinator :?
williams2
Posts: 1062
Joined: Sat Jul 25, 2020 5:45 pm
Been thanked: 305 times

Re: How to kill everything when Puppy is going to freeze due to 100% CPU usage?

Post by williams2 »

Again, the kernel has a builtin out of memory killer.

Which does not work well.

earlyOOM does work, very well.

earlyOOM uses about 200kb of ram.

Code: Select all

# ps5
 Private  +   Shared  =  RAM used	Program

152.0 KiB +  52.5 KiB = 204.5 KiB	earlyoom

It handles tail /dev/zero effortlessly.
WARNNG, without earlyOOM, tail /dev/zero will crash your OS, very, vary hard. You could lose data.

User avatar
amethyst
Posts: 2420
Joined: Tue Dec 22, 2020 6:35 am
Has thanked: 57 times
Been thanked: 506 times

Re: How to kill everything when Puppy is going to freeze due to 100% CPU usage?

Post by amethyst »

High CPU usage for extended periods can be a problem with especially laptops. My laptop either freezes completely or switch off in these circumstances (probably as a precaution for overheating). Some websites run my CPU into the red. Running out of memory is seldom the main culprit for me (I also have a swap file). I still have Windows XP as a dual boot on this machine. Will have to check whether I get so many hickups when using this, can't remember that I had these issues when still using XP but the internet has marched on since so have to run the same problematic websites with XP to see if the performance is better.

williwaw
Posts: 1960
Joined: Tue Jul 14, 2020 11:24 pm
Has thanked: 172 times
Been thanked: 371 times

Re: How to kill everything when Puppy is going to freeze due to 100% CPU usage?

Post by williwaw »

high cpu % and temps with browsers a problem here also.

I have disabled my /etc/hosts blocklist and firefox seems to be running cooler on the usual suspect sites.

can users who have browser issues mention if adblocking makes it worse?

User avatar
mikewalsh
Moderator
Posts: 6169
Joined: Tue Dec 03, 2019 1:40 pm
Location: King's Lynn, UK
Has thanked: 799 times
Been thanked: 1987 times

Re: How to kill everything when Puppy is going to freeze due to 100% CPU usage?

Post by mikewalsh »

I had several years of this stuff happening on a semi-regular basis. Ye anciente Dell lappie, with just 1.5 GB.....and the 2005 Compaq desktop with just 3 GB. I just used to perform a "hard power-off" when freeze-up time came round (which it did quite often).

I was getting warning signs from the Compaq - mid-2017 - that all was not well. Mostly graphic-related, but enough other awkward stuff to indicate possible mobo issues were on the horizon. And they were; early January 2020, I gave her the annual spring-clean.....and she would NOT start again. Caps had finally dried out.

In a way, things timed themselves just right. I bought the HP desktop, then a couple of months later, treated myself to the GeForce GT710; at that point, GPU prices hadn't yet gone stupid due to cryptomining. And with the near-continuous lockdowns, that first year of the pandemic, nobody was going out anywhere.....something I used to do quite a bit. So money began to pile up in the bank that wouldn't normally have been there.

The HP came with just 4 GB DDR4. By the end of the year, I'd maxed her out at the full 32GB; I'd already decided that RAM was never going to be an issue for me again.....not if I had anything to do with it.

(I found a brilliant deal at Amazon in November that year; a 32GB Crucial kit for less than half what Crucial themselves were asking for their 16 GB one. So I grabbed it!) :D

------------------------------------

It sounds like overkill, I know.....but there's method in the madness. At long last, I could do whatever I wanted to do; could have 2 or even 3 browsers open, be video-editing, watching YouTube (or NetFlix), etc, etc.....it made no difference. The most I've yet seen in use was 9.5 GB on one memorable afternoon, and it barely bothered it. Multi-tasking was now entirely feasible, even with 'commercial' apps as opposed to Puppy-specific ones. And the 'quad-core' Pentium G5400 - dual-core with HT, 3.7 GHz and plenty of modern instruction sets - has the 'legs' to run with it. It's made all the difference in the world.

Mike. ;)

williwaw
Posts: 1960
Joined: Tue Jul 14, 2020 11:24 pm
Has thanked: 172 times
Been thanked: 371 times

Re: How to kill everything when Puppy is going to freeze due to 100% CPU usage?

Post by williwaw »

The HP came with just 4 GB DDR4. By the end of the year, I'd maxed her out at the full 32GB; I'd already decided that RAM was never going to be an issue for me again.....not if I had anything to do with it.

(I found a brilliant deal at Amazon in November that year; a 32GB Crucial kit for less than half what Crucial themselves were asking for their 16 GB one. So I grabbed it!) :D

------------------------------------

It sounds like overkill, I know.....but there's method in the madness. At long last, I could do whatever I wanted to do;

more ram makes the cpu work better?

how can I look at my ram usage when the cpu starts running hot?

User avatar
amethyst
Posts: 2420
Joined: Tue Dec 22, 2020 6:35 am
Has thanked: 57 times
Been thanked: 506 times

Re: How to kill everything when Puppy is going to freeze due to 100% CPU usage?

Post by amethyst »

how can I look at my ram usage when the cpu starts running hot?

Run in terminal:

Code: Select all

free
User avatar
mikewalsh
Moderator
Posts: 6169
Joined: Tue Dec 03, 2019 1:40 pm
Location: King's Lynn, UK
Has thanked: 799 times
Been thanked: 1987 times

Re: How to kill everything when Puppy is going to freeze due to 100% CPU usage?

Post by mikewalsh »

williwaw wrote: Sat Dec 10, 2022 2:47 am

The HP came with just 4 GB DDR4. By the end of the year, I'd maxed her out at the full 32GB; I'd already decided that RAM was never going to be an issue for me again.....not if I had anything to do with it.

(I found a brilliant deal at Amazon in November that year; a 32GB Crucial kit for less than half what Crucial themselves were asking for their 16 GB one. So I grabbed it!) :D

------------------------------------

It sounds like overkill, I know.....but there's method in the madness. At long last, I could do whatever I wanted to do;

more ram makes the cpu work better?

how can I look at my ram usage when the cpu starts running hot?

@williwaw :-

Um.....that's perhaps an over-simplification of the situation, in so many ways.

It's probably more to the point to say it's something of a delicate balancing-act.....between the CPU itself, its generation, speed, instruction sets, and abilities.....the generation (DDR!/2/3/4), speed and latency of your RAM.....and what you as an individual actually DO with your machine.

But in broad terms, more RAM doesn't so much make the CPU work better as it makes things easier for the system as a whole. Any single-core CPU, today, is going to be working flat-out pretty much all the time, especially with the sheer amount of unnecessary crap that's running, by default, in the background of so many web-sites. Rockedge has pretty much summed the situation up perfectly; it's bad website design by devs who either don't realise what they're doing.....or, more likely, simply don't care.

The more cores your CPU has, the faster it runs, and the greater number of up-to-date instructions sets it has, the better use it can make of that extra RAM.....and the less likely it is to start "swapping". Your system will generally run smoother, and be more stable as a result.

I've mentioned about this before. It seems to be a constant battle between manufacturers who try to develop new technologies to make everybody's life easier.....and developers, who see all these extra, additional resources, and immediately decide that their already "lazy" coding is going to drop to a new "low" as they do their utmost to gobble said resources up with ever-increasing amounts of totally useless junk......just because it "looks good".

The modern tech world is inhabited by an awful lot of shallow, self-centered individuals who seem determined to boost their already over-inflated egos at everybody else's expense. That's the way I read it, anyway. No doubt plenty will disagree with me.

Mike. ;)

williwaw
Posts: 1960
Joined: Tue Jul 14, 2020 11:24 pm
Has thanked: 172 times
Been thanked: 371 times

Re: How to kill everything when Puppy is going to freeze due to 100% CPU usage?

Post by williwaw »

mikewalsh wrote: Sun Dec 11, 2022 1:15 am

@williwaw :-

Um.....that's perhaps an over-simplification of the situation, in so many ways.

It's probably more to the point to say it's something of a delicate balancing-act.....
Mike. ;)

yes, the devils always in the details

Rockedge has pretty much summed the situation up perfectly; it's bad website design by devs who either don't realise what they're doing.....

so the challenge has moved from running a usable OS on older hardware, to just running a secure browser on older hardware.

Perhaps there is a need for some way to set a kill switch for the app/browser at some adjustable level of resource hogging? At least to keep the hardware (cpu) from overheating too much?

williams2 wrote: Fri Dec 09, 2022 5:01 am

Many (or most or all) Linux kernels have a builtin Out Of Memory killer (OOM)
which for most kernels doesn't work well, if it works at all.

EarlyOOM works very well. My machine has not slowed down because of out of memory, since I installed earlyoom.

See viewtopic.php?t=2980

About 34kb.

I have been running it with these parameters:

Code: Select all

earlyoom -r0 -m1 --avoid Xorg

this seems to have potential, I am still looking for the arguments needed to generate a shutdown at a lower level of ram usage.

williams2
Posts: 1062
Joined: Sat Jul 25, 2020 5:45 pm
Been thanked: 305 times

Re: How to kill everything when Puppy is going to freeze due to 100% CPU usage?

Post by williams2 »

looking for the arguments needed to generate a shutdown

By shutdown do you mean shutdown an app like Firefox
or do you mean shutdown the Puppy operating system ?

EarlyOOM shuts down running applications like Firefox, Pale Moon,Geany, Abiword, mpv. etc.

So you have enough free ram to keep going, and your mouse and keyboard work normally.

You have configuration options that let you choose applications that you prefer to be killed, and you can choose applications that you prefer not to be killed.

This is the line I use to start EarlyOOM:

Code: Select all

killall -q earlyoom ; earlyoom -r0 -m1 --avoid 'Xorg' &> /tmp/yoom.log & disown

It would be better to start it from rc.local, then you would not need the killall command..

If you want to try it you could run it with no parameters ./earlyoom
the defaults should be good enough to try it.

williwaw
Posts: 1960
Joined: Tue Jul 14, 2020 11:24 pm
Has thanked: 172 times
Been thanked: 371 times

Re: How to kill everything when Puppy is going to freeze due to 100% CPU usage?

Post by williwaw »

not shutdownthe OS, but kill the offending app, which in my case is usually the browser,
a script with

Code: Select all

earlyoom -s 100 -m 50  --avoid Xorg

seems to work, where
-s 100 lets me use earlyoom when there is no swap
-m 50 sends SIGTERM when available ram drops below 50%. I am still adjusting this value to something that doesn't let the cpu get too hot.

Thanks for posting the pet.

User avatar
wiak
Posts: 4082
Joined: Tue Dec 03, 2019 6:10 am
Location: Packing - big job
Has thanked: 65 times
Been thanked: 1208 times
Contact:

Re: How to kill everything when Puppy is going to freeze due to 100% CPU usage?

Post by wiak »

williwaw wrote: Sun Dec 11, 2022 4:53 am

not shutdownthe OS, but kill the offending app, which in my case is usually the browser,
a script with

Code: Select all

earlyoom -s 100 -m 50  --avoid Xorg

seems to work, where
-s 100 lets me use earlyoom when there is no swap
-m 50 sends SIGTERM when available ram drops below 50%. I am still adjusting this value to something that doesn't let the cpu get too hot.

Thanks for posting the pet.

Hmmm... that's the problem I have with the likes of earlyoom - I don't want programs like that to start killing processes when I have significant RAM still available. 50%...!!!...wow...on my current laptop that means processes could suddenly get killed when I have 16GB RAM still available! What is is got to do with cpu heat?

I think the problem is that RAM can start vanishing at a high rate when doing memory intensive work and earlyoom needs time (meaning RAM in reserve really) to bring the system under control before it freezes; not such a problem when you allow swap (virtual RAM situation), where matters may slow down dramatically but not result in an actual freeze. But... I almost never allocate space for swap on any of my systems and certainly not on the 32GB ram machine... Overall, it becomes necessary to configure the likes of earlyoom differently depending on how much RAM the various machines have to start with and what kind of computer processing tasks you are doing (e.g. large compiles or graphic processing RAM intensive). Problem with a percentage allocation, for example, is that 10% of 4GB, being 400MB is very much smaller than if setting for 10% on 32GB machine (basically a waste of around 3GB since suddenly processes die when still 3GB RAM available...!). Definitely best to allocate some swap if using such process killers I feel - and low swappiness so you can be reasonably sure actual RAM is running out before your browser tabs start getting killed off or whatever!

So overall, I try to avoid such techniques, but nice to have an activate earlyoom button should I start doing something I know will be increasingly memory intensive, but depends if the work is critical in which case no way do I want to kill any processes required to complete the job. No easy answer to all of this - except the recipe similar to earlyoom plus some swap is good; no swap case is difficult with earlyoom... And yes, you can exclude some processes from being ever killed... even groups of processes, but unfortunately that won't help if these processes happen to be the very ones that are rapidly using up RAM...

https://www.tinylinux.info/
DOWNLOAD wd_multi for hundreds of 'distros' at your fingertips: viewtopic.php?p=99154#p99154
Αξίζει να μεταφραστεί;

User avatar
wiak
Posts: 4082
Joined: Tue Dec 03, 2019 6:10 am
Location: Packing - big job
Has thanked: 65 times
Been thanked: 1208 times
Contact:

Re: How to kill everything when Puppy is going to freeze due to 100% CPU usage?

Post by wiak »

Fedora has been using earlyoom by default for a while, though, not surprisingly, looking towards moving to use a systemd-oomd service. A couple of years ago they were debating, at a technical level, some of the issues I mentioned in above post:

https://pagure.io/fedora-workstation/issue/119

It will also be possible to receive complaints from users whose applications will crashes before the appearance of obvious signs of OOM, especially from those who do not use the swap space. For users, this may look like an unreasonable termination of applications against the background of complete well-being, if they do not monitor the memory level and have not heard about enabling earlyoom by default.

In the case of no swap, I agree this becomes difficult to use a single percentage. 1% is too low for e.g. 8GiB RAM system, and is too high for e.g. 64GiB RAM system. This might be the most significant liability of the feature.

Even though no swap isn't our default configuration, and the installer warns users when swap isn't configured, I think it's sufficiently common users have systems with lots of RAM forego swap. I'm not convinced merely documenting users will experience OOM killing of processes at 5% of 32-64GiB, e.g. 1.6-3.2GiB free RAM, is acceptable.

However, if there is no swap, earlyoom has only a single low watermark, free RAM. Once that gets to 5% on a 64GiB system, i.e. 3.2GiB free, it's going to kill something. That's the problem. 3.2GiB free is plenty of RAM to keep chugging away, so in the no swap case I think it needs a different metric for what the low watermark is.

We cannot have a definite answer now. Some users would rather wait until the compilation is complete. Other users would prefer to achieve high responsiveness at all costs. Some users criticize earlyoom for taking early corrective actions. But in the case of an attempt to maintain the responsiveness of the desktop, based on the PSI, the corrective action will occur even earlier.

https://www.tinylinux.info/
DOWNLOAD wd_multi for hundreds of 'distros' at your fingertips: viewtopic.php?p=99154#p99154
Αξίζει να μεταφραστεί;

User avatar
Phoenix
Posts: 341
Joined: Fri Feb 12, 2021 2:03 am
Location: Canada
Has thanked: 4 times
Been thanked: 48 times

Re: How to kill everything when Puppy is going to freeze due to 100% CPU usage?

Post by Phoenix »

You COULD enable Sysrq but.. the kernel devs don't advise this.
Regardless if you want to enable this which the kernel will always respond or will respond to (eventually), you can configure this functionality and rebuild the kernel.
To call the OOM killer you can invoke it via Sysrq+f or, Alt+PrtScreen+f.

IRC: firepup | Time to hack Puppy!

williwaw
Posts: 1960
Joined: Tue Jul 14, 2020 11:24 pm
Has thanked: 172 times
Been thanked: 371 times

Re: How to kill everything when Puppy is going to freeze due to 100% CPU usage?

Post by williwaw »

wiak wrote: Sun Dec 11, 2022 10:05 am
williwaw wrote: Sun Dec 11, 2022 4:53 am

not shutdownthe OS, but kill the offending app, which in my case is usually the browser,
a script with

Code: Select all

earlyoom -s 100 -m 50  --avoid Xorg

seems to work, where
-s 100 lets me use earlyoom when there is no swap
-m 50 sends SIGTERM when available ram drops below 50%. I am still adjusting this value to something that doesn't let the cpu get too hot.

Thanks for posting the pet.

Hmmm... that's the problem I have with the likes of earlyoom - I don't want programs like that to start killing processes when I have significant RAM still available. 50%...!!!...wow...on my current laptop that means processes could suddenly get killed when I have 16GB RAM still available! What is is got to do with cpu heat?

I think the problem is that RAM can start vanishing at a high rate when doing memory intensive work and earlyoom needs time (meaning RAM in reserve really) to bring the system under control before it freezes; not such a problem when you allow swap (virtual RAM situation), where matters may slow down dramatically but not result in an actual freeze. But... I almost never allocate space for swap on any of my systems and certainly not on the 32GB ram machine... Overall, it becomes necessary to configure the likes of earlyoom differently depending on how much RAM the various machines have to start with and what kind of computer processing tasks you are doing (e.g. large compiles or graphic processing RAM intensive). Problem with a percentage allocation, for example, is that 10% of 4GB, being 400MB is very much smaller than if setting for 10% on 32GB machine (basically a waste of around 3GB since suddenly processes die when still 3GB RAM available...!). Definitely best to allocate some swap if using such process killers I feel - and low swappiness so you can be reasonably sure actual RAM is running out before your browser tabs start getting killed off or whatever!

So overall, I try to avoid such techniques, but nice to have an activate earlyoom button should I start doing something I know will be increasingly memory intensive, but depends if the work is critical in which case no way do I want to kill any processes required to complete the job. No easy answer to all of this - except the recipe similar to earlyoom plus some swap is good; no swap case is difficult with earlyoom... And yes, you can exclude some processes from being ever killed... even groups of processes, but unfortunately that won't help if these processes happen to be the very ones that are rapidly using up RAM...

Hi Wiak

I'm using an old alienware laptop for browsing, its got a nice screen and Im trying to keep the cpu from getting too hot so as to be able to use it for a while longer. I dont want to kill the machine watching youtube vids.
How high do you think I should let the cpu temps go?
Is there a better tool?

User avatar
amethyst
Posts: 2420
Joined: Tue Dec 22, 2020 6:35 am
Has thanked: 57 times
Been thanked: 506 times

Re: How to kill everything when Puppy is going to freeze due to 100% CPU usage?

Post by amethyst »

@williwaw
As far as watching youtube videos goes, the best thing to do is to avoid loading the resource hungry youtube site. I watch youtube videos via the DuckDuckGo or Bing search sites.

User avatar
wiak
Posts: 4082
Joined: Tue Dec 03, 2019 6:10 am
Location: Packing - big job
Has thanked: 65 times
Been thanked: 1208 times
Contact:

Re: How to kill everything when Puppy is going to freeze due to 100% CPU usage?

Post by wiak »

williwaw wrote: Sun Dec 11, 2022 7:46 pm

I'm using an old alienware laptop for browsing, its got a nice screen and Im trying to keep the cpu from getting too hot so as to be able to use it for a while longer. I dont want to kill the machine watching youtube vids.
How high do you think I should let the cpu temps go?
Is there a better tool?

I'd agree to do whatever you can to keep the CPU usage percentage down, since not using so much energy and thus heating so much then, so external-to-browser-youtube-watching a good tip indeed.
But, why is it getting hot? Best if you could addrress that, though I'm sure you've blown out the dust from the fan and so on?
I don't know what temps you can safely go up to, or for how long. Trouble is that too high for too long and you will permanently damage the machine even if keeps working and thereafter if you ever manage to fix the overheating issue it will still be damaged. If fan not moving much, personally I'll try and get to it some way or another - on my old HP elitebook machines the fan is buried at bottom of laptop under the main motherboard and I'm far too lazy to try and disassemble that far. It has a magnesium case which turns out to be relatively easy to chip away at with long nose pliers... so I have huge hole in bottom of case where fan is now which allowed me to clean out the fan sufficiently to keep it turning for a year or two now after it pretty much seized up. I can't say I recommend my rough method, but for me it was better than stressing out and maybe ruining my old HP running it too hot.

You could be using most of your RAM without necessarily using much CPU though so limiting RAM use doesn't mean the machine will not get hot (except earlyoom might result in CPU hogging processes being shut down, but really it is more concerned with RAM-hogging processes which may simply use lots of RAM and may or may not be using much CPU actually).

https://www.tinylinux.info/
DOWNLOAD wd_multi for hundreds of 'distros' at your fingertips: viewtopic.php?p=99154#p99154
Αξίζει να μεταφραστεί;

williwaw
Posts: 1960
Joined: Tue Jul 14, 2020 11:24 pm
Has thanked: 172 times
Been thanked: 371 times

Re: How to kill everything when Puppy is going to freeze due to 100% CPU usage?

Post by williwaw »

@amethyst
good suggestion for youtube, tx
more and more its also just looking at the news

looking for newsreader that wont bork the hardware i guess

bob93
Posts: 53
Joined: Fri Nov 25, 2022 8:29 am
Location: Fossapup64 9.5
Has thanked: 21 times
Been thanked: 1 time

Re: How to kill everything when Puppy is going to freeze due to 100% CPU usage?

Post by bob93 »

williwaw wrote: Sun Dec 11, 2022 10:31 pm

@amethyst
good suggestion for youtube, tx
more and more its also just looking at the news

looking for newsreader that wont bork the hardware i guess

You can also watch youtube in SMPlayer, it's the only I can do it on my laptop

Fossapup64 9.5

User avatar
amethyst
Posts: 2420
Joined: Tue Dec 22, 2020 6:35 am
Has thanked: 57 times
Been thanked: 506 times

Re: How to kill everything when Puppy is going to freeze due to 100% CPU usage?

Post by amethyst »

Getting rid of gimmicks like conky also helps. Last time I checked, conky was the biggest resource mongrel after the browser on my machine.

User avatar
gychang
Posts: 591
Joined: Fri Aug 28, 2020 4:51 pm
Location: San Diego, CA
Has thanked: 206 times
Been thanked: 64 times

Re: How to kill everything when Puppy is going to freeze due to 100% CPU usage?

Post by gychang »

I had a similar issue of CPU / RAM maxing out in my fanless old miniPC.

1. CPU scaling tool to throttle less CPU use
2. add zram function to maximize use of RAM
I did not answer your question directly but these may prevent lockup.

======

Puppy Bytes, utube videos
https://www.youtube.com/channel/UCg-DUU ... u62_iqR-MA

======

User avatar
wizard
Posts: 1990
Joined: Sun Aug 09, 2020 7:50 pm
Has thanked: 2662 times
Been thanked: 694 times

Re: How to kill everything when Puppy is going to freeze due to 100% CPU usage?

Post by wizard »

How high do you think I should let the cpu temps go?

Look up your CPU's spec, for Intel's the Tcase temperature is the upper limit. Other stuff:
-run the laptop on a hard, flat surface so you do not block the cooling vents
-find the fan and heat sink vents and blow them out with "canned air" or a shop vac on blow. Insert the end of a paper clip into the fan blades to prevent over spinning.
-use an adblocker such as Ublock-Origin to reduce the amount of stream data
-view the video in a window instead of full screen

Most dual core or better CPU's with 4gb ram or more should be able to view Youtube at 60C or less.

wizard

Big pile of OLD computers

Eastler_Dart
Posts: 80
Joined: Wed Aug 05, 2020 3:34 am
Has thanked: 1 time
Been thanked: 8 times

Re: How to kill everything when Puppy is going to freeze due to 100% CPU usage?

Post by Eastler_Dart »

my experiences with fossapup64 running frugal without a save-file are:
mostoften the probs are the handling of real-ram and swapspace-ram.
If my Ram (4GB) gets hardly used, the system begins to swap out,
copies lots of Data out of Ram to swapspace, if you go back to an
other application, the sytem has to copy that Ramparts back in real ram ....
that takes several seconds :-(

reasons <=> solution
1: the directory /tmp is holding in ram.
thisway everything programms are storing temporarly needs ram
<=> make a empty directory on Harddisk, say "myTemp", and link that as "tmp" in your system.
2: the directory /root/.cache is holded in ram
thisway every cache-file (browser?) needs ram
<=> make a empty directory on Harddisk, say "myCache", and link that as "/root/.cache" in your system.
You have to do that at a (bootup-) point, where your system has not used /root/.cache /tmp
( I havn't done this in my system at the moment, but it's planned :shock: :-) )

If you success in doing that, you should tell your system,
to delete the contents in the Hdd Directories myCache and myTemp at shutdown,
so that at next bootup there is nothing in.

When my system begins to 'hang', I try to get a console on
/root/.cache/mozilla/firefox/xwjd51ai.default-release/cache2/entries
and delete all files there. Often this brings 700-900 MB free Ram
(until firefox needs them and thats why saves them again)
The problem with this tip is, that the part of the path
'xwjd51ai.default-release' is on every system different,
maybe in special setups (this directory not defined in SFS
so that firefox build it new up at boot) it differs with every reboot.

If you can be sure, that on your system
/root/.cache/mozilla/firefox/xwjd51ai.default-release
has the same name every bootup, you can put that deleting
in your /root/.jwmrc with a shortkey
for example:
<Key mask="A" key="F3">exec:sh -c "rm /root/.cache/mozilla/firefox/xwjd51ai.default-release/cache2/entries/*"</Key>
with menu->exit->RestartWindowManager this Hotkey is active
pressing leftALT+F3 deletes the firefox cache files

If you want to find out the name of that, take a look in /root/.mozilla/firefox/profiles.ini,
there the name is listed.

hope my thoughts can help, Eastler

P.S: a second problem ist overheat and immediately shutdown (without saving anything) from the kernel.
mostly that happens, when I pack gread sfs-files. In that case I tell mksquashfs to use only 1 kernel
example: mksquashfs * ../my.sfs -processors 1
with that mostly I success in building SFSs with 200 or 400 MB of size

Post Reply

Return to “Beginners Help”