Tag Archives: email

Improving your privacy with a custom email domain

This blog post is a follow-up to It’s Time to Ditch Gmail. It began as a review of Fastmail, and my experience of moving to it from Gmail, but I quickly found myself going on a tangent. Since privacy was the main driver in my decision to move to Fastmail, and using a custom domain is one of the ways that I protect my privacy, I figured it was important enough to warrant its own post.

One of the factors that made it easier to move away from Gmail is my use of a custom domain for most of my mail. Before moving to Fastmail, this domain was tied to a GSuite account which forwarded everything to my standard Gmail account. This made switching in anger much easier, as I had fewer accounts to log in to and update my email address, and those that were still pointing directly at Gmail tended to be older low-value accounts that I no longer use anyway.

In this article though, I want to take a detour to explain why I use a custom domain, and how it can aid your privacy. Continue reading

It’s Time to Ditch Gmail

I haven’t written much about privacy on this blog, despite often behaving, by some people’s standards, like a paranoid schizophrenic where my data is concerned. Until fairly recently I used to run a rooted phone with XPrivacy installed, which is about as private as you can get without ditching smartphones altogether. These days I’ve gone back to a stock un-rooted phone, partly because Android permissions have improved (although you do have to be careful with apps targeting older APIs), and partly because rooting is more risk and burden to me as a user. Also, some apps actively attempt to block rooted devices for quite legitimate (if, I would argue, misguided) reasons.

Anyway, I could go on for hours about Android privacy, but the subject of this post is Gmail. We all know that Google mines your personal data for targeted advertising purposes. But when giving data to companies, there’s a balance between functionality that is useful to you, and commercialising your data for purposes that, often, are not in your best interest.

While Gmail was once an innovative service, I’d argue that the scales have long been tipped in favour of commercialisation, and that today the data cost of Gmail outweighs its value as a service. Continue reading

Bash script to alert when memory gets low

We have a web server that’s running out of memory about once every couple of weeks. The problem is that when it happens the swap file is totally full, the system is unresponsive and it usually needs a hard reboot. So it’s a bit difficult to debug. To avoid digging through log files I don’t understand I elected to put a script in /etc/cron.hourly which checks the total amount of free memory (including swap and physical). If there is less than 256mb free (this server has 512mb of ram and a 1gb swap so at this point the situation is serious), it dumps the process list to /tmp/processes.txt and sends me an email with it attached.

Note that mutt must be installed (‘apt-get install mutt’ on Debian/Ubuntu, or ‘yum install mutt’ on RedHat/CentOS).


free=`free -mt | grep Total | awk '{print $4}'`

if [ $free -lt 256 ]; then
        ps -eo %mem,pid,user,args >/tmp/processes.txt
        echo 'Warning, free memory is '$free'mb' | mutt -a /tmp/processes.txt -s "Server alert" email@me.com

Then of course make it executable and symlink to cron.hourly:

chmod +x /etc/scripts/memalert.sh
ln -s -t /etc/cron.hourly/memalert.sh /etc/scripts/memalert.sh