eMail

Leaving Google

I’m not going to go into a ton of detail, because I am sure I have rambled about it before, but I have had a pretty downward relationship with Google. There was a time when I was an enormous Google fanboy, and that slowly started to decline as they started just, removing services and features, and the core turn happened when they dumped Google Reader. Over the last ten years or so I’ve slowly migrated things away from Google, though I never quite outright left Google. In fact, technically i still and not quite “leaving” Google.

This is the problem with a company like Google, you can never quite “leave”. Most of what I use though wasn’t super due to choice. I use YouTube, because there isn’t really an alternative, for example. I also continues to use Gmail and Calendar, because I had a free Legacy G-suite account, that allowed me to use my domain for my email. I do also have a Legacy Gmail account, from when things were Invite Only as well. I don’t really use Docs or drive, except for a few annoying services that don’t offer alternatives. I sort of used Photos, but more as a backup to my backup to my backup, never as a primary, and I stopped when they discontinued the Unlimited Storage.

I have a variety of reasons I dislike Google, but I’m not going to get into all of that here and now.

However, it recently came to my attention that Google is discontinuing it’s free tier Legacy G-suite accounts. Previously these accounts were grandfathered, but now they are going away. This is an enormous problem for a lot of people who use this as their Primary account, central to their work flow. Thankfully, in my case, I have mostly stopped using Google for my workflow, but this is definitely giving people a bad time. The only option is essentially to pay to upgrade to a regular account, at $6/month on the lowest tier.

Part of my annoyance stems from having to hear about this from a Podcast, talking about Microsoft offering a discount to people who switch. I didn’t get the email, as the email went to my admin account, that I never check and forgot existed. Granted that is on me, but I wonder how many others are going to get screwed by this.

My only worry at the moment is what will happen to my Play Store purchases. It appears that my account will be able to downgrade to an Identity Account, which will allow me to keep my Play Store purchases. It also seems to keep YoutTube data as well. but to be safe I’m shuffling that around as well (more in a bit).

So what do I, personally, need to do about this?

The main issue is email. I use my domain email on Google a lot. It’s one of two Primary Email addresses, and it’s the top one of those two. Fortunately, I already run an email server for some secondary domains. I was planning to get rid of that email server, but it could wait for a bit while I wind down my Primary Email as well.

Fortunately, I didn’t need to go this route. I pay for Microsoft 365. I suppose it’s worth mentioning, my problem with what is happening with Google, isn’t the paying. The $6/month tier at Google is just not worth it for me. I dislike Google as a privacy nightmare for starters. The search results have been shot for years, they push a lot of weird lock ins. Docs/Sheets sucks next to MS Office as well, and you get a LOT more space with One Drive than Google Drive. The lowest tier of Google’s offerings is $72/year, and I pay $99/year for Microsoft 365, for SIX accounts, which I use across my family.

Anyway, Microsoft 365 offers the ability to use a custom domain email. The set up is designed to be simple, and uses GoDaddy, which I don’t use, but there is an easy work around to use any domain registrar. It’s all just DNS records. If you are capable enough to set up DNS records, you are capable of following this helpful guide on Reddit. You may need to massage things a bit, for some reason the guide has a 0 leading the @ entry which I didn’t need. Though I did need to set the Priority to “0” (Zero) before it took, over on Cloudflare’s DNS. I followed the guide, and around 24 hours later (probably would have been sooner but I had Priority 5), the email was coming in to my Outlook account instead of my Gmail account.

The biggest hurdle was out of the way.

It’s worth mentioning, that Gmail will still contain the older emails. It may be EASIEST, to clean out those emails BEFORE transferring the domain. You can probably still connect the old account to something like Outlook or Thunderbird, but to be sure, either make sure you already set up the Gmail account in a client, before the transfer, if you go this route. This suggestion is honestly, for any 3rd part email provider. You can do a Take Out request, but it’s much easier to just use a client, then drag and drop emails.

In my case, I already had MOST of my emails cleaned out. I keep a local email server on my Synology NAS, with a sorted archive of all my emails. If you really want to be thorough, once you have copied the emails off, go back to the Gmail web interface, select “All Mail”, then use the “Select all” button at the top of the list to delete everything.

Next step was calendars. This was fairly simple. I opened Outlook’s calendar and Google Calendar in tabs side by side. I copied the URL for any web calendars I was subscribed to (use the ical URL) over to Outlook. I then took a moment to sort out the events on my remaining user created Google Calendars, before exporting and importing them to Outlook. Lastly, Google Calendar lets you create tasks and reminders, I manually copied those all into Microsoft ToDo, (which I also, already used). The remaining task, my wife has a Google Calendar from her Gmail account that we share. I’ll transfer my half of that from my Gsuite account to my Gmail account and be done there. I’d convince her to convert it to Microsoft but frankly convincing her to do the shared calendar int he first place was enough of a hassle.

After the Calendar we have Docs, well, Drive, and mostly Sheets. I honestly could never quite get Google’s naming for it’s office suite. I don’t keep much in my Google Drive, some PDFs I had clipped and a few shared docs I had saved off. I simply downloaded everything and sorted the files out to other places in my archive structure.

Photos is tedious, but not hard either. I already have better back up systems in place for my photos, using some USB drives in a safe and One Drive in the cloud through my NAS. I did have thousands of photos uploaded to Google Photos however, from around 2005 through 2019. Mostly I am just going through periodically and deleting them all out, downloading a few here and there just to make sure that I have them saved locally, which I probably do. These “here are there” things are more like, scanned photos, some random work photos, some screen shots from my phone. Things that may have been direct uploads basically, instead of pushed up by the old Photo Uploader from my archive.

The last real potential issue is YouTube. I have several channels on YouTube, though I don’t use them a lot for posting, I do use them for different things. 3 of the 4 channels are “Brand Accounts”. I had previously converted them to Brand Accounts to consolidate ownership under this Gsuite account. This also makes it easier to shuffle ownership back to my Gmail account. I have a 4th channel that is just a regular YouTube account, that I will likely convert to a Brand account and shuffle over to the Gmail account as well. I may also just copy it’s playlists over and call it good.

The last worry, I mentioned before, is my Play Store purchases, mostly Apps, I don’t care about books and movies or music as everything I have gotten there is free. I suspect I will continue to be able to use this account as an ID account, connected to those app licenses. Ideally, I would love to transfer ownership of everything to my Gmail account, but I don’t think that’s going to be offered as an option.

Migrating Mail-In-A-Box to a New VPS

A few years ago, I started running my own mail server using Mail-In-A-Box. Four years or so actually, if the age of my old server was accurate. I have several different email addresses, mostly to better segment out content. I have done this with Reddit, and Twitter, and TT-RSS, and probably other things. In my Mail-In-A-Box I run email for 3 domains, two of mine, one for my wife’s. Overtime I may eventually migrate all of my email to it, at this point, I am a little worried about being blacklisted, so I mostly use it for secondary, receive only, email aggregation.

For a while I’ve been putting off migrating the system to a new VPS. It’s been running on Ubuntu 14.04 since it was created. Newer MiaB won’t run on 14.04 and I can’t distro update the machine. The only choice is to roll a new VPS and migrate the mail.

I use Digital Ocean for my online services, feel free to sign up with the link in the side bar if you want, I get a little kickback if you do. It’s easy to use and affordable. Plus in cases like this, I can spin up an extra VPS, then easily destroy it and spin up a new one, when I discover that MiaB only works up through 18.04, so 20.04, which I used initially, won’t work. Also having the extra server just means a temporary bump in my billing for the month.

The basic process for migrating Mail-In-A-Box is here, in the official documentation. I had a few hiccups along the way but I got them ironed out.

First step was creating the new machine. I mentioned above, I first made a 20.04 machine, but found that doesn’t work, so I killed that and made a new 18.04 machine. Before anything else, I did a few security based housecleaning tasks. The server was creating with Shared Keys log in set up, but it only had a root account. So I created a new user and made them a sudoer. I also copied the SSH keys from root to the user.

adduser Username
usermod -aG sudo Username
cp ~/.ssh /home/Username
chown Username:Username /home/Username/.ssh -R

Next step was to add the new user to the SSH users and secure up that access.

sudo pico /etc/ssh/sshd_config

Then edit:

#Port 22

To a custom port and change:

PermitRootLogin no

Finally add:

AllowUsers Username

Lastly restart the ssh server with sudo service sshd restart. Then test the connection using the regular user. If that works, then disconnect from the root session and continue on the regular user.

I was doing an upgrade but the fresh install guide is here. All I needed was the set up line really, which takes a minute to run but does an initial set up of Mail-in-a-Box.

curl -s https://mailinabox.email/setup.sh | sudo -E bash

The next part was the trickiest bit. I linked the migration article above but I ended up trying to simplify things a bit. On the old machine, I stopped the mailinabox service, so no new mail would come in, then ran the backup python script as described int he article above. I found it was easiest to just connect to the server using Filezilla using SSH FTP, which meant importing my keys to Filezilla. It’s in the settings under SFTP. Something to keep in mind if you set a custom port is you’ll need to add sftp:// before the IP address.

Things are a little tricky here, since root owns the backup folder. I ended up doing a sudo copy into my user home directory, then a chown on the folder to give my user account access to the folder. This meant Filezilla could see the folder and download it to my local machine. There are way to directly transfer between the new and old server, but between custom ports and SSH keys and permissions, I found it was easiest just to download to my local laptop. Afterwards, I connected with SFTP to the NEW server, and pushed the backup folder to the new server. You need the whole folder with the “secret_key” text file and the encrypted folder and files. Basically, this is all the settings and emails.

Next step was to ssh into the New Server, go to the freshly uploaded backup directory, and import the old files, as described in the link. This is two commands run, separately.

export PASSPHRASE=$(cat secret_key.txt)

sudo -E duplicity restore --force file:///home/Username/backup/encrypted /home/user-data/

This takes a minute to run. The next step listed is to rerun the mailinabox set up with “sudo mailinabox”.

I had trouble here. Nginx would not restart. After sound troubleshooting I found it was an issue with SSL. Basically what seemed to happen was the restore, pulled the old SSL certs. Or maybe it was looking for the old SSL certs. Whatever the case, the fix was this process.

rm -rf /home/user-data/ssl/*

The fix was to delete the SSL certificates. then run “sudo mailinabox”. Everything started up. I verified I could log into the control panel and the mailbox using the UP address of the new server. I verified that all my custom DNS records existed, these are needed since the Glue Records point to the Mail-In-A-Box machine but because I host my websites on a separate machine, I have to have DNS records set up appropriately.

One thing I noticed was the SSL Certificates seemed to be wrong, which meant things worked, but would cause annoying security messages. I am not sure if this was related to deleting the certs above, or just that it was still looking for the old IP address. Whatever the case, I did a manual update with certbox for my MiaB Subdomain using

sudo certbot certonly --force-renewal -d Subdomain.Domain.comHere

Another minor issue I ran into, doing this needs to drop a file either in the webroot folder, or spin up a temporary web server to host it’s own file. I couldn’t find the webroot for the custom MiaB set up (it was not /var/www/html) so I temporarily ran “sudo service nginx stop”, then ran the above certbox command, using a temporary webserver option, then “sudo service nginx start” to restart Nginx. NGinx had to be stopped since otherwise it is using Port 80, and the temporary server can’t start to runt he certificate verification process.

Another note, I am not sure if the –force-renewal option is needed above. It didn’t throw out any errors and it fixed the issue, so I left it.

The final step was to go to my Domain Registrar and update the name servers and Glue Records to point to the new Server IP. After a short bit of waiting, eventually the mail server URL connected to the admin and web consoles. I did some test send and receive of emails between my server and gmail to verify everything was working properly. One nice bit, the newer MiaB has a different interface for Roundcube webmail, so I could easily tell if I was going to the new or old server.

Once everything was satisfactory, i went back to Digital Ocean and powered down the old server. If everything is still working in a few days, I will destroy the old server, so I don’t have to keep paying upkeep on it. One thing to keep in mind, both the old and new servers require a specific hostname, so they will be named the same, so double check that you are powering down and deleting the correct server. some easy ways to verify are IP address, or server age. The old server is several years old but the new server is several days old.