Tag Archives: Backup

Archive and Transfer your Google Mail

When an employee leaves your company you may need to archive.

Using the Chrome browser:

1. Sign into your google account.

2. In a new tab, browse to the following address: https://takeout.google.com/settings/takeout/custom/gmail,calendar

3. Follow the wizard.  You can choose to make an archive just of your eMail and calendar, or you can select information from other services such as Google Drive.

4. Once you have selected the services that you want,  click on Next

This shows the file version (zipped),

5. Click on Next again   This starts the archive process.  You can access the archive after it created by clicking on the link that Google sends to your eMail account.


Set default text editor in Ubuntu

I was looking at our crontab on our backup server. This server is an Ubuntu 12.x LTS machine, and the logs for this were being sent to my predecessor, and I wanted to change the eMail address. The usual procedure is to run the following command to see and edit the contents of the crontab file:

crontab -e

This brings up the crontab file for the root user.  Crontab is probably for another day, but basically the script shows a MAILTO address that I wanted to change.

# Edit this file to introduce tasks to be run by cron.
#  m h  dom mon dow   command
0 23 * * * rsync -avz root@ /backup/hive
0 18 * * * /backup/scripts/rsync_agave.sh
0 17 * * * /backup/scripts/rsync_basil.sh
0 1  * * * /backup/scripts/rsync_mysql1.sh
0 4  * * * /backup/scripts/rsync_mimic.sh
0 2  * * * /backup/scripts/rsync_petal2.sh

Running the crontab-e opens up the file in the default editor. Well, I didn’t even realize I had a default editor on this machine, and the file opened in vim, which is an archaic program, beloved by Unix freaks.  I prefer the nano editor, especially because I don’t use a text editor much, and I know how nano works.

After some digging it appears that the default editor is set as an environment variable specific to the user.  It can be changed by running the following command:

export EDITOR=nano

You can view your current environment variables, by typing


There will be a line similar to


In Ubuntu, you can also use the following command: 

sudo update-alternatives –config editor

This will bring up a list of editors from which you can choose your favorite.