[Info-vax] difference in files being copied by scp from Unix to VMS

Sumir sumirmehta at gmail.com
Tue Apr 28 23:34:21 EDT 2009


On Apr 28, 12:56 pm, JF Mezei <jfmezei.spam... at vaxination.ca> wrote:
> Sumir wrote:
> > Is it possible to force the end-of-filemarker, so that it is read
> > differently (using say set/file/attrib or something similar)
>
> There is no magical solution to fix the brokenfile. FromVMS'spoint of
> view, all of the data prior to the end offileis perfectly valid andVMSdoesn't know where you would want the end offileto really be.
>
> You could write a utility that scans thefileand figures out where the
> last real byte is, and then use an RMS call to update where the ened offileshould really be. (forget what the system call incantation is to
> update the FAB).
>
> In terms of the SCPfiletransfer you used, do you recall what options
> you used at both ends ?
>
> did you use binary transfer at both ends ? Did you specify /VMSwhen
> sending it to theunixsytem ?
>
> As a recall, when afiletransfer utiity (such as Kermit) wants to send
> a "rich"VMSfilewith all its attributes, it sends a small bock ahead
> of the data , that block contains variousfilesettings (record format
> etc etc).  If this is store on the remote system and sent back to theVMSsystem, then the receivingVMSsystem will use that block to set the
> samefileattributes as the originalfile.
>
> Such a process allows the transmission of indexed files in a way that
> thefilecan be recreated on anortherVMSsystem (as opposed to sending
> the data as a sequentialfileand build a new indexfilefrom scratch on
> the remote system).
>
> One possibility is that the sending process sent some 140 bytes ofVMS
> information ahead of thefile, the receivingUnixsystem realised this
> wasVMSrelated junk and discarded it, but forgot to not count that data
> towards thefilesize.
>
> One thing you could try is to set the originalfile'sattributes to
> something very odd (such as RFM=FIX,LRL-387) (fixed length, record
> length = 387) and then transfer thefileback and forth and see if it
> recreated with the same attributes.



I tried out this....

var = F$FILE(FILE1,"FFB")
set file/attribute=(FFB:'var) FILE2

this way i was able to make the eof byte same for both the files, and
then the diff does not show up the extra nulls. I guess this would
solve out the problem.




More information about the Info-vax mailing list