HPlogo HP ARPA File Transfer Protocol User's Guide > Appendix A MPE/iX and POSIX Differences

Building and Transferring a Bytestream File

MPE documents

Complete PDF
Table of Contents
Index
Glossary

E0300 Edition 6 ♥
E1098 Edition 5

These examples create a bytestream file in the POSIX shell and MPE namespace with the vi editor and then transfers that file to a remote system with FTP.

Example 1:

File transfer HP3000 MPE/iX to HP3000 MPE/iX system.

  :sh
  ######################################################################
                 MPE/iX Shell and Utilities (A.00.00)
     COPYRIGHT (C) Hewlett-Packard Company 1992, All Rights Reserved.
  ######################################################################
  shell/iX > vi

This is a test file with sample data.

-
:w bytestrm

  shell/iX> ls bytestrm
  bytestrm

  shell/iX> /SYS/ARPA/FTP
  File Transfer Protocol [A0006018] (C) Hewlett-Packard Co. 1990

  ftp> :LISTFILE /SYS/PUB/bytestrm
  PATH= /SYS/PUB/

  bytestrm

  ftp> pwd
  257-"/SYS/WORK" is the current directory.
  257 ",MANAGER.SYS,WORK" is the current session.

  ftp> put /SYS/PUB/bytestrm
  200 PORT command ok.
  150 File: ./bytestrm;REC=,,B;DISC=2147483647,8 opened; data connection
    will be opened
  226 Transfer complete.
  38 bytes sent in 0.00 seconds (18.55 Kbytes/sec)

  ftp> dir ./bytestrm
  200 PORT command ok.
  150 File: LISTFILE .bytestrm,2 opened; data connection will be opened

  PATH= /SYS/PUB/

  CODE  ------------LOGICAL RECORD-----------  ----SPACE----  FILENAME
          SIZE  TYP        EOF      LIMIT R/B  SECTORS #X MX

           80B  FA          38 2147483647   1       16  1 32  bytestrm

  226 Transfer complete.
  230 bytes received in 0.01 seconds (24.96 Kbytes/sec)

Example 2:

File transfer HPUX (unix) system to HP3000 MPE/iX system.

  vi bytestrm

This is a bytestrm test data file.

  :wq
  "bytestrm" [New file] 1 lines, 34 characters


  ftp> put bytestrm ./bytestrm
  200 PORT command ok.
  150 File: ./bytestrm;rec=,,b opened; data connection will be opened
  226 Transfer complete.
  35 bytes sent in 0.00 seconds (64.73) Kbytes/sec)

  ftp> dir ./bytestrm
  200 PORT command ok.
  150 File: LISTFILE ./bytestrm,2 opened; data connection will be opened

  PATH= /SYS/PUB/

  CODE  ------------LOGICAL RECORD-----------  ----SPACE----  FILENAME
          SIZE  TYP        EOF      LIMIT R/B  SECTORS #X MX

            1B  BA          35    2048007   1       16  1  8  bytestrm

  226 Transfer complete.


NOTE: When transferring a Bytestream file from UNIX to a MPE/iX system it is necessary to specify ";rec=,,b". This is required as a result of FTP/iX supporting a default of "fixed" file type rather than bytestream which is the default on UNIX and POSIX systems.

Example 3:

File transfer HP 3000 MPE/iX system to HPUX (UNIX) system.

  ftp> bytestream
  200 Type set to L (byte size 8).
  ftp> put ./bytestrm
  200 PORT command successful.
  150 Opening BINARY mode data connection for ./bytestrm.
  226 Transfer complete.
  35 bytes sent in 0.00 seconds (+INF Kbytes/sec)
  
  ftp> dir ./bytestrm
  200 PORT command successful.
  150 Opening ASCII mode data connection for /bin/ls.

  -rw-r--r--   1 jph     network     35 Jun 20 16:19 ./bytestrm

  226 Transfer complete.
  66 bytes received in 0.18 seconds (0.37 Kbytes/sec)




Bytestream Files


FTP Default Name Space