Hi. Jumping in a bit late, but anyway...
On 2021-11-28 01:40, Eckie 63 wrote:
> Hi Anton and Warner,
>
> Thank you for all the information. I see now what's happening. So, what
> I am doing is, I am transferring files from RSX to one of my Linux boxes
> using FTP. I was transferring them in binary format, because I wanted
> them just like they are stored in RSX. But the header information from
> RSX isn't coming across so none of the record info is coming across.
> Just the text data. Turns out if I transfer text files in ASCII mode, it
> seems to do the translation for me and I get perfectly readable text
> files in Linux.
What Anton and Warner wrote is basically all correct. However, it does
depend on the file attributes, which also need to be examined in order
to get the file correctly. The implied CR+LF are only implied if you
actually have the attribute implied CR+LF. Otherwise you should not add
such characters at the end of each record.
And it's only variable length record files that have a record length at
the beginning of each records. You can also have fixed length record
files, in which case the length of each record is also actually in the
file attributes.
So in order to correctly convert the raw data on disk for an RSX file,
you also need the file attributes, which is up to 20 bytes of meta-data
for the file. It can be read by special calls, but are not a part of the
actual file content.
And yes, ftp in ASCII mode does it for you. That's the whole point of
ASCII mode. It is supposed to transfer text files between systems,
independent of what the representation of a text file is on different
systems.
Binary mode should only be used when you want to preserve a file exactly
how it is, without any processing of the content. Which might mean it's
a file that don't make any sense anywhere else.
> So since I don't get any of the record info in the file in Linux, I
> can't really do much I can do once it is transferred. So it seems ASCII
> mode will be my solution. But now I have had an opportunity to use the
> DMP utility and see how useful it can be, so it was good!
In addition to just using DMP, check the /HD switch to DMP, and also
RMSDSP. Or read the manuals, which describes it all. :-)
Johnny
> <
https://groups.google.com/d/msgid/pidp-11/c3eee175-091d-4a02-8f34-6e9be7cd3a26n%40googlegroups.com>.
>
>
> --
> You received this message because you are subscribed to the Google
> Groups "[PiDP-11]" group.
> To unsubscribe from this group and stop receiving emails from it, send
> an email to
pidp-11+u...@googlegroups.com
> <mailto:
pidp-11+u...@googlegroups.com>.
> To view this discussion on the web visit
>
https://groups.google.com/d/msgid/pidp-11/2fae67bd-5943-488e-a67d-cc8665da15dan%40googlegroups.com
> <
https://groups.google.com/d/msgid/pidp-11/2fae67bd-5943-488e-a67d-cc8665da15dan%40googlegroups.com?utm_medium=email&utm_source=footer>.
--
Johnny Billquist || "I'm on a bus
|| on a psychedelic trip
email:
b...@softjar.se || Reading murder books
pdp is alive! || tryin' to stay hip" - B. Idol