Reading Email Using Legacy Mail Client

by Charles McGrew


Please Note: This procedure is a hack to allow users who must use legacy mail client to read incoming email without using a new POP3 or IMAP mail client.

This procedure will only work in:

  • constance.rutgers.edu -> for Faculty/Staff account
  • bloustein.rutgers.edu -> for research account

    To use an old mail reader you must first download mail to a local file, and then run your mail reader on that local file. The program we recommend is getmail. To use getmail, you must first create a configuration file for it, in a file called .getmail/getmailrc (you will have to create the .getmail directory yourself.) Your .getmailrc file should look like:

    [options]
    delete=true
    
    [retriever]
    type=SimpleIMAPSSLRetriever
    server=dragon.rutgers.edu
    username=your_username <- change your_username to your own username
    
    [destination]
    type=Mboxrd
    path=/var/mail/your_username  <- change your_username to your own username
    
    

  • delete=true
    says to delete messages from the folder once they have been downloaded. delete=false will leave them where they are on the server.
  • type=SimpleIMAPSSLRetriever
    tells getmail to use ssl and imap when talking to the server. (This way your mail (and password) is encrypted when getting mail.)
  • server=dragon.rutgers.edu
    says what server to get mail from.
  • username=your_username
    is where you put your username. Please replace your_username with your username.
  • type=Mboxrd
    says to use 'mbox' (unix mail) format. The other possibility is 'Maildir', which we don't recommend.
  • path=/var/mail/your_username
    says where to stash the mail. Getmail will append new messages to this file. If this file doesn't exist, getmail will complain and not download mail. Most users should already have this file existing. If you do not, please contact

    Getting multiple mailboxes

    If you want to download multiple mailboxes (that is, more than "INBOX"), at once, you can add something like the following to getmailrc after username=

         mailboxes=("INBOX","Myotherfolder")
    

    ... this will collect files from both folders into the file you've set with the "path" line. (If no mailboxes are specified, getmail assumes "INBOX".)

    Alternatively, you can run multiple invocations of getmail, specifying configuration files (each, for instance, with a different set of folders and path values), by specifying a different configuration file with the -r switch, like:

        getmail -r myotherconfigurationfile
    
    ... due to a slightly dumb parsing algorithm in getmail, to specify a single non-INBOX folder, you must write the configuration line like this:

         mailboxes=("INBOX",)
    

    ... with the trailing comma.

    Runtime

    When it runs, getmail looks like:
    [mcgrew@alert ~]$ getmail
    /usr/lib/python2.3/optparse.py:668: FutureWarning: %u/%o/%x/%X of
    negative int will return a signed string in Python 2.4 and up
      return ("<%s at 0x%x: %r>"
    getmail version 4.6.0
    Copyright (C) 1998-2006 Charles Cazabon.  Licensed under the GNU GPL
    version 2.
    SimpleIMAPSSLRetriever:your_username@dragon.rutgers.edu:993:
    Enter password for SimpleIMAPSSLRetriever:your_username@dragon.rutgers.edu:993:
    
    ... at this point, you type your dragon mail password. It will not be echoed. getmail then tells you what it is doing:
      msg  1/29 (1569 bytes) delivered, deleted
      msg  2/29 (1569 bytes) delivered, deleted
      msg  3/29 (1569 bytes) delivered, deleted
      msg  4/29 (23799 bytes) delivered, deleted
      msg  5/29 (1569 bytes) delivered, deleted
      msg  6/29 (1931 bytes) delivered, deleted
    .
    .
    .
    
    ... then run your mail reading program as before.
  • Login