old-www/LDP/LG/issue01to08/mail_jan96.html

101 lines
4.2 KiB
HTML

<HTML>
<HEAD>
<TITLE> E-Mail and Linux </TITLE>
</HEAD>
<BODY>
<H1> E-Mail and Linux</H1>
<P>
by <B>Edward Cameron</B>
<A HREF="mailto: ecame119@ecity.net">&lt;ecame119@ecity.net&gt;</A>
Copyright (c) 1996<BR>
<H5>Published in Issue #6 of the Linux Gazette</H5>
<HR>
<P>
Rec'd a copy of Eudora Lite mail reader for Windoze that other day. (a promo; I get a lot junk mail and sometimes I get lucky)
Being curious, I booted Windoze and installed the demo and played around with it for about an hour. Jotted down some notes.
Composed and sent a few e-mail messages.
<P>
Fed up with the ugly Windoze screen, I rebooted Linux; with sanity restored I decided to see if I could
get PINE to automatically retrieve mail from my ISP.
Before I started working on this, I had to telnet to ecity.net and use Pine on their end in order to read and send
email. (IDT uses Linux boxes as Internet servers!) This endeaver took two weeks of off and on again effort. Finally
I found all the pieces of information and programs that would allow me to retrieve e-mail from a POP2/3 server
and place it into a user directory on my machine. Along the way I've messed up my system to the point I can't
use PERL now. (don't ask...!)
<P>
What you need: POPCLIENT and PINE. I'm gonna harp about the PINE program as I feel it's the finest mail reader I've seen for
Linux. Nothing in the X window series of mail readers come close and what there is is not worth the effort to write about.
<P>
POPCLIENT can be found on any sunsite mirror in Mail/readers. (I have a quarterly CDROM and got the program from there)
Pine is provided with nearly every Linux distribution.
<P>
There are a few 'popper' programs as well. Some I tried didn't compile and those that relied on Perl didn't work
for me either. POPCLIENT works and is just what I was looking for.
<P>
Create a script file as follows:
<P>
#!/bin/sh
<PRE>
echo "
Checking for mail.....
"
popclient -3 -u <I>your ISP username here</I> <I>your ISP here</I> -o $HOME/mail/inbox
echo "
done....
"
</PRE>
<P>
for example you might have:
<P>
<CENTER> popclient -3 -u jblow sunsite.unc.edu -o $HOME/mail/inbox </CENTER>
<P>
You will have to provide your password every time you run the above script, but that is safer than having a clear copy
of it sitting around for some hacker to discover. If you have a permanent ppp connection, then you can create a cron job entry for the above
and set a time to kick the script file off, say every day or hour or whatever to, automatically get your mail.
<P>
<H3> Setting up the services file for POP</H3>
<P>
I'm taking a step back here as I haven't mentioned two important steps. You must have an entry in the <I>services</I> file
in order to connect to the SMTP server. The entry is detailed in the docs for popclient; I'm using a line like this:
<P>
<PRE> pop-3 110/tcp.</PRE> 110 is the port number for a POP3 server. Use 109 if your STMP server is a POP 2.
<P>
<H3> Setting up Pine</H3>
<P>
Pine needs to be set up. Enter Pine and choose 'S' then 'C'. Move the cursor down to the <B>in-box path</B> entry. You need to
tell Pine the complete path and file name for incomming mail messages. I use
<P> <I>/ecame119/mail/inbox</I>.
<P> Exit setup and Pine.
CWD to the directory you entered above and <I>touch</I> the file <B>inbox</B> into being. "chmod 600 inbox" and you're all set.
<P>
That's it folks. Automatic retrieval of e-mail under Linux. And these programs are free.
Edura is selling for around US$50.00.
<HR>
<H3>Lingo Used:</H3>
<P>
I'd like to explain some of the terms I've sprinkled in the above.
<P>
SMTP: <B>S</B>imple <B>M</B>ail <B>T</B>ransport <B>P</B>rotocol.
<P>
POP: <B>P</B>ost <B>O</B>ffice <B>P</B>rotocol.
<P>
ISP: <B>I</B>nterNet <B>S</B>ervice <B>P</B>rovider.
<HR>
<P>
There are a few more, but I'll save those for another time. To learn more, grab a book about electronic mail systems and be prepared
to be confused with all the acronyms, like MTA or MDA and MHS!
<P>
<B><I> Ciao for now.</B></I>
<HR>
<P>
Beam me back to the <A HREF="./lg_issue6.html">Linux Gazette</A>, Scotty!
</BODY>
</HTML>