Long long ago, I tried Debian and it struggled to do a lot of pretty basic things (play DVDs, hardware, graphics, laptops). I respect Debian’s enhanced wholesomeness, but the functionality was just too constrained. These days however, Debian is fine for me. In fact, it’s the only sane distribution that "doesn’t break userspace". Add your stupid new features and ways of doing things, but, jeez, don’t take away perfectly good things that people have come to depend on. I find that today (2016) Debian with MATE is 100% configurable to be exactly how I want it with minimal fuss. Here are my notes for doing that, not because it’s complicated, but because if I have a list I won’t forget anything and I will be able to set up a perfect system from scratch in about 15 minutes.


When it asks for packages choose the MATE package and sanity will be preserved.

Or, just go with minimal Debian Desktop with no window manager and then choose the window manager. This can save time when you have to install from a lower version and dist-upgrade to a higher one after.

sudo apt-get install mate-desktop-environment-core

Or this if you want all the bells and whistles.

sudo apt-get install mate-desktop-environment \

Even after doing this I still had a hard time getting it activated. Here is one plausible thing to explore.

sudo update-alternatives --config x-window-manager

For some reason that did not work at all for me. Eventually, I needed to install lightdm and then try update-alternatives. This changed the display manager and with lightdm there is a pull down at the top for choosing Mate. After doing that once, everything is fine.

Remove Exim

Do you need a MTA moving email around? No, me neither. I’m accessing all my mail on my proper server and normal people often are 100% web mail, so this large complex system can be a real mess. I’ve found it is often the top CPU consuming process on my Debian system. Here’s how to completely get rid of mail handling on Debian.

sudo apt-get --purge remove exim4 exim4-base exim4-config exim4-daemon-light


By being wholesome with respect to licenses, Debian is at odds with wifi manufacturers who are notoriously unfriendly to open source efforts. This is because they worry that they’ll get on the wrong side of the FCC with respect to radio transmission regulation if they let just anybody have complete control. Tricky problem. But once your Debian is installed and not happy with the wifi, you can go get the lesser of evils.

Here’s how to see what kind of wifi device you have.

$ lspci | grep -i net
01:00.0 Ethernet controller: Qualcomm Atheros AR8151 v1.0 Gigabit Ethernet (rev c0)
02:00.0 Network controller: Broadcom Limited BCM43225 802.11b/g/n (rev 01)

Looking through the list for "43225", I find that the driver I need is brcm80211. Following to the link I find that this cures it.

$ sudo apt-get install firmware-brcm80211

Then on reboot (you could load modules manually too) the networking icon in the bar should work.

If you’re installing and you have no other network, the installer will sometimes complain that it doesn’t have the proprietary drivers and ask if you want to supply them on removable media. It will list the exact files you need. Look those files up (you’ll need some computer/telephone somewhere for this) and find out what deb package they are part of. You need that whole deb package, not just the files it explicitly mentioned. Copy the suitable deb onto a normal person USB drive and put that in and it should find it and carry on with the install.


Dang, don’t you hate it when you start a lengthy update and walk away only to come back in an hour and find that 2 minutes into the process it stopped to ask you to read some stupid thing (ahem Debian, why don’t you guys have a look at how Gentoo does it?).

I think this generally works.

sudo apt-get -y update

But maybe you need this.

sudo apt-get -y --force-yes update

Then of course you have to do this.

sudo apt-get upgrade

No Really, Seriously, UPDATE

Debian likes its little updates, but there comes a time when all the cool people are laughing at your make version 4.0 because they’re all using 4.1. You do the update/upgrade dance and it says everything is up to date. But it is not. There may be a newer major release and the only way to know that, as far as I can tell, is to look some place like this.


For example, this page might say something like this.

  • The next release of Debian is codenamed "stretch" — no release date has been set

  • Debian 8 ("jessie") — current stable release

  • Debian 7 ("wheezy") — obsolete stable release

  • Debian 6.0 ("squeeze") — obsolete stable release

  • Debian GNU/Linux 5.0 ("lenny") — obsolete stable release

  • Debian GNU/Linux 4.0 ("etch") — obsolete stable release

(I won’t inquire about why they dropped "GNU/Linux", sorry RMS!) I had Debian 8 and I thought everything was ok. But the cool kids were using Ubuntu 16.04. Turns out that this required a more aggressive upgrade to "stretch" despite how dodgy it looks.

The procedure for doing this is nicely covered here and basically entails the following.

  • sudo apt-get update # Get current system well up to date.

  • sudo apt-get upgrade

  • sudo apt-get dist-upgrade

  • sudo cp /etc/apt/sources.list /etc/apt/sources.list_backup

  • sudo sed -i s/jessie/stretch/g /etc/apt/sources.list

  • sudo apt-get update # Start the new system upgrading.

  • sudo apt-get upgrade

  • sudo apt-get dist-upgrade


Did you just move several timezones away? Easily fixed.

sudo dpkg-reconfigure tzdata

It’s an ncurses thing — choose your new zone. Done.

Curing Caps Lock

Go to System→Preferences→Keyboard→Layouts→Options→Ctrl key position Check "Caps Lock as Ctrl".

Amazingly the virtual console can also be cured with minimal fuss.

sudo sed -i 's@\(XKBOPTIONS="\)@\1ctrl:nocaps@' /etc/default/keyboard
sudo dpkg-reconfigure -phigh console-setup

Takes effect after the next reboot.


During installation the user setup in Debian is not as helpful as I’d like it to be. I need a UID of a specific number to match everywhere else I use it and Debian doesn’t seem to think of that. Basically I just make a throwaway account during installation.

What is weird is that this account that is made during installation is not automatically (or even by setting an option) put in the sudo group. So you either have to log in as root (avoiding that is the whole reason the install system insists you create a non-root user, right?) or do this from your bogus user’s account.

su -
gpasswd -a bogusaccount sudo

And because group changes are not especially good at taking effect in any Linux I know about, you have to log out of bogusaccount and then back in. Now bogusaccount has sudo privileges like it should have from the start. The other way is just to make your real account while you su into root.

Create the real account.

# useradd -m -U -u 11111 -d /home/xed -s /bin/bash xed
# passwd xed
# gpasswd -a xed sudo

Exit out of the su, log out of the bogus user, and log back in as your real user which should be fine now. Get rid of the temporary account.

$ sudo /usr/sbin/deluser --remove-all-files delme

Use delgroup if the group lingers.


It can help to add your main user to groups that may help things. Here are some I’ve had to deal with.

  • dialout - to use the serial ports

  • video

  • crontab

  • wireshark

  • bluetooth

  • audio

Just add them with something like this.

gpasswd -a xed dialout

Or all in one go.

for G in dialout video crontab audio ; do sudo gpasswd -a xed $G ; done

GRUB Timeout Fix

Before you reboot to let the new groups settings take effect, might as well fix grub’s time out. When I’m trying to get the full power cycle round trip down around 20s I don’t need 5 seconds spent on the grub prompt. Here’s how to shorten that.

sudo sed -i 's/TIMEOUT=5/TIMEOUT=2/'  /etc/default/grub
sudo grub-mkconfig
sudo update-grub

Remove Useless Bars

The bar at the bottom of the screen is absurdly redundant. It normally contains a Workspace Switcher which can sometimes be useful. Still, absolutely no need for two screen wasting bars.

Right click the top panel. Choose "Add To Panel" and find "Workspace Switcher" at the very bottom of the list. Feel free to add System Monitor if that makes sense. Now you can safely get rid of the bottom panel by right clicking on it and selecting "Delete this panel".

Right click on the top panel and choose "Properties". Orientation should be "Left" and check "Autohide".


Open a terminal with Applications→System Tools→MATE Terminal

On the menubar click Edit→Profiles and select "Default" and click Edit. Choose Colors tab and uncheck "Use colors from system theme". Choose "White on black" from the pull down. Choose Scrolling tab and choose "Scrollbar is: Disabled" and give a scrollback buffer of 5000. Close.

Create a new keyboard shortcut for this command.

/usr/bin/mate-terminal --hide-menubar

Bind it to Ctrl+Shift+N.

Alt-Tab Annoyances

The new Mate shows some very misleading icons when you alt-tab. These are derived from your actual windows which sounds good in theory but in practice it is that is super confusing and annoying. Apparently it’s a bit slower too because the setting to change to cure it is this.

gsettings set org.mate.Marco.general compositing-fast-alt-tab true

Remove Useless Desk Icons

First install dconf-editor.

apt-get install dconf-editor

Run that as a normal user since these settings are done per user. If you run it as sudo it will apply the settings to the root account.

Go to org->mate->caja->desktop and change the following by sliding the "Use default value" switch to grey/left and then choosing "False" (until it is dark gray) as your "Custom value"; click the green checkbox in the lower right and you’re good. Scrub all of these dumb icons.

  • computer-icon-visible

  • home-icon-visible

  • trash-icon-visible

I’ll leave "volumes-visible" because I want to know if that kind of automounting ever happens. See below.

One time I was cleaning dumb stuff in my $HOME directory and I got rid of the empty Desktop directory. This put stupid icons for the entire contents of $HOME on the "Desktop". I like to have a completely blank desktop so this was very bad. I cured it by making an empty directory called ~/.Desktop and then making sure this file was this way.

$ cat .config/user-dirs.dirs

You can also explore the xdg-user-dirs-update script whose reason to exist seems questionable.

No Automounting

I don’t need USB flash drives doing nefarious things behind my back; I’ll mount things explicitly, thanks.

Again use dconf-editor as previously mentioned look for this.

  • Uncheck automount

  • Uncheck automount-open

  • Check autorun-never

Also look at this.


Same deal. This seems to cure it if the first doesn’t.

After doing all this I still had automounting problems. What finally cured them was this.

systemctl mask udisks2
systemctl stop udisks2

I don’t know what is sufficient and necessary but these are good hints.

And if you’re like me and you don’t like automounting, you might like a comprehensive set of mount points.

sudo mkdir -v /mnt/sd{a..z}{1..4} /mnt/sd{a..z}


System→Preferences→Appearance In the Theme tab I like "TraditionalOkTest"; you can’t miss it which is the point.

Meddling with Firefox default CSS can be fun too. Power to the client where it belongs! Check this out.


Of course this will cause many stupid forms to show up black on black or white on white since dumb web devs will set one or the other. So it’s best to make these have some color and to know how to look for this file in the Shift-F7 style profiler or Inspect Element.

Display Manager Settings

One thing I sometimes like to do, especially with portable computers, is to put my contact information on the login page. This way if someone finds my computer and wants to return it to me, they can (without leet hacker skills). I have done this by changing the default login background which is an SVG. Of course getting everything to line up on all monitors can be a pain.

If you want your own SVG image on the login screen investigate the lightdm-gtk-greeter-settings package. Once installed look under System->Control Center. Or maybe just play around with putting your own image at /usr/share/images/desktop-base/login-background.svg. Actually, that’s a nest of symlinks — I think the real one lives at /etc/alternatives/desktop-theme/login/background.svg.

Here’s one I use that can give you some ideas. Just cut and paste this to be the login-background.svg file somehow.

<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<svg xmlns="http://www.w3.org/2000/svg" width="1920" height="1080" viewBox="0 0 480 270" version="1.1" >
  <!-- == Background == -->
  <defs> <linearGradient id="thegradient" x1="200" y1="100" x2="800" y2="800" gradientUnits="userSpaceOnUse" >
      <stop style="stop-color:#000000" offset="0" /> <stop style="stop-color:#888888" offset="1" />
  </linearGradient> </defs>
  <rect y="0" x="0" height="1080" width="1920" style="fill:url(#thegradient)" />
  <!-- == Place Features == -->
  <g transform="matrix(.35,0,0,.35,180,50)"> <!-- Xscale,rot,skew,Yscale,Xpos,Ypos -->
    <!-- == X Logo == -->
    <g transform="translate(-93.766085,42.315052)" style="fill:#9ab0c9;fill-opacity:1;stroke-width:0.5" >
      <path d="M-100,100 L-68,100 C-55,72 -35,50 -6,38 L0,60 L6,38 C38,50
      55,72 68,100 L100,100 L100,68 C72,55 50,33 38,6 L60,0 L38,-6 C50,-33
      72,-55 100,-68 L100,-100 L 68,-100 C55,-72 33,-50 6,-38 L0,-60 L-6,-38
      C-33,-50 -55,-72 -68,-100 L-100,-100 L-100,-68 C-72,-55 -50,-33 -38,-6
      L-60,0 L-38,6 C-50,33 -73,55 -100,68 z M-20,20 L-8,0 L-20,-20 L0,-8
      L20,-20 L8,0 L20,20 L0,8 L-20,20 z" fill="#ff8800" stroke="#cecece" stroke-width="3"> </path>
    <!-- == Text == -->
    <text fill="#ff8800" font-size="24" font-family="sans-serif" x="20" y="50">Chris X Edwards</text>
    <text fill="#ff8800" font-size="16" font-family="sans-serif" x="60" y="70">chris@xed.ch</text>
Chris X Edwards chris@xed.ch


System→Preferences→Monitors Uncheck "Same image in all monitors".


Out of the box, the middle buttons on my Logitech Marble Mouse are not activated. Somewhat outdated Ubuntu chatter is possibly helpful here.

Some newer information is coming to light on the Amazon answer where I complained about it.


What worked was to put this in ${HOME}/.xsessionrc.

# Fix the marble mouse problems.
if grep "Logitech USB Trackball" /proc/bus/input/devices >/dev/null 2>&1 ; then
    xmodmap -e 'pointer = 1 8 3 4 5 6 7 2 9' >/dev/null 2>&1

Check .Xsession-errors and /var/log/lightdm/* if there are errors, especially ones that prevent you from starting a session.

Screensaver Lock

Under System→Preferences→Screensaver, uncheck Screensaver and Locking. Click the Power Management button and from there set "Put display to sleep when inactive for:" to "Never".

Also if it’s not installed, install mate-power-manager and under System→Preferences→Power Management look for "Put display to sleep when in active for:" should be "Never" (since it takes so damn long for it to wake up).


Start browser for the first time with this.

iceweasel https://noscript.net

Go ahead and add Self-Destructing Cookies, Privacy Badger, HTTPS Everywhere, and JS free DDG.

Add this to .bashrc.

export BROWSER=/usr/bin/iceweasel
alias ff='bash -c "${BROWSER} &";exit'


sudo apt-get install vim
sudo apt-get purge nano
echo 'export EDITOR=/usr/bin/vim' >> .bashrc
sudo update-alternatives --config editor

This may also be good in .bashrc

alias visudo='sudo EDITOR=/usr/bin/vim /usr/sbin/visudo'

Display Manager Fixes

I understand not publishing a list of users at the login prompt but for a single user system, that’s just annoying. Strangely Debian seems to default to this.

The fix appears to be in the greeter-hide-users setting in /etc/lightdm/lightdm.conf. [Untested]

Guest Account

The popular parasite distribution has a "guest" log in. That’s probably very bad for many situations. But it can make sense if you want to let trusted people use your computer. This can be accomplished in Debian by just making a new user whose home directory is in the /tmp directory.

sudo useradd -d /tmp/guest -s /bin/bash guest

No need to set a password, right? Hmm. Kind of sketchy if this host is on the real internet in any way!

Screen Blanking - NOT!

Sometimes it can be very annoying to have 10 subsystems all trying intently to get you to save the pixels on your phosphorous CRT by causing the screen to go blank after inactivity. Sometimes you have something you want to watch untouched for an hour. How to stop this madness of screen blanking?

Here are some things to check.

  • System→Preferences→Look and Feel→Screensaver (obviously)

  • System→Preferences→Hardware→Power Management

  • xset -dpms CURED IT

  • xset s off

  • xset s noblank


A reminder to myself of what I need.

  • .vimrc

  • .bashrc (put . ~/.bashrc in .bash_profile)

  • .screenrc

I usually do something like this.

cp ~/.bashrc ~/.bashrc_orig
rsync -v --rsh='ssh -p ${PORT}' ${IP}:/home/xed/.bashrc ~/.bashrc-xed
ln -sf .bashrc-xed .bashrc


  • rsync - It is usually present but some excessively minimal systems omit it. Which is crazy.

  • ssh

  • feh

  • htop

  • dstat

  • lftp

  • screen

  • inkscape

  • gimp

  • git

  • sshfs

  • make

  • gcc

  • smartmontools

  • net-tools - route, ifconfig, netstat, arp

  • dnsutils - provides nslookup, dig

  • wireshark

  • tcpdump - no, it doesn’t come with wireshark!

  • mtr

  • mplayer

  • ffmpeg

  • mpg123

  • x11-xserver-utils - now includes "xrandr"

  • mercurial

  • wmctrl - for starting the idiotic firefox in the right place

  • cryptsetup - LUKS

  • system-config-printer - if you need to print and the config tools are not there.

Cut and paste this…
sudo apt install rsync ssh feh htop dstat lftp screen inkscape gimp git sshfs make gcc smartmontools net-tools dnsutils tcpdump
sudo apt install wireshark mplayer ffmpeg mpg123 x11-xserver-utils mercurial wmctrl cryptsetup mtr


Sometimes Debian can be a real PITA by not having a sensible way to install required (proprietary) firmware images during the initial install. This can prevent graphics and wifi, for example, from working.

  • firmware-realtek - Have WIFI problems? Maybe the venerable Edimax USB adaptor?

  • firmware-amd-graphics - Have AMD graphics? Maybe on a laptop?

Optional Packages That Are Sometimes Useful

  • xpdf - Seems to bring in cups so consider that carefully.

  • abcde - Need to "archive" personal music CDs? Generally not needed for work machines.

  • asciidoc - Brings in the whole TeX universe at an obese 1.2 GB!!! And seems dead.

  • asciidoctor - Needs Ruby which (a comparatively light 7MB) but is not dead like asciidoc.

  • chromium - Sometimes you need the Google Desktop Client. Sometimes you don’t.

  • xfsprogs - Only if you formatted something XFS of course. Which is worth doing!

  • wireless-tools - Only if you’re using wifi. Provides iwconfig, iwlist, etc.

  • openvpn -

If you installed from mate-desktop-environment-core as an upgrade to Mate rather than just selecting the entire Mate oriented distro you might also find use for these.

  • mate-applets (for system monitor)

  • mate-system-monitor


Graphics stop working after a new install on an Nvidia system? Well, those Debian folks have mixed feelings about Nvidia’s proprietary drivers. On one hand they make it so it doesn’t work, but on the other hand you can fix that. Official help is here.

Try to log in some how and install


This may require appending the lines in your /etc/apt/sources.list with main contrib non-free instead of just main.

Run that program and install what is recommended. For my NVIDIA Corporation GK104 [GeForce GTX 760] I had to install


In old times it was sometimes required to have something like this in place.

Section "Device"
    Identifier "My GPU"
    Driver "nvidia"

But today I’ve successfully ignored it. Simply…



Steam was pretty easy to install. First, add this to /etc/apt/sources.list. Replace jessie with the proper version (e.g. stretch) if needed. Actually just find this line and add contrib non-free to the main entry already there.

deb http://httpredir.debian.org/debian/ jessie main contrib non-free

The installer says this incredible absurd thing. In 2019!

Steam is a 32-bit program, so running it on this computer requires the 32-bit versions of the Nvidia libraries, even if all the games you will run via Steam are 64-bit. Please install the nvidia-driver-libs-i386 package.

This seems to be necessary and probably can’t hurt on a Steam box.

dpkg --add-architecture i386

Don’t forget to do this.

apt update

Then you can just do the obvious.

sudo apt install steam

If you get the error an error like this…

You are missing the following 32-bit libraries:

I used to have luck with this.

apt-get install libgl1-nvidia-glx-i386

Now on 9 (stretch) and 10 (buster), I’ve had luck with this.

apt-get install libgl1-nvidia-glx libnvidia-glcore:i386

Needs a reboot because of the module situation.

To move the obese user directories to another volume, set up something like this.

  • .steam → /data/xed/S/.steam/

  • Steam → /data/xed/S/Steam/

  • .steampath → .steam/sdk32/steam

  • .steampid → .steam/steam.pid

How to move downloads from previous installations is an ongoing area of research, but it looks like you’ll want the manifest files as well as the directories actually containing the game.

:->[usb128][~/old_steam/.steam/steam/steamapps]$ cat appmanifest_370360.acf
    "appid"     "370360"
    "Universe"      "1"
    "name"      "TIS-100"
    "StateFlags"        "4"
    "installdir"        "TIS-100"
    "LastUpdated"       "1482809267"
    "UpdateResult"      "0"
    "SizeOnDisk"        "84036583"
    "buildid"       "717588"
    "LastOwner"     "76561198123579102"
    "BytesToDownload"       "29826000"
    "BytesDownloaded"       "29826000"
    "AutoUpdateBehavior"        "0"
    "AllowOtherDownloadsWhileRunning"       "0"
        "Language"      "english"
        "370363"        "1208369354753219700"
:->[usb128][~/X/old_steam/.steam/steam/steamapps]$ ls -d common/TIS-100/

This seems to work. Shut down Steam first. Copy the .acf manifest files into the steamapps directory. Then copy or move the directory containing the game (referred to in the manifest) to the steamapps/common directory. When Steam starts back up, it will find these things and assume they’re good to go. As normal, it does its update check and usually starts updating some of them.