Speed up your Mint!


Back to the home page


Speeding up your Linux Mint is fun! That way, you'll get more performance out of your computer for free.

Note: are you using Ubuntu? There's a separate page for speed tips for Ubuntu.

There are several tweaks to make Linux Mint 18.x run faster. Some are quite safe, some are risky. Here you'll find only the safe ones.

I don't like risky tweaks, because I think that stability and reliability are much more important than a little speed gain. That's why I've collected a couple of speed tips, that you can apply safely and with which you can make your Mint run considerably faster in many cases.

Those tips are mainly how-to's that can be found elsewhere on this website as well, but scattered all over the site. I've bundled them on this page, that only deals with speed gain.

Note: even though you can apply those tips safely, nothing in life is really for free.... You always pay some "price". You disable a particular system service, a couple of nice visual effects or some feature.

Each tweak therefore has its own "price tag". So you should consider before you apply a tip, whether you're willing to pay the "price" for it.


Written with Xfce in mind, but useful in Cinnamon and Mate as well

These tips are useful for all desktops of Linux Mint: Cinnamon, Mate, KDE and Xfce.

But the tips are especially aimed at Linux Mint with the Xfce desktop, because that particular lightweight desktop is often used on slow older computers that are in dire need of a speed boost.

Improve usage of the system memory (RAM)

1. You can improve the usage of the system memory with the following tweaks:

The absolute number one: decrease swap use

1.1. This is especially noticeable on computers with relatively low RAM memory (2 GB or less): they tend to be far too slow in Mint, and Mint accesses the hard disk too much. Luckily, this can be helped.

Note: does your computer have 4 GB RAM or more? Then you can skip this item, because with so much RAM you probably won't notice any benefits from applying it.

On the hard disk there's a separate partition for virtual memory, called the swap. When Mint uses the swap too much, the computer slows down a lot.

Mint's inclination to use the swap, is determined by a value. The lower the value, the longer it takes before Mint starts using the swap. On a scale of 0-100, the default value is 60. Which is much too high for normal desktop use, and only fit for servers. Decreasing this value on a desktop computer has no negative side effects whatsoever.

A detailed explanation can be found here (link dead? Then download this pdf file with the same content).

Now the how-to.

a. First check your current swappiness value. Type in the terminal (use copy/paste):

cat /proc/sys/vm/swappiness

Press Enter.

The result will probably be 60.

b. To change the swappiness into a more sensible setting, type in the terminal (use copy/paste to avoid typo's):

gksudo xed /etc/sysctl.conf

Press Enter.

Now a text file opens. Scroll to the bottom of that text file and add your swappiness parameter to override the default. Copy/paste the following two green lines:

# Decrease swap usage to a more reasonable level
vm.swappiness=10

c. Save and close the text file. Then reboot your computer.

d. After the reboot, check the new swappiness setting:

Launch a terminal window.
(You can launch a terminal window like this: *Click*)

Type (use copy/paste):

cat /proc/sys/vm/swappiness

Press Enter.

Now it should be 10.

Note: if your hard disk is an SSD, your machine will benefit from an even bigger decrease in swappiness. That's because too many write actions, like frequent swapping, reduce the lifespan of an SSD. For an SSD I advise a swappiness of 1. Also check these tips for optimizing an SSD for your Linux.

More than 1 GB memory (RAM): tame the inode cache

1.2. Computers with more than 1 GB of memory (RAM), will probably benefit by shrinking the inode cache less aggressively.

The price that you pay for this, is that certain system items will remain longer in the RAM memory, which decreases the amount of available RAM for general tasks. That's why this tweak is only useful for computers with more than 1 GB of memory (RAM).

This is how you do it:

a. Type in the terminal (use copy/paste):

gksudo xed /etc/sysctl.conf

Press Enter.

Now a text file opens. Scroll to the bottom of that text file and add your swappiness and cache parameters to override the defaults, so copy/paste the following two green lines:
# Improve cache management
vm.vfs_cache_pressure=50
d. Close the text file and reboot your computer.

Only 768 MB RAM or less: enable zRam

1.3. When your computer has very little RAM (768 MB or less), then of course your best choice is a lightweight member of the Mint family, like Mint Xfce. But even then the lack of memory will remain a problem, which will cause your system to slow down from time to time. Even when the swappiness has been decreased to 5.

In that case, you might achieve better results by enabling the experimental kernel module zRam. zRam creates a compressed swap file in your RAM. The compression factor is the gain: with that, you "increase" your RAM.

Note: this hack might make your system unstable! So do not apply it on important computers.

The price you pay for this, is threefold:

- Your processor (CPU) is being taxed more heavily, because it'll have to compress and decompress all the time;

- When the system has filled the RAM swap, it'll start swapping on the hard drive as well. With a heavy burden: the chunk of memory that has been sacrificed for the RAM swap.

- For the time being it's still an experimental module, so this extra layer of complexity might cause instability.

That's why, for the time being, I advise zRam only for computers with very little RAM, and even then only in combination with a swappiness that has been decreased to 5. Furthermore, zRam isn't suitable yet for production computers, but only for test machines and other, non-essential computers.

You can install it as follows:

Launch a terminal window.
(You can launch a terminal window like this: *Click*)

Type (use copy/paste):

sudo apt-get install zram-config

Press Enter. Type your password when prompted; your password will remain entirely invisible, not even dots will show, this is normal.

Reboot your computer.


Check

Now check whether it works, with the following terminal command:

cat /proc/swaps

Press Enter.

If all has gone well, you should receive a report about one or more /dev/zram "partitions". zRam is active then; no need for further action.

How to disable zRam again

1.3.1. When you want to disable and remove zRam again, it can't be done by the simple terminal command "apt-get remove". This is how you do it:

a. Launch a terminal window.
(You can launch a terminal window like this: *Click*)

Type (use copy/paste):

sudo apt-get purge zram-config

Press Enter. Type your password when prompted; your password will remain entirely invisible, not even dots will show, this is normal.

b. Reboot your computer.

c. Now check whether the removal has succeeded, with the following terminal command:

cat /proc/swaps

Press Enter.

If all has gone well, you should receive no report anymore about one or more /dev/zram "partitions".

Make your Solid State Drive (SSD) run faster

2. Do you have an SSD for hard drive? Then optimize it to make it faster.

Remove indexing application apt-xapian-index and plumbing for VirtualBox

3. a. The indexing application apt-xapian-index speeds up certain search operations, but it can slow down older and weaker computers a lot. You can freely remove this package, because it's not essential. In real life you'll hardly miss it. In lightweight Lubuntu it's not even there by default.

If you have installed Synaptic Package Manager: a side effect of the removal is, that the "Quick search" box disappears from the panel of Synaptic. This means that you have to use the search button (the one with the magnifying glass icon) in the panel of Synaptic now.

This search button is superior to the Quick search anyway (it produces more search results), so this disappearance is actually an extra advantage.

Removing is easy:

Launch a terminal window.
(You can launch a terminal window like this: *Click*)

Type (use copy/paste to prevent errors):

sudo apt-get purge apt-xapian-index

Press Enter. When prompted, type your password. Your password will remain entirely invisible, not even dots will show, this is normal.
Press Enter again.

Reboot your computer.

b. By default, Linux Mint contains some plumbing for VirtualBox. If you don't use VirtualBox, then this plumbing is superfluous. What's more, it slows down certain update processes.

You can remove it like this:

Launch a terminal window.
(You can launch a terminal window like this: *Click*)

Type (use copy/paste to prevent errors):

sudo apt-get purge virtualbox*

Press Enter. When prompted, type your password. Your password will remain entirely invisible, not even dots will show, this is normal.
Press Enter again.

Disable Java in Libre Office

4. The performance of Libre Office can be enhanced greatly, when you disable Java in it. This will disable a few features, but usually you won't even miss those.

Toolbar Libre Office Writer - Tools - Options...

LibreOffice - Advanced - Java Options:
remove the tick for: Use a Java runtime environment

Turn off some startup applications

5. You can speed up Mint somewhat, by disabling a couple of system services that may be superfluous for you. This tweak can be compared to tweaking msconfig in Windows.

These are called startup applications, because they're being launched at startup. Untick what you don't need and reboot your computer (or log out and then log in again).

Mint Xfce: type session in the search box of the menu and select:
Session and Startup

Note: only remove the ticks, do not remove the application from the list! Keep the tweak easily reversible (you never know). When in doubt about a particular application: don't do anything, just leave it the way it is.

Examples of system services that many people don't need:
- Bluetooth Manager
- NVIDIA X Server Settings

Note: unticking startup applications is a user preference, so repeat this in each user account.

(continued in the column on the right)


This website is being sponsored by Google Ads.

Are you using an ad blocker? Then you're also blocking my earnings from advertisements....

If you wish to support my website, you can configure your ad blocker to make an exception for this website. Or you can make a donation (and get free goodies).

Thanks in advance....


Cinnamon, Mate and Xfce: turn off all visual effects

6. Visual effects are nice, but they can slow down your system and even cause stability problems. That's why Cinnamon, Mate and Xfce have only a few visual effects enabled by default.

You can gain some speed and stability when you turn off those as well. Proceed as follows:

Turn off visual effects in Cinnamon

6.1. Disabling the "heavy" visual effects in Cinnamon, consists out of three steps:

a. First do this:
Menu button - Preferences - Effects
Turn off everything there.

b. Then do this:
Menu button - Preferences - System Settings
Section Preferences: General
Disable compositing for full-screen windows: set the slider to ON.

c. Finally:
Menu button - Preferences - Window Tiling
Enable Window Tiling and Snapping: set the switch to OFF.

Note: all this disabling has at least one negative side effect (which is a bug): when you try now to launch your media player from within the sound applet in the desktop task bar, Cinnamon will crash. Launching your media player from the menu is thankfully still no problem, though.

I consider this easily avoidable bug as a small price to pay, for the system resources that you've freed for more important tasks....


Turn off visual effects in Mate

6.2. Disabling visual effects in Mate is easy:

a. Menu button - Preferences - Windows
Tab General: deselect: Enable software compositing window manager

b. Remove Compiz:

Launch a terminal window.
(You can launch a terminal window like this: *Click*)

Type (use copy/paste to prevent errors):

sudo apt-get remove compiz-core

Press Enter. When prompted, type your password. Your password will remain entirely invisible, not even dots will show, this is normal.
Press Enter again.

Turn off visual effects in Xfce

6.3. Even lightweight champion Xfce has some relatively heavy visual effects by default. Disable them like this:

a. Menu button - Settings - Desktop Settings
Window Manager: set it to plain Xfwm4 (instead of Xfwm4 + Compositing)

b. Remove Compiz:

Launch a terminal window.
(You can launch a terminal window like this: *Click*)

Type (use copy/paste to prevent errors):

sudo apt-get remove compiz-core

Press Enter. When prompted, type your password. Your password will remain entirely invisible, not even dots will show, this is normal.
Press Enter again.

Add-ons and extensions: don't turn your web browser into a Christmas tree

7. You can install a lot of add-ons (extensions) in the web browsers Firefox, Chrome and Chromium. Those add-ons can be very useful, but they have a couple of important disadvantages, because they are "applications within an application":

- they slow your browser down, especially if there are a lot of them;

- they can cause malfunctions, both in each other and in the browser itself;

- it has occurred: add-ons with malicious content. Don't trust them blindly.

So don't turn your browser into a Christmas tree: don't adorn it with lots of add-ons. Limit yourself to only a few add-ons, that are really important for you.

Note: watch out for add-ons that claim that they make your browser faster! Often they do more harm than good. Do not install them: even if one or two of them can really make your browser run noticeably faster, they may damage the stability of your browser.

Make Firefox write less to the hard disk

8. By default, Firefox writes a lot to the hard disk. This costs system resources.

You can sharply reduce the write actions of Firefox by disabling the session restore feature, which remembers what pages were opened if Firefox experiences an unexpected shutdown (read: crashes). This feature is neat, but causes many disk writes. You can disable it as follows:

Type about:config in the url bar of Firefox and press Enter. Click the button to accept the risk.

In the search bar, type: sessionstore

Double-click on the item called browser.sessionstore.interval. The default interval is 15000, which means 15 seconds. Add three zeroes to the existing value, so that it becomes: 15000000 and click the OK button (note: adding too much zeroes causes an error!).

Now disable the following three other sessionstore items, by simply double-clicking them (so that "true" becomes "false"):

browser.sessionstore.restore_on_demand

and:

browser.sessionstore.resume_from_crash

and:

services.sync.prefs.sync.browser.sessionstore.restore_on_demand

Close Firefox and launch it again.

Lots of RAM (at least 4 GB): put /tmp on tmpfs

9. Does your system have lots of RAM memory? If it has at least 4 GB, then you can probably speed up your system a bit by placing /tmp on a tmpfs partition. Which means, translated into ordinary language: you bring about that temporary files will not be placed on the hard disk anymore, but on a virtual RAM disk instead.

This is how you do it:

a. Launch a terminal window.
(You can launch a terminal window like this: *Click*)

Copy/paste this green line into the terminal (it's one line!):

sudo cp -v /usr/share/systemd/tmp.mount /etc/systemd/system/

Press Enter. Type your password when prompted; your password will remain entirely invisible, not even dots will show when you type it, this is normal.

b. Then copy/paste this command into the terminal:

sudo systemctl enable tmp.mount

Press Enter.

c. Reboot your computer.

d. After the reboot: check whether it works, with this terminal command:

systemctl status tmp.mount

By default, a tmpfs partition has its maximum size set to half your total RAM. The actual memory consumption depends on how much you fill it up, as a tmpfs partition doesn't consume any memory until it is actually needed.

Note: do not apply this on systems with less RAM than 4 GB! Because then this tweak won't make them faster, but (much) slower.

How to undo tmpfs

9.1. Do you wish to undo tmpfs? Then copy/paste this line into the terminal:

sudo rm -v /etc/systemd/system/tmp.mount

Press Enter. Type your password when prompted; your password will remain entirely invisible, not even dots will show when you type it, this is normal.

Afterwards, reboot your computer.

Speed up your wireless internet

10. For some wireless chipsets, a simple tweak is sufficient for increasing the speed and the connection quality of your wireless internet. Namely disabling the power management for the wireless chipset. The price you pay is obviously an increase in power consumption, although this increase isn't big.

You can do that as follows:

a. First find out if Ubuntu or Mint applies power management to your wireless chipset:

Launch a terminal window.
(You can launch a terminal window like this: *Click*)

Type in the terminal:
iwconfig

Press Enter.

You can then not only see the name for your wireless chipset (for example: wlp2s0), but also whether Power Management is on for it. When it's off, or when no mention is made of Power Management at all, you don't need to do anything.

b. When Power Management is on, proceed as follows.

In order to prevent typo's, copy/paste this line into the terminal (it's one line!):

gksudo xed /etc/NetworkManager/conf.d/default-wifi-powersave-on.conf

Press Enter.

Now a text file opens. In that text file, you see the following content:

[connection]
wifi.powersave = 3


Change 3 into 2.

Save the modified file and close it.

c. Reboot your computer.

d. Then check in the terminal, by the command iwconfig, whether Power Management for the wireless chipset is off now.

If so, you're done!

Speed up your Intel wireless chipset

11. If you have a (reasonably) modern wireless chipset from Intel, it'll run on the iwlwifi driver. If so, you'll probably be able to increase its speed noticeably, by turning on Tx AMPDU for it.

The purpose of AMPDU is to improve data transmission by aggregating or grouping together several sets of data. Thus it sharply reduces the amount of transmission overhead.

It used to be "on" by default in the iwlwifi driver. But several years ago, it was turned off because of stability issues on a few wifi chipsets. This problem category is, however, only a minority.

For turning it on, proceed like this:

a. First check whether your chipset runs on the iwlwifi driver:

Launch a terminal window.
(You can launch a terminal window like this: *Click*)

Use copy/paste to transfer this line into the terminal:
lsmod | grep iwlwifi

Press Enter.

Does the terminal output contain the word iwlwifi (in red letters)? If so, proceed with the next step.

b. Use copy/paste to transfer the following blue line (it's one line!) to the terminal. Don't type it: it's too easy to make typing errors....

echo "options iwlwifi 11n_disable=8" | sudo tee /etc/modprobe.d/iwlwifi11n.conf

Press Enter and submit your password. Note that your password will remain entirely invisible, not even asterisks will show, which is normal.

c. Reboot your computer.

d. Finally, check your new wireless speed, for example on speedtest.net.

Has your wifi become unstable? Then undo the iwlwifi hack as described below (item 11.1).

Problems? Then undo it like this

11.1. Does the iwlwifi hack create stability issues for your wifi? Then undo it with the following terminal command:

sudo rm -v /etc/modprobe.d/iwlwifi11n.conf

Then reboot. All should be then, as it was before.

Clean up your Mint

12. A clean Mint will perform better than a Mint that has become polluted too much (although pollution is much less of a problem than in Windows). This is how to clean Linux Mint.

Want more tips?

12. Do you want more tips and tweaks for Linux Mint? There's a lot more of them on this website!

To the content of this website applies a Creative Commons license.


Comments