Configuring Alpine (or Pine) to read your mail
Last updated December 23, 2009
The Alpine command is a terminal-based mail client available on the CCIS Linux machines. It is the current version of the earlier Pine program. (Pine is not available on our Linux machines, but if you are trying to read your CCIS mail from a non-CCIS computer that has Pine installed, these instructions should work approximately the same for Pine.)
Most of this HOWTO assumes you receive your mail via our Zimbra server, but at the very end we explain what to change if you are still using our older legacy infrastructure.
To configure Alpine, open a terminal window (Applications → Accessories → Terminal) and type alpine.
If you’ve never used Pine or Alpine before, you’ll get a welcome message that tells you to use “Setup/Config” to configure Alpine, and asks you (via the menu at the bottom of the screen) to press “E” to exit or hit Return to send a message counting yourself as an Alpine user. When you do so, you’ll be taken to the Alpine main menu, which looks roughly like this:
ALPINE 2.00 MAIN MENU Folder: INBOX No Messages
? HELP - Get help using Alpine
C COMPOSE MESSAGE - Compose and send a message
I MESSAGE INDEX - View messages in current folder
L FOLDER LIST - Select a folder to view
A ADDRESS BOOK - Update address book
S SETUP - Configure Alpine Options
Q QUIT - Leave the Alpine program
Copyright 2006-2008 University of Washington
[Opening "INBOX" DONE]
? Help P PrevCmd R RelNotes
O OTHER CMDS > [ListFldrs] N NextCmd K KBLock
except with spacing and highlighting. In particular, the “L FOLDER LIST” line
is highlighted. Press “S” for “SETUP” (or press the down-arrow to select it and hit Return). Then, on the Setup screen, press C for Config.
SMTP server
Using the arrow keys, move down to the “SMTP Server (for sending)” line, and press “C” for “Change Val” (or you can just hit Return).
Type zimbra.ccs.neu.edu and hit Return, so that the line reads
SMTP Server (for sending) = zimbra.ccs.neu.edu
Inbox path (location of incoming mail)
Then move down to the “Inbox Path” line, and change that so it reads
Inbox Path = {zimbra.ccs.neu.edu:993/ssl/user=yourusername}INBOX
(replacing yourusername with your real CCIS login name, of course. For instance, my CCIS login name is jay, so I would change that to {zimbra.ccs.neu.edu:993/ssl/user=jay}INBOX. All the funny punctuation is important; the stuff in curly braces identifies the IMAP server, and INBOX is the folder name on that server.
Then press “E” to “Exit Setup”, and say “Y” when asked whether to save your changes.
Note: Once you’ve changed your incoming mailbox (“Inbox Path”), you’ll be prompted for your CCIS password near the bottom of the screen, so that Alpine can connect to the server to get your mail. That will also happen whenever you start Alpine in the future.
Zimbra folders
In order to read your incoming mail and send outgoing mail, those are the only two settings you need to change, but you probably want Alpine to be able to see all your other Zimbra folders, too (like Trash and Sent, and any folders you create).
To configure Alpine to access your saved Zimbra folders, press “S” from the main menu to get back to “Setup”, but then press “L” for “collectionLists” to get to the “Setup Collection List” screen. Then press “A” to “Add Cltn”. The “Nickname” can be anything you choose; “Zimbra” or “CCIS” are good choices. For “Server”, you should specify zimbra.ccs.neu.edu/ssl/user=yourusername (using your real CCIS login name for yourusername, of course). “Path” and “View” can be left empty. (If you’re using Alpine to connect to other IMAP servers as well as Zimbra, though, you might want to see the help information for Path.) Here’s an example, for my account:
Nickname : Zimbra Server : zimbra.ccs.neu.edu/ssl/user=jay Path : View : Fill in the fields above to add a Folder Collection to your COLLECTION LIST screen. Use the "^G" command to get help specific to each item, and use "^X" when finished.
As prompted, press Control-X (“^X”) when done and say “Y” when asked whether to save your changes.
Now you have two folder collections defined; besides the one you’ve just created, there’s a default one called “Mail”, described as “Local folders in mail/”. If you’re using Zimbra for all your mail, you probably want to delete that since you don’t need it, and if you leave it defined, you’re likely to save things there by accident (which will prevent you from getting to them via other mail clients, including Zimbra’s web interface). So highlight it and press “D” for “Del Cltn”. Check that you’re deleting the right collection (“Mail”, not whatever you called your Zimbra folders) before saying “Y” to confirm.
Then press “E” to exit setup. Now you can press “I” to see the messages in your current folder (which starts out as your inbox), or “L” to select a folder. (When you hit “L”, if you have more than one folder collection defined, you’ll get to choose among them. Otherwise, you’ll just be shown all the folders in your only collection. If you’ve taken our advice above to delete your “Mail” collection and leave only a Zimbra collection, you’ll see all your Zimbra folders when you choose “L”.)
Your .pinerc file
Alpine (and the earlier Pine) stores its configuration into a file called .pinerc in your home directory. If you prefer, you can edit that file (while Alpine is not running) to change your configuration instead of using Alpine’s internal configuration mechanism.
If you just run alpine and immediately quit it, it will create an well-commented .pinerc configuration file for you, with all the default settings. Then you can edit it with your favourite editor. For example, here are some extracts from my .pinerc file:
# List of SMTP servers for sending mail. If blank: Unix Alpine uses sendmail.
smtp-server=zimbra.ccs.neu.edu
# Path of (local or remote) INBOX, e.g. ={mail.somewhere.edu}inbox
# Normal Unix default is the local INBOX (usually /usr/spool/mail/$USER).
inbox-path={zimbra.ccs.neu.edu:993/ssl/user=jay}INBOX
# List of directories where saved-message folders may be. First one is
# the default for Saves. Example: Main {host1}mail/[], Desktop mail\[]
# Syntax: optnl-label {optnl-imap-hostname}optnl-directory-path[]
folder-collections=Zimbra {zimbra.ccs.neu.edu/ssl/user=jay}[]
Using Alpine with our old legacy email infrastructure
If your mail is not delivered via Zimbra, and you do not wish to request a migration to Zimbra (which you can do at https://gozimbra.ccs.neu.edu/), you can tell Alpine to talk to our old IMAP and SMTP server. Use imap.ccs.neu.edu instead of zimbra.ccs.neu.edu when specifying your inbox (and any folder collections):
Inbox Path = {imap.ccs.neu.edu/ssl/user=yourusername}INBOX
And use mail.ccs.neu.edu instead of zimbra.ccs.neu.edu as the “SMTP Server (for sending)”.
However, we encourage you to move to Zimbra at your earliest convenience. Among other reasons, that gives you an excellent web interface for times when you may not be able to make an SSH connection to CCIS (or if you need to see a message sent in HTML with its full formatting intact).
You must log in to post a comment.