Subject: Moving messages from VAX/VMS to UNIX/Berkeley

From: Mike Brudenell <[email-masked]>
Date: Fri, 12 May 1995 11:47:51 +0100 (BST)

Hi!

We are in the process of discontinuing our old VAX/VMS service (scheduled 
to be switched off at the end of June).  Instead all our users are moving 
to UNIX (actually IRIX on SGI boxes) and will be using Pine for their mail.

A lot of people (thankfully) have been making the move over the past year.

However some people have been using the VAX/VMS service right to the 
bitter end, and have a number of mail messages they'd like to "take with 
them" to UNIX.

I was thinking of a little utility that could be used to read the 
messages saved from VAX mail using an "EXTRACT/ALL" command (messages are 
written into a file separated with Line Feeds) and write a Berkeley 
format mailbox.

Then I wondered if anyone had already faced this problem and either 
written such a utility already, or had some other suggestion.

Anyone?  (he said, hopefully! :-)

Mike Brudenell                                               <[email-masked]>
------------------------------------------------------------------------------
The Computing Service, University of York, Heslington, York, YO1 5DD, UK
Phone: +44-(0)1904-433811  FAX: +44-(0)1904-433740

---

From: Portia Shao <[email-masked]>
Date: Fri, 12 May 1995 13:14:46 -0700 (PDT)

> written such a utility already, or had some other suggestion.

I have written a little utility which depends on you having an IMAP2 
server on both systems to move the mail from one system to another.
Since PMDF is the only VMS package which comes with an IMAP server on the 
VMS side, this depends on you having PMDF on your VMS system. If you do 
have it and are willing to try it out, send me mail, and we'll arrange 
something.

> Mike Brudenell                                               <[email-masked]>

     /portia     [email-masked]
     Innosoft International Inc. (818)919-3600 voice, (818)919-3614 fax
     1050 East Garvey Ave South, West Covina, CA 91790

---

From: "Steven D. Majewski" <[email-masked]>
Date: Fri, 12 May 1995 17:17:28 -0400 (EDT)

> > written such a utility already, or had some other suggestion.

I have managed to use 'formail' ( from the procmail package ) to 
do this, but I don't recall the details - mainly, because I did it
more than once with slightly different methods, with various levels
of success at different occasions, but all of them were quite some
time ago. 

I do recall that I had some trouble getting the date set correctly.
Some mailers ( I think pine was one ) are more strict than others
on the format of a "From " line and expected the date to be in the
proper format. Formail can generate a date if there is none in the
message, but since there was a "Date:" *VMS* header ( not in rfc822
format ), it just appended the improper date to the "From " line. 

I think I made two (or more) passes, temporarily renaming the "Date:"
header lines to "X-Date:", so that it would regenerate a "From " line
with the proper syntax, and then changing them back to "Date:" lines,
so that the mailers would display the proper date. ( I guess that
effectively made "arrival" date the same for all the messages, but the
send date was at least correct, if not correct rfc822 syntax. ) 

 On one of the attempts, I also recompiled formail with a different
message separator defined, but I don't recall if I needed this the
last time, but I don't recall what methods or switches I used to 
get it to separate the messages properly. If you try this, be sure
to get a count of the number of messages from VMS, and then check 
that you see the correct number from the unix mailer - if you don't,
then some messages may have gotten wrongly concatenated ( i.e. not
gotten properly separated! )  

---|  Steven D. Majewski   (804-982-0831)  <[email-masked]>  |---
---|  Computer Systems Engineer          University of Virginia  |---
---|  Department of Molecular Physiology and Biological Physics  |---
---|  Box 449 Health Science Center    Charlottesville,VA 22908  |---

---

From: Mark Crispin <[email-masked]>
Date: Fri, 12 May 1995 17:57:27 -0700

On 12 May 1995, Steven D. Majewski wrote:
> proper format.

For the record, this is true.

There is a reason why it is this way.  We wanted to avoid the lossage with
message text lines that begin with the word "From"; specifically that a
">" character gets inserted in front of them.  But, we also had to avoid
the hokey "Content-Length:" header (it's a long story).

This was a requirement; our local users were getting pissed off at the
bogus ">"  characters in their messages.  [Of course, another alternative
is to use a format other than Unix mbox format...]

The solution we came up with is that our mail delivery tools do *not*
insert the ">" character in front of lines that begin with "From", unless
it is in a very precise format that is certain to be a message delimiter.
In turn, Pine does not consider a line that beings with "From" to be a
message delimiter unless it is in that precise format.

There are 20 variants of "From" header line that Pine recognizes.

Most mail delivery tools blindly insert the ">" in front of all message
lines that begins with "From", and most mail readers blindly declare any
line that begins with "From" to be the start of a message.

The problem comes in when a mail delivery tool uses some format of "From"
delimiter which is not one of the 20 that Pine knows about.  To date, all
of these episodes have been caused by site-local tools and not by any
known widely-distributed software.  But this can cause the situation of
"other tools work but Pine does not."

Partisans of the infamous "Content-Length:" mechanism may chime in and say
that they don't have this problem.  They're right; they have a completely
different set of problems that are potentially worse.  ;-)

ANYWAY...  For the most part, it works.  I'm fairly confident that the 20
supported variants cover what is actually out there.  I'm aware of a few
additional variants but as noted above they seem to be more due to local
mistakes.

-- Mark --

DoD #0105, R90/6 pilot, FAX: (206) 685-4045  ICBM: N 47 39'35" W 122 18'39"
Science does not emerge from voting, party politics, or public debate.