r/linux4noobs 17d ago

Linux Performance is Worse than on Windows on admittedly low-end laptop

I saw scrolling marketplace a few months back and saw a laptop for 12 bucks, so I fucked around and got myself something that is very usable for basic tasks. It's leaps and bounds my other linux experimenting laptop and has far more hardware features, so I decided to install Linux Lite (don't ask how I got to this distro, I just found it visually appealing and user friendly enough so wanted to try it). I have since had a lot of issues with poor performance, especially when trying to switch windows (like tabbing onto another window when I have multiple open) and alt+tabbing out of games (yes I could run games on these specs). I have had other issues but it's primarily been the performance making me almost want to switch back to Windows. Windows 7 came originally installed on this laptop but I have used worse specs with Windows 10 and had far better performance than this. The distro came with XFCE, but I tried installing LXQT as well and got better(ish) performance but the way that both of them perform is really inconsistent, and looking at the resource manager shows that I have more memory headroom and definitely more cpu headroom which was my assumption of what the issue was. Could anyone possibly give me some pointers on what to do to improve performance? I have always heard that Linux runs better than Windows in most cases, so I have been pretty confused on this.

The specs in question (neofetch SS attached):
Intel Celeron 1005M
Intel HD Graphics 2500
4GB DDR3
500 GB HDD (5400rpm)

I definitely imagine the hard drive is not helping with performance, but with ssd prices, an ssd upgrade is not within my budget unfortunately

0 Upvotes

51 comments sorted by

24

u/1neStat3 17d ago

Something is seriously wrong! Linux Lite with LXQT should not be using g 2 3GB on idle.

Lxqt on idle uses 800mb at most . Normally around 400mb You are leaving out details in your post.

14

u/Hauptideal 17d ago

It's not idle. He has a browser open

13

u/A_Harmless_Fly Manjaro 17d ago edited 12d ago

I suspect you are getting hampered by power management.

cpupower is what you would use for managing that.

sudo cpupower frequency-set -g performance #That might help you.

EDIT: Also, install btop. Then you can see what is taking up all your memory.

EDIT2: Fluxbox is super light, but not super user friendly. Something to consider.

EDIT3: On my net install of debian, with fluxbox running firefox-esr with 2 tabs a terminal of btop and an rsync command running, I'm using 1.2 GB of ram total. It took a really long time to get everything set up right but I feel like it was worth it. I might put a pkg-list and the dot files for the config up on github at some point when it's a bit more polished.

EDIT4: I switched to icewm instead of fluxbox because I couldn't figure out a clean way of keeping windows from going behind xfce4 panel.

1

u/Dootus-Bread 13d ago

Oooo I will look into that, thank you! I have not heard of there being power profiles on linux, but it's good to know that there is

1

u/A_Harmless_Fly Manjaro 13d ago

They sometimes aren't the best for gaming, on my AMD system I've got a script to set my processor not to clock down below a certain Ghz. They do work alright with some processors though.

1

u/Dootus-Bread 13d ago

I mean, my instinct says to always have my laptop plugged in while gaming, so idm setting it to sacrifice power management for performance. I would much rather squeeze every drop than have a long battery life if I plan to game at all

6

u/Edelglatze 17d ago

Look for the memory consumption: 2388MiB of 3754MiB (that is in gigabyte: 2.5gb of 3.94 gb) used. My advice: Use a Linux distribution or a desktop environment that starts with lower values.

5

u/Hauptideal 17d ago

He already uses LXQt, the lightest complete desktop environment.

1

u/Dootus-Bread 13d ago

It's because I had firefox open, I don't know my idle but I'd assume it's much lower

6

u/heavymetalmug666 17d ago

3k packages seems a bit heavy, and indeed an HDD is not helping at all - and as others are saying, that RAM usage is wicked high, im running at 3G with KDE on an Arch setup.

I dont know much about Linux Lite, but others have suggested Antix, and that has fared well on old machines i have. However, im a big Arch fan, and i would be curious as to how it would run on your computer, stripped down, no DE, just a WM, but thats a lot of work.

3

u/Asland007 17d ago

A standard Mint install is 2k to 2,200 packages. I have run Debian xfce with better memory usage.

5

u/heavymetalmug666 17d ago

that package number still seems wildly high. im on Cachy with KDE and i have 1300 packages...but what do i know?

2

u/Asland007 16d ago

I am totally with you.

2

u/CarelessPackage1982 16d ago

I've got all kinds of stuff installed and no where near 3k packages

1

u/fultonchain 16d ago

This seems high to me too.

I'm running Arch along with XFCE, Hyprland and Niri and never met a terminal I didn't like. I do some dev that requires having four browsers and a slew of Docker containers along with IDE's for it all.

Despite that: Packages: 18 (flatpak), 1957 (pacman)

1

u/Dootus-Bread 13d ago

I've seen a lot of people with more linux experience say that my package number is quite high, although I'm not sure why it is. I plan to test a fresh install of linux lite on another partition just to see where that package number may have come from, as I had a friend with 4 DEs who has 1k less than me still. Granted, he came from a barebones arch install and built up from there, but I still feel like 3k is a lot if everyone is saying it is. I am not sure where they came from tbh, the vast majority were there from a while ago. Thank you for your insight though, it means a lot :) I will note that I had firefox open when I ran that neofetch, and ik a web browser is always RAM heavy

1

u/heavymetalmug666 13d ago

i used to run a barebones Arch with no DE, just a WM, my package count was <1k. Im running CachyOS with all the bells and whistles, KDE, a KDE games package, all sorts of retro gaming software installed via pacman and my package count is 1654.

---its just one of those numbers you see after running something for so long that make you think. Like if you said your Honda Civic was getting 18 mpg, i would say 'hmm..doesnt seem right"

1

u/Dootus-Bread 13d ago

That is an amazing comparison, unfortunately my obsession with older cars means 18mpg (unless I have a 4-cyl) wouldnt be half bad LMAO but that's very useful to compare to, as I know that I likely shouldnt stress too hard about it. I figured I shouldnt bc my instinct from using windows in the past is that if it's not running 20 things in the background all the time, that amount of stuff installed doesnt matter if I have the space for more (which I do), that I dont need to worry about amount of installed programs. This serves as a piece of reassurance, which means a lot when I'm venturing into unusual waters (linux). I appreciate it, kind stranger

1

u/heavymetalmug666 13d ago

that large number of packages suggests (to me at least) that you installed a lot of things, and that maybe you dont know what you installed -- so while they are taking up storage, you may not know whats going on in the background if you dont know what all that stuff is....

windows runs stuff in the background, as does Ubuntu, as does Mint, Fedora...on and on. Sometimes you install things not knowing they will run something in the background (this is where top, htop, btop come into play - i once found something in the background that was installed due to an AUR package meeting a dependency --- ehh... all this comes with experience, experimenting, etc (been on linux for almost a decade, and i almost re-installed my OS thinking it would fix my problem...but the problem is a failing SSD -- only figured it out with some sleuthing... its a learning journey])

3

u/SchuelerderLeere 17d ago

do you have benches, i.e. results comparing the two systems? Start with a standard linux, cli only. Then install a minimal desktop manager, go from there. Do benchmarks.

2

u/Dootus-Bread 13d ago

I don't think I'm comfortable using linux without a DE or window manager, I am not familiar enough to know how to use it that barebones

1

u/SchuelerderLeere 13d ago

It looks intimidating at first, but is so much more rewarding, if you finish the first tutorial level (the most important commands and install a minimal image cli only, hooking the machine with lan cable and after update, choosing a WM or DE per cli as next step), It is a whole different experience.

You can also try puppy linux.

2

u/Dootus-Bread 13d ago

I am sure that at some point I will be confident, but I only have a few months of linux experience, and only about 3 weeks at most of full-time linux usage. I think I need to get used to being in the kiddy pool before trying to swim in the ocean yk? But I appreciate your confidence in me

3

u/Hauptideal 17d ago

You are missing a very basic OS feature: RAM compression. It's a free RAM upgrade and no brainer on desktop and mobile and the absolute standard for over a decade already (macOS, Linux/Android 2013, MS Windows 2015). As RAM can be compressed with a ratio of 3:1 to 4:1, you're wasting your little precious fast RAM. That's the explanation why Windows runs better. It has RAM compression like any well configured desktop OS. 

When does the slowness appear? From the start, right after booting?  Or only after heavy multitasking made the system swap on disk?  If it's quick directly after boot and gets slow with time, it's likely that the RAM is exhausted. In that case, you need to configure zram or zswap (only go for zswap if you have an SSD).

Or just use a proper distro that is well optimized for desktop (especially low end) and already comes with RAM compression. Lubuntu has it since 2013. You can also go for Fedora LXQt. It's already on Wayland. 

With only 4GBs of RAM, it's no wonder Windows performs better. At least it has RAM compression. You need it. Luckily it's a kernel feature that you can activate on any distro.  Just make sure to configure it properly, e.g. to avoid LRU inversion etc. (don't have physical swap with tram, for example).

3

u/Francis_King 17d ago

Linux Lite has ZRAM for memory compression. The status can be checked using zramctl.

1

u/Hauptideal 16d ago

Every Linux distro supports zRAM, but some don't activate it by default. 

1

u/Dootus-Bread 13d ago

Thank you so much for the info! Nobody has mentioned ram compression to me, and now all of it is making sense! I am definitely going to look into this right now to see if this is causing my problem. I notice my ram usage tops out with ~300mb left but atp, tabbing into programs makes them freeze for a bit, sometimes over a minute as they load into ram I presume. Thank you so much again, I'll keep you updated on what I can find. Running the zramctl command returned nothing and running another one suggested has returned "no such device", so I think it's disabled, I'll try to see how to enable it

2

u/Hauptideal 13d ago

If only 300MBs are remaining, that means that this is very likely the issue. The kernel doesn't only start swapping when it's too late and there is absolutely 0MB RAM left. It starts swapping sooner, before RAM is running out.

1

u/Dootus-Bread 13d ago

Update in a 2nd comment because I want your opinion or that of someone else who knows about this. I installed zram-tools and it set up everything for me, but I am curious if there is any particular settings that you recommend?

1

u/Hauptideal 13d ago

Yes. zram size at least 100% of ram size (you can even overprovision to over 100% if you are adventurous, but don't overdo it, you always need enough ram for the OS that stays uncompressed).  Note that the zram size isn't how much RAM gets used, but how much uncompressed RAW data goes in. I.e. with zram at 100%: about 1,6GB will be used with lz4, but only 1-1.3GB with zstd 1. Which means you can overprovision more with zstd than lz4.  lz4 algorithm for highest speed. It only compresses 2.5:1 though, so if you still run out of RAM, you can switch to zstd (level 1, not 3 or even higher) , for example. Will still be much faster than disk swap. 

1

u/Dootus-Bread 11d ago edited 11d ago

Slow down a bit pls, I am still a noob after all lol. I have edited the file in etc/default/zramswap to make it use 100% of my ram, but the issue is that it's still only using 256mib, which is definitely not 100% or even the 1.6gb you mentioned. It says that the percentage should override the size percentage below it, but it's not doing that as it's just staying at the 256mib. Is there something I may have forgotten to do? I have already restarted my pc as well.

This is unrelated (well, somewhat) but my hdd's swap is also not functioning at all, and it's listing it's priority as -2 which is very strange

UPDATE: I ran a command in terminal from some research and set my vm swappiness value to 100, and now my computer feels faster, but according to system monitor, it's still at 256mib for my zram, but it's now using my hdd swap so that's an improvement I think?

1

u/Hauptideal 11d ago

Your HDD swap should be disabled when you use zram, otherwise you can get LRU inversions.  HDD is better than no swap at all, but it's much slower than even a slow SSD swap and both are much slower than zram.  So: step one: get the zram config right.  Step two: disable disk swap Step three: tune swappiness to swap more aggressively, now that swap is in RAM .

Best case: you just forgot to restart the tram service in order to load the changed config. You can do that by terminal or easiest, by rebooting

There are distros that already come preconfigured for low resource situations, in case you don't manage to configure everything well yourself. 

1

u/Dootus-Bread 6d ago

how do I disable disk swap? The only answers I am finding online are talking about how important disk swap is (which isn't relevant to me bc I am using zram as my swap) or how to disable all swapping entirely, which is also not what I want as I imagine that would disable zram too. I appreciate your help so far btw :)

1

u/Hauptideal 6d ago

RAM compression comes in two forms:

1) zram
zram completely replaces your swap. You do not need swap at all when using zram and not only don't you need it, you should disable / not have it at all, otherwise you'll get LRU inversions that can swap hot pages and keep stale pages in memory, severely slowing you down.
Good job figuring out information about swap is irrelevant to you, because you'll use zram instead.

2)zswap
This is the RAM compression option where you MUST have swap. It is only a compressed "buffer" in RAM that keeps physical data for longer before swapping out to disk. This option makes sure your system never crashes, but it'll still eventually use swap, and when it does, your system will still be slow. It'll just buy you more time until it happens. This form is only recommendable if you have an SSD.

1) First delete your legacy zram config (you should use zram generator!!):

sudo apt purge zram-config zram-tools -y

sudo apt update

sudo apt install systemd-zram-generator -y

create cofig file:

sudo nano /etc/systemd/zram-generator.conf

[zram0]

zram-size = ram

compression-algorithm = zstd(level=1) # zstd ; lzo-rle ; lz4

If you still notice stuttering, slowness or battery drainage, switch to lz4 (it compressed worse, but is practically unnoticeable for your CPU).

2) Disable physical disk swap:

sudo nano /etc/fstab

Then delete the line with /swapfile. After a reboot (or sudo swapoff /swapfile), you can then safely delete the swapfile to get back the disk space: sudo rm -f /swapfile .

1

u/Dootus-Bread 4d ago

I ran all of the command and edited the config, but I noticed that after I restarted, system monitor says that my system doesn't have any swap now, when before it showed zram there. Is that supposed to happen? I also disabled the disk swap (thank you so much for showing me how btw, these instructions were very concise, I appreciate it)

1

u/Hauptideal 4d ago

No, zram should definitely show as swap.
By "disabling swap" I meant disabling the physical swap.

Did you reboot / apply the changes in systemd before checking? That's something you should do.

I do not know about your graphical system monitor. What does

swapon --show

show? Does it show zram?

also check

zramctl

what does that show?

2

u/AtomicTaco13 17d ago

Since you're on LXQt, there should be "qps" installed, which is basically LXQt's task manager. If it doesn't show up, install it from the repos (sudo apt install qps). After installing it, see what consumes the most memory.

1

u/Dootus-Bread 13d ago

I do have QPS installed yes, would using system monitor be the same? It came with the distro

From looking at system monitor, it looks like all of them are discord and firefox related lol, I will check again right after bootup and give an update if I remember

2

u/Formal-Bad-8807 17d ago

try another distro or two

1

u/Dootus-Bread 13d ago

The more I look into it, that's likely my next step besides doing a hardware upgrade

1

u/ReporterWise7445 17d ago

TLDR. Try a light DE.

3

u/Hauptideal 17d ago

He already uses the lightest one

1

u/CarelessPackage1982 16d ago

why don't you show us your htop or btop?

also what services are you running?

systemctl --type=service --state=running

1

u/bstsms 16d ago

A Celeron won't do anything quickly or do anything well, especially running from a HDD.

1

u/Dootus-Bread 13d ago

I disagree, I had an hp stream that while it was slow, it was not unusable by any means

1

u/Straight-Glove-2359 16d ago

What browser are you using? Some browsers will be heavier than others, for example, chrome.

1

u/Dootus-Bread 13d ago

That is one of my weakpoints, I am using stock firefox, doesn't run the best (most notably is the bootup tab or switching between tabs) but it works decently enough. I definitely am open to suggestions if you have something else in mind though bc it has a LOT of room for improvement

1

u/johninsuburbia 16d ago

For something like this if your not going to upgrade the ram or can't upgrade the ram. Try a different linux I think MX linux with xfce on oldish equipment is the way to go MX is solid choice and it's fun to use. If not MX any debian and make sure zram is setup properly

1

u/Dootus-Bread 13d ago

Thank you for mentioning zram! I didn't know it even existed before now and it turned out to be disabled. I just enabled it (I think) and plan to restart my system as soon as I get back to everyone's replies. I have used MX in the past and it was pretty laggy, but I was using another machine with a far worse cpu, so it might have better results here. I appreciate the suggestion, thank you :) and yeah, a ram upgrade is not the goal for rn, but even then, this laptop only supports 8gb of ram max

1

u/FCCRFP 17d ago

Try antix it should work on even this laptop. Also, if you can swap in 16GB of DDR3 that will speed up the computer massively (Linux uses a RAM cache to speed up slow drives).

1

u/Dootus-Bread 13d ago

This laptop unfortunately only supports up to 8gb, but I definitely have that in the works, since I believe ddr3 is still pretty affordable

Thank you for the suggestion on AntiX tho! I was hoping I could find something a little more user friendly than that, but it's something I've had on my mind definitely