Linux Mint: system hacks for advanced users


Back to the home page

Below you'll find some advanced hacks for Linux Mint, only meant for users with a lot of Linux experience. Not for beginners!


Create a frozen guest account in Linux Mint

1. Present by default in Ubuntu / Xubuntu / Lubuntu: an idiot-proof guest account that automatically reverts to the default settings upon reboot. But it's not present in Linux Mint.

In order to create a frozen guest account in Linux Mint that runs in kiosk mode (all changes in the guest session are being deleted at reboot), you have to switch your display manager from MDM to LightDM.

Extra information for Linux wizards: LightDM creates the guest account every time in /tmp , which ensures that it's being wiped entirely when the guest logs out (or shuts the computer down).

Note: this how-to has only been tested for the Xfce edition of Linux Mint 18.x. On Cinnamon, this may cause malfunctions!

You can achieve this as follows:

a. Establish internet connection.

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

c. Now install a series of software packages. Use copy/paste to transport this magical incantation to the terminal (it's one line!):

sudo apt-get install lightdm lightdm-gtk-greeter unity-greeter light-themes light-locker

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

d. During installation your terminal will show a coloured information dialog. Press Enter (to confirm OK) and choose in this selection window lightdm (use the arrow keys on your keyboard for navigation). Then use the Tab key to activate the OK button and press Enter.

Made the wrong choice? You can launch a selection screen again by the following magical incantation in the terminal:
sudo dpkg-reconfigure lightdm


e. Create a new configuration file for LightDM:

First create a certain folder. In the terminal (copy/paste):

sudo mkdir -p -v /etc/lightdm/lightdm.conf.d

Press Enter.

Now create a particular text file in the new folder. In the terminal (use copy/paste, it's one line!):

sudo touch /etc/lightdm/lightdm.conf.d/50-my-config.conf

Press Enter.

f. Now you're going to fill that text file with a particular text. In the terminal (use copy/paste, it's one line!):

gksudo xed /etc/lightdm/lightdm.conf.d/50-my-config.conf

Press Enter.

Copy / paste the following text into the empty text file (example for Mint Xfce):
[SeatDefaults]
greeter-session=unity-greeter
user-session=xfce
(In Mate you need to change the last line into user-session=mate)

Do you want the system to boot automatically into the guest account (useful for public computers)? Then add the following line as well:
autologin-guest=true


Save the modified file and close it.

g. Now some cleaning, in order to have a nice guest session. In the terminal (use copy/paste, it's one line):

sudo apt-get remove mdm mintwelcome xscreensaver-data-extra xscreensaver-gl xscreensaver-gl-extra

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

Note: this will trigger the removal of a couple of meta packages, like for example in Mint Xfce: mint-meta-xfce and mint-meta-core. This is harmless, because those list files were only needed at the installation of Linux Mint anyway.

h. Finally remove a superfluous Ubuntu logo. In the terminal (use copy/paste):

sudo rm -v /usr/share/unity-greeter/logo.png

Press Enter.

i. Reboot your computer.

j. Log into the Guest session. Note that logging in lasts longer than you might expect: this is because the Guest session has to be created fully anew in a temporary directory, each time you log into it.

Note: the guest session doesn't "borrow" its wireless internet access to your router, from your own account. For that to happen, do this, in your own account:

Click in your own account on the system tray icon of Network Manager - Edit Connections...
Click on the name of your wireless network - Edit - tab General - tick: All users may connect to this network. Click Save.

Do you want to customize the guest session further? Then read on below.

Customize the frozen Guest session (guest account) to your liking

1.1. The frozen Guest session which you've created according to the how-to in item 1 above, has default settings which might not suit you.

You can adapt those settings by a trick: you can create a "skeleton" account with the right settings and then configure the Guest session to copy those settings from the "skeleton" account. This is how you do that:

a. Create a new user account, called Hospitality. You can do that by launching "Users and Groups" from the menu. This should be a normal user account with no special priviliges.

Note: the "Full Name" of this new user should begin with a capital letter! Not the "Username", because user names have to be all lowercase. But in "Users and Groups" the new "Full Name" should begin with a capital letter, because otherwise a malfunction might occur.

Ensure that a password is required for logging into this new user account. It's best to set the same password as the one for the account of the system administrator (your personal account), because only the system administrator should be able to log into it.

b. Log out and then log into the new user account Hospitality, and configure it the way you want the Guest session to become. For example with different settings for Firefox and Libre Office.

In the next step you'll ensure that the Guest session will copy all of it's settings from the new account Hospitality. You can change those settings later on as well: later changes will also land automatically in the Guest session.

c. Log out from the Hospitality account and log into the account of the system administrator (your personal account).

d. Launch a terminal window and copy/paste the following command line into it:

sudo mkdir /etc/guest-session

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

Then copy/paste this command line into the terminal:

sudo ln -s /home/hospitality /etc/guest-session/skel

Press Enter.

(note that hospitality doesn't begin with a capital letter in the command)

e. Log out from your account and log into the Guest session. Now it should have the same settings as the new user account Hospitality.

The only disadvantage is, that you now have an extra "useless" user account in the login window.

How to undo (back to MDM)

1.2. Undoing display manager LightDM and reverting to the original MDM is easy (note that your guest account will disappear as well):

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


b. Use copy/paste to transport this magical incantation to the terminal:

sudo apt-get install mdm

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


c. Now your terminal shows a coloured information dialog. Press Enter (to confirm OK) and choose in this selection window mdm (use the arrow keys on your keyboard for navigation). Hit the Tab key to activate the OK button and press Enter.


d. Reboot your computer.

Use Conky to monitor your system

2. Conky is a very useful and versatile tool for checking what's going on in your system. You can find a how-to with screenshots on this page.
(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.

Thanks in advance....


Problems with Libre Office? Install a newer Libre Office

3. If you experience problems with your current version of Libre Office, you can install a later version of Libre Office with this PPA. Namely 5.1.x.

This is how to do it (item 8, right column).

How to manually install a non-free driver for your Nvidia video card

4. Do you have a graphics card from Nvidia, which is so new that the proprietary restricted driver version in the software repositories of Mint is too old? Then you can proceed like this.

Install the latest iwlwifi driver for your new Intel wireless card

5. In certain circumstances you may need a newer iwlwifi driver for your Intel wireless card, than the one that's available by default. For that, you can proceed as follows:

a. Download the zipped driver file for your kernel version:
https://wireless.wiki.kernel.org/en/users/drivers/iwlwifi

Don't do anything with it. Only download it and don't even click on it.


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


c. Now move the old driver to the root folder, in order to disable it. For that, use copy/paste to transport this magical incantation to the terminal:

sudo mv -v /lib/firmware/iwlwifi-* /

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


d. Then unpack the downloaded file like this:

cd Downloads && tar xvzf ~/Downloads/iwlwifi*.tgz


e. Now go to the folder with the unpacked driver, like this:

cd iwlwifi*


f. Then move the new driver to the right location:

sudo mv -v iwlwifi-*.ucode /lib/firmware


g. Reboot your computer, in order to load the new driver. Your wireless Intel card should now run on the new driver.


h. Finally, pin the package linux-firmware to its current version, in order to prevent potential future problems by updates:

sudo apt-mark hold linux-firmware

Automatic shutdown when closing laptop lid (all desktops)

6. It's useful when closing the laptop lid invokes an automatic shutdown, even when Power Manager doesn't allow for that option in your desktop environment. In all desktops that can be achieved like this:

a. Copy/paste the following command line into the terminal:

gksudo xed /etc/systemd/logind.conf

Press Enter.

b. In that text configuration file, find the following line:

HandleLidSwitch=ignore

in some cases this line looks a bit different, namely: #HandleLidSwitch=suspend

Delete it and replace it by this line:

HandleLidSwitch=poweroff

Save the modified text file and close it.

c. Reboot your computer. Closing the laptop lid should now evoke an automatic shutdown of your computer.

Note: on some laptops an undesirable side effect might occur, namely a CPU that becomes very hot, causing its cooling fan to start blowing full speed all the time.

In that case I advise to undo this hack.

Disable IPv6 (when you can't establish internet connection)

7. Some old modems and routers can't deal properly with modern IPv6. This might cause a bad unstable connection or even a complete failure to establish any connection at all. In that case, disable IPv6 like this:

Menu - Preferences - Network Connections

Click on the name of your current connection - click the button Edit...
Tab IPv6 Settings - Method: change it into Ignore

Click the button Save... and then click the button Close

Disconnect and reconnect, or simply reboot your computer.

Install a brand-new unsupported kernel

8. Sometimes, when you have a very new computer, you have a problem: the drivers in the Linux kernel of Linux Mint, aren't recent enough. In that case, you can do the following:

a. First of all, you can try whether a newer officially supported kernel suffices:
From the menu, launch Update Manager. In the toolbar of Update Manager: View - Linux kernels
Install the very latest kernel in the list.

Then reboot your computer.

b. If that kernel still isn't new enough, you can install an even newer and wholly unsupported kernel by means of a non-official (and therefore less safe) software source: the canonical-kernel-team PPA.

Note that the newer kernel you're about to install is unsupported in your version of Linux Mint, so there's an increased risk of malfunctions and errors. This should therefore only be done as emergency measure.

The method is as follows:

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

Then in the terminal (use copy/paste to avoid typing errors):

sudo add-apt-repository ppa:canonical-kernel-team

Press Enter. Type your password; your password will remain entirely invisible, you won't even see dots, that's normal. Press Enter again.

With this, you add the software source to your sources list.

c. Then in the terminal (use copy/paste):

sudo apt-get update

Press Enter. With this, you inform your system about the contents of the newly added software source.

d. From the menu, launch Update Manager. In the toolbar of Update Manager: View - Linux kernels
Install the very latest kernel in the list.

Then reboot your computer.

e. After this reboot your computer should run on the latest kernel. Check it by means of the following terminal command:

uname -r

Press Enter.

Install newer touchpad support

9. Emergencies only (negative side effects are quite possible): problems with your touchpad? Try whether a newer version of touchpad support does a better job:

For 64-bit, download this:
http://archive.ubuntu.com/ubuntu/pool/main/libi/libinput/libinput-bin_1.6.3-1ubuntu1_amd64.deb

Then this:
http://archive.ubuntu.com/ubuntu/pool/main/libi/libinput/libinput10_1.6.3-1ubuntu1_amd64.deb

Then this:
http://archive.ubuntu.com/ubuntu/pool/main/libw/libwacom/libwacom2_0.22-1_amd64.deb

Finally this:
http://archive.ubuntu.com/ubuntu/pool/main/libw/libwacom/libwacom-common_0.22-1_all.deb

Installation:

cd Downloads

sudo dpkg --force-depends-version -i libinput-bin*

sudo dpkg --force-depends-version -i libwacom2*

sudo dpkg --force-depends-version -i libwacom-common*

sudo dpkg -i libinput10*

Reboot.

Want more tips?

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.

Back to the home page

Disclaimer

Comments